AUA Framework Training — Episode 5

The AUA's General Structure

Understanding Software Architecture, Layering Principles, and Main Layers in AUA

Watch Video on YouTube
Solution Overview & Directory Tree

AUA Solution Folder Structure

Explore the clean, layered architecture of the AUA Framework solution. Designed strictly following Onion Architecture and Domain-Driven Design (DDD) principles.

Solution Explorer AUA.sln
📂 AUA.Solution
📁 01. Core / Domain
├── 📁 Entities
├── 📁 Enums
└── 📁 ValueObjects
📁 02. Infrastructure
├── 📁 Data / EFContext
├── 📁 Migrations
└── 📁 Repositories
📁 03. Services
├── 📁 Contracts (Interfaces)
├── 📁 Implementations
└── 📁 DataModels (Dm)
📁 04. Mapping & DTOs
├── 📁 Dtos
└── 📁 Profiles
📁 05. Presentation / Web API
├── 📁 Controllers
├── 📁 ViewModels (Vm)
├── 📄 Program.cs
└── 📄 appsettings.json
01. Core / Domain Layer
Zero Dependencies

Houses domain entities, base domain contracts (DomainEntity), audit interfaces (ICreationAudited, IDeletionAudited), and global enums.

02. Data & Infrastructure Layer
EF Core & Persistence

Contains Entity Framework Core DbContext, Fluent API configuration classes (IEntityTypeConfiguration), database migrations, and unit-of-work repositories.

03. Application Services Layer
Business Rules

Encapsulates business services inheriting from GenericService, internal DataModels (Dm), and domain logic handlers.

04. Mapping & DTOs Layer
AutoMapper Projections

Defines Data Transfer Objects (BaseDto) and custom mapping profiles via IHaveCustomMappings for seamless entity-to-dto projections.

05. Presentation / Web API Layer
REST Endpoints

Contains Web API Controllers inheriting from BaseApiController, request ViewModels (Vm), and application entry configuration settings.

Why Software Structure Matters

Software projects require constant changes and updates. If the structure develops incorrectly, it prevents changes and extensions, frequently leading to task duplication or rewriting the project from scratch.

Just like front-end developers rely on frameworks like Bootstrap instead of writing all CSS from scratch, a simple general-purpose back-end framework saves time and cost, producing high-quality, uniform architecture. Software architecture defines the structure and organization of a system to support specific operations, grouping components into related domains.

Main Layers of the AUA Framework

Depending on project size and business requirements, layers can vary, but the general core layers of AUA are structured as follows:

Common Layer

Contains shared items used across other layers, such as Tools, Enums, Consts, Extensions, and more.

Data Layer

Associated with data sources, including EF Context, Db Extensions, Search Filters, Unit of Work patterns, Configuration Tools, and Dapper Context.

Domain Entity Layer

Contains the database entities and their fluent configurations, tailored to the scale of the business.

Layer Models

Houses DTOs, View Models, Report Models, and mapping configurations (e.g., EntitiesDto, ViewModels).

Service Infrastructure Layer

The overall infrastructure framework for Services and Repositories, written and prepared for implementation.

Service Layer

Includes all core business services of the project, including BaseServices, BusinessService, EntitiesService, and ReportService.

Web API / UI MVC Layer

The user/client interface layer implemented via General MVC, WebAPI, GraphQL, or gRPC.

Test & External Services ToDo

Includes the Test layer for unit testing and the External Web Service layer for calling external third-party services.

“
”
"If you think good architecture is expensive, try bad architecture."
AUA Framework Philosophy

Official Channels & Community

Connect with the AUA Framework ecosystem.

Episode 5 Completed Add Entities (NewModule)