Skip to content

v3.0.0

Latest

Choose a tag to compare

@sam0r040 sam0r040 released this 27 Nov 18:02
· 8 commits to main since this release

We are happy to release Springwolf v3.0.0 🥳

Highlights

  • Jackson 3 & swagger-core 3: Springwolf now uses tools.jackson.* and swagger-core 3.0
  • New springwolf-web module: the HTTP endpoints moved out of springwolf-core, so Springwolf can generate documents without exposing any endpoints
  • Single springwolf-bindings artifact: replaces all springwolf-*-binding artifacts and springwolf-generic-binding
  • OpenAPI 3.1: nullable properties are documented as type: [string, "null"]
  • Cleaner extension APIs: deprecations removed, packages aligned, JSpecify nullability annotations

Breaking changes

  1. Add springwolf-web to keep the AsyncAPI endpoints, springwolf-ui and publishing.
  2. Replace the binding artifacts with springwolf-bindings, which the plugins already include. AsyncGenericOperationBinding moved to io.github.springwolf.bindings.generic.annotations.
  3. Jackson 3: register Jackson modules as JacksonModule beans, and migrate custom model converters and serializers to the Jackson 3 API.
  4. Changed signatures: BindingFactory, BindingContext, ChannelsScanner, OperationsScanner, ComponentsService and AsyncApiService.
  5. Moved classes: controllers (to io.github.springwolf.web), schema classes, ModelConvertersProvider (renamed to ModelConvertersRegisterer), and the plugin Producer classes (renamed to Publisher).
  6. The generated AsyncAPI document may change slightly.

Migrating from Springwolf 2.x to 3.0

If you only use a plugin and annotations, steps 1–3 are all you need.

1. Add springwolf-web

The HTTP endpoints (AsyncAPI document, actuator, UI config, publishing) moved from springwolf-core to springwolf-web.

implementation 'io.github.springwolf:springwolf-web:3.0.0'
implementation 'io.github.springwolf:springwolf-ui:3.0.0' // optional, requires springwolf-web

Unknown AsyncAPI groups now return HTTP 404.

2. Replace the binding artifacts

springwolf-bindings replaces all springwolf-*-binding artifacts and springwolf-generic-binding.
The plugins already include it, so you can usually just remove the old binding dependencies.

The generic binding annotation moved to io.github.springwolf.bindings.generic.annotations.AsyncGenericOperationBinding.

3. Jackson 3 and swagger-core 3

  • Remove or align any explicit swagger-*-jakarta 2.x dependencies (now swagger-core, swagger-models, swagger-annotations 3.x).
  • Springwolf no longer pulls in spring-boot-jackson2. Add it yourself, or switch to the Jackson 3 converters (JacksonJsonMessageConverter).
  • Migrate custom ModelConverters and serializers to Jackson 3 (tools.jackson.*, ValueSerializer).
  • Register Jackson modules as beans:
// 2.x
modelConvertersProvider.getObjectMapper().registerModule(new ProtobufModule());

// 3.0
@Bean
public JacksonModule protobufJacksonModule() {
    return new ProtobufModule();
}

4. Review the generated document

  • With payload-schema-format=openapi_v3_1, nullable properties are now type: [string, "null"].
  • The Kafka default header schema no longer contains kafka_recordMetadata, which changes the header schema name's hash suffix.
  • springwolf.scanner.async-listener.enabled / async-publisher.enabled now take effect.

5. Extension API changes

BindingFactory: only the BindingContext methods remain, and the context now contains the annotation (bindingContext.annotation()).

String getChannelName(BindingContext<T> ctx);
Map<String, ChannelBinding> buildChannelBinding(BindingContext<T> ctx);
Map<String, OperationBinding> buildOperationBinding(BindingContext<T> ctx);
Map<String, MessageBinding> buildMessageBinding(BindingContext<T> ctx, SchemaObject headerSchema);

Scanners: ChannelsScanner#scan() and OperationsScanner#scan() return a List instead of a Map.

