bdeggleston commented on code in PR #3174:
URL: https://github.com/apache/cassandra/pull/3174#discussion_r1548661295
##########
src/java/org/apache/cassandra/repair/messages/RepairOption.java:
##########
@@ -199,21 +198,16 @@ public static RepairOption parse(Map<String, String>
options, IPartitioner parti
boolean ignoreUnreplicatedKeyspaces =
Boolean.parseBoolean(options.get(IGNORE_UNREPLICATED_KS));
boolean repairPaxos =
Boolean.parseBoolean(options.get(REPAIR_PAXOS_KEY));
boolean paxosOnly = Boolean.parseBoolean(options.get(PAXOS_ONLY_KEY));
- boolean accordRepair =
Boolean.parseBoolean(options.get(ACCORD_REPAIR_KEY));
+ boolean accordOnly =
Boolean.parseBoolean(options.get(ACCORD_ONLY_KEY));
+
+ if (paxosOnly && accordOnly)
+ throw new IllegalArgumentException("Cannot repair paxos and repair
only");
if (previewKind != PreviewKind.NONE)
{
Preconditions.checkArgument(!repairPaxos, "repairPaxos must be set
to false for preview repairs");
Preconditions.checkArgument(!paxosOnly, "paxosOnly must be set to
false for preview repairs");
- Preconditions.checkArgument(!accordRepair, "accordRepair must be
set to false for preview repairs");
- }
-
- if (accordRepair)
- {
- Preconditions.checkArgument(!paxosOnly, "paxosOnly must be set to
false for Accord repairs");
- Preconditions.checkArgument(previewKind == PreviewKind.NONE,
"Can't perform preview repair with an Accord repair");
- Preconditions.checkArgument(!force, "Accord repair only requires a
quorum to work so force is not supported");
Review Comment:
Force would still be useful for accord tables if some nodes were down. The
barrier that's run and is considered an accord repair only requires a quorum.
So running a force repair on an accord table with a node down would still apply
the barrier and stream between available nodes. It would fail pretty quickly if
there weren't enough live nodes to complete the barrier though
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]