jbonofre commented on code in PR #40605:
URL: https://github.com/apache/beam/pull/40605#discussion_r4411562922
##########
sdks/java/io/jms/src/main/java/org/apache/beam/sdk/io/jms/JmsCheckpointMark.java:
##########
@@ -66,6 +82,15 @@ private JmsCheckpointMark(
/** Acknowledge all outstanding message. */
@Override
public void finalizeCheckpoint() {
+ if (messages == null && consumer == null && session == null) {
+ // Possibly a restored copy of a checkpoint whose state lives in another
instance.
Review Comment:
Done. `id` is now `@Nullable`, and `finalizeCheckpoint()` skips the registry
lookup when it's null.
Just a clarification from my side: the checkpoint coder here is
`SerializableCoder`, not `AvroCoder` (see
`UnboundedJmsSource#getCheckpointMarkCoder`).
A mark written by an older version still deserializes with `id == null`, so
the guard applies.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]