Commit Graph

78 Commits

Author SHA1 Message Date
Sam Tunnicliffe ae0842372f Implementation of Transactional Cluster Metadata as described in CEP-21
An overview of the core components can be found in the included
TransactionalClusterMetadata.md

patch by Alex Petrov, Marcus Eriksson and Sam Tunnicliffe; reviewed by
Alex Petrov, Marcus Eriksson and Sam Tunnicliffe for CASSANDRA-18330

Co-authored-by: Marcus Eriksson <marcuse@apache.org>
Co-authored-by: Alex Petrov <oleksandr.petrov@gmail.com>
Co-authored-by: Sam Tunnicliffe <samt@apache.org>
2023-11-24 10:26:08 +00:00
Stefan Miklosovic 6a3bcc83d2
Merge branch 'cassandra-5.0' into trunk 2023-11-14 21:45:34 +01:00
Ethan Brown fb806d51e3
Add UCS sstable_growth and min_sstable_size options
patch by Ethan Brown; reviewed by Branimir Lambov, Stefan Miklosovic for CASSANDRA-18945
2023-11-14 21:41:07 +01:00
Andrés de la Peña e8c5fe31a2 Merge branch 'cassandra-5.0' into trunk 2023-10-25 12:15:26 +01:00
Andrés de la Peña 5eba52feb8 Add cqlsh autocompletion for the vector data type
patch by Andrés de la Peña; reviewed by Brandon Williams for CASSANDRA-18946
2023-10-25 11:54:01 +01:00
Brad Schoening 60314f2d6a
Resolve deprecations in pylib
patch by Brad Schoening; reviewed by Stefan Miklosovic and Brandon Williams for CASSANDRA-18827
2023-09-27 20:42:15 +02:00
maoling 32cf1ea33d
Add ELAPSED command to cqlsh
patch by Ling Mao; reviewed by Stefan Miklosovic, Brandon Williams for CASSANDRA-18861

Co-authored-by: Stefan Miklosovic <smiklosovic@apache.org>
2023-09-27 19:37:06 +02:00
Shailaja Koppu 933137fb14 CIDR filtering authorizer
Patch by Shailaja Koppu, Yifan Cai; Reviewed by Dinesh Joshi, Yifan Cai for CASSANDRA-18592

Co-Authored-By: Yifan Cai <ycai@apache.org>
2023-07-28 20:10:02 -07:00
Brad Schoening 61333964f4
Add HISTORY command for CQLSH
patch by Brad Schoening; reviewed by Stefan Miklosovic and Brandon Williams for CASSANDRA-15046
2023-05-23 14:02:23 +02:00
Andrés de la Peña 2e2a49fcdc CEP-20: Dynamic Data Masking
Allows to attach the native masking functions and UDFs to the definitions of
table columns in the schema, as defined by CEP-20.

The functions masking a column can be specified on CREATE TABLE queries, right
at the end of the column definition. The mask of a column can also be changed
or dropped with an ALTER TABLE query. Once a column is masked, SELECT queries
will always return the masked value of the column. That masking is done on the
coordinator, at the end of the query execution. Thus, masking won't affect any
filters or ordering, which would be based on the clear values of the masked
columns. Column masks are stored on the table system_schema.column_masks.

A new UNMASK permission allows to see the clear data of columns with an
attached mask. Also, a new SELECT_MASKED permission allows to run SELECT
queries restricting the clear values of masked columns. Superusers have both
permissions by default, whereas regular users don't have them.

Dynamic data masking can be enabled/disabled with the config property
dynamic_data_masking_enabled in cassandra.yaml. It is disabled by default.

This is the combination of multiple tickets:

 * Add masking functions to column metadata (CASSANDRA-18068)
 * Add UNMASK permission (CASSANDRA-18069)
 * Add SELECT_MASKED permission (CASSANDRA-18070)
 * Add support for using UDFs as masking functions (CASSANDRA-18071)
 * Add feature flag for dynamic data masking (CASSANDRA-18316)

patch by Andrés de la Peña; reviewed by Benjamin Lerer and Berenguer Blasi for CASSANDRA-17940
2023-03-24 13:57:18 +00:00
Stefan Miklosovic 58a3b12508
Remove DateTieredCompactionStrategy
patch by Stefan Miklosovic; reviewed by Jacek Lewandowski for CASSANDRA-18043
2023-03-16 09:38:10 +01:00
yziadeh 1528798a5b Add tests for CQL and cqlsh quote escaping
Patch by Yaman Ziadeh; Reviewed by Paulo Motta and Brandom Williams for CASSANDRA-15458
2023-01-17 15:27:51 -05:00
maxwellguo ee8b66da8c Make incremental backup configurable per table
patch by Maxwell Guo; reviewed by Stefan Miklosovic and Benjamin Lerer for CASSANDRA-15402
2022-11-19 10:57:54 +01:00
Brad Schoening addc5748a7 Add missing cqlsh completion and round out cqlsh completion test coverage
IF (NOT) EXISTS is now also offered in cqlsh completion for CREATE TYPE, DROP TYPE, CREATE ROLE and DROP ROLE

