-
Notifications
You must be signed in to change notification settings - Fork 40
Add stats_counts context api #7415
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
base: main
Are you sure you want to change the base?
Conversation
Working on fixing the |
Ok, the |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
- Look in the dev tools network tab. Check that in the request to the stats contains the new stats counts fields.
- Look in the dev tools network tab. See that the request to the new stats endpoint was successful.
Looks good!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
-
Look in the dev tools network tab. Check that in the request to the stats contains the new stats counts fields.
-
Look in the dev tools network tab. See that the request to the new stats endpoint was successful.
Fixes #7414
Creates a
stats_counts
api that returns in a json response the counts for collection objects, collections, and specify users. Also, edit the call to the stats server, with these new parameters added. The stats count values are cached for 24 hours in order to not over request to the database.The lambda function for handling the new stats request is here https://us-east-1.console.aws.amazon.com/lambda/home?region=us-east-1#/functions/AggrgatedSp7Stats?tab=aliases. I also put the lambda function code on discourse https://discourse.specifysoftware.org/t/aggregated-stats-data-lambda-function/3028
The corresponding issue for the stats server to use these new fields is here specify/sp7-stats#7
TODO: Decide what other fields want to be added.
Checklist
self-explanatory (or properly documented)
Testing instructions