Issue #3564915: Fix ContainerNotInitializedException during D11 container compilation
Summary
Fixes the remaining gap in CacheBase::deleteMultiple() where ContainerNotInitializedException can still occur on Drupal 11 when using bootstrap_container_definition.
Changes
-
Code fix: Wrap
\Drupal::database()call in try-catch forContainerNotInitializedException - Documentation: Update README.md and settings.redis.example.php with D11 compatibility notes
-
Tests: Add
CacheBaseContainerCompatibilityTest(5 tests, 11 assertions)
Issue
Why the existing fix is insufficient
Commit fbd11ae added hasContainer() check, but during D11's HookCollectorKeyValueWritePass, the container exists (hasContainer() returns TRUE) but database service throws ContainerNotInitializedException.