allframe 0.1.28

Complete Rust web framework with built-in HTTP/2 server, REST/GraphQL/gRPC, compile-time DI, CQRS - TDD from day zero
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
# AllFrame Project Status

**Last Updated**: 2026-03-17
**Version**: 0.1.18
**Status**: Active Development

> **Vision**: AllFrame is evolving from a composable Rust API framework into a **cloud-native microservice architecture generator**. See [ROADMAP.md]./current/ROADMAP.md and [IGNITE_VISION.md]./current/IGNITE_VISION.md for the full vision.

---

## Quick Status

| Category | Status | Progress |
|----------|--------|----------|
| **Offline-First** | ✅ Complete | SQLite, offline resilience, sync, Tauri (100%) |
| **Authentication** | ✅ Complete | Layered auth (JWT, Axum, gRPC) (100%) |
| **Graceful Shutdown** | ✅ Complete | ShutdownAwareTaskSpawner, GracefulShutdownExt (100%) |
| **Resilience Patterns** | ✅ Complete | Retry, CircuitBreaker, RateLimiter, Redis (100%) |
| **Security Utilities** | ✅ Complete | Obfuscation, Safe Logging (100%) |
| **GraphQL Documentation** | ✅ Complete | Phase 6.3 complete (100%) |
| **Scalar API Documentation** | ✅ Complete | Track A complete (100%) |
| **Binary Size Monitoring** | ✅ Complete | Track B complete (100%) |
| **CQRS Infrastructure** | ✅ Complete | 5/5 phases (100%) |
| **Router Core** | ✅ Complete | Phase 6.1 complete (100%) |
| **Dependency Injection** | ✅ Complete | Production-ready |
| **OpenTelemetry** | ✅ Complete | Tracing support |
| **CI/CD** | ✅ Complete | All workflows passing |

---

## Completed Work (Phases 1-5)

### Phase 1: AllSource Integration ✅
**Status**: Complete (2025-11-23)
**Achievement**: Pluggable event store backend architecture

**Deliverables**:
- `EventStoreBackend` trait for custom backends
- `InMemoryBackend` for testing/MVP
- `AllSourceBackend` for production (embedded DB)
- Backend statistics and monitoring
- Snapshot support for optimization

**Impact**: Production-ready storage with zero code changes to switch backends

**Documentation**: [docs/phases/PHASE1_COMPLETE.md](./phases/PHASE1_COMPLETE.md)

---

### Phase 2: CommandBus ✅
**Status**: Complete (2025-11-24)
**Achievement**: 90% boilerplate reduction for command handling

**Deliverables**:
- `CommandBus<E>` for type-safe command dispatch
- `CommandHandler` trait for command processing
- Automatic validation and error handling
- Handler registry with type-safe lookup
- 90% less code vs manual implementation

**Before**: 30-40 lines per command
**After**: 3 lines per command
**Reduction**: 90%

**Documentation**: [docs/phases/PHASE2_COMPLETE.md](./phases/PHASE2_COMPLETE.md)

---

### Phase 3: ProjectionRegistry ✅
**Status**: Complete (2025-11-25)
**Achievement**: 90% boilerplate reduction for projections

**Deliverables**:
- `ProjectionRegistry<E, B>` for automatic projection lifecycle
- Automatic event subscription and updates
- Projection rebuild functionality
- Consistency tracking via `ProjectionPosition`
- Metadata and monitoring support

**Before**: 50+ lines per projection
**After**: 5 lines per projection
**Reduction**: 90%

**Documentation**: [docs/phases/PHASE3_COMPLETE.md](./phases/PHASE3_COMPLETE.md)

---

### Phase 4: Event Versioning ✅
**Status**: Complete (2025-11-25)
**Achievement**: 95% boilerplate reduction for event schema evolution

**Deliverables**:
- `VersionRegistry<E>` for centralized version management
- `AutoUpcaster` using Rust's `From` trait
- Migration path tracking
- Type-erased upcaster storage
- Zero manual version checking

**Before**: 30-40 lines per event type for version management
**After**: 5 lines per event type
**Reduction**: 95%

**Documentation**: [docs/phases/PHASE4_COMPLETE.md](./phases/PHASE4_COMPLETE.md)

