1.5.0
Changes
Changed
- PHP 8.2+ Requirement: Updated minimum PHP version from ^8.1 to ^8.2
- Symfony Cache Update: Updated dependency to
^6.0 || ^7.2 - Removed doctrine/annotations: Eliminated abandoned dependency, migrated to native PHP 8 attributes
- Code Modernization: Use readonly properties where applicable for immutability
Removed
- Serializable interface from cache adapters (now use
__serialize/__unserializemagic methods) - Unused
Php73BcSerializableTraitclass - Unused
RedisInstanceannotation class
Added
- Migration Tools: Added
rector-migrate.phpfor automated annotation-to-attribute migration - Migration Guide: Added
ANNOTATION_TO_ATTRIBUTE.mdwith comprehensive migration instructions - Documentation: Added CLAUDE.md with project architecture and development workflow
Fixed
- CI/CD workflows updated to latest GitHub Actions versions
- Replace deprecated
set-outputwith$GITHUB_OUTPUT - Add
--ignore-platform-req=phpfor PHP 8.5 compatibility testing - rector-migrate.php: Remove hardcoded paths to allow users to specify their own project paths
⚠️ Migration Required
Applications using annotations must migrate to PHP 8 attributes:
# Preview changes
vendor/bin/rector process src --config=vendor/ray/psr-cache-module/rector-migrate.php --dry-run
# Apply migration
vendor/bin/rector process src --config=vendor/ray/psr-cache-module/rector-migrate.phpSee ANNOTATION_TO_ATTRIBUTE.md for detailed migration guide.
Why This Change?
The doctrine/annotations package has been officially abandoned by its maintainers and will no longer receive updates or security patches. This change:
- Eliminates security and compatibility risks from the abandoned package
- Adopts native PHP 8 attributes as the modern standard
- Improves performance (no runtime annotation parsing overhead)
- Provides migration tooling for users to update their applications
Supported Annotations
The migration tool automatically converts:
@Local→#[Local]- For non-shared cache (APCu/Filesystem)@Shared→#[Shared]- For shared cache (Redis/Memcached)@CacheDir→#[CacheDir]- Cache directory configuration@CacheNamespace→#[CacheNamespace]- Cache namespace configuration@RedisConfig→#[RedisConfig]- Redis connection configuration@MemcacheConfig→#[MemcacheConfig]- Memcached connection configuration