Historical task source. The Eve task board holds current task state.
Phase 3: Shared Foundation Libraries#
3.1 @oshun/types (Base Types Library) ✅#
- 3.1.1 Create libs/shared/types/ project
- 3.1.2 Add project.json with scope:shared, layer:contracts tags
- 3.1.3 Merge yemaya/packages/types (241+ types) into @oshun/types
- 3.1.4 Merge lilith/packages/core types into @oshun/types
- 3.1.5 Define branded ID types (ProjectID, UserID, AssetID, etc.)
- 3.1.6 Define Result<T> types for error handling
- 3.1.7 Define base entity interfaces (timestamps, soft delete)
- 3.1.8 Export all types with proper barrel file
- 3.1.9 Ensure zero dependencies (foundational package)
3.2 @oshun/errors (Error Handling) ✅#
- 3.2.1 Create libs/shared/errors/ project
- 3.2.2 Add project.json with scope:shared, layer:infra tags
- 3.2.3 Merge lilith/packages/errors into @oshun/errors
- 3.2.4 Merge yemaya/packages/errors into @oshun/errors
- 3.2.5 Standardize error codes across domains
- 3.2.6 Create domain-specific error subclasses
- 3.2.7 Add Sentry integration utilities
3.3 @oshun/config (Configuration Management) ✅#
- 3.3.1 Create libs/shared/config/ project
- 3.3.2 Add project.json with scope:shared, layer:infra tags
- 3.3.3 Merge lilith/packages/config into @oshun/config
- 3.3.4 Merge yemaya/packages/core config utilities
- 3.3.5 Create environment validation with Zod
- 3.3.6 Support .env, environment variables, and config files
- 3.3.7 Create config schemas for each domain
3.4 @oshun/logging (Structured Logging) ✅#
- 3.4.1 Create libs/shared/logging/ project
- 3.4.2 Add project.json with scope:shared, layer:infra tags
- 3.4.3 Merge lilith/packages/logger into @oshun/logging
- 3.4.4 Merge yemaya/packages/logging into @oshun/logging
- 3.4.5 Standardize on Pino logger
- 3.4.6 Add OpenTelemetry integration
- 3.4.7 Create log level configuration
- 3.4.8 Add structured log context utilities
3.5 @oshun/tracing (Distributed Tracing) ✅#
- 3.5.1 Create libs/shared/tracing/ project
- 3.5.2 Add project.json with scope:shared, layer:infra tags
- 3.5.3 Merge lilith/packages/tracing into @oshun/tracing
- 3.5.4 Add OpenTelemetry SDK setup
- 3.5.5 Create span utilities and decorators
- 3.5.6 Add trace context propagation helpers
3.6 @oshun/metrics (Metrics Collection) ✅#
- 3.6.1 Create libs/shared/metrics/ project
- 3.6.2 Add project.json with scope:shared, layer:infra tags
- 3.6.3 Merge lilith/packages/metrics into @oshun/metrics
- 3.6.4 Add Prometheus client utilities
- 3.6.5 Create metric registration helpers
- 3.6.6 Add histogram/counter/gauge factories
3.7 @oshun/cache (Caching Utilities) ✅#
- 3.7.1 Create libs/shared/cache/ project
- 3.7.2 Add project.json with scope:shared, layer:infra tags
- 3.7.3 Merge lilith/packages/cache into @oshun/cache
- 3.7.4 Add Redis client with Sentinel/Cluster support
- 3.7.5 Create cache key builders and TTL utilities
- 3.7.6 Add cache invalidation patterns
3.8 @oshun/queue (Job Queue) ✅#
- 3.8.1 Create libs/shared/queue/ project
- 3.8.2 Add project.json with scope:shared, layer:infra tags
- 3.8.3 Merge lilith/packages/queue into @oshun/queue
- 3.8.4 Standardize on BullMQ
- 3.8.5 Create job envelope types
- 3.8.6 Add retry policies and dead letter queue support
- 3.8.7 Create worker base classes
3.9 @oshun/database (Database Utilities) ✅#
- 3.9.1 Create libs/shared/database/ project
- 3.9.2 Add project.json with scope:shared, layer:data tags
- 3.9.3 Merge lilith/packages/database utilities
- 3.9.4 Merge yemaya/packages/database utilities (NOT schema)
- 3.9.5 Create connection pooling utilities (PgBouncer)
- 3.9.6 Add migration runner helpers
- 3.9.7 Create transaction utilities
- 3.9.8 Add health check utilities
3.10 @oshun/testing (Test Utilities) ✅#
- 3.10.1 Create libs/shared/testing/ project
- 3.10.2 Add project.json with scope:shared, layer:infra tags
- 3.10.3 Merge lilith/packages/testing into @oshun/testing
- 3.10.4 Create mock factories for common types
- 3.10.5 Add test database utilities
- 3.10.6 Create API test helpers
- 3.10.7 Add snapshot testing utilities
3.11 @oshun/http-client (HTTP Client Helpers) ✅#
- 3.11.1 Create libs/shared/http-client/ project
- 3.11.2 Add project.json with scope:shared, layer:infra tags
- 3.11.3 Extract HTTP client utilities from both codebases
- 3.11.4 Add circuit breaker pattern
- 3.11.5 Add retry with exponential backoff
- 3.11.6 Add request/response logging interceptors
3.12 @oshun/auth-primitives (Auth Helpers) ✅#
- 3.12.1 Create libs/shared/auth-primitives/ project
- 3.12.2 Add project.json with scope:shared, layer:infra tags
- 3.12.3 Create JwtService with sign/verify/decode using jose library
- 3.12.4 Create SessionManager with InMemorySessionStore
- 3.12.5 Create TokenRefreshManager with rotation and family tracking
- 3.12.6 Add PasswordHasher (PBKDF2) and PasswordValidator
- 3.12.7 Add ApiKeyManager with create/validate/revoke
- 3.12.8 Add comprehensive test suite (34 tests)
3.13 @oshun/storage (Object Storage) ✅#
- 3.13.1 Create libs/shared/storage/ project
- 3.13.2 Add project.json with scope:shared, layer:infra tags
- 3.13.3 Create S3StorageClient for AWS S3 and MinIO
- 3.13.4 Create LocalStorageClient for development/testing
- 3.13.5 Create file manifest types and utilities
- 3.13.6 Add signed URL generators (download, upload, POST policy)
- 3.13.7 Create multipart upload support
- 3.13.8 Add utility functions (MIME types, file keys, checksums)
- 3.13.9 Add comprehensive test suite (43 tests)
3.14 @oshun/health (Health Checks) ✅#
- 3.14.1 Create libs/shared/health/ project
- 3.14.2 Add project.json with scope:shared, layer:infra tags
- 3.14.3 Create HealthManager with check registration and caching
- 3.14.4 Create ProbeManager for Kubernetes liveness/readiness/startup probes
- 3.14.5 Create DependencyAggregator for tracking external dependency health
- 3.14.6 Add helper functions (healthy, degraded, unhealthy, createDatabaseCheck, etc.)
- 3.14.7 Add comprehensive test suite (25 tests)