---

### Phase 5: Saga Orchestration ✅
**Status**: Complete (2025-11-26)
**Achievement**: 75% boilerplate reduction for distributed transactions

**Deliverables**:
- `SagaOrchestrator<E>` for saga execution
- `SagaStep` trait for defining saga steps
- `SagaDefinition` builder for composing sagas
- Automatic reverse-order compensation
- Per-step timeout management
- Saga execution history and tracking

**Before**: 100+ lines per saga
**After**: 20 lines per saga
**Reduction**: 75%

**Documentation**: [docs/phases/PHASE5_COMPLETE.md](./phases/PHASE5_COMPLETE.md)

---

### Track A: Scalar Integration ✅
**Status**: Complete (2025-12-01)
**Achievement**: Beautiful API documentation 10x smaller than Swagger UI

**Deliverables**:
- `OpenApiServer` struct for server configuration
- `OpenApiGenerator::with_server()` for "Try It" functionality
- `ScalarConfig` for comprehensive UI customization
- `scalar_html()` for generating documentation HTML
- CDN version pinning for stability
- SRI hashes for security
- CORS proxy support for browser compatibility
- Custom theming and CSS injection

**Features**:
- <50KB bundle size (vs 500KB for Swagger UI)
- Dark mode by default
- Interactive "Try It" button for all endpoints
- Mobile-friendly responsive design
- Framework-agnostic (works with any Rust web framework)

**Testing**:
- 42 tests (25 Scalar + 17 OpenAPI)
- 100% passing
- Comprehensive feature coverage

**Documentation**:
- [Scalar Integration Complete]./phases/SCALAR_INTEGRATION_COMPLETE.md
- [Scalar Documentation Guide]./guides/SCALAR_DOCUMENTATION.md (500+ lines)
- [Examples Updated]./phases/EXAMPLES_UPDATED.md
- [scalar_docs.rs example]../crates/allframe-core/examples/scalar_docs.rs

**Impact**: Best-in-class API documentation experience for Rust ecosystem

---

### Track B: Binary Size Monitoring ✅
**Status**: Complete (2025-12-01)
**Achievement**: All binaries under 2MB (exceeded 2-8MB targets)

**Deliverables**:
- GitHub Actions CI/CD workflow for automated size tracking
- Local development scripts (`scripts/check_size.sh`)
- cargo-make integration (`cargo make check-size`)
- Hard limit enforcement (CI fails on exceeding targets)
- cargo-bloat analysis for optimization

**Results**:
- Minimal config: 1.89MB (target: <2MB) - **95% headroom**
- Default features: 1.89MB (target: <5MB) - **62% smaller**
- All features: 1.89MB (target: <8MB) - **76% smaller**

**Testing**:
- 3 build configurations tested
- Automated on every PR
- Local verification available

**Documentation**:
- [Binary Size Monitoring Complete]./phases/BINARY_SIZE_MONITORING_COMPLETE.md

**Impact**: Zero-cost abstractions proven effective, binaries exceed all size targets

---

### Phase 6.3: GraphQL Documentation (GraphiQL) ✅
**Status**: Complete (2025-12-01)
**Achievement**: Interactive GraphQL playground with schema explorer

**Deliverables**:
- `GraphiQLConfig` struct with builder pattern
- `GraphiQLTheme` enum (Light/Dark)
- `graphiql_html()` function for playground generation
- WebSocket subscription support
- Schema explorer sidebar
- Query history persistence
- Custom header configuration
- Custom CSS injection

**Features**:
- <100KB bundle size (GraphiQL 3.0)
- Modern alternative to deprecated GraphQL Playground
- Interactive schema documentation
- Variables editor with JSON validation
- Multiple theme support
- Framework-agnostic (works with any Rust web framework)

**Testing**:
- 7 tests (100% passing)
- Comprehensive configuration tests
- HTML generation validation
- Subscription URL handling
- Theme serialization tests

**Documentation**:
- [GraphQL Documentation Guide]./guides/GRAPHQL_DOCUMENTATION.md (600+ lines)
- [graphql_docs.rs example]../crates/allframe-core/examples/graphql_docs.rs (220+ lines)
- Complete framework integration examples (Axum, Actix, Rocket)