patch by Brad Schoening; reviewed by Stefan Miklosovic and Brandon Williams for CASSANDRA-16640
2022-11-07 18:00:53 +01:00
Stefan Miklosovic c71f04bd5b Add memtable option among possible tab completions for a table
patch by Stefan Miklosovic; reviewed by Brandon Williams for CASSANDRA-17982
2022-10-21 22:34:33 +02:00
Stefan Miklosovic c4c4ad5cbc Merge branch 'cassandra-4.1' into trunk 2022-10-04 20:38:01 +02:00
Stefan Miklosovic f0fd551c7c Merge branch 'cassandra-4.0' into cassandra-4.1 2022-10-03 16:27:45 +02:00
Stefan Miklosovic e9b411e3e0 Merge branch 'cassandra-3.11' into cassandra-4.0 2022-10-03 12:06:37 +02:00
Stefan Miklosovic ad6bca4ab5 Merge branch 'cassandra-3.0' into cassandra-3.11 2022-10-03 10:43:08 +02:00
Brad Schoening 83c1f7713b Fix auto-completing "WITH" when creating a materialized view (CASSANDRA-17879)
patch by Brad Schoening; reviewed by Stefan Miklosovic and Brandon Williams for CASSANDRA-17879
2022-10-03 10:35:38 +02:00
Stefan Miklosovic b6d8e2ce6b Make disabling auto snapshot on selected tables possible
patch by Tommy Stendahl; reviewed by Stefan Miklosovic and Aleksey Yeschenko for CASSANDRA-10383

Co-authored-by: Tommy Stendahl <tommy.stendahl@ericsson.com>
Co-authored-by: Stefan Miklosovic <smiklosovic@apache.org>
2022-09-08 10:25:34 +02:00
ROCHETEAU Antoine d80bb323c9 CONTAINS and CONTAINS KEY support for Lightweight Transactions
patch by ROCHETEAU Antoine; reviewed by Benjamin Lerer, Berenguer Blasi for CASSANDRA-10537
2022-04-21 09:16:07 +02:00
Jogesh Anand e137c7c34c Add support for IF EXISTS and IF NOT EXISTS in ALTER statements
patch by Jogesh Anand; reviewed by Benjamin Lerer, Berenguer Blasi for CASSANDRA-16916
2022-04-04 11:35:16 +02:00
Brad Schoening 27ab63f005 remove unused imports in cqlsh.py and cqlshlib
patch by Brad Schoening; reviewed by Stefan Miklosovic and Brandon Williams for CASSANDRA-17413
2022-03-08 09:34:23 +01:00
Brad Schoening db35833182 update Python test framework from nose to pytest
patch by Brad Schoening; reviewed by Brandon Williams, Berenguer Blasi and Stefan Miklosovic for CASSANDRA-17293
2022-02-20 17:32:11 +01:00
Aleksei Zotov c3d51a825c Merge branch 'cassandra-3.0' into cassandra-3.11 2022-02-19 13:20:04 +04:00
Aleksei Zotov d17b16c9b1 Fix flaky test - test_cqlsh_completion.TestCqlshCompletion
Patch by Aleksei Zotov; reviewed by Brandon Williams for CASSANDRA-17338
2022-02-19 13:18:38 +04:00
Stefan Miklosovic da47849b50 Remove Windows-specific classes and related code
patch by Stefan Miklosovic; reviewed by Joshua McKenzie, Bowen Song, Berenguer Blasi for CASSANDRA-16956
2022-02-05 15:41:33 +01:00
Francisco Guerrero 185893256f Allow GRANT/REVOKE multiple permissions in a single statement
patch by Francisco Guerrero; reviewed by Benjamin Lerer and Yifan Cai for CASSANDRA-17030

This commit allows GRANT/REVOKE statement to support multiple permissions with a single
statement. For example,

```
GRANT MODIFY, SELECT ON KEYSPACE field TO manager;
GRANT ALTER, DROP ON ROLE role1 TO role2;
```
2021-10-22 14:34:04 +02:00
Benjamin Lerer df6ecaae1c Allow to grant permission for all tables in a keyspace
Patch by Benjamin Lerer; Review by Andres de la Peña and Ekaterina Dimitrova for CASSANDRA-17027

