I have a question regarding TYPO3 9 (and future versions) and PSR-15.
AFAIK most of the backend modules implement a handleRequest
method for backend module controllers that have the same signature as PSR-15's RequestHandlerInterface
.
Is it intended in future versions to implement this interface and does anything speak against implementing for my own backend modules?
I’m rebuilding an entire backend module for compatibility with TYPO3 9 and would like to be sure that such an approach is viable in future version s (at least until TYPO3 10).
The module itself worked for almost 10 years without any bigger overhaul, but with BaseScriptClass being deprecated, I see no other choice.
Thanks for your feedback.
Using requests and response is the way to go. This is nothing invented by TYPO3 but a standard which is implemented, see https://www.php-fig.org/psr/psr-15/. Stuff like
GeneralUtility::_GET
will be deprecated or even removed probably in version 10.Getting back to your question: Yes use that in your backend modules! Currently the core tries to remove less extbase, especially in the backend because of various reasons and this is also the way to go for extensions. Check out e.g. the backend module of the redirects extension or site module. A custom extension I currently implement is https://github.com/georgringer/site_management which follows also those principles.