This is an automated email from the ASF dual-hosted git repository. bvahdat pushed a commit to branch master in repository https://gitbox.apache.org/repos/asf/camel.git
The following commit(s) were added to refs/heads/master by this push: new ab594f3 fix the failing tests on the ci-server ab594f3 is described below commit ab594f36fe1606ca7408713b0a4ff55dfabe5cf6 Author: Babak Vahdat <bvah...@apache.org> AuthorDate: Tue Aug 13 21:51:35 2019 +0200 fix the failing tests on the ci-server --- .../camel/component/http/CamelHttp4Context.xml | 79 ---------------------- .../camel/itest/http/Http4EndpointTest-context.xml | 55 --------------- .../http/Http4MaxConnectionPerHostTest-context.xml | 46 ------------- .../camel/itest/http/HttpEndpointTest-context.xml | 21 +++--- .../http/HttpMaxConnectionPerHostTest-context.xml | 18 ++--- 5 files changed, 18 insertions(+), 201 deletions(-) diff --git a/components/camel-http/src/test/resources/org/apache/camel/component/http/CamelHttp4Context.xml b/components/camel-http/src/test/resources/org/apache/camel/component/http/CamelHttp4Context.xml deleted file mode 100644 index bb1c7d3..0000000 --- a/components/camel-http/src/test/resources/org/apache/camel/component/http/CamelHttp4Context.xml +++ /dev/null @@ -1,79 +0,0 @@ -<?xml version="1.0" encoding="UTF-8"?> -<!-- - - 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. - ---> -<beans xmlns="http://www.springframework.org/schema/beans" - xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" - xmlns:camel="http://camel.apache.org/schema/spring" - - xsi:schemaLocation=" - http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans.xsd - http://camel.apache.org/schema/spring http://camel.apache.org/schema/spring/camel-spring.xsd - "> - - <bean class="org.springframework.beans.factory.config.PropertyPlaceholderConfigurer"/> - - <camel:sslContextParameters id="correctSniSslContextParameters"> - <camel:clientParameters> - <camel:sniHostNames> - <camel:sniHostName>www.mnot.net</camel:sniHostName> - </camel:sniHostNames> - </camel:clientParameters> - </camel:sslContextParameters> - - <camel:sslContextParameters id="noSniSslContextParameters"> - </camel:sslContextParameters> - - <camel:sslContextParameters id="wrongSniSslContextParameters"> - <camel:clientParameters> - <camel:sniHostNames> - <camel:sniHostName>blabla</camel:sniHostName> - </camel:sniHostNames> - </camel:clientParameters> - </camel:sslContextParameters> - - <bean id="https4" class="org.apache.camel.component.http.HttpComponent"> - <property name="sslContextParameters" ref="correctSniSslContextParameters"/> - </bean> - - <bean id="https4-no" class="org.apache.camel.component.http.HttpComponent"> - <property name="sslContextParameters" ref="noSniSslContextParameters"/> - </bean> - - <bean id="https4-wrong" class="org.apache.camel.component.http.HttpComponent"> - <property name="sslContextParameters" ref="wrongSniSslContextParameters"/> - </bean> - - <camelContext id="camel" xmlns="http://camel.apache.org/schema/spring"> - <route errorHandlerRef="noErrorHandler"> - <from uri="direct:goodSNI"/> - <to uri="https4://www.mnot.net?sslContextParameters=#correctSniSslContextParameters"/> - </route> - <route errorHandlerRef="noErrorHandler"> - <from uri="direct:wrongSNI"/> - <to uri="https4-wrong://www.mnot.net?sslContextParameters=#wrongSniSslContextParameters"/> - </route> - <route errorHandlerRef="noErrorHandler"> - <from uri="direct:noSNI"/> - <to uri="https4-no://www.mnot.net?sslContextParameters=#noSniSslContextParameters"/> - </route> - </camelContext> - - <bean id="noErrorHandler" class="org.apache.camel.builder.NoErrorHandlerBuilder"/> - -</beans> diff --git a/tests/camel-itest/src/test/resources/org/apache/camel/itest/http/Http4EndpointTest-context.xml b/tests/camel-itest/src/test/resources/org/apache/camel/itest/http/Http4EndpointTest-context.xml deleted file mode 100644 index 2ddffc8..0000000 --- a/tests/camel-itest/src/test/resources/org/apache/camel/itest/http/Http4EndpointTest-context.xml +++ /dev/null @@ -1,55 +0,0 @@ -<?xml version="1.0" encoding="UTF-8"?> -<!-- - - 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. - ---> -<beans xmlns="http://www.springframework.org/schema/beans" - xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" - - xsi:schemaLocation=" - http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans.xsd - http://camel.apache.org/schema/spring http://camel.apache.org/schema/spring/camel-spring.xsd - "> - - <!-- START SNIPPET: e1 --> - <bean class="org.springframework.beans.factory.config.PropertyPlaceholderConfigurer"/> - - <bean id="httpEndpoint" class="org.apache.camel.component.http.HttpEndpoint"> - <property name="httpUri" value="http://localhost:${HttpTestServer.Port}/"/> - <property name="clientBuilder" ref="clientBuilder"/> - <property name="clientConnectionManager" ref="myManager"/> - </bean> - - <bean id="myManager" class="org.apache.http.impl.conn.PoolingHttpClientConnectionManager"/> - - <!-- You can set the client configuration by setting up the builder class --> - <bean id="clientBuilder" class="org.apache.http.impl.client.HttpClientBuilder" /> - - - <!-- END SNIPPET: e1 --> - - <!-- START SNIPPET: e2 --> - <camelContext id="camel" xmlns="http://camel.apache.org/schema/spring" trace="true"> - <route> - <from uri="direct:start"/> - <to uri="httpEndpoint"/> - <to uri="mock:result"/> - </route> - </camelContext> - <!-- END SNIPPET: e2 --> - -</beans> \ No newline at end of file diff --git a/tests/camel-itest/src/test/resources/org/apache/camel/itest/http/Http4MaxConnectionPerHostTest-context.xml b/tests/camel-itest/src/test/resources/org/apache/camel/itest/http/Http4MaxConnectionPerHostTest-context.xml deleted file mode 100644 index 8b3c66d..0000000 --- a/tests/camel-itest/src/test/resources/org/apache/camel/itest/http/Http4MaxConnectionPerHostTest-context.xml +++ /dev/null @@ -1,46 +0,0 @@ -<?xml version="1.0" encoding="UTF-8"?> -<!-- - - 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. - ---> -<beans xmlns="http://www.springframework.org/schema/beans" - xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" - - xsi:schemaLocation=" - http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans.xsd - http://camel.apache.org/schema/spring http://camel.apache.org/schema/spring/camel-spring.xsd - "> - - <!-- START SNIPPET: e1 --> - <bean id="properties" class="org.apache.camel.component.properties.PropertiesComponent"/> - <bean id="httpComponent" class="org.apache.camel.component.http.HttpComponent"> - <property name="camelContext" ref="camel"/> - <property name="connectionsPerRoute" value="5" /> - </bean> - - <!-- END SNIPPET: e1 --> - - <!-- START SNIPPET: e2 --> - <camelContext id="camel" xmlns="http://camel.apache.org/schema/spring" trace="true"> - <route> - <from uri="direct:start"/> - <to uri="http://localhost:{{HttpTestServer.Port}}/"/> - <to uri="mock:result"/> - </route> - </camelContext> - <!-- END SNIPPET: e2 --> -</beans> \ No newline at end of file diff --git a/tests/camel-itest/src/test/resources/org/apache/camel/itest/http/HttpEndpointTest-context.xml b/tests/camel-itest/src/test/resources/org/apache/camel/itest/http/HttpEndpointTest-context.xml index b6b9dea..2ddffc8 100644 --- a/tests/camel-itest/src/test/resources/org/apache/camel/itest/http/HttpEndpointTest-context.xml +++ b/tests/camel-itest/src/test/resources/org/apache/camel/itest/http/HttpEndpointTest-context.xml @@ -26,25 +26,30 @@ "> <!-- START SNIPPET: e1 --> - <bean id="google" class="org.apache.camel.component.http.HttpEndpoint"> - <property name="httpUri" value="http://www.google.com"/> - <property name="clientParams" ref="myParams"/> - <property name="httpConnectionManager" ref="myManager"/> + <bean class="org.springframework.beans.factory.config.PropertyPlaceholderConfigurer"/> + + <bean id="httpEndpoint" class="org.apache.camel.component.http.HttpEndpoint"> + <property name="httpUri" value="http://localhost:${HttpTestServer.Port}/"/> + <property name="clientBuilder" ref="clientBuilder"/> + <property name="clientConnectionManager" ref="myManager"/> </bean> + + <bean id="myManager" class="org.apache.http.impl.conn.PoolingHttpClientConnectionManager"/> - <bean id="myParams" class="org.apache.commons.httpclient.params.HttpClientParams"/> + <!-- You can set the client configuration by setting up the builder class --> + <bean id="clientBuilder" class="org.apache.http.impl.client.HttpClientBuilder" /> + - <bean id="myManager" class="org.apache.commons.httpclient.MultiThreadedHttpConnectionManager"/> <!-- END SNIPPET: e1 --> <!-- START SNIPPET: e2 --> <camelContext id="camel" xmlns="http://camel.apache.org/schema/spring" trace="true"> <route> <from uri="direct:start"/> - <to uri="google"/> + <to uri="httpEndpoint"/> <to uri="mock:result"/> </route> </camelContext> <!-- END SNIPPET: e2 --> -</beans> +</beans> \ No newline at end of file diff --git a/tests/camel-itest/src/test/resources/org/apache/camel/itest/http/HttpMaxConnectionPerHostTest-context.xml b/tests/camel-itest/src/test/resources/org/apache/camel/itest/http/HttpMaxConnectionPerHostTest-context.xml index ea20e8d..8b3c66d 100644 --- a/tests/camel-itest/src/test/resources/org/apache/camel/itest/http/HttpMaxConnectionPerHostTest-context.xml +++ b/tests/camel-itest/src/test/resources/org/apache/camel/itest/http/HttpMaxConnectionPerHostTest-context.xml @@ -26,17 +26,10 @@ "> <!-- START SNIPPET: e1 --> - <bean id="http" class="org.apache.camel.component.http.HttpComponent"> + <bean id="properties" class="org.apache.camel.component.properties.PropertiesComponent"/> + <bean id="httpComponent" class="org.apache.camel.component.http.HttpComponent"> <property name="camelContext" ref="camel"/> - <property name="httpConnectionManager" ref="myHttpConnectionManager"/> - </bean> - - <bean id="myHttpConnectionManager" class="org.apache.commons.httpclient.MultiThreadedHttpConnectionManager"> - <property name="params" ref="myHttpConnectionManagerParams"/> - </bean> - - <bean id="myHttpConnectionManagerParams" class="org.apache.commons.httpclient.params.HttpConnectionManagerParams"> - <property name="defaultMaxConnectionsPerHost" value="5"/> + <property name="connectionsPerRoute" value="5" /> </bean> <!-- END SNIPPET: e1 --> @@ -45,10 +38,9 @@ <camelContext id="camel" xmlns="http://camel.apache.org/schema/spring" trace="true"> <route> <from uri="direct:start"/> - <to uri="http://www.google.com"/> + <to uri="http://localhost:{{HttpTestServer.Port}}/"/> <to uri="mock:result"/> </route> </camelContext> <!-- END SNIPPET: e2 --> - -</beans> +</beans> \ No newline at end of file