Skip to content

Commit ff19e23

Browse files
authored
Remove thinTaskExecutionList from TaskTemplate (spring-attic#5842)
ThinTaskExecutions are not a part of SCDF-3.0.x. During the migration some of the ThinTaskExecution URL calls were left in the rest client and this caused some test failures in IT. This PR removes the API access from the client for ThinTaskExecutions.
1 parent ebe2ce8 commit ff19e23

File tree

2 files changed

+2
-22
lines changed

2 files changed

+2
-22
lines changed

spring-cloud-dataflow-rest-client/src/main/java/org/springframework/cloud/dataflow/rest/client/TaskOperations.java

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -108,11 +108,6 @@ public interface TaskOperations {
108108
*/
109109
PagedModel<TaskExecutionResource> executionList();
110110

111-
/**
112-
* @return the list of thin task executions known to the system.
113-
*/
114-
PagedModel<TaskExecutionThinResource> thinExecutionList();
115-
116111
/**
117112
* List task executions known to the system filtered by task name.
118113
*

spring-cloud-dataflow-rest-client/src/main/java/org/springframework/cloud/dataflow/rest/client/TaskTemplate.java

Lines changed: 2 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -69,8 +69,6 @@ public class TaskTemplate implements TaskOperations {
6969
private static final String VALIDATION_THIN_TASK_VERSION = "2.11.3";
7070
private static final String EXECUTIONS_RELATION = "tasks/executions";
7171

72-
private static final String THIN_EXECUTIONS_RELATION = "tasks/thinexecutions";
73-
7472
private static final String EXECUTIONS_CURRENT_RELATION = "tasks/executions/current";
7573

7674
private static final String EXECUTION_RELATION = "tasks/executions/execution";
@@ -95,8 +93,6 @@ public class TaskTemplate implements TaskOperations {
9593

9694
private final Link executionsLink;
9795

98-
private final Link thinExecutionsLink;
99-
10096
private final Link executionLink;
10197

10298
private final Link executionLaunchLink;
@@ -131,8 +127,7 @@ public class TaskTemplate implements TaskOperations {
131127
EXECUTIONS_INFO_RELATION,
132128
PLATFORM_LIST_RELATION,
133129
RETRIEVE_LOG,
134-
VALIDATION_REL,
135-
THIN_EXECUTIONS_RELATION
130+
VALIDATION_REL
136131
).forEach(relation -> {
137132
Assert.isTrue(resources.getLink(relation).isPresent(), () -> relation + " relation is required");
138133
});
@@ -147,12 +142,7 @@ public class TaskTemplate implements TaskOperations {
147142
} else {
148143
this.executionsCurrentLink = null;
149144
}
150-
if(VersionUtils.isDataFlowServerVersionGreaterThanOrEqualToRequiredVersion(version, VALIDATION_THIN_TASK_VERSION)) {
151-
Assert.isTrue(resources.getLink(THIN_EXECUTIONS_RELATION).isPresent(), () -> THIN_EXECUTIONS_RELATION + " relation is required");
152-
this.thinExecutionsLink = resources.getLink(THIN_EXECUTIONS_RELATION).get();
153-
} else {
154-
this.thinExecutionsLink = null;
155-
}
145+
156146
this.restTemplate = restTemplate;
157147
this.aboutLink = resources.getLink("about").get();
158148
this.definitionsLink = resources.getLink(DEFINITIONS_RELATION).get();
@@ -265,11 +255,6 @@ public TaskExecutionResource.Page executionList() {
265255
return restTemplate.getForObject(executionsLink.getHref(), TaskExecutionResource.Page.class);
266256
}
267257

268-
@Override
269-
public PagedModel<TaskExecutionThinResource> thinExecutionList() {
270-
return restTemplate.getForObject(thinExecutionsLink.getHref(), TaskExecutionThinResource.Page.class);
271-
}
272-
273258
@Override
274259
public TaskExecutionResource.Page executionListByTaskName(String taskName) {
275260
return restTemplate.getForObject(executionByNameLink.expand(taskName).getHref(),

0 commit comments

Comments
 (0)