Skip to content

Commit f715975

Browse files
authored
Update idls (#882)
Implement required methods for new IDL types
1 parent 88a8a78 commit f715975

File tree

8 files changed

+346
-1
lines changed

8 files changed

+346
-1
lines changed

src/main/idls

Submodule idls updated from 1850ff2 to 83d5cae

src/main/java/com/uber/cadence/internal/compatibility/Thrift2ProtoAdapter.java

Lines changed: 54 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -80,9 +80,15 @@
8080
import com.uber.cadence.RespondDecisionTaskCompletedResponse;
8181
import com.uber.cadence.RespondDecisionTaskFailedRequest;
8282
import com.uber.cadence.RespondQueryTaskCompletedRequest;
83+
import com.uber.cadence.RestartWorkflowExecutionRequest;
84+
import com.uber.cadence.RestartWorkflowExecutionResponse;
8385
import com.uber.cadence.ServiceBusyError;
86+
import com.uber.cadence.SignalWithStartWorkflowExecutionAsyncRequest;
87+
import com.uber.cadence.SignalWithStartWorkflowExecutionAsyncResponse;
8488
import com.uber.cadence.SignalWithStartWorkflowExecutionRequest;
8589
import com.uber.cadence.SignalWorkflowExecutionRequest;
90+
import com.uber.cadence.StartWorkflowExecutionAsyncRequest;
91+
import com.uber.cadence.StartWorkflowExecutionAsyncResponse;
8692
import com.uber.cadence.StartWorkflowExecutionRequest;
8793
import com.uber.cadence.StartWorkflowExecutionResponse;
8894
import com.uber.cadence.TerminateWorkflowExecutionRequest;
@@ -186,6 +192,14 @@ public void DeprecateDomain(DeprecateDomainRequest deprecateRequest)
186192
}
187193
}
188194

195+
@Override
196+
public RestartWorkflowExecutionResponse RestartWorkflowExecution(
197+
RestartWorkflowExecutionRequest restartRequest)
198+
throws BadRequestError, ServiceBusyError, DomainNotActiveError, LimitExceededError,
199+
EntityNotExistsError, ClientVersionNotSupportedError, TException {
200+
throw new IllegalArgumentException("unimplemented");
201+
}
202+
189203
@Override
190204
public StartWorkflowExecutionResponse StartWorkflowExecution(
191205
StartWorkflowExecutionRequest startRequest)
@@ -195,6 +209,15 @@ public StartWorkflowExecutionResponse StartWorkflowExecution(
195209
return startWorkflowExecution(startRequest);
196210
}
197211

212+
@Override
213+
public StartWorkflowExecutionAsyncResponse StartWorkflowExecutionAsync(
214+
StartWorkflowExecutionAsyncRequest startRequest)
215+
throws BadRequestError, WorkflowExecutionAlreadyStartedError, ServiceBusyError,
216+
DomainNotActiveError, LimitExceededError, EntityNotExistsError,
217+
ClientVersionNotSupportedError, TException {
218+
throw new IllegalArgumentException("unimplemented");
219+
}
220+
198221
private StartWorkflowExecutionResponse startWorkflowExecution(
199222
StartWorkflowExecutionRequest startRequest)
200223
throws BadRequestError, WorkflowExecutionAlreadyStartedError, ServiceBusyError,
@@ -468,6 +491,15 @@ public StartWorkflowExecutionResponse SignalWithStartWorkflowExecution(
468491
}
469492
}
470493

494+
@Override
495+
public SignalWithStartWorkflowExecutionAsyncResponse SignalWithStartWorkflowExecutionAsync(
496+
SignalWithStartWorkflowExecutionAsyncRequest signalWithStartRequest)
497+
throws BadRequestError, WorkflowExecutionAlreadyStartedError, ServiceBusyError,
498+
DomainNotActiveError, LimitExceededError, EntityNotExistsError,
499+
ClientVersionNotSupportedError, TException {
500+
throw new IllegalArgumentException("unimplemented");
501+
}
502+
471503
@Override
472504
public ResetWorkflowExecutionResponse ResetWorkflowExecution(
473505
ResetWorkflowExecutionRequest resetRequest)
@@ -769,13 +801,27 @@ public void DeprecateDomain(
769801
throw new UnsupportedOperationException("not implemented");
770802
}
771803

804+
@Override
805+
public void RestartWorkflowExecution(
806+
RestartWorkflowExecutionRequest restartRequest, AsyncMethodCallback resultHandler)
807+
throws TException {
808+
throw new IllegalArgumentException("unimplemented");
809+
}
810+
772811
@Override
773812
public void StartWorkflowExecution(
774813
StartWorkflowExecutionRequest startRequest, AsyncMethodCallback resultHandler)
775814
throws TException {
776815
throw new UnsupportedOperationException("not implemented");
777816
}
778817

818+
@Override
819+
public void StartWorkflowExecutionAsync(
820+
StartWorkflowExecutionAsyncRequest startRequest, AsyncMethodCallback resultHandler)
821+
throws TException {
822+
throw new IllegalArgumentException("unimplemented");
823+
}
824+
779825
@Override
780826
public void GetWorkflowExecutionHistory(
781827
GetWorkflowExecutionHistoryRequest getRequest, AsyncMethodCallback resultHandler)
@@ -905,6 +951,14 @@ public void SignalWithStartWorkflowExecution(
905951
throw new UnsupportedOperationException("not implemented");
906952
}
907953

954+
@Override
955+
public void SignalWithStartWorkflowExecutionAsync(
956+
SignalWithStartWorkflowExecutionAsyncRequest signalWithStartRequest,
957+
AsyncMethodCallback resultHandler)
958+
throws TException {
959+
throw new IllegalArgumentException("unimplemented");
960+
}
961+
908962
@Override
909963
public void ResetWorkflowExecution(
910964
ResetWorkflowExecutionRequest resetRequest, AsyncMethodCallback resultHandler)

src/main/java/com/uber/cadence/internal/sync/TestActivityEnvironmentInternal.java

Lines changed: 48 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -441,6 +441,15 @@ public StartWorkflowExecutionResponse SignalWithStartWorkflowExecution(
441441
return impl.SignalWithStartWorkflowExecution(signalWithStartRequest);
442442
}
443443

444+
@Override
445+
public SignalWithStartWorkflowExecutionAsyncResponse SignalWithStartWorkflowExecutionAsync(
446+
SignalWithStartWorkflowExecutionAsyncRequest signalWithStartRequest)
447+
throws BadRequestError, WorkflowExecutionAlreadyStartedError, ServiceBusyError,
448+
DomainNotActiveError, LimitExceededError, EntityNotExistsError,
449+
ClientVersionNotSupportedError, TException {
450+
return impl.SignalWithStartWorkflowExecutionAsync(signalWithStartRequest);
451+
}
452+
444453
@Override
445454
public ResetWorkflowExecutionResponse ResetWorkflowExecution(
446455
ResetWorkflowExecutionRequest resetRequest)
@@ -597,6 +606,13 @@ public void DeprecateDomain(
597606
impl.DeprecateDomain(deprecateRequest, resultHandler);
598607
}
599608

609+
@Override
610+
public void RestartWorkflowExecution(
611+
RestartWorkflowExecutionRequest restartRequest, AsyncMethodCallback resultHandler)
612+
throws TException {
613+
impl.RestartWorkflowExecution(restartRequest, resultHandler);
614+
}
615+
600616
@Override
601617
public void GetTaskListsByDomain(
602618
GetTaskListsByDomainRequest request, AsyncMethodCallback resultHandler)
@@ -611,6 +627,13 @@ public void StartWorkflowExecution(
611627
impl.StartWorkflowExecution(startRequest, resultHandler);
612628
}
613629

