commit 555c76bc93897072f573d80c0ab1d7a36d9259c4
parent 7938086bf106d67b8cb6db442178b5989f7d39f1
Author: MS <ms@taler.net>
Date: Thu, 17 Nov 2022 22:19:08 +0100
Reduce logging.
Not printing stack trace on a invalid
EBICS request.
Diffstat:
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/sandbox/src/main/kotlin/tech/libeufin/sandbox/Main.kt b/sandbox/src/main/kotlin/tech/libeufin/sandbox/Main.kt
@@ -973,11 +973,11 @@ val sandboxApp: Application.() -> Unit = {
* generic error types to EBICS-formatted responses.
*/
catch (e: UtilError) {
- logger.error(e)
+ logger.error(e.reason)
throw EbicsProcessingError("Serving EBICS threw unmanaged UtilError: ${e.reason}")
}
catch (e: SandboxError) {
- logger.error(e)
+ logger.error(e.reason)
// Should translate to EBICS error code.
when (e.errorCode) {
LibeufinErrorCode.LIBEUFIN_EC_INVALID_STATE -> throw EbicsProcessingError("Invalid bank state.")
@@ -989,13 +989,13 @@ val sandboxApp: Application.() -> Unit = {
respondEbicsTransfer(call, e.errorText, e.errorCode)
}
catch (e: EbicsRequestError) {
- logger.error(e)
+ logger.error(e.errorText)
// Preventing the last catch-all block
// from capturing a known type.
throw e
}
catch (e: Exception) {
- logger.error(e)
+ logger.error(e.message)
throw EbicsProcessingError("Unmanaged error: $e")
}
return@post