Skip to content

Commit

Permalink
test: add isolation level requirement message to tracing tests
Browse files Browse the repository at this point in the history
Alternator tracing tests require the cluster to have the 'always'
isolation level configured to work properly. If that's not the case,
the tests will fail due to not having CAS-related traces present
in the logs. In order to help the users fix their configuration,
a helper message is printed before the test case is performed.
Automatic tests do not need this, because they are all ran with
matching isolation level, but this message could greatly improve
the user experience for manual tests.
Message-Id: <62bcbf60e674f57a55c9573852b6a28f99cbf408.1607949754.git.sarna@scylladb.com>
  • Loading branch information
psarna authored and nyh committed Dec 14, 2020
1 parent 4b0303d commit 7081e36
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions test/alternator/test_tracing.py
Original file line number Diff line number Diff line change
Expand Up @@ -188,6 +188,8 @@ def test_tracing_all(with_tracing, test_table_s, dynamodb):

# Check the traces. NOTE: the following checks are fairly arbitrary, and
# may break in the future if we change the tracing messages...
print("If you see CAS failures here, please check if your alternator cluster is configured"
" to have write isolation level 'always'. Otherwise, CAS operations will not be present in the traces.")
expect_tracing_events(dynamodb, p_putitem, ['PutItem', 'CAS successful'])
expect_tracing_events(dynamodb, p_getitem, ['GetItem', 'Querying is done'])
expect_tracing_events(dynamodb, p_deleteitem, ['DeleteItem', 'CAS successful'])
Expand Down

0 comments on commit 7081e36

Please sign in to comment.