[ML] Add missing job Ids to log messages

Original commit: elastic/x-pack-elasticsearch@56855a3808
This commit is contained in:
David Kyle 2017-12-05 17:43:34 +00:00
parent 751caaae76
commit 4cd8f075b9
2 changed files with 5 additions and 5 deletions

View File

@ -118,7 +118,7 @@ class DatafeedJob {
}
}
if (!isIsolated) {
LOGGER.debug("Lookback finished after being stopped");
LOGGER.debug("[{}] Lookback finished after being stopped", jobId);
}
return null;
}
@ -133,7 +133,7 @@ class DatafeedJob {
FlushJobAction.Request request = new FlushJobAction.Request(jobId);
request.setSkipTime(String.valueOf(startTime));
FlushJobAction.Response flushResponse = flushJob(request);
LOGGER.info("Skipped to time [" + flushResponse.getLastFinalizedBucketEnd().getTime() + "]");
LOGGER.info("[{}] Skipped to time [{}]", jobId, flushResponse.getLastFinalizedBucketEnd().getTime());
return flushResponse.getLastFinalizedBucketEnd().getTime();
}
return startTime;

View File

@ -98,8 +98,8 @@ public class ChunkedDataExtractor implements DataExtractor {
currentEnd = currentStart;
chunkSpan = context.chunkSpan == null ? dataSummary.estimateChunk() : context.chunkSpan.getMillis();
chunkSpan = context.timeAligner.alignToCeil(chunkSpan);
LOGGER.debug("Chunked search configured: totalHits = {}, dataTimeSpread = {} ms, chunk span = {} ms",
dataSummary.totalHits, dataSummary.getDataTimeSpread(), chunkSpan);
LOGGER.debug("[{}]Chunked search configured: totalHits = {}, dataTimeSpread = {} ms, chunk span = {} ms",
context.jobId, dataSummary.totalHits, dataSummary.getDataTimeSpread(), chunkSpan);
} else {
// search is over
currentEnd = context.end;
@ -164,7 +164,7 @@ public class ChunkedDataExtractor implements DataExtractor {
currentStart = currentEnd;
currentEnd = Math.min(currentStart + chunkSpan, context.end);
currentExtractor = dataExtractorFactory.newExtractor(currentStart, currentEnd);
LOGGER.trace("advances time to [{}, {})", currentStart, currentEnd);
LOGGER.trace("[{}] advances time to [{}, {})", context.jobId, currentStart, currentEnd);
}
@Override