You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@cassandra.apache.org by Colin Taylor <co...@gmail.com> on 2014/04/09 01:04:58 UTC

[ANN] ccm-clj - test Cassandra clusters via Clojure

Hi, we have released ccm-clj (https://github.com/SMX-LTD/ccm-clj) a Clojure
interface to ccm (https://github.com/pcmanus/ccm) designed specifically for
the creation of arbitrary clusters in Clojure integration tests.

(if (not (ccm/cluster? "testcluster"))
  (do
    (ccm/new! "testcluster" cass-version num-nodes cql-port)
    (ccm/cql! (io/file "./test/resources/test-keyspace.cql"))
    (ccm/cql! (io/resource "schema/test-schema.cql") "testkeyspace")
    (ccm/cql! (io/file "./test/resources/test-data.cql") "testkeyspace"))
  (do
    (ccm/switch! "testcluster")
    (ccm/start! "testcluster")))
....
(ccm/remove! "testcluster")

cheers
Colin Taylor