In some cases it is useful to prevent users to alter or drop a keyspace
while allowing them to create new tables.
This patch add support for a new DataResource below KEYSPACE but above
TABLE. The syntax to grant permission at this level in ALL TABLES IN
KEYSPACE.
2021-10-20 14:09:02 +02:00
Adam Holmberg 0301fc6cea cqlsh: fix DESC TYPE with non-ascii character in the identifier
Patch by Adam Holmberg; reviewed by brandonwilliams for CASSANDRA-16400
2021-05-17 14:54:58 -05:00
Brandon Williams a3db11831a Revert "Fix cqlsh DESC TYPE with non-ascii character in the identifier"
This reverts commit 327d7c1803.
2021-05-05 07:21:53 -05:00
Adam Holmberg 327d7c1803 Fix cqlsh DESC TYPE with non-ascii character in the identifier
Patch by Adam Holmberg; reviewed by brandonwilliams for CASSANDRA-16400
2021-05-04 11:52:23 -05:00
Brandon Williams 288bb9d902 Fix cqlsh encoding error with unicode in multi-line statement
Patch by Adam Holmberg; reviewed by brandonwilliams for CASSANDRA-16539
2021-05-04 08:45:26 -05:00
Adam Holmberg 132c01e570 generate keyspace names internally instead of abusing tempfile
Patch by Adam Holmberg; reviewed by brandonwilliams for CASSANDRA-16639
2021-04-28 15:19:47 -05:00
Marcus Eriksson 1d24c7cf49 Merge branch 'cassandra-3.11' into trunk 2021-04-13 10:52:21 +02:00
Brian Houser 7152d40bb3 Add autocomplete, errors for provide_overlapping_tombstones
Patch by Brian Houser; reviewed by marcuse for CASSANDRA-16350
2021-04-13 10:49:31 +02:00
jacek-lewandowski 91cb934e25
In cqlshlib tests, don't overwrite the environment and improve hostname matching
patch by Jacek Lewandowski; reviewed by Mick Semb Wever for CASSANDRA-16409
2021-01-28 12:56:39 +01:00
Eduard Tudenhoefner 39a0703b65 Mark system_views/system_virtual_schema as non-alterable keyspaces in cqlsh
patch by Eduard Tudenhoefner; reviewed by Benjamin Lerer for
CASSANDRA-15711
2020-04-09 16:53:22 +02:00
Patrick Bannister bf9a1d487b Make cqlsh and cqlshlib Python 2 & 3 compatible
Patch by Patrick Bannister; reviewed by Dinesh Joshi, Andy Tolbert and David Capwell for CASSANDRA-10190
2020-02-14 10:33:57 -08:00
Sam Tunnicliffe 0388d89e29 Allow max protocol version to be capped
Patch by Sam Tunnicliffe; reviewed by Alex Petrov and Aleksey
Yeschenko for CASSANDRA-15193
2019-10-08 18:09:52 +01:00
Ariel Weisberg 4ae229f5cd Upgrade to 4.0 fails with NullPointerException
Patch by Ariel Weisberg; Reviewed by Dinesh Joshi for CASSANDRA-14820
2018-10-16 18:47:40 -04:00
Ariel Weisberg f7431b4328 Transient Replication and Cheap Quorums
Patch by Blake Eggleston, Benedict Elliott Smith, Marcus Eriksson, Alex Petrov, Ariel Weisberg; Reviewed by Blake Eggleston, Marcus Eriksson, Benedict Elliott Smith, Alex Petrov, Ariel Weisberg for CASSANDRA-14404

Co-authored-by: Blake Eggleston <bdeggleston@gmail.com>
Co-authored-by: Benedict Elliott Smith <benedict@apache.org>
Co-authored-by: Marcus Eriksson <marcuse@apache.org>
Co-authored-by: Alex Petrov <oleksandr.petrov@gmail.com>
2018-08-31 21:34:22 -04:00
Aleksey Yeshchenko 2fcd29b830 Eliminate background repair and probablistic read_repair_chance table options
patch by Aleksey Yeschenko; reviewed by Blake Eggleston for
CASSANDRA-13910
2018-04-18 11:41:17 +01:00
Sylvain Lebresne 4881d9c308 Thrift removal
patch by Sylvain Lebresne; reviewed by Aleksey Yeschenko for CASSANDRA-11115
2016-12-13 10:27:12 +01:00
Tyler Hobbs cc582855ea Ninja: update cqlsh completion tests for CASSANDRA-8844
In CASSANDRA-8844, a new 'cdc' table option was added.  The python
driver added this as a recognized option, which caused it to show up in
cqlsh autocomplete suggestions.  However, the cqlsh tests were not
updated to match this.

This should fix the following failing tests:
 - test_complete_in_create_table
 - test_complete_in_create_columnfamily
2016-07-19 14:40:55 -05:00
Yusuke Takata 74647a8cc5 cqlsh does not automatically downgrade CQL version
patch by Yusuke Takata and Stefania Alborghetti;
reviewed by Stefania Alborghetti and Tyler Hobbs for CASSANDRA-12150
2016-07-13 10:00:21 +08:00
Marcus Eriksson 8ef1e2ce25 Merge branch 'cassandra-3.0' into trunk 2016-06-07 07:45:10 +02:00
Jeff Jirsa 6c867f0030 Add TimeWindowCompactionStrategy
Patch by Jeff Jirsa; reviewed by marcuse for CASSANDRA-9666
2016-06-07 07:38:22 +02:00
Tyler Hobbs 677230df69 Support for non-frozen UDTS
Patch by Tyler Hobbs; reviewed by Benjamin Lerer for CASSANDRA-7423
2016-04-08 15:26:12 -05:00