From 06678cdb62e847e462e24e340425cb59df9fa645 Mon Sep 17 00:00:00 2001 From: vityaman Date: Tue, 28 Jan 2025 11:40:07 +0300 Subject: [PATCH] #121 Test Matchmaker SOAP --- .../se/dating/matchmaker/soap/RestClientConfiguration.kt | 3 ++- .../se/dating/matchmaker/soap/WebServiceConfiguration.kt | 2 +- .../matchmaker-soap/src/main/resources/application.yml | 8 ++++++-- .../main/resources/wsdl/{grammy.wsdl => matchmaker.wsdl} | 4 ++-- compose.yml | 1 + 5 files changed, 12 insertions(+), 6 deletions(-) rename backend/matchmaker-soap/src/main/resources/wsdl/{grammy.wsdl => matchmaker.wsdl} (98%) diff --git a/backend/matchmaker-soap/src/main/kotlin/ru/ifmo/se/dating/matchmaker/soap/RestClientConfiguration.kt b/backend/matchmaker-soap/src/main/kotlin/ru/ifmo/se/dating/matchmaker/soap/RestClientConfiguration.kt index 4017aa1..484266c 100644 --- a/backend/matchmaker-soap/src/main/kotlin/ru/ifmo/se/dating/matchmaker/soap/RestClientConfiguration.kt +++ b/backend/matchmaker-soap/src/main/kotlin/ru/ifmo/se/dating/matchmaker/soap/RestClientConfiguration.kt @@ -16,8 +16,9 @@ class RestClientConfiguration { ssl: RestClientSsl, ): MatchmakerRestClient = RestClient.builder() - .baseUrl(baseUrl) + .baseUrl("$baseUrl/api") .messageConverters { it.add(MappingJackson2HttpMessageConverter()) } + .apply(ssl.fromBundle("internal")) .build() .let { MatchmakerRestClient(it) } } diff --git a/backend/matchmaker-soap/src/main/kotlin/ru/ifmo/se/dating/matchmaker/soap/WebServiceConfiguration.kt b/backend/matchmaker-soap/src/main/kotlin/ru/ifmo/se/dating/matchmaker/soap/WebServiceConfiguration.kt index 2c6ba6e..cdf5f40 100644 --- a/backend/matchmaker-soap/src/main/kotlin/ru/ifmo/se/dating/matchmaker/soap/WebServiceConfiguration.kt +++ b/backend/matchmaker-soap/src/main/kotlin/ru/ifmo/se/dating/matchmaker/soap/WebServiceConfiguration.kt @@ -20,7 +20,7 @@ class WebServiceConfiguration { service: ITMODatingMatchmakerPortType, ): Endpoint { val endpoint = EndpointImpl(bus, service) - endpoint.publish("/") + endpoint.publish("/matchmaker") return endpoint } } diff --git a/backend/matchmaker-soap/src/main/resources/application.yml b/backend/matchmaker-soap/src/main/resources/application.yml index 758f070..3c9ba69 100644 --- a/backend/matchmaker-soap/src/main/resources/application.yml +++ b/backend/matchmaker-soap/src/main/resources/application.yml @@ -1,4 +1,6 @@ spring: + config: + import: application-tls.yml application: name: matchmaker-soap ssl: @@ -6,11 +8,13 @@ spring: jks: internal: keystore: + type: PKCS12 location: classpath:keystore/itmo-dating-backend.p12 password: ${ITMO_DATING_KEY_STORE_PASSWORD} truststore: - location: ${spring.ssl.bundle.jks.internal.keystore.location} - password: ${spring.ssl.bundle.jks.internal.keystore.password} + type: PKCS12 + location: classpath:keystore/itmo-dating-backend.p12 + password: ${ITMO_DATING_KEY_STORE_PASSWORD} itmo-dating: matchmaker: url: https://matchmaker-0.dating.se.ifmo.ru:8080 diff --git a/backend/matchmaker-soap/src/main/resources/wsdl/grammy.wsdl b/backend/matchmaker-soap/src/main/resources/wsdl/matchmaker.wsdl similarity index 98% rename from backend/matchmaker-soap/src/main/resources/wsdl/grammy.wsdl rename to backend/matchmaker-soap/src/main/resources/wsdl/matchmaker.wsdl index 8093d10..0cab036 100644 --- a/backend/matchmaker-soap/src/main/resources/wsdl/grammy.wsdl +++ b/backend/matchmaker-soap/src/main/resources/wsdl/matchmaker.wsdl @@ -303,8 +303,8 @@ - - + + diff --git a/compose.yml b/compose.yml index d7708de..eb88ce2 100644 --- a/compose.yml +++ b/compose.yml @@ -187,6 +187,7 @@ services: - "127.0.0.1:8455:8455" - "127.0.0.1:8456:8456" - "127.0.0.1:8457:8457" + - "127.0.0.1:8458:8458" restart: unless-stopped node-exporter: image: prom/node-exporter:latest