Hey! Laravelians ❤️ Can You Tell Me?
Did you ever have worked on a very huge Laravel project with millions of dataset & how do you optimize your queries in such a project using Eloquent or Raw SQL?
Back
•
In response to @muhammadabdullahmirza
For me the optimization started on the database side.
I monitored the most time consuming ( slowest and most used) queries and optimized the indexes or created materialized tables to optimize them. Optimizing the db was highly effective.
Take advantage of short circuit to speed huge where queries if your db supports it.
Another optimization is to take advantage of as much cache as possible for your project. Appart from that I can't give more advice without knowing more about the project.