feat: Implement v1.1.1 Phase 1 - Core Infrastructure
Phase 1 of v1.1.1 "Polish" release focusing on production readiness. Implements logging, connection pooling, validation, and error handling. Following specs in docs/design/v1.1.1/developer-qa.md and ADRs 052-055. **Structured Logging** (Q3, ADR-054) - RotatingFileHandler (10MB files, keep 10) - Correlation IDs for request tracing - All print statements replaced with logging - Context-aware correlation IDs (init/request) - Logs written to data/logs/starpunk.log **Database Connection Pooling** (Q2, ADR-053) - Connection pool with configurable size (default: 5) - Request-scoped connections via Flask g object - Pool statistics for monitoring - WAL mode enabled for concurrency - Backward compatible get_db() signature **Configuration Validation** (Q14, ADR-052) - Validates presence and type of all config values - Fail-fast startup with clear error messages - LOG_LEVEL enum validation - Type checking for strings, integers, paths - Non-zero exit status on errors **Centralized Error Handling** (Q4, ADR-055) - Moved handlers to starpunk/errors.py - Micropub spec-compliant JSON errors - HTML templates for browser requests - All errors logged with correlation IDs - MicropubError exception class **Database Module Reorganization** - Moved database.py to database/ package - Separated init.py, pool.py, schema.py - Maintains backward compatibility - Cleaner separation of concerns **Testing** - 580 tests passing - 1 pre-existing flaky test noted - No breaking changes to public API **Documentation** - CHANGELOG.md updated with v1.1.1 entry - Version bumped to 1.1.1 - Implementation report in docs/reports/ 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
46
CHANGELOG.md
46
CHANGELOG.md
@@ -7,6 +7,52 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
||||
|
||||
## [Unreleased]
|
||||
|
||||
## [1.1.1] - 2025-11-25
|
||||
|
||||
### Added
|
||||
- **Structured Logging** - Enhanced logging system for production readiness
|
||||
- RotatingFileHandler with 10MB files, keeping 10 backups
|
||||
- Correlation IDs for request tracing across the entire request lifecycle
|
||||
- Separate log files in `data/logs/starpunk.log`
|
||||
- All print statements replaced with proper logging
|
||||
- See ADR-054 for architecture details
|
||||
|
||||
- **Database Connection Pooling** - Improved database performance
|
||||
- Connection pool with configurable size (default: 5 connections)
|
||||
- Request-scoped connections via Flask's g object
|
||||
- Pool statistics available for monitoring via `/admin/metrics`
|
||||
- Transparent to calling code (maintains same interface)
|
||||
- See ADR-053 for implementation details
|
||||
|
||||
- **Enhanced Configuration Validation** - Fail-fast startup validation
|
||||
- Validates both presence and type of all required configuration values
|
||||
- Clear, detailed error messages with specific fixes
|
||||
- Validates LOG_LEVEL against allowed values
|
||||
- Type checking for strings, integers, and Path objects
|
||||
- Non-zero exit status on configuration errors
|
||||
- See ADR-052 for configuration strategy
|
||||
|
||||
### Changed
|
||||
- **Centralized Error Handling** - Consistent error responses
|
||||
- Moved error handlers from inline decorators to `starpunk/errors.py`
|
||||
- Micropub endpoints return spec-compliant JSON errors
|
||||
- HTML error pages for browser requests
|
||||
- All errors logged with correlation IDs
|
||||
- MicropubError exception class for spec compliance
|
||||
- See ADR-055 for error handling strategy
|
||||
|
||||
- **Database Module Reorganization** - Better structure
|
||||
- Moved from single `database.py` to `database/` package
|
||||
- Separated concerns: `init.py`, `pool.py`, `schema.py`
|
||||
- Maintains backward compatibility with existing imports
|
||||
- Cleaner separation of initialization and connection management
|
||||
|
||||
### Technical Details
|
||||
- Phase 1 of v1.1.1 "Polish" release
|
||||
- Core infrastructure improvements for production readiness
|
||||
- 580 tests passing
|
||||
- No breaking changes to public API
|
||||
|
||||
## [1.1.0] - 2025-11-25
|
||||
|
||||
### Added
|
||||
|
||||
Reference in New Issue
Block a user