Welcome to MasLazu.AspNet
A comprehensive collection of modern ASP.NET Core libraries and modules designed to accelerate enterprise application development with clean architecture principles.
What is MasLazu.AspNet?โ
MasLazu.AspNet is a modular ecosystem that provides everything you need to build scalable, maintainable, and secure web applications. From foundational frameworks to specialized modules for authentication, authorization, and communication.
๐๏ธ Architecture Overviewโ
MasLazu.AspNet implements a Ports and Adapters (Hexagonal Architecture) pattern that provides exceptional flexibility and maintainability. This architecture separates what your application does from how it does it.
Core Architecture Patternโ
The fundamental pattern follows this dependency flow:
Flexible Infrastructure Implementationsโ
The beauty of this architecture is that you can swap infrastructure implementations without changing your core business logic:
Deployment Flexibilityโ
Modules can be deployed in multiple ways without code changes:
Direct Usage (Modular Monolith)โ
Distributed Services (Microservices)โ
Implementation Variantsโ
You can create different implementations of the same abstraction for various scenarios:
- User Module - Basic user management
- User Module with RBAC - Role-based access control
- User Module with ABAC - Attribute-based access control
- User Module with Multi-tenancy - Tenant isolation
All variants share the same abstraction, ensuring client compatibility across implementations.
Key Benefitsโ
- ๐ Technology Agnostic - Switch databases, frameworks, or deployment models without core changes
- ๐งช High Testability - Mock abstractions for fast, reliable unit tests
- ๐ฆ Excellent Modularity - Self-contained modules with clear boundaries
- ๐ Deployment Flexibility - Start as monolith, evolve to microservices
- ๐ง Extensibility - Add features (RBAC, caching, etc.) without breaking existing clients
๐ฏ What's Includedโ
๐๏ธ Framework Componentsโ
Core building blocks for clean architecture applications:
- Domain Layer - Entities, value objects, and domain logic
- Application Layer - Services, validation, and business workflows
- EfCore Layer - Data access with repository patterns
- Endpoint Layer - FastEndpoints integration for high-performance APIs
๐ฆ Modulesโ
Pre-built functionality modules for common requirements:
- Authentication.Core - JWT authentication with multi-language support
- Verification - Email/SMS verification with secure code generation
๐ง Utilitiesโ
Standalone libraries for specific tasks:
- EmailSender - Multi-provider email with beautiful templates (Gmail, SendGrid)
- Future Utilities - SMS, file storage, push notifications, and more
๐ Quick Startโ
Prerequisitesโ
- .NET 9 or later
- Visual Studio 2022 or VS Code
- SQL Server, PostgreSQL, or other supported database
Basic Setupโ
- Choose the components you need from the Components Overview
- Follow the specific setup guides for each component
- Configure your database and services
- Start building your application
๐ Documentation Structureโ
- Framework - Core framework components and layers
- Modules - Authentication, verification, and feature modules
- Utilities - EmailSender and other standalone utilities
- Examples - Sample implementations and tutorials
๐ฏ Key Featuresโ
- Clean Architecture - Strict separation of concerns with Domain, Application, Infrastructure, and Presentation layers
- FastEndpoints Integration - High-performance minimal APIs with automatic OpenAPI documentation
- Modular Design - Use only what you need, extend what you want
- Enterprise Ready - Built with scalability, security, and maintainability in mind
- Modern .NET - Leverages .NET 9 features including nullable types and records
๐ค Contributingโ
We welcome contributions! Please see our Contributing Guide for details.
๐ Licenseโ
This project is licensed under the MIT License - see the LICENSE file for details.