Skip to content

Conversation

@jul-stas
Copy link

When integration test gets constructed, it can set global cb_ and
data_ to temporaries. After the test finishes and temporaries are
destroyed, the next tests ctor may try to refer to them (before it
sets the globals by itself).

This happened in the ctor of Random, which logged a message in
case of failure. Sometimes this manifested as segfault, sometimes
as a deadlock. This fix restores the old logger values on test teardown -

  • most likely to stderr.

Fixes #13

@jul-stas jul-stas requested a review from kbr- December 15, 2020 14:30
When integration test gets constructed, it can set global `cb_` and
`data_` to temporaries. After the test finishes and temporaries are
destroyed, the next tests ctor may try to refer to them (before it
sets the globals by itself).

This happened in the ctor of `Random`, which logged a message in
case of failure. Sometimes this manifested as segfault, sometimes
as a deadlock.

This fix restores the old logger values on test teardown - most
likely to stderr.

Fixes datastax#13
@jul-stas jul-stas force-pushed the integ-tests-correct-fix branch from 65385e7 to e7d1193 Compare December 15, 2020 14:56
@jul-stas jul-stas merged commit 5183cf0 into scylladb:master Dec 15, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

cassandra-integration-tests stuck without any output

2 participants