* It hosts the **application** and **domain** layers in the **same process** (that's why it needs to have a reference to a database integration package).
* This application also **serves** the module's **HTTP API** (since it includes the HttpApi package through the Web package).
* The application **can not show UI** of the module since it does not have a reference to the Web package.
* It hosts the **application** and **domain** layers in the **same process** (that's why it needs to have a reference to a database integration package).
* This application **serves** the module's **HTTP API** (as the main goal of the application).
* **C)** An application that shows the module **UI** but does not host the application (just uses it as a remote service that is hosted by the application A or B);
* **E**) A proxy application that hosts the HTTP API of the module but just forwards all requests to another application (that is hosted by the application A, B or C);
* Adds a reference to the **HttpApi** and **HttpApi.Client** packages.
* Configures the remote endpoint for the HttpApi.Client package.
* The result;
* The application can use all the functionality of the module as a **remote client**.
* This application also **serves** the module's **HTTP API**, but actually works just like a proxy by redirecting all requests (for the module) to another remote server.
* **Domain.Shared** package, named as *CompanyName.ModuleName.Domain.Shared*, that contains constants, enums and other types those can be safely shared with the all layers of the module. This package can also be shared to 3rd-party clients. It can not contain entities, repositories, domain services or any other business objects.
* **Domain** package, named as *CompanyName.ModuleName.Domain*, that contains entities, repository interfaces, domain service interfaces and their implementations and other domain objects.
* **Application.Contracts** package, named as *CompanyName.ModuleName.Application.Contracts*, that contains application service interfaces and related data transfer objects.
* Application contract package depends on the **Domain.Shared** package.
* **Do**, for instance, create a *CompanyName.ModuleName.EntityFrameworkCore* package that abstracts the Entity Framework Core integration. ORM integration packages depend on the **Domain** package.
* **Do** create a separated integration package for each major library that is planned to be replaceable by another library without effecting the other packages.
* HTTP API package only depends on the **Application.Contracts** package. It does not depend on the Application package.
* **Do** create a Controller for each application service (generally by implementing their interfaces). These controllers uses the application service interfaces to delegate the actions. It just configures routes, HTTP methods and other web related stuffs if needed.
* **Do** create an **HTTP API Client** package, named as *CompanyName.ModuleName.HttpApi.Client*, to provide client services for the HTTP API package. Those client services implement application interfaces as clients to a remote endpoint.