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

TestSingleKey: no txn persisted, yet intent has heartbeat #2111

Closed
tbg opened this issue Aug 14, 2015 · 3 comments
Closed

TestSingleKey: no txn persisted, yet intent has heartbeat #2111

tbg opened this issue Aug 14, 2015 · 3 comments
Labels
C-test-failure Broken test (automatically or manually discovered). E-easy Easy issue to tackle, requires little or no CockroachDB experience help wanted Help is requested / needed by the one who filed the issue to fix it.

Comments

@tbg
Copy link
Member

tbg commented Aug 14, 2015

The following test appears to have failed:

#5940:

=== RUN TestPut
--- PASS: TestPut (22.56s)
=== RUN TestRangeReplication
--- PASS: TestRangeReplication (12.07s)
=== RUN TestSingleKey
--- FAIL: TestSingleKey (19.64s)
    single_key_test.go:125: txn "acceptance/single_key_test.go:101 func·008" id=d508bfcc key="test-key" rw=false pri=87.92241271 iso=SERIALIZABLE stat=PENDING epo=1 ts=1439565620.755168676,2 orig=1439565620.742974281,0 max=1439565620.992974043,0: no txn persisted, yet intent has heartbeat
=== RUN TestStatusServer
--- PASS: TestStatusServer (18.48s)
FAIL
ok github.com/cockroachdb/cockroach/acceptance 1337s

Please assign, take a look and update the issue accordingly.

@tbg tbg added the C-test-failure Broken test (automatically or manually discovered). label Aug 14, 2015
@tbg tbg changed the title Test failure in CI build 5940 TestSingleKey: no txn persisted, yet intent has heartbeat Aug 14, 2015
@tbg
Copy link
Member Author

tbg commented Aug 14, 2015

A Push finds no txn entry in the table, but the intent's Txn has a heartbeat. That likely means that the txn entry was auto-gc'ed, but it didn't commit in one round-trip, so that a concurrent actor had time to run into it and tries to push the transaction (which at that point had already been deleted).

From the above, I would suggest to just dismantle the check that triggered the above error.

@spencerkimball
Copy link
Member

Yes, that check is clearly no longer valid.

How can an actor which encounters an intent and is able to push the attached txn distinguish between the txn having been auto-committed (meaning the intent will have been concurrently cleaned up) vs. still pending (in which case the txn record should be written as either ABORTED or with a pushed timestamp)?

@tbg
Copy link
Member Author

tbg commented Aug 15, 2015

I'll post my reply in #2062 because it's relevant there.

@tbg tbg added help wanted Help is requested / needed by the one who filed the issue to fix it. E-easy Easy issue to tackle, requires little or no CockroachDB experience labels Aug 15, 2015
@tbg tbg closed this as completed in #2139 Aug 18, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
C-test-failure Broken test (automatically or manually discovered). E-easy Easy issue to tackle, requires little or no CockroachDB experience help wanted Help is requested / needed by the one who filed the issue to fix it.
Projects
None yet
Development

No branches or pull requests

2 participants