**Impact**: Best-in-class GraphQL documentation for Rust ecosystem, on par with industry standards

---

### Resilience & Security Module ✅
**Status**: Complete (2025-12-08)
**Achievement**: Production-ready resilience patterns and safe logging utilities (~1,000+ lines)

**Resilience Module (`resilience` feature)**:
- `RetryExecutor` - Async retry with exponential backoff and jitter
- `RetryConfig` - Configurable retry behavior (max_retries, intervals, randomization)
- `RetryPolicy` trait - Custom retry decision logic
- `RetryBudget` - System-wide retry token management to prevent retry storms
- `AdaptiveRetry` - Adjusts retry behavior based on success/failure rates
- `RateLimiter` - Token bucket rate limiting with burst support
- `AdaptiveRateLimiter` - Backs off when receiving external 429 responses
- `KeyedRateLimiter<K>` - Per-key rate limiting (per-endpoint, per-user)
- `CircuitBreaker` - Fail-fast pattern with Closed/Open/HalfOpen states
- `CircuitBreakerConfig` - Configurable thresholds and timeouts
- `CircuitBreakerManager` - Manages multiple circuit breakers by name

**Security Module (`security` feature)**:
- `obfuscate_url()` - Strips credentials, path, and query from URLs
- `obfuscate_redis_url()` - Preserves host/port, hides auth
- `obfuscate_api_key()` - Shows prefix/suffix only (e.g., "sk_l***mnop")
- `obfuscate_header()` - Smart header obfuscation (Authorization, Cookie, etc.)
- `Obfuscate` trait - Custom obfuscation for user types
- `Sensitive<T>` wrapper - Debug/Display always shows "***"

**Procedural Macros (allframe-macros)**:
- `#[derive(Obfuscate)]` - Auto-generate safe logging with `#[sensitive]` field attribute
- `#[retry(max_retries = 3)]` - Wrap async functions with exponential backoff
- `#[circuit_breaker(failure_threshold = 5)]` - Fail-fast pattern for functions
- `#[rate_limited(rps = 100, burst = 10)]` - Token bucket rate limiting

**New Feature Flags**:
- `resilience` - Full resilience module (retry, circuit breaker, rate limiting)
- `security` - URL/credential obfuscation utilities
- `router-grpc-tls` - TLS/mTLS support for gRPC
- `http-client` - Re-exports reqwest for HTTP client functionality
- `otel-otlp` - Full OpenTelemetry stack with OTLP exporter
- `metrics` - Prometheus metrics support
- `cache-memory` - In-memory caching with moka and dashmap
- `cache-redis` - Redis client for distributed caching
- `utils` - Common utilities bundle (chrono, url, parking_lot, rand)

**Testing**:
- 299 tests (allframe-core) + 15 tests (allframe-macros)
- 100% passing
- Comprehensive examples (`resilience.rs`, `security.rs`)

**Documentation**:
- [Feature Flags Guide]./guides/FEATURE_FLAGS.md - Updated with all new features
- [Changelog]../CHANGELOG.md - Full release notes for 0.1.7

**Impact**: Replaces ~1,112 lines of kraken-gateway code with modular, well-tested AllFrame features

---

### Graceful Shutdown Utilities ✅
**Status**: Complete (2025-12-09)
**Achievement**: Production-ready shutdown utilities for service orchestration

**Deliverables**:
- `ShutdownAwareTaskSpawner` - Named tasks with automatic cancellation on shutdown
- `spawn()` - Spawn tasks that respond to shutdown signals
- `spawn_background()` - Background tasks (non-blocking)
- `spawn_with_result()` - Tasks that return values (returns `None` if cancelled)
- `GracefulShutdownExt` trait - Cleanup orchestration with error handling
- `perform_shutdown()` - Run cleanup logic with automatic error logging
- `ShutdownExt` trait - Make any future cancellable with `with_shutdown()`

**Testing**:
- 17 tests (100% passing)
- Task lifecycle, cancellation, cleanup error handling
- Multiple workers with shared spawner

**Examples**:
- `graceful_shutdown.rs` - Full application example with DB pool, message consumer, metrics
- `shutdown_patterns.rs` - 5 common patterns (basic spawning, results, cleanup, ext, workers)

**Impact**: Production-ready shutdown handling for microservices with zero boilerplate

---

### Layered Authentication ✅
**Status**: Complete (2025-12-14)
**Achievement**: Zero-bloat, feature-gated auth infrastructure

**Feature Flags**:
| Feature | Dependencies | Description |
|---------|--------------|-------------|
| `auth` | None | Core traits only (`Authenticator`, `AuthContext`, `AuthError`) |
| `auth-jwt` | jsonwebtoken | JWT validation (HS256/RS256/EdDSA) |
| `auth-axum` | tower, hyper | Axum extractors (`AuthenticatedUser<C>`, `AuthLayer`) |
| `auth-tonic` | tonic | gRPC interceptors (`AuthInterceptor`) |

**Deliverables**:
- `Authenticator` trait - Protocol-agnostic token validation
- `JwtValidator<C>` - Type-safe JWT claims extraction
- `JwtConfig` - Builder pattern with `from_env()` support
- `AuthenticatedUser<C>` - Axum extractor for handlers
- `AuthLayer` - Tower middleware for route protection
- `AuthInterceptor` - gRPC interceptor with required/optional modes
- `AuthContext<C>` - Unified auth state across protocols

**Testing**:
- 24 auth tests (100% passing)
- JWT validation, expiration, signature verification
- Protocol-specific extractor tests

**Impact**: Same auth logic works across REST, GraphQL, and gRPC with zero code duplication

---

### Enhanced Resilience ✅
**Status**: Complete (2025-12-14)
**Achievement**: Keyed circuit breakers and distributed rate limiting

**New Features**:
- `KeyedCircuitBreaker<K>` - Per-resource circuit breaker isolation
  - Independent state per key (e.g., per exchange, per endpoint)
  - Failures in one resource don't affect others
  - Same API as `KeyedRateLimiter<K>` for consistency
- `resilience-redis` feature - Redis-backed distributed rate limiting
  - `RedisRateLimiter` with sliding window algorithm
  - `KeyedRedisRateLimiter` with per-key configuration
  - Atomic operations via Lua scripts
  - Works across multiple instances

**Testing**:
- 10 KeyedCircuitBreaker tests
- Redis integration tests (requires Redis)

**Impact**: Production-ready resilience for distributed microservices

---

## CQRS Infrastructure Summary

**Total Achievement**: 85% average boilerplate reduction

| Phase | Feature | Reduction | Lines Before | Lines After |
|-------|---------|-----------|--------------|-------------|
| 2 | CommandBus | 90% | 30-40 | 3-5 |
| 3 | ProjectionRegistry | 90% | 50+ | 5 |
| 4 | Event Versioning | 95% | 30-40 | 5 |
| 5 | Saga Orchestration | 75% | 100+ | 20 |
| **Average** | **All Features** | **85%** | **~220** | **~33** |

**Test Coverage**:
- 72 tests across all CQRS infrastructure
- 100% passing
- Property-based tests for key components
- Integration tests for full CQRS flow

**Code Quality**:
- Zero breaking changes across all phases
- 100% TDD from day one
- ~1,500 lines of framework code
- Full documentation for all features

**Announcement**: [docs/announcements/CQRS_INFRASTRUCTURE_COMPLETE.md](./announcements/CQRS_INFRASTRUCTURE_COMPLETE.md)

---

## Active Work

### Compiler Warning Cleanup ✅
**Status**: Complete (2025-11-27)
**Achievement**: Zero unexpected warnings, all exceptions documented

**Work Completed**:
- ✅ Fixed 15+ "field never read" warnings by adding proper assertions
- ✅ Fixed irrefutable pattern warnings
- ✅ Removed unused imports
- ✅ Added comprehensive `#[allow(dead_code)]` documentation to all test files
- ✅ Documented all 45 intentional exceptions with clear explanations
- ✅ Created AllSource-Core dependency issue tracker

**Documentation**:
- [Milestone: Warning Cleanup Complete]./milestones/WARNING_CLEANUP_COMPLETE.md
- [AllSource-Core Issues]./current/ALLSOURCE_CORE_ISSUES.md

