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

Refactor dispatcher timeout #641

Merged
merged 1 commit into from
Jul 17, 2024

Conversation

ian-shim
Copy link
Contributor

Why are these changes needed?

Currently, the dispatcher DisperseBatch method takes context in the parameter but uses the fixed timeout specified in its config.
This doesn't allow the caller to use variable timeouts for different requests which is necessary for minibatcher.
This PR makes two changes:

  • It removes the fixed timeout in dispatcher config, and adds a timeout parameter for explicitly setting the timeout for each call
  • It makes sendChunks a public method

Checks

  • I've made sure the lint is passing in this PR.
  • I've made sure the tests are passing. Note that there might be a few flaky tests, in that case, please comment that they are not relevant.
  • Testing Strategy
    • Unit tests
    • Integration tests
    • This PR is not tested :(

@ian-shim ian-shim requested review from pschork and jianoaix July 16, 2024 00:20
@ian-shim ian-shim marked this pull request as ready for review July 16, 2024 04:23
@ian-shim ian-shim force-pushed the dispatcher-send-chunks branch from 3bf5495 to 18f4fca Compare July 17, 2024 21:21
@ian-shim ian-shim merged commit 52932b5 into Layr-Labs:master Jul 17, 2024
6 checks passed
ian-shim added a commit that referenced this pull request Jul 18, 2024
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