ComponentsService is read-only (getSchemas(), getMessages()). Use these instead:

2.x ComponentsService 3.0
resolvePayloadSchema(Type, String) SchemasService#registerType(Type, String)
registerSchema, getSchemaName, getSimpleSchemaName SchemasService (same name)
registerMessage MessagesService#registerMessage

AsyncApiService#getForGroupName returns AsyncAPI instead of Optional and throws AsyncApiGroupNotFoundException.

Nullability annotations: jakarta.annotation.Nullable → org.jspecify.annotations.Nullable.

Moved classes

2.x 3.0
core.asyncapi.schemas.ModelConvertersProvider core.asyncapi.schemas.converters.ModelConvertersRegisterer
core.asyncapi.schemas.{SwaggerSchemaService, SwaggerSchemaMapper, SpringwolfTypeNameResolver} core.asyncapi.schemas.schema.*
core.asyncapi.components.postprocessors.* core.asyncapi.schemas.schema.postprocessors.*
core.asyncapi.components.examples.* core.asyncapi.schemas.schema.examples.*
core.asyncapi.scanners.channels.ChannelMerger core.asyncapi.channels.ChannelMerger
core.asyncapi.scanners.operations.OperationMerger core.asyncapi.operations.OperationMerger
core.asyncapi.scanners.operations.OperationIdHelper core.asyncapi.scanners.common.operation.OperationIdHelper
core.controller.{PublishingPayloadCreator, dtos.MessageDto} core.controller.publish.*
core.controller.{AsyncApiController, UiConfigController} web.controller.*
core.controller.ActuatorAsyncApiController web.controller.ActuatorController
core.controller.PublishingBaseController web.controller.publish.PublishingBaseController
core.configuration.{SpringwolfWebConfiguration, SpringwolfUiResource*} web.configuration.*
plugins.<protocol>.producer.Springwolf<Protocol>Producer plugins.<protocol>.publish.Springwolf<Protocol>Publisher
plugins.<protocol>.configuration.Springwolf<Protocol>ProducerConfiguration plugins.<protocol>.configuration.Springwolf<Protocol>PublisherConfiguration

Every package starts with io.github.springwolf.. SpringwolfKafkaTemplateProvider stays in plugins.kafka.producer.