**Impact**:
- Production-ready codebase with documented quality standards
- Clear best practices for test assertions
- External dependency issues tracked with workarounds

---

### CI/CD Fixes ✅
**Status**: Complete (2025-11-26)

**Issues Fixed**:
1. `-Z minimal-versions` now runs on nightly (was failing on stable)
2. ✅ MSRV updated to 1.80 (required for edition2024 dependencies)
3. ✅ Documented prost version conflict (allsource-core uses 0.13, we use 0.14)

**Changes Made**:
- Updated `.github/workflows/compatibility-matrix.yml`
- Updated workspace `rust-version` to 1.80
- Added toolchain selection for minimal-versions test
- Improved dependency version testing

**Remaining**:
- prost version conflict needs allsource-core update (external dependency)
- AllSource backend blocked by upstream compilation errors (see [ALLSOURCE_CORE_ISSUES.md]./current/ALLSOURCE_CORE_ISSUES.md)
- Monitoring for upstream dependency changes

---

## Active Phase

### Phase 6.1: Router Core Enhancement ✅
**Status**: COMPLETE (2025-11-27)
**Achievement**: Type-safe routing + OpenAPI 3.1 + JSON Schema generation

**Deliverables Completed**:
- ✅ Route metadata extraction (`RouteMetadata`)
- ✅ Type-safe route registration (`router.get()`, `router.post()`, etc.)
- ✅ JSON Schema generation (`ToJsonSchema` trait)
- ✅ OpenAPI 3.1 spec generation (`Router::to_openapi()`)
- ✅ Route builder API (`RouteBuilder`)
- ✅ Documentation serving (`DocsConfig`, `openapi_json()`, `docs_html()`)

**Metrics**:
- Tests added: 60 (39 → 99 total)
- Files created: 6 router modules (~835 lines)
- Breaking changes: 0
- Test coverage: 100%
- Performance: <1μs per route (exceeded <10μs target)

**Documentation**: [Phase 6.1 Complete](./phases/PHASE6_1_COMPLETE.md)

---

## Next Phase

### Phase 6.2: REST + Scalar Integration ✅
**Status**: COMPLETE (2025-12-01)
**Achievement**: Beautiful API documentation with Scalar UI

**Completed**:
- ✅ Scalar UI Integration (<50KB bundle)
- ✅ Interactive "Try It" functionality
- ✅ Server configuration for multi-environment support
- ✅ CDN version pinning + SRI hashes
- ✅ CORS proxy support
- ✅ Custom theming and CSS
- ✅ Comprehensive documentation (500+ lines)
- ✅ Working examples (175 lines)
- ✅ 42 tests (100% passing)

**Timeline**: Completed 40% faster than planned (Days 3-10 of dual-track)

**Documentation**:
- [Scalar Integration Complete]./phases/SCALAR_INTEGRATION_COMPLETE.md
- [Scalar Documentation Guide]./guides/SCALAR_DOCUMENTATION.md
- [Examples Updated]./phases/EXAMPLES_UPDATED.md

### Upcoming Phases

**Phase 6.4: gRPC Documentation** 📋
- gRPC reflection UI
- Service exploration
- Interactive request testing
- Timeline: 2 weeks

**Phase 6.5: Contract Testing** 📋
- Built-in contract test generation
- API versioning support
- Breaking change detection
- Timeline: 2 weeks

---

### Quality Metrics & Performance 📝
**Status**: PRD Complete, Ready for Implementation
**Priority**: P0 (Critical for 1.0)

**Goal**: Comprehensive quality monitoring, performance testing, and demo scenarios

**Key Deliverables**:
1. **Binary Size Monitoring** - < 8 MB target, CI/CD enforcement
2. **Demo Scenarios** - 5 comprehensive real-world examples
3. **Performance Testing** - TechEmpower benchmarks, > 500k req/s
4. **Automated Monitoring** - CI/CD checks for all metrics

**Timeline**: 9 weeks (4 phases)
- Phase 1: Binary Size Monitoring (1 week)
- Phase 2: Demo Scenarios (5 weeks)
- Phase 3: Performance Testing (2 weeks)
- Phase 4: Integration & Documentation (1 week)

