Skip to content

Add caching to /statistics endpoint #2544

@piprett

Description

@piprett

This endpoint is significantly slower than a lot of others, due to doing large database queries. It takes multiple seconds on production, and makes graphing hard since I don't want to downgrade performance. Caching this endpoint in redis would improve the response times, and reduce DDoS risk. An alternative approach would be to keep count in-memory, then increase this number when X happens. This is even more performant, but less reliable.

Metadata

Metadata

Assignees

No one assigned

    Labels

    backendInvolves work from the backend team

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions