- Mastering Microservices with Java 9(Second Edition)
- Sourabh Sharma
- 321字
- 2021-07-02 21:54:41
Services design
The following third design depicts the microservices. Here, each component represents autonomy. Each component could be developed, built, tested, and deployed independently. Here, even the application User Interface (UI) component could also be a client and consume the microservices. For the purpose of our example, the layer designed is used within μService.
The API Gateway provides the interface where different clients can access the inpidual services and solve the following problems:
What do you do when you want to send different responses to different clients for the same service? For example, a booking service could send different responses to a mobile client (minimal information) and a desktop client (detailed information) providing different details, and something different again to a third-party client.
A response may require fetching information from two or more services:

After observing all the sample design diagrams, which are very high-level designs, you might find out that in monolithic design, the components are bundled together and tightly coupled.
All the services are part of the same bundle. Similarly, in the second design figure, you can see a variant of the first figure where all services could have their own layers and form different APIs, but, as shown in the figure, these are also all bundled together.
Conversely, in microservices, design components are not bundled together and have loose coupling. Each service has its own layers and DB, and is bundled in a separate archive. All these deployed services provide their specific APIs such as Customers, Bookings, or Customer. These APIs are ready to consume. Even the UI is also deployed separately and designed using μService. For this reason, it provides various advantages over its monolithic counterpart. I would still remind you that there are some exceptional cases where monolithic application development is highly successful, such as Etsy, and peer-to-peer e-commerce web applications.
Now let us discuss the limitations you'd face while working with Monolithic applications.
- DB2 V9權(quán)威指南
- Java多線程編程實(shí)戰(zhàn)指南:設(shè)計(jì)模式篇(第2版)
- 算法訓(xùn)練營:入門篇(全彩版)
- VSTO開發(fā)入門教程
- Java Web開發(fā)技術(shù)教程
- SQL Server 2016數(shù)據(jù)庫應(yīng)用與開發(fā)習(xí)題解答與上機(jī)指導(dǎo)
- Active Directory with PowerShell
- 機(jī)器學(xué)習(xí)與R語言實(shí)戰(zhàn)
- Learning AWS
- Java程序設(shè)計(jì)基礎(chǔ)(第6版)
- 第五空間戰(zhàn)略:大國間的網(wǎng)絡(luò)博弈
- Testing Practitioner Handbook
- 網(wǎng)絡(luò)工程方案設(shè)計(jì)與實(shí)施(第二版)
- CentOS High Performance
- Java EE 8 Development with Eclipse