-
Notifications
You must be signed in to change notification settings - Fork 3.8k
[CASSANDRA-21138] Add autorepair to Cassandra 5.0 #4558
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: cassandra-5.0
Are you sure you want to change the base?
Changes from all commits
97dd7de
1e742f1
8a43705
2e1092a
e73dbaa
443652a
60b12b4
cbdc1e5
abd1183
bbb1258
3cedc3b
c3ed2d0
0bdf37c
46f1c84
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -188,21 +188,23 @@ _build_all_dtest_jars() { | |
| if [ -d ${TMP_DIR}/cassandra-dtest-jars/.git ] && [ "https://github.com/apache/cassandra.git" == "$(git -C ${TMP_DIR}/cassandra-dtest-jars remote get-url origin)" ] ; then | ||
| echo "Reusing ${TMP_DIR}/cassandra-dtest-jars for past branch dtest jars" | ||
| if [ "x" == "x${OFFLINE}" ] ; then | ||
| until git -C ${TMP_DIR}/cassandra-dtest-jars fetch --quiet origin ; do echo "git -C ${TMP_DIR}/cassandra-dtest-jars fetch failed… trying again… " ; done | ||
| until git -C ${TMP_DIR}/cassandra-dtest-jars fetch --quiet --tags origin ; do echo "git -C ${TMP_DIR}/cassandra-dtest-jars fetch failed… trying again… " ; done | ||
| fi | ||
| else | ||
| echo "Cloning cassandra to ${TMP_DIR}/cassandra-dtest-jars for past branch dtest jars" | ||
| rm -fR ${TMP_DIR}/cassandra-dtest-jars | ||
| pushd $TMP_DIR >/dev/null | ||
| until git clone --quiet --depth 1 --no-single-branch https://github.com/apache/cassandra.git cassandra-dtest-jars ; do echo "git clone failed… trying again… " ; done | ||
| until git clone --quiet --depth 1 --no-single-branch --tags https://github.com/apache/cassandra.git cassandra-dtest-jars ; do echo "git clone failed… trying again… " ; done | ||
| popd >/dev/null | ||
| fi | ||
|
|
||
| # cassandra-4 branches need CASSANDRA_USE_JDK11 to allow jdk11 | ||
| [ "${java_version}" -eq 11 ] && export CASSANDRA_USE_JDK11=true | ||
|
|
||
| pushd ${TMP_DIR}/cassandra-dtest-jars >/dev/null | ||
| for branch in cassandra-4.0 cassandra-4.1 cassandra-5.0 ; do | ||
| # Note: cassandra-5.0.6 tag is used instead of cassandra-5.0 branch to enable | ||
| # testing upgrades from 5.0.6 to the current local build for autorepair feature | ||
| for branch in cassandra-4.0 cassandra-4.1 cassandra-5.0.6 ; do | ||
|
Contributor
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. The |
||
| git clean -qxdff && git reset --hard HEAD || echo "failed to reset/clean ${TMP_DIR}/cassandra-dtest-jars… continuing…" | ||
| git checkout --quiet $branch | ||
| dtest_jar_version=$(grep 'property\s*name=\"base.version\"' build.xml |sed -ne 's/.*value=\"\([^"]*\)\".*/\1/p') | ||
|
|
||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -68,12 +68,37 @@ using the provided 'sstableupgrade' tool. | |
| 5.0.7 | ||
| ====== | ||
|
|
||
| New features | ||
| ------------ | ||
| - CEP-37 Auto Repair is a fully automated scheduler that provides repair orchestration within Apache Cassandra. This | ||
| significantly reduces operational overhead by eliminating the need for operators to deploy external tools to submit | ||
| and manage repairs. See | ||
| https://cwiki.apache.org/confluence/display/CASSANDRA/CEP-37+Apache+Cassandra+Unified+Repair+Solution for more | ||
| details on the motivation and design. | ||
|
|
||
| Upgrading | ||
| --------- | ||
| - This release addresses a security vulnerability in the LZ4 dependency, documented in CASSANDRA-21052. For users | ||
| who did not use LZ4 native libraries, this will now fallback to a safer but less performant pure Java | ||
| implementation. During startup, a warning will be logged if the LZ4 native library is not available. | ||
|
|
||
| - The auto-repair feature requires enabling the JVM property `cassandra.autorepair.enable=true` (add | ||
| `-Dcassandra.autorepair.enable=true` to JVM options) before starting the node. This property creates the required | ||
| schema elements for auto-repair, including the auto_repair column in system_schema.tables and system_schema.views, | ||
| as well as the auto_repair_history and auto_repair_priority tables in system_distributed. After enabling this | ||
| property, you still need to enable auto-repair scheduling either in cassandra.yaml under the `auto_repair` section | ||
| or at runtime via JMX. | ||
|
|
||
| Users who do not intend to use auto-repair can leave this property disabled (the default) to maintain schema | ||
| compatibility with pre-5.0.7 nodes during rolling upgrades. This property must be set consistently across all | ||
| nodes before startup and cannot be changed at runtime. | ||
|
|
||
| WARNING: This property is non-reversible. Once enabled, it cannot be disabled. Attempting to start a node | ||
| with `cassandra.autorepair.enable=false` after it was previously enabled will cause the node to fail during | ||
| initialization due to schema incompatibility (the persisted schema contains auto-repair columns that are not | ||
| recognized when the property is disabled). To disable auto-repair scheduling after the property has been | ||
| enabled, use cassandra.yaml or JMX instead of changing the JVM property. | ||
|
Comment on lines
+85
to
+100
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 👍 great write up here, does a good job describing how to opt into feature and describing how it mitigates any risk if you do no opt into it. |
||
|
|
||
| 5.0.5 | ||
| ===== | ||
|
|
||
|
|
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
the
--tagsis needed becausecassandra-5.0.6is a tag and not a branch.