630+
@Override
631+
public void StartWorkflowExecutionAsync(
632+
StartWorkflowExecutionAsyncRequest startRequest, AsyncMethodCallback resultHandler)
633+
throws TException {
634+
impl.StartWorkflowExecutionAsync(startRequest, resultHandler);
635+
}
636+
614637
@Override
615638
public void StartWorkflowExecutionWithTimeout(
616639
StartWorkflowExecutionRequest startRequest,
@@ -751,6 +774,14 @@ public void SignalWithStartWorkflowExecution(
751774
impl.SignalWithStartWorkflowExecution(signalWithStartRequest, resultHandler);
752775
}
753776

777+
@Override
778+
public void SignalWithStartWorkflowExecutionAsync(
779+
SignalWithStartWorkflowExecutionAsyncRequest signalWithStartRequest,
780+
AsyncMethodCallback resultHandler)
781+
throws TException {
782+
impl.SignalWithStartWorkflowExecutionAsync(signalWithStartRequest, resultHandler);
783+
}
784+
754785
@Override
755786
public void ResetWorkflowExecution(
756787
ResetWorkflowExecutionRequest resetRequest, AsyncMethodCallback resultHandler)
@@ -889,6 +920,14 @@ public void DeprecateDomain(DeprecateDomainRequest deprecateRequest)
889920
impl.DeprecateDomain(deprecateRequest);
890921
}
891922

923+
@Override
924+
public RestartWorkflowExecutionResponse RestartWorkflowExecution(
925+
RestartWorkflowExecutionRequest restartRequest)
926+
throws BadRequestError, ServiceBusyError, DomainNotActiveError, LimitExceededError,
927+
EntityNotExistsError, ClientVersionNotSupportedError, TException {
928+
return impl.RestartWorkflowExecution(restartRequest);
929+
}
930+
892931
@Override
893932
public GetTaskListsByDomainResponse GetTaskListsByDomain(GetTaskListsByDomainRequest request)
894933
throws BadRequestError, EntityNotExistsError, LimitExceededError, ServiceBusyError,
@@ -904,6 +943,15 @@ public StartWorkflowExecutionResponse StartWorkflowExecution(
904943
return impl.StartWorkflowExecution(startRequest);
905944
}
906945

946+
@Override
947+
public StartWorkflowExecutionAsyncResponse StartWorkflowExecutionAsync(
948+
StartWorkflowExecutionAsyncRequest startRequest)
949+
throws BadRequestError, WorkflowExecutionAlreadyStartedError, ServiceBusyError,
950+
DomainNotActiveError, LimitExceededError, EntityNotExistsError,
951+
ClientVersionNotSupportedError, TException {
952+
return impl.StartWorkflowExecutionAsync(startRequest);
953+
}
954+
907955
@Override
908956
public GetWorkflowExecutionHistoryResponse GetWorkflowExecutionHistory(
909957
GetWorkflowExecutionHistoryRequest getRequest)

src/main/java/com/uber/cadence/internal/sync/TestWorkflowEnvironmentInternal.java

Lines changed: 54 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -79,9 +79,15 @@
7979
import com.uber.cadence.RespondDecisionTaskCompletedResponse;
8080
import com.uber.cadence.RespondDecisionTaskFailedRequest;
8181
import com.uber.cadence.RespondQueryTaskCompletedRequest;
82+
import com.uber.cadence.RestartWorkflowExecutionRequest;
83+
import com.uber.cadence.RestartWorkflowExecutionResponse;
8284
import com.uber.cadence.ServiceBusyError;
85+
import com.uber.cadence.SignalWithStartWorkflowExecutionAsyncRequest;
86+
import com.uber.cadence.SignalWithStartWorkflowExecutionAsyncResponse;
8387
import com.uber.cadence.SignalWithStartWorkflowExecutionRequest;
8488
import com.uber.cadence.SignalWorkflowExecutionRequest;
89+
import com.uber.cadence.StartWorkflowExecutionAsyncRequest;
90+
import com.uber.cadence.StartWorkflowExecutionAsyncResponse;
8591
import com.uber.cadence.StartWorkflowExecutionRequest;
8692
import com.uber.cadence.StartWorkflowExecutionResponse;
8793
import com.uber.cadence.TerminateWorkflowExecutionRequest;
@@ -338,6 +344,15 @@ public StartWorkflowExecutionResponse SignalWithStartWorkflowExecution(
338344
return impl.SignalWithStartWorkflowExecution(signalWithStartRequest);
339345
}
340346

347+
@Override
348+
public SignalWithStartWorkflowExecutionAsyncResponse SignalWithStartWorkflowExecutionAsync(
349+
SignalWithStartWorkflowExecutionAsyncRequest signalWithStartRequest)
350+
throws BadRequestError, WorkflowExecutionAlreadyStartedError, ServiceBusyError,
351+
DomainNotActiveError, LimitExceededError, EntityNotExistsError,
352+
ClientVersionNotSupportedError, TException {
353+
return impl.SignalWithStartWorkflowExecutionAsync(signalWithStartRequest);
354+
}
355+
341356
@Override
342357
public ResetWorkflowExecutionResponse ResetWorkflowExecution(
343358
ResetWorkflowExecutionRequest resetRequest) throws TException {
@@ -473,6 +488,13 @@ public void DeprecateDomain(
473488
impl.DeprecateDomain(deprecateRequest, resultHandler);
474489
}
475490

491+
@Override
492+
public void RestartWorkflowExecution(
493+
RestartWorkflowExecutionRequest restartRequest, AsyncMethodCallback resultHandler)
494+
throws TException {
495+
impl.RestartWorkflowExecution(restartRequest);
496+
}
497+
476498
@Override
477499
public void GetTaskListsByDomain(
478500
GetTaskListsByDomainRequest request, AsyncMethodCallback resultHandler)
@@ -487,6 +509,13 @@ public void StartWorkflowExecution(
487509
impl.StartWorkflowExecution(startRequest, resultHandler);
488510
}
489511

512+
@Override
513+
public void StartWorkflowExecutionAsync(
514+
StartWorkflowExecutionAsyncRequest startRequest, AsyncMethodCallback resultHandler)
515+
throws TException {
516+
impl.StartWorkflowExecutionAsync(startRequest, resultHandler);
517+
}
518+
490519
@Override
491520
public void StartWorkflowExecutionWithTimeout(
492521
StartWorkflowExecutionRequest startRequest,
@@ -632,6 +661,14 @@ public void SignalWithStartWorkflowExecution(
632661
impl.SignalWithStartWorkflowExecution(signalWithStartRequest, resultHandler);
633662
}
634663

664+
@Override
665+
public void SignalWithStartWorkflowExecutionAsync(
666+
SignalWithStartWorkflowExecutionAsyncRequest signalWithStartRequest,
667+
AsyncMethodCallback resultHandler)
668+
throws TException {
669+
impl.SignalWithStartWorkflowExecutionAsync(signalWithStartRequest, resultHandler);
670+
}
671+
635672
@Override
636673
public void ResetWorkflowExecution(
637674
ResetWorkflowExecutionRequest resetRequest, AsyncMethodCallback resultHandler)
@@ -769,6 +806,14 @@ public void DeprecateDomain(DeprecateDomainRequest deprecateRequest)
769806
impl.DeprecateDomain(deprecateRequest);
770807
}
771808

809+
@Override
810+
public RestartWorkflowExecutionResponse RestartWorkflowExecution(
811+
RestartWorkflowExecutionRequest restartRequest)
812+
throws BadRequestError, ServiceBusyError, DomainNotActiveError, LimitExceededError,
813+
EntityNotExistsError, ClientVersionNotSupportedError, TException {
814+
return impl.RestartWorkflowExecution(restartRequest);
815+
}
816+
772817
@Override
773818
public GetTaskListsByDomainResponse GetTaskListsByDomain(GetTaskListsByDomainRequest request)
774819
throws BadRequestError, EntityNotExistsError, LimitExceededError, ServiceBusyError,
@@ -784,6 +829,15 @@ public StartWorkflowExecutionResponse StartWorkflowExecution(
784829
return impl.StartWorkflowExecution(startRequest);
785830
}
786831

832+
@Override
833+
public StartWorkflowExecutionAsyncResponse StartWorkflowExecutionAsync(
834+
StartWorkflowExecutionAsyncRequest startRequest)
835+
throws BadRequestError, WorkflowExecutionAlreadyStartedError, ServiceBusyError,
836+
DomainNotActiveError, LimitExceededError, EntityNotExistsError,
837+
ClientVersionNotSupportedError, TException {
838+
return impl.StartWorkflowExecutionAsync(startRequest);
839+
}
840+
787841
@Override
788842
public GetWorkflowExecutionHistoryResponse GetWorkflowExecutionHistory(
789843
GetWorkflowExecutionHistoryRequest getRequest)

0 commit comments

Comments
 (0)