zoo_live_crew
zoo_live_crew

Reputation: 271

Where can I observer writes to Cassandra database, aka where are they logged?

Trying to track down a problem with one of our developers, mainly a program he wrote that modifies (adds some flags) to existing entries in the various tables in our Cassandra keyspace.

The issue is that it seems to work just fine for many of the tables, but at least 3 so far I've discovered that it isn't writing anything to them. The only thing his logs can tell me is that x number of rows were committed to the database, but of course when I query a specific row I see that is not the case.

I was just wondering if there is somewhere that Cassandra logs each INSERT so I can look the log and figure out what was going on when it was supposedly inserting that data into the table? I know when a write command is issued it is written to the commit log but I believe that is not human readable, so I need to be able to check somewhere that is.

Upvotes: 3

Views: 226

Answers (1)

phact
phact

Reputation: 7305

The only thing his logs can tell me is that x number of rows were committed to the database, but of course when I query a specific row I see that is not the case.

This sounds like it might be a consistency issue, can you query using CL ALL?

I was just wondering if there is somewhere that Cassandra logs each INSERT so I can look the log and figure out what was going on when it was supposedly inserting that data into the table?

Bad news:

Cassandra does not have audit logging

Good news:

DSE does have audit logging -- http://docs.datastax.com/en/datastax_enterprise/4.7/datastax_enterprise/sec/secAuditingCassandraTable.html

Remember there is a performance penalty for audit logging. You may just want to turn it on temporarily.

Upvotes: 3

Related Questions