Skip to content

[AMORO-4550][Common] Fix composition of completed SimpleFuture inputs - #4551

Open
sivakumar-mahalingam wants to merge 1 commit into
apache:masterfrom
sivakumar-mahalingam:fix/amoro-4550-simple-future-composition
Open

sivakumar-mahalingam wants to merge 1 commit into
apache:masterfrom
sivakumar-mahalingam:fix/amoro-4550-simple-future-composition

Conversation

@sivakumar-mahalingam

Copy link
Copy Markdown
Contributor

Why are the changes needed?

Compositions with already-completed inputs remain incomplete because the completion callback runs before its bookkeeping is initialized. This leaves isDone() returning false and join() blocked even when the completion condition is satisfied. Empty allOf() has the same problem.

Closes #4550

Brief change log

  • Register completion checks after callback bookkeeping so already-completed compositions and empty allOf() complete immediately.
  • Add eight regression tests covering completed inputs, partially completed inputs, and empty compositions.
  • Update existing mocked futures to return a valid callback stage.

How was this patch tested?

  • Add test cases covering positive and negative cases.
  • Add screenshots for manual tests if appropriate (not applicable).
  • Run tests locally: ./mvnw test -pl amoro-common - all 121 tests passed, including Spotless and Checkstyle validation.

Documentation

  • Does this pull request introduce a new feature? no
  • If yes, how is the feature documented? not applicable

… already-completed inputs and empty allOf() complete immediately.

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

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Bug]: Composing completed SimpleFuture inputs never finishes

1 participant