Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Computation cache #633

Open
sbidoul opened this issue Sep 11, 2024 · 0 comments
Open

Computation cache #633

sbidoul opened this issue Sep 11, 2024 · 0 comments

Comments

@sbidoul
Copy link
Member

sbidoul commented Sep 11, 2024

Some reports can be slow to compute.

When displaying the report, then using the drill-down feature, the recomputation time when navigating back from drill-down is painful.

We considered a drill-down in a new browser tab but that is not possible with Odoo.
#621 opens a pop-up but the ergonomics is poor and further navigation from there loses the benefit.

Related: #593

The compute method of mis.report.instance returns a json that could be cached.

The idea would be that

  • the compute method stores the result in a per instance / per context cache
  • the compute method returns the cached json if not too old
  • we empty the cache on any write on mis.report.instance or related objects (periods, template, kpis), but not on reported data (move lines, etc) - how to do that cleanly?
  • a cron purges the cache for old entries
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant