core
core copied to clipboard
Performance: Cached Routes + opcache
Is it possible to cache the current routes? For max performance?
Examples:
- https://github.com/nikic/FastRoute#caching
- https://github.com/laravel/framework/blob/8.x/src/Illuminate/Foundation/Console/RouteCacheCommand.php
Any suggestion @mikecao?
Opcache should work with Flight.
Flight is really light.
Other things such as database or dynamic content would probably be the performance bottleneck.
If you have a large amount of routes, then caching is beneficial. If you only have a couple dozen, it's basically worthless. When you have 100s of routes then caching becomes amazing!
Closing for now.