The extbase ConfigurationManager is (unfortunately)
a stateful singleton that we can not get rid of
without a bigger rewrite.
While stateful singletons are bad enough, the
extbase LocalizationUtility makes this worse by
parking an instance of ConfigurationManager in
a static property, re-using it as a "cached"
singleton.
LocalizationUtility does this since it in itself
is static, which makes this service just so
convenient to use. When it comes to sub requests
and similar, static state is doomed and we need
to get rid of it, we've had a couple of patches
in v12 dealing with similar things.
Mid-term, extbase LocalizationUtility needs to
vanish anyways, but in the meantime, we have to
get rid of static state that kills sub request scope.
The patch removes the static $configurationManager
property and adapts functional tests that already
showed the current solution was a hack. There are
various upper and lower cache layers that ensure
removing this "cache layer" won't make things more
expensive in practice, which allows us to remove
this static state without further fallback.
In main, this needs a TF update:
> composer u typo3/testing-framework
In 12.4, this need a TF raise:
> composer req --dev typo3/testing-framework:^8.0.3