Skip to content

Commit 89e0a0c

Browse files
hpoettkerfmbenhassine
authored andcommitted
Deprecate overrides of StepBuilderHelper#repository for removal
1 parent dde5455 commit 89e0a0c

File tree

4 files changed

+27
-1
lines changed

4 files changed

+27
-1
lines changed

spring-batch-integration/src/main/java/org/springframework/batch/integration/chunk/RemoteChunkingManagerStepBuilder.java

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -227,7 +227,16 @@ public RemoteChunkingManagerStepBuilder<I, O> reader(ItemReader<? extends I> rea
227227
return this;
228228
}
229229

230+
/**
231+
* Set the job repository
232+
* @param jobRepository the repository to set
233+
* @return this to enable fluent chaining
234+
* @deprecated use
235+
* {@link RemoteChunkingManagerStepBuilder#RemoteChunkingManagerStepBuilder(String, JobRepository)}
236+
*/
230237
@Override
238+
@SuppressWarnings("removal")
239+
@Deprecated(since = "5.1", forRemoval = true)
231240
public RemoteChunkingManagerStepBuilder<I, O> repository(JobRepository jobRepository) {
232241
super.repository(jobRepository);
233242
return this;

spring-batch-integration/src/main/java/org/springframework/batch/integration/partition/RemotePartitioningManagerStepBuilder.java

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -242,7 +242,16 @@ private boolean isPolling() {
242242
return this.inputChannel == null;
243243
}
244244

245+
/**
246+
* Set the job repository
247+
* @param jobRepository the repository to set
248+
* @return this to enable fluent chaining
249+
* @deprecated use
250+
* {@link RemotePartitioningManagerStepBuilder#RemotePartitioningManagerStepBuilder(String, JobRepository)}
251+
*/
245252
@Override
253+
@SuppressWarnings("removal")
254+
@Deprecated(since = "5.1", forRemoval = true)
246255
public RemotePartitioningManagerStepBuilder repository(JobRepository jobRepository) {
247256
super.repository(jobRepository);
248257
return this;

spring-batch-integration/src/main/java/org/springframework/batch/integration/partition/RemotePartitioningWorkerStepBuilder.java

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -157,7 +157,16 @@ public RemotePartitioningWorkerStepBuilder beanFactory(BeanFactory beanFactory)
157157
return this;
158158
}
159159

160+
/**
161+
* Set the job repository
162+
* @param jobRepository the repository to set
163+
* @return this to enable fluent chaining
164+
* @deprecated use
165+
* {@link RemotePartitioningWorkerStepBuilder#RemotePartitioningWorkerStepBuilder(String, JobRepository)}
166+
*/
160167
@Override
168+
@SuppressWarnings("removal")
169+
@Deprecated(since = "5.1", forRemoval = true)
161170
public RemotePartitioningWorkerStepBuilder repository(JobRepository jobRepository) {
162171
super.repository(jobRepository);
163172
return this;

spring-batch-integration/src/test/java/org/springframework/batch/integration/chunk/RemoteChunkingManagerStepBuilderTests.java

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -190,7 +190,6 @@ void testUnsupportedOperationExceptionWhenSpecifyingAnItemWriter() {
190190
.reader(this.itemReader)
191191
.writer(items -> {
192192
})
193-
.repository(this.jobRepository)
194193
.transactionManager(this.transactionManager)
195194
.inputChannel(this.inputChannel)
196195
.outputChannel(this.outputChannel)

0 commit comments

Comments
 (0)