camel-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From davscl...@apache.org
Subject [1/2] camel git commit: CAMEL-8579 Upgrade to jclouds 1.9.x
Date Fri, 03 Apr 2015 15:49:40 GMT
Repository: camel
Updated Branches:
  refs/heads/master 9ff05dc66 -> ff38d130a


CAMEL-8579 Upgrade to jclouds 1.9.x


Project: http://git-wip-us.apache.org/repos/asf/camel/repo
Commit: http://git-wip-us.apache.org/repos/asf/camel/commit/0f18a3fa
Tree: http://git-wip-us.apache.org/repos/asf/camel/tree/0f18a3fa
Diff: http://git-wip-us.apache.org/repos/asf/camel/diff/0f18a3fa

Branch: refs/heads/master
Commit: 0f18a3fa333111694cb1ba4a61176b0436931fc0
Parents: 9ff05dc
Author: ancosen <ancosen@gmail.com>
Authored: Fri Apr 3 10:23:32 2015 +0200
Committer: Claus Ibsen <davsclaus@apache.org>
Committed: Fri Apr 3 17:33:57 2015 +0200

----------------------------------------------------------------------
 .../camel/component/jclouds/JcloudsPayloadConverter.java    | 9 +++++++--
 parent/pom.xml                                              | 2 +-
 2 files changed, 8 insertions(+), 3 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/camel/blob/0f18a3fa/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 7f3b4ef..c2ee88b 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
@@ -103,11 +103,16 @@ public final class JcloudsPayloadConverter {
     }
 
     @Converter
-    public static Payload toPayload(InputStream is, Exchange exchange) throws IOException
{
+    public static Payload toPayload(final InputStream is, Exchange exchange) throws IOException
{
         InputStreamPayload payload = new InputStreamPayload(is);
         // only set the contentlength if possible
         if (is.markSupported()) {
-            long contentLength = ByteStreams.length(payload);
+            long contentLength = ByteStreams.length(new InputSupplier<InputStream>()
{
+                @Override
+                public InputStream getInput() throws IOException {
+                    return is;
+                }
+            });
             is.reset();
             payload.getContentMetadata().setContentLength(contentLength);
         }

http://git-wip-us.apache.org/repos/asf/camel/blob/0f18a3fa/parent/pom.xml
----------------------------------------------------------------------
diff --git a/parent/pom.xml b/parent/pom.xml
index 5bc200b2..d6bd994 100644
--- a/parent/pom.xml
+++ b/parent/pom.xml
@@ -248,7 +248,7 @@
     <jboss-javaee-6-version>1.0.0.Final</jboss-javaee-6-version>
     <jboss-logging-version>3.1.4.GA</jboss-logging-version>
     <jboss-marshalling-version>1.3.18.GA</jboss-marshalling-version>
-    <jclouds-version>1.8.1</jclouds-version>
+    <jclouds-version>1.9.0</jclouds-version>
     <!-- jclouds must use this guava version -->
     <jclouds-google-guava-version>17.0</jclouds-google-guava-version>
     <jcr-version>2.0</jcr-version>


Mime
View raw message