personium / personium-core

Core module of Personium
https://personium.io
Apache License 2.0
88 stars 16 forks source link

PersoniumCoreExceptionMapper doesn't write exception stacktrace #565

Closed tochi-y closed 4 years ago

tochi-y commented 4 years ago

Problem

PersoniumCoreExceptionMapper doesn't write exception stacktrace even when the log level is DEBUG. The log example is the following.

2020-03-17 17:01:44.785 [catalina-exec-4] [DEBUG] [PL-ES-0002] - ESReq index=u0_ad type=Cell node=null reqType=Search data={"size":150000,"query":{"filtered":{"filter":{"term":{"s.Name.untouched":"timefiller"}},"query":{"match_all":{}}}}} - [io.personium.core.model.impl.es.EsModel$2#handleEvent:57] - PersoniumCoreLog
2020-03-17 17:01:44.802 [catalina-exec-4] [INFO ] [PR403-AU-0002] - Necessary privilege is lacking. - PersoniumCoreExceptionMapper
2020-03-17 17:01:44.805 [catalina-exec-4] [INFO ] [pEF1_d8kkT7ySKZ7XvbcT1w] > 403 179ms - PersoniumCoreContainerFilter

Another Problem

There is an another problem. PersoniumCoreExceptionMapper doesn't use PersoniumCoreLog. So logs are not followed for Personium Unified format.

Source code of the Problem

https://github.com/personium/personium-core/blob/6e6bcee4b3ebad7fd35e685beec532e955d673f6/src/main/java/io/personium/core/rs/PersoniumCoreExceptionMapper.java#L74-L78

tochi-y commented 4 years ago

We discussed this issue. The conclusion is