Pekka Enberg
0d77615b80
cql3: Filter compaction strategy class from compaction options
...
Cassandra 2.x does not store the compaction strategy class in compaction
options so neither should we to avoid confusing the drivers.
Fixes #1538 .
Message-Id: <1470722615-29106-1-git-send-email-penberg@scylladb.com >
(cherry picked from commit 9ff242d339 )
2016-08-10 12:44:50 +03:00
Vlad Zolotarov
baa6496816
service::storage_proxy: READ instrumentation: store trace state object in abstract_read_executor
...
Having a trace_state_ptr in the storage_proxy level is needed to trace code bits in this level.
Signed-off-by: Vlad Zolotarov <vladz@cloudius-systems.com >
2016-07-19 18:21:59 +03:00
Vlad Zolotarov
962bddf8fe
transport: CQL tracing: instrument a BATCH command
...
Signed-off-by: Vlad Zolotarov <vladz@cloudius-systems.com >
2016-07-19 18:21:58 +03:00
Vlad Zolotarov
1f9b858d83
cql3: prepared_statement: add raw_cql_statement field
...
This field will contain an original statement given to a PREPARE
command.
Signed-off-by: Vlad Zolotarov <vladz@cloudius-systems.com >
2016-07-19 18:21:58 +03:00
Vlad Zolotarov
4c16df9e4c
service: instrument MUTATE flow with tracing
...
Store the trace state in the abstract_write_response_handler.
Instrument send_mutation RPC to receive an additional
rpc::optional parameter that will contain optional<trace_info>
value.
Signed-off-by: Vlad Zolotarov <vladz@cloudius-systems.com >
2016-07-19 18:21:58 +03:00
Vlad Zolotarov
54a758dfff
cql3::select_statement: simplify the tracing code by using a tracing::make_trace_info() helper
...
Signed-off-by: Vlad Zolotarov <vladz@cloudius-systems.com >
2016-07-19 18:21:58 +03:00
Vlad Zolotarov
a5022a09a4
tracing: use 'write' instead of 'flush' and 'store' for consistency with seastar's API
...
In names of functions and variables:
s/flush_/write_/
s/store_/write_/
In a i_tracing_backend_helper:
s/flush()/kick()/
Signed-off-by: Vlad Zolotarov <vladz@cloudius-systems.com >
2016-07-19 18:21:57 +03:00
Tomasz Grabiec
7328a8eff8
cql: modification_statement: Avoid copying keyspace and table names
...
Message-Id: <1468574135-4701-1-git-send-email-tgrabiec@scylladb.com >
2016-07-15 10:36:53 +01:00
Duarte Nunes
f013425bb5
query: Ensure timestamp is last param in read_command
...
Since the timestamp is not serialized, it must always be the last
parameter of query::read_command. This patch reorders it with the
partition_limit parameters and updates callers that specified a
timestamp argument.
Signed-off-by: Duarte Nunes <duarte@scylladb.com >
Message-Id: <1468312334-10623-1-git-send-email-duarte@scylladb.com >
2016-07-12 10:41:54 +01:00
Avi Kivity
7bd4b7ca63
cql3: split use_statement into raw and prepared variants
...
Rather than having one class fulfil both roles, have one class per role,
disentangling dependencies.
Message-Id: <1465053407-20931-1-git-send-email-avi@scylladb.com >
2016-06-08 16:48:45 +03:00
Tomasz Grabiec
57413618e8
Merge branch 'range-tombstone-v9' from https://github.com/duarten/scylla.git
...
From Duarte:
This patchset adds the range_tombstone_list data structure,
used to hold a set of disjoint range tombstones, and changes
the internal representation of row tombstones to use that
data structure.
Fixes #1155
[tgrabiec: Added compound_wrapper::make_empty(const schema&) overload
to fix compilation failure in tracing code]
2016-06-02 22:17:17 +02:00
Duarte Nunes
91aac30f12
mutations: Row tombstones are now a set of ranges
...
This patch changes the type of the mutation partition's row_tombstones
to be a range_tombstone_list, so that they are now represented as a
set of disjoint ranges. All of its usages are updated accordingly.
Fixes #1155
Signed-off-by: Duarte Nunes <duarte@scylladb.com >
2016-06-02 16:21:59 +02:00
Pekka Enberg
f64c25a495
cql3/statements/select_statement: Unify coding style
...
The coding style in select_statement.cc is very inconsistent which makes
the code hard to read. Clean that up.
Message-Id: <1464871790-21031-1-git-send-email-penberg@scylladb.com >
2016-06-02 16:17:21 +02:00
Vlad Zolotarov
4c17a422e0
cql3: instrument a SELECT query to send tracing info
...
Instrument a coordinator of a SELECT query to send tracing session
info to the corresponding replica Nodes.
Signed-off-by: Vlad Zolotarov <vladz@cloudius-systems.com >
2016-06-01 20:17:25 +03:00
Vlad Zolotarov
6e26909b02
query::read_command: add an optional trace_info field
...
Signed-off-by: Vlad Zolotarov <vladz@cloudius-systems.com >
2016-06-01 20:17:19 +03:00
Avi Kivity
c8b5104aa5
cql3: extract raw batch_statement into raw sub-namespace
...
prepare() was moved to .cc to avoid circular dependencies.
2016-05-31 21:41:26 +03:00
Avi Kivity
1d144699f6
cql3: extract raw delete_statement into raw sub-namespace
2016-05-31 21:24:56 +03:00
Avi Kivity
e596799962
cql3: extract raw update_statement into raw sub-namespace
...
update_statment also has an insert_statement counterpart, convert it too.
2016-05-31 21:16:53 +03:00
Avi Kivity
10213c4211
cql3: extract raw modification_statement into raw sub-namespace
2016-05-31 20:53:37 +03:00
Avi Kivity
0135b4d5cd
cql3: constify metadata users
...
Metadata usually doesn't change after it is created; make that visible in
the code, allowing further optimizations to be applied later.
Message-Id: <1464334638-7971-3-git-send-email-avi@scylladb.com >
2016-05-31 09:12:11 +03:00
Avi Kivity
6728454591
cql3: rationalize extract_result_metadata()
...
Rather than dynamic_cast<>ing the statement to see whether it is a
select statement, add a virtual function to cql_statement to get the
result metadata.
This is faster and easier to follow.
Message-Id: <1464334638-7971-2-git-send-email-avi@scylladb.com >
2016-05-31 09:12:02 +03:00
Avi Kivity
25b3d74f45
cql3: Split select_statement::raw_statement into raw namespace
...
cql3::select_statement::raw_statement
-> cql3::raw::select_statement
Message-Id: <1464609556-3756-4-git-send-email-avi@scylladb.com >
2016-05-31 09:09:30 +03:00
Avi Kivity
c8f98c5981
cql3: move cf_statement into raw hierarchy
...
cql3::statements::cf_statement
-> cql3::statements::raw::cf_statement
Message-Id: <1464609556-3756-3-git-send-email-avi@scylladb.com >
2016-05-31 09:09:21 +03:00
Avi Kivity
caf8d4f0e6
cql3: separate parsed_statement and parsed_statment::prepared
...
cql3::statements::parsed_statement
-> cql3::statements::raw::parsed_statement
cql3::statements::parsed_statement::prepared
-> cql3::statements::prepared_statement
Message-Id: <1464609556-3756-2-git-send-email-avi@scylladb.com >
2016-05-31 09:09:10 +03:00
Gleb Natapov
7f6b12c97a
query: add user provided timestamp to read_command
...
If read query supplies timestamp move it to read_command to be
used later otherwise get local timestamp.
2016-05-24 15:19:35 +03:00
Calle Wilund
152bd82a05
alter_keyspace_statement: Handle missing replication strategy
...
ALTER KEYSPACE should allow no replication strategy to be set,
in which case old strategy should be kept.
Initial translation from origin missed this.
Fixes #1256
Message-Id: <1462967584-2875-2-git-send-email-calle@scylladb.com >
2016-05-11 16:02:22 +03:00
Calle Wilund
5604fb8aa3
cql3::statements::cf_prop_defs: Fix compation min/max not handled
...
Property parsing code was looking at wrong property level
for initial guard statement.
Fixes #1257
Message-Id: <1462967584-2875-1-git-send-email-calle@scylladb.com >
2016-05-11 16:02:16 +03:00
Calle Wilund
5c36d2e09e
alter_keyspace_statement: Implement
...
Note: Like create keyspace, we don't properly validate
replication strategy yet.
2016-05-10 14:36:17 +00:00
Pekka Enberg
7af9ac2880
Merge "Add support for User Defined Types" from Duarte
...
"This patchset enables support for user defined types,
completing the functionality that was already in place.
Fixes #426 "
2016-04-20 21:26:03 +03:00
Duarte Nunes
fbf70e9bed
udt: Add alter type statement
...
Signed-off-by: Duarte Nunes <duarte@scylladb.com >
2016-04-20 18:07:07 +02:00
Duarte Nunes
809b45e160
udt: Add drop type statement
...
Signed-off-by: Duarte Nunes <duarte@scylladb.com >
2016-04-20 18:07:02 +02:00
Calle Wilund
7f85373e15
cql3/drop_table_statement: Fix exception handling in access check
...
Tried to handle possibly benign exception in continuation, but
this is always thrown synchronously.
Fixes ttl_test dtest failures.
Message-Id: <1461154499-10674-1-git-send-email-calle@scylladb.com >
2016-04-20 15:49:04 +03:00
Duarte Nunes
35a88b5d49
udt: Complete create_type_statement
...
Signed-off-by: Duarte Nunes <duarte@scylladb.com >
2016-04-20 09:54:06 +02:00
Calle Wilund
3b101c6e19
cql3::statements::drop_user_statement: Drop all permissions for user
2016-04-19 11:49:06 +00:00
Calle Wilund
14cc47d8b9
cql3::statements::revoke_statement: Initial conversion
2016-04-19 11:49:06 +00:00
Calle Wilund
4e1ef3c1bc
cql3::statements::grant_statement: Initial conversion
2016-04-19 11:49:05 +00:00
Calle Wilund
04c37def3a
cql3::statements::list_permissions_statement: Initial conversion
2016-04-19 11:49:05 +00:00
Calle Wilund
fe23447f6f
cql3::statements::permission_altering_statement: Inital conversion
...
Alter permission base typ
2016-04-19 11:49:05 +00:00
Calle Wilund
add2111c0a
cql3::statements::authorizarion_statement: Initial conversion
...
Auth cql base type
2016-04-19 11:49:05 +00:00
Calle Wilund
3906dc9f0d
cql3::statements: Change check_access to future<> + implement
2016-04-19 11:49:05 +00:00
Calle Wilund
b8bd77e621
cql3::list_users_statement: Initial conversion
2016-04-11 09:10:41 +00:00
Calle Wilund
adaf21403b
cql3::drop_user_statement: Initial conversion
2016-04-11 09:10:41 +00:00
Calle Wilund
8732b3eed7
cql3::alter_user_statement: Initial conversion
2016-04-11 09:10:41 +00:00
Calle Wilund
da89189308
cql3::create_user_statement: Initial conversion
2016-04-11 09:10:41 +00:00
Calle Wilund
57f5bb854f
cql3::authentication_statement: cql auth base class
2016-04-11 09:10:41 +00:00
Pekka Enberg
38a54df863
Fix pre-ScyllaDB copyright statements
...
People keep tripping over the old copyrights and copy-pasting them to
new files. Search and replace "Cloudius Systems" with "ScyllaDB".
Message-Id: <1460013664-25966-1-git-send-email-penberg@scylladb.com >
2016-04-08 08:12:47 +03:00
Avi Kivity
6a3cf4ac41
cql: unlock ALTER TABLE syntax
...
It was marked experimental for 1.0, but will be fully supported in the
next release.
Message-Id: <1459707946-5860-1-git-send-email-avi@scylladb.com >
2016-04-04 11:36:11 +03:00
Tomasz Grabiec
5f44afa311
cql3: batch_statement: Execute statements sequentially
...
Currently we execute all statements in parallel, but some statements
depend on order, in particular list append/prepend. Fix by executing
sequentially.
Fixes cql_additional_tests.py:TestCQL.batch_and_list_test dtest.
Fixes #1075 .
Message-Id: <1458672874-4749-1-git-send-email-tgrabiec@scylladb.com >
2016-03-22 20:59:40 +02:00
Tomasz Grabiec
c518e852ee
modificiation_statement: Use result_view::do_with()
...
Reduces code duplication.
Message-Id: <1458336592-22065-1-git-send-email-tgrabiec@scylladb.com >
2016-03-20 15:14:28 +02:00
Tomasz Grabiec
b42d3a90b3
cql3: create_table_statement: Sort _defined_names by text
...
Currently they are sorted by address in memory, which breaks the
check for column name duplicates, which assumes sorting by text.
Fixes #975 .
Message-Id: <1456937400-20475-1-git-send-email-tgrabiec@scylladb.com >
2016-03-02 18:53:43 +02:00