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

clientv3/integration: finish isolated node test cases #8785

Merged
merged 1 commit into from
Oct 30, 2017

Conversation

gyuho
Copy link
Contributor

@gyuho gyuho commented Oct 27, 2017

  1. one with retry
  2. one without retry (range request with longer timeouts)

#8711

func TestBalancerUnderNetworkPartitionSerializableGet(t *testing.T) {
testBalancerUnderNetworkPartition(t, func(cli *clientv3.Client, ctx context.Context) error {
_, err := cli.Get(ctx, "a", clientv3.WithSerializable())
if err == context.DeadlineExceeded {
Copy link
Contributor

Choose a reason for hiding this comment

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

for s-get, it should return immediately since it does not need go through raft. we should not even see deadline exceed, right?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Removed and only kept s-get case that expects always succeeds on the first try.

@gyuho gyuho added the WIP label Oct 30, 2017
}, 2*time.Second, false)
}

func TestBalancerUnderNetworkPartitionSerializableGetRetry(t *testing.T) {
Copy link
Contributor

Choose a reason for hiding this comment

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

what is the difference between Get and GetRetry?

Copy link
Contributor Author

@gyuho gyuho Oct 30, 2017

Choose a reason for hiding this comment

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

LinearizableGetWithRetry expects quorum get succeeds on the second try, after network partition happens.

LinearizableGetWithNoRetry expects quorum get blocks until balancer switch after network partition. Otherwise error out (without manual retry--expects first request succeeds).

1. one with retry
2. one without retry (range request with longer timeouts)

Signed-off-by: Gyu-Ho Lee <[email protected]>
@xiang90
Copy link
Contributor

xiang90 commented Oct 30, 2017

lgtm if tests pass.

@gyuho gyuho merged commit 299c704 into etcd-io:master Oct 30, 2017
@gyuho gyuho deleted the ttt branch October 30, 2017 19:38
@codecov-io
Copy link

Codecov Report

❗ No coverage uploaded for pull request base (master@2200450). Click here to learn what that means.
The diff coverage is n/a.

Impacted file tree graph

@@            Coverage Diff            @@
##             master    #8785   +/-   ##
=========================================
  Coverage          ?   76.09%           
=========================================
  Files             ?      360           
  Lines             ?    29648           
  Branches          ?        0           
=========================================
  Hits              ?    22560           
  Misses            ?     5516           
  Partials          ?     1572

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 2200450...bea930f. Read the comment docs.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants