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

Add send total timeout and use dedicated context for metrics #33

Merged
merged 1 commit into from
Jun 9, 2023

Conversation

masih
Copy link
Member

@masih masih commented Jun 9, 2023

Add a total timeout for a single cycle of broadcast. This is to make sure that the entire broadcast batch is either sent or wiped clean if it cannot be sent. The previous mechanism had timeouts implicitly inside bitswap implementation. The changes here add an explicit timeout to the context used across send.

Use a separate background context for metrics to assure that metrics are collected even if context expires. This is to avoid room for odd numbers being reported by metrics.

Add a total timeout for a single cycle of broadcast. This is to make
sure that the entire broadcast batch is either sent or wiped clean if it
cannot be sent. The previous mechanism had timeouts implicitly inside
bitswap implementation. The changes here add an explicit timeout to the
context used across send.

Use a separate background context for metrics to assure that metrics are
collected even if context expires. This is to avoid room for odd numbers
being reported by metrics.
@masih masih merged commit 481164f into main Jun 9, 2023
@masih masih deleted the masih/metrics_context branch June 9, 2023 19:22
masih added a commit to ipni/storetheindex that referenced this pull request Jun 9, 2023
masih added a commit to ipni/storetheindex that referenced this pull request Jun 9, 2023
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.

1 participant