Add DB indexes to queried tables
See original GitHub issueHi everyone, good afternoon.
We are using lighthouse-ci and sqlite to save the data. We have a bunch of websites that we’ve collect the data, but today I started experiencing some slowness, it’s impossible to get the data from the /statistics
path. I took a look at the database and we have ~23.000 rows on the statistics table. It seems that there is no indexes on it as well. However, not sure if you guys had a huge amount of data before.
Thanks, Regards.
Issue Analytics
- State:
- Created 3 years ago
- Reactions:1
- Comments:8
Top Results From Across the Web
How to use Indexing to Improve Database Queries - Data School
Indexes allow us to create sorted lists without having to create all new sorted tables, which would take up a lot of storage...
Read more >SQL CREATE INDEX Statement
The CREATE INDEX statement is used to create indexes in tables. Indexes are used to retrieve data from the database more quickly than...
Read more >Using Database Indexes Tutorial Example
A database table can have one or more indexes associated with it. An index is defined by a field expression that you specify...
Read more >Top five considerations for SQL Server index design
SQL index is considered as one of the most important factors in the SQL Server performance tuning field. It helps in speeding up...
Read more >How Does Indexing Work
Indexing is the way to get an unordered table into an order that will maximize the query's efficiency while searching. When a table...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Hi @patrickhulce I was able to manage in a different way. I was using AWS fargate and it seems that when the application started the metrics calculation the container stopped suddenly, so the calculation has never finished properly. I moved to an AWS EC2 instance and now the metrics are able to be calculated.
It’s taking ~11 seconds (the
/statistics
path on dashboard window), but we have more than 60 websites being analyzed, I believe that it’s a huge number.However, adding an index in the future maybe help to decrease that number!
Thank you for your helping! Regards.
Wow, that’s pretty cool @patrickhulce thank you for your effort on that! As soon as you release it I’ll update on my side!