[ https://issues.apache.org/jira/browse/CASSANDRA-11990?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15413135#comment-15413135 ]
Pavel Yaskevich commented on CASSANDRA-11990: --------------------------------------------- bq. Sure, this was already done: CASSANDRA-12374 and CASSANDRA-12378. The branch you have in the previous comment still have all of the change from dropping/rebuilding of the indexes. bq. As far as I understood, SASI relies heavily on the fact that the tokens are fixed size... Yes, and that's exactly my point, let's keep it that way - relying that index has *fixed-size long tokens*. _If_ we were to keep all of the changes done to partitioner interface and TokenTreeSerializationHelper it would mean maintenance cost for no long term benefit, because once we go full featured variable size tokens all of the changes done to partitioner interface are going to be no longer required (will have to be removed), because index shouldn't care (at that point) about how exactly are tokens serialized from it's point of view it's just going to be comparable blob of bytes and we can use existing token serialization and partitioner logic to deal with that. bq. We can improve the situation with current abstraction by relying on the fact that Partitioner is a singleton in DatabaseDescriptor so higher level abstractions will never even see it. We shouldn't make such assumptions, because everything is already polluted by that as is, better option would be to get it from the keyspace which indexes are attached to and keep that info somewhere on the top level e.g. SASIndex plus push down specialized comparator implementation like what we do with KeyFetcher right now... bq. Rolling back everything will be a large chunk of work both now in order to undo it (in combination with all test changes and original PR changes) and re-introducing it shortly when we do RP (or any other partitioner) support. Now imagine how much more work would that be to undo that in the future? I'm not comfortable committing code just because it's hard to get out from the patch. RP is as good as dead currently and there no other viable partitioners, which are going to benefit from the changes, so it's much easier to stick with long tokens and get to variable-size in one hop instead of three. > Address rows rather than partitions in SASI > ------------------------------------------- > > Key: CASSANDRA-11990 > URL: https://issues.apache.org/jira/browse/CASSANDRA-11990 > Project: Cassandra > Issue Type: Improvement > Components: CQL, sasi > Reporter: Alex Petrov > Assignee: Alex Petrov > Attachments: perf.pdf, size_comparison.png > > > Currently, the lookup in SASI index would return the key position of the > partition. After the partition lookup, the rows are iterated and the > operators are applied in order to filter out ones that do not match. > bq. TokenTree which accepts variable size keys (such would enable different > partitioners, collections support, primary key indexing etc.), -- This message was sent by Atlassian JIRA (v6.3.4#6332)