-
Type:
Task
-
Status: Dev in Progress
-
Priority:
Critical
-
Resolution: Unresolved
-
Affects Version/s: 7.0.0
-
Fix Version/s: 7.1.0
-
Component/s: core apis, core server, ease of use, logging, tech-debt
-
Labels:None
-
Epic Link:
-
Story Points:5
Motivation: OPENDJ-6528 and OPENDJ-6505.
We could do with rationalizing some of our exception logging. At the moment we have many methods that output different varieties of exception message:
- com.forgerock.opendj.util.StaticUtils#getExceptionMessage - this is the method used for the CME in this bug. It does not include any stack trace when the main exception has a message
- com.forgerock.opendj.util.StaticUtils#stackTraceToSingleLineString(java.lang.StringBuilder, java.lang.Throwable, boolean)
- com.forgerock.opendj.util.StaticUtils#stackTraceToSingleLineString(java.lang.Throwable, boolean) - delegates to method above
- org.opends.server.util.StaticUtils#getBacktrace
- org.opends.server.util.StaticUtils#getExceptionMessage - does some stuff then delegates to SDK equivalent
- org.opends.server.util.StaticUtils#stackTraceToSingleLineString - delegates to SDK
- org.opends.server.util.StaticUtils#stackTraceToString(java.lang.Throwable) - no delegation
I wonder if we could replace all these with a single method that combines getExceptionMessage(), which handles recognized exception types, then fall through to stackTraceToSingleLineString() with full stack always set to true for unrecognized exceptions.
Additional input from Jean-Noël Rouvignac: I see a lot of code calling e.getMessage() or e.getLocalizedMessage() (Java exceptions) or e.getMessageObject() (OpenDJ exceptions). I would ban them all in favour of a single call to StaticUtils.getExceptionMessage(e) which does the right thing (TM).
- caused
-
OPENDJ-7509 dskeymgr prints too much information when passing a wrong keystore password
-
- Done
-
-
OPENDJ-7534 DSML: Useful exception message on invalid dsml request got truncated
-
- Done
-
-
OPENDJ-7515 Token resolution: exception stack trace is printed out on error
-
- Dev backlog
-
-
OPENDJ-7517 Replication: Exception stack trace logged in an INFORMATION message
-
- Dev backlog
-
-
OPENDJ-7521 Referential Integrity plugin: weird exception when shutting down the server
-
- Dev backlog
-
- is required by
-
OPENDJ-7495 Exception logging improvements
-
- Dev backlog
-
- relates to
-
OPENDJ-6505 ConcurrentModificationException in Topology
-
- Done
-
-
OPENDJ-6528 Randomly getting ConcurrentModificationException during upgrade
-
- Dev backlog
-