This is an automated email from the ASF dual-hosted git repository. davsclaus pushed a commit to branch CAMEL-13755 in repository https://gitbox.apache.org/repos/asf/camel.git
commit a1cce3314540307104b70011afd392805441afe7 Author: Claus Ibsen <claus.ib...@gmail.com> AuthorDate: Sun Jul 21 13:02:57 2019 +0200 CAMEL-13755: camel3 - Remove fault from camel-core/message and let it be component specific for camel-cxf and camel-spring-ws as its only used by SOAP-WS --- .../component/openstack/cinder/VolumeProducerTest.java | 16 ---------------- .../component/openstack/keystone/DomainProducerTest.java | 7 ------- .../component/openstack/keystone/GroupProducerTest.java | 7 ------- .../openstack/keystone/ProjectProducerTest.java | 7 ------- .../component/openstack/keystone/RegionProducerTest.java | 7 ------- .../component/openstack/keystone/UserProducerTest.java | 7 ------- .../component/openstack/neutron/NetworkProducerTest.java | 7 ------- .../component/openstack/neutron/PortProducerTest.java | 7 ------- .../component/openstack/neutron/RouterProducerTest.java | 7 ------- .../component/openstack/neutron/SubnetProducerTest.java | 7 ------- .../component/openstack/nova/FlavorProducerTest.java | 3 --- .../component/openstack/nova/ServerProducerTest.java | 7 ------- .../component/openstack/swift/ContainerProducerTest.java | 13 ------------- .../component/openstack/swift/ObjectProducerTest.java | 14 -------------- .../component/sjms/tx/TransactedQueueProducerTest.java | 10 ++++++++-- .../component/sjms/tx/TransactedTopicProducerTest.java | 10 ++++++++-- .../modules/ROOT/pages/activemq-component.adoc | 9 +++------ docs/components/modules/ROOT/pages/amqp-component.adoc | 9 +++------ docs/components/modules/ROOT/pages/jms-component.adoc | 10 +++------- docs/components/modules/ROOT/pages/spring-boot.adoc | 3 +-- 20 files changed, 26 insertions(+), 141 deletions(-) diff --git a/components/camel-openstack/src/test/java/org/apache/camel/component/openstack/cinder/VolumeProducerTest.java b/components/camel-openstack/src/test/java/org/apache/camel/component/openstack/cinder/VolumeProducerTest.java index adff34a..69bfbb2 100644 --- a/components/camel-openstack/src/test/java/org/apache/camel/component/openstack/cinder/VolumeProducerTest.java +++ b/components/camel-openstack/src/test/java/org/apache/camel/component/openstack/cinder/VolumeProducerTest.java @@ -114,22 +114,6 @@ public class VolumeProducerTest extends CinderProducerTestSupport { } @Test - public void updateVolumeFailTest() throws Exception { - final String faultMessage = "fault"; - when(volumeService.update(anyString(), anyString(), anyString())).thenReturn(ActionResponse.actionFailed(faultMessage, 401)); - - msg.setHeader(OpenstackConstants.OPERATION, OpenstackConstants.UPDATE); - final String id = "id"; - msg.setHeader(OpenstackConstants.ID, id); - msg.setBody(createTestVolume()); - - producer.process(exchange); - - assertTrue(msg.getExchange().isFailed()); - assertTrue(msg.getExchange().getException().getMessage().contains(faultMessage)); - } - - @Test public void getVolumeTest() throws Exception { when(endpoint.getOperation()).thenReturn(OpenstackConstants.GET); msg.setHeader(OpenstackConstants.ID, "anyID"); diff --git a/components/camel-openstack/src/test/java/org/apache/camel/component/openstack/keystone/DomainProducerTest.java b/components/camel-openstack/src/test/java/org/apache/camel/component/openstack/keystone/DomainProducerTest.java index 2e3b871..fa02d1e 100644 --- a/components/camel-openstack/src/test/java/org/apache/camel/component/openstack/keystone/DomainProducerTest.java +++ b/components/camel-openstack/src/test/java/org/apache/camel/component/openstack/keystone/DomainProducerTest.java @@ -152,13 +152,6 @@ public class DomainProducerTest extends KeystoneProducerTestSupport { verify(domainService).delete(domainIdCaptor.capture()); assertEquals(networkID, domainIdCaptor.getValue()); - - //in case of failure - final String failureMessage = "fail"; - when(domainService.delete(anyString())).thenReturn(ActionResponse.actionFailed(failureMessage, 404)); - producer.process(exchange); - assertTrue(msg.getExchange().isFailed()); - assertTrue(msg.getExchange().getException().getMessage().contains(failureMessage)); } private void assertEqualsDomain(Domain old, Domain newDomain) { diff --git a/components/camel-openstack/src/test/java/org/apache/camel/component/openstack/keystone/GroupProducerTest.java b/components/camel-openstack/src/test/java/org/apache/camel/component/openstack/keystone/GroupProducerTest.java index f8d4ca1..605c206 100644 --- a/components/camel-openstack/src/test/java/org/apache/camel/component/openstack/keystone/GroupProducerTest.java +++ b/components/camel-openstack/src/test/java/org/apache/camel/component/openstack/keystone/GroupProducerTest.java @@ -153,13 +153,6 @@ public class GroupProducerTest extends KeystoneProducerTestSupport { verify(groupService).delete(groupIdCaptor.capture()); assertEquals(networkID, groupIdCaptor.getValue()); - - //in case of failure - final String failureMessage = "fail"; - when(groupService.delete(anyString())).thenReturn(ActionResponse.actionFailed(failureMessage, 404)); - producer.process(exchange); - assertTrue(msg.getExchange().isFailed()); - assertTrue(msg.getExchange().getException().getMessage().contains(failureMessage)); } private void assertEqualsGroup(Group old, Group newGroup) { diff --git a/components/camel-openstack/src/test/java/org/apache/camel/component/openstack/keystone/ProjectProducerTest.java b/components/camel-openstack/src/test/java/org/apache/camel/component/openstack/keystone/ProjectProducerTest.java index 00e40c1..e1be336 100644 --- a/components/camel-openstack/src/test/java/org/apache/camel/component/openstack/keystone/ProjectProducerTest.java +++ b/components/camel-openstack/src/test/java/org/apache/camel/component/openstack/keystone/ProjectProducerTest.java @@ -155,13 +155,6 @@ public class ProjectProducerTest extends KeystoneProducerTestSupport { verify(projectService).delete(projectIdCaptor.capture()); assertEquals(networkID, projectIdCaptor.getValue()); - - //in case of failure - final String failureMessage = "fail"; - when(projectService.delete(anyString())).thenReturn(ActionResponse.actionFailed(failureMessage, 404)); - producer.process(exchange); - assertTrue(msg.getExchange().isFailed()); - assertTrue(msg.getExchange().getException().getMessage().contains(failureMessage)); } private void assertEqualsProject(Project old, Project newProject) { diff --git a/components/camel-openstack/src/test/java/org/apache/camel/component/openstack/keystone/RegionProducerTest.java b/components/camel-openstack/src/test/java/org/apache/camel/component/openstack/keystone/RegionProducerTest.java index 3fc8fa0..9e8b10a 100644 --- a/components/camel-openstack/src/test/java/org/apache/camel/component/openstack/keystone/RegionProducerTest.java +++ b/components/camel-openstack/src/test/java/org/apache/camel/component/openstack/keystone/RegionProducerTest.java @@ -149,13 +149,6 @@ public class RegionProducerTest extends KeystoneProducerTestSupport { verify(regionService).delete(regionIdCaptor.capture()); assertEquals(networkID, regionIdCaptor.getValue()); - - //in case of failure - final String failureMessage = "fail"; - when(regionService.delete(anyString())).thenReturn(ActionResponse.actionFailed(failureMessage, 404)); - producer.process(exchange); - assertTrue(msg.getExchange().isFailed()); - assertTrue(msg.getExchange().getException().getMessage().contains(failureMessage)); } private void assertEqualsRegion(Region old, Region newRegion) { diff --git a/components/camel-openstack/src/test/java/org/apache/camel/component/openstack/keystone/UserProducerTest.java b/components/camel-openstack/src/test/java/org/apache/camel/component/openstack/keystone/UserProducerTest.java index 1228f16..7d9722d 100644 --- a/components/camel-openstack/src/test/java/org/apache/camel/component/openstack/keystone/UserProducerTest.java +++ b/components/camel-openstack/src/test/java/org/apache/camel/component/openstack/keystone/UserProducerTest.java @@ -157,13 +157,6 @@ public class UserProducerTest extends KeystoneProducerTestSupport { verify(userService).delete(userIdCaptor.capture()); assertEquals(networkID, userIdCaptor.getValue()); - - //in case of failure - final String failureMessage = "fail"; - when(userService.delete(anyString())).thenReturn(ActionResponse.actionFailed(failureMessage, 404)); - producer.process(exchange); - assertTrue(msg.getExchange().isFailed()); - assertTrue(msg.getExchange().getException().getMessage().contains(failureMessage)); } private void assertEqualsUser(User old, User newUser) { diff --git a/components/camel-openstack/src/test/java/org/apache/camel/component/openstack/neutron/NetworkProducerTest.java b/components/camel-openstack/src/test/java/org/apache/camel/component/openstack/neutron/NetworkProducerTest.java index 32697b0..c7f15ed 100644 --- a/components/camel-openstack/src/test/java/org/apache/camel/component/openstack/neutron/NetworkProducerTest.java +++ b/components/camel-openstack/src/test/java/org/apache/camel/component/openstack/neutron/NetworkProducerTest.java @@ -133,13 +133,6 @@ public class NetworkProducerTest extends NeutronProducerTestSupport { verify(networkService).delete(networkIdCaptor.capture()); assertEquals(networkID, networkIdCaptor.getValue()); - - //in case of failure - final String failureMessage = "fail"; - when(networkService.delete(anyString())).thenReturn(ActionResponse.actionFailed(failureMessage, 404)); - producer.process(exchange); - assertTrue(msg.getExchange().isFailed()); - assertTrue(msg.getExchange().getException().getMessage().contains(failureMessage)); } private Network createNetwork() { diff --git a/components/camel-openstack/src/test/java/org/apache/camel/component/openstack/neutron/PortProducerTest.java b/components/camel-openstack/src/test/java/org/apache/camel/component/openstack/neutron/PortProducerTest.java index 0fbe05d..8af3d62 100644 --- a/components/camel-openstack/src/test/java/org/apache/camel/component/openstack/neutron/PortProducerTest.java +++ b/components/camel-openstack/src/test/java/org/apache/camel/component/openstack/neutron/PortProducerTest.java @@ -154,13 +154,6 @@ public class PortProducerTest extends NeutronProducerTestSupport { verify(portService).delete(portIdCaptor.capture()); assertEquals(portID, portIdCaptor.getValue()); - - //in case of failure - final String failureMessage = "fail"; - when(portService.delete(anyString())).thenReturn(ActionResponse.actionFailed(failureMessage, 404)); - producer.process(exchange); - assertTrue(msg.getExchange().isFailed()); - assertTrue(msg.getExchange().getException().getMessage().contains(failureMessage)); } private Port createPort() { diff --git a/components/camel-openstack/src/test/java/org/apache/camel/component/openstack/neutron/RouterProducerTest.java b/components/camel-openstack/src/test/java/org/apache/camel/component/openstack/neutron/RouterProducerTest.java index a950509..8b9aea8 100644 --- a/components/camel-openstack/src/test/java/org/apache/camel/component/openstack/neutron/RouterProducerTest.java +++ b/components/camel-openstack/src/test/java/org/apache/camel/component/openstack/neutron/RouterProducerTest.java @@ -162,13 +162,6 @@ public class RouterProducerTest extends NeutronProducerTestSupport { verify(routerService).delete(routerIdCaptor.capture()); assertEquals(routerID, routerIdCaptor.getValue()); - - //in case of failure - final String failureMessage = "fail"; - when(routerService.delete(anyString())).thenReturn(ActionResponse.actionFailed(failureMessage, 404)); - producer.process(exchange); - assertTrue(msg.getExchange().isFailed()); - assertTrue(msg.getExchange().getException().getMessage().contains(failureMessage)); } @Test diff --git a/components/camel-openstack/src/test/java/org/apache/camel/component/openstack/neutron/SubnetProducerTest.java b/components/camel-openstack/src/test/java/org/apache/camel/component/openstack/neutron/SubnetProducerTest.java index eff4fb4..692fd78 100644 --- a/components/camel-openstack/src/test/java/org/apache/camel/component/openstack/neutron/SubnetProducerTest.java +++ b/components/camel-openstack/src/test/java/org/apache/camel/component/openstack/neutron/SubnetProducerTest.java @@ -132,13 +132,6 @@ public class SubnetProducerTest extends NeutronProducerTestSupport { verify(subnetService).delete(subnetIdCaptor.capture()); assertEquals(subnetID, subnetIdCaptor.getValue()); - - //in case of failure - final String failureMessage = "fail"; - when(subnetService.delete(anyString())).thenReturn(ActionResponse.actionFailed(failureMessage, 404)); - producer.process(exchange); - assertTrue(msg.getExchange().isFailed()); - assertTrue(msg.getExchange().getException().getMessage().contains(failureMessage)); } private Subnet createSubnet() { diff --git a/components/camel-openstack/src/test/java/org/apache/camel/component/openstack/nova/FlavorProducerTest.java b/components/camel-openstack/src/test/java/org/apache/camel/component/openstack/nova/FlavorProducerTest.java index 0aa83f5..d4b7723 100644 --- a/components/camel-openstack/src/test/java/org/apache/camel/component/openstack/nova/FlavorProducerTest.java +++ b/components/camel-openstack/src/test/java/org/apache/camel/component/openstack/nova/FlavorProducerTest.java @@ -178,9 +178,6 @@ public class FlavorProducerTest extends NovaProducerTestSupport { verify(flavorService).delete(flavorIdCaptor.capture()); assertEquals(id, flavorIdCaptor.getValue()); - - assertTrue(msg.getExchange().isFailed()); - assertTrue(msg.getExchange().getException().getMessage().contains(failReason)); } private Flavor createTestFlavor() { diff --git a/components/camel-openstack/src/test/java/org/apache/camel/component/openstack/nova/ServerProducerTest.java b/components/camel-openstack/src/test/java/org/apache/camel/component/openstack/nova/ServerProducerTest.java index 768b9e0..cde240d 100644 --- a/components/camel-openstack/src/test/java/org/apache/camel/component/openstack/nova/ServerProducerTest.java +++ b/components/camel-openstack/src/test/java/org/apache/camel/component/openstack/nova/ServerProducerTest.java @@ -121,13 +121,6 @@ public class ServerProducerTest extends NovaProducerTestSupport { assertEquals(id, idArgumentCaptor.getValue()); assertTrue(actionArgumentCaptor.getValue() == Action.PAUSE); assertNull(msg.getBody()); - - //test fail - final String failReason = "fr"; - when(serverService.action(anyString(), any())).thenReturn(ActionResponse.actionFailed(failReason, 401)); - producer.process(exchange); - assertTrue(msg.getExchange().isFailed()); - assertTrue(msg.getExchange().getException().getMessage().contains(failReason)); } @Test diff --git a/components/camel-openstack/src/test/java/org/apache/camel/component/openstack/swift/ContainerProducerTest.java b/components/camel-openstack/src/test/java/org/apache/camel/component/openstack/swift/ContainerProducerTest.java index c9327e6..6478b04 100644 --- a/components/camel-openstack/src/test/java/org/apache/camel/component/openstack/swift/ContainerProducerTest.java +++ b/components/camel-openstack/src/test/java/org/apache/camel/component/openstack/swift/ContainerProducerTest.java @@ -152,19 +152,6 @@ public class ContainerProducerTest extends SwiftProducerTestSupport { } @Test - public void deleteObjectFailTest() throws Exception { - final String failMessage = "fail"; - when(containerService.delete(anyString())).thenReturn(ActionResponse.actionFailed(failMessage, 401)); - msg.setHeader(OpenstackConstants.OPERATION, OpenstackConstants.DELETE); - msg.setHeader(SwiftConstants.CONTAINER_NAME, CONTAINER_NAME); - - producer.process(exchange); - - assertTrue(msg.getExchange().isFailed()); - assertTrue(msg.getExchange().getException().getMessage().contains(failMessage)); - } - - @Test public void createUpdateMetadataTest() throws Exception { final Map<String, String> md = new HashMap<>(); md.put("key", "val"); diff --git a/components/camel-openstack/src/test/java/org/apache/camel/component/openstack/swift/ObjectProducerTest.java b/components/camel-openstack/src/test/java/org/apache/camel/component/openstack/swift/ObjectProducerTest.java index 2add89d..312d22c 100644 --- a/components/camel-openstack/src/test/java/org/apache/camel/component/openstack/swift/ObjectProducerTest.java +++ b/components/camel-openstack/src/test/java/org/apache/camel/component/openstack/swift/ObjectProducerTest.java @@ -147,20 +147,6 @@ public class ObjectProducerTest extends SwiftProducerTestSupport { } @Test - public void deleteObjectFailTest() throws Exception { - final String failMessage = "fail"; - when(objectService.delete(anyString(), anyString())).thenReturn(ActionResponse.actionFailed(failMessage, 401)); - msg.setHeader(OpenstackConstants.OPERATION, OpenstackConstants.DELETE); - msg.setHeader(SwiftConstants.CONTAINER_NAME, CONTAINER_NAME); - msg.setHeader(SwiftConstants.OBJECT_NAME, OBJECT_NAME); - - producer.process(exchange); - - assertTrue(msg.getExchange().isFailed()); - assertTrue(msg.getExchange().getException().getMessage().contains(failMessage)); - } - - @Test public void updateMetadataTest() throws Exception { final Map<String, String> md = new HashMap<>(); md.put("key", "val"); diff --git a/components/camel-sjms/src/test/java/org/apache/camel/component/sjms/tx/TransactedQueueProducerTest.java b/components/camel-sjms/src/test/java/org/apache/camel/component/sjms/tx/TransactedQueueProducerTest.java index 0c8257f..a41f689 100644 --- a/components/camel-sjms/src/test/java/org/apache/camel/component/sjms/tx/TransactedQueueProducerTest.java +++ b/components/camel-sjms/src/test/java/org/apache/camel/component/sjms/tx/TransactedQueueProducerTest.java @@ -22,6 +22,7 @@ import org.apache.camel.Exchange; import org.apache.camel.Processor; import org.apache.camel.Produce; import org.apache.camel.ProducerTemplate; +import org.apache.camel.RollbackExchangeException; import org.apache.camel.builder.RouteBuilder; import org.apache.camel.component.mock.MockEndpoint; import org.apache.camel.component.sjms.SjmsComponent; @@ -47,7 +48,12 @@ public class TransactedQueueProducerTest extends CamelTestSupport { MockEndpoint mock = getMockEndpoint("mock:result"); mock.expectedBodiesReceived("Hello World 2"); - template.sendBodyAndHeader("direct:start", "Hello World 1", "isfailed", true); + try { + template.sendBodyAndHeader("direct:start", "Hello World 1", "isfailed", true); + fail("Should fail"); + } catch (Exception e) { + // expected + } template.sendBodyAndHeader("direct:start", "Hello World 2", "isfailed", false); mock.assertIsSatisfied(); @@ -88,7 +94,7 @@ public class TransactedQueueProducerTest extends CamelTestSupport { public void process(Exchange exchange) throws Exception { if (exchange.getIn().getHeader("isfailed", Boolean.class)) { log.info("We failed. Should roll back."); - throw new IllegalArgumentException("Forced error"); + throw new RollbackExchangeException(exchange); } else { log.info("We passed. Should commit."); } diff --git a/components/camel-sjms/src/test/java/org/apache/camel/component/sjms/tx/TransactedTopicProducerTest.java b/components/camel-sjms/src/test/java/org/apache/camel/component/sjms/tx/TransactedTopicProducerTest.java index 540df18..2a9934e 100644 --- a/components/camel-sjms/src/test/java/org/apache/camel/component/sjms/tx/TransactedTopicProducerTest.java +++ b/components/camel-sjms/src/test/java/org/apache/camel/component/sjms/tx/TransactedTopicProducerTest.java @@ -22,6 +22,7 @@ import org.apache.camel.Exchange; import org.apache.camel.Processor; import org.apache.camel.Produce; import org.apache.camel.ProducerTemplate; +import org.apache.camel.RollbackExchangeException; import org.apache.camel.builder.RouteBuilder; import org.apache.camel.component.mock.MockEndpoint; import org.apache.camel.component.sjms.SjmsComponent; @@ -48,7 +49,12 @@ public class TransactedTopicProducerTest extends CamelTestSupport { MockEndpoint mock = getMockEndpoint("mock:result"); mock.expectedBodiesReceived("Hello World 2"); - template.sendBodyAndHeader("direct:start", "Hello World 1", "isfailed", true); + try { + template.sendBodyAndHeader("direct:start", "Hello World 1", "isfailed", true); + fail("Should throw exception"); + } catch (Exception e) { + // expected + } template.sendBodyAndHeader("direct:start", "Hello World 2", "isfailed", false); mock.assertIsSatisfied(); @@ -93,7 +99,7 @@ public class TransactedTopicProducerTest extends CamelTestSupport { public void process(Exchange exchange) throws Exception { if (exchange.getIn().getHeader("isfailed", Boolean.class)) { log.info("We failed. Should roll back."); - throw new IllegalArgumentException("Forced error"); + throw new RollbackExchangeException(exchange); } else { log.info("We passed. Should commit."); } diff --git a/docs/components/modules/ROOT/pages/activemq-component.adoc b/docs/components/modules/ROOT/pages/activemq-component.adoc index 4faf25f..13784cb 100644 --- a/docs/components/modules/ROOT/pages/activemq-component.adoc +++ b/docs/components/modules/ROOT/pages/activemq-component.adoc @@ -44,7 +44,7 @@ activemq:foo === Component options // component options: START -The ActiveMQ component supports 86 options, which are listed below. +The ActiveMQ component supports 85 options, which are listed below. @@ -112,7 +112,6 @@ The ActiveMQ component supports 86 options, which are listed below. | *requestTimeoutChecker Interval* (advanced) | Configures how often Camel should check for timed out Exchanges when doing request/reply over JMS. By default Camel checks once per second. But if you must react faster when a timeout occurs, then you can lower this interval, to check more frequently. The timeout is determined by the option requestTimeout. | 1000 | long | *transferExchange* (advanced) | You can transfer the exchange over the wire instead of just the body and headers. The following fields are transferred: In body, Out body, Fault body, In headers, Out headers, Fault headers, exchange properties, exchange exception. This requires that the objects are serializable. Camel will exclude any non-serializable objects and log it at WARN level. You must enable this option on both the producer and consumer side, so Camel knows the payloads is an E [...] | *transferException* (advanced) | If enabled and you are using Request Reply messaging (InOut) and an Exchange failed on the consumer side, then the caused Exception will be send back in response as a javax.jms.ObjectMessage. If the client is Camel, the returned Exception is rethrown. This allows you to use Camel JMS as a bridge in your routing - for example, using persistent queues to enable robust routing. Notice that if you also have transferExchange enabled, this option takes preced [...] -| *transferFault* (advanced) | If enabled and you are using Request Reply messaging (InOut) and an Exchange failed with a SOAP fault (not exception) on the consumer side, then the fault flag on org.apache.camel.Message#isFault() will be send back in the response as a JMS header with the key JmsConstants#JMS_TRANSFER_FAULT. If the client is Camel, the returned fault flag will be set on the org.apache.camel.Message#setFault(boolean). You may want to enable this when using Camel components [...] | *jmsOperations* (advanced) | Allows you to use your own implementation of the org.springframework.jms.core.JmsOperations interface. Camel uses JmsTemplate as default. Can be used for testing purpose, but not used much as stated in the spring API docs. | | JmsOperations | *destinationResolver* (advanced) | A pluggable org.springframework.jms.support.destination.DestinationResolver that allows you to use your own resolver (for example, to lookup the real destination in a JNDI registry). | | DestinationResolver | *replyToType* (producer) | Allows for explicitly specifying which kind of strategy to use for replyTo queues when doing request/reply over JMS. Possible values are: Temporary, Shared, or Exclusive. By default Camel will use temporary queues. However if replyTo has been configured, then Shared is used by default. This option allows you to use exclusive queues instead of shared ones. See Camel JMS documentation for more details, and especially the notes about the implications if running [...] @@ -163,7 +162,7 @@ with the following path and query parameters: |=== -==== Query Parameters (93 parameters): +==== Query Parameters (92 parameters): [width="100%",cols="2,5,^1,2",options="header"] @@ -249,7 +248,6 @@ with the following path and query parameters: | *synchronous* (advanced) | Sets whether synchronous processing should be strictly used, or Camel is allowed to use asynchronous processing (if supported). | false | boolean | *transferException* (advanced) | If enabled and you are using Request Reply messaging (InOut) and an Exchange failed on the consumer side, then the caused Exception will be send back in response as a javax.jms.ObjectMessage. If the client is Camel, the returned Exception is rethrown. This allows you to use Camel JMS as a bridge in your routing - for example, using persistent queues to enable robust routing. Notice that if you also have transferExchange enabled, this option takes preced [...] | *transferExchange* (advanced) | You can transfer the exchange over the wire instead of just the body and headers. The following fields are transferred: In body, Out body, Fault body, In headers, Out headers, Fault headers, exchange properties, exchange exception. This requires that the objects are serializable. Camel will exclude any non-serializable objects and log it at WARN level. You must enable this option on both the producer and consumer side, so Camel knows the payloads is an E [...] -| *transferFault* (advanced) | If enabled and you are using Request Reply messaging (InOut) and an Exchange failed with a SOAP fault (not exception) on the consumer side, then the fault flag on org.apache.camel.Message#isFault() will be send back in the response as a JMS header with the key JmsConstants#JMS_TRANSFER_FAULT. If the client is Camel, the returned fault flag will be set on the org.apache.camel.Message#setFault(boolean). You may want to enable this when using Camel components [...] | *useMessageIDAsCorrelation ID* (advanced) | Specifies whether JMSMessageID should always be used as JMSCorrelationID for InOut messages. | false | boolean | *waitForProvisionCorrelation ToBeUpdatedCounter* (advanced) | Number of times to wait for provisional correlation id to be updated to the actual correlation id when doing request/reply over JMS and when the option useMessageIDAsCorrelationID is enabled. | 50 | int | *waitForProvisionCorrelation ToBeUpdatedThreadSleeping Time* (advanced) | Interval in millis to sleep each time while waiting for provisional correlation id to be updated. | 100 | long @@ -281,7 +279,7 @@ When using Spring Boot make sure to use the following Maven dependency to have s ---- -The component supports 87 options, which are listed below. +The component supports 86 options, which are listed below. @@ -367,7 +365,6 @@ The component supports 87 options, which are listed below. | *camel.component.activemq.transaction-timeout* | The timeout value of the transaction (in seconds), if using transacted mode. | -1 | Integer | *camel.component.activemq.transfer-exception* | If enabled and you are using Request Reply messaging (InOut) and an Exchange failed on the consumer side, then the caused Exception will be send back in response as a javax.jms.ObjectMessage. If the client is Camel, the returned Exception is rethrown. This allows you to use Camel JMS as a bridge in your routing - for example, using persistent queues to enable robust routing. Notice that if you also have transferExchange enabled, this opti [...] | *camel.component.activemq.transfer-exchange* | You can transfer the exchange over the wire instead of just the body and headers. The following fields are transferred: In body, Out body, Fault body, In headers, Out headers, Fault headers, exchange properties, exchange exception. This requires that the objects are serializable. Camel will exclude any non-serializable objects and log it at WARN level. You must enable this option on both the producer and consumer side, so Camel knows the p [...] -| *camel.component.activemq.transfer-fault* | If enabled and you are using Request Reply messaging (InOut) and an Exchange failed with a SOAP fault (not exception) on the consumer side, then the fault flag on org.apache.camel.Message#isFault() will be send back in the response as a JMS header with the key JmsConstants#JMS_TRANSFER_FAULT. If the client is Camel, the returned fault flag will be set on the org.apache.camel.Message#setFault(boolean). You may want to enable this when using Ca [...] | *camel.component.activemq.trust-all-packages* | Define if all packages are trusted or not | false | Boolean | *camel.component.activemq.use-message-i-d-as-correlation-i-d* | Specifies whether JMSMessageID should always be used as JMSCorrelationID for InOut messages. | false | Boolean | *camel.component.activemq.use-pooled-connection* | Enables or disables whether a PooledConnectionFactory will be used so that when messages are sent to ActiveMQ from outside of a message consuming thread, pooling will be used rather than the default with the Spring JmsTemplate which will create a new connection, session, producer for each message then close them all down again. The default value is true. Note that this requires an extra dependency on commons-pool2. | false | Boolean diff --git a/docs/components/modules/ROOT/pages/amqp-component.adoc b/docs/components/modules/ROOT/pages/amqp-component.adoc index 5994810..23675ad 100644 --- a/docs/components/modules/ROOT/pages/amqp-component.adoc +++ b/docs/components/modules/ROOT/pages/amqp-component.adoc @@ -36,7 +36,7 @@ xref:../../../../camel-jms/src/main/docs/readme.adoc[JMS] component after the de // component options: START -The AMQP component supports 81 options, which are listed below. +The AMQP component supports 80 options, which are listed below. @@ -99,7 +99,6 @@ The AMQP component supports 81 options, which are listed below. | *requestTimeoutChecker Interval* (advanced) | Configures how often Camel should check for timed out Exchanges when doing request/reply over JMS. By default Camel checks once per second. But if you must react faster when a timeout occurs, then you can lower this interval, to check more frequently. The timeout is determined by the option requestTimeout. | 1000 | long | *transferExchange* (advanced) | You can transfer the exchange over the wire instead of just the body and headers. The following fields are transferred: In body, Out body, Fault body, In headers, Out headers, Fault headers, exchange properties, exchange exception. This requires that the objects are serializable. Camel will exclude any non-serializable objects and log it at WARN level. You must enable this option on both the producer and consumer side, so Camel knows the payloads is an E [...] | *transferException* (advanced) | If enabled and you are using Request Reply messaging (InOut) and an Exchange failed on the consumer side, then the caused Exception will be send back in response as a javax.jms.ObjectMessage. If the client is Camel, the returned Exception is rethrown. This allows you to use Camel JMS as a bridge in your routing - for example, using persistent queues to enable robust routing. Notice that if you also have transferExchange enabled, this option takes preced [...] -| *transferFault* (advanced) | If enabled and you are using Request Reply messaging (InOut) and an Exchange failed with a SOAP fault (not exception) on the consumer side, then the fault flag on org.apache.camel.Message#isFault() will be send back in the response as a JMS header with the key JmsConstants#JMS_TRANSFER_FAULT. If the client is Camel, the returned fault flag will be set on the org.apache.camel.Message#setFault(boolean). You may want to enable this when using Camel components [...] | *jmsOperations* (advanced) | Allows you to use your own implementation of the org.springframework.jms.core.JmsOperations interface. Camel uses JmsTemplate as default. Can be used for testing purpose, but not used much as stated in the spring API docs. | | JmsOperations | *destinationResolver* (advanced) | A pluggable org.springframework.jms.support.destination.DestinationResolver that allows you to use your own resolver (for example, to lookup the real destination in a JNDI registry). | | DestinationResolver | *replyToType* (producer) | Allows for explicitly specifying which kind of strategy to use for replyTo queues when doing request/reply over JMS. Possible values are: Temporary, Shared, or Exclusive. By default Camel will use temporary queues. However if replyTo has been configured, then Shared is used by default. This option allows you to use exclusive queues instead of shared ones. See Camel JMS documentation for more details, and especially the notes about the implications if running [...] @@ -153,7 +152,7 @@ with the following path and query parameters: |=== -==== Query Parameters (93 parameters): +==== Query Parameters (92 parameters): [width="100%",cols="2,5,^1,2",options="header"] @@ -239,7 +238,6 @@ with the following path and query parameters: | *synchronous* (advanced) | Sets whether synchronous processing should be strictly used, or Camel is allowed to use asynchronous processing (if supported). | false | boolean | *transferException* (advanced) | If enabled and you are using Request Reply messaging (InOut) and an Exchange failed on the consumer side, then the caused Exception will be send back in response as a javax.jms.ObjectMessage. If the client is Camel, the returned Exception is rethrown. This allows you to use Camel JMS as a bridge in your routing - for example, using persistent queues to enable robust routing. Notice that if you also have transferExchange enabled, this option takes preced [...] | *transferExchange* (advanced) | You can transfer the exchange over the wire instead of just the body and headers. The following fields are transferred: In body, Out body, Fault body, In headers, Out headers, Fault headers, exchange properties, exchange exception. This requires that the objects are serializable. Camel will exclude any non-serializable objects and log it at WARN level. You must enable this option on both the producer and consumer side, so Camel knows the payloads is an E [...] -| *transferFault* (advanced) | If enabled and you are using Request Reply messaging (InOut) and an Exchange failed with a SOAP fault (not exception) on the consumer side, then the fault flag on org.apache.camel.Message#isFault() will be send back in the response as a JMS header with the key JmsConstants#JMS_TRANSFER_FAULT. If the client is Camel, the returned fault flag will be set on the org.apache.camel.Message#setFault(boolean). You may want to enable this when using Camel components [...] | *useMessageIDAsCorrelation ID* (advanced) | Specifies whether JMSMessageID should always be used as JMSCorrelationID for InOut messages. | false | boolean | *waitForProvisionCorrelation ToBeUpdatedCounter* (advanced) | Number of times to wait for provisional correlation id to be updated to the actual correlation id when doing request/reply over JMS and when the option useMessageIDAsCorrelationID is enabled. | 50 | int | *waitForProvisionCorrelation ToBeUpdatedThreadSleeping Time* (advanced) | Interval in millis to sleep each time while waiting for provisional correlation id to be updated. | 100 | long @@ -270,7 +268,7 @@ When using Spring Boot make sure to use the following Maven dependency to have s ---- -The component supports 82 options, which are listed below. +The component supports 81 options, which are listed below. @@ -354,7 +352,6 @@ The component supports 82 options, which are listed below. | *camel.component.amqp.transaction-timeout* | The timeout value of the transaction (in seconds), if using transacted mode. | -1 | Integer | *camel.component.amqp.transfer-exception* | If enabled and you are using Request Reply messaging (InOut) and an Exchange failed on the consumer side, then the caused Exception will be send back in response as a javax.jms.ObjectMessage. If the client is Camel, the returned Exception is rethrown. This allows you to use Camel JMS as a bridge in your routing - for example, using persistent queues to enable robust routing. Notice that if you also have transferExchange enabled, this option t [...] | *camel.component.amqp.transfer-exchange* | You can transfer the exchange over the wire instead of just the body and headers. The following fields are transferred: In body, Out body, Fault body, In headers, Out headers, Fault headers, exchange properties, exchange exception. This requires that the objects are serializable. Camel will exclude any non-serializable objects and log it at WARN level. You must enable this option on both the producer and consumer side, so Camel knows the paylo [...] -| *camel.component.amqp.transfer-fault* | If enabled and you are using Request Reply messaging (InOut) and an Exchange failed with a SOAP fault (not exception) on the consumer side, then the fault flag on org.apache.camel.Message#isFault() will be send back in the response as a JMS header with the key JmsConstants#JMS_TRANSFER_FAULT. If the client is Camel, the returned fault flag will be set on the org.apache.camel.Message#setFault(boolean). You may want to enable this when using Camel [...] | *camel.component.amqp.use-message-i-d-as-correlation-i-d* | Specifies whether JMSMessageID should always be used as JMSCorrelationID for InOut messages. | false | Boolean | *camel.component.amqp.username* | Username to use with the ConnectionFactory. You can also configure username/password directly on the ConnectionFactory. | | String | *camel.component.amqp.wait-for-provision-correlation-to-be-updated-counter* | Number of times to wait for provisional correlation id to be updated to the actual correlation id when doing request/reply over JMS and when the option useMessageIDAsCorrelationID is enabled. | 50 | Integer diff --git a/docs/components/modules/ROOT/pages/jms-component.adoc b/docs/components/modules/ROOT/pages/jms-component.adoc index aed022e..3e0b64f 100644 --- a/docs/components/modules/ROOT/pages/jms-component.adoc +++ b/docs/components/modules/ROOT/pages/jms-component.adoc @@ -192,7 +192,7 @@ about these properties by consulting the relevant Spring documentation. // component options: START -The JMS component supports 81 options, which are listed below. +The JMS component supports 80 options, which are listed below. @@ -255,7 +255,6 @@ The JMS component supports 81 options, which are listed below. | *requestTimeoutChecker Interval* (advanced) | Configures how often Camel should check for timed out Exchanges when doing request/reply over JMS. By default Camel checks once per second. But if you must react faster when a timeout occurs, then you can lower this interval, to check more frequently. The timeout is determined by the option requestTimeout. | 1000 | long | *transferExchange* (advanced) | You can transfer the exchange over the wire instead of just the body and headers. The following fields are transferred: In body, Out body, Fault body, In headers, Out headers, Fault headers, exchange properties, exchange exception. This requires that the objects are serializable. Camel will exclude any non-serializable objects and log it at WARN level. You must enable this option on both the producer and consumer side, so Camel knows the payloads is an E [...] | *transferException* (advanced) | If enabled and you are using Request Reply messaging (InOut) and an Exchange failed on the consumer side, then the caused Exception will be send back in response as a javax.jms.ObjectMessage. If the client is Camel, the returned Exception is rethrown. This allows you to use Camel JMS as a bridge in your routing - for example, using persistent queues to enable robust routing. Notice that if you also have transferExchange enabled, this option takes preced [...] -| *transferFault* (advanced) | If enabled and you are using Request Reply messaging (InOut) and an Exchange failed with a SOAP fault (not exception) on the consumer side, then the fault flag on org.apache.camel.Message#isFault() will be send back in the response as a JMS header with the key JmsConstants#JMS_TRANSFER_FAULT. If the client is Camel, the returned fault flag will be set on the org.apache.camel.Message#setFault(boolean). You may want to enable this when using Camel components [...] | *jmsOperations* (advanced) | Allows you to use your own implementation of the org.springframework.jms.core.JmsOperations interface. Camel uses JmsTemplate as default. Can be used for testing purpose, but not used much as stated in the spring API docs. | | JmsOperations | *destinationResolver* (advanced) | A pluggable org.springframework.jms.support.destination.DestinationResolver that allows you to use your own resolver (for example, to lookup the real destination in a JNDI registry). | | DestinationResolver | *replyToType* (producer) | Allows for explicitly specifying which kind of strategy to use for replyTo queues when doing request/reply over JMS. Possible values are: Temporary, Shared, or Exclusive. By default Camel will use temporary queues. However if replyTo has been configured, then Shared is used by default. This option allows you to use exclusive queues instead of shared ones. See Camel JMS documentation for more details, and especially the notes about the implications if running [...] @@ -320,7 +319,7 @@ with the following path and query parameters: |=== -==== Query Parameters (93 parameters): +==== Query Parameters (92 parameters): [width="100%",cols="2,5,^1,2",options="header"] @@ -406,7 +405,6 @@ with the following path and query parameters: | *synchronous* (advanced) | Sets whether synchronous processing should be strictly used, or Camel is allowed to use asynchronous processing (if supported). | false | boolean | *transferException* (advanced) | If enabled and you are using Request Reply messaging (InOut) and an Exchange failed on the consumer side, then the caused Exception will be send back in response as a javax.jms.ObjectMessage. If the client is Camel, the returned Exception is rethrown. This allows you to use Camel JMS as a bridge in your routing - for example, using persistent queues to enable robust routing. Notice that if you also have transferExchange enabled, this option takes preced [...] | *transferExchange* (advanced) | You can transfer the exchange over the wire instead of just the body and headers. The following fields are transferred: In body, Out body, Fault body, In headers, Out headers, Fault headers, exchange properties, exchange exception. This requires that the objects are serializable. Camel will exclude any non-serializable objects and log it at WARN level. You must enable this option on both the producer and consumer side, so Camel knows the payloads is an E [...] -| *transferFault* (advanced) | If enabled and you are using Request Reply messaging (InOut) and an Exchange failed with a SOAP fault (not exception) on the consumer side, then the fault flag on org.apache.camel.Message#isFault() will be send back in the response as a JMS header with the key JmsConstants#JMS_TRANSFER_FAULT. If the client is Camel, the returned fault flag will be set on the org.apache.camel.Message#setFault(boolean). You may want to enable this when using Camel components [...] | *useMessageIDAsCorrelation ID* (advanced) | Specifies whether JMSMessageID should always be used as JMSCorrelationID for InOut messages. | false | boolean | *waitForProvisionCorrelation ToBeUpdatedCounter* (advanced) | Number of times to wait for provisional correlation id to be updated to the actual correlation id when doing request/reply over JMS and when the option useMessageIDAsCorrelationID is enabled. | 50 | int | *waitForProvisionCorrelation ToBeUpdatedThreadSleeping Time* (advanced) | Interval in millis to sleep each time while waiting for provisional correlation id to be updated. | 100 | long @@ -437,7 +435,7 @@ When using Spring Boot make sure to use the following Maven dependency to have s ---- -The component supports 171 options, which are listed below. +The component supports 169 options, which are listed below. @@ -545,7 +543,6 @@ The component supports 171 options, which are listed below. | *camel.component.jms.configuration.transaction-timeout* | The timeout value of the transaction (in seconds), if using transacted mode. | -1 | Integer | *camel.component.jms.configuration.transfer-exception* | If enabled and you are using Request Reply messaging (InOut) and an Exchange failed on the consumer side, then the caused Exception will be send back in response as a javax.jms.ObjectMessage. If the client is Camel, the returned Exception is rethrown. This allows you to use Camel JMS as a bridge in your routing - for example, using persistent queues to enable robust routing. Notice that if you also have transferExchange enabled, [...] | *camel.component.jms.configuration.transfer-exchange* | You can transfer the exchange over the wire instead of just the body and headers. The following fields are transferred: In body, Out body, Fault body, In headers, Out headers, Fault headers, exchange properties, exchange exception. This requires that the objects are serializable. Camel will exclude any non-serializable objects and log it at WARN level. You must enable this option on both the producer and consumer side, so Camel kn [...] -| *camel.component.jms.configuration.transfer-fault* | If enabled and you are using Request Reply messaging (InOut) and an Exchange failed with a SOAP fault (not exception) on the consumer side, then the fault flag on {@link org.apache.camel.Message#isFault()} will be send back in the response as a JMS header with the key {@link JmsConstants#JMS_TRANSFER_FAULT}. If the client is Camel, the returned fault flag will be set on the {@link org.apache.camel.Message#setFault(boolean)}. <p> You [...] | *camel.component.jms.configuration.use-message-i-d-as-correlation-i-d* | Specifies whether JMSMessageID should always be used as JMSCorrelationID for InOut messages. | false | Boolean | *camel.component.jms.configuration.username* | Username to use with the ConnectionFactory. You can also configure username/password directly on the ConnectionFactory. | | String | *camel.component.jms.configuration.wait-for-provision-correlation-to-be-updated-counter* | Number of times to wait for provisional correlation id to be updated to the actual correlation id when doing request/reply over JMS and when the option useMessageIDAsCorrelationID is enabled. | 50 | Integer @@ -610,7 +607,6 @@ The component supports 171 options, which are listed below. | *camel.component.jms.transaction-timeout* | The timeout value of the transaction (in seconds), if using transacted mode. | -1 | Integer | *camel.component.jms.transfer-exception* | If enabled and you are using Request Reply messaging (InOut) and an Exchange failed on the consumer side, then the caused Exception will be send back in response as a javax.jms.ObjectMessage. If the client is Camel, the returned Exception is rethrown. This allows you to use Camel JMS as a bridge in your routing - for example, using persistent queues to enable robust routing. Notice that if you also have transferExchange enabled, this option ta [...] | *camel.component.jms.transfer-exchange* | You can transfer the exchange over the wire instead of just the body and headers. The following fields are transferred: In body, Out body, Fault body, In headers, Out headers, Fault headers, exchange properties, exchange exception. This requires that the objects are serializable. Camel will exclude any non-serializable objects and log it at WARN level. You must enable this option on both the producer and consumer side, so Camel knows the payloa [...] -| *camel.component.jms.transfer-fault* | If enabled and you are using Request Reply messaging (InOut) and an Exchange failed with a SOAP fault (not exception) on the consumer side, then the fault flag on org.apache.camel.Message#isFault() will be send back in the response as a JMS header with the key JmsConstants#JMS_TRANSFER_FAULT. If the client is Camel, the returned fault flag will be set on the org.apache.camel.Message#setFault(boolean). You may want to enable this when using Camel c [...] | *camel.component.jms.use-message-i-d-as-correlation-i-d* | Specifies whether JMSMessageID should always be used as JMSCorrelationID for InOut messages. | false | Boolean | *camel.component.jms.username* | Username to use with the ConnectionFactory. You can also configure username/password directly on the ConnectionFactory. | | String | *camel.component.jms.wait-for-provision-correlation-to-be-updated-counter* | Number of times to wait for provisional correlation id to be updated to the actual correlation id when doing request/reply over JMS and when the option useMessageIDAsCorrelationID is enabled. | 50 | Integer diff --git a/docs/components/modules/ROOT/pages/spring-boot.adoc b/docs/components/modules/ROOT/pages/spring-boot.adoc index 230b5c2..c81424e 100644 --- a/docs/components/modules/ROOT/pages/spring-boot.adoc +++ b/docs/components/modules/ROOT/pages/spring-boot.adoc @@ -89,7 +89,7 @@ When using Spring Boot make sure to use the following Maven dependency to have s ---- -The component supports 125 options, which are listed below. +The component supports 124 options, which are listed below. @@ -151,7 +151,6 @@ The component supports 125 options, which are listed below. | *camel.springboot.duration-max-seconds* | To specify for how long time in seconds to keep running the JVM before automatic terminating the JVM. You can use this to run Spring Boot for a short while. | 0 | Integer | *camel.springboot.endpoint-runtime-statistics-enabled* | Sets whether endpoint runtime statistics is enabled (gathers runtime usage of each incoming and outgoing endpoints). The default value is false. | false | Boolean | *camel.springboot.file-configurations* | Directory to load additional configuration files that contains configuration values that takes precedence over any other configuration. This can be used to refer to files that may have secret configuration that has been mounted on the file system for containers. You must use either file: or classpath: as prefix to load from file system or classpath. Then you can specify a pattern to load from sub directories and a name pattern such as file:/var/ [...] -| *camel.springboot.handle-fault* | Sets whether fault handling is enabled or not. Default is false. | false | Boolean | *camel.springboot.include-non-singletons* | Whether to include non-singleton beans (prototypes) when scanning for RouteBuilder instances. By default only singleton beans is included in the context scan. | false | Boolean | *camel.springboot.java-routes-exclude-pattern* | Used for exclusive filtering component scanning of RouteBuilder classes with @Component annotation. The exclusive filtering takes precedence over inclusive filtering. The pattern is using Ant-path style pattern. Multiple patterns can be specified separated by comma. For example to exclude all classes starting with Bar use: **/Bar* To exclude all routes form a specific package use: com/mycompany/bar/* To exclude all routes [...] | *camel.springboot.java-routes-include-pattern* | Used for inclusive filtering component scanning of RouteBuilder classes with @Component annotation. The exclusive filtering takes precedence over inclusive filtering. The pattern is using Ant-path style pattern. Multiple patterns can be specified separated by comma. For example to include all classes starting with Foo use: **/Foo* To include all routes form a specific package use: com/mycompany/foo/* To include all routes for [...]