[
https://issues.apache.org/jira/browse/CASSANDRA-8375?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14349051#comment-14349051
]
Joshua McKenzie commented on CASSANDRA-8375:
--------------------------------------------
Unit test failure w/the patch:
{noformat}
[junit] Testcase:
testSuperColumnTombstones(org.apache.cassandra.db.compaction.CompactionsTest):
Caused an ERROR
[junit] org.apache.cassandra.db.BufferDecoratedKey cannot be cast to
org.apache.cassandra.dht.Token
[junit] java.lang.ClassCastException:
org.apache.cassandra.db.BufferDecoratedKey cannot be cast to
org.apache.cassandra.dht.Token
[junit] at org.apache.cassandra.dht.Range.makeRowRange(Range.java:465)
[junit] at
org.apache.cassandra.db.DataRange.forKeyRange(DataRange.java:73)
[junit] at
org.apache.cassandra.db.compaction.CompactionsTest.testSuperColumnTombstones(CompactionsTest.java:192)
{noformat}
> Cleanup of generics in bounds serialization
> -------------------------------------------
>
> Key: CASSANDRA-8375
> URL: https://issues.apache.org/jira/browse/CASSANDRA-8375
> Project: Cassandra
> Issue Type: Improvement
> Reporter: Branimir Lambov
> Assignee: Branimir Lambov
> Priority: Trivial
> Fix For: 3.0
>
> Attachments: 8375-v2.patch, 8375.patch
>
>
> There is currently a single serializer for {{AbstractBounds}} applied to both
> {{Token}} and {{RowPosition}} ranges and bounds. This serializer does not
> know which kind of bounds it needs to work with, which causes some
> necessarily unsafe conversions and needs extra code in all bounds types
> ({{toRowBounds}}/{{toTokenBounds}}) to make the conversions safe, the
> application of which can be easily forgotten.
> As all users of this serialization know in advance the kind of range they
> want to serialize, this can be replaced by simpler type-specific
> serialization.
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)