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

storage: Add test that the first timeseries range uses epoch leases #18247

Merged
merged 1 commit into from
Sep 7, 2017
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 7 additions & 1 deletion pkg/storage/client_lease_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,13 @@ func TestStoreRangeLease(t *testing.T) {
defer mtc.Stop()
mtc.Start(t, 1)

splitKeys := []roachpb.Key{roachpb.Key("a"), roachpb.Key("b"), roachpb.Key("c")}
// NodeLivenessKeyMax is a static split point, so this is always
// the start key of the first range that uses epoch-based
// leases. Splitting on it here is redundant, but we want to include
// it in our tests of lease types below.
splitKeys := []roachpb.Key{
keys.NodeLivenessKeyMax, roachpb.Key("a"), roachpb.Key("b"), roachpb.Key("c"),
}
for _, splitKey := range splitKeys {
splitArgs := adminSplitArgs(splitKey)
if _, pErr := client.SendWrapped(context.Background(), mtc.distSenders[0], splitArgs); pErr != nil {
Expand Down