Skip to content

Omit the Nexus cancellation token from JSON - #3239

Open
litlep-nibbyt wants to merge 1 commit into
mainfrom
nexus-info-cancellation-json
Open

litlep-nibbyt wants to merge 1 commit into
mainfrom
nexus-info-cancellation-json

Conversation

@litlep-nibbyt

Copy link
Copy Markdown
Contributor

What changed?

Omit the live cancellation token when Jackson serializes NexusOperationInfo. Java handlers can still call getCancellationToken(). Added an entry under Unreleased → Fixed.

Why?

When an application serializes the whole info object, Jackson calls getCancellationFuture() and registers an unnecessary callback. Omitting the token avoids that side effect.

This only affects applications that include NexusOperationInfo in data they serialize.

Breaking changes?

No. The cancellationToken JSON field has never shipped in a Java SDK release. Had it shipped, removing it would be a breaking change only for consumers that rely on the field in the serialized NexusOperationInfo payload.

Server PR

None.

Testing

  • Verified that the regression test fails before the fix and passes after it. Metadata still round-trips, and serialization skips getCancellationFuture().
  • Ran the Nexus and Jackson suites on JDK 21. 193 passed, 15 skipped, and zero failed.
  • Verified that both Jackson 3 modes omit the token and register zero callbacks.

@litlep-nibbyt
litlep-nibbyt marked this pull request as ready for review November 25, 2026 23:36
@litlep-nibbyt
litlep-nibbyt requested a review from a team as a code owner November 25, 2026 23:36

This branch has not been deployed

No deployments
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