更新时间:2021-06-24 17:02:46
封面
Title Page
Copyright and Credits
Hands-On Swift 5 Microservices Development
Dedication
About Packt
Why subscribe?
Foreword
Contributors
About the author
About the reviewer
Packt is searching for authors like you
Preface
Who this book is for
What this book covers
To get the most out of this book
Download the example code files
Conventions used
Get in touch
Reviews
Introduction to Microservices
What is a microservice?
Rules for using microservices
Understanding why to choose microservices
Effective team management
Reusable code base
Flexible scope of functionality
Maintainability
Scalability
Auto-scaling
Flexible cost
Service-oriented availability
Mixed stacks
Understanding why not to choose microservices
Initially more work
Increased complexity
Debugging and troubleshooting
Who is using microservices?
Amazon
Netflix
Uber
A lot of other companies
Comparing monolith and microservices
Multiple versions online
No downtime
Updates are as slow or fast as required
Common microservice use cases
Upgrading from monolith to microservices
Decoupling business logic
What does the application do?
What are the common components?
Reorganizing your monolith
Using authentication
Adjusting business logic
Integrating microservices
Summary
Questions
Understanding Server-Side Swift
Technical Requirements
A quick review of Swift
From Fortran to Swift
Swift performance
Scripting languages
Facebook
Twitter
VM languages
Native languages
Comparing frameworks
Swift's features
Swift on the server
Self-contained server
Linux/Ubuntu
Docker
SwiftNIO
Asynchronous events
Features of Swift 5
ABI stability
Raw strings and UTF8 strings
Result type
Future enum cases
Flattening nested optionals
Getting Started with the Vapor Framework
The Vapor framework
History of Vapor
Hello World
General structure
Configuration
Middleware
Services
RoutesBuilder
SwiftNIO – futures and promises
EventLoop
EventLoopFutures
map
flatMap
EventLoopPromises