|
1 | | -# UMS — Enterprise User Management System |
| 1 | +# UMS - Enterprise User Management System |
2 | 2 |
|
3 | | -> **[OPEN STANDARDS](./docs/STANDARDS.md) • [OPEN MASTER INDEX](./docs/MASTER_INDEX.md) • [LEER EN ESPAÑOL](./docs/README.es.md) • [ARCHITECTURE PORTAL](./docs/architecture/index.md)** |
4 | | -> *Note: GitHub displays source files first. To skip the code and read the documentation, click the links above.* |
| 3 | +UMS is a modular monolith for identity, authorization, configuration, approvals, compliance, IGA, and audit. The repository follows the Evolith baseline and documents any local deviation through ADRs and the project documentation hub. |
5 | 4 |
|
6 | | ---- |
| 5 | +## Language |
7 | 6 |
|
8 | | -> **Standardized Modular Monolith for Unified Identity & Authorization.** |
9 | | -> |
10 | | ->    [](./LICENSE) |
| 7 | +- English docs portal: [README](./docs/README.md) |
| 8 | +- English lifecycle map: [Master Index](./docs/MASTER_INDEX.md) |
| 9 | +- Spanish lifecycle map: [Indice Maestro](./docs/MASTER_INDEX.es.md) |
| 10 | +- Spanish docs portal: [README en Espanol](./docs/README.es.md) |
11 | 11 |
|
12 | | ---- |
| 12 | +## Fast Routes |
13 | 13 |
|
14 | | -## License |
15 | | - |
16 | | -Dual licensed. See [LICENSE](./LICENSE) and [NOTICE](./NOTICE). |
17 | | - |
18 | | ---- |
19 | | - |
20 | | -## Standards Quick Access |
21 | | - |
22 | | -| Need | Direct path | |
23 | | -| :--- | :--- | |
24 | | -| UMS applied React Web reference | [UMS React Web Applied Reference](./docs/architecture/web-frontend/ums-react-applied-reference.md) | |
25 | | -| UMS applied .NET API reference | [UMS API .NET Applied Reference](./docs/architecture/api-dotnet/ums-api-dotnet-applied-reference.md) | |
26 | | -| Upstream Evolith React standard | [Evolith React Web Frontend Standard](https://github.com/beyondnetcode/evolith_arch32/blob/main/reference/governance/standards/engineering/web-frontend/react/react-web-frontend-standard.md) | |
27 | | -| Upstream Evolith .NET API standard | [Evolith .NET API Standard](https://github.com/beyondnetcode/evolith_arch32/blob/main/reference/governance/standards/engineering/api-dotnet/api-dotnet-standard.md) | |
28 | | -| All standards in one page | [Standards Quick Access](./docs/STANDARDS.md) | |
29 | | - |
30 | | ---- |
31 | | - |
32 | | -## Master Navigation Index |
33 | | -Start here if you are new to UMS. This index gives each reader a fast route into the repository without needing to know the folder structure. |
| 14 | +| Need | Open this | |
| 15 | +|---|---| |
| 16 | +| Standards and upstream Evolith references | [Standards Quick Access](./docs/STANDARDS.md) | |
| 17 | +| Full English documentation map | [Master Index](./docs/MASTER_INDEX.md) | |
| 18 | +| Full Spanish documentation map | [Indice Maestro](./docs/MASTER_INDEX.es.md) | |
| 19 | +| Short navigation by team or goal | [Quick Navigation](./docs/governance/quick-navigation.md) | |
| 20 | +| Architecture portal | [Architecture Portal](./docs/architecture/index.md) | |
| 21 | +| Governance portal | [Governance Portal](./docs/governance/index.md) | |
34 | 22 |
|
35 | | -### Quick Route by Persona |
| 23 | +## At a Glance |
36 | 24 |
|
37 | | -| I am a… | Start here | Then read | |
38 | | -| :--- | :--- | :--- | |
39 | | -| **Backend Engineer** | [Standards Quick Access](./docs/STANDARDS.md) · [Construction Portal](./docs/governance/construction/index.md) · [Domain Aggregate Index](./docs/domain/index.md) | [UMS API .NET Applied Reference](./docs/architecture/api-dotnet/ums-api-dotnet-applied-reference.md) → [DDD Design Portal](./docs/governance/construction/ddd-design/index.md) | |
40 | | -| **Frontend Engineer** | [Standards Quick Access](./docs/STANDARDS.md) · [UMS React Web Applied Reference](./docs/architecture/web-frontend/ums-react-applied-reference.md) | [Evolith React Web Frontend Standard](https://github.com/beyondnetcode/evolith_arch32/blob/main/reference/governance/standards/engineering/web-frontend/react/react-web-frontend-standard.md) | |
41 | | -| **Architect** | [Architecture Portal](./docs/architecture/index.md) · [ADR Registry](./docs/architecture/adrs/index.md) | [Standards Quick Access](./docs/STANDARDS.md) → [Traceability Matrix](./docs/architecture/traceability-matrix.md) | |
42 | | -| **Product Owner / QA** | [Master Index](./docs/MASTER_INDEX.md) · [Functional Stories](./docs/governance/requirements/functional-stories/index.md) | [MVP Backlog](./docs/governance/project/mvp-product-backlog.md) → [Glossary](./docs/governance/requirements/glossary.md) | |
43 | | -| **DevOps / Ops** | [Operations Portal](./docs/operations/index.md) · [Runbooks](./docs/operations/runbooks/) | [ADR-0053 OpenTelemetry](./docs/architecture/adrs/0053-opentelemetry-observability.md) → [ADR-0054 Shell Library Isolation](./docs/architecture/adrs/0054-shell-library-isolation.md) | |
| 25 | +| Area | Authoritative choice | |
| 26 | +|---|---| |
| 27 | +| Backend | .NET 10, SQL Server 2022, EF Core | |
| 28 | +| Frontend | React 18, Vite, TypeScript | |
| 29 | +| Monorepo | Nx, npm workspaces | |
| 30 | +| Delivery method | BMAD-METHOD, Clean Architecture, DDD | |
| 31 | +| Multi-tenancy | Application-layer tenant filtering first, SQL Server RLS as secondary failsafe | |
44 | 32 |
|
45 | | -### I want to… |
46 | | - |
47 | | -| Goal | Start Here | Then Read | |
48 | | -| :--- | :--- | :--- | |
49 | | -| Find standards for React, Web, C# or .NET | [Standards Quick Access](./docs/STANDARDS.md) | [Architecture Portal](./docs/architecture/index.md) | |
50 | | -| Understand the product | [Product Vision](./docs/governance/product/product-vision.md) | [Business Context](./docs/governance/product/business-context.md) → [Scope](./docs/governance/product/scope.md) | |
51 | | -| See Epics & Priorities | [MVP Product Backlog](./docs/governance/project/mvp-product-backlog.md) | [Requirements Index](./docs/governance/requirements/index.md) → [Functional Stories](./docs/governance/requirements/functional-stories/index.md) | |
52 | | -| Review functional requirements | [Requirements Index](./docs/governance/requirements/index.md) | [Functional Stories](./docs/governance/requirements/functional-stories/index.md) → [Glossary](./docs/governance/requirements/glossary.md) | |
53 | | -| Validate the data and domain model | [Conceptual Data Model](./docs/governance/requirements/conceptual-data-model.md) | [Data Model Consistency Review](./docs/architecture/blueprints/data-model-consistency-review.md) → [Database Design ER](./docs/architecture/blueprints/database-design-er.md) | |
54 | | -| Understand the architecture | [Architecture Portal](./docs/architecture/index.md) | [Architecture Overview](./docs/architecture/overview.md) → [Database Design ER](./docs/architecture/blueprints/database-design-er.md) | |
55 | | -| Browse everything | [Master Index](./docs/MASTER_INDEX.md) | Complete document tree by lifecycle phase. | |
56 | | - |
57 | | ---- |
58 | | - |
59 | | -## Architecture Overview |
60 | | - |
61 | | -### Technology Stack |
62 | | -| Layer | Technology | |
63 | | -| :--- | :--- | |
64 | | -| **Backend** | .NET 10, HotChocolate (GraphQL), Minimal APIs (REST) | |
65 | | -| **Frontend** | React 18, Vite 5, TypeScript, TailwindCSS, Zustand, TanStack Query | |
66 | | -| **Database** | SQL Server 2022, Entity Framework Core | |
67 | | -| **Monorepo** | Nx, npm Workspaces | |
68 | | -| **Methodology** | BMAD-METHOD, Clean Architecture (Hexagonal), DDD | |
69 | | - |
70 | | -### Project Structure |
71 | | -``` |
72 | | -src/ |
73 | | -├── apps/ |
74 | | -│ ├── ums.api/ # .NET Backend (Clean Architecture) |
75 | | -│ │ ├── Domain/ # Pure DDD model: Aggregate Roots, Entities, Value Objects, Domain Events; zero framework dependencies |
76 | | -│ │ ├── Application/ # Use cases, interfaces |
77 | | -│ │ ├── Infrastructure/ # EF Core, external services |
78 | | -│ │ └── Presentation/ # GraphQL/REST endpoints |
79 | | -│ └── ums.web-app/ # React Frontend (Clean Architecture) |
80 | | -│ ├── src/ |
81 | | -│ │ ├── domain/ # Client-side domain types, value objects, and UI-facing business model |
82 | | -│ │ ├── application/ # Hooks, stores, use cases |
83 | | -│ │ ├── infrastructure/ # HTTP clients, GraphQL client |
84 | | -│ │ └── presentation/ # Components, screens, layouts |
85 | | -│ └── ... |
86 | | -└── ... |
87 | | -``` |
| 33 | +## Local Workflows |
88 | 34 |
|
89 | | -### Key Architectural Decisions |
90 | | -- **GraphQL for Queries, REST for Commands**: All read operations use HotChocolate GraphQL; writes use REST Minimal APIs for transactional clarity. |
91 | | -- **Clean Architecture + DDD**: Strict layer boundaries. The Domain layer contains the pure DDD model — Aggregate Roots, Entities, Value Objects, Domain Events, and invariants — with zero framework dependencies. Application contains use cases and ports. Infrastructure handles persistence and external concerns. |
92 | | -- **Result Pattern**: No exceptions for flow control. All operations return `Result<T>` for explicit error handling. |
93 | | -- **Bounded Contexts**: Identity, Authorization, Configuration, Approvals, Compliance, IGA, Audit, Cache, and Console. Each context owns its aggregate model, contracts, and integration rules. |
94 | | - |
95 | | ---- |
96 | | - |
97 | | -## Quick Start (Engine Room) |
98 | | - |
99 | | -### Prerequisites |
100 | | -- Node.js 20+ |
101 | | -- .NET 10 SDK |
102 | | -- SQL Server 2022 (or Docker: `docker run -e "ACCEPT_EULA=Y" -e "SA_PASSWORD=YourPassword123!" -p 1433:1433 mcr.microsoft.com/mssql/server:2022-latest`) |
| 35 | +All technical commands should be run from `src/`. |
103 | 36 |
|
104 | 37 | ### Frontend |
| 38 | + |
105 | 39 | ```bash |
106 | | -cd src/apps/ums.web-app |
| 40 | +cd src |
107 | 41 | npm install |
108 | | -npm run dev |
| 42 | +npx nx run app-web:dev |
109 | 43 | ``` |
110 | 44 |
|
111 | 45 | ### Backend |
| 46 | + |
112 | 47 | ```bash |
113 | 48 | cd src/apps/ums.api |
114 | 49 | dotnet build |
115 | 50 | dotnet run |
116 | 51 | ``` |
117 | 52 |
|
118 | | -### Full Stack (Frontend + Backend) |
119 | | -```bash |
120 | | -# Terminal 1 — Backend (port 7114) |
121 | | -cd src/apps/ums.api && dotnet run |
| 53 | +### Validation and context |
122 | 54 |
|
123 | | -# Terminal 2 — Frontend (port 5173) |
124 | | -cd src/apps/ums.web-app && npm run dev |
| 55 | +```bash |
| 56 | +cd src |
| 57 | +python ../.bmad-core/scripts/validate_docs_consistency.py README.md docs/ |
125 | 58 | ``` |
126 | 59 |
|
127 | | ---- |
128 | | - |
129 | | -## Development Commands |
130 | | - |
131 | | -| Command | Description | |
132 | | -| :--- | :--- | |
133 | | -| `npm install` | Install all frontend dependencies (run from `src/apps/ums.web-app`) | |
134 | | -| `npm run dev` | Start frontend dev server (port 5173) | |
135 | | -| `npm run build` | Build frontend for production | |
136 | | -| `npm run lint` | Run ESLint | |
137 | | -| `npm run test` | Run Vitest tests | |
138 | | -| `dotnet build` | Build backend solution (run from `src/apps/ums.api`) | |
139 | | -| `dotnet test` | Run backend tests | |
140 | | -| `dotnet run` | Start backend API (port 7114) | |
141 | | - |
142 | | ---- |
143 | | - |
144 | | -## Knowledge Hub |
145 | | -| Domain | Portal Index | Contents | |
146 | | -| :--- | :--- | :--- | |
147 | | -| **Standards** | [Standards Quick Access](./docs/STANDARDS.md) | Direct links to Evolith standards and UMS applied references for React Web and .NET API. | |
148 | | -| **Governance** | [Governance Portal](./docs/governance/index.md) | Product direction, business scope, and functional requirements. | |
149 | | -| **Project Delivery** | [Project Backlog](./docs/governance/project/index.md) | MVP epics, user stories, and functional design of core modules. | |
150 | | -| **Requirements** | [Requirements Index](./docs/governance/requirements/index.md) | Functional stories, business glossary, and conceptual data model. | |
151 | | -| **Architecture** | [Architecture Portal](./docs/architecture/index.md) | Database ER design, entity maps, data-model consistency review, and interactive viewers. | |
152 | | -| **Construction** | [Construction Portal](./docs/governance/construction/index.md) | DDD domain layer design (bounded contexts, aggregates, events, commands). | |
153 | | -| **Metrics** | [Solution Metrics Dashboard](./docs/operations/metrics/index.md) | Engineering metrics by solution type: coding, security, quality, tests, AI usage. | |
154 | | - |
155 | | ---- |
156 | | - |
157 | | -## Security & Compliance |
158 | | - |
159 | | -- **Content Security Policy**: Restrictive CSP with `unsafe-eval` removed (production-ready). |
160 | | -- **CSRF Protection**: Double-submit cookie pattern with token refresh. |
161 | | -- **Security Headers**: HSTS, X-Frame-Options, X-Content-Type-Options, Referrer-Policy via Nginx. |
162 | | -- **Input Validation**: Zod schemas as single source of truth for runtime validation. |
| 60 | +## Documentation Map |
| 61 | + |
| 62 | +| Portal | Purpose | |
| 63 | +|---|---| |
| 64 | +| [Standards Quick Access](./docs/STANDARDS.md) | UMS applied references and Evolith standards | |
| 65 | +| [Master Index](./docs/MASTER_INDEX.md) | English lifecycle map of the documentation tree | |
| 66 | +| [Indice Maestro](./docs/MASTER_INDEX.es.md) | Spanish lifecycle map of the documentation tree | |
| 67 | +| [Governance Portal](./docs/governance/index.md) | Product direction, requirements, backlog, and construction | |
| 68 | +| [Architecture Portal](./docs/architecture/index.md) | Architecture, blueprints, ADRs, and traceability | |
| 69 | +| [Operations Portal](./docs/operations/index.md) | Runbooks, metrics, and operational guidance | |
| 70 | + |
| 71 | +## Governance Notes |
| 72 | + |
| 73 | +- Bilingual documentation must stay synchronized. |
| 74 | +- Markdown files must remain clean, professional, and free of decorative icons. |
| 75 | +- Architecture decisions must stay aligned with the approved ADRs and the Evolith baseline. |
| 76 | +- Root documentation should stay short and navigable. Detailed content belongs in `docs/`. |
| 77 | + |
| 78 | +## License |
| 79 | + |
| 80 | +See [LICENSE](./LICENSE) and [NOTICE](./NOTICE). |
0 commit comments