[ML] Put C++ process/PID and file@line in square brackets (elastic/x-pack-elasticsearch#671)
This is the Elastic convention, and also makes it clearer where the actual log message from the C++ starts Original commit: elastic/x-pack-elasticsearch@dc9aeefb08
This commit is contained in:
parent
ac93195407
commit
094be3c28b
|
@ -215,9 +215,10 @@ public class CppLogMessageHandler implements Closeable {
|
|||
}
|
||||
// TODO: Is there a way to preserve the original timestamp when re-logging?
|
||||
if (jobId != null) {
|
||||
LOGGER.log(level, "[{}] {}/{} {}@{} {}", jobId, msg.getLogger(), latestPid, msg.getFile(), msg.getLine(), latestMessage);
|
||||
LOGGER.log(level, "[{}] [{}/{}] [{}@{}] {}", jobId, msg.getLogger(), latestPid, msg.getFile(), msg.getLine(),
|
||||
latestMessage);
|
||||
} else {
|
||||
LOGGER.log(level, "{}/{} {}@{} {}", msg.getLogger(), latestPid, msg.getFile(), msg.getLine(), latestMessage);
|
||||
LOGGER.log(level, "[{}/{}] [{}@{}] {}", msg.getLogger(), latestPid, msg.getFile(), msg.getLine(), latestMessage);
|
||||
}
|
||||
// TODO: Could send the message for indexing instead of or as well as logging it
|
||||
} catch (IOException e) {
|
||||
|
|
Loading…
Reference in New Issue