incubator-cassandra-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Benjamin Black...@b3k.us>
Subject Re: Columns limit
Date Sat, 07 Aug 2010 01:16:14 GMT
Yes, it is common to create distinct CFs for indices.

On Fri, Aug 6, 2010 at 4:40 PM, Software Dev <static.void.dev@gmail.com> wrote:
>
> Thanks for the suggestion.
>
> I've somewhat understand all that, the point where my head begins to explode
> is when I want to figure out something like
>
> Continuing with your example: "Over the last X amount of days give me all
> the logs for remote_addr:XXX".
> I'm guessing I would need to create a separate index ColumnFamily???
>
> On Fri, Aug 6, 2010 at 4:32 PM, Thomas Heller <info@zilence.net> wrote:
>>
>> Howdy,
>>
>> thought I jump in here. I did something similar, meaning I had lots of
>> items coming in per day and wanted to somehow partition them to avoid
>> running into the column limit (it was also logging related). Solution
>> was pretty simple, log data is immutable, so no SuperColumn needed.
>>
>> ColumnFamily Standard: LogRecords, CompareWith=TimeUUIDType
>>
>> Row Key "20100806":
>>  Column Name: TimeUUID.new Value: JSON({'remote_addr':...,
>> 'user_agent':...., 'url':....)
>>  ..., more Columns
>>
>> In my case I chose to "partition" by day, if you are getting too many
>> columns per day, just get hours in there. If you want an extra
>> seperation level (foo, bar) in your example you could either go for a
>> SuperColumn or just adjust your row key accordingly (eg.
>> "foo:20100806")
>>
>> HTH,
>> /thomas
>
>

Mime
View raw message