Skip to content

Cache todo counters (pending/done)

Paco Guzman requested to merge 18034-cache-todo-counter into master

What does this MR do?

Cache todos_pending and todos_done counters

Are there points in the code the reviewer needs to double check?

  • The service object that creates/updates todos will manage the cache invalidations
  • The helper methods that originate the calls to get counter will use the Todo class methods to go through the cache.
  • I wrote all the code together in one place onto the Todo model. So all the cache writes, reads and deletes are happening in the same place even when is used in different places.

Why was this MR needed?

To reduce the number of database queries

What are the relevant issue numbers?

Closes #18034 (closed)

Merge request reports