You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cassandra.apache.org by "Sylvain Lebresne (JIRA)" <ji...@apache.org> on 2016/09/01 08:26:20 UTC

[jira] [Commented] (CASSANDRA-12572) CQL query size bound to 64Kb

    [ https://issues.apache.org/jira/browse/CASSANDRA-12572?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15454750#comment-15454750 ] 

Sylvain Lebresne commented on CASSANDRA-12572:
----------------------------------------------

bq. Is this in reference to the check in {{RowFilter.Expression#validateForIndexing()}}?

If it is, that's a completely different problem than what the description and title suggests. What this method do is limit the size for indexed values. This does *not* mean the full query is limited to 64K as a whole, and this isn't related to the query text at all.

This only just mean a value (it's binary representation) that is indexed must not be bigger than 64kb. And that limit is due to the fact that for (internal) 2ndary indexes, that index value will be a partition key in the internal index table and the storage engine has a limit of 64kb for those. We can't change that without changes to the storage engine.

I will note that this is really a limitation of internal indexes, but that in 2.x, the limit seems to be blindly enforced whenever there is an index, even a custom one, which is not necessary. That being said, it looks this has been fixed in 3.0 with the refactor of the 2ndary index API and it's now only validated for internal indexes (to be precise, the check is performed in {{CassandraIndex.java}}, which is only for internal index. The check also indeed exists in {{RowFilter.Expression#validateForIndexing()}} *but* that method is never called (and is marked {{\@Deprecated}} so I assume it's some old stuff)).

So theoretically we could lift the limit for custom indexes in 2.x releases, but as this has been there forever this would really be more of an improvement while we're only committing critical bug fixes in those release. So I'm going to close this ticket based on that reasoning. Feel free to reopen if you feel I'm missed something here.

> CQL query size bound to 64Kb
> ----------------------------
>
>                 Key: CASSANDRA-12572
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-12572
>             Project: Cassandra
>          Issue Type: Improvement
>          Components: Core
>         Environment: Cassandra 2.1.14.1346 
> Cassandra 3.0.8.1284
>            Reporter: Jose Martinez Poblete
>            Priority: Minor
>
> Currently, a query is bound to a 64Kb text limit
> In some edge scenarios, the query text could go over that limit
> Can we make that a configurable parameter?



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)