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

311 timeouts #347

Closed
wants to merge 8 commits into from
Closed

311 timeouts #347

wants to merge 8 commits into from

Conversation

bretambrose
Copy link
Contributor

@bretambrose bretambrose commented Jan 29, 2024

  • Adds support and tests for 311-client-wide operation timeout for Subscribe and all of its variants. The previous timeout implementation did not apply to subscribe.
  • Adds internal APIs (and tests) for per-311-operation timeouts for Subscribe, Unsubscribe, and Publish

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.

@codecov-commenter
Copy link

codecov-commenter commented Jan 29, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Comparison is base (d55553f) 82.72% compared to head (3e27f40) 82.77%.

Additional details and impacted files
@@               Coverage Diff               @@
##           311Listener     #347      +/-   ##
===============================================
+ Coverage        82.72%   82.77%   +0.05%     
===============================================
  Files               23       23              
  Lines             9088     9115      +27     
===============================================
+ Hits              7518     7545      +27     
  Misses            1570     1570              

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@bretambrose bretambrose changed the base branch from 311Listener2 to 311Listener January 30, 2024 23:07
@bretambrose bretambrose marked this pull request as ready for review January 30, 2024 23:10
source/client.c Outdated Show resolved Hide resolved
.socket_options = &state_test_data->socket_options,
.on_connection_complete = aws_test311_on_connection_complete_fn,
.ping_timeout_ms = DEFAULT_TEST_PING_TIMEOUT_MS,
.protocol_operation_timeout_ms = 3000,
Copy link
Contributor

Choose a reason for hiding this comment

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

It looks like we're using the same value for the regular timeout tests and overridden timeout tests (3 seconds). Let's use different values (shorter for override) to make sure we're using the override value when examining test results. Also, might be useful to set the protocol_operation_timeout_ms in the override tests to make sure we're overriding the provided value explicitly. Not setting it defaults the regular value to UINT64_MAX which is ignored so any timeout occurring probably indicates this test is successful.

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'm not bothered by this. Elapsed time comparisons in tests have consisently blown up in our faces when containers and CPU throttling on cloud CI (and emulated ARM builds) get thrown into the mix.

Copy link
Contributor

@sbSteveK sbSteveK left a comment

Choose a reason for hiding this comment

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

Some trivial comments that may or may not need action but otherwise looks good.

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.

3 participants