**PRD**: [docs/current/PRD_QUALITY_METRICS.md](./current/PRD_QUALITY_METRICS.md)

**Why This Matters**:
- Swagger UI is outdated (2015), heavy (100KB+), slow
- Scalar is modern (2023), light (<50KB), fast
- GraphQL needs better auto-documentation
- gRPC has NO standard web documentation solution
- Contract testing is manual and error-prone

**Competitive Advantage**:
- **Zero configuration** - Docs generated automatically from code
- **Best-in-class UIs** - Scalar for REST, GraphiQL for GraphQL
- **First-class gRPC** - No other framework has web-based gRPC docs
- **Built-in contract testing** - No other framework has this

---

## Technical Debt

### Known Issues

1. **prost Version Conflict**
   - allsource-core (external) uses prost 0.13
   - allframe-core uses prost 0.14
   - **Status**: Documented, not blocking
   - **Action**: Monitor upstream, coordinate update

2. **Feature Flag Tests**
   - Some feature flag combinations not fully tested
   - **Status**: Low priority
   - **Action**: Add feature matrix tests (Phase 6)

3. **MSRV Testing**
   - MSRV updated from 1.75 to 1.80
   - **Status**: Documented
   - **Action**: Monitor ecosystem for MSRV changes

### Technical Improvements Needed

1. **Performance Benchmarks**
   - Need comprehensive benchmarks for all CQRS operations
   - **Priority**: P1
   - **Target**: Phase 6.1

2. **Documentation Examples**
   - Need more real-world examples in phase docs
   - **Priority**: P2
   - **Target**: Ongoing

3. **Error Messages**
   - Improve error messages for common mistakes
   - **Priority**: P2
   - **Target**: Phase 6

---

## Repository Statistics

### Code

| Component | Files | Lines | Tests |
|-----------|-------|-------|-------|
| allframe-core | ~55 | ~8,500 | 308 |
| allframe-macros | ~12 | ~2,000 | 15 |
| allframe-forge | ~5 | ~500 | 5 |
| allframe-mcp | ~10 | ~1,500 | 37 |
| Integration tests | ~20 | ~4,000 | 90 |
| **Total** | **~102** | **~16,500** | **455** |

**Phase Breakdown**:
- CQRS (Phases 1-5): 39 tests
- Router Core (Phase 6.1): 60 tests
- GraphQL Docs (Phase 6.3): 7 tests
- Resilience Module: 43 tests
- Security Module: 12 tests
- Graceful Shutdown: 17 tests
- Other: 183 tests

### Documentation

