Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix ActivityCompletionClient cancellation and failure by WorkflowExecution #930

Merged
merged 1 commit into from
Oct 31, 2024

Conversation

natemort
Copy link
Member

When sending RespondActivityTaskFailedByIDRequest or RespondActivityTaskCanceledByIDRequest we don't include the ActivityID. Correctly include the id and add test coverage.

What changed?

  • Include the ActivityID when canceling/failing activities by ID.

Why?

  • Fix longstanding bug.
  • Increase test coverage.

How did you test it?

  • Unit/Integration tests.

Potential risks

Release notes

Documentation Changes

@coveralls
Copy link

Pull Request Test Coverage Report for Build 2563

Details

  • 2 of 2 (100.0%) changed or added relevant lines in 1 file are covered.
  • 1 unchanged line in 1 file lost coverage.
  • Overall coverage increased (+0.6%) to 67.203%

Files with Coverage Reduction New Missed Lines %
src/main/java/com/uber/cadence/internal/common/InternalUtils.java 1 79.61%
Totals Coverage Status
Change from base Build 2555: 0.6%
Covered Lines: 13024
Relevant Lines: 19380

💛 - Coveralls

Copy link

codecov bot commented Oct 29, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 66.13%. Comparing base (e62b0fb) to head (255d591).

Additional details and impacted files
Files with missing lines Coverage Δ
...l/external/ManualActivityCompletionClientImpl.java 75.00% <100.00%> (+28.96%) ⬆️

... and 11 files with indirect coverage changes


Continue to review full report in Codecov by Sentry.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update e62b0fb...255d591. Read the comment docs.

@@ -0,0 +1,249 @@
/*
* Copyright 2012-2016 Amazon.com, Inc. or its affiliates. All Rights Reserved.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is this correct?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

oh, I didn't see the "modifiications copyright" down below, I guess it is from there. the licence URL looks sus, but I guess it is what it is.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The cadence java client is a fork of https://github.com/aws/aws-swf-flow-library 😄

Copy link
Member

@davidporter-id-au davidporter-id-au left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not super strong with the Java impl, but the test looks reasonable from what I can see

testRule.newWorkflowStub(ManualCompletionWorkflow.class).run();
}

public interface ManualCompletionActivities {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nonblocking / question: So, forgive my utter ignorance of testing in Java, but why declare an interface here?

@natemort natemort force-pushed the manual branch 2 times, most recently from 255d591 to 926be8a Compare October 31, 2024 16:30
…ution

When sending RespondActivityTaskFailedByIDRequest or RespondActivityTaskCanceledByIDRequest we don't include the ActivityID. Correctly include the id and add test coverage.
@natemort natemort merged commit 948814c into cadence-workflow:master Oct 31, 2024
11 checks passed
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.

3 participants