You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@camel.apache.org by ni...@apache.org on 2013/10/23 16:34:36 UTC
[1/2] git commit: CAMEL-6888 fixed the stream copy issue of
JcloudsPayloadConverter
Updated Branches:
refs/heads/camel-2.11.x d5663eb2c -> 6780b7d9e
refs/heads/camel-2.12.x c4b376472 -> 4e6bab3bb
CAMEL-6888 fixed the stream copy issue of JcloudsPayloadConverter
Project: http://git-wip-us.apache.org/repos/asf/camel/repo
Commit: http://git-wip-us.apache.org/repos/asf/camel/commit/6780b7d9
Tree: http://git-wip-us.apache.org/repos/asf/camel/tree/6780b7d9
Diff: http://git-wip-us.apache.org/repos/asf/camel/diff/6780b7d9
Branch: refs/heads/camel-2.11.x
Commit: 6780b7d9eea06e87de2d1eec9ece162a582b2c5e
Parents: d5663eb
Author: Willem Jiang <ni...@apache.org>
Authored: Wed Oct 23 21:20:00 2013 +0800
Committer: Willem Jiang <wi...@gmail.com>
Committed: Wed Oct 23 22:33:10 2013 +0800
----------------------------------------------------------------------
.../apache/camel/component/jclouds/JcloudsPayloadConverter.java | 2 ++
1 file changed, 2 insertions(+)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/camel/blob/6780b7d9/components/camel-jclouds/src/main/java/org/apache/camel/component/jclouds/JcloudsPayloadConverter.java
----------------------------------------------------------------------
diff --git a/components/camel-jclouds/src/main/java/org/apache/camel/component/jclouds/JcloudsPayloadConverter.java b/components/camel-jclouds/src/main/java/org/apache/camel/component/jclouds/JcloudsPayloadConverter.java
index 4f41197..11e904b 100644
--- a/components/camel-jclouds/src/main/java/org/apache/camel/component/jclouds/JcloudsPayloadConverter.java
+++ b/components/camel-jclouds/src/main/java/org/apache/camel/component/jclouds/JcloudsPayloadConverter.java
@@ -30,6 +30,7 @@ import org.apache.camel.component.file.GenericFile;
import org.apache.camel.converter.stream.CachedOutputStream;
import org.apache.camel.converter.stream.StreamSourceCache;
import org.apache.camel.spi.TypeConverterRegistry;
+import org.apache.camel.util.IOHelper;
import org.jclouds.io.Payload;
import org.jclouds.io.payloads.ByteArrayPayload;
import org.jclouds.io.payloads.FilePayload;
@@ -68,6 +69,7 @@ public final class JcloudsPayloadConverter {
return payload;
} else {
CachedOutputStream cos = new CachedOutputStream(exchange);
+ IOHelper.copy(is, cos);
return toPayload(cos.getWrappedInputStream(), exchange);
}
}
[2/2] git commit: CAMEL-6888 fixed the stream copy issue of
JcloudsPayloadConverter
Posted by ni...@apache.org.
CAMEL-6888 fixed the stream copy issue of JcloudsPayloadConverter
Project: http://git-wip-us.apache.org/repos/asf/camel/repo
Commit: http://git-wip-us.apache.org/repos/asf/camel/commit/4e6bab3b
Tree: http://git-wip-us.apache.org/repos/asf/camel/tree/4e6bab3b
Diff: http://git-wip-us.apache.org/repos/asf/camel/diff/4e6bab3b
Branch: refs/heads/camel-2.12.x
Commit: 4e6bab3bb85221129f838ad6df77fc6f53c5885b
Parents: c4b3764
Author: Willem Jiang <ni...@apache.org>
Authored: Wed Oct 23 21:20:00 2013 +0800
Committer: Willem Jiang <wi...@gmail.com>
Committed: Wed Oct 23 22:33:55 2013 +0800
----------------------------------------------------------------------
.../apache/camel/component/jclouds/JcloudsPayloadConverter.java | 2 ++
1 file changed, 2 insertions(+)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/camel/blob/4e6bab3b/components/camel-jclouds/src/main/java/org/apache/camel/component/jclouds/JcloudsPayloadConverter.java
----------------------------------------------------------------------
diff --git a/components/camel-jclouds/src/main/java/org/apache/camel/component/jclouds/JcloudsPayloadConverter.java b/components/camel-jclouds/src/main/java/org/apache/camel/component/jclouds/JcloudsPayloadConverter.java
index 4f41197..11e904b 100644
--- a/components/camel-jclouds/src/main/java/org/apache/camel/component/jclouds/JcloudsPayloadConverter.java
+++ b/components/camel-jclouds/src/main/java/org/apache/camel/component/jclouds/JcloudsPayloadConverter.java
@@ -30,6 +30,7 @@ import org.apache.camel.component.file.GenericFile;
import org.apache.camel.converter.stream.CachedOutputStream;
import org.apache.camel.converter.stream.StreamSourceCache;
import org.apache.camel.spi.TypeConverterRegistry;
+import org.apache.camel.util.IOHelper;
import org.jclouds.io.Payload;
import org.jclouds.io.payloads.ByteArrayPayload;
import org.jclouds.io.payloads.FilePayload;
@@ -68,6 +69,7 @@ public final class JcloudsPayloadConverter {
return payload;
} else {
CachedOutputStream cos = new CachedOutputStream(exchange);
+ IOHelper.copy(is, cos);
return toPayload(cos.getWrappedInputStream(), exchange);
}
}