Skip to content

Commit

Permalink
tests: Add reproduce etcd-io#13766 scenario
Browse files Browse the repository at this point in the history
Signed-off-by: Marek Siarkowicz <siarkowicz@google.com>
  • Loading branch information
serathius committed Jan 17, 2023
1 parent 09b5663 commit 287e1b6
Show file tree
Hide file tree
Showing 4 changed files with 20 additions and 11 deletions.
12 changes: 6 additions & 6 deletions .github/workflows/linearizability-nightly.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -10,17 +10,17 @@ jobs:
uses: ./.github/workflows/linearizability-template.yaml
with:
ref: main
count: 300
testTimeout: 170m
count: 100
testTimeout: 200m
test-35:
uses: ./.github/workflows/linearizability-template.yaml
with:
ref: release-3.5
count: 300
testTimeout: 170m
count: 100
testTimeout: 200m
test-34:
uses: ./.github/workflows/linearizability-template.yaml
with:
ref: release-3.4
count: 300
testTimeout: 170m
count: 100
testTimeout: 200m
2 changes: 1 addition & 1 deletion .github/workflows/linearizability-template.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ on:
permissions: read-all
jobs:
test:
timeout-minutes: 180
timeout-minutes: 210
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@ac593985615ec2ede58e132d2e21d2b1cbd6127c # v3.3.0
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/linearizability.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -6,5 +6,5 @@ jobs:
uses: ./.github/workflows/linearizability-template.yaml
with:
ref: ${{ github.ref }}
count: 60
count: 15
testTimeout: 30m
15 changes: 12 additions & 3 deletions tests/linearizability/linearizability_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -37,9 +37,9 @@ import (

const (
// minimalQPS is used to validate if enough traffic is send to make tests accurate.
minimalQPS = 100.0
minimalQPS = 200.0
// maximalQPS limits number of requests send to etcd to avoid linearizability analysis taking too long.
maximalQPS = 200.0
maximalQPS = 1000.0
// waitBetweenFailpointTriggers
waitBetweenFailpointTriggers = time.Second
)
Expand All @@ -56,6 +56,7 @@ func TestLinearizability(t *testing.T) {
failpoint: RandomFailpoint,
config: *e2e.NewConfig(
e2e.WithClusterSize(1),
e2e.WithSnapshotCount(100),
e2e.WithPeerProxy(true),
e2e.WithGoFailEnabled(true),
e2e.WithCompactionBatchLimit(100), // required for compactBeforeCommitBatch and compactAfterCommitBatch failpoints
Expand All @@ -65,6 +66,7 @@ func TestLinearizability(t *testing.T) {
name: "ClusterOfSize3",
failpoint: RandomFailpoint,
config: *e2e.NewConfig(
e2e.WithSnapshotCount(100),
e2e.WithPeerProxy(true),
e2e.WithGoFailEnabled(true),
e2e.WithCompactionBatchLimit(100), // required for compactBeforeCommitBatch and compactAfterCommitBatch failpoints
Expand All @@ -86,6 +88,13 @@ func TestLinearizability(t *testing.T) {
e2e.WithGoFailEnabled(true),
),
},
{
name: "Issue13766",
failpoint: KillFailpoint,
config: *e2e.NewConfig(
e2e.WithSnapshotCount(100),
),
},
}
for _, tc := range tcs {
t.Run(tc.name, func(t *testing.T) {
Expand All @@ -103,7 +112,7 @@ func TestLinearizability(t *testing.T) {
}, trafficConfig{
minimalQPS: minimalQPS,
maximalQPS: maximalQPS,
clientCount: 8,
clientCount: 12,
traffic: DefaultTraffic,
})
longestHistory, remainingEvents := pickLongestHistory(events)
Expand Down

0 comments on commit 287e1b6

Please sign in to comment.