Skip to content
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

Revert node replacement behavior so that the framework does not pass … #403

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -125,11 +125,9 @@ public CassandraDaemonTask create(
}

private static CassandraConfig updateConfig(
final CassandraMode mode,
final Protos.TaskState state,
final CassandraConfig config) {
// If the Cassandra daemon has transitioned to the NORMAL mode, remove the replaceIp so that the next
// time Cassandra starts, it does not have the startup argument -Dcassandra.replace_address=<replaceIp>.
if (CassandraMode.NORMAL.equals(mode)) {
if (Protos.TaskState.TASK_RUNNING.equals(state)) {
return config.mutable().setReplaceIp("").build();
} else {
return config;
Expand Down Expand Up @@ -218,7 +216,7 @@ public CassandraDaemonTask update(CassandraTaskStatus status) {
.setData(getData().updateDaemon(
daemonStatus.getState(),
daemonStatus.getMode(),
updateConfig(daemonStatus.getMode(), getConfig())
updateConfig(daemonStatus.getState(), getConfig())
).getBytes()).build()
);
}
Expand Down