You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@cassandra.apache.org by Gaurav Bhatnagar <gb...@gmail.com> on 2014/08/22 13:10:35 UTC

how to generate log entries for columns getting deleted due to TTL expiration

Hi,
    I have stored following data structure in cassandra

RowKey: 119551747098

=> (name=c:per:@batchId, value=ad1, timestamp=1408345109805011, ttl=1436489)

=> (name=c:per:@currency, value=USD, timestamp=1408345109805009,
ttl=1436489)

=> (name=c:per:@decimalValue, value=2, timestamp=1408345109805003,
ttl=1436489)


here Rowkey 119551747098 is a numeric number containing serial number of
data


These columns get expired when ttl value for that column is reached.

I what to generate an log entry which contains value of RowKey along when
column pointed by this Rowkey gets deleted due to ttl expiration.


Where in code I can put log entries so that Rowkey corresponding to deleted
columns gets printed in log file?


Regards,

Gaurav

Re: how to generate log entries for columns getting deleted due to TTL expiration

Posted by Tyler Hobbs <ty...@datastax.com>.
I would use LazilyCompactedRow (probably in getReduced()).


On Fri, Aug 22, 2014 at 6:10 AM, Gaurav Bhatnagar <gb...@gmail.com>
wrote:

> Hi,
>     I have stored following data structure in cassandra
>
> RowKey: 119551747098
>
> => (name=c:per:@batchId, value=ad1, timestamp=1408345109805011,
> ttl=1436489)
>
> => (name=c:per:@currency, value=USD, timestamp=1408345109805009,
> ttl=1436489)
>
> => (name=c:per:@decimalValue, value=2, timestamp=1408345109805003,
> ttl=1436489)
>
>
> here Rowkey 119551747098 is a numeric number containing serial number of
> data
>
>
> These columns get expired when ttl value for that column is reached.
>
> I what to generate an log entry which contains value of RowKey along when
> column pointed by this Rowkey gets deleted due to ttl expiration.
>
>
> Where in code I can put log entries so that Rowkey corresponding to deleted
> columns gets printed in log file?
>
>
> Regards,
>
> Gaurav
>



-- 
Tyler Hobbs
DataStax <http://datastax.com/>