[1/2] camel git commit: CAMEL-7152 - HttpProducer loses response data (specifically which headers where returned):
Repository: camel Updated Branches: refs/heads/master b528f7788 - e21187e82 CAMEL-7152 - HttpProducer loses response data (specifically which headers where returned): 1) Added copyHeaders to http and http4 components 2) Fixed some online tests which were outdated Project: http://git-wip-us.apache.org/repos/asf/camel/repo Commit: http://git-wip-us.apache.org/repos/asf/camel/commit/f8503218 Tree: http://git-wip-us.apache.org/repos/asf/camel/tree/f8503218 Diff: http://git-wip-us.apache.org/repos/asf/camel/diff/f8503218 Branch: refs/heads/master Commit: f8503218d55b80f1ff9bb9e59a9b4d07db4a9074 Parents: b528f77 Author: Robert Budźko robert.krzysztof.bud...@gmail.com Authored: Sat Jul 18 12:35:47 2015 +0200 Committer: Claus Ibsen davscl...@apache.org Committed: Sun Jul 19 10:16:36 2015 +0200 -- .../camel/component/http/HttpEndpoint.java | 24 -- .../camel/component/http/HttpProducer.java | 10 ++-- ...ponentConfigurationAndDocumentationTest.java | 9 +++- .../http/HttpGetHeadersNotCopiedTest.java | 46 ++ .../camel/component/http/HttpGetTest.java | 2 +- .../component/http/HttpGetWithHeadersTest.java | 3 +- .../component/http/HttpPostWithBodyTest.java| 4 +- .../component/http/HttpQueryGoogleTest.java | 5 +- .../camel/component/http4/HttpEndpoint.java | 12 + .../camel/component/http4/HttpProducer.java | 10 ++-- .../http4/HttpCamelHeadersNotCopiedTest.java| 41 .../component/http4/HttpCamelHeadersTest.java | 50 +--- 12 files changed, 179 insertions(+), 37 deletions(-) -- http://git-wip-us.apache.org/repos/asf/camel/blob/f8503218/components/camel-http/src/main/java/org/apache/camel/component/http/HttpEndpoint.java -- diff --git a/components/camel-http/src/main/java/org/apache/camel/component/http/HttpEndpoint.java b/components/camel-http/src/main/java/org/apache/camel/component/http/HttpEndpoint.java index fcdd6a4..bcf6cb6 100644 --- a/components/camel-http/src/main/java/org/apache/camel/component/http/HttpEndpoint.java +++ b/components/camel-http/src/main/java/org/apache/camel/component/http/HttpEndpoint.java @@ -110,6 +110,10 @@ public class HttpEndpoint extends DefaultEndpoint implements HeaderFilterStrateg @UriParam(label = producer, description = If this option is true, The http producer won't read response body and cache the input stream) private boolean ignoreResponseBody; +@UriParam(defaultValue = true, +description = If this option is true then IN exchange headers will be copied to OUT exchange headers ++ according to copy strategy.) +private boolean copyHeaders = true; @UriParam(label = consumer, description = Whether to eager check whether the HTTP requests has content if the content-length header is 0 or not present. + This can be turned on in case HTTP clients do not send streamed data.) @@ -125,7 +129,7 @@ public class HttpEndpoint extends DefaultEndpoint implements HeaderFilterStrateg public HttpEndpoint(String endPointURI, HttpComponent component, URI httpURI, HttpConnectionManager httpConnectionManager) throws URISyntaxException { this(endPointURI, component, httpURI, new HttpClientParams(), httpConnectionManager, null); } - + public HttpEndpoint(String endPointURI, HttpComponent component, HttpClientParams clientParams, HttpConnectionManager httpConnectionManager, HttpClientConfigurer clientConfigurer) throws URISyntaxException { this(endPointURI, component, null, clientParams, httpConnectionManager, clientConfigurer); @@ -338,7 +342,7 @@ public class HttpEndpoint extends DefaultEndpoint implements HeaderFilterStrateg public void setThrowExceptionOnFailure(boolean throwExceptionOnFailure) { this.throwExceptionOnFailure = throwExceptionOnFailure; } - + public boolean isBridgeEndpoint() { return bridgeEndpoint; } @@ -350,7 +354,7 @@ public class HttpEndpoint extends DefaultEndpoint implements HeaderFilterStrateg public void setBridgeEndpoint(boolean bridge) { this.bridgeEndpoint = bridge; } - + public boolean isMatchOnUriPrefix() { return matchOnUriPrefix; } @@ -363,7 +367,7 @@ public class HttpEndpoint extends DefaultEndpoint implements HeaderFilterStrateg public void setMatchOnUriPrefix(boolean match) { this.matchOnUriPrefix = match; } - + public boolean isDisableStreamCache() { return this.disableStreamCache; } @@ -382,7 +386,7 @@ public class HttpEndpoint extends DefaultEndpoint implements HeaderFilterStrateg public void setDisableStreamCache(boolean
[1/2] camel git commit: Polished
Repository: camel Updated Branches: refs/heads/master e21187e82 - f44a8cdbd Polished Project: http://git-wip-us.apache.org/repos/asf/camel/repo Commit: http://git-wip-us.apache.org/repos/asf/camel/commit/33f08352 Tree: http://git-wip-us.apache.org/repos/asf/camel/tree/33f08352 Diff: http://git-wip-us.apache.org/repos/asf/camel/diff/33f08352 Branch: refs/heads/master Commit: 33f083526138d2982f308dafb57c87f46934f1b6 Parents: e21187e Author: Claus Ibsen davscl...@apache.org Authored: Sun Jul 19 10:31:25 2015 +0200 Committer: Claus Ibsen davscl...@apache.org Committed: Sun Jul 19 10:31:25 2015 +0200 -- .../org/apache/camel/component/git/GitEndpoint.java | 12 ++-- 1 file changed, 6 insertions(+), 6 deletions(-) -- http://git-wip-us.apache.org/repos/asf/camel/blob/33f08352/components/camel-git/src/main/java/org/apache/camel/component/git/GitEndpoint.java -- diff --git a/components/camel-git/src/main/java/org/apache/camel/component/git/GitEndpoint.java b/components/camel-git/src/main/java/org/apache/camel/component/git/GitEndpoint.java index 261c6ce..cda09f5 100644 --- a/components/camel-git/src/main/java/org/apache/camel/component/git/GitEndpoint.java +++ b/components/camel-git/src/main/java/org/apache/camel/component/git/GitEndpoint.java @@ -30,20 +30,20 @@ import org.apache.camel.spi.UriEndpoint; import org.apache.camel.spi.UriParam; import org.apache.camel.spi.UriPath; -@UriEndpoint(scheme = git, title = Git, syntax = git://localpath, label = api,file) +@UriEndpoint(scheme = git, title = Git, syntax = git:localpath, label = file) public class GitEndpoint extends DefaultEndpoint { @UriPath @Metadata(required = true) private String localPath; -@UriPath +@UriParam private String branchName; -@UriPath +@UriParam private String tagName; -@UriPath(label = consumer) +@UriParam(label = consumer) private GitType type; @UriParam @@ -76,13 +76,13 @@ public class GitEndpoint extends DefaultEndpoint { } else if (type == GitType.BRANCH) { return new GitBranchConsumer(this, processor); } else { -throw new IllegalArgumentException(Cannot create producer with type + type); +throw new IllegalArgumentException(Cannot create consumer with type + type); } } @Override public boolean isSingleton() { -return false; +return true; } /**
[2/2] camel git commit: Polished
Polished Project: http://git-wip-us.apache.org/repos/asf/camel/repo Commit: http://git-wip-us.apache.org/repos/asf/camel/commit/f44a8cdb Tree: http://git-wip-us.apache.org/repos/asf/camel/tree/f44a8cdb Diff: http://git-wip-us.apache.org/repos/asf/camel/diff/f44a8cdb Branch: refs/heads/master Commit: f44a8cdbd5a9bbe856aad8ff4838e1649661bafe Parents: 33f0835 Author: Claus Ibsen davscl...@apache.org Authored: Sun Jul 19 10:34:00 2015 +0200 Committer: Claus Ibsen davscl...@apache.org Committed: Sun Jul 19 10:34:00 2015 +0200 -- .../src/main/java/org/apache/camel/coap/CoAPEndpoint.java | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) -- http://git-wip-us.apache.org/repos/asf/camel/blob/f44a8cdb/components/camel-coap/src/main/java/org/apache/camel/coap/CoAPEndpoint.java -- diff --git a/components/camel-coap/src/main/java/org/apache/camel/coap/CoAPEndpoint.java b/components/camel-coap/src/main/java/org/apache/camel/coap/CoAPEndpoint.java index 5cc63ca..fb985f1 100644 --- a/components/camel-coap/src/main/java/org/apache/camel/coap/CoAPEndpoint.java +++ b/components/camel-coap/src/main/java/org/apache/camel/coap/CoAPEndpoint.java @@ -29,12 +29,11 @@ import org.eclipse.californium.core.CoapServer; /** * Represents a CoAP endpoint. */ -@UriEndpoint(scheme = coap, title = CoAP, syntax = coap:name, consumerClass = CoAPConsumer.class, label = CoAP) +@UriEndpoint(scheme = coap, title = CoAP, syntax = coap:uri, consumerClass = CoAPConsumer.class, label = iot) public class CoAPEndpoint extends DefaultEndpoint { @UriPath private URI uri; - - + private CoAPComponent component; public CoAPEndpoint(String uri, CoAPComponent component) {
camel git commit: CAMEL-8957: Added unit test
Repository: camel Updated Branches: refs/heads/master f44a8cdbd - 3909b0a82 CAMEL-8957: Added unit test Project: http://git-wip-us.apache.org/repos/asf/camel/repo Commit: http://git-wip-us.apache.org/repos/asf/camel/commit/3909b0a8 Tree: http://git-wip-us.apache.org/repos/asf/camel/tree/3909b0a8 Diff: http://git-wip-us.apache.org/repos/asf/camel/diff/3909b0a8 Branch: refs/heads/master Commit: 3909b0a82d61617ed3ccc228da5ddaf7f8c206bc Parents: f44a8cd Author: Claus Ibsen davscl...@apache.org Authored: Sun Jul 19 10:40:57 2015 +0200 Committer: Claus Ibsen davscl...@apache.org Committed: Sun Jul 19 10:40:57 2015 +0200 -- ...rceptSendToEndpointWithLoadbalancerTest.java | 57 1 file changed, 57 insertions(+) -- http://git-wip-us.apache.org/repos/asf/camel/blob/3909b0a8/camel-core/src/test/java/org/apache/camel/issues/AdviceWithInterceptSendToEndpointWithLoadbalancerTest.java -- diff --git a/camel-core/src/test/java/org/apache/camel/issues/AdviceWithInterceptSendToEndpointWithLoadbalancerTest.java b/camel-core/src/test/java/org/apache/camel/issues/AdviceWithInterceptSendToEndpointWithLoadbalancerTest.java new file mode 100644 index 000..eb1c2ae --- /dev/null +++ b/camel-core/src/test/java/org/apache/camel/issues/AdviceWithInterceptSendToEndpointWithLoadbalancerTest.java @@ -0,0 +1,57 @@ +/** + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the License); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an AS IS BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package org.apache.camel.issues; + +import org.apache.camel.ContextTestSupport; +import org.apache.camel.builder.RouteBuilder; +import org.apache.camel.model.RouteDefinition; + +public class AdviceWithInterceptSendToEndpointWithLoadbalancerTest extends ContextTestSupport { + +@Override +public boolean isUseRouteBuilder() { +return false; +} + +public void testInterceptSendToEndpoint() throws Exception { +context.addRoutes(new RouteBuilder() { +@Override +public void configure() throws Exception { +from(direct:start) +.loadBalance().failover() +.to(seda:end1, seda:end2); +} +}); + +RouteDefinition route = context.getRouteDefinitions().get(0); +route.adviceWith(context, new RouteBuilder() { +public void configure() throws Exception { +interceptSendToEndpoint(seda:end1) +.skipSendToOriginalEndpoint() +.to(mock:end); +} +}); +context.start(); + +getMockEndpoint(mock:end).expectedMessageCount(1); + +template.sendBody(direct:start, Hello World); + +assertMockEndpointsSatisfied(); +} + +}
camel git commit: CAMEL-8981: camel-test-spring - Allow to use UseOverridePropertiesWithPropertiesComponent
Repository: camel Updated Branches: refs/heads/master 3909b0a82 - 3b5c6aeef CAMEL-8981: camel-test-spring - Allow to use UseOverridePropertiesWithPropertiesComponent Project: http://git-wip-us.apache.org/repos/asf/camel/repo Commit: http://git-wip-us.apache.org/repos/asf/camel/commit/3b5c6aee Tree: http://git-wip-us.apache.org/repos/asf/camel/tree/3b5c6aee Diff: http://git-wip-us.apache.org/repos/asf/camel/diff/3b5c6aee Branch: refs/heads/master Commit: 3b5c6aeeff1254d9e11f8e669041dd693496cfcb Parents: 3909b0a Author: Claus Ibsen davscl...@apache.org Authored: Sun Jul 19 11:27:26 2015 +0200 Committer: Claus Ibsen davscl...@apache.org Committed: Sun Jul 19 11:27:26 2015 +0200 -- components/camel-test-spring/pom.xml| 6 +- .../CamelSpringDelegatingTestContextLoader.java | 63 +++- .../spring/CamelSpringTestContextLoader.java| 59 ++- ...erridePropertiesWithPropertiesComponent.java | 36 + .../CamelSpringOverridePropertiesTest.java | 77 .../src/test/resources/log4j.properties | 5 +- ...amelSpringOverridePropertiesTest-context.xml | 40 ++ 7 files changed, 277 insertions(+), 9 deletions(-) -- http://git-wip-us.apache.org/repos/asf/camel/blob/3b5c6aee/components/camel-test-spring/pom.xml -- diff --git a/components/camel-test-spring/pom.xml b/components/camel-test-spring/pom.xml index d9017f8..65a7ab7 100644 --- a/components/camel-test-spring/pom.xml +++ b/components/camel-test-spring/pom.xml @@ -82,13 +82,17 @@ version${spring4-version}/version /dependency - !-- test dependencies -- dependency groupIdorg.slf4j/groupId artifactIdslf4j-log4j12/artifactId scopetest/scope /dependency +dependency + groupIdlog4j/groupId + artifactIdlog4j/artifactId + scopetest/scope +/dependency /dependencies /project http://git-wip-us.apache.org/repos/asf/camel/blob/3b5c6aee/components/camel-test-spring/src/main/java/org/apache/camel/test/spring/CamelSpringDelegatingTestContextLoader.java -- diff --git a/components/camel-test-spring/src/main/java/org/apache/camel/test/spring/CamelSpringDelegatingTestContextLoader.java b/components/camel-test-spring/src/main/java/org/apache/camel/test/spring/CamelSpringDelegatingTestContextLoader.java index cea1656..c7511ff 100644 --- a/components/camel-test-spring/src/main/java/org/apache/camel/test/spring/CamelSpringDelegatingTestContextLoader.java +++ b/components/camel-test-spring/src/main/java/org/apache/camel/test/spring/CamelSpringDelegatingTestContextLoader.java @@ -21,8 +21,10 @@ import java.lang.reflect.Modifier; import java.util.Collection; import java.util.LinkedList; import java.util.List; +import java.util.Properties; import java.util.concurrent.TimeUnit; +import org.apache.camel.component.properties.PropertiesComponent; import org.apache.camel.impl.DefaultDebugger; import org.apache.camel.impl.InterceptSendToMockEndpointStrategy; import org.apache.camel.management.JmxSystemPropertyKeys; @@ -42,8 +44,6 @@ import org.springframework.test.context.support.DelegatingSmartContextLoader; import static org.apache.camel.test.spring.CamelSpringTestHelper.getAllMethods; - - /** * CamelSpringDelegatingTestContextLoader which fixes issues in Camel's JavaConfigContextLoader. (adds support for Camel's test annotations) * br @@ -90,12 +90,15 @@ public class CamelSpringDelegatingTestContextLoader extends DelegatingSmartConte throws Exception { AnnotationConfigUtils.registerAnnotationConfigProcessors((BeanDefinitionRegistry) context); - + +logger.info( I was here ); + // Post CamelContext(s) instantiation but pre CamelContext(s) start setup handleProvidesBreakpoint(context, testClass); handleShutdownTimeout(context, testClass); handleMockEndpoints(context, testClass); handleMockEndpointsAndSkip(context, testClass); +handleUseOverridePropertiesWithPropertiesComponent(context, testClass); // CamelContext(s) startup handleCamelContextStartup(context, testClass); @@ -277,7 +280,59 @@ public class CamelSpringDelegatingTestContextLoader extends DelegatingSmartConte } } - +/** + * Handles override this method to include and override properties with the Camel {@link org.apache.camel.component.properties.PropertiesComponent}. + * + * @param context the initialized Spring context + * @param testClass the test class being executed + */ +protected void handleUseOverridePropertiesWithPropertiesComponent(ConfigurableApplicationContext context, Class?
[2/2] camel git commit: Upgrade cmis and fixed CS
Upgrade cmis and fixed CS Project: http://git-wip-us.apache.org/repos/asf/camel/repo Commit: http://git-wip-us.apache.org/repos/asf/camel/commit/c1e500b0 Tree: http://git-wip-us.apache.org/repos/asf/camel/tree/c1e500b0 Diff: http://git-wip-us.apache.org/repos/asf/camel/diff/c1e500b0 Branch: refs/heads/master Commit: c1e500b0965e7a1afdd0ac97b4e4242f981c7e8b Parents: e9703d3 Author: Claus Ibsen davscl...@apache.org Authored: Sun Jul 19 11:37:30 2015 +0200 Committer: Claus Ibsen davscl...@apache.org Committed: Sun Jul 19 11:37:30 2015 +0200 -- .../camel/component/cmis/CMISProducer.java | 278 +-- .../camel/component/cmis/CMISSessionFacade.java | 35 ++- .../camel/component/cmis/CMISProducerTest.java | 34 +-- parent/pom.xml | 2 +- 4 files changed, 177 insertions(+), 172 deletions(-) -- http://git-wip-us.apache.org/repos/asf/camel/blob/c1e500b0/components/camel-cmis/src/main/java/org/apache/camel/component/cmis/CMISProducer.java -- diff --git a/components/camel-cmis/src/main/java/org/apache/camel/component/cmis/CMISProducer.java b/components/camel-cmis/src/main/java/org/apache/camel/component/cmis/CMISProducer.java index 49e4f80..f3d1b76 100644 --- a/components/camel-cmis/src/main/java/org/apache/camel/component/cmis/CMISProducer.java +++ b/components/camel-cmis/src/main/java/org/apache/camel/component/cmis/CMISProducer.java @@ -43,143 +43,143 @@ import org.slf4j.LoggerFactory; * The CMIS producer. */ public class CMISProducer extends DefaultProducer { - private static final Logger LOG = LoggerFactory.getLogger(CMISProducer.class); - private final CMISSessionFacade cmisSessionFacade; - - public CMISProducer(CMISEndpoint endpoint, CMISSessionFacade cmisSessionFacade) { - super(endpoint); - this.cmisSessionFacade = cmisSessionFacade; - } - - public void process(Exchange exchange) throws Exception { - CmisObject cmisObject = createNode(exchange); - LOG.debug(Created node with id: {}, cmisObject.getId()); - exchange.getOut().setBody(cmisObject.getId()); - } - - private MapString, Object filterTypeProperties(MapString, Object properties) { - MapString, Object result = new HashMapString, Object(properties.size()); - - String objectTypeName = CamelCMISConstants.CMIS_DOCUMENT; - if (properties.containsKey(PropertyIds.OBJECT_TYPE_ID)) { - objectTypeName = (String) properties.get(PropertyIds.OBJECT_TYPE_ID); - } - - SetString types = new HashSetString(); - types.addAll(cmisSessionFacade.getPropertiesFor(objectTypeName)); - - if (cmisSessionFacade.supportsSecondaries() properties.containsKey(PropertyIds.SECONDARY_OBJECT_TYPE_IDS)) { - @SuppressWarnings(unchecked) - CollectionString secondaryTypes = (CollectionString) properties.get(PropertyIds.SECONDARY_OBJECT_TYPE_IDS); - for (String secondaryType : secondaryTypes) { - types.addAll(cmisSessionFacade.getPropertiesFor(secondaryType)); - } - } - - for (Map.EntryString, Object entry : properties.entrySet()) { - if (types.contains(entry.getKey())) { - result.put(entry.getKey(), entry.getValue()); - } - } - return result; - } - - private CmisObject createNode(Exchange exchange) throws Exception { - validateRequiredHeader(exchange, PropertyIds.NAME); - - Message message = exchange.getIn(); - String parentFolderPath = parentFolderPathFor(message); - Folder parentFolder = getFolderOnPath(exchange, parentFolderPath); - MapString, Object cmisProperties = filterTypeProperties(message.getHeaders()); - - if (isDocument(exchange)) { - String fileName = message.getHeader(PropertyIds.NAME, String.class); - String mimeType = getMimeType(message); - byte[] buf = getBodyData(message); - ContentStream contentStream = cmisSessionFacade.createContentStream(fileName, buf, mimeType); - return storeDocument(parentFolder, cmisProperties, contentStream); - } else if (isFolder(message)) { - return storeFolder(parentFolder, cmisProperties); - } else { // other types - return storeDocument(parentFolder, cmisProperties, null); - } - } - -
camel git commit: Revert CAMEL-8639: Ensure FTP uses the FTP poll strategy by default. Thanks to Rob Sessink for the patch.
Repository: camel Updated Branches: refs/heads/camel-2.14.x 560044167 - 10e9a9b87 Revert CAMEL-8639: Ensure FTP uses the FTP poll strategy by default. Thanks to Rob Sessink for the patch. This reverts commit 560044167b6605abcd439716a58da5dd23759f4e. Project: http://git-wip-us.apache.org/repos/asf/camel/repo Commit: http://git-wip-us.apache.org/repos/asf/camel/commit/10e9a9b8 Tree: http://git-wip-us.apache.org/repos/asf/camel/tree/10e9a9b8 Diff: http://git-wip-us.apache.org/repos/asf/camel/diff/10e9a9b8 Branch: refs/heads/camel-2.14.x Commit: 10e9a9b8747b86bc6355f2d08e9b03c809ec70ec Parents: 5600441 Author: Claus Ibsen davscl...@apache.org Authored: Sun Jul 19 10:15:24 2015 +0200 Committer: Claus Ibsen davscl...@apache.org Committed: Sun Jul 19 10:15:24 2015 +0200 -- .../file/remote/RemoteFileEndpoint.java | 6 ...moteFilePollingConsumerPollStrategyTest.java | 30 2 files changed, 36 deletions(-) -- http://git-wip-us.apache.org/repos/asf/camel/blob/10e9a9b8/components/camel-ftp/src/main/java/org/apache/camel/component/file/remote/RemoteFileEndpoint.java -- diff --git a/components/camel-ftp/src/main/java/org/apache/camel/component/file/remote/RemoteFileEndpoint.java b/components/camel-ftp/src/main/java/org/apache/camel/component/file/remote/RemoteFileEndpoint.java index e327292..97a310d 100644 --- a/components/camel-ftp/src/main/java/org/apache/camel/component/file/remote/RemoteFileEndpoint.java +++ b/components/camel-ftp/src/main/java/org/apache/camel/component/file/remote/RemoteFileEndpoint.java @@ -50,9 +50,6 @@ public abstract class RemoteFileEndpointT extends GenericFileEndpointT { // for ftp we need to use higher interval/checkout that for files setReadLockTimeout(2); setReadLockCheckInterval(5000); -// explicitly set RemoteFilePollingConsumerPollStrategy otherwise -// DefaultPollingConsumerPollStrategy is be used -setPollStrategy(new RemoteFilePollingConsumerPollStrategy()); } public RemoteFileEndpoint(String uri, RemoteFileComponentT component, RemoteFileConfiguration configuration) { @@ -61,9 +58,6 @@ public abstract class RemoteFileEndpointT extends GenericFileEndpointT { // for ftp we need to use higher interval/checkout that for files setReadLockTimeout(2); setReadLockCheckInterval(5000); -// explicitly set RemoteFilePollingConsumerPollStrategy otherwise -// DefaultPollingConsumerPollStrategy is be used -setPollStrategy(new RemoteFilePollingConsumerPollStrategy()); } @Override http://git-wip-us.apache.org/repos/asf/camel/blob/10e9a9b8/components/camel-ftp/src/test/java/org/apache/camel/component/file/remote/RemoteEndPointRemoteFilePollingConsumerPollStrategyTest.java -- diff --git a/components/camel-ftp/src/test/java/org/apache/camel/component/file/remote/RemoteEndPointRemoteFilePollingConsumerPollStrategyTest.java b/components/camel-ftp/src/test/java/org/apache/camel/component/file/remote/RemoteEndPointRemoteFilePollingConsumerPollStrategyTest.java deleted file mode 100644 index 1d05b97..000 --- a/components/camel-ftp/src/test/java/org/apache/camel/component/file/remote/RemoteEndPointRemoteFilePollingConsumerPollStrategyTest.java +++ /dev/null @@ -1,30 +0,0 @@ -/** - * Licensed to the Apache Software Foundation (ASF) under one or more - * contributor license agreements. See the NOTICE file distributed with - * this work for additional information regarding copyright ownership. - * The ASF licenses this file to You under the Apache License, Version 2.0 - * (the License); you may not use this file except in compliance with - * the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an AS IS BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package org.apache.camel.component.file.remote; - -import org.apache.camel.test.junit4.CamelTestSupport; -import org.junit.Test; - -public class RemoteEndPointRemoteFilePollingConsumerPollStrategyTest extends CamelTestSupport { - -@Test -public void testPollStrategy() throws Exception { -RemoteFileEndpoint? endpoint = context.getEndpoint(ftp://hostname;, RemoteFileEndpoint.class); -assertTrue(endpoint.getPollStrategy() instanceof RemoteFilePollingConsumerPollStrategy); -} - -}
[2/2] camel git commit: CAMEL-7152: Polished
CAMEL-7152: Polished Project: http://git-wip-us.apache.org/repos/asf/camel/repo Commit: http://git-wip-us.apache.org/repos/asf/camel/commit/e21187e8 Tree: http://git-wip-us.apache.org/repos/asf/camel/tree/e21187e8 Diff: http://git-wip-us.apache.org/repos/asf/camel/diff/e21187e8 Branch: refs/heads/master Commit: e21187e8266aa2910c1273a08b5775308b4beedf Parents: f850321 Author: Claus Ibsen davscl...@apache.org Authored: Sun Jul 19 10:19:50 2015 +0200 Committer: Claus Ibsen davscl...@apache.org Committed: Sun Jul 19 10:20:58 2015 +0200 -- .../java/org/apache/camel/component/http/HttpEndpoint.java | 8 +--- .../java/org/apache/camel/component/http4/HttpEndpoint.java | 1 + 2 files changed, 6 insertions(+), 3 deletions(-) -- http://git-wip-us.apache.org/repos/asf/camel/blob/e21187e8/components/camel-http/src/main/java/org/apache/camel/component/http/HttpEndpoint.java -- diff --git a/components/camel-http/src/main/java/org/apache/camel/component/http/HttpEndpoint.java b/components/camel-http/src/main/java/org/apache/camel/component/http/HttpEndpoint.java index bcf6cb6..a31ec23 100644 --- a/components/camel-http/src/main/java/org/apache/camel/component/http/HttpEndpoint.java +++ b/components/camel-http/src/main/java/org/apache/camel/component/http/HttpEndpoint.java @@ -110,9 +110,9 @@ public class HttpEndpoint extends DefaultEndpoint implements HeaderFilterStrateg @UriParam(label = producer, description = If this option is true, The http producer won't read response body and cache the input stream) private boolean ignoreResponseBody; -@UriParam(defaultValue = true, -description = If this option is true then IN exchange headers will be copied to OUT exchange headers -+ according to copy strategy.) +@UriParam(label = producer, defaultValue = true, +description = If this option is true then IN exchange headers will be copied to OUT exchange headers according to copy strategy. ++ Setting this to false, allows to only include the headers from the HTTP response (not propagating IN headers).) private boolean copyHeaders = true; @UriParam(label = consumer, description = Whether to eager check whether the HTTP requests has content if the content-length header is 0 or not present. @@ -502,6 +502,7 @@ public class HttpEndpoint extends DefaultEndpoint implements HeaderFilterStrateg /** * If this option is true then IN exchange headers will be copied to OUT exchange headers according to copy strategy. + * Setting this to false, allows to only include the headers from the HTTP response (not propagating IN headers). */ public boolean isCopyHeaders() { return copyHeaders; @@ -510,6 +511,7 @@ public class HttpEndpoint extends DefaultEndpoint implements HeaderFilterStrateg public void setCopyHeaders(boolean copyHeaders) { this.copyHeaders = copyHeaders; } + public boolean isEagerCheckContentAvailable() { return eagerCheckContentAvailable; } http://git-wip-us.apache.org/repos/asf/camel/blob/e21187e8/components/camel-http4/src/main/java/org/apache/camel/component/http4/HttpEndpoint.java -- diff --git a/components/camel-http4/src/main/java/org/apache/camel/component/http4/HttpEndpoint.java b/components/camel-http4/src/main/java/org/apache/camel/component/http4/HttpEndpoint.java index 8b10cb8..c2c2c57 100644 --- a/components/camel-http4/src/main/java/org/apache/camel/component/http4/HttpEndpoint.java +++ b/components/camel-http4/src/main/java/org/apache/camel/component/http4/HttpEndpoint.java @@ -508,6 +508,7 @@ public class HttpEndpoint extends DefaultEndpoint implements HeaderFilterStrateg /** * If this option is true then IN exchange headers will be copied to OUT exchange headers according to copy strategy. + * Setting this to false, allows to only include the headers from the HTTP response (not propagating IN headers). */ public boolean isCopyHeaders() { return copyHeaders;
svn commit: r958910 [3/4] - in /websites/production/camel/content: book-component-appendix.html book-in-one-page.html cache/main.pageCache http.html http4.html
Modified: websites/production/camel/content/http.html == --- websites/production/camel/content/http.html (original) +++ websites/production/camel/content/http.html Sun Jul 19 08:20:50 2015 @@ -127,7 +127,7 @@ from(quot;direct:startquot;) lt;to uri=quot;http://www.google.comquot;/gt; lt;to uri=quot;mock:resultsquot;/gt; ]]/script -/div/div/td/tr/tbody/table/divh3 id=HTTP-HttpEndpointOptionsHttpEndpoint Options/h3div class=confluenceTableSmalldiv class=table-wraptable class=confluenceTabletbodytrth colspan=1 rowspan=1 class=confluenceThpName/p/thth colspan=1 rowspan=1 class=confluenceThpDefault Value/p/thth colspan=1 rowspan=1 class=confluenceThpDescription/p/th/trtrtd colspan=1 rowspan=1 class=confluenceTdpcodethrowExceptionOnFailure/code/p/tdtd colspan=1 rowspan=1 class=confluenceTdpcodetrue/code/p/tdtd colspan=1 rowspan=1 class=confluenceTdpOption to disable throwing the codeHttpOperationFailedException/code in case of failed responses from the remote server. This allows you to get all responses regardless of the HTTP status code./p/td/trtrtd colspan=1 rowspan=1 class=confluenceTdpcodebridgeEndpoint/code/p/tdtd colspan=1 rowspan=1 class=confluenc eTdpcodefalse/code/p/tdtd colspan=1 rowspan=1 class=confluenceTdpIf the option is true , HttpProducer will ignore the Exchange.HTTP_URI header, and use the endpoint's URI for request. You may also set the * throwExceptionOnFailure* to be false to let the HttpProducer send all the fault response back. br clear=none class=atl-forced-newline strongCamel 2.3:/strong If the option is true, HttpProducer and CamelServlet will skip the gzip processing if the content-encoding is gzip./p/td/trtrtd colspan=1 rowspan=1 class=confluenceTdpcodedisableStreamCache/code/p/tdtd colspan=1 rowspan=1 class=confluenceTdpcodefalse/code/p/tdtd colspan=1 rowspan=1 class=confluenceTdpDefaultHttpBinding will copy the request input stream into a stream cache and put it into message body if this option is false to support read it twice, otherwise DefaultHttpBinding will set the request input stream direct into the message bo dy./p/td/trtrtd colspan=1 rowspan=1 class=confluenceTdpcodehttpBindingRef/code/p/tdtd colspan=1 rowspan=1 class=confluenceTdpcodenull/code/p/tdtd colspan=1 rowspan=1 class=confluenceTdpstrongDeprecated and will be removed in Camel 3.0:/strong Reference to a codeorg.apache.camel.component.http.HttpBinding/code in the a shape=rect href=registry.htmlRegistry/a. Use the codehttpBinding/code option instead./p/td/trtrtd colspan=1 rowspan=1 class=confluenceTdpcodehttpBinding/code/p/tdtd colspan=1 rowspan=1 class=confluenceTdpcodenull/code/p/tdtd colspan=1 rowspan=1 class=confluenceTdpstrongCamel 2.3:/strong Reference to a codeorg.apache.camel.component.http.HttpBinding/code in the a shape=rect href=registry.htmlRegistry/a./p/td/trtrtd colspan=1 rowspan=1 class=confluenceTdpcodehttpClientConfigurerRef/code/p/tdtd colspan= 1 rowspan=1 class=confluenceTdpcodenull/code/p/tdtd colspan=1 rowspan=1 class=confluenceTdpstrongDeprecated and will be removed in Camel 3.0:/strong Reference to a codeorg.apache.camel.component.http.HttpClientConfigurer/code in the a shape=rect href=registry.htmlRegistry/a. Use the codehttpClientConfigurer/code option instead./p/td/trtrtd colspan=1 rowspan=1 class=confluenceTdpcodehttpClientConfigurer/code/p/tdtd colspan=1 rowspan=1 class=confluenceTdpcodenull/code/p/tdtd colspan=1 rowspan=1 class=confluenceTdpstrongCamel 2.3:/strong Reference to a codeorg.apache.camel.component.http.HttpClientConfigurer/code in the a shape=rect href=registry.htmlRegistry/a./p/td/trtrtd colspan=1 rowspan=1 class=confluenceTdpcodehttpClient.XXX/code/p/tdtd colspan=1 rowspan=1 class=confluenceTdpcodenull/code/p/tdtd colspan=1 rowspan=1 cl ass=confluenceTdpSetting options on the a shape=rect class=external-link href=http://hc.apache.org/httpclient-3.x/apidocs/org/apache/commons/httpclient/params/HttpClientParams.html;HttpClientParams/a. For instance codehttpClient.soTimeout=5000/code will set the codeSO_TIMEOUT/code to 5 seconds./p/td/trtrtd colspan=1 rowspan=1 class=confluenceTdpcodeclientConnectionManager/code/p/tdtd colspan=1 rowspan=1 class=confluenceTdpcodenull/code/p/tdtd colspan=1 rowspan=1 class=confluenceTdpTo use a custom codeorg.apache.http.conn.ClientConnectionManager/code./p/td/trtrtd colspan=1 rowspan=1 class=confluenceTdpcodetransferException/code/p/tdtd colspan=1 rowspan=1 class=confluenceTdpcodefalse/code/p/tdtd colspan=1 rowspan=1 class=confluenceTdpstrongCamel 2.6:/strong If enabled and an a shape=rect href=exchange.htmlExchange/a failed processing on the consumer side, and if the caused codeException/code was send back serialized in the response as a codeapplication/x-java-serialized-object/code content type (for example using a shape=rect href=jetty.htmlJetty/a or a shape=rect
svn commit: r958910 [1/4] - in /websites/production/camel/content: book-component-appendix.html book-in-one-page.html cache/main.pageCache http.html http4.html
Author: buildbot Date: Sun Jul 19 08:20:50 2015 New Revision: 958910 Log: Production update by buildbot for camel Modified: websites/production/camel/content/book-component-appendix.html websites/production/camel/content/book-in-one-page.html websites/production/camel/content/cache/main.pageCache websites/production/camel/content/http.html websites/production/camel/content/http4.html Modified: websites/production/camel/content/book-component-appendix.html == --- websites/production/camel/content/book-component-appendix.html (original) +++ websites/production/camel/content/book-component-appendix.html Sun Jul 19 08:20:50 2015 @@ -1268,11 +1268,11 @@ template.send(quot;direct:alias-verify ]]/script /div/divp/ph3 id=BookComponentAppendix-SeeAlso.8See Also/h3 ullia shape=rect href=configuring-camel.htmlConfiguring Camel/a/lilia shape=rect href=component.htmlComponent/a/lilia shape=rect href=endpoint.htmlEndpoint/a/lilia shape=rect href=getting-started.htmlGetting Started/a/li/ulullia shape=rect href=crypto.htmlCrypto/a Crypto is also available as a a shape=rect href=data-format.htmlData Format/a/li/ul h2 id=BookComponentAppendix-CXFComponentCXF Component/h2div class=confluence-information-macro confluence-information-macro-notespan class=aui-icon aui-icon-small aui-iconfont-warning confluence-information-macro-icon/spandiv class=confluence-information-macro-bodypWhen using CXF as a consumer, the a shape=rect href=cxf-bean-component.htmlCXF Bean Component/a allows you to factor out how message payloads are received from their processing as a RESTful or SOAP web service. This has the potential of using a multitude of transports to cons ume web services. The bean component's configuration is also simpler and provides the fastest method to implement web services using Camel and CXF./p/div/divdiv class=confluence-information-macro confluence-information-macro-tipspan class=aui-icon aui-icon-small aui-iconfont-approve confluence-information-macro-icon/spandiv class=confluence-information-macro-bodypWhen using CXF in streaming modes (see DataFormat option), then also read about a shape=rect href=stream-caching.htmlStream caching/a./p/div/divpThe strongcxf:/strong component provides integration with a shape=rect href=http://cxf.apache.org;Apache CXF/a for connecting to JAX-WS services hosted in CXF./ppstyle type=text/css/*![CDATA[*/ -div.rbtoc1437131876948 {padding: 0px;} -div.rbtoc1437131876948 ul {list-style: disc;margin-left: 0px;} -div.rbtoc1437131876948 li {margin-left: 0px;padding-left: 0px;} +div.rbtoc1437293926066 {padding: 0px;} +div.rbtoc1437293926066 ul {list-style: disc;margin-left: 0px;} +div.rbtoc1437293926066 li {margin-left: 0px;padding-left: 0px;} -/*]]*//style/pdiv class=toc-macro rbtoc1437131876948 +/*]]*//style/pdiv class=toc-macro rbtoc1437293926066 ul class=toc-indentationlia shape=rect href=#BookComponentAppendix-CXFComponentCXF Component/a ul class=toc-indentationlia shape=rect href=#BookComponentAppendix-URIformatURI format/a/lilia shape=rect href=#BookComponentAppendix-OptionsOptions/a ul class=toc-indentationlia shape=rect href=#BookComponentAppendix-ThedescriptionsofthedataformatsThe descriptions of the dataformats/a @@ -4521,7 +4521,7 @@ from(quot;direct:startquot;) lt;to uri=quot;http://www.google.comquot;/gt; lt;to uri=quot;mock:resultsquot;/gt; ]]/script -/div/div/td/tr/tbody/table/divh3 id=BookComponentAppendix-HttpEndpointOptionsHttpEndpoint Options/h3div class=confluenceTableSmalldiv class=table-wraptable class=confluenceTabletbodytrth colspan=1 rowspan=1 class=confluenceThpName/p/thth colspan=1 rowspan=1 class=confluenceThpDefault Value/p/thth colspan=1 rowspan=1 class=confluenceThpDescription/p/th/trtrtd colspan=1 rowspan=1 class=confluenceTdpcodethrowExceptionOnFailure/code/p/tdtd colspan=1 rowspan=1 class=confluenceTdpcodetrue/code/p/tdtd colspan=1 rowspan=1 class=confluenceTdpOption to disable throwing the codeHttpOperationFailedException/code in case of failed responses from the remote server. This allows you to get all responses regardless of the HTTP status code./p/td/trtrtd colspan=1 rowspan=1 class=confluenceTdpcodebridgeEndpoint/code/p/tdtd colspan=1 rowspan=1 class=confluenceTdpcodefalse/code/p/tdtd colspan=1 rowspan=1 class=confluenceTdpIf the option is true , HttpProducer will ignore the Exchange.HTTP_URI header, and use the endpoint's URI for request. You may also set the * throwExceptionOnFailure* to be false to let the HttpProducer send all the fault response back. br clear=none class=atl-forced-newline strongCamel 2.3:/strong If the option is true, HttpProducer and CamelServlet will skip the gzip processing if the content-encoding is gzip./p/td/trtrtd colspan=1 rowspan=1 class=confluenceTdpcodedisableStreamCache/code/p/tdtd colspan=1 rowspan=1 class=confluenceTdpcodefalse/code/p/tdtd colspan=1
svn commit: r958910 [2/4] - in /websites/production/camel/content: book-component-appendix.html book-in-one-page.html cache/main.pageCache http.html http4.html
Modified: websites/production/camel/content/book-in-one-page.html == --- websites/production/camel/content/book-in-one-page.html (original) +++ websites/production/camel/content/book-in-one-page.html Sun Jul 19 08:20:50 2015 @@ -3681,11 +3681,11 @@ The tutorial has been designed in two pa While not actual tutorials you might find working through the source of the various a shape=rect href=examples.htmlExamples/a useful./li/ul h2 id=BookInOnePage-TutorialonSpringRemotingwithJMSTutorial on Spring Remoting with JMS/h2p#160;/pdiv class=confluence-information-macro confluence-information-macro-informationp class=titleThanks/pspan class=aui-icon aui-icon-small aui-iconfont-info confluence-information-macro-icon/spandiv class=confluence-information-macro-bodypThis tutorial was kindly donated to Apache Camel by Martin Gilday./p/div/divh2 id=BookInOnePage-PrefacePreface/h2pThis tutorial aims to guide the reader through the stages of creating a project which uses Camel to facilitate the routing of messages from a JMS queue to a a shape=rect class=external-link href=http://www.springramework.org; rel=nofollowSpring/a service. The route works in a synchronous fashion returning a response to the client./ppstyle type=text/css/*![CDATA[*/ -div.rbtoc1437131904817 {padding: 0px;} -div.rbtoc1437131904817 ul {list-style: disc;margin-left: 0px;} -div.rbtoc1437131904817 li {margin-left: 0px;padding-left: 0px;} +div.rbtoc1437293951893 {padding: 0px;} +div.rbtoc1437293951893 ul {list-style: disc;margin-left: 0px;} +div.rbtoc1437293951893 li {margin-left: 0px;padding-left: 0px;} -/*]]*//style/pdiv class=toc-macro rbtoc1437131904817 +/*]]*//style/pdiv class=toc-macro rbtoc1437293951893 ul class=toc-indentationlia shape=rect href=#BookInOnePage-TutorialonSpringRemotingwithJMSTutorial on Spring Remoting with JMS/a/lilia shape=rect href=#BookInOnePage-PrefacePreface/a/lilia shape=rect href=#BookInOnePage-PrerequisitesPrerequisites/a/lilia shape=rect href=#BookInOnePage-DistributionDistribution/a/lilia shape=rect href=#BookInOnePage-AboutAbout/a/lilia shape=rect href=#BookInOnePage-CreatetheCamelProjectCreate the Camel Project/a ul class=toc-indentationlia shape=rect href=#BookInOnePage-UpdatethePOMwithDependenciesUpdate the POM with Dependencies/a/li/ul /lilia shape=rect href=#BookInOnePage-WritingtheServerWriting the Server/a @@ -5785,11 +5785,11 @@ So we completed the last piece in the pi pThis example has been removed from strongCamel 2.9/strong onwards. Apache Axis 1.4 is a very old and unsupported framework. We encourage users to use a shape=rect href=cxf.htmlCXF/a instead of Axis./p/div/div style type=text/css/*![CDATA[*/ -div.rbtoc1437131905406 {padding: 0px;} -div.rbtoc1437131905406 ul {list-style: disc;margin-left: 0px;} -div.rbtoc1437131905406 li {margin-left: 0px;padding-left: 0px;} +div.rbtoc1437293952217 {padding: 0px;} +div.rbtoc1437293952217 ul {list-style: disc;margin-left: 0px;} +div.rbtoc1437293952217 li {margin-left: 0px;padding-left: 0px;} -/*]]*//stylediv class=toc-macro rbtoc1437131905406 +/*]]*//stylediv class=toc-macro rbtoc1437293952217 ul class=toc-indentationlia shape=rect href=#BookInOnePage-TutorialusingAxis1.4withApacheCamelTutorial using Axis 1.4 with Apache Camel/a ul class=toc-indentationlia shape=rect href=#BookInOnePage-PrerequisitesPrerequisites/a/lilia shape=rect href=#BookInOnePage-DistributionDistribution/a/lilia shape=rect href=#BookInOnePage-IntroductionIntroduction/a/lilia shape=rect href=#BookInOnePage-SettinguptheprojecttorunAxisSetting up the project to run Axis/a ul class=toc-indentationlia shape=rect href=#BookInOnePage-Maven2Maven 2/a/lilia shape=rect href=#BookInOnePage-wsdlwsdl/a/lilia shape=rect href=#BookInOnePage-ConfiguringAxisConfiguring Axis/a/lilia shape=rect href=#BookInOnePage-RunningtheExampleRunning the Example/a/li/ul @@ -17751,11 +17751,11 @@ template.send(quot;direct:alias-verify ]]/script /div/divp/ph3 id=BookInOnePage-SeeAlso.28See Also/h3 ullia shape=rect href=configuring-camel.htmlConfiguring Camel/a/lilia shape=rect href=component.htmlComponent/a/lilia shape=rect href=endpoint.htmlEndpoint/a/lilia shape=rect href=getting-started.htmlGetting Started/a/li/ulullia shape=rect href=crypto.htmlCrypto/a Crypto is also available as a a shape=rect href=data-format.htmlData Format/a/li/ul h2 id=BookInOnePage-CXFComponentCXF Component/h2div class=confluence-information-macro confluence-information-macro-notespan class=aui-icon aui-icon-small aui-iconfont-warning confluence-information-macro-icon/spandiv class=confluence-information-macro-bodypWhen using CXF as a consumer, the a shape=rect href=cxf-bean-component.htmlCXF Bean Component/a allows you to factor out how message payloads are received from their processing as a RESTful or SOAP web service. This has the potential of using a multitude of transports to consume web
svn commit: r958910 [4/4] - in /websites/production/camel/content: book-component-appendix.html book-in-one-page.html cache/main.pageCache http.html http4.html
Modified: websites/production/camel/content/http4.html == --- websites/production/camel/content/http4.html (original) +++ websites/production/camel/content/http4.html Sun Jul 19 08:20:50 2015 @@ -96,7 +96,7 @@ /div/divdiv class=confluence-information-macro confluence-information-macro-informationp class=titlecamel-http4 vs camel-http/pspan class=aui-icon aui-icon-small aui-iconfont-info confluence-information-macro-icon/spandiv class=confluence-information-macro-bodypCamel-http4 uses a shape=rect class=external-link href=http://hc.apache.org/httpcomponents-client-ga/;Apache HttpClient 4.x/a while camel-http uses a shape=rect class=external-link href=http://hc.apache.org/httpclient-3.x/;Apache HttpClient 3.x/a./p/div/divh3 id=HTTP4-URIformatURI format/h3div class=code panel pdl style=border-width: 1px;div class=codeContent panelContent pdl script class=brush: java; gutter: false; theme: Default type=syntaxhighlighter![CDATA[http4:hostname[:port][/resourceUri][?options] ]]/script -/div/divpWill by default use port 80 for HTTP and 443 for HTTPS./ppYou can append query options to the URI in the following format, code?option=valueamp;option=valueamp;.../code/pdiv class=confluence-information-macro confluence-information-macro-informationp class=titlecamel-http4 vs camel-jetty/pspan class=aui-icon aui-icon-small aui-iconfont-info confluence-information-macro-icon/spandiv class=confluence-information-macro-bodypYou can only produce to endpoints generated by the HTTP4 component. Therefore it should never be used as input into your Camel Routes. To bind/expose an HTTP endpoint via a HTTP server as input to a Camel route, use the a shape=rect href=jetty.htmlJetty Component/a instead./p/div/divh3 id=HTTP4-HttpComponentOptionsHttpComponent Options/h3div class=table-wraptable class=confluenceTabletbodytrth colspan=1 rowspan=1 class=confluenceThpName/p/thth colspan=1 rowspan=1 clas s=confluenceThpDefault Value/p/thth colspan=1 rowspan=1 class=confluenceThpDescription/p/th/trtrtd colspan=1 rowspan=1 class=confluenceTdpcodemaxTotalConnections/code/p/tdtd colspan=1 rowspan=1 class=confluenceTdpcode200/code/p/tdtd colspan=1 rowspan=1 class=confluenceTdpThe maximum number of connections./p/td/trtrtd colspan=1 rowspan=1 class=confluenceTdpcodeconnectionsPerRoute/code/p/tdtd colspan=1 rowspan=1 class=confluenceTdpcode20/code/p/tdtd colspan=1 rowspan=1 class=confluenceTdpThe maximum number of connections per route./p/td/trtrtd colspan=1 rowspan=1 class=confluenceTdpcodecookieStore/code/p/tdtd colspan=1 rowspan=1 class=confluenceTdpcodenull/code/p/tdtd colspan=1 rowspan=1 class=confluenceTdpstrongCamel 2.11.2/2.12.0:/strong To use a custom codeorg.apache.http.client.CookieStore/code. By default the codeorg.apache.http.impl.client.BasicCookieStore/code is used which is an in-memory only cookie store. Notice if codebridgeEndpoint=true/code then the cookie store is forced to be a noop cookie store as cookies shouldn't be stored as we are just bridging (eg acting as a proxy)./p/td/trtrtd colspan=1 rowspan=1 class=confluenceTdpcodehttpClientConfigurer/code/p/tdtd colspan=1 rowspan=1 class=confluenceTdpcodenull/code/p/tdtd colspan=1 rowspan=1 class=confluenceTdpReference to a codeorg.apache.camel.component.http.HttpClientConfigurer/code in the a shape=rect href=registry.htmlRegistry/a./p/td/trtrtd colspan=1 rowspan=1 class=confluenceTdpcodeclientConnectionManager/code/p/tdtd colspan=1 rowspan=1 class=confluenceTdpcodenull/code/p/tdtd colspan=1 rowspan=1 class=confluenceTdpTo use a custom codeorg.apache.http.conn.ClientConnectionManager/co de./p/td/trtrtd colspan=1 rowspan=1 class=confluenceTdpcodehttpBinding/code/p/tdtd colspan=1 rowspan=1 class=confluenceTdpcodenull/code/p/tdtd colspan=1 rowspan=1 class=confluenceTdpTo use a custom codeorg.apache.camel.component.http.HttpBinding/code./p/td/trtrtd colspan=1 rowspan=1 class=confluenceTdpcodehttpContext/code/p/tdtd colspan=1 rowspan=1 class=confluenceTdpcodenull/code/p/tdtd colspan=1 rowspan=1 class=confluenceTdpstrongCamel 2.9.2:/strong To use a custom codeorg.apache.http.protocol.HttpContext/code when executing requests./p/td/trtrtd colspan=1 rowspan=1 class=confluenceTdpcodesslContextParameters/code/p/tdtd colspan=1 rowspan=1 class=confluenceTdpcodenull/code/p/tdtd colspan=1 rowspan=1 class=confluenceTdpstrongCamel 2.8:/strong To use a custom codeorg.apache.camel.util.jsse.SSLContextParam eters/code. See a shape=rect href=#HTTP4-UsingtheJSSEConfigurationUtilityUsing the JSSE Configuration Utility/a. strongImportant:/strong Only one instance of codeorg.apache.camel.util.jsse.SSLContextParameters/code is supported per HttpComponent. If you need to use 2 or more different instances, you need to define a new HttpComponent per instance you need. See further below for more details./p/td/trtrtd colspan=1 rowspan=1
[1/2] camel git commit: Added support for secondary types (CMIS 1.1)
Repository: camel Updated Branches: refs/heads/master 3b5c6aeef - c1e500b09 Added support for secondary types (CMIS 1.1) Project: http://git-wip-us.apache.org/repos/asf/camel/repo Commit: http://git-wip-us.apache.org/repos/asf/camel/commit/e9703d34 Tree: http://git-wip-us.apache.org/repos/asf/camel/tree/e9703d34 Diff: http://git-wip-us.apache.org/repos/asf/camel/diff/e9703d34 Branch: refs/heads/master Commit: e9703d3415733bc1d0a5c607e70cecc7a6d84ebe Parents: 3b5c6ae Author: bpeters bas.pet...@alfresco.com Authored: Fri Jun 5 10:14:22 2015 +0200 Committer: Claus Ibsen davscl...@apache.org Committed: Sun Jul 19 11:33:14 2015 +0200 -- .../camel/component/cmis/CMISProducer.java | 272 ++- .../camel/component/cmis/CMISSessionFacade.java | 13 + .../camel/component/cmis/CMISProducerTest.java | 22 ++ .../camel/component/cmis/CMISTestSupport.java | 4 +- 4 files changed, 178 insertions(+), 133 deletions(-) -- http://git-wip-us.apache.org/repos/asf/camel/blob/e9703d34/components/camel-cmis/src/main/java/org/apache/camel/component/cmis/CMISProducer.java -- diff --git a/components/camel-cmis/src/main/java/org/apache/camel/component/cmis/CMISProducer.java b/components/camel-cmis/src/main/java/org/apache/camel/component/cmis/CMISProducer.java index b05346d..49e4f80 100644 --- a/components/camel-cmis/src/main/java/org/apache/camel/component/cmis/CMISProducer.java +++ b/components/camel-cmis/src/main/java/org/apache/camel/component/cmis/CMISProducer.java @@ -16,7 +16,9 @@ */ package org.apache.camel.component.cmis; +import java.util.Collection; import java.util.HashMap; +import java.util.HashSet; import java.util.Map; import java.util.Set; @@ -30,7 +32,6 @@ import org.apache.camel.util.MessageHelper; import org.apache.chemistry.opencmis.client.api.CmisObject; import org.apache.chemistry.opencmis.client.api.Document; import org.apache.chemistry.opencmis.client.api.Folder; -import org.apache.chemistry.opencmis.client.api.ObjectType; import org.apache.chemistry.opencmis.commons.PropertyIds; import org.apache.chemistry.opencmis.commons.data.ContentStream; import org.apache.chemistry.opencmis.commons.enums.VersioningState; @@ -42,134 +43,143 @@ import org.slf4j.LoggerFactory; * The CMIS producer. */ public class CMISProducer extends DefaultProducer { -private static final Logger LOG = LoggerFactory.getLogger(CMISProducer.class); -private final CMISSessionFacade cmisSessionFacade; - -public CMISProducer(CMISEndpoint endpoint, CMISSessionFacade cmisSessionFacade) { -super(endpoint); -this.cmisSessionFacade = cmisSessionFacade; -} - -public void process(Exchange exchange) throws Exception { -CmisObject cmisObject = createNode(exchange); -LOG.debug(Created node with id: {}, cmisObject.getId()); -exchange.getOut().setBody(cmisObject.getId()); -} - -private MapString, Object filterTypeProperties(MapString, Object properties) { -MapString, Object result = new HashMapString, Object(properties.size()); -String objectTypeName = CamelCMISConstants.CMIS_DOCUMENT; -if (properties.containsKey(PropertyIds.OBJECT_TYPE_ID)) { -objectTypeName = (String) properties.get(PropertyIds.OBJECT_TYPE_ID); -} - -SetString types = cmisSessionFacade.getPropertiesFor(objectTypeName); -for (Map.EntryString, Object entry : properties.entrySet()) { -if (types.contains(entry.getKey())) { -result.put(entry.getKey(), entry.getValue()); -} -} -return result; -} - -private CmisObject createNode(Exchange exchange) throws Exception { -validateRequiredHeader(exchange, PropertyIds.NAME); - -Message message = exchange.getIn(); -String parentFolderPath = parentFolderPathFor(message); -Folder parentFolder = getFolderOnPath(exchange, parentFolderPath); -MapString, Object cmisProperties = filterTypeProperties(message.getHeaders()); - -if (isDocument(exchange)) { -String fileName = message.getHeader(PropertyIds.NAME, String.class); -String mimeType = getMimeType(message); -byte[] buf = getBodyData(message); -ContentStream contentStream = cmisSessionFacade.createContentStream(fileName, buf, mimeType); -return storeDocument(parentFolder, cmisProperties, contentStream); -} else if (isFolder(message)) { -return storeFolder(parentFolder, cmisProperties); -} else { //other types -return storeDocument(parentFolder, cmisProperties, null); -} -} - -private Folder getFolderOnPath(Exchange exchange, String path) { -try { -return
camel git commit: Upgrade Chunk to version 3.0.1
Repository: camel Updated Branches: refs/heads/master c1e500b09 - 80bb02d58 Upgrade Chunk to version 3.0.1 Project: http://git-wip-us.apache.org/repos/asf/camel/repo Commit: http://git-wip-us.apache.org/repos/asf/camel/commit/80bb02d5 Tree: http://git-wip-us.apache.org/repos/asf/camel/tree/80bb02d5 Diff: http://git-wip-us.apache.org/repos/asf/camel/diff/80bb02d5 Branch: refs/heads/master Commit: 80bb02d584962e56575e6d015bf398d6938da0ed Parents: c1e500b Author: Andrea Cosentino anco...@gmail.com Authored: Sun Jul 19 12:15:19 2015 +0200 Committer: Andrea Cosentino anco...@gmail.com Committed: Sun Jul 19 12:15:19 2015 +0200 -- parent/pom.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) -- http://git-wip-us.apache.org/repos/asf/camel/blob/80bb02d5/parent/pom.xml -- diff --git a/parent/pom.xml b/parent/pom.xml index 0e001d6..78ec68b 100644 --- a/parent/pom.xml +++ b/parent/pom.xml @@ -88,7 +88,7 @@ cdi-api-version1.1/cdi-api-version cglib-bundle-version2.1_3_7/cglib-bundle-version cglib-version2.2/cglib-version -chunk-templates-version3.0.0/chunk-templates-version +chunk-templates-version3.0.1/chunk-templates-version classmate-version1.0.0/classmate-version cmis-version0.13.0/cmis-version cometd-bayeux-version6.1.11/cometd-bayeux-version
svn commit: r958927 [2/2] - in /websites/production/camel/content: book-cookbook.html book-in-one-page.html cache/main.pageCache camel-2160-release.html spring-testing.html
Modified: websites/production/camel/content/camel-2160-release.html == --- websites/production/camel/content/camel-2160-release.html (original) +++ websites/production/camel/content/camel-2160-release.html Sun Jul 19 10:19:32 2015 @@ -84,7 +84,7 @@ tbody tr td valign=top width=100% -div class=wiki-content maincontenth1 id=Camel2.16.0Release-Camel2.16.0release(currentlyinprogress)Camel 2.16.0#160;release (currently in progress)/h1div style=padding-right:20px;float:left;margin-left:-20px;pspan class=confluence-embedded-file-wrapperimg class=confluence-embedded-image confluence-external-resource src=http://camel.apache.org/download.data/camel-box-v1.0-150x200.png; data-image-src=http://camel.apache.org/download.data/camel-box-v1.0-150x200.png;/span/p/divdiv style=min-height:200px#160;/divh2 id=Camel2.16.0Release-NewandNoteworthyNew and Noteworthy/h2pWelcome to the 2.16.0 release which approx XXX issues resolved (new features, improvements and bug fixes such as...)/ppNoteworthy improvements:/pulliThe route models (definition classes) preserve property placeholders, which allows round trip editing, and also prevents showing potential sensitive information/liliAdded onPrepareFailure option to#160;a shape =rect href=dead-letter-channel.htmlDead Letter Channel/a to allow a custom processor to prepare the Exchange before sending to the dead letter queue./lilia shape=rect href=mongodb.htmlMongoDB/a tailable consumers now allow setting the codereadPreference/code option./liliUsing setFaultBody / setFaultHeader behaves similar to setBody / setHeader to preserve existing headers/attachments by setting on existing IN or OUT message./liliJava DSL using choice with end vs endChoice now validates you use them as intended. Any misconfiguration now throws an exception explaining the problem./lilia shape=rect href=pojo-producing.htmlPOJO Producing/a and#160;a shape=rect href=pojo-consuming.htmlPOJO Consuming/a lifecycle is now in sync with a shape=rect href=camelcontext.htmlCamelContext/a#160;which ensures it works as similar to Camel#160;a shape=rect href=routes.htmlRoutes/a does. Also the created producer/consumer is stopped when#160;a shape=rect href=camelcontext.htmlCamelContext/a#160;is stopping to cleanup properly./lilia shape=rect href=jms.htmlJMS/a#160;component now allows configuring concurrentConsumers/maxConcurrentConsumers separately between from(jms) vs to(jms) using request/reply over JMS/lilispana shape=rect class=external-link href=https://issues.apache.org/jira/browse/CAMEL-8506;Added SEARCH/a operation to Elasticsearch component/span/lilispanThe#160;a shape=rect href=properties.htmlProperties/a component (property placeholder) now supports an encoding option to allow reading the .properties files using a specific charset such as UTF-8. By default ISO-8859-1 is used (latin1)/span/lilispanAdded#160;codereceviveBufferSize/code option to the a shape=rect href=ftp.htmlFTP/a#160;component to make download faster. The size is by default 32kb buffer./span/lilispanThe#160;a shape=rect href=aggregator2.html Aggregator2/a EIP now allows an external source using a#160;codeAggregateController/code to control the aggregator, such as for forcing completing a group or all groups, or query runtime information from the aggregator. A default controller is provided out of the box if none has been configured./span/lilispanThe#160;a shape=rect href=aggregator2.htmlAggregator2/a now enlists in JMX using a#160;codeManagedAggregateProcessorMBean/code which has more information, and also allows using the aggregate controller to control it./span/lilispanThe#160;a shape=rect href=aggregator2.htmlAggregator2/a now includes more runtime statistics which can be accessed from Java and JMX about number of incoming and completed exchanges, and per different completion triggers./span/lilispanThe#160;a shape=rect href=aggregator2.htmlAggregator2/a now supports pre-completion mode if the aggregation strategy implements#160;codePreCompletionAwareAg gregationStrategy/code. This supports the use-case where an incoming Exchange are used to determine if the current aggregated group is completed or not. If completed the group is emitted as-is, and the new incoming Exchange is used to start a new group from scratch./span/lilispanAdded options to#160;a shape=rect href=mail.htmlMail/a consumer so it can skip or handle a mail message that cannot be read from the mail server in the batch; and then move on to read the next message. This ensures the consumer can deal with mail boxes that has problematic mails that otherwise will cause no mails to be retrieve by the consumer in the batch./span/liliThe runtime route processors and their corresponding model definition are now linked by their id using codeHasId/code, so its easier to obtain the processor or model definition from the
svn commit: r958927 [1/2] - in /websites/production/camel/content: book-cookbook.html book-in-one-page.html cache/main.pageCache camel-2160-release.html spring-testing.html
Author: buildbot Date: Sun Jul 19 10:19:32 2015 New Revision: 958927 Log: Production update by buildbot for camel Modified: websites/production/camel/content/book-cookbook.html websites/production/camel/content/book-in-one-page.html websites/production/camel/content/cache/main.pageCache websites/production/camel/content/camel-2160-release.html websites/production/camel/content/spring-testing.html Modified: websites/production/camel/content/book-cookbook.html == --- websites/production/camel/content/book-cookbook.html (original) +++ websites/production/camel/content/book-cookbook.html Sun Jul 19 10:19:32 2015 @@ -1934,7 +1934,7 @@ public class FilterTest extends SpringRu } } ]]/script -/div/divpNotice that we use#160;strong@DirtiesContext/strong#160;on the test methods to force#160;a shape=rect href=spring-testing.htmlSpring Testing/a#160;to automatically reload the#160;a shape=rect href=camelcontext.htmlCamelContext/a#160;after each test method - this ensures that the tests don't clash with each other (e.g. one test method sending to an endpoint that is then reused in another test method)./ppAlso notice the use of#160;strong@ContextConfiguration/strong#160;to indicate that by default we should look for the#160;a shape=rect class=external-link href=http://svn.apache.org/repos/asf/camel/trunk/components/camel-spring/src/test/resources/org/apache/camel/spring/patterns/FilterTest-context.xml;FilterTest-context.xml on the classpath/a#160;to configure the test case which looks like this/pdiv class=code panel pdl style=border-width: 1px;div class=codeContent panelContent pdl +/div/divNotice that we use#160;strong@DirtiesContext/strong#160;on the test methods to force#160;a shape=rect href=spring-testing.htmlSpring Testing/a#160;to automatically reload the#160;a shape=rect href=camelcontext.htmlCamelContext/a#160;after each test method - this ensures that the tests don't clash with each other (e.g. one test method sending to an endpoint that is then reused in another test method).pAlso notice the use of#160;strong@ContextConfiguration/strong#160;to indicate that by default we should look for the#160;a shape=rect class=external-link href=http://svn.apache.org/repos/asf/camel/trunk/components/camel-spring/src/test/resources/org/apache/camel/spring/patterns/FilterTest-context.xml;FilterTest-context.xml on the classpath/a#160;to configure the test case which looks like this/pdiv class=code panel pdl style=border-width: 1px;div class=codeContent panelContent pdl script class=brush: xml; gutter: false; theme: Default type=syntaxhighlighter![CDATA[ lt;beans xmlns=quot;http://www.springframework.org/schema/beansquot; xmlns:xsi=quot;http://www.w3.org/2001/XMLSchema-instancequot; @@ -1956,7 +1956,7 @@ public class FilterTest extends SpringRu lt;/beansgt; ]]/script -/div/divpThis test will load a Spring XML configuration file calledFilterTest-context.xml#160;from the classpath in the same package structure as the FilterTest class and initialize it along with any Camel routes we define inside it, then inject theCamelContextinstance into our test case./ppFor instance, like this maven folder layout:/pdiv class=code panel pdl style=border-width: 1px;div class=codeContent panelContent pdl +/div/divThis test will load a Spring XML configuration file calledFilterTest-context.xml#160;from the classpath in the same package structure as the FilterTest class and initialize it along with any Camel routes we define inside it, then inject theCamelContextinstance into our test case.pFor instance, like this maven folder layout:/pdiv class=code panel pdl style=border-width: 1px;div class=codeContent panelContent pdl script class=brush: java; gutter: false; theme: Default type=syntaxhighlighter![CDATA[src/test/java/org/apache/camel/spring/patterns/FilterTest.java src/test/resources/org/apache/camel/spring/patterns/FilterTest-context.xml ]]/script @@ -2008,7 +2008,7 @@ public class FilterTest extends Abstract } } ]]/script -/div/divpThis is similar to the XML Config example above except that there is no XML file and instead the nested strongContextConfig/strong class does all of the configuration; so your entire test case is contained in a single Java class. We currently have to reference by class name this class in the strong@ContextConfiguration/strong which is a bit ugly. Please vote for a shape=rect class=external-link href=http://jira.springframework.org/browse/SJC-238; rel=nofollowSJC-238/a to address this and make Spring Test work more cleanly with Spring JavaConfig./ph4 id=Bookcookbook-PlainSpringTestusingJUnit4.0.xRunnerwithXMLConfigPlain Spring Test using JUnit 4.0.x Runner with XML Config/h4pYou can avoid extending Spring classes by using the SpringJUnit4ClassRunner provided by Spring Test. #160;This custom JUnit runner means you are free to choose your
camel git commit: Upgrade Jboss Logging to version 3.3.0.Final
Repository: camel Updated Branches: refs/heads/master 80bb02d58 - 164022d25 Upgrade Jboss Logging to version 3.3.0.Final Project: http://git-wip-us.apache.org/repos/asf/camel/repo Commit: http://git-wip-us.apache.org/repos/asf/camel/commit/164022d2 Tree: http://git-wip-us.apache.org/repos/asf/camel/tree/164022d2 Diff: http://git-wip-us.apache.org/repos/asf/camel/diff/164022d2 Branch: refs/heads/master Commit: 164022d25584531efba9e7469f2a6ae546f0b9d9 Parents: 80bb02d Author: Andrea Cosentino anco...@gmail.com Authored: Sun Jul 19 12:38:41 2015 +0200 Committer: Andrea Cosentino anco...@gmail.com Committed: Sun Jul 19 12:38:41 2015 +0200 -- parent/pom.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) -- http://git-wip-us.apache.org/repos/asf/camel/blob/164022d2/parent/pom.xml -- diff --git a/parent/pom.xml b/parent/pom.xml index 78ec68b..e39986b 100644 --- a/parent/pom.xml +++ b/parent/pom.xml @@ -251,7 +251,7 @@ jaxb-bundle-version2.2.6_1/jaxb-bundle-version jaxen-version1.1.6/jaxen-version jboss-javaee-6-version1.0.0.Final/jboss-javaee-6-version -jboss-logging-version3.1.4.GA/jboss-logging-version +jboss-logging-version3.3.0.Final/jboss-logging-version jboss-marshalling-version1.4.10.Final/jboss-marshalling-version jclouds-version1.9.0/jclouds-version !-- jclouds must use this guava version --
buildbot failure in ASF Buildbot on camel-site-production
The Buildbot has detected a new failure on builder camel-site-production while building ASF Buildbot. Full details are available at: http://ci.apache.org/builders/camel-site-production/builds/465 Buildbot URL: http://ci.apache.org/ Buildslave for this Build: bb-cms-slave Build Reason: The Nightly scheduler named 'camel-site-production' triggered this build Build Source Stamp: [branch camel/website] HEAD Blamelist: BUILD FAILED: failed compile Sincerely, -The Buildbot
buildbot success in ASF Buildbot on camel-site-production
The Buildbot has detected a restored build on builder camel-site-production while building ASF Buildbot. Full details are available at: http://ci.apache.org/builders/camel-site-production/builds/466 Buildbot URL: http://ci.apache.org/ Buildslave for this Build: bb-cms-slave Build Reason: The Nightly scheduler named 'camel-site-production' triggered this build Build Source Stamp: [branch camel/website] HEAD Blamelist: Build succeeded! Sincerely, -The Buildbot
buildbot success in ASF Buildbot on camel-site-production
The Buildbot has detected a restored build on builder camel-site-production while building ASF Buildbot. Full details are available at: http://ci.apache.org/builders/camel-site-production/builds/479 Buildbot URL: http://ci.apache.org/ Buildslave for this Build: bb-cms-slave Build Reason: The Nightly scheduler named 'camel-site-production' triggered this build Build Source Stamp: [branch camel/website] HEAD Blamelist: Build succeeded! Sincerely, -The Buildbot
buildbot failure in ASF Buildbot on camel-site-production
The Buildbot has detected a new failure on builder camel-site-production while building ASF Buildbot. Full details are available at: http://ci.apache.org/builders/camel-site-production/builds/480 Buildbot URL: http://ci.apache.org/ Buildslave for this Build: bb-cms-slave Build Reason: The Nightly scheduler named 'camel-site-production' triggered this build Build Source Stamp: [branch camel/website] HEAD Blamelist: BUILD FAILED: failed compile Sincerely, -The Buildbot