What's Changed

  • Refactor/use bindingcontext by @timonback in #1916
  • chore(deps): Bump com.diffplug.spotless from 8.10.2 to 8.10.4 by @dependabot[bot] in #1911
  • feat(core): migrate to jackson 3 by @timonback in #1917
  • feat(core): use openapi 3.1 spec fields by @timonback in #1931
  • chore(binding): combine into single artifact by @timonback in #1932
  • chore(binding): move generic binding from add-ons by @timonback in #1933
  • Chore/resolve maintainer notes by @timonback in #1935
  • chore(deps): Bump spring-boot-plugin from 4.1.1 to 4.1.2 by @dependabot[bot] in #1941
  • chore(deps): Bump io-awspring-cloud from 4.2.0 to 4.2.1 by @dependabot[bot] in #1942
  • chore(deps): Bump net.javacrumbs.json-unit:json-unit-assertj from 6.2.0 to 6.4.0 by @dependabot[bot] in #1944
  • chore(deps): Bump org.jetbrains.kotlinx:kotlinx-serialization-core-jvm from 1.11.0 to 1.12.0 by @dependabot[bot] in #1937
  • chore(deps-dev): Bump @playwright/test from 1.57.0 to 1.65.1 in /springwolf-examples/e2e by @dependabot[bot] in #1959
  • chore(deps): Bump gradle/actions from 6.4.0 to 6.4.1 by @dependabot[bot] in #1938
  • chore(deps): Bump tslib from 2.8.1 to 2.9.1 in /springwolf-ui by @dependabot[bot] in #1945
  • chore(deps): Bump ngx-markdown from 22.1.0 to 22.1.1 in /springwolf-ui by @dependabot[bot] in #1947
  • chore(deps-dev): Bump @asyncapi/parser from 3.6.3 to 3.6.6 in /springwolf-ui by @dependabot[bot] in #1948
  • chore(deps): Bump github/codeql-action from 4.39.1 to 4.39.3 by @dependabot[bot] in #1950
  • Further refactoring by @timonback in #1949
  • chore(deps-dev): Bump prettier from 3.7.4 to 3.10.1 in /springwolf-examples/e2e by @dependabot[bot] in #1960
  • chore(deps-dev): Bump @types/node from 22.19.1 to 26.6.6 in /springwolf-examples/e2e by @dependabot[bot] in #1961
  • chore(deps): Bump confluentinc/cp-kafka from 8.3.2 to 8.4.0 in /springwolf-examples/springwolf-kafka-example by @dependabot[bot] in #1954
  • chore(deps-dev): Bump prettier from 3.9.9 to 3.10.1 in /springwolf-ui by @dependabot[bot] in #1957
  • chore(deps): Bump io.swagger.core.v3:swagger-annotations-jakarta from 2.2.42 to 2.2.56 by @dependabot[bot] in #1958
  • chore(deps): Bump org.springframework.cloud:spring-cloud-dependencies from 2025.1.3 to 2025.1.4 by @dependabot[bot] in #1956
  • chore(deps): Bump io-awspring-cloud from 4.2.1 to 4.2.2 by @dependabot[bot] in #1955
  • chore(deps): Bump confluentinc/cp-kafka from 8.3.2 to 8.4.0 in /springwolf-examples/springwolf-cloud-stream-example by @dependabot[bot] in #1953
  • chore(deps): Bump com.fasterxml.jackson.core:jackson-annotations from 2.22 to 2.23 by @dependabot[bot] in #1952
  • chore(deps): Bump jackson-core from 3.2.4 to 3.3.0 by @dependabot[bot] in #1951
  • chore(deps): Bump the dependencies-angular group across 1 directory with 12 updates by @dependabot[bot] in #1964
  • chore(deps): Bump org.apache.activemq:activemq-broker from 6.3.2 to 6.4.0 by @dependabot[bot] in #1971
  • chore(deps): Bump org.jetbrains.kotlinx:kotlinx-serialization-core-jvm from 1.12.0 to 1.13.0 by @dependabot[bot] in #1970
  • chore(deps): Bump com.google.protobuf from 0.10.0 to 0.10.1 by @dependabot[bot] in #1968
  • chore(deps-dev): Bump ts-json-schema-generator from 2.9.0 to 2.10.0 in /springwolf-ui by @dependabot[bot] in #1969
  • chore(deps): Bump github/codeql-action from 4.39.3 to 4.39.4 by @dependabot[bot] in #1966
  • chore(deps): Bump zod from 4.4.3 to 4.6.7 in /springwolf-ui by @dependabot[bot] in #1965
  • chore(deps): Bump spring-cloud-stream from 5.0.4 to 5.1.0 by @dependabot[bot] in #1972
  • chore(deps): Bump spring-boot-plugin from 4.1.2 to 4.2.0 by @dependabot[bot] in #1975
  • chore(deps): Bump com.networknt:json-schema-validator from 3.0.8 to 3.0.9 by @dependabot[bot] in #1977
  • chore(deps): Bump confluentinc/cp-kafka from 8.4.0 to 8.4.1 in /springwolf-examples/springwolf-kafka-example by @dependabot[bot] in #1974
  • chore(deps): Bump confluentinc/cp-kafka from 8.4.0 to 8.4.1 in /springwolf-examples/springwolf-cloud-stream-example by @dependabot[bot] in #1973
  • chore(deps): Bump com.rabbitmq:amqp-client from 5.37.0 to 5.38.0 by @dependabot[bot] in #1978
  • chore(deps): Bump com.diffplug.spotless from 8.10.4 to 8.12.0 by @dependabot[bot] in #1976
  • docs(README): rework README by @timonback in #1934
  • feat(web): create new module springwolf-web by @timonback in #1963

Full Changelog: v2.9.0...v3.0.0