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

kv/kvserver/tenantrate: TestDataDriven failed #53590

Closed
cockroach-teamcity opened this issue Aug 28, 2020 · 6 comments · Fixed by #53661
Closed

kv/kvserver/tenantrate: TestDataDriven failed #53590

cockroach-teamcity opened this issue Aug 28, 2020 · 6 comments · Fixed by #53661
Labels
branch-master Failures and bugs on the master branch. C-test-failure Broken test (automatically or manually discovered). O-robot Originated from a bot.
Milestone

Comments

@cockroach-teamcity
Copy link
Member

(kv/kvserver/tenantrate).TestDataDriven failed on master@2e4df338ecd027f36a4ea9fee78b7398a5f55271:

=== RUN   TestDataDriven
--- FAIL: TestDataDriven (0.01s)
=== RUN   TestDataDriven/basic
    --- FAIL: TestDataDriven/basic (0.00s)
        limiter_test.go:68: output didn't match expected:
            @@ -1,6 +1,6 @@
            -kv_tenant_rate_limit_current_blocked 2
            -kv_tenant_rate_limit_current_blocked{tenant_id="2"} 2
            +kv_tenant_rate_limit_current_blocked 1
            +kv_tenant_rate_limit_current_blocked{tenant_id="2"} 1
             kv_tenant_rate_limit_current_blocked{tenant_id="3"} 0
             kv_tenant_rate_limit_current_blocked{tenant_id="5"} 0
             kv_tenant_rate_limit_current_blocked{tenant_id="system"} 0
             

More

Parameters:

  • TAGS=
  • GOFLAGS=-parallel=4
make stressrace TESTS=TestDataDriven PKG=./pkg/kv/kvserver/tenantrate TESTTIMEOUT=5m STRESSFLAGS='-timeout 5m' 2>&1

See this test on roachdash
powered by pkg/cmd/internal/issues

@cockroach-teamcity cockroach-teamcity added branch-master Failures and bugs on the master branch. C-test-failure Broken test (automatically or manually discovered). O-robot Originated from a bot. labels Aug 28, 2020
@cockroach-teamcity cockroach-teamcity added this to the 20.2 milestone Aug 28, 2020
@cockroach-teamcity
Copy link
Member Author

(kv/kvserver/tenantrate).TestDataDriven failed on master@2e4df338ecd027f36a4ea9fee78b7398a5f55271:

=== RUN   TestDataDriven
--- FAIL: TestDataDriven (0.02s)
=== RUN   TestDataDriven/basic
    --- FAIL: TestDataDriven/basic (0.01s)
        limiter_test.go:68: output didn't match expected:
            @@ -1,6 +1,6 @@
            -kv_tenant_rate_limit_current_blocked 2
            +kv_tenant_rate_limit_current_blocked 1
             kv_tenant_rate_limit_current_blocked{tenant_id="2"} 2
             kv_tenant_rate_limit_current_blocked{tenant_id="3"} 0
             kv_tenant_rate_limit_current_blocked{tenant_id="5"} 0
             kv_tenant_rate_limit_current_blocked{tenant_id="system"} 0
             

More

Parameters:

  • TAGS=
  • GOFLAGS=-race -parallel=2
make stressrace TESTS=TestDataDriven PKG=./pkg/kv/kvserver/tenantrate TESTTIMEOUT=5m STRESSFLAGS='-timeout 5m' 2>&1

See this test on roachdash
powered by pkg/cmd/internal/issues

@ajwerner
Copy link
Contributor

Must not be waiting for the timers correctly.

@cockroach-teamcity
Copy link
Member Author

(kv/kvserver/tenantrate).TestDataDriven failed on master@8b91062f9351d18f9104aff567cb152df162021e:

=== RUN   TestDataDriven
--- FAIL: TestDataDriven (0.01s)
=== RUN   TestDataDriven/basic
    --- FAIL: TestDataDriven/basic (0.01s)
        limiter_test.go:68: output didn't match expected:
            @@ -1,6 +1,6 @@
            -kv_tenant_rate_limit_current_blocked 2
            +kv_tenant_rate_limit_current_blocked 1
             kv_tenant_rate_limit_current_blocked{tenant_id="2"} 2
             kv_tenant_rate_limit_current_blocked{tenant_id="3"} 0
             kv_tenant_rate_limit_current_blocked{tenant_id="5"} 0
             kv_tenant_rate_limit_current_blocked{tenant_id="system"} 0
             

