components-contrib
components-contrib copied to clipboard
Add ETag support to Cassandra state
Describe the proposal
Currently the Cassandra state store does not currently support ETags.
It seems possible by adding an etag column to the table and managing the etag values manually. That of course makes this tricky for systems already using this component. Perhaps the code can perform the ALTER TABLE
query so it is not a breaking change but this is likely non-trivial.
This issue has been automatically marked as stale because it has not had activity in the last 30 days. It will be closed in the next 7 days unless it is tagged (pinned, good first issue, help wanted or triaged/resolved) or other activity occurs. Thank you for your contributions.
This issue has been automatically closed because it has not had activity in the last 37 days. If this issue is still valid, please ping a maintainer and ask them to label it as pinned, good first issue, help wanted or triaged/resolved. Thank you for your contributions.
Given that #86 makes it clear that transaction support is unlikely. Is there enough value to add ETAG support?
Yes you can add a column to store a ETAG (a hash of the data / value combine with unix time millis or something like that).
This would mean every write operation would need an additional WHERE clause / operand, which can impact performance. Or the column needs to be indexed.
hi @berndverst
There is scyllaDB, a C++ Cassandra compatible product, support Lightweight Transactions
LWT should be able to provide ETAG support.
Cassandra/ScyllaDB can offer massive data storage, but each partition need in a limited size.
With etag, I can use it store massive data for one actor without worried about data consistency issues. (like 100M state KV for each one actor, and there could be 100M actor in total)
Other open source solution is hard to maintenance and scale compare to scyllaDB. ( similar product like DynamoDB, is not open source)
for example: discord never delete message history and storage it in scyllaDB. There is no other open source solution will meet the requirement (I am not aware there is any other similar open source products).