Controllers are the most important thing in MVC pattern, controller helps to receive request, process and render pages. To create a frontend controller and to process the request we need to extend our controller class with Magento\Framework\App\Action\Action class this class context gives some added features to handle request type and to validate authorized users and so on. But in this process Magento needs to include so many classes which ultimately increase execution time.
Custom Router in Magento 2
In our development lifecycle, we face the situation where we need to create a custom URL for our module or we need to modify the route to match the requirement, in this situation we need to create a custom router in Magento 2
Profiler in Magento 2
Profiler in simple language can be considered as a program, which helps to check and report the performance of another program.
Virtual Types in Magento 2
Virtual types are a way to inject different dependencies into existing PHP classes without affecting other classes and without having to create a new class file.
Custom Cache Type
In cache.xml file we need to pass two parameters i.e. “label” and the “description” this parameters use to display label and the cache description on cache management page i.e. System > Tools > Cache Management