-
Improvement
-
Resolution: Unresolved
-
Neutral
-
None
-
None
-
None
The info.magnolia.rest.RestExceptionMapper logs an error and the stacktrace (except for NotAcceptableException). The stacktrace seems to be abused for logging the source endpoint/method, and clutters the logs.
Acceptance Criteria
- Decorated WebApplicationException exists which takes as arguments:
- The URI of the resource
- The HTTP Method
- The method's FQN
- Decorated WebApplicationException formats the log message containing the above arguments
- RestExceptionMapper logs an info (instead of an error)
- RestExceptionMapper logs exactly one line.
Technical Details
Logging an error in the server for a client error is not ideal. The client error represents an error to the client, hence the error response. To the server it should represent every day business though, hence an Info would be more appropriate.
Acceptance criteria