Make dataMapper not a singleton
In order to make further refactoring for https://review.typo3.org/#/c/53974/ where we want to pass a query/query settings object to datamapper, first we need to make dataMapper not a singleton.
All dependencies injected in datamapper are singletons.
There is a property "dataMap" which serves as a runtime cache for datamap.
btw, Datamap is also cached additionaly in dataMapFactory.
so the datamap property can be either replaced by a runtime cache from core, or kept as is, or moved to DataMapFactory
[TASK] Make DataMapper not a singleton
DataMapper is not a singleton any more. Thanks to that, a further
refactoring can be done to pass aggregate root query configuration
to the DataMapper, which will allow to fix inconsistencies
in Extbase language handling.
The runtime cache of data maps is moved to DataMapFactory.
Tested-by: TYPO3com <firstname.lastname@example.org>
Reviewed-by: Christian Kuhn <email@example.com>
Tested-by: Christian Kuhn <firstname.lastname@example.org>
Reviewed-by: Markus Klein <email@example.com>
Tested-by: Markus Klein <firstname.lastname@example.org>