Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

file cache route creation Ziggy.php #710

Open
wants to merge 1 commit into
base: 2.x
Choose a base branch
from
Open

Conversation

msoler75
Copy link

file cache creation of data for optimum performance.

In my localhost, with a laravel project with ~300 routes, I reduce time about 10 to 56 ms

cache creation of data for better performance
@bakerkretzmar
Copy link
Collaborator

Not totally convinced that this is necessary, but open to it if the performance gains are significant. I'm surprised that reading from the file and calling collect() is faster than doing it in memory.

Can you add tests for this and update your code comments to be in English? Also, is this tied to the route cache at all? How does it get cleared/updated when routes change?

Thanks!

@bakerkretzmar bakerkretzmar self-assigned this Feb 20, 2024
@bakerkretzmar bakerkretzmar changed the base branch from main to 2.x February 20, 2024 21:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants