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

Cosmos Issue #5247: Address read-my-writes test failure #6201

Merged
merged 12 commits into from
Nov 7, 2019
Merged

Cosmos Issue #5247: Address read-my-writes test failure #6201

merged 12 commits into from
Nov 7, 2019

Conversation

David-Noble-at-work
Copy link

@David-Noble-at-work David-Noble-at-work commented Nov 7, 2019

Addresses issue #5247 and improves Direct TCP diagnostics. The fix to the read-my-writes test failure is a single-line change to RntbdTransportClient. A number of other changes were made to:

  • Improve Direct TCP diagnostics
    One of the more notable improvements is the addition of RntbdRequestRecord.Stage which is useful for tracking a request through its lifetime in the RNTBD request pipeline. This addition ripples through the code in a few places.

  • An RntbdTransportClient.Options addition: requestExpiryInverval.
    This option will eventually be used to cancel "lost" requests. A lost request is one which was successfully sent but for which we get no response. The default value is 5 seconds, the time within which the server guarantees a response. Rationale: requests are sometimes lost when testing under load. When these requests are lost we currently wait the full request timeout interval; 65 seconds by default. Waiting just 5 seconds to fail a lost request once sent reduces our latency significantly.

  • Modest azure-cosmos-benchmark package changes that I found useful in troubleshooting the read-my-writes test failure.

  • Import optimization, code tidying/method sorting in a couple of places.

Most of the latter two changes were ported from my working branch on the v2.6 code path. The port to v2.6 and v3.0 will follow completion of this PR.

@David-Noble-at-work David-Noble-at-work marked this pull request as ready for review November 7, 2019 01:15
@David-Noble-at-work David-Noble-at-work merged commit b4029c2 into Azure:feature/cosmos/v4 Nov 7, 2019
@David-Noble-at-work David-Noble-at-work deleted the issue/#5247/cosmos/direct-tcp/read-my-writes branch November 7, 2019 02:40
@@ -73,6 +74,8 @@ public static void main(String[] args) throws Exception {
System.err.println("INVALID Usage: " + e.getMessage());
System.err.println("Try '-help' for more information.");
throw e;
} finally {
System.exit(0);
Copy link
Contributor

Choose a reason for hiding this comment

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

why do we need this?
This will cause problem for tests directly invoking Main:main()

@David-Noble-at-work David-Noble-at-work changed the title Direct TCP: address read-my-writes test failure Direct TCP: Address read-my-writes test failure Nov 9, 2019
@David-Noble-at-work David-Noble-at-work changed the title Direct TCP: Address read-my-writes test failure Cosmos Issue #5247: Address read-my-writes test failure Nov 9, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants