You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@camel.apache.org by da...@apache.org on 2016/11/07 19:25:15 UTC
[1/4] camel git commit: CAMEL-10449 - Set CXF SoapAction header
correctly
Repository: camel
Updated Branches:
refs/heads/camel-2.18.x 7530b37ef -> 13af4f0c9
refs/heads/master 583bec8fb -> 1c20543ba
CAMEL-10449 - Set CXF SoapAction header correctly
Project: http://git-wip-us.apache.org/repos/asf/camel/repo
Commit: http://git-wip-us.apache.org/repos/asf/camel/commit/f7181595
Tree: http://git-wip-us.apache.org/repos/asf/camel/tree/f7181595
Diff: http://git-wip-us.apache.org/repos/asf/camel/diff/f7181595
Branch: refs/heads/master
Commit: f71815955ef536a1b63a2525a86c7aca3a3596b8
Parents: 583bec8
Author: jpoth <po...@gmail.com>
Authored: Mon Nov 7 15:30:54 2016 +0100
Committer: Claus Ibsen <da...@apache.org>
Committed: Mon Nov 7 20:20:21 2016 +0100
----------------------------------------------------------------------
.../camel/component/cxf/DefaultCxfBinding.java | 1 +
.../component/cxf/DefaultCxfBindingTest.java | 18 ++++++++++++++++++
2 files changed, 19 insertions(+)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/camel/blob/f7181595/components/camel-cxf/src/main/java/org/apache/camel/component/cxf/DefaultCxfBinding.java
----------------------------------------------------------------------
diff --git a/components/camel-cxf/src/main/java/org/apache/camel/component/cxf/DefaultCxfBinding.java b/components/camel-cxf/src/main/java/org/apache/camel/component/cxf/DefaultCxfBinding.java
index de771da..89acf0f 100644
--- a/components/camel-cxf/src/main/java/org/apache/camel/component/cxf/DefaultCxfBinding.java
+++ b/components/camel-cxf/src/main/java/org/apache/camel/component/cxf/DefaultCxfBinding.java
@@ -728,6 +728,7 @@ public class DefaultCxfBinding implements CxfBinding, HeaderFilterStrategyAware
// from the previous request or response propagated with the invocation context
cxfContext.remove(Message.PROTOCOL_HEADERS);
}
+ cxfContext.put(SoapBindingConstants.SOAP_ACTION, camelHeaders.get(SoapBindingConstants.SOAP_ACTION));
}
protected static Object getContentFromCxf(Message message, DataFormat dataFormat, String encoding) {
http://git-wip-us.apache.org/repos/asf/camel/blob/f7181595/components/camel-cxf/src/test/java/org/apache/camel/component/cxf/DefaultCxfBindingTest.java
----------------------------------------------------------------------
diff --git a/components/camel-cxf/src/test/java/org/apache/camel/component/cxf/DefaultCxfBindingTest.java b/components/camel-cxf/src/test/java/org/apache/camel/component/cxf/DefaultCxfBindingTest.java
index a700832..2ef1fd8 100644
--- a/components/camel-cxf/src/test/java/org/apache/camel/component/cxf/DefaultCxfBindingTest.java
+++ b/components/camel-cxf/src/test/java/org/apache/camel/component/cxf/DefaultCxfBindingTest.java
@@ -45,6 +45,7 @@ import org.apache.camel.spi.HeaderFilterStrategy;
import org.apache.camel.util.IOHelper;
import org.apache.cxf.attachment.AttachmentImpl;
import org.apache.cxf.binding.Binding;
+import org.apache.cxf.binding.soap.SoapBindingConstants;
import org.apache.cxf.endpoint.Client;
import org.apache.cxf.endpoint.Endpoint;
import org.apache.cxf.helpers.CastUtils;
@@ -184,6 +185,23 @@ public class DefaultCxfBindingTest extends Assert {
assertEquals("att-1", att.getId());
assertEquals("value 1", att.getHeader("attachment-header"));
}
+
+ @Test
+ public void testPopulateCxfSoapHeaderRequestFromExchange() {
+ DefaultCxfBinding cxfBinding = new DefaultCxfBinding();
+ cxfBinding.setHeaderFilterStrategy(new DefaultHeaderFilterStrategy());
+ Exchange exchange = new DefaultExchange(context);
+ org.apache.cxf.message.Exchange cxfExchange = new org.apache.cxf.message.ExchangeImpl();
+ Map<String, Object> requestContext = new HashMap<>();
+
+ String expectedSoapActionHeader = "urn:hello:world";
+ exchange.getIn().setHeader("soapAction", expectedSoapActionHeader);
+
+ cxfBinding.populateCxfRequestFromExchange(cxfExchange, exchange, requestContext);
+
+ String actualSoapActionHeader = (String)requestContext.get(SoapBindingConstants.SOAP_ACTION);
+ assertEquals(expectedSoapActionHeader,actualSoapActionHeader);
+ }
@Test
public void testPopupalteExchangeFromCxfResponse() {
[3/4] camel git commit: CAMEL-10449 - Set CXF SoapAction header
correctly
Posted by da...@apache.org.
CAMEL-10449 - Set CXF SoapAction header correctly
Project: http://git-wip-us.apache.org/repos/asf/camel/repo
Commit: http://git-wip-us.apache.org/repos/asf/camel/commit/bb1803c8
Tree: http://git-wip-us.apache.org/repos/asf/camel/tree/bb1803c8
Diff: http://git-wip-us.apache.org/repos/asf/camel/diff/bb1803c8
Branch: refs/heads/camel-2.18.x
Commit: bb1803c8b799713d24169b642bdf756f3479aa8c
Parents: 7530b37
Author: jpoth <po...@gmail.com>
Authored: Mon Nov 7 15:30:54 2016 +0100
Committer: Claus Ibsen <da...@apache.org>
Committed: Mon Nov 7 20:24:58 2016 +0100
----------------------------------------------------------------------
.../camel/component/cxf/DefaultCxfBinding.java | 1 +
.../component/cxf/DefaultCxfBindingTest.java | 18 ++++++++++++++++++
2 files changed, 19 insertions(+)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/camel/blob/bb1803c8/components/camel-cxf/src/main/java/org/apache/camel/component/cxf/DefaultCxfBinding.java
----------------------------------------------------------------------
diff --git a/components/camel-cxf/src/main/java/org/apache/camel/component/cxf/DefaultCxfBinding.java b/components/camel-cxf/src/main/java/org/apache/camel/component/cxf/DefaultCxfBinding.java
index de771da..89acf0f 100644
--- a/components/camel-cxf/src/main/java/org/apache/camel/component/cxf/DefaultCxfBinding.java
+++ b/components/camel-cxf/src/main/java/org/apache/camel/component/cxf/DefaultCxfBinding.java
@@ -728,6 +728,7 @@ public class DefaultCxfBinding implements CxfBinding, HeaderFilterStrategyAware
// from the previous request or response propagated with the invocation context
cxfContext.remove(Message.PROTOCOL_HEADERS);
}
+ cxfContext.put(SoapBindingConstants.SOAP_ACTION, camelHeaders.get(SoapBindingConstants.SOAP_ACTION));
}
protected static Object getContentFromCxf(Message message, DataFormat dataFormat, String encoding) {
http://git-wip-us.apache.org/repos/asf/camel/blob/bb1803c8/components/camel-cxf/src/test/java/org/apache/camel/component/cxf/DefaultCxfBindingTest.java
----------------------------------------------------------------------
diff --git a/components/camel-cxf/src/test/java/org/apache/camel/component/cxf/DefaultCxfBindingTest.java b/components/camel-cxf/src/test/java/org/apache/camel/component/cxf/DefaultCxfBindingTest.java
index a700832..2ef1fd8 100644
--- a/components/camel-cxf/src/test/java/org/apache/camel/component/cxf/DefaultCxfBindingTest.java
+++ b/components/camel-cxf/src/test/java/org/apache/camel/component/cxf/DefaultCxfBindingTest.java
@@ -45,6 +45,7 @@ import org.apache.camel.spi.HeaderFilterStrategy;
import org.apache.camel.util.IOHelper;
import org.apache.cxf.attachment.AttachmentImpl;
import org.apache.cxf.binding.Binding;
+import org.apache.cxf.binding.soap.SoapBindingConstants;
import org.apache.cxf.endpoint.Client;
import org.apache.cxf.endpoint.Endpoint;
import org.apache.cxf.helpers.CastUtils;
@@ -184,6 +185,23 @@ public class DefaultCxfBindingTest extends Assert {
assertEquals("att-1", att.getId());
assertEquals("value 1", att.getHeader("attachment-header"));
}
+
+ @Test
+ public void testPopulateCxfSoapHeaderRequestFromExchange() {
+ DefaultCxfBinding cxfBinding = new DefaultCxfBinding();
+ cxfBinding.setHeaderFilterStrategy(new DefaultHeaderFilterStrategy());
+ Exchange exchange = new DefaultExchange(context);
+ org.apache.cxf.message.Exchange cxfExchange = new org.apache.cxf.message.ExchangeImpl();
+ Map<String, Object> requestContext = new HashMap<>();
+
+ String expectedSoapActionHeader = "urn:hello:world";
+ exchange.getIn().setHeader("soapAction", expectedSoapActionHeader);
+
+ cxfBinding.populateCxfRequestFromExchange(cxfExchange, exchange, requestContext);
+
+ String actualSoapActionHeader = (String)requestContext.get(SoapBindingConstants.SOAP_ACTION);
+ assertEquals(expectedSoapActionHeader,actualSoapActionHeader);
+ }
@Test
public void testPopupalteExchangeFromCxfResponse() {
[4/4] camel git commit: Fixed CS. This closes #1254
Posted by da...@apache.org.
Fixed CS. This closes #1254
Project: http://git-wip-us.apache.org/repos/asf/camel/repo
Commit: http://git-wip-us.apache.org/repos/asf/camel/commit/13af4f0c
Tree: http://git-wip-us.apache.org/repos/asf/camel/tree/13af4f0c
Diff: http://git-wip-us.apache.org/repos/asf/camel/diff/13af4f0c
Branch: refs/heads/camel-2.18.x
Commit: 13af4f0c9ff3d07b9b47e3f9040d1adf57154e8f
Parents: bb1803c
Author: Claus Ibsen <da...@apache.org>
Authored: Mon Nov 7 20:24:34 2016 +0100
Committer: Claus Ibsen <da...@apache.org>
Committed: Mon Nov 7 20:25:05 2016 +0100
----------------------------------------------------------------------
.../java/org/apache/camel/component/cxf/DefaultCxfBindingTest.java | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/camel/blob/13af4f0c/components/camel-cxf/src/test/java/org/apache/camel/component/cxf/DefaultCxfBindingTest.java
----------------------------------------------------------------------
diff --git a/components/camel-cxf/src/test/java/org/apache/camel/component/cxf/DefaultCxfBindingTest.java b/components/camel-cxf/src/test/java/org/apache/camel/component/cxf/DefaultCxfBindingTest.java
index 2ef1fd8..7e7b79f 100644
--- a/components/camel-cxf/src/test/java/org/apache/camel/component/cxf/DefaultCxfBindingTest.java
+++ b/components/camel-cxf/src/test/java/org/apache/camel/component/cxf/DefaultCxfBindingTest.java
@@ -200,7 +200,7 @@ public class DefaultCxfBindingTest extends Assert {
cxfBinding.populateCxfRequestFromExchange(cxfExchange, exchange, requestContext);
String actualSoapActionHeader = (String)requestContext.get(SoapBindingConstants.SOAP_ACTION);
- assertEquals(expectedSoapActionHeader,actualSoapActionHeader);
+ assertEquals(expectedSoapActionHeader, actualSoapActionHeader);
}
@Test
[2/4] camel git commit: Fixed CS. This closes #1254
Posted by da...@apache.org.
Fixed CS. This closes #1254
Project: http://git-wip-us.apache.org/repos/asf/camel/repo
Commit: http://git-wip-us.apache.org/repos/asf/camel/commit/1c20543b
Tree: http://git-wip-us.apache.org/repos/asf/camel/tree/1c20543b
Diff: http://git-wip-us.apache.org/repos/asf/camel/diff/1c20543b
Branch: refs/heads/master
Commit: 1c20543baeb4c2a6f308d1536edc1c7617e4733c
Parents: f718159
Author: Claus Ibsen <da...@apache.org>
Authored: Mon Nov 7 20:24:34 2016 +0100
Committer: Claus Ibsen <da...@apache.org>
Committed: Mon Nov 7 20:24:34 2016 +0100
----------------------------------------------------------------------
.../java/org/apache/camel/component/cxf/DefaultCxfBindingTest.java | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/camel/blob/1c20543b/components/camel-cxf/src/test/java/org/apache/camel/component/cxf/DefaultCxfBindingTest.java
----------------------------------------------------------------------
diff --git a/components/camel-cxf/src/test/java/org/apache/camel/component/cxf/DefaultCxfBindingTest.java b/components/camel-cxf/src/test/java/org/apache/camel/component/cxf/DefaultCxfBindingTest.java
index 2ef1fd8..7e7b79f 100644
--- a/components/camel-cxf/src/test/java/org/apache/camel/component/cxf/DefaultCxfBindingTest.java
+++ b/components/camel-cxf/src/test/java/org/apache/camel/component/cxf/DefaultCxfBindingTest.java
@@ -200,7 +200,7 @@ public class DefaultCxfBindingTest extends Assert {
cxfBinding.populateCxfRequestFromExchange(cxfExchange, exchange, requestContext);
String actualSoapActionHeader = (String)requestContext.get(SoapBindingConstants.SOAP_ACTION);
- assertEquals(expectedSoapActionHeader,actualSoapActionHeader);
+ assertEquals(expectedSoapActionHeader, actualSoapActionHeader);
}
@Test