diff options
author | MS <ms@taler.net> | 2023-01-15 19:12:46 +0100 |
---|---|---|
committer | MS <ms@taler.net> | 2023-01-15 19:12:46 +0100 |
commit | 16a0d51d1139659a365b2d123e54886a738934fb (patch) | |
tree | 7501864f49ccb88193e299cd5a0244287bb1ab5c /nexus/src/main/kotlin/tech/libeufin/nexus/server | |
parent | 38cb05b259002d5eac494cd175c6f02a2d7effbf (diff) | |
download | libeufin-16a0d51d1139659a365b2d123e54886a738934fb.tar.gz libeufin-16a0d51d1139659a365b2d123e54886a738934fb.tar.bz2 libeufin-16a0d51d1139659a365b2d123e54886a738934fb.zip |
Logging policy: not throwing stacktraces by default.
Diffstat (limited to 'nexus/src/main/kotlin/tech/libeufin/nexus/server')
-rw-r--r-- | nexus/src/main/kotlin/tech/libeufin/nexus/server/NexusServer.kt | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/nexus/src/main/kotlin/tech/libeufin/nexus/server/NexusServer.kt b/nexus/src/main/kotlin/tech/libeufin/nexus/server/NexusServer.kt index 288dabf7..0ba9d975 100644 --- a/nexus/src/main/kotlin/tech/libeufin/nexus/server/NexusServer.kt +++ b/nexus/src/main/kotlin/tech/libeufin/nexus/server/NexusServer.kt @@ -168,7 +168,7 @@ val nexusApp: Application.() -> Unit = { } install(StatusPages) { exception<NexusError> { call, cause -> - logger.error("Caught exception while handling '${call.request.uri} (${cause.reason})") + logger.error("Caught exception while handling '${call.request.uri} (${cause.message})") call.respond( status = cause.statusCode, message = ErrorResponse( @@ -179,7 +179,7 @@ val nexusApp: Application.() -> Unit = { ) } exception<JsonMappingException> { call, cause -> - logger.error("Exception while handling '${call.request.uri}'", cause) + logger.error("Exception while handling '${call.request.uri}'", cause.message) call.respond( HttpStatusCode.BadRequest, message = ErrorResponse( @@ -190,7 +190,7 @@ val nexusApp: Application.() -> Unit = { ) } exception<UtilError> { call, cause -> - logger.error("Exception while handling '${call.request.uri}'", cause) + logger.error("Exception while handling '${call.request.uri}'", cause.message) call.respond( cause.statusCode, message = ErrorResponse( @@ -201,7 +201,7 @@ val nexusApp: Application.() -> Unit = { ) } exception<EbicsProtocolError> { call, cause -> - logger.error("Caught exception while handling '${call.request.uri}' (${cause.reason})") + logger.error("Caught exception while handling '${call.request.uri}' (${cause.message})") call.respond( cause.httpStatusCode, message = ErrorResponse( @@ -223,7 +223,7 @@ val nexusApp: Application.() -> Unit = { ) } exception<Exception> { call, cause -> - logger.error("Uncaught exception while handling '${call.request.uri}'") + logger.error("Uncaught exception while handling '${call.request.uri}'", cause.message) cause.printStackTrace() call.respond( HttpStatusCode.InternalServerError, |