官术网_书友最值得收藏!

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.

主站蜘蛛池模板: 中阳县| 松江区| 新泰市| 永新县| 商南县| 盱眙县| 宁波市| 龙陵县| 信阳市| 偏关县| 社旗县| 保德县| 闽清县| 宽甸| 遵义县| 宜黄县| 乌恰县| 张家港市| 三穗县| 丘北县| 公安县| 沧州市| 阆中市| 彰武县| 双桥区| 博客| 霍邱县| 鄂伦春自治旗| 玉树县| 紫金县| 闻喜县| 车险| 吴旗县| 资阳市| 获嘉县| 卓尼县| 雷山县| 新平| 绍兴县| 鄂托克旗| 准格尔旗|