cassandra-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From kaveh minooie <ka...@plutoz.com>
Subject Re: need help with triggers
Date Mon, 28 Oct 2013 21:20:27 GMT
I know that, but in all the example that I have seen online, they are 
getting an object of actuall 'ColumnFamily'. I was wondering why I am 
getting a UsortedClumns instead of ColumnFamily.

and thanks for pointing out column iterator to me. that is gonna be 
usefull ;)


On 10/28/2013 01:28 PM, Jonathan Ellis wrote:
> UnsortedColumns is a subclass of CF that only supports iterating
> through the cells, not random access.
>
> On Mon, Oct 28, 2013 at 2:36 PM, kaveh minooie <kaveh@plutoz.com> wrote:
>> Hi
>>
>> I am not sure if, stricly speaking, this is a dev list issue, but i figured
>> I would probably have a better chance here than user list. I am using
>> cassandra 2.0.1 and I am trying to write a trigger, but I am having an
>> issue. in the augment function:
>>
>> public Collection<RowMutation> augment(ByteBuffer key, ColumnFamily update)
>>
>> the instance that I get in variable 'update' is of type
>> 'org.apache.cassandra.db.UnsortedColumns' instead of type ColumnFamily which
>> does not support lots of method that exist in ColumnFamily including:
>>
>> public Column getColumn(ByteBuffer name)
>>      {
>>          throw new UnsupportedOperationException();
>>      }
>>
>> Now what I want to know is, first of all, why I am getting an
>> unsortedColumns instead of ColumnFamily? and how I can access my columns
>> from this class anyway?
>>
>> the CF that I am running this trigger on is created using CQL3.
>>
>> thanks,
>> --
>> Kaveh Minooie
>
>
>

-- 
Kaveh Minooie

Mime
View raw message