routing by frontName like {frontName}/[params1]/[paramsX]… in magento2

Magento2 processing requests with the structure like:

{frontName}/{controller}/{action}

but i need to process some requests with the structure like

{frontName}/[params1]/[paramsX]...

what’s the best way to solve it?
Event linstener for controller_front_send_response_before?
Interceptor for MagentoUrlRewriteControllerRoute?
or any other … thanks very much


Source: stackoverflow-php