cassandra-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Ivo Mei├čner <>
Subject Secondary index data gone after restart (1.1.1)
Date Tue, 26 Jun 2012 07:07:29 GMT

I am running into some problems with secondary indexes that I am unable to track down. When
I restart the cassandra service, the secondary index data won't load and I get the following
error during startup: 

INFO 08:29:42,127 Opening /var/myproject/cassandra/data/mykeyspace/group_admin/mykeyspace-group_admin.group_admin_groupId_idx-hd-1
(20808 bytes)
ERROR 08:29:42,159 Exception in thread Thread[SSTableBatchOpen:1,5,main]
java.lang.ClassCastException: java.math.BigInteger cannot be cast to java.nio.ByteBuffer
	at org.apache.cassandra.dht.LocalToken.compareTo(
	at org.apache.cassandra.db.DecoratedKey.compareTo(
	at org.apache.cassandra.db.DecoratedKey.compareTo(
	at java.util.TreeMap.getEntry(
	at java.util.TreeMap.containsKey(
	at java.util.TreeSet.contains(
	at java.util.concurrent.Executors$
	at java.util.concurrent.FutureTask$Sync.innerRun(
	at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(
	at java.util.concurrent.ThreadPoolExecutor$

When the service starts I can still select data from the column family, but not using the
secondary index. 
After I execute "nodetool rebuild_index" the secondary index works fine again until the next

The error only seems to occur on the column groupId (TimeUUIDType). The other index on userId
seems to work. 

I have the following column family definition: 

create column family group_admin with
  comparator = UTF8Type and
  key_validation_class = UTF8Type and
  column_metadata = [
    {column_name: id, validation_class: UTF8Type},
    {column_name: added, validation_class: LongType},
    {column_name: userId, validation_class: BytesType, index_type: KEYS},
    {column_name: requestMessage, validation_class: UTF8Type},
    {column_name: status, validation_class: LongType},
    {column_name: groupId, validation_class: TimeUUIDType, index_type: KEYS}

Thank you very much for your help!

View raw message