Skip to content
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
9 changes: 5 additions & 4 deletions src/java/org/apache/cassandra/repair/RepairRunnable.java
Original file line number Diff line number Diff line change
Expand Up @@ -110,7 +110,7 @@ protected void fireErrorAndComplete(String tag, int progressCount, int totalProg
protected void runMayThrow() throws Exception
{
final TraceState traceState;

final UUID parentSession = UUIDGen.getTimeUUID();
final String tag = "repair:" + cmd;

final AtomicInteger progress = new AtomicInteger();
Expand All @@ -121,10 +121,9 @@ protected void runMayThrow() throws Exception
columnFamilies);

final long startTime = System.currentTimeMillis();
String message = String.format("Starting repair command #%d, repairing keyspace %s with %s", cmd, keyspace,
String message = String.format("Starting repair command #%d (%s), repairing keyspace %s with %s", cmd, parentSession, keyspace,
options);
logger.info(message);
fireProgressEvent(tag, new ProgressEvent(ProgressEventType.START, 0, 100, message));
if (options.isTraced())
{
StringBuilder cfsb = new StringBuilder();
Expand All @@ -134,6 +133,8 @@ protected void runMayThrow() throws Exception
UUID sessionId = Tracing.instance.newSession(Tracing.TraceType.REPAIR);
traceState = Tracing.instance.begin("repair", ImmutableMap.of("keyspace", keyspace, "columnFamilies",
cfsb.substring(2)));
message = message + " tracing with " + sessionId;
fireProgressEvent(tag, new ProgressEvent(ProgressEventType.START, 0, 100, message));
Tracing.traceRepair(message);
traceState.enableActivityNotification(tag);
for (ProgressListener listener : listeners)
Expand All @@ -144,6 +145,7 @@ protected void runMayThrow() throws Exception
}
else
{
fireProgressEvent(tag, new ProgressEvent(ProgressEventType.START, 0, 100, message));
traceState = null;
}

Expand Down Expand Up @@ -194,7 +196,6 @@ protected void runMayThrow() throws Exception
cfnames[i] = columnFamilyStores.get(i).name;
}

final UUID parentSession = UUIDGen.getTimeUUID();
SystemDistributedKeyspace.startParentRepair(parentSession, keyspace, cfnames, options);
long repairedAt;
try
Expand Down