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

Send usage data in 1-month portions #806

Merged
merged 5 commits into from
Jul 28, 2023
Merged

Conversation

ch-iara
Copy link
Contributor

@ch-iara ch-iara commented Jul 27, 2023

This change is meant to speed up the checkin loop when routers have a lot of data to upload for usage history. We now only iterate through and send up to a month's worth of hours per checkin.

@ch-iara ch-iara force-pushed the chiara/usage-data-send-portions branch from 4240025 to f1d520a Compare July 27, 2023 11:07
@jkilpatr jkilpatr force-pushed the chiara/usage-data-send-portions branch from f1d520a to 02fdaf9 Compare July 27, 2023 17:08
Copy link
Member

@jkilpatr jkilpatr left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This looks like it works ok but I'm going to insist on some unit tests.

I've also recommended how you can avoid using a self-implemented binary search. You may want to add sorting the usage tracker list to the startup cleanup (where we also remove duplicate hours)

rita_client/src/operator_update/mod.rs Outdated Show resolved Hide resolved
rita_client/src/operator_update/mod.rs Show resolved Hide resolved
@ch-iara ch-iara force-pushed the chiara/usage-data-send-portions branch from 02fdaf9 to df34ec6 Compare July 27, 2023 22:48
This change is meant to speed up the checkin loop when routers have
a lot of data to upload for usage history. We now only iterate
through and send up to a month's worth of hours per checkin.
@ch-iara ch-iara force-pushed the chiara/usage-data-send-portions branch 2 times, most recently from b5c318a to 20547a7 Compare July 28, 2023 08:56
@ch-iara ch-iara force-pushed the chiara/usage-data-send-portions branch from 20547a7 to d6da2c1 Compare July 28, 2023 09:02
@ch-iara ch-iara force-pushed the chiara/usage-data-send-portions branch from d6da2c1 to 2eafe8f Compare July 28, 2023 19:00
@jkilpatr jkilpatr enabled auto-merge (rebase) July 28, 2023 23:37
@jkilpatr jkilpatr merged commit 97d9d0a into master Jul 28, 2023
16 of 17 checks passed
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 this pull request may close these issues.

2 participants