-
Notifications
You must be signed in to change notification settings - Fork 10
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Proposal: streamsx.cassandra #99
Comments
+1 |
+1 |
+1! very nice proposal btw! |
+1 2016-10-07 0:04 GMT+03:00 Samantha Chan notifications@github.com:
Best regards, |
Repository creation underway. |
Sweet deal, I see the repo that got created!
|
@ecurtin before you can push code, can you please sign this document: Yes, I think you can keep the current version number. |
Woo!! Thanks all!! Here it is! https://github.com/IBMStreams/streamsx.cassandra |
Proposal: streamsx.cassandra
streamsx.cassandra is a toolkit in active development (and production!) at The Weather Company.
It consists of an operator that writes Streams tuples to Cassandra.
The operator is a very thin Java facade for a Scala implementation. It's built using SBT.
Basic Capabilities
The operator is configured by specifying connection information in a ZooKeeper node.
Additionally, it provides mechanisms, also configurable in ZK, for writing values as NULLS.
Nearly all SPL types are supported, including sets, lists, and maps.
Null Value Mechanism
For a real-life example, say we have a tuple representing a report from a weather station:
Old-school meteorological convention specifies that invalid observations are reported as -9999. When these observations are written in Cassandra, however, we don't want to keep them as -9999, we want to take advantage of Cassandra's ability to write nulls.
So if I specify in the JSON blob that I store in ZooKeeper:
Any tuples that pass into the operator with the tempF value of -9999 will be written with a tempF value of NULL in Cassandra.
Licensing
The source is licensed under Apache V2.
Currently Supported Versions
Sample SPL Code
The znodes specify the connection to a dev Cassandra cluster and specifies that the null value for "nint" is -2147483647.
And here's a sample of the output, which I am pulling using CQL using a call that you should never ever use on a real table :)
Future Work
The text was updated successfully, but these errors were encountered: