Onion Structure talks about separating the UI, Service, and Information Layers. All of the samples normally given for this contain a single deployment mannequin of the applying. For instance in .internet a lot of the samples are
Internet – MVC app
Core/Area – Easy class library
Information – Entity Framework
What occurs if my software has a number of deployment flavors? For instance Azure assets versus On premise SQL Server. Does the answer break down into shareable tasks? What occurs when items of the infrastructure are shared?
Host – On-Premise – has the Program.cs and Startup class solely, wires up all of the dependencies. Additionally has logic to do migration/setup for infrastructure
Host – Azure – similar as above
Internet – Controllers, View, Fashions – but it surely class library not an app
Core/Area – Would not change
Infrastructure – SQL
Infrastructure – Azure
Infrastructure – X
Is that this right pondering? ought to the “App Hosts” be as minimal as attainable and wire all the pieces up? Ought to infrastructures be separated by the infrastructure they’re using or the deployment model (On premise vs Azure)? Is it unusual to have an infrastructure layer not implement all of the repositories outlined in area layer?