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

Organisation usage charts should show data for current billing period #3406

Closed
matthewelwell opened this issue Feb 12, 2024 · 4 comments · Fixed by #4526
Closed

Organisation usage charts should show data for current billing period #3406

matthewelwell opened this issue Feb 12, 2024 · 4 comments · Fixed by #4526
Assignees

Comments

@matthewelwell
Copy link
Contributor

Conversation for context: #3340 (review).

Currently the Organisation usage charts show the numbers for the previous 30 days. We are making changes in the PR linked above to send customers alerts when they hit certain thresholds of their API calls limits. Based on this, we'll need to add information to this screen which shows the data for the current billing period.

image

I suggest that we add some kind of switcher which allows you to switch between current billing period and then the previous 30 days. The charts should display exactly the same, but the numbers should change (in 99% of cases).

@matthewelwell
Copy link
Contributor Author

Next step: discuss with @novakzaballa as to what is feasible from a FE perspective.

@zachaysan
Copy link
Contributor

Notes from call with Novak:

  • Include prior billing period as it's own selection
  • Include current billing period (TBD: how does the current billing period look if there is not many days?)
  • Include rolling 30 day billing period.

Some possible nice to haves:

  • A 60 or 90 day window to show longer window to users.

Notes on the integration:

  • Should be straightforward if the structure is similar for the graphs.
  • Not 100% sure about the structure for the current billing period or the 90 day window will be able to easily snap in.

@dabeeeenster
Copy link
Contributor

@zachaysan I can explain how the downsampling works in Influx - there are several downsampling stages so its important you are querying the right bucket if timeliness of data is important.

@matthewelwell
Copy link
Contributor Author

The endpoint at /api/v1/organisations/{organisation_pk}/usage-data accepts the query parameter period=current_billing_period|previous_billing_period|90_day_period.

Note that only paid organisations should have access to the billing period specific periods.

@kyle-ssg kyle-ssg linked a pull request Aug 21, 2024 that will close this issue
4 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants