Skip to content

Commit

Permalink
adding workaround for FlatFileItemWriter JIRA issues
Browse files Browse the repository at this point in the history
  • Loading branch information
alvinhenrick committed Jun 25, 2014
1 parent 656b4c4 commit d80e067
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions src/main/java/com/batch/partition/BatchConfiguration.java
Original file line number Diff line number Diff line change
Expand Up @@ -91,6 +91,7 @@ public ItemProcessor<User, User> processor() {
@StepScope
@Bean
public FlatFileItemWriter<User> writer(@Value("#{stepExecutionContext[fromId]}") Integer fromId, @Value("#{stepExecutionContext[toId]}") Integer toId) {
//https://jira.spring.io/browse/BATCH-2097
FlatFileItemWriter<User> writer = new FlatFileItemWriter<User>();
writer.setResource(new FileSystemResource("csv/outputs/users.processed-"+fromId+"-"+toId+".csv"));
writer.setAppendAllowed(false);
Expand Down

0 comments on commit d80e067

Please sign in to comment.