| Type | Count | Location |
|------|-------|----------|
| Phase docs | 5 | docs/phases/ |
| Announcements | 3 | docs/announcements/ |
| Guides | 4 | docs/guides/ |
| PRDs | 2 | docs/current/ |
| Milestones | 6 | docs/milestones/ |
| Archive | 6 | docs/archive/ |
| **Total** | **26** | **docs/** |

---

## Development Workflow

### Current Standards

**TDD Mandatory**:
- RED: Write failing test first
- GREEN: Minimal implementation to pass
- REFACTOR: Clean up while maintaining tests
- 100% TDD, no exceptions

**Code Quality**:
- `cargo clippy` must pass (zero warnings)
- `cargo fmt` enforced
- All tests must pass
- Documentation required for public APIs

**Git Workflow**:
- Feature branches from `main`
- PR required for merge
- CI/CD must pass
- Code review required

---

## Roadmap

> **See [ROADMAP.md]./current/ROADMAP.md for the complete vision and detailed phase planning.**

AllFrame is evolving from a composable Rust API framework into a **cloud-native microservice architecture generator**. The full roadmap includes:

### Current (v0.1.x) - Foundation ✅
- ✅ CQRS Infrastructure (Phases 1-5)
- ✅ Protocol-Agnostic Routing (Phase 6)
- ✅ API Documentation (Scalar, GraphiQL, gRPC Explorer)
- ✅ Resilience & Security Patterns
- ✅ Graceful Shutdown Utilities

### Near-Term (v0.2.0 - v0.4.0) - Architecture Configuration
- Phase 7: Architecture Configuration Schema (TOML/YAML)
- Phase 8: Core Service Archetypes (stateless, event-sourced, consumer, producer)
- Phase 9: Advanced Service Patterns (saga-orchestrator, gateway, bff, websocket-gateway)

### Mid-Term (v0.5.0 - v0.7.0) - Multi-Cloud IaC
- Phase 10: AWS Infrastructure (Lambda, Fargate, MSK, Terraform)
- Phase 11: Multi-Cloud Support (GCP, Fly.io, Shuttle)
- Phase 12: Architecture Templates (e-commerce, data-pipeline, saas)

### Long-Term (v0.8.0 - v1.0.0) - Production Readiness
- Phase 13: Testing & Quality (Pact contracts, k6 load testing, chaos engineering)
- Phase 14: Production Readiness (security audit, mTLS, feature flags, multi-tenancy)

**Vision**: Generate deployable microservice architectures in < 5 minutes from declarative configuration.

For detailed configuration examples and service archetypes, see **[IGNITE_VISION.md](./current/IGNITE_VISION.md)**.

---

## Key Decisions

### Architectural Decisions

1. **Backend Abstraction** (Phase 1)
   - **Decision**: Pluggable backend via trait
   - **Why**: Support in-memory (testing) and AllSource (production)
   - **Trade-off**: Slight API complexity for flexibility

2. **Type Erasure** (Phases 3, 4, 5)
   - **Decision**: Use `Box<dyn Trait>` for heterogeneous collections
   - **Why**: Store different types in single registry
   - **Trade-off**: Heap allocation for flexibility

3. **Zero Config** (All phases)
   - **Decision**: Automatic everything, zero configuration required
   - **Why**: Best developer experience
   - **Trade-off**: Magic behavior, less explicit control

4. **Scalar over Swagger** (Phase 6)
   - **Decision**: Use Scalar for REST documentation
   - **Why**: Modern, lighter, better UX
   - **Trade-off**: Less mature than Swagger UI

5. **GraphiQL over Playground** (Phase 6)
   - **Decision**: Use GraphiQL, not GraphQL Playground
   - **Why**: Playground is deprecated, GraphiQL is industry standard
   - **Trade-off**: Less features than Playground

### Technology Choices

| Technology | Purpose | Why Chosen |
|------------|---------|------------|
| Tokio | Async runtime | Industry standard, mature |
| Hyper | HTTP server | Low-level, performant |
| async-graphql | GraphQL | Best Rust GraphQL library |
| tonic | gRPC | Official gRPC for Rust |
| Scalar | REST docs | Modern, lightweight, beautiful |
| GraphiQL | GraphQL docs | Industry standard |
| AllSource | Event store | Embedded DB, no external deps |

---

## Team & Contributors

**Core Team**:
- Engineering Lead: TBD
- Product Owner: TBD
- Contributors: Open to community

**Community**:
- GitHub: https://github.com/all-source-os/all-frame
- Discussions: https://github.com/all-source-os/all-frame/discussions
- Issues: https://github.com/all-source-os/all-frame/issues

---

## Resources

### Documentation
- [Main README]../README.md
- [Documentation Index]./INDEX.md
- [PRD 01]./current/PRD_01.md - Original product requirements
- [PRD Router/Docs]./current/PRD_ROUTER_DOCS.md - Router + documentation system

### CQRS Infrastructure
- [Phase 1: AllSource]./phases/PHASE1_COMPLETE.md
- [Phase 2: CommandBus]./phases/PHASE2_COMPLETE.md
- [Phase 3: ProjectionRegistry]./phases/PHASE3_COMPLETE.md
- [Phase 4: Event Versioning]./phases/PHASE4_COMPLETE.md
- [Phase 5: Saga Orchestration]./phases/PHASE5_COMPLETE.md

### Announcements
- [CQRS Infrastructure Complete]./announcements/CQRS_INFRASTRUCTURE_COMPLETE.md

---

## Contact

For questions, feedback, or contributions:
- **Issues**: https://github.com/all-source-os/all-frame/issues
- **Discussions**: https://github.com/all-source-os/all-frame/discussions
- **Email**: contact@allframe.rs (TBD)

---

**AllFrame. One frame. Infinite transformations.**
*Built with TDD, from day zero.* 🦀