camel-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ningji...@apache.org
Subject git commit: CAMEL-6590 Fixed Restlet header warnings with thanks to David
Date Wed, 31 Jul 2013 13:49:11 GMT
Updated Branches:
  refs/heads/camel-2.11.x fdb65509d -> 929609587


CAMEL-6590 Fixed Restlet header warnings with thanks to David


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

Branch: refs/heads/camel-2.11.x
Commit: 92960958794671118642b0551d01b9d8cb9abc6a
Parents: fdb6550
Author: Willem Jiang <ningjiang@apache.org>
Authored: Wed Jul 31 14:22:21 2013 +0800
Committer: Willem Jiang <ningjiang@apache.org>
Committed: Wed Jul 31 21:43:21 2013 +0800

----------------------------------------------------------------------
 .../camel/component/restlet/RestletHeaderFilterStrategy.java    | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/camel/blob/92960958/components/camel-restlet/src/main/java/org/apache/camel/component/restlet/RestletHeaderFilterStrategy.java
----------------------------------------------------------------------
diff --git a/components/camel-restlet/src/main/java/org/apache/camel/component/restlet/RestletHeaderFilterStrategy.java
b/components/camel-restlet/src/main/java/org/apache/camel/component/restlet/RestletHeaderFilterStrategy.java
index 62f44a1..a269169 100644
--- a/components/camel-restlet/src/main/java/org/apache/camel/component/restlet/RestletHeaderFilterStrategy.java
+++ b/components/camel-restlet/src/main/java/org/apache/camel/component/restlet/RestletHeaderFilterStrategy.java
@@ -18,6 +18,7 @@ package org.apache.camel.component.restlet;
 
 import org.apache.camel.Exchange;
 import org.apache.camel.impl.DefaultHeaderFilterStrategy;
+import org.restlet.engine.http.header.HeaderConstants;
 
 /**
  * Default header filtering strategy for Restlet
@@ -37,6 +38,8 @@ public class RestletHeaderFilterStrategy extends DefaultHeaderFilterStrategy
{
         // The "CamelAcceptContentType" header is not added to the outgoing HTTP 
         // headers but it will be going out as "Accept.
         getOutFilter().add(Exchange.ACCEPT_CONTENT_TYPE);
-
+        
+        // Remove the restlet headers from the out message.
+        getOutFilter().add(HeaderConstants.ATTRIBUTE_HEADERS);
     }
 }


Mime
View raw message