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

gsb-http-proxy counters support #84

Merged
merged 21 commits into from
Apr 4, 2024
Merged

gsb-http-proxy counters support #84

merged 21 commits into from
Apr 4, 2024

Conversation

pwalski
Copy link
Contributor

@pwalski pwalski commented Mar 29, 2024

Resolves: #56

@pwalski pwalski force-pushed the pwalski/gsb_proxy_counters branch 3 times, most recently from 7beea76 to 0ed2ab7 Compare March 31, 2024 22:26
@pwalski pwalski marked this pull request as ready for review April 1, 2024 20:38
@pwalski pwalski force-pushed the pwalski/gsb_proxy_counters branch from 42d0f3d to f119a8f Compare April 1, 2024 20:38
@pwalski pwalski marked this pull request as draft April 2, 2024 09:42
@pwalski pwalski marked this pull request as ready for review April 2, 2024 14:52
@pwalski pwalski mentioned this pull request Apr 2, 2024
@pwalski pwalski changed the title gsb proxy counters gsb-http-proxy counters Apr 2, 2024
@pwalski pwalski changed the title gsb-http-proxy counters gsb-http-proxy counters support Apr 2, 2024
Comment on lines +75 to +82
CounterError::UsageLimitExceeded(info) => {
set_terminate_state_msg(
&report_service,
activity_id,
Some(format!("Usage limit exceeded: {}", info)),
None,
)
.await
Copy link
Contributor Author

Choose a reason for hiding this comment

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

Side effect of sharing counters implementation is an UsageLimitExceeded error. Not expected but handling it will do no harm.

@@ -215,6 +251,21 @@ async fn run<RUNTIME: process::Runtime + Clone + Unpin + 'static>(

let agreement = AgreementDesc::load(agreement_path)?;

let mut gsb_proxy = GsbToHttpProxy::new("http://localhost:7861/".into());

let mut counters = CountersServiceBuilder::new(agreement.counters.clone(), Some(10000));
Copy link
Contributor Author

Choose a reason for hiding this comment

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

I forgot about it. It is a default backlog_limit.

Copy link
Contributor

@nieznanysprawiciel nieznanysprawiciel left a comment

Choose a reason for hiding this comment

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

Looks good

@pwalski pwalski merged commit 7ae55db into main Apr 4, 2024
6 checks passed
@pwalski pwalski deleted the pwalski/gsb_proxy_counters branch April 4, 2024 10:41
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.

Usage counters - GPU
2 participants