Skip to content
Commit de7eea95 authored by Daniel Vrátil's avatar Daniel Vrátil 🤖
Browse files

CollectionStatistics: prefetch all stats on start

When Akonadi is started each application and agent starts requesting
its Collections and statistics. This causes the CollectionStatistics
cache to query the stats for each Collection individually with the
very expensive query. On my system all the statistics queries together
take over 17 seconds.

With this change the CollectionStatistics cache simply pre-fetches
statistics for all Collections in single a query, which is MUCH
faster (less than a second on my system), because the expensive JOINs
only have to be done once.

As a result of this change applications and agents become responsive
much faster after start and CPU and IO load during start is massively
decreased.
parent 94fdc1d4
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment