Working version with cassandra