Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Avoid inferring caller in LogRecord.getSourceClassName and getSourceMethodName when processing System.out calls #7433

Closed
donbourne opened this issue May 6, 2019 · 2 comments · Fixed by #7471
Assignees
Labels
release bug This bug is present in a released version of Open Liberty release:19006 team:Lumberjack

Comments

@donbourne
Copy link
Member

Currently the code is trying to figure out the JUL caller, even in cases where we are just logging our System.out.print "events". inferCaller is expensive so we need to stop doing that.

4XESTACKTRACE at java/lang/J9VMInternals.getStackTrace(Native Method)
4XESTACKTRACE at java/lang/Throwable.getInternalStackTrace(Throwable.java:284(Compiled Code))
4XESTACKTRACE at java/lang/Access.getStackTraceDepth(Access.java:117(Compiled Code))
4XESTACKTRACE at java/util/logging/LogRecord.inferCaller(LogRecord.java:557(Compiled Code))
4XESTACKTRACE at java/util/logging/LogRecord.getSourceClassName(LogRecord.java:319(Compiled Code))
4XESTACKTRACE at com/ibm/ws/logging/internal/impl/BaseTraceFormatter.messageLogFormat(BaseTraceFormatter.java:462(Compiled Code))
4XESTACKTRACE at com/ibm/ws/logging/internal/impl/BaseTraceService.invokeMessageRouters(BaseTraceService.java:712(Compiled Code))
4XESTACKTRACE at com/ibm/ws/logging/internal/impl/BaseTraceService.echo(BaseTraceService.java:644(Compiled Code))
4XESTACKTRACE at com/ibm/ws/logging/internal/impl/BaseTraceService$TrOutputStream.flush(BaseTraceService.java:1248(Compiled Code)) 5XESTACKTRACE (entered lock: com/ibm/ws/logging/internal/impl/BaseTraceService$TrOutputStream@0x00000000E02E4150, entry count: 1)
4XESTACKTRACE at java/io/PrintStream.write(PrintStream.java:506(Compiled Code)) 5XESTACKTRACE (entered lock: com/ibm/ws/logging/internal/impl/BaseTraceService$TeePrintStream@0x00000000E02D5EC8, entry count: 1)
@donbourne donbourne changed the title Avoid inferring caller in LogRecord.getSourceClassName when processing System.out calls Avoid inferring caller in LogRecord.getSourceClassName and getSourceMethodName when processing System.out calls May 6, 2019
@fwji
Copy link
Contributor

fwji commented May 7, 2019

PH11759 is created

@fmhwong fmhwong added the release bug This bug is present in a released version of Open Liberty label May 7, 2019
@fwji
Copy link
Contributor

fwji commented May 9, 2019

New performance result:

Action Threads Duration (s) Delay (ms) Actions Completed Actions per Second
sysout 1 90 0 2885981 32066

Old performance result:

Action Threads Duration (s) Delay (ms) Actions Completed Actions per Second
sysout 1 90 0 977688 10863

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
release bug This bug is present in a released version of Open Liberty release:19006 team:Lumberjack
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants