question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Add DB indexes to queried tables

See original GitHub issue

Hi 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:closed
  • Created 3 years ago
  • Reactions:1
  • Comments:8

github_iconTop GitHub Comments

1reaction
thiagosanchescommented, Aug 13, 2020

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.

0reactions
thiagosanchescommented, Aug 18, 2020

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!

Read more comments on GitHub >

github_iconTop 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 >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found