mirror of
https://github.com/archtechx/tenancy.git
synced 2025-12-12 19:14:04 +00:00
1 commit
| Author | SHA1 | Message | Date | |
|---|---|---|---|---|
|
|
bd9bbe8b41
|
Cache prefix mode for separating tenant caches (#1014)
* cache prefix
* prefix cache bootstrapper and tests
* remove comment
* DI app
* cache prefix base from config
* Create PrefixCacheBootstrapperTest.php
* remove `null` check
* fix phpstan error
* Update PrefixCacheTenancyBootstrapper.php
* Update PrefixCacheBootstrapperTest.php
* add comments
* Update PrefixCacheTenancyBootstrapper.php
* Update PrefixCacheBootstrapperTest.php
* Update config.php
* test names grammar
* user `getTenantKey` method
* assert tenants' data is accessible using the prefix from the central context
* remove unused line
* use proper DI
* build prefix using original prefix
* fix prefix test according to prefix changes
* fix test
* CacheManager dependency injection test
* CacheService class as singleton
* introduce second tenant in test
* use Repository in service class DI
* Update CacheAction.php
* Rename CacheAction to CacheService
* Update prefix bootstrapper and test (`setStore()` in CacheManager and Repository needed)
* Add macro
* Fix code style (php-cs-fixer)
* Simplify cache store refreshing
* Make Tenancy override CacheManager
* Update CacheManager, add refreshStore()
* Fix code style (php-cs-fixer)
* Uncomment cache tagging
* Revert condition in CacheManager to avoid excessive nesting
* Move `Cache::macro()` to a slightly more appropriate place
* Fix code style (php-cs-fixer)
* Use better class for the macro
* Toggle cache tags
* Make CacheManager::$addTags default to `true`
* Add changes to PR to Laravel
* Fix code style (php-cs-fixer)
* Revert changes, add comment
* Add test
* Make `$cache` non-nullable
Co-authored-by: Samuel Štancl <samuel@archte.ch>
* Add and test `nonTenantCacheDrivers`
* Add nonTenantCacheDrivers check
* Test that the prefix stays the same
* Change nonTenantCacheDrivers to tenantCacheStores
* Remove redundant CacheManager extend() call
* Make 'redis' the only tenant cache store in beforeEach, test that tenantCacheStores works
* Remove unused import, change word
* Make CacheService a singleton in a test
* Update test name
* Remove group('prefix')
* Rename CacheManagerService
* Improve specific cache store in a service test
* Improve comment
* Improve tests
* Use my Laravel fork
* Fix code style (php-cs-fixer)
* Downgrade Laravel
* Upgrade Laravel
* Hint Repository implementation instead of contract
* Fix types
* Fix code style (php-cs-fixer)
* Fix test
* Use Laravel fork in ci.yml
* use dev-master before our changes are released in L10
* remove laravel fork from repositories
* use 10.x-dev instead of master
* remove L9 support
* 10.x-dev (fix conflict resolution)
* use the laravel version from the ci matrix for the phpstan job as well
* Revert "use the laravel version from the ci matrix for the phpstan job as well"
This reverts commit
|