From 8beb37fef3991071a3cf63d939125b2c3d705846 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 10 Jun 2024 22:53:29 +0000 Subject: [PATCH 1/4] chore(deps): Bump org.springframework.boot from 3.2.5 to 3.3.0 Bumps [org.springframework.boot](https://github.com/spring-projects/spring-boot) from 3.2.5 to 3.3.0. - [Release notes](https://github.com/spring-projects/spring-boot/releases) - [Commits](https://github.com/spring-projects/spring-boot/compare/v3.2.5...v3.3.0) --- updated-dependencies: - dependency-name: org.springframework.boot dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- build.gradle | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build.gradle b/build.gradle index da49feb75..1f22c83c9 100644 --- a/build.gradle +++ b/build.gradle @@ -9,7 +9,7 @@ plugins { id 'io.github.gradle-nexus.publish-plugin' version '2.0.0' id 'ca.cutterslade.analyze' version '1.9.1' id 'io.spring.dependency-management' version '1.1.5' apply false - id 'org.springframework.boot' version '3.2.5' apply false + id 'org.springframework.boot' version '3.3.0' apply false id 'org.owasp.dependencycheck' version '9.2.0' id 'com.diffplug.spotless' version '6.25.0' id 'com.bmuschko.docker-spring-boot-application' version '9.4.0' apply false From 09f766a88665af6dfa23fddba3ee593503da00cf Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 3 Jun 2024 22:56:28 +0000 Subject: [PATCH 2/4] chore(deps): Bump org.apache.kafka:kafka-clients from 3.6.1 to 3.7.0 Bumps org.apache.kafka:kafka-clients from 3.6.1 to 3.7.0. --- updated-dependencies: - dependency-name: org.apache.kafka:kafka-clients dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- dependencies.gradle | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dependencies.gradle b/dependencies.gradle index 2e4bf0b79..60a1f37fe 100644 --- a/dependencies.gradle +++ b/dependencies.gradle @@ -39,7 +39,7 @@ ext { kafkaAvroSerializerVersion = '7.6.0' - kafkaClientsVersion = '3.6.1' + kafkaClientsVersion = '3.7.0' kafkaStreamsVersion = '3.7.0' kafkaProtobufSerializerVersion = '7.6.0' From fe7f94e4c314765828905a4a0f9539401967cfe6 Mon Sep 17 00:00:00 2001 From: Timon Back Date: Wed, 12 Jun 2024 20:53:30 +0200 Subject: [PATCH 3/4] chore(jms): fix spring jms configuration after 3.3.0 upgrade --- springwolf-examples/springwolf-jms-example/README.md | 1 + .../springwolf-jms-example/docker-compose.yml | 4 +++- .../src/main/resources/application.properties | 8 ++++---- 3 files changed, 8 insertions(+), 5 deletions(-) diff --git a/springwolf-examples/springwolf-jms-example/README.md b/springwolf-examples/springwolf-jms-example/README.md index c03d549d3..a71b4f6e3 100644 --- a/springwolf-examples/springwolf-jms-example/README.md +++ b/springwolf-examples/springwolf-jms-example/README.md @@ -4,6 +4,7 @@ 1. Copy the `docker-compose.yml` file to your machine. 2. Run `$ docker-compose up`. 3. Visit `localhost:8080/springwolf/asyncapi-ui.html` or try the API: `$ curl localhost:8080/springwolf/docs`. +4. ActiveMQ Management: `http://localhost:8161` using `artemis:artemis` as login ### Run with gradle Note: You need to execute the gradle `bootRun` task since the IntelliJ spring application will not include springwolf-ui correctly. diff --git a/springwolf-examples/springwolf-jms-example/docker-compose.yml b/springwolf-examples/springwolf-jms-example/docker-compose.yml index 568924a06..7d9cec476 100644 --- a/springwolf-examples/springwolf-jms-example/docker-compose.yml +++ b/springwolf-examples/springwolf-jms-example/docker-compose.yml @@ -11,9 +11,11 @@ services: - activemq activemq: - image: apache/activemq-artemis:2.31.2 + image: apache/activemq-artemis:2.34.0 environment: EXTRA_ARGS: --http-host 0.0.0.0 --relax-jolokia --nio + ARTEMIS_USER: artemis + ARTEMIS_PASSWORD: artemis ports: - "61616:61616" - "8161:8161" diff --git a/springwolf-examples/springwolf-jms-example/src/main/resources/application.properties b/springwolf-examples/springwolf-jms-example/src/main/resources/application.properties index f0b6e2c36..eb34ac783 100644 --- a/springwolf-examples/springwolf-jms-example/src/main/resources/application.properties +++ b/springwolf-examples/springwolf-jms-example/src/main/resources/application.properties @@ -5,9 +5,9 @@ spring.application.name=Springwolf example project - JMS ######### # JMS configuration -spring.artemis.broker-url=${BOOTSTRAP_SERVER:tcp://localhost:61616} -spring.artemis.user=artemis -spring.artemis.password=artemis +spring.activemq.broker-url=${BOOTSTRAP_SERVER:tcp://localhost:61616} +spring.activemq.user=artemis +spring.activemq.password=artemis ######### @@ -23,7 +23,7 @@ springwolf.docket.info.contact.email=example@example.com springwolf.docket.info.contact.url=https://github.com/springwolf/springwolf-core springwolf.docket.info.license.name=Apache License 2.0 springwolf.docket.servers.jms-server.protocol=jms -springwolf.docket.servers.jms-server.host=${spring.artemis.broker-url} +springwolf.docket.servers.jms-server.host=${spring.activemq.broker-url} springwolf.plugin.jms.publishing.enabled=true From f357197280a07057025ccc142ebdf611bb06eac5 Mon Sep 17 00:00:00 2001 From: Timon Back Date: Wed, 12 Jun 2024 21:14:41 +0200 Subject: [PATCH 4/4] chore(deps)!: update actuator endpoint Actuators have a single path with different operations, but not multiple paths. Also, only json is supported. --- .../controller/ActuatorAsyncApiController.java | 17 ++++------------- ...iIntegrationWithActuatorIntegrationTest.java | 2 +- 2 files changed, 5 insertions(+), 14 deletions(-) diff --git a/springwolf-core/src/main/java/io/github/springwolf/core/controller/ActuatorAsyncApiController.java b/springwolf-core/src/main/java/io/github/springwolf/core/controller/ActuatorAsyncApiController.java index 527a67121..7fc090c28 100644 --- a/springwolf-core/src/main/java/io/github/springwolf/core/controller/ActuatorAsyncApiController.java +++ b/springwolf-core/src/main/java/io/github/springwolf/core/controller/ActuatorAsyncApiController.java @@ -7,29 +7,20 @@ import io.github.springwolf.core.asyncapi.AsyncApiService; import lombok.RequiredArgsConstructor; import lombok.extern.slf4j.Slf4j; -import org.springframework.boot.actuate.endpoint.web.annotation.RestControllerEndpoint; -import org.springframework.http.MediaType; -import org.springframework.web.bind.annotation.GetMapping; +import org.springframework.boot.actuate.endpoint.annotation.ReadOperation; +import org.springframework.boot.actuate.endpoint.web.annotation.WebEndpoint; @Slf4j -@RestControllerEndpoint(id = "springwolf") +@WebEndpoint(id = "springwolf") @RequiredArgsConstructor public class ActuatorAsyncApiController { private final AsyncApiService asyncApiService; private final AsyncApiSerializerService serializer; - @GetMapping( - path = {"/docs", "/docs.json"}, - produces = MediaType.APPLICATION_JSON_VALUE) + @ReadOperation public String asyncApiJson() throws JsonProcessingException { AsyncAPI asyncAPI = asyncApiService.getAsyncAPI(); return serializer.toJsonString(asyncAPI); } - - @GetMapping(path = "/docs.yaml", produces = "application/yaml") - public String asyncApiYaml() throws JsonProcessingException { - AsyncAPI asyncAPI = asyncApiService.getAsyncAPI(); - return serializer.toYaml(asyncAPI); - } } diff --git a/springwolf-examples/springwolf-kafka-example/src/test/java/io/github/springwolf/examples/kafka/ApiIntegrationWithActuatorIntegrationTest.java b/springwolf-examples/springwolf-kafka-example/src/test/java/io/github/springwolf/examples/kafka/ApiIntegrationWithActuatorIntegrationTest.java index 7aa4f748e..761e4f217 100644 --- a/springwolf-examples/springwolf-kafka-example/src/test/java/io/github/springwolf/examples/kafka/ApiIntegrationWithActuatorIntegrationTest.java +++ b/springwolf-examples/springwolf-kafka-example/src/test/java/io/github/springwolf/examples/kafka/ApiIntegrationWithActuatorIntegrationTest.java @@ -38,7 +38,7 @@ public class ApiIntegrationWithActuatorIntegrationTest { @Test void asyncApiResourceArtifactTest() throws IOException { - String url = "http://localhost:" + managementPort + "/actuator/springwolf/docs"; + String url = "http://localhost:" + managementPort + "/actuator/springwolf"; String actual = restTemplate.getForObject(url, String.class); InputStream s = this.getClass().getResourceAsStream("/asyncapi.json");