-
Notifications
You must be signed in to change notification settings - Fork 212
π₯ Standalone Activities for Java #2858
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
Merged
Merged
Changes from all commits
Commits
Show all changes
91 commits
Select commit
Hold shift + click to select a range
b4abb30
vc
GregoryTravis d87dbc5
Integration tests.
GregoryTravis 40ad564
Options .toBuilder() should duplicate 'this'.
GregoryTravis 64f5cc9
equals and hashCode for StartActivityOptions
GregoryTravis 8c40020
Only throw ActivityAlreadyStartedException if error detail is present
GregoryTravis 6794e92
Same for getActivityResult
GregoryTravis d26c527
equals/hashcode/tostring for ActivityExecution
GregoryTravis 6dd4263
use-api-design
GregoryTravis aa4bcf3
match fully
GregoryTravis 5859bf0
More tests
GregoryTravis b4a27a0
Rename ActivityExecution to ActivityExecutionMetadata.
GregoryTravis 511f1c1
Store ActivityExecutionInfo instead of DescribeActivityExecutionRespoβ¦
GregoryTravis d3ec5c3
Rename getRetryPolicy to getRetryOptions.
GregoryTravis 416be5a
Missing methods in ActivityExecutionDescription.
GregoryTravis ee1f4df
Correct naming for interceptor interfaces.
GregoryTravis 282765f
Update ActivityInfo interface.
GregoryTravis 262d63d
More tests.
GregoryTravis 74b48bf
Tests for standalone completion client methods.
GregoryTravis 2324e6d
Interceptor tests.
GregoryTravis 8863baf
Nullable fields.
GregoryTravis d8bf835
swap args
GregoryTravis 2fc4bae
Rename IsInWorkflow to IsWorkflowActivity.
GregoryTravis 007de18
Merge branch 'master' into gmt/java-standalone-activities
GregoryTravis 381e66c
Test: contextPropagatorValueAppearsInStartActivityHeader.
GregoryTravis ba898ef
Revert "Test: contextPropagatorValueAppearsInStartActivityHeader."
GregoryTravis 133770e
ActivityClientInterceptor and ActivityClientInterceptorBase.
GregoryTravis a801751
Correct order for activity interceptors.
GregoryTravis f10f46f
Rename to initializeClientInvoker.
GregoryTravis 44875e3
Javadoc warnings, unused classes, a deprecated method.
GregoryTravis 0ea7377
Remove runtime rethrow.
GregoryTravis fedaacd
Pass null instead of "" for summary/details.
GregoryTravis f9f7dc9
Remove section dividers.
GregoryTravis cfa9427
useless test comments
GregoryTravis a2647fc
Enable SAA in test server.
GregoryTravis 0906641
Remove trivial tests.
GregoryTravis af94c2b
wip
GregoryTravis 2076001
Rename to ActivityClientCallsInterceptorBaseTest.
GregoryTravis ffd9f71
Non-mocked completion client tests.
GregoryTravis 0068b55
Tweak javadoc
GregoryTravis 5a839d6
Box for capturing
GregoryTravis cd6aa3e
Box for capturing
GregoryTravis e92cef8
MethodExtractor
GregoryTravis f7ebe1f
All overloads of same
GregoryTravis 62e9c3b
Refactor ME
GregoryTravis d4bf5b1
.start() pulls headers from context propagators.
GregoryTravis 3e99be2
Distinguish standalone method names in completion client.
GregoryTravis 749a8c7
Use long poll token in describeActivity.
GregoryTravis 84d5a4d
Expose lastFailure and raw proto on ActivityExecutionDescription.
GregoryTravis 076073f
Completion handled at gPRC layer.
GregoryTravis bc467e8
Cache for ActivityHandleImpl.getResultAsync.
GregoryTravis 4ea8ea4
Rename ActivityHandleWrapper to ActivityHandleImpl.
GregoryTravis cb6a1f7
Javadoc for ActivityClientCallsInterceptor
GregoryTravis 3d381de
ActivityException base class
GregoryTravis 00ecb71
Remove throws clauses for unchecked exceptions
GregoryTravis 0ec8f74
Don't expose ActivityClient.listExecutionsPaginated
GregoryTravis 467682f
Examples for all overloads in ActivityClient
GregoryTravis 1af2a9b
Update temporal-sdk/src/main/java/io/temporal/client/ActivityClient.java
GregoryTravis 5c157de
Merge branch 'gmt/java-standalone-activities' of github.com:temporaliβ¦
GregoryTravis 13993a9
Finish removing implementation detail in comment.
GregoryTravis cbf33f6
Remove trivial tests
GregoryTravis 21a1bb7
Update testFromUntypedWithExplicitTypePassesTypeToInterceptor to makeβ¦
GregoryTravis 4463c9e
testGetActivityResultAsyncDelegatesToNext
GregoryTravis 2773588
Merge branch 'master' into gmt/java-standalone-activities
GregoryTravis dc9188d
Merge branch 'master' into gmt/java-standalone-activities
GregoryTravis 6d54d34
Javadoc: missing import
GregoryTravis 6f5735e
Revert "Use long poll token in describeActivity."
GregoryTravis 172ce53
Address small review changes
GregoryTravis 3a85617
Default implementations for some untyped execute/executeAsync
GregoryTravis 2237e72
Remove ActivityCountOptions
GregoryTravis 6d3450d
Apply DataConverter to results of .getLastFailure
GregoryTravis c514cf3
Polling can outlast server timeout
GregoryTravis f322d84
Remove ActivityListOptions and ActivityListPaginatedOptions; keep botβ¦
GregoryTravis 7328b47
getResult/Async continue polling across the server's long-poll boundary
GregoryTravis 9142f0a
getResult/Async continue polling across the server's long-poll boundaβ¦
GregoryTravis a3a7e9c
Split slow tests for speed
GregoryTravis d0cc4b4
Increase timeout tolerance for GetActivityResultOverLongPollWaitTest.
GregoryTravis 5d8d055
Remaining two default overloads of execute/executeAsync, and remove rβ¦
GregoryTravis 2eaf28a
Remove unused listActivitiesPaginated interceptor
GregoryTravis eddc53e
Add overload to ActivityHandle.getResult with timeout.
GregoryTravis e2c88a6
TODO
GregoryTravis b59d1b9
getWorkflowNamespace returns null if no workflow execution
GregoryTravis c4bf54b
Update comment on ActivityInfo for getActivityNamespace() returning nβ¦
GregoryTravis 632a23d
Remove result caching, will revisit later.
GregoryTravis d47fc5e
Rename isWorkflowActivity to isInWorkflow
GregoryTravis 1156814
Remove default ActivityClientCallsInterceptor.getActivityResultAsync
GregoryTravis 0cc7209
Move Func7 to the correct spot
GregoryTravis 373c5f9
Remove internal ActivityExecutionDescription.info()
GregoryTravis fc29246
Tests that check that both only scheduleToCloseTimeout and only startβ¦
GregoryTravis 9429e47
ActivityClientCallsInterceptorChainTest: confirm ordering for 2 interβ¦
GregoryTravis e10dbd6
Added tests testGetHandleWithNullRunId and testVoidExecuteOverloadDisβ¦
GregoryTravis 0ee5b7f
Merge branch 'master' into gmt/java-standalone-activities
GregoryTravis File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Some comments aren't visible on the classic Files Changed page.
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
35 changes: 35 additions & 0 deletions
35
temporal-sdk/src/main/java/io/temporal/client/ActivityAlreadyStartedException.java
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,35 @@ | ||
| package io.temporal.client; | ||
|
|
||
| import io.temporal.common.Experimental; | ||
| import javax.annotation.Nullable; | ||
|
|
||
| /** | ||
| * Thrown by {@link ActivityClient#start} when the server returns an ALREADY_EXISTS error because an | ||
| * activity with the same ID is already running (or has a completed run that conflicts with the | ||
| * requested {@link StartActivityOptions#getIdReusePolicy()} / {@link | ||
| * StartActivityOptions#getIdConflictPolicy()}). | ||
| */ | ||
| @Experimental | ||
| public final class ActivityAlreadyStartedException extends ActivityException { | ||
|
|
||
| private final String activityType; | ||
|
|
||
| public ActivityAlreadyStartedException( | ||
| String activityId, String activityType, @Nullable String runId, Throwable cause) { | ||
| super( | ||
| "Activity already started: activityId='" | ||
| + activityId | ||
| + "', activityType='" | ||
| + activityType | ||
| + (runId != null ? "', runId='" + runId + "'" : "'"), | ||
| activityId, | ||
| runId, | ||
| cause); | ||
| this.activityType = activityType; | ||
| } | ||
|
|
||
| /** The activity type that was requested. */ | ||
| public String getActivityType() { | ||
| return activityType; | ||
| } | ||
| } |
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.