From 426c8e674be6c802f10ead0beef1bba61f16f7ab Mon Sep 17 00:00:00 2001 From: Dave Syer Date: Mon, 22 Nov 2010 09:41:49 +0000 Subject: [PATCH] BATCH-1651: removed unnecessary synchronized block --- .../item/support/CompositeItemStream.java | 18 ++++++------------ 1 file changed, 6 insertions(+), 12 deletions(-) diff --git a/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/support/CompositeItemStream.java b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/support/CompositeItemStream.java index 7568718ba..3db7ce1db 100644 --- a/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/support/CompositeItemStream.java +++ b/spring-batch-infrastructure/src/main/java/org/springframework/batch/item/support/CompositeItemStream.java @@ -69,10 +69,8 @@ public class CompositeItemStream implements ItemStream { * @see org.springframework.batch.item.ItemStream#update(ExecutionContext) */ public void update(ExecutionContext executionContext) { - synchronized (streams) { - for (ItemStream itemStream : streams) { - itemStream.update(executionContext); - } + for (ItemStream itemStream : streams) { + itemStream.update(executionContext); } } @@ -81,10 +79,8 @@ public class CompositeItemStream implements ItemStream { * @throws ItemStreamException */ public void close() throws ItemStreamException { - synchronized (streams) { - for (ItemStream itemStream : streams) { - itemStream.close(); - } + for (ItemStream itemStream : streams) { + itemStream.close(); } } @@ -93,10 +89,8 @@ public class CompositeItemStream implements ItemStream { * @throws ItemStreamException */ public void open(ExecutionContext executionContext) throws ItemStreamException { - synchronized (streams) { - for (ItemStream itemStream : streams) { - itemStream.open(executionContext); - } + for (ItemStream itemStream : streams) { + itemStream.open(executionContext); } }