More

Parameters:

  • TAGS=
  • GOFLAGS=-parallel=4
make stressrace TESTS=TestDataDriven PKG=./pkg/kv/kvserver/tenantrate TESTTIMEOUT=5m STRESSFLAGS='-timeout 5m' 2>&1

See this test on roachdash
powered by pkg/cmd/internal/issues

@cockroach-teamcity
Copy link
Member Author

(kv/kvserver/tenantrate).TestDataDriven failed on master@8746e7e347dbbc19be051168225cd4fab0582294:

=== RUN   TestDataDriven
--- FAIL: TestDataDriven (0.01s)
=== RUN   TestDataDriven/basic
    --- FAIL: TestDataDriven/basic (0.00s)
        limiter_test.go:68: output didn't match expected:
            @@ -1,6 +1,6 @@
            -kv_tenant_rate_limit_current_blocked 2
            -kv_tenant_rate_limit_current_blocked{tenant_id="2"} 2
            +kv_tenant_rate_limit_current_blocked 1
            +kv_tenant_rate_limit_current_blocked{tenant_id="2"} 1
             kv_tenant_rate_limit_current_blocked{tenant_id="3"} 0
             kv_tenant_rate_limit_current_blocked{tenant_id="5"} 0
             kv_tenant_rate_limit_current_blocked{tenant_id="system"} 0
             

More

Parameters:

  • TAGS=
  • GOFLAGS=-parallel=4
make stressrace TESTS=TestDataDriven PKG=./pkg/kv/kvserver/tenantrate TESTTIMEOUT=5m STRESSFLAGS='-timeout 5m' 2>&1

See this test on roachdash
powered by pkg/cmd/internal/issues

@cockroach-teamcity
Copy link
Member Author

(kv/kvserver/tenantrate).TestDataDriven failed on master@cd8267ca84f6a0267a898220cfaa6630188b45c5:

=== RUN   TestDataDriven
--- FAIL: TestDataDriven (0.01s)
=== RUN   TestDataDriven/basic
    --- FAIL: TestDataDriven/basic (0.00s)
        limiter_test.go:68: output didn't match expected:
            @@ -1,6 +1,6 @@
            -kv_tenant_rate_limit_current_blocked 2
            -kv_tenant_rate_limit_current_blocked{tenant_id="2"} 2
            +kv_tenant_rate_limit_current_blocked 1
            +kv_tenant_rate_limit_current_blocked{tenant_id="2"} 1
             kv_tenant_rate_limit_current_blocked{tenant_id="3"} 0
             kv_tenant_rate_limit_current_blocked{tenant_id="5"} 0
             kv_tenant_rate_limit_current_blocked{tenant_id="system"} 0
             

More

Parameters:

  • TAGS=
  • GOFLAGS=-parallel=4
make stressrace TESTS=TestDataDriven PKG=./pkg/kv/kvserver/tenantrate TESTTIMEOUT=5m STRESSFLAGS='-timeout 5m' 2>&1

See this test on roachdash
powered by pkg/cmd/internal/issues

@knz
Copy link
Contributor

knz commented Aug 31, 2020

Still failing under stress.

cc @tbg @nvanbenschoten for triage.

@knz knz assigned knz and unassigned ajwerner Aug 31, 2020
@knz knz removed their assignment Aug 31, 2020
craig bot pushed a commit that referenced this issue Aug 31, 2020
53661: kvserver/tenantrate: fix flakey test r=nvanbenschoten a=ajwerner

This test was broken in #53510 which augmented the limiter machinery to
deal with read and write requests independently. The problem is that the
timer machinery works to synchronize the first blocked request but not
subsequent requests. That leaves the test-writer with no fundamental
means to ensure that subsequent blocked commands synchronize with a
metrics command. This lack of synchronization on metrics was a pain-point
when writing the original tests and led to excessive use of timers as
synchronization. Rather than trying to add excess synchronization, this
commit just adds a succeeds soon around the metrics. This works well.

Fixes #53590

Release justification: non-production code changes

Release note: None

Co-authored-by: Andrew Werner <[email protected]>
@craig craig bot closed this as completed in 224e5e5 Aug 31, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
branch-master Failures and bugs on the master branch. C-test-failure Broken test (automatically or manually discovered). O-robot Originated from a bot.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants