Skip to content

refactor(spring): drop ChannelSendOperator from the DataSource return-value handler - #30

Merged
rossdanderson merged 1 commit into
mainfrom
refactor/payload-return-value-handler
May 29, 2026
Merged

rossdanderson merged 1 commit into
mainfrom
refactor/payload-return-value-handler

Conversation

@rossdanderson

@rossdanderson rossdanderson commented May 29, 2026 •

Copy link
Copy Markdown
Collaborator

Sets the DataSource response flow directly in DataSourcePayloadReturnValueHandler instead of routing it through a WebFlux ChannelSendOperator. The operator was an HTTP-response idiom that only pulled spring-web into the messaging starter for no benefit — the flow is cold and collected later, so a synchronous set plus Mono.empty() is equivalent.

One file changed, no public API change.

…f via ChannelSendOperator

The return-value handler stored the encoded content flow into the response
AtomicReference inside a Spring WebFlux ChannelSendOperator. That operator is an
HTTP-response-writing idiom (buffer the first element to decide status/headers)
and pulled spring-web into the messaging starter. The handler's only contract is
to set the response reference before its Mono completes, and the flow is cold and
collected later by DataSourceServerBootstrap — so a direct synchronous set plus
Mono.empty() is equivalent and drops the spring-web coupling. Also removes the
now-unneeded org.springframework.lang.Nullable usage (the parameter is non-null
after the simplification).
@rossdanderson
rossdanderson force-pushed the refactor/payload-return-value-handler branch from 972e7e5 to 621149a Compare May 29, 2026 15:21
@rossdanderson
rossdanderson merged commit 251fcb2 into main May 29, 2026
3 checks passed
rossdanderson added a commit that referenced this pull request Jun 25, 2026
* feat: upgrade to Spring Boot 4.0 with Jackson 3 as the default

- Bump to Spring Boot 4.0.6 / Kotlin 2.2.21; Jackson 3 versions come from the BOM.
- util: Jackson 3 becomes the runtime default (api), Jackson 2 is compileOnly;
  createDataSource defaults to the Jackson 3 handler.
- spring starter: JsonHandler bean prefers Jackson 3, falls back to Jackson 2
  (spring-boot-jackson2); DataMessageMapping doc references tools.jackson.
- spring tests use Logback only (drop slf4j-simple) with a quiet logback-test.xml;
  add kotest SpringExtension + a context test asserting the Jackson 3 handler.
- Docs: README compatibility table + MIGRATION.md (2.x/Boot 3.5 -> 3.x/Boot 4.0).

Depends on the ChannelSendOperator removal (PR #30) landing on main first.

* chore: bump Kotlin JPS plugin to 2.3.20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant