2

I have a need to write a log entry (time-series/journal) entry within the context of a transaction of Gremlin mutations in DSE 5.0. Preferably to a separate Cassandra table (a bit of CQL I suppose).

I understand that DSE provides some optimizations around time-series with edges, but it feels like it would be an abuse to creates potentially billions of edges to record a journal that way.

Is there some way to include a CQL write within the context of a Gremlin transaction? Or, flipped around, can I include a batch of Gremlin mutations within the context of a CQL lightweight transactions?

stephen mallette
  • 45,298
  • 5
  • 67
  • 135

1 Answers1

1

First, note that CQL LWT transactions and Gremlin transactions are actually different things. CQL transactions are essentially CAS operations. Gremlin transactions allow you to group business logic into a single request in order to get read isolation and write atomicity (but not full ACID).

It is currently not possible to add CQL operations inside a Gremlin transaction request. However, you could add a new vertex for each journal entry. That would effectively create a separate CQL table (underneath the hood) and you can control data placement through custom vertex ids. The benefit of that approach is that you can stay within Gremlin to writ