Opened 6 years ago

Closed 6 years ago

#673 closed defect (fixed)

logging in snark creates garbage even when disabled

Reported by: zab Owned by: zzz
Priority: minor Milestone: 0.9.2
Component: apps/i2psnark Version: 0.9.1
Keywords: logging OOM garbage Cc:
Parent Tickets:

Description

example http://pastethis.i2p/show/1543/

reason: even if logging at debug level is disabled, java will evaluate the arguments before they get put on the stack. Evaluating all these strings & java.util.Date objects is expensive.

Fixing requires all such uses to be prefixed by a predicate like is done in other parts of the code

Subtickets

Change History (4)

comment:1 Changed 6 years ago by zab

  • Keywords logging OOM garbage added

comment:2 Changed 6 years ago by zzz

  • Milestone set to 0.9.2
  • Status changed from new to accepted

of course, left over from original port to I2P years ago.

but if logging is causing you to oom you have other problems...

comment:3 Changed 6 years ago by zab

see comment on ticket #674 why OOM stack traces don't really mean anything and instead heap dumps should be used for post-mortem analysis, or pofilers for runtime analysis

comment:4 Changed 6 years ago by zzz

  • Resolution set to fixed
  • Status changed from accepted to closed

Fixed in 0.9.1-2

Not going to continue a discussion of OOM analysis here...

Note: See TracTickets for help on using tickets.