mirror of https://github.com/apache/lucene.git
logging: log versions
git-svn-id: https://svn.apache.org/repos/asf/lucene/dev/trunk@1292619 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
a9fbb020a5
commit
42c1ca8212
|
@ -106,7 +106,10 @@ class LogUpdateProcessor extends UpdateRequestProcessor {
|
|||
}
|
||||
|
||||
if (adds.size() < maxNumToLog) {
|
||||
adds.add(cmd.getPrintableId());
|
||||
long version = cmd.getVersion();
|
||||
String msg = cmd.getPrintableId();
|
||||
if (version != 0) msg = msg + " (" + version + ')';
|
||||
adds.add(msg);
|
||||
}
|
||||
if (logDebug) { log.debug("add {}", cmd.getPrintableId()); }
|
||||
|
||||
|
@ -123,11 +126,17 @@ class LogUpdateProcessor extends UpdateRequestProcessor {
|
|||
toLog.add("delete",deletes);
|
||||
}
|
||||
if (deletes.size() < maxNumToLog) {
|
||||
deletes.add(cmd.getId());
|
||||
long version = cmd.getVersion();
|
||||
String msg = cmd.getId();
|
||||
if (version != 0) msg = msg + " (" + version + ')';
|
||||
deletes.add(msg);
|
||||
}
|
||||
if (logDebug) { log.debug("delete {}", cmd.getId()); }
|
||||
} else {
|
||||
if (toLog.size() < maxNumToLog) {
|
||||
long version = cmd.getVersion();
|
||||
String msg = cmd.query;
|
||||
if (version != 0) msg = msg + " (" + version + ')';
|
||||
toLog.add("deleteByQuery", cmd.query);
|
||||
}
|
||||
if (logDebug) { log.debug("deleteByQuery {}", cmd.getQuery()); }
|
||||
|
|
Loading…
Reference in New Issue