-
Notifications
You must be signed in to change notification settings - Fork 174
Apartment 4.0.0.alpha1: Complete architectural refactor with comprehensive spec coverage #327
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Open
mnovelo
wants to merge
19
commits into
development
Choose a base branch
from
man/spec-restart
base: development
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
…iews, and add cspell configuration
- Add 13 new spec files covering all major components - Achieve comprehensive test coverage across PostgreSQL, MySQL, and SQLite - Add extensive documentation (CLAUDE.md files) for architecture context - Update docs/4.0-Upgrade.md with detailed migration guide for breaking changes - Fix Rails 8 compatibility issues in connection pooling - Add stress testing for high-concurrency tenant switching scenarios - Include database-agnostic tests for cross-platform compatibility - Add comprehensive error handling and edge case testing 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <[email protected]>
- Keep 4.0.0.alpha1 dependency requirements (Rails 7.1+, Ruby 3.2+) - Incorporate updated public_suffix constraint from development (< 7) - Maintain new dependencies needed for architecture (concurrent-ruby, zeitwerk) - Preserve enhanced metadata and file listing approach 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <[email protected]>
- Remove .github/workflows/close-stale-issues.yml (no longer needed) - Update .github/workflows/gem-publish.yml to use actions/checkout@v5 (latest version) 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <[email protected]>
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Summary
This PR represents the Apartment 4.0.0.alpha1 release with a complete architectural refactor focused on connection-pool-per-tenant design. This is a major milestone that introduces significant performance improvements, enhanced thread safety, and comprehensive test coverage.
Key Architectural Changes
ActiveSupport::CurrentAttributes
Comprehensive Test Coverage
Added 13 new spec files with extensive coverage:
Breaking Changes (4.0.0.alpha1)
Configuration Changes:
tenant_names
→tenants_provider
(must be callable)tenant_strategy
setting (:schema
,:database_name
,:shard
,:database_config
)API Changes:
Apartment::Tenant.current_tenant
→Apartment::Tenant.current
Apartment::Tenant.reset!
→Apartment::Tenant.reset
Middleware Updates:
ensure
blocksPerformance Improvements
Documentation & Migration Support
docs/4.0-Upgrade.md
with step-by-step migrationTest Coverage Verification
Cross-Database Testing ✅
Verified compatibility across all database engines:
Stress Testing ✅
Rails Version Compatibility ✅
Tested across multiple Rails versions:
Test Plan
Migration Timeline
Recommended: 1-2 sprint cycles for complete migration and testing
This alpha release provides a stable foundation for early adopters to begin migration while we gather feedback for the final 4.0.0 release.
🤖 Generated with Claude Code