Answers to the hottest questions about. Net microservices


In our recent special activity for us to learn about. Net microservices, we received some good questions. We have answered many questions on the spot, but we want to continue to answer some of the hottest questions in the meeting. If you miss the live broadcast, don’t worry, because you can watch it on demand.…

When we extend these services, how do we extend the databases related to these services?

There are well-defined patterns and best practices that can improve performance and scale the database. To learn how to partition data to improve scalability, reduce, and optimize performance, see horizontal, vertical, and functional data partitioning. To deeply study the scalability and distributed data of microservices, why each microservice has a database and choose between relational database and NoSQL database, please refer to our guidance on building cloud native. Net applications for azure or download free e-books.

Do we need to use a new database for each microservice, or can microservices share the same database instance?

The autonomy of the team in using microservices is an important benefit of building cloud native applications. In order to enable the team to flexibly launch updates, security patches and bug fixes in production without damaging other microservices, it is best to use independent database instances. The native cloud application architecture is inspired by the famous 12 element application methodology. One of the factors “support services” points out that auxiliary resources such as data storage, caching and message broker should be exposed through an addressable URL. Cloud providers provide a variety of rich hosting support services. We recommend checking the database options available in the cloud rather than owning and maintaining the database yourself.

Can a single web API communicate with microservices?

yes. If the endpoint of the microservice is reachable in the infrastructure, or accessed securely using a common endpoint, a monolithic application can communicate with the microservice. Microservices and their data can be consumed synchronously through their endpoints or asynchronously through messaging (such as event bus). As part of modern technology, we recommend a strangulation model that helps to gradually migrate old systems. As part of the solution, you need to create a fa ç ade that blocks requests. FA ç ade routes these requests to old applications or new services. For more information on microservice communication and modernization technologies, see the. Net Architecture Guide.

If microservices are loosely coupled and deployed independently, how do they communicate with each other? How to synchronize data between microservices?

That’s a good question. This problem is explained in detail in the two chapters of building cloud native. Net applications for azure. These links will help you:

  • Native cloud communication mode or download free e-books.
  • Manage data in distributed applications.
  • You can also download a free e-book on the microservice Architecture Guide, which covers some patterns, such as DDD, cqrs, event sources, etc.

Do microservices need containers?

It’s not necessary. However, using containers also has its benefits. Microservices, commonly known as microservice architecture, are design guidance and best practices. It helps you decompose your application into smaller services defined by specific business boundaries, which are managed independently by smaller teams. Containers combine applications, their configurations, and dependencies into a single, independent deployable unit. Container is very suitable for binding and deploying independent microservices. You can see the benefits by writing the first microservice endpoint and containerizing it.

More microservices resources

Are you looking for more microservices and local cloud resources for. Net development? Please continue to pay attention to Microsoft’s blog and official documents. If you have any questions, welcome to the Microsoft Q & a forum:…