cassandra

By charmers

  • 764 deploys

Description

Cassandra is a distributed (peer-to-peer) system for the management and storage of structured data.

Readme

See README.storage for the persistent storage approach taken.

TODO(jjo): [2012/Sep/27] * [P0] Support setting an invalid volume-map - ie don't assume we've 'lost' our volume assignment -> raise error, to require human intervention (play safe & conservative)

  • [P0] Review state/needed configs/etc in case of "re-attaching" set of volumes into a fresh new deployment (should serve data present in volume-s) - this really requires a well thought statemachine transition diagram, to assure we'll never e.g.: - override already populated volumes, and/or "partially" serve a cluster (units should behave consistently).

  • [P0] Fix/implement DELAY_START_UNTIL_VOLUME logic (config set to indeed make the instance to void serving, until volume-map "assigns" a volume to it)

  • [P0] Do "full-cycle" testing, specially assess that volumes survive destroy-service, and can 'resume' serving if re-attached and setup with proper 'volume-map'.

  • [P1] Create helper scripts to scrape euca-describe-volumes, and 'merge' with juju status output, to: - fire attachments, then: - set a proper volume-map (instance->volume)

Configuration

client-port
(int) Thrift clients port
9160
new-gen-size
(string) Size of Java new generation memory, for example 100M. Only used if auto-memory = false.
100M
allow-single-node
(boolean) Allow cassandra to start in a single-node configuration. When deploying a new service with more than one initial unit (i.e. juju deploy -n 2), this should be set to false.
cluster-port
(int) Cluster communication port
7000
nagios_heapchk_warn_pct
(int) The pct of heap used to trigger a nagios warning
80
auto-memory
(boolean) Automatically configure memory options based on specification of the server infrastructure its running on.
True
heap-size
(string) Total size of Java memory heap, for example 1G or 512M. Only used if auto-memory = false.
1G
nagios_context
(string) a string that will be prepended to instance name to set the host name in nagios. So for instance the hostname would be something like: juju-cassandra-0 If you're running multiple environments with the same services in them this allows you to differentiate between them.
juju
token-map-by-unitname
(string) YAML map as e.g. "{ cassandra/0: 107950406921370402326527496543482482275, cassandra/1: 150485702786487710259449322472453508707 }". Set initial_token according to the unit name using this map. Cannot be used if token-map-by-volid is also set. If persistent storage is being used then use token-map-by-volid instead. Useful when rebalancing a ring by hand
jmx-port
(int) JMX management port
7199
apt-repo-key
(string) Apt repository key, typically needed for apt-repo-spec.
4BD736A82B5C1B00
volume-dev-regexp
(string) Block device for attached volumes as seen by the VM, will be "scanned" for an unused device when "volume-map" is valid for the unit.
/dev/vd[b-z]
volume-ephemeral-storage
(boolean) If False, a configure-error state will be raised if volume-map[$JUJU_UNIT_NAME] is not set (see "volume-map" below) - see "volume-map" below. If True, service units won't try to use "volume-map" (and related variables) to mount and use external (EBS) volumes, thus storage lifetime will equal VM, thus ephemeral. YOU'VE BEEN WARNED.
True
num-tokens
(int) Number of tokens per node for Cassandra 1.2+. Ignored for earlier versions.
256
cluster-name
(string) Name of the Cassandra Cluster - don't change yet!
Cassandra Cluster
token-map-by-volid
(string) YAML map as e.g. "{ vol-00000012: 107950406921370402326527496543482482275, vol-00000013: 150485702786487710259449322472453508707 }". Set initial_token according to the name of the attached volume using this map. Can only be used when using persistent storage and cannot be used if token-map-by-unitname is also set. Useful when rebalancing a ring by hand
volume-map
(string) YAML map as e.g. "{ cassandra/0: vol-0000010, cassandra/1: vol-0000016 }". Service units will raise a "configure-error" condition if no volume-map value is set for it - it's expected a human to set it properly to resolve it.
compaction-throughput
(int) Throttles compaction to the given total throughput (in MB/sec) across the entire system. The faster you insert data, the faster you need to compact in order to keep the sstable count down, but in general, setting this to 16 to 32 times the rate you are inserting data is more than sufficient. Setting this to 0 disables throttling. Note that this account for all types of compaction, including validation compaction.
16
force-seed-nodes
(string) A comma separated list of seed nodes. This is useful if the cluster being created in this juju environment is part of a larger cluser and the seed nodes are remote.
nagios_heapchk_crit_pct
(int) The pct of heap used to trigger a nagios critcal alert
90
apt-repo-spec
(string) Apt repository to install cassandra package(s) from.
deb http://www.apache.org/dist/cassandra/debian 12x main