Skip to content

Commit 2b85fe4

Browse files
committed
update README
1 parent ade5f70 commit 2b85fe4

File tree

1 file changed

+75
-2
lines changed

1 file changed

+75
-2
lines changed

README.md

+75-2
Original file line numberDiff line numberDiff line change
@@ -5,8 +5,81 @@ Cassandra Reaper is a centralized, stateful, and highly configurable tool for ru
55
repairs for multi-site clusters.
66

77

8+
Overview
9+
--------
10+
11+
Cassandra Reaper consists of a database containing the full state of the system, a REST-full API,
12+
and a CLI tool called *spreaper* that provides an alternative way to issue commands to a running
13+
Reaper instance. Communication with Cassandra clusters is handled through JMX to the given seed
14+
node of each registered cluster.
15+
16+
You can also run the Reaper with memory storage, which is not persistent, and all the registered
17+
clusters, column families, and repair runs will be lost upon service restart. Currently Reaper
18+
supports only PostgreSQL database for persisting the state.
19+
20+
This project is built on top of Dropwizard:
21+
http://dropwizard.io/
22+
23+
824
Usage
925
-----
1026

11-
This project is built on top of Dropwizard, and can be run as defined in:
12-
http://dropwizard.io/getting-started.html#running-your-application
27+
To start the Reaper service providing the REST API, you need to configure the service in one
28+
configuration file. Run the service by calling *bin/cassandra-reaper* command with one
29+
argument, which is the path to the configuration file. See the available configuration options
30+
in later section of this readme document.
31+
32+
You can call the service directly through the REST API using a tool like *curl*. More about
33+
the REST API later.
34+
35+
You can also use the provided CLI tool in *bin/spreaper* to call the service. Run the tool with
36+
*-h* or *--help* option to see usage instructions.
37+
38+
39+
Configuration
40+
-------------
41+
42+
An example testing configuration YAML file can be found from within this project repository:
43+
*src/test/resources/cassandra-reaper.yaml*
44+
45+
The configuration file structure is provided by Dropwizard, and help on configuring the server,
46+
database connection, or logging, can be found from:
47+
*http://dropwizard.io/manual/configuration.html*
48+
49+
The Reaper service specific configuration values are:
50+
51+
* segmentCount:
52+
53+
Defines the amount of repair segments to create for newly registered Cassandra column families
54+
(token rings). When running a repair run by the Reaper, each segment is repaired separately
55+
by the Reaper process, until all the segments in a token ring are repaired.
56+
57+
* snapshotRepair:
58+
59+
Whether to use a snapshot repair by default when triggering repairs for repair segments.
60+
61+
* repairIntensity:
62+
63+
Repair intensity is a value between 0.0 and 1.0, but not zero. Repair intensity defines
64+
the amount of time to sleep between triggering each repair segment while running a repair run.
65+
When intensity is one, it means that Reaper doesn't sleep at all before triggering next segment,
66+
and otherwise the sleep time is defined by how much time it took to repair the last segment
67+
divided by the intensity value. 0.5 means half of the time is spent sleeping, and half running.
68+
69+
* repairRunThreadCount:
70+
The amount of threads to use for handling the Reaper tasks. Have this big enough not to cause
71+
blocking in cause some thread is waiting for I/O, like calling a Cassandra cluster through JMX.
72+
73+
74+
REST API
75+
--------
76+
77+
TODO:
78+
79+
GET /ping (com.spotify.reaper.resources.PingResource)
80+
GET /cluster (com.spotify.reaper.resources.ClusterResource)
81+
GET /cluster/{name} (com.spotify.reaper.resources.ClusterResource)
82+
POST /cluster (com.spotify.reaper.resources.ClusterResource)
83+
GET /table/{clusterName}/{keyspace}/{table} (com.spotify.reaper.resources.TableResource)
84+
POST /table (com.spotify.reaper.resources.TableResource)
85+
GET /repair_run/{id} (com.spotify.reaper.resources.RepairRunResource)

0 commit comments

Comments
 (0)