mirror of
https://github.com/scylladb/scylladb.git
synced 2026-06-05 14:33:08 +00:00
The CDC feature is not supported on a table that uses tablets (Refs https://github.com/scylladb/scylladb/issues/16317), so if a user creates a keyspace with tablets enabled they may be surprised later (perhaps much later) when they try to enable CDC on the table and can't. The LWT feature always had issue Refs https://github.com/scylladb/scylladb/issues/5251, but it has become potentially more common with tablets. So it was proposed that as long as we have missing features (like CDC or LWT), every time a keyspace is created with tablets it should output a warning (a bona-fide CQL warning, not a log message) that some features are missing, and if you need them you should consider re-creating the keyspace without tablets. This PR does this. The warning text which will be produced is the following (obviously, it can be improved later, as we perhaps find more missing features): > "Tables in this keyspace will be replicated using tablets, and will > not support the CDC feature (issue https://github.com/scylladb/scylladb/issues/16317) and LWT may suffer from > issue https://github.com/scylladb/scylladb/issues/5251 more often. If you want to use CDC or LWT, please drop > this keyspace and re-create it without tablets, by adding AND TABLETS > = {'enabled': false} to the CREATE KEYSPACE statement." This PR also includes a test - that checks that this warning is is indeed generated when a keyspace is created with tablets (either by default or explicitly), and not generated if the keyspace is created without tablets. It also fixes existing tests which didn't like the new warning. Fixes https://github.com/scylladb/scylladb/issues/16807 Closes scylladb/scylladb#17318 * github.com:scylladb/scylladb: tablets: add warning on CREATE KEYSPACE test/cql-pytest: fix guadrail tests to not be sensitive to more warnings