From a431a7becb7655ec11cb9c28b4082b9fe320f29f Mon Sep 17 00:00:00 2001 From: Jasper Kamerling Date: Fri, 17 Nov 2023 10:13:02 +0100 Subject: [PATCH] FDP-94: Add todo's Signed-off-by: Jasper Kamerling --- .../application/factories/HttpsUrlConnectionFactory.java | 1 + .../java/org/gxf/soapbridge/soap/endpoints/SoapEndpoint.java | 1 + .../configuration/properties/SoapConfigurationProperties.kt | 2 +- 3 files changed, 3 insertions(+), 1 deletion(-) diff --git a/application/src/main/java/org/gxf/soapbridge/application/factories/HttpsUrlConnectionFactory.java b/application/src/main/java/org/gxf/soapbridge/application/factories/HttpsUrlConnectionFactory.java index b25c9e0..4d4de32 100644 --- a/application/src/main/java/org/gxf/soapbridge/application/factories/HttpsUrlConnectionFactory.java +++ b/application/src/main/java/org/gxf/soapbridge/application/factories/HttpsUrlConnectionFactory.java @@ -76,6 +76,7 @@ public HttpsURLConnection createConnection( connection.setSSLSocketFactory(sslContext.getSocketFactory()); connection.setDoInput(true); connection.setDoOutput(true); + // TODO use constants for properties and method connection.setRequestMethod("POST"); connection.setRequestProperty( "Accept-Encoding", "text/xml;charset=" + StandardCharsets.UTF_8.name()); diff --git a/application/src/main/java/org/gxf/soapbridge/soap/endpoints/SoapEndpoint.java b/application/src/main/java/org/gxf/soapbridge/soap/endpoints/SoapEndpoint.java index f9a870c..5618160 100644 --- a/application/src/main/java/org/gxf/soapbridge/soap/endpoints/SoapEndpoint.java +++ b/application/src/main/java/org/gxf/soapbridge/soap/endpoints/SoapEndpoint.java @@ -255,6 +255,7 @@ private void createSuccessFulResponse(final HttpServletResponse response, final throws IOException { LOGGER.debug("Start - creating successful response"); response.setStatus(HttpServletResponse.SC_OK); + // TODO use constants for headers response.addHeader("SOAP-ACTION", ""); response.addHeader("Keep-Alive", "timeout=5, max=100"); response.addHeader("Accept", "text/xml"); diff --git a/application/src/main/kotlin/org/gxf/soapbridge/configuration/properties/SoapConfigurationProperties.kt b/application/src/main/kotlin/org/gxf/soapbridge/configuration/properties/SoapConfigurationProperties.kt index b3597d6..90b5a9a 100644 --- a/application/src/main/kotlin/org/gxf/soapbridge/configuration/properties/SoapConfigurationProperties.kt +++ b/application/src/main/kotlin/org/gxf/soapbridge/configuration/properties/SoapConfigurationProperties.kt @@ -30,7 +30,7 @@ class SoapEndpointConfiguration( port: Int, protocol: String ) { - + // TODO Use java.net.URI class val hostAndPort = "$host:$port" val uri = "$protocol://${hostAndPort}" }