Table of Contents
Currently there is no tool that will help with the versioning of cassandra scheme. I was looking for a tool that is similar to flyway or liquidbase
To use the tool you need to create a directory will all your script files (files must end in cql). The tool will save in a table in Cassandra which scripts where already run. So all you need to do is add your new scripts to the same dir, and the tool will run only the new scripts. In the case that you have changed a script that was already run, you will get a warning.
Since this is a spring boot application you can run the application from the command line like:
java -jar cassandra-scheme.jar --cassandra.keyspace=myspace --scheme.dir=/mydir
Another option is to create a application.properties file under a config dir with all the parameters set.
Mandatory parameters that need to be configured:
cassandra.contactpoints = [ip]
cassandra.keyspace = [name]
scheme.dir = [location]
Optional parameters
cassandra.port = 9042
cassandra.version.table = scheme_version
As part of spring boot the parameters for the log with the default values are: logging.file=cassandra-scheme.log logging.path=./log
- Chaim Turkel (Email: [email protected])