Quick Start-Analysis of Microsoft microservice architecture eShopOnContainers (1), eshoponcontainers

Source: Internet
Author: User
Tags docker toolbox

Quick Start-Analysis of Microsoft microservice architecture eShopOnContainers (1), eshoponcontainers
For promotion. net Core, Microsoft provides us with an open-source Demo-eShopOnContainers, which is developed using the Net Core framework across platforms (covering almost all platforms, for windows, mac, linux, android, and ios, small applications running in containers based on the microservice architecture are not only displayed. the cross-platform nature of. Net Core shows the strength of VS2017. All code is developed under VS2017. It can be seen from the name that this is an e-Store application running on containers. Using Docker's cross-platform nature, we can "build once, run anywhere ". 1. Introduction eShopOnContainers is a simple. Net Core application based on the microservice architecture and Docker container. At present, the microservice architecture is in full swing, and docker technology is also developing rapidly. At this time, Microsoft launched this Demo, which is intended to be imagined. Although this Demo cannot be fully applied to the production environment, for our developers, however, it is very good learning materials. Whether you make some modifications or re-develop the architecture, it is very necessary to learn such a Demo. This reminds me of the previous learning of BlogEngine.. Net. 2. Architecture: Let's take a look at the structural diagram provided by Microsoft from left to right. We can see two dashed boxes, and each client application is on the left, on the right is the web application, microservice application, and database on Docker. In the Demo, Microsoft builds multiple services based on different functions, and Microsoft uses different methods to implement these services, as shown in: the above are four services displayed by Microsoft in the Demo. You can use different frameworks and databases to build your microservices, this is why microservices are so popular. I can build my services in any language or database, regardless of the language or system used by the call end. 3. The source code architecture is open-source on Github. Address: https://github.com/dotnet-architecture/eShopOnContainers We can clone the source code through git: we can see three SLNs in it. We recommend that you use vs2017. If you have installed the full version, you can open eShopOnContainers. sln, but generally for beginners, we still open the eShopOnContainers-ServicesAndWebApps.sln solution. We can see that webapp and service app are already covered in the solution. Our tutorial also follows this solution. Iv. Necessary environment: we have mentioned that our applications are cross-platform and can run on any operating system that supports Docker. However, when developing and debugging, we need the appropriate environment for debugging (of course you can also use iisexpress for debugging) 1. 64bit Windows 10 Pro2. Enable Hyper-V (Microsoft Virtual Machine) 3. Install Docker for Windows. If we use a version earlier than win10, though we can install Docker Toolbox, we cannot use VS2017 for Docker debugging. An error will be reported during running. for this tutorial, I decided to upgrade my computer to Win10 for better display. If you want to debug and run Docker Toolbox in the previous system, in addition to installing Docker Toolbox, you also need to install: 1. NodeJS2 and BowerDocker for Windows have two types of containers on win10 or server 2016, Linux iner and Windows container. Here we only need to use Linux Container (default ). Our tutorial is only for Services and WebApp. Microsoft recommends that you set the Docker memory to 4096 MB (4 GB) and CPU 3. If you want to run the full version (including the mobile client ), then you need to configure 16 GB memory for Dockere. In my personal suggestion, you 'd better have a machine dedicated to storing databases. Otherwise, a mssql-linux-SQL docker requires 4 GB memory, not to mention setting up a redis instance. When we are learning, we do not have to use Docker for debugging. We can also use iis express. which method is not important, but learning is important. 5. Learning steps: this series describes the ServicesAndWebApps. sln code. We will first learn from microservices and then look at the code structure of the web part. The general order is as follows: 1. Identity service2, Catalog Service3, Ordering Sevice4, Basket Service5, WebApp Mvc6, and WebSPA

Written at the end: Busy some time ago, but I have been very concerned about it. net Core development, in the previous builder conference, the 2.0 debut, thoroughly let me believe that Microsoft will not hesitate to develop. net, also make me wait. net Developer feels that spring is coming, so far it is all over the world. net Developer. We have been waiting for 10 years. Why choose this architecture? This is because it was written by Microsoft and has great teaching significance. Now, the concepts of microservices and Docker are getting increasingly popular, currently, the company is based on services (which has not yet reached the microservice concept) and has a lot of inconvenience in deployment, development, maintenance, and expansion. Therefore, this learning is very important to me. The first article is more nonsense. Later I will explain the code and architecture and design patterns. You are welcome to subscribe to it. Last

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.