From c909718c41ba1304bf22a40e0f2fdc4bd8622624 Mon Sep 17 00:00:00 2001 From: Jasper Kamerling Date: Thu, 16 Nov 2023 10:28:08 +0100 Subject: [PATCH] FDP-94: Update logging --- .../application/services/ClientCommunicationService.java | 2 +- .../org/gxf/soapbridge/kafka/senders/ProxyRequestKafkaSender.kt | 2 +- .../gxf/soapbridge/kafka/senders/ProxyResponseKafkaSender.kt | 2 +- .../gxf/soapbridge/valueobjects/ProxyServerResponseMessage.kt | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/application/src/main/java/org/gxf/soapbridge/application/services/ClientCommunicationService.java b/application/src/main/java/org/gxf/soapbridge/application/services/ClientCommunicationService.java index 8cbb5b2..29fb25f 100644 --- a/application/src/main/java/org/gxf/soapbridge/application/services/ClientCommunicationService.java +++ b/application/src/main/java/org/gxf/soapbridge/application/services/ClientCommunicationService.java @@ -55,7 +55,7 @@ public void handleIncomingResponse(final ProxyServerResponseMessage proxyServerR connection.setSoapResponse("Security check has failed."); } } else { - LOGGER.error("Cached connection is null"); + LOGGER.error("No connection found in cache for id."); } } catch (final ConnectionNotFoundInCacheException e) { LOGGER.error("ConnectionNotFoundInCacheException", e); diff --git a/application/src/main/kotlin/org/gxf/soapbridge/kafka/senders/ProxyRequestKafkaSender.kt b/application/src/main/kotlin/org/gxf/soapbridge/kafka/senders/ProxyRequestKafkaSender.kt index 36d3e2c..9c620a1 100644 --- a/application/src/main/kotlin/org/gxf/soapbridge/kafka/senders/ProxyRequestKafkaSender.kt +++ b/application/src/main/kotlin/org/gxf/soapbridge/kafka/senders/ProxyRequestKafkaSender.kt @@ -20,7 +20,7 @@ class ProxyRequestKafkaSender( private val topic = topicConfiguration.outgoing.requests fun send(requestMessage: ProxyServerRequestMessage) { - logger.debug("SOAP payload: ${requestMessage.soapPayload} to $topic") + logger.debug { "SOAP payload: ${requestMessage.soapPayload} to $topic" } kafkaTemplate.send(topic, requestMessage.constructSignedString()) } } diff --git a/application/src/main/kotlin/org/gxf/soapbridge/kafka/senders/ProxyResponseKafkaSender.kt b/application/src/main/kotlin/org/gxf/soapbridge/kafka/senders/ProxyResponseKafkaSender.kt index 3a1e978..d97a38e 100644 --- a/application/src/main/kotlin/org/gxf/soapbridge/kafka/senders/ProxyResponseKafkaSender.kt +++ b/application/src/main/kotlin/org/gxf/soapbridge/kafka/senders/ProxyResponseKafkaSender.kt @@ -20,7 +20,7 @@ class ProxyResponseKafkaSender( private val topic = topicConfiguration.outgoing.responses fun send(responseMessage: ProxyServerResponseMessage) { - logger.debug("SOAP payload: ${responseMessage.soapResponse} to $topic") + logger.debug { "SOAP payload: ${responseMessage.soapResponse} to $topic" } kafkaTemplate.send(topic, responseMessage.constructSignedString()) } } diff --git a/application/src/main/kotlin/org/gxf/soapbridge/valueobjects/ProxyServerResponseMessage.kt b/application/src/main/kotlin/org/gxf/soapbridge/valueobjects/ProxyServerResponseMessage.kt index 92c513c..a6ad773 100644 --- a/application/src/main/kotlin/org/gxf/soapbridge/valueobjects/ProxyServerResponseMessage.kt +++ b/application/src/main/kotlin/org/gxf/soapbridge/valueobjects/ProxyServerResponseMessage.kt @@ -32,7 +32,7 @@ class ProxyServerResponseMessage(connectionId: String, val soapResponse: String) fun createInstanceFromString(string: String): ProxyServerResponseMessage { val split = string.split(SEPARATOR) val numTokens = split.size - logger.debug("split.length: {}", numTokens) + logger.debug { "split.length: ${numTokens}" } if (numTokens < 3) { throw ProxyMessageException( "Invalid number of tokens, don't try to create ProxyServerResponseMessage"