Skip to content

Commit

Permalink
address comments to remove use docker
Browse files Browse the repository at this point in the history
  • Loading branch information
shijiesheng committed Nov 8, 2024
1 parent 235a768 commit c8f85be
Showing 1 changed file with 2 additions and 14 deletions.
16 changes: 2 additions & 14 deletions src/test/java/com/uber/cadence/workflow/WorkflowMigrationTest.java
Original file line number Diff line number Diff line change
Expand Up @@ -30,9 +30,7 @@
import com.uber.cadence.migration.MigrationActivitiesImpl;
import com.uber.cadence.migration.MigrationIWorkflowService;
import com.uber.cadence.migration.MigrationInterceptorFactory;
import com.uber.cadence.serviceclient.ClientOptions;
import com.uber.cadence.serviceclient.IWorkflowService;
import com.uber.cadence.serviceclient.WorkflowServiceTChannel;
import com.uber.cadence.testUtils.CadenceTestRule;
import com.uber.cadence.worker.Worker;
import com.uber.cadence.worker.WorkerFactory;
Expand All @@ -46,7 +44,6 @@

public class WorkflowMigrationTest {
private WorkflowClient migrationWorkflowClient, workflowClientCurr, workflowClientNew;
private boolean useDockerService = Boolean.parseBoolean(System.getenv("USE_DOCKER_SERVICE"));
private static final String TASKLIST = "TASKLIST";
private TracingWorkflowInterceptorFactory tracer;
WorkerFactory factoryCurr, factoryNew;
Expand All @@ -60,15 +57,6 @@ public class WorkflowMigrationTest {
public void setUp() {
IWorkflowService serviceCur = testRuleCur.getWorkflowClient().getService();
IWorkflowService serviceNew = testRuleNew.getWorkflowClient().getService();
if (useDockerService) {
serviceCur =
new WorkflowServiceTChannel(
ClientOptions.newBuilder()
.setFeatureFlags(
new FeatureFlags().setWorkflowExecutionAlreadyCompletedErrorEnabled(true))
.build());
serviceNew = serviceCur; // docker only starts one server so share the same service
}
workflowClientCurr =
WorkflowClient.newInstance(
serviceCur, WorkflowClientOptions.newBuilder().setDomain(DOMAIN).build());
Expand Down Expand Up @@ -161,7 +149,7 @@ public void execute(int iter) {
}

@Test
public void whenUseDockerService_cronWorkflowMigration() {
public void cronWorkflowMigration() {
String workflowID = UUID.randomUUID().toString();
try {
workflowClientCurr
Expand All @@ -178,7 +166,7 @@ public void whenUseDockerService_cronWorkflowMigration() {
}

@Test
public void whenUseDockerService_continueAsNewWorkflowMigration() {
public void continueAsNewWorkflowMigration() {
String workflowID = UUID.randomUUID().toString();
try {
workflowClientCurr
Expand Down

0 comments on commit c8f85be

Please sign in to comment.