[
https://issues.apache.org/jira/browse/CASSANDRA-20237?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17916550#comment-17916550
]
Stefan Miklosovic commented on CASSANDRA-20237:
-----------------------------------------------
[CASSANDRA-20237|https://github.com/instaclustr/cassandra/tree/CASSANDRA-20237]
{noformat}
java17_pre-commit_tests
✓ j17_build 4m 8s
✓ j17_cqlsh_dtests_py311 7m 0s
✓ j17_cqlsh_dtests_py311_vnode 7m 25s
✓ j17_cqlsh_dtests_py38 6m 49s
✓ j17_cqlsh_dtests_py38_vnode 7m 8s
✓ j17_cqlshlib_cython_tests 10m 55s
✓ j17_cqlshlib_tests 7m 15s
✓ j17_jvm_dtests_latest_vnode 17m 19s
✓ j17_unit_tests 14m 18s
✓ j17_unit_tests_repeat 19m 46s
✓ j17_utests_latest_repeat 18m 33s
✓ j17_utests_oa 15m 28s
✓ j17_utests_oa_repeat 18m 43s
✕ j17_dtests 49m 59s
refresh_test.TestRefresh test_refresh_deadlock_startup
✕ j17_dtests_latest 41m 50s
read_repair_test.TestSpeculativeReadRepair test_speculative_write
✕ j17_dtests_vnode 43m 3s
counter_test.TestCounters test_counter_node_down
✕ j17_jvm_dtests 24m 51s
org.apache.cassandra.fuzz.ring.ConsistentBootstrapTest
coordinatorIsBehindTest
✕ j17_utests_latest 14m 32s
org.apache.cassandra.db.commitlog.CommitlogShutdownTest
testShutdownWithPendingTasks
{noformat}
[java17_pre-commit_tests|https://app.circleci.com/pipelines/github/instaclustr/cassandra/5268/workflows/9fb2429c-835d-47c8-adf9-650e13832ebe]
> Error on server side when trying to provide a TupleType to select on where
> target type is not a tuple.
> ------------------------------------------------------------------------------------------------------
>
> Key: CASSANDRA-20237
> URL: https://issues.apache.org/jira/browse/CASSANDRA-20237
> Project: Apache Cassandra
> Issue Type: Bug
> Components: CQL/Semantics, CQL/Syntax
> Reporter: Stefan Miklosovic
> Assignee: Stefan Miklosovic
> Priority: Normal
> Fix For: 5.x
>
> Time Spent: 40m
> Remaining Estimate: 0h
>
> I just found this by accident.
> {noformat}
> cassandra@cqlsh> select * from system_views.settings where name =
> ('authorizer.class_name', 'role_manager_class_name');
> NoHostAvailable: ('Unable to complete the operation against any hosts',
> {<Host: 127.0.0.1:9042 datacenter1>: <Error from server: code=0000 [Server
> error] message="java.lang.ClassCastException: class
> org.apache.cassandra.db.marshal.UTF8Type cannot be cast to class
> org.apache.cassandra.db.marshal.TupleType
> (org.apache.cassandra.db.marshal.UTF8Type and
> org.apache.cassandra.db.marshal.TupleType are in unnamed module of loader
> 'app')">})
> {noformat}
> Then on server side:
> {noformat}
> ERROR [Native-Transport-Requests-1] 2025-01-22 13:09:22,865
> QueryMessage.java:130 - Unexpected error during query
> java.lang.ClassCastException: class org.apache.cassandra.db.marshal.UTF8Type
> cannot be cast to class org.apache.cassandra.db.marshal.TupleType
> (org.apache.cassandra.db.marshal.UTF8Type and
> org.apache.cassandra.db.marshal.TupleType are in unnamed module of loader
> 'app')
> at org.apache.cassandra.cql3.terms.Tuples.getTupleType(Tuples.java:230)
> at
> org.apache.cassandra.cql3.terms.Tuples$Literal.prepare(Tuples.java:71)
> at org.apache.cassandra.cql3.terms.Terms$Raw$3.prepare(Terms.java:365)
> at org.apache.cassandra.cql3.Relation.toRestriction(Relation.java:216)
> at
> org.apache.cassandra.cql3.restrictions.StatementRestrictions.<init>(StatementRestrictions.java:218)
> at
> org.apache.cassandra.cql3.restrictions.StatementRestrictions.<init>(StatementRestrictions.java:157)
> at
> org.apache.cassandra.cql3.statements.SelectStatement$RawStatement.prepareRestrictions(SelectStatement.java:1353)
> at
> org.apache.cassandra.cql3.statements.SelectStatement$RawStatement.prepare(SelectStatement.java:1198)
> at
> org.apache.cassandra.cql3.statements.SelectStatement$RawStatement.prepare(SelectStatement.java:1187)
> at
> org.apache.cassandra.cql3.statements.SelectStatement$RawStatement.prepare(SelectStatement.java:1159)
> at
> org.apache.cassandra.cql3.QueryProcessor.getStatement(QueryProcessor.java:900)
> at
> org.apache.cassandra.cql3.QueryProcessor.parse(QueryProcessor.java:357)
> at
> org.apache.cassandra.transport.messages.QueryMessage.execute(QueryMessage.java:116)
> {noformat}
> This does not seem to be a problem for other types like sets, maps or lists:
> {noformat}
> cassandra@cqlsh> select * from system_views.settings where name =
> {'authorizer.class_name', 'role_manager_class_name'};
> InvalidRequest: Error from server: code=2200 [Invalid query] message="Invalid
> set literal for name of type text"
> cassandra@cqlsh> select * from system_views.settings where name =
> ['authorizer.class_name', 'role_manager_class_name'];
> InvalidRequest: Error from server: code=2200 [Invalid query]
> message="Unexpected receiver type 'text'; only list and vector are expected"
> cassandra@cqlsh> select * from system_views.settings where name =
> {'authorizer.class_name': 'a', 'role_manager_class_name': 'b'};
> InvalidRequest: Error from server: code=2200 [Invalid query] message="Invalid
> map literal for name of type text"
> {noformat}
> I would expect that tuples would be treated the same way.
--
This message was sent by Atlassian Jira
(v8.20.10#820010)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]