buildbot success in on cxf-site-production
The Buildbot has detected a restored build on builder cxf-site-production while building . Full details are available at: https://ci.apache.org/builders/cxf-site-production/builds/32639 Buildbot URL: https://ci.apache.org/ Buildslave for this Build: bb-cms-slave Build Reason: The Nightly scheduler named 'cxf-site-production' triggered this build Build Source Stamp: [branch cxf/web] HEAD Blamelist: Build succeeded! Sincerely, -The Buildbot
[cxf-dosgi] 03/16: Remove leading whitespace
This is an automated email from the ASF dual-hosted git repository. amichai pushed a commit to branch master in repository https://gitbox.apache.org/repos/asf/cxf-dosgi.git commit 5c1e2c963efca73af157339532a68e08f44e7075 Author: Amichai Rothman AuthorDate: Tue May 28 14:49:53 2019 +0300 Remove leading whitespace --- buildtools/cxf-checkstyle-suppressions.xml | 6 +++--- buildtools/cxf-checkstyle.xml| 8 .../apache/cxf/dosgi/common/endpoint/ServerEndpoint.java | 2 +- .../apache/cxf/dosgi/common/intent/IntentManager.java| 2 +- .../cxf/dosgi/common/intent/impl/IntentManagerImpl.java | 16 .../apache/cxf/dosgi/common/proxy/ExceptionMapper.java | 6 +++--- .../dosgi/common/intent/impl/IntentManagerImplTest.java | 2 +- .../dosgi/common/proxy/ServiceInvocationHandlerTest.java | 4 ++-- .../cxf/dosgi/dsw/decorator/ServiceDecoratorImpl.java| 2 +- .../decorator/ServiceDecoratorBundleListenerTest.java| 2 +- .../dosgi/dsw/decorator/ServiceDecoratorImplTest.java| 2 +- distribution/features/src/main/resources/features.xml| 2 +- distribution/multi-bundle/pom.xml| 2 +- distribution/repository/pom.xml | 2 +- itests/multi-bundle/pom.xml | 12 ++-- .../apache/cxf/dosgi/itests/multi/AbstractDosgiTest.java | 14 +++--- .../apache/cxf/dosgi/itests/multi/TestCustomIntent.java | 2 +- .../apache/cxf/dosgi/itests/multi/TestExportPolicy.java | 4 ++-- .../apache/cxf/dosgi/itests/multi/TestExportService.java | 8 .../itests/multi/customintent/CustomIntentActivator.java | 2 +- parent/pom.xml | 6 +++--- pom.xml | 6 +++--- provider-rs/pom.xml | 4 ++-- .../apache/cxf/dosgi/dsw/handlers/rest/RsProvider.java | 8 .../dsw/handlers/rest/provider/RsProviderCustomTest.java | 2 +- .../cxf/dosgi/dsw/handlers/rest/provider/Task.java | 4 ++-- .../dosgi/dsw/handlers/rest/simple/RsProviderTest.java | 8 .../apache/cxf/dosgi/dsw/handlers/rest/simple/Task.java | 4 ++-- provider-ws/pom.xml | 2 +- .../org/apache/cxf/dosgi/dsw/handlers/ws/WsProvider.java | 12 ++-- .../apache/cxf/dosgi/dsw/handlers/ws/WsdlSupport.java| 2 +- release_notes.md | 4 ++-- samples/features/src/main/resources/features.xml | 6 +++--- samples/pom.xml | 2 +- samples/repository/pom.xml | 4 ++-- .../java/org/apache/cxf/dosgi/samples/rest/Task.java | 2 +- .../org/apache/cxf/dosgi/samples/rest/TaskResource.java | 2 +- .../dosgi/samples/rest/client/TaskResourceCommand.java | 4 ++-- .../cxf/dosgi/samples/rest/impl/JacksonIntent.java | 2 +- .../cxf/dosgi/samples/rest/impl/TaskResourceImpl.java| 2 +- .../cxf/dosgi/samples/rest/impl/TaskResourceImpl.java| 2 +- samples/soap/api/pom.xml | 2 +- .../java/org/apache/cxf/dosgi/samples/soap/Task.java | 2 +- .../org/apache/cxf/dosgi/samples/soap/TaskService.java | 2 +- samples/soap/client/pom.xml | 2 +- .../dosgi/samples/soap/client/TaskServiceCommand.java| 4 ++-- samples/soap/impl/pom.xml| 2 +- samples/soap/soap.bndrun | 2 +- samples/ssl/README.md| 4 ++-- samples/ssl/pom.xml | 2 +- 50 files changed, 105 insertions(+), 105 deletions(-) diff --git a/buildtools/cxf-checkstyle-suppressions.xml b/buildtools/cxf-checkstyle-suppressions.xml index b15b6ac..d27656f 100644 --- a/buildtools/cxf-checkstyle-suppressions.xml +++ b/buildtools/cxf-checkstyle-suppressions.xml @@ -10,9 +10,9 @@ 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 @@ -27,7 +27,7 @@ - + diff --git a/buildtools/cxf-checkstyle.xml b/buildtools/cxf-checkstyle.xml index 521192b..9d54896 100644 --- a/buildtools/cxf-checkstyle.xml +++ b/buildtools/cxf-checkstyle.xml @@ -7,9 +7,9 @@ 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
[cxf-dosgi] 01/16: Fix typo in bundle name
This is an automated email from the ASF dual-hosted git repository. amichai pushed a commit to branch master in repository https://gitbox.apache.org/repos/asf/cxf-dosgi.git commit 5a905be4528f80d42d867bf2f35a4df975efc4e4 Author: Amichai Rothman AuthorDate: Mon May 27 23:01:20 2019 +0300 Fix typo in bundle name --- itests/multi-bundle/pom.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/itests/multi-bundle/pom.xml b/itests/multi-bundle/pom.xml index 0b6aa6b..2a9d711 100644 --- a/itests/multi-bundle/pom.xml +++ b/itests/multi-bundle/pom.xml @@ -31,7 +31,7 @@ org.apache.cxf.dosgi.systests cxf-dosgi-itests-multibundle jar -CXF DOSGi Integration Tests Multi Bundle +CXF DOSGi Integration Tests Multi-Bundle ../..
[cxf-dosgi] 07/16: Fix typos
This is an automated email from the ASF dual-hosted git repository. amichai pushed a commit to branch master in repository https://gitbox.apache.org/repos/asf/cxf-dosgi.git commit ef22f0e7180bc158b7d7aa41e282047c825aeec7 Author: Amichai Rothman AuthorDate: Tue May 28 21:02:24 2019 +0300 Fix typos --- Readme.md | 2 +- distribution/Readme.md| 2 +- provider-ws/Readme.md | 2 +- .../java/org/apache/cxf/dosgi/dsw/handlers/ws/WsProvider.java | 2 +- release_notes.md | 8 .../org/apache/cxf/dosgi/samples/rest/impl/TaskResourceImpl.java | 2 +- samples/ssl/README.md | 2 +- 7 files changed, 10 insertions(+), 10 deletions(-) diff --git a/Readme.md b/Readme.md index 16ff485..22c95cd 100644 --- a/Readme.md +++ b/Readme.md @@ -18,7 +18,7 @@ CXF DOSGi allows to easily publish and consume SOAP and REST services without us Intents allow a service to leverage CXF extensions like features. A service can list the named intents it requires. It will then only be exported / imported once all the intents are available. This allows for example security restrictions or logging. -For more informations see [common module](common). +For more information see [common module](common). ## Build diff --git a/distribution/Readme.md b/distribution/Readme.md index 651bf9d..e0ce8f9 100644 --- a/distribution/Readme.md +++ b/distribution/Readme.md @@ -1,4 +1,4 @@ -# CXF DOSGi Distribtions +# CXF DOSGi Distributions ## Apache karaf features diff --git a/provider-ws/Readme.md b/provider-ws/Readme.md index 6632058..c6b7a8c 100644 --- a/provider-ws/Readme.md +++ b/provider-ws/Readme.md @@ -18,7 +18,7 @@ then JAX-WS mode is used else simple mode is used. ## Simple -This mode uses the CXF simple frontend and the Aegis Databinding. It can export almost any service but is not much configureable. Aegis is also not very popular anymore. So this +This mode uses the CXF simple frontend and the Aegis Databinding. It can export almost any service but is not much configurable. Aegis is also not very popular anymore. So this mode for exporting existing services and small tests. For most cases the JAX-WS mode is recommended. ## JAX-WS diff --git a/provider-ws/src/main/java/org/apache/cxf/dosgi/dsw/handlers/ws/WsProvider.java b/provider-ws/src/main/java/org/apache/cxf/dosgi/dsw/handlers/ws/WsProvider.java index 7584f02..6006fe8 100644 --- a/provider-ws/src/main/java/org/apache/cxf/dosgi/dsw/handlers/ws/WsProvider.java +++ b/provider-ws/src/main/java/org/apache/cxf/dosgi/dsw/handlers/ws/WsProvider.java @@ -191,7 +191,7 @@ public class WsProvider extends BaseDistributionProvider implements Distribution completeEndpointAddress, intentNames); return createServerFromFactory(factory, epd); } catch (Exception e) { -throw new RuntimeException("Error exporting service with adress " + completeEndpointAddress, e); +throw new RuntimeException("Error exporting service with address " + completeEndpointAddress, e); } } diff --git a/release_notes.md b/release_notes.md index 1c70343..23f7ec5 100644 --- a/release_notes.md +++ b/release_notes.md @@ -204,7 +204,7 @@ Release Notes - CXF Distributed OSGi - Version 1.5.0 * [DOSGI-69] - CXF-DOSGi requires internet access when reading XML * [DOSGI-90] - Do not use/assume that endpoint.id is an address * [DOSGI-92] - Exception : Applying intent: SOAP via binding config -* [DOSGI-109] - NullPointerException in ToloplogyManager during bundle +* [DOSGI-109] - NullPointerException in TopologyManager during bundle * stop * [DOSGI-110] - Unable to export multiple services * [DOSGI-111] - DOSGi bundle attempts to load WSDL using wrong bundle in @@ -280,7 +280,7 @@ Fixes needed in order to pass the OSGi 4.3 Remote Service Admin TCK. 1.3 === -The following modules have been removed from the destribution: +The following modules have been removed from the distribution: * org.apache.cxf.dosgi:cxf-dosgi-ri-discovery-distributed-zookeeper-wrapper @@ -288,7 +288,7 @@ The following modules have been removed from the destribution: * org.apache.cxf.dosgi:cxf-dosgi-remote-service-admin-interfaces - org.osgi:org.osgi.enterprize:4.2.0 artifact is now available. See DOSGI-104 for more information. + org.osgi:org.osgi.enterprise:4.2.0 artifact is now available. See DOSGI-104 for more information. Many dependencies have been updated, including the update to CXF 2.5.1. See also DOSGI-96. @@ -365,7 +365,7 @@ Additionally, a number of bugs has been fixed including: * [DOSGI-43] - ClassCastException with Declarative Services * [DOSGI-44] - Existing OSGi Services are not remoted when
[cxf-dosgi] 11/16: Add missing @Override annotations
This is an automated email from the ASF dual-hosted git repository. amichai pushed a commit to branch master in repository https://gitbox.apache.org/repos/asf/cxf-dosgi.git commit 153eef0e679236a42f95e5d8e52c06aedbf1cb25 Author: Amichai Rothman AuthorDate: Tue May 28 22:06:41 2019 +0300 Add missing @Override annotations --- .../cxf/dosgi/common/httpservice/HttpServiceManager.java | 1 + .../common/httpservice/SecurityDelegatingHttpContext.java | 4 .../apache/cxf/dosgi/common/intent/impl/IntentManagerImpl.java | 6 ++ .../cxf/dosgi/common/proxy/ServiceInvocationHandler.java | 2 ++ .../cxf/dosgi/common/httpservice/HttpServiceManagerTest.java | 4 .../common/httpservice/SecurityDelegatingHttpContextTest.java | 10 ++ .../cxf/dosgi/common/proxy/ServiceInvocationHandlerTest.java | 3 +++ .../java/org/apache/cxf/dosgi/dsw/decorator/Activator.java | 2 ++ .../java/org/apache/cxf/dosgi/dsw/decorator/InterfaceRule.java | 2 ++ .../dosgi/dsw/decorator/ServiceDecoratorBundleListener.java| 3 ++- .../apache/cxf/dosgi/dsw/decorator/ServiceDecoratorImpl.java | 1 + .../org/apache/cxf/dosgi/dsw/decorator/InterfaceRuleTest.java | 1 + .../cxf/dosgi/dsw/decorator/ServiceDecoratorImplTest.java | 2 ++ .../org/apache/cxf/dosgi/itests/multi/TestCustomIntent.java| 1 + .../org/apache/cxf/dosgi/itests/multi/TestExportService.java | 2 ++ .../itests/multi/customintent/ChangeTitleInterceptor.java | 1 + .../dosgi/itests/multi/customintent/CustomIntentActivator.java | 2 ++ .../org/apache/cxf/dosgi/dsw/handlers/rest/RsProvider.java | 3 +++ .../java/org/apache/cxf/dosgi/dsw/handlers/ws/WsProvider.java | 3 +++ .../dsw/handlers/ws/PojoConfigurationTypeHandlerTest.java | 3 +++ .../cxf/dosgi/samples/security/SampleSecurityFilter.java | 3 +++ 21 files changed, 58 insertions(+), 1 deletion(-) diff --git a/common/src/main/java/org/apache/cxf/dosgi/common/httpservice/HttpServiceManager.java b/common/src/main/java/org/apache/cxf/dosgi/common/httpservice/HttpServiceManager.java index 5aab6be..188 100644 --- a/common/src/main/java/org/apache/cxf/dosgi/common/httpservice/HttpServiceManager.java +++ b/common/src/main/java/org/apache/cxf/dosgi/common/httpservice/HttpServiceManager.java @@ -143,6 +143,7 @@ public class HttpServiceManager { private final class UnregisterListener implements ServiceListener { +@Override public void serviceChanged(ServiceEvent event) { if (!(event.getType() == ServiceEvent.UNREGISTERING)) { return; diff --git a/common/src/main/java/org/apache/cxf/dosgi/common/httpservice/SecurityDelegatingHttpContext.java b/common/src/main/java/org/apache/cxf/dosgi/common/httpservice/SecurityDelegatingHttpContext.java index 4eba758..53d727f 100644 --- a/common/src/main/java/org/apache/cxf/dosgi/common/httpservice/SecurityDelegatingHttpContext.java +++ b/common/src/main/java/org/apache/cxf/dosgi/common/httpservice/SecurityDelegatingHttpContext.java @@ -64,14 +64,17 @@ class SecurityDelegatingHttpContext implements HttpContext { requireFilter = Boolean.TRUE.toString().equalsIgnoreCase(bundleContext.getProperty(FILTER_REQUIRED_PROP)); } +@Override public String getMimeType(String name) { return delegate.getMimeType(name); } +@Override public URL getResource(String name) { return delegate.getResource(name); } +@Override @SuppressWarnings({ "unchecked", "rawtypes" }) @@ -123,6 +126,7 @@ class Chain implements FilterChain { this.filters = filters; } +@Override public void doFilter(ServletRequest request, ServletResponse response) throws IOException, ServletException { if (current < filters.length && !response.isCommitted()) { Filter filter = filters[current++]; diff --git a/common/src/main/java/org/apache/cxf/dosgi/common/intent/impl/IntentManagerImpl.java b/common/src/main/java/org/apache/cxf/dosgi/common/intent/impl/IntentManagerImpl.java index 779b76e..1cf26cf 100644 --- a/common/src/main/java/org/apache/cxf/dosgi/common/intent/impl/IntentManagerImpl.java +++ b/common/src/main/java/org/apache/cxf/dosgi/common/intent/impl/IntentManagerImpl.java @@ -96,6 +96,7 @@ public class IntentManagerImpl implements IntentManager { intentMap.remove(intentName); } +@Override @SuppressWarnings("unchecked") public synchronized List getRequiredIntents(Set requiredIntents) { String[] intentNames = assertAllIntentsSupported(requiredIntents); @@ -124,6 +125,7 @@ public class IntentManagerImpl implements IntentManager { return intents; } +@Override public T getIntent(Class type, List intents) { List selectedIntents = getIntents(type, intents); if (selectedIntents.isEmpty()) { @@ -135,6 +137,7 @@ public class IntentManagerImpl implements
[cxf-dosgi] 04/16: Add explicit block quotes in readme
This is an automated email from the ASF dual-hosted git repository. amichai pushed a commit to branch master in repository https://gitbox.apache.org/repos/asf/cxf-dosgi.git commit d0b87315a1876f80205320496dfe519268ddaeb5 Author: Amichai Rothman AuthorDate: Tue May 28 15:21:47 2019 +0300 Add explicit block quotes in readme --- samples/ssl/README.md | 35 ++- 1 file changed, 18 insertions(+), 17 deletions(-) diff --git a/samples/ssl/README.md b/samples/ssl/README.md index ac53836..056c2df 100644 --- a/samples/ssl/README.md +++ b/samples/ssl/README.md @@ -15,21 +15,20 @@ We want the karaf HttpService to be secured by https and require a client certif * Create client and server keys. * Add client certificate to server - - mkdir -p etc/keystores - # Create server key - keytool -genkey -dname CN=localhost -keyalg RSA -validity 10 -alias serverkey -keypass password -storepass password -keystore etc/keystores/keystore.jks - # Create client key and add to keystore as trusted - keytool -genkey -dname CN=chris -keyalg RSA -validity 10 -alias clientkey -keypass password -storepass password -keystore etc/keystores/client.jks - keytool -export -rfc -keystore etc/keystores/client.jks -storepass password -alias clientkey -file client.cer - keytool -import -trustcacerts -keystore etc/keystores/keystore.jks -storepass password -alias clientkey -file client.cer - - - # Export server cert - keytool -exportcert -storepass password -keystore etc/keystores/keystore.jks -alias serverKey -file server.cert - # Import server cert into client store - keytool -importcert -storepass password -keystore etc/keystores/client.jks -alias serverKey -file server.cert - +``` +mkdir -p etc/keystores +# Create server key +keytool -genkey -dname CN=localhost -keyalg RSA -validity 10 -alias serverkey -keypass password -storepass password -keystore etc/keystores/keystore.jks +# Create client key and add to keystore as trusted +keytool -genkey -dname CN=chris -keyalg RSA -validity 10 -alias clientkey -keypass password -storepass password -keystore etc/keystores/client.jks +keytool -export -rfc -keystore etc/keystores/client.jks -storepass password -alias clientkey -file client.cer +keytool -import -trustcacerts -keystore etc/keystores/keystore.jks -storepass password -alias clientkey -file client.cer + +# Export server cert +keytool -exportcert -storepass password -keystore etc/keystores/keystore.jks -alias serverKey -file server.cert +# Import server cert into client store +keytool -importcert -storepass password -keystore etc/keystores/client.jks -alias serverKey -file server.cert +``` - Copy thes files in etc to the karaf etc dir - Copy the keystores (*.jks) into the karaf etc directory. @@ -50,8 +49,10 @@ install -s mvn:org.apache.cxf.dosgi.samples/cxf-dosgi-samples-ssl-intent/2.0.0 If you want to access the service using your browser then you have to export it in pkcs12 format and import it into your browser. - # Export client cert as pkcs12 for browser - keytool -importkeystore -srckeystore etc/keystores/client.jks -destkeystore etc/keystores/client.p12 -deststoretype PKCS12 +``` +# Export client cert as pkcs12 for browser +keytool -importkeystore -srckeystore etc/keystores/client.jks -destkeystore etc/keystores/client.p12 -deststoretype PKCS12 +``` Access the service as [](https://localhost:8443/cxf/echo "echo service"). Add a security exemption to accept the server certificate.
[cxf-dosgi] 10/16: Fix skipped tests
This is an automated email from the ASF dual-hosted git repository. amichai pushed a commit to branch master in repository https://gitbox.apache.org/repos/asf/cxf-dosgi.git commit 7cc135df4c8e4f120c22d3475eaeff71e03fd410 Author: Amichai Rothman AuthorDate: Tue May 28 22:01:13 2019 +0300 Fix skipped tests --- .../common/proxy/ServiceInvocationHandlerTest.java | 1 + .../ws/PojoConfigurationTypeHandlerTest.java | 22 ++ 2 files changed, 15 insertions(+), 8 deletions(-) diff --git a/common/src/test/java/org/apache/cxf/dosgi/common/proxy/ServiceInvocationHandlerTest.java b/common/src/test/java/org/apache/cxf/dosgi/common/proxy/ServiceInvocationHandlerTest.java index 5b60075..bd1b38e 100644 --- a/common/src/test/java/org/apache/cxf/dosgi/common/proxy/ServiceInvocationHandlerTest.java +++ b/common/src/test/java/org/apache/cxf/dosgi/common/proxy/ServiceInvocationHandlerTest.java @@ -46,6 +46,7 @@ public class ServiceInvocationHandlerTest { assertEquals(5, sih.invoke(null, m, new Object[] {})); } +@Test public void testInvokeObjectMethod() throws Throwable { final List called = new ArrayList(); ServiceInvocationHandler sih = new ServiceInvocationHandler("hi", String.class) { diff --git a/provider-ws/src/test/java/org/apache/cxf/dosgi/dsw/handlers/ws/PojoConfigurationTypeHandlerTest.java b/provider-ws/src/test/java/org/apache/cxf/dosgi/dsw/handlers/ws/PojoConfigurationTypeHandlerTest.java index f234014..0f3db95 100644 --- a/provider-ws/src/test/java/org/apache/cxf/dosgi/dsw/handlers/ws/PojoConfigurationTypeHandlerTest.java +++ b/provider-ws/src/test/java/org/apache/cxf/dosgi/dsw/handlers/ws/PojoConfigurationTypeHandlerTest.java @@ -230,12 +230,11 @@ public class PojoConfigurationTypeHandlerTest extends TestCase { (String[])props.get(org.osgi.framework.Constants.OBJECTCLASS)); } -public void t2estCreateServerException() { +public void testCreateServerException() { BundleContext dswContext = EasyMock.createNiceMock(BundleContext.class); EasyMock.replay(dswContext); -IntentManager intentManager = EasyMock.createNiceMock(IntentManager.class); -EasyMock.replay(intentManager); +IntentManager intentManager = new IntentManagerImpl(); WsProvider handler = new WsProvider() { @Override @@ -247,15 +246,21 @@ public class PojoConfigurationTypeHandlerTest extends TestCase { handler.setHttpServiceManager(dummyHttpServiceManager()); handler.activate(dswContext); +Class[] exportedInterfaces = {Runnable.class}; Map props = new HashMap(); +EndpointHelper.addObjectClass(props, exportedInterfaces); Runnable myService = EasyMock.createMock(Runnable.class); EasyMock.replay(myService); try { -handler.exportService(myService, null, props, new Class[] {Runnable.class}); +handler.exportService(myService, null, props, exportedInterfaces); fail("Expected TestException"); } catch (TestException e) { // Expected +} catch (RuntimeException re) { +if (!(re.getCause() instanceof TestException)) { +fail("Expected TestException"); +} } } @@ -337,7 +342,7 @@ public class PojoConfigurationTypeHandlerTest extends TestCase { assertEquals(new Version("0.0.0"), epd.getPackageVersion("java.lang")); } -public void t2estCreateJaxWsEndpointWithoutIntents() { +public void testCreateJaxWsEndpointWithoutIntents() { IMocksControl c = EasyMock.createNiceControl(); BundleContext dswBC = c.createMock(BundleContext.class); @@ -347,15 +352,16 @@ public class PojoConfigurationTypeHandlerTest extends TestCase { handler.setHttpServiceManager(dummyHttpServiceManager()); handler.activate(dswBC); +Class[] exportedInterfaces = new Class[] {MyJaxWsEchoService.class}; Map sd = new HashMap(); sd.put(WsConstants.WS_ADDRESS_PROPERTY, "/somewhere"); +EndpointHelper.addObjectClass(sd, exportedInterfaces); BundleContext serviceBC = c.createMock(BundleContext.class); -Object myService = null; +Object myService = c.createMock(MyJaxWsEchoService.class); c.replay(); -Class[] ifaces = new Class[] {MyJaxWsEchoService.class}; ServerEndpoint serverWrapper = (ServerEndpoint)handler.exportService(myService, serviceBC, sd, - ifaces); +exportedInterfaces); c.verify(); org.apache.cxf.endpoint.Endpoint ep = serverWrapper.getServer().getEndpoint();
[cxf-dosgi] 06/16: Simplify MultiBundleTools
This is an automated email from the ASF dual-hosted git repository. amichai pushed a commit to branch master in repository https://gitbox.apache.org/repos/asf/cxf-dosgi.git commit 84309c10cd1e9a1afc2f33f906614e0bae83bbc0 Author: Amichai Rothman AuthorDate: Tue May 28 15:39:44 2019 +0300 Simplify MultiBundleTools --- .../cxf/dosgi/itests/multi/MultiBundleTools.java | 46 +- 1 file changed, 18 insertions(+), 28 deletions(-) diff --git a/itests/multi-bundle/src/test/java/org/apache/cxf/dosgi/itests/multi/MultiBundleTools.java b/itests/multi-bundle/src/test/java/org/apache/cxf/dosgi/itests/multi/MultiBundleTools.java index e3d96ba..3603aea 100644 --- a/itests/multi-bundle/src/test/java/org/apache/cxf/dosgi/itests/multi/MultiBundleTools.java +++ b/itests/multi-bundle/src/test/java/org/apache/cxf/dosgi/itests/multi/MultiBundleTools.java @@ -19,7 +19,6 @@ package org.apache.cxf.dosgi.itests.multi; import java.io.File; -import java.io.FilenameFilter; import java.net.URL; import java.util.ArrayList; import java.util.Collection; @@ -36,42 +35,33 @@ public final class MultiBundleTools { private static Collection getDistroBundles(File distroDir) { List bundles = new ArrayList<>(); File bundlesDir = new File(distroDir, "bundle"); -File[] files = bundlesDir.listFiles(new FilenameFilter() { -public boolean accept(File dir, String name) { -return name.toLowerCase().endsWith(".jar"); -} +for (File file : bundlesDir.listFiles()) { +if (file.getName().toLowerCase().endsWith(".jar")) { +bundles.add(file.toURI().toASCIIString()); } -); -for (File file : files) { -bundles.add(file.toURI().toASCIIString()); } return bundles; } private static File getRootDirectory() { -String resourceName = "/" + MultiBundleTools.class.getName().replace('.', '/') + ".class"; -URL curURL = MultiBundleTools.class.getResource(resourceName); -File curFile = new File(curURL.getFile()); -String curString = curFile.getAbsolutePath(); -File curBase = new File(curString.substring(0, curString.length() - resourceName.length())); -return curBase.getParentFile().getParentFile(); +URL url = MultiBundleTools.class.getResource("/"); // get ${root}/target/test-classes +File dir = new File(url.getFile()).getAbsoluteFile(); +return dir.getParentFile().getParentFile(); } public static Option getDistro() { -File root = getRootDirectory(); -File depRoot = new File(root, "target/dependency"); -File distroDir = depRoot.listFiles()[0]; -Collection bundles = getDistroBundles(distroDir); -List opts = new ArrayList(); -// Make sure annotation bundle is loaded first to make sure it is used for resolution -for (String bundleUri : bundles) { -if (bundleUri.contains("javax.annotation")) { -opts.add(CoreOptions.bundle(bundleUri)); -} -} -for (String bundleUri : bundles) { -if (!bundleUri.contains("javax.annotation")) { -opts.add(CoreOptions.bundle(bundleUri)); +File rootDir = getRootDirectory(); +File depsDir = new File(rootDir, "target/dependency"); +File distroDir = depsDir.listFiles()[0]; +Collection bundleUris = getDistroBundles(distroDir); +List opts = new ArrayList<>(); +for (String uri : bundleUris) { +Option opt = CoreOptions.bundle(uri); +// Make sure annotation bundle is loaded first to make sure it is used for resolution +if (uri.contains("javax.annotation")) { +opts.add(0, opt); +} else { +opts.add(opt); } } return CoreOptions.composite(opts.toArray(new Option[opts.size()]));
[cxf-dosgi] 09/16: Simplify array initialization
This is an automated email from the ASF dual-hosted git repository. amichai pushed a commit to branch master in repository https://gitbox.apache.org/repos/asf/cxf-dosgi.git commit 6818159ff1002cd9a6d5a3b1b0420f277cac53c8 Author: Amichai Rothman AuthorDate: Tue May 28 21:10:09 2019 +0300 Simplify array initialization --- .../httpservice/SecurityDelegatingHttpContextTest.java | 14 -- 1 file changed, 4 insertions(+), 10 deletions(-) diff --git a/common/src/test/java/org/apache/cxf/dosgi/common/httpservice/SecurityDelegatingHttpContextTest.java b/common/src/test/java/org/apache/cxf/dosgi/common/httpservice/SecurityDelegatingHttpContextTest.java index 8b36548..84a3545 100644 --- a/common/src/test/java/org/apache/cxf/dosgi/common/httpservice/SecurityDelegatingHttpContextTest.java +++ b/common/src/test/java/org/apache/cxf/dosgi/common/httpservice/SecurityDelegatingHttpContextTest.java @@ -68,7 +68,7 @@ public class SecurityDelegatingHttpContextTest extends TestCase { public void testFilterRequired() throws Exception { // Mock up the service references -ServiceReference[] serviceReferences = new ServiceReference[] {}; +ServiceReference[] serviceReferences = {}; // Mock up the bundle context BundleContext bundleContext = EasyMock.createNiceMock(BundleContext.class); @@ -100,9 +100,7 @@ public class SecurityDelegatingHttpContextTest extends TestCase { // Mock up the service references ServiceReference filterReference = EasyMock.createNiceMock(ServiceReference.class); EasyMock.replay(filterReference); -ServiceReference[] serviceReferences = new ServiceReference[] { -filterReference -}; +ServiceReference[] serviceReferences = {filterReference}; // Mock up the bundle context BundleContext bundleContext = EasyMock.createNiceMock(BundleContext.class); @@ -136,9 +134,7 @@ public class SecurityDelegatingHttpContextTest extends TestCase { // Mock up the service references ServiceReference filterReference = EasyMock.createNiceMock(ServiceReference.class); EasyMock.replay(filterReference); -ServiceReference[] serviceReferences = new ServiceReference[] { -filterReference, filterReference -}; +ServiceReference[] serviceReferences = {filterReference, filterReference}; // Mock up the bundle context BundleContext bundleContext = EasyMock.createNiceMock(BundleContext.class); @@ -173,9 +169,7 @@ public class SecurityDelegatingHttpContextTest extends TestCase { // Mock up the service references ServiceReference filterReference = EasyMock.createNiceMock(ServiceReference.class); EasyMock.replay(filterReference); -ServiceReference[] serviceReferences = new ServiceReference[] { -filterReference -}; +ServiceReference[] serviceReferences = {filterReference}; // Mock up the bundle context BundleContext bundleContext = EasyMock.createNiceMock(BundleContext.class);
[cxf-dosgi] 02/16: Remove extra blank lines
This is an automated email from the ASF dual-hosted git repository. amichai pushed a commit to branch master in repository https://gitbox.apache.org/repos/asf/cxf-dosgi.git commit 230db05ea227923f70f32faab341a63aa27afb24 Author: Amichai Rothman AuthorDate: Tue May 28 14:28:49 2019 +0300 Remove extra blank lines --- NOTICE| 1 - buildtools/cxf-checkstyle-suppressions.xml| 2 +- buildtools/cxf-checkstyle.xml | 11 --- buildtools/notice-supplements.xml | 1 - common/bnd.bnd| 1 - .../cxf/dosgi/common/proxy/ServiceInvocationHandler.java | 1 - .../test/java/org/apache/cxf/dosgi/common/util/Provider.java | 1 - itests/multi-bundle/pom.xml | 1 - .../org/apache/cxf/dosgi/itests/multi/AbstractDosgiTest.java | 5 - .../org/apache/cxf/dosgi/itests/multi/TestExportPolicy.java | 1 - .../org/apache/cxf/dosgi/itests/multi/TestExportService.java | 1 - itests/multi-bundle/src/test/resources/rs-test1.xml | 1 - pom.xml | 1 - .../dsw/handlers/rest/provider/RsProviderCustomTest.java | 1 - provider-ws/Readme.md | 1 - .../dsw/handlers/ws/PojoConfigurationTypeHandlerTest.java | 1 - release_notes.md | 6 +- samples/Readme.md | 1 - samples/repository/pom.xml| 1 - .../org/apache/cxf/dosgi/samples/rest/impl/JacksonIntent.java | 1 - samples/soap/soap.bndrun | 2 +- samples/ssl/etc/org.ops4j.pax.web.cfg | 1 - .../main/java/org/apache/cxf/dosgi/samples/ssl/SslIntent.java | 2 -- 23 files changed, 7 insertions(+), 38 deletions(-) diff --git a/NOTICE b/NOTICE index 51527cd..eb55f8e 100644 --- a/NOTICE +++ b/NOTICE @@ -6,4 +6,3 @@ This product includes software developed at The Apache Software Foundation (http://www.apache.org/). This product contains interfaces and specifications Copyright The OSGi Alliance. - diff --git a/buildtools/cxf-checkstyle-suppressions.xml b/buildtools/cxf-checkstyle-suppressions.xml index 60c70ab..b15b6ac 100644 --- a/buildtools/cxf-checkstyle-suppressions.xml +++ b/buildtools/cxf-checkstyle-suppressions.xml @@ -35,4 +35,4 @@ - \ No newline at end of file + diff --git a/buildtools/cxf-checkstyle.xml b/buildtools/cxf-checkstyle.xml index 87dd736..521192b 100644 --- a/buildtools/cxf-checkstyle.xml +++ b/buildtools/cxf-checkstyle.xml @@ -58,7 +58,6 @@ --> - @@ -71,7 +70,6 @@ - @@ -87,7 +85,6 @@ --> - @@ -129,13 +126,11 @@ value="ASSIGN, BAND, BAND_ASSIGN, BOR, BOR_ASSIGN, BSR, BSR_ASSIGN, BXOR, BXOR_ASSIGN, COLON, DIV, DIV_ASSIGN, EQUAL, GE, GT, LAND, LCURLY, LE, LITERAL_ASSERT, LITERAL_CATCH, LITERAL_DO, LITERAL_ELSE, LITERAL_FINALLY, LITERAL_FOR, LITERAL_IF, LITERAL_RETURN, LITERAL_SYNCHRONIZED, LITERAL_TRY, LITERAL_WHILE, LOR, LT, MINUS, MINUS_ASSIGN, MOD, MOD_ASSIGN, NOT_EQUAL, PLUS, PLUS_ASSIGN, QUESTION, RCURLY, SL, SLIST, SL_ASSIGN, SR, SR_ASSIGN, STAR, STAR_ASSIGN,TYPE_EXTENSION_AND" /> - - @@ -148,7 +143,6 @@ - @@ -203,8 +197,6 @@ - - @@ -224,8 +216,6 @@ - - @@ -239,7 +229,6 @@ - diff --git a/itests/multi-bundle/src/test/java/org/apache/cxf/dosgi/itests/multi/AbstractDosgiTest.java b/itests/multi-bundle/src/test/java/org/apache/cxf/dosgi/itests/multi/AbstractDosgiTest.java index 9be797e..673a2f6 100644 --- a/itests/multi-bundle/src/test/java/org/apache/cxf/dosgi/itests/multi/AbstractDosgiTest.java +++ b/itests/multi-bundle/src/test/java/org/apache/cxf/dosgi/itests/multi/AbstractDosgiTest.java @@ -97,7 +97,6 @@ public class AbstractDosgiTest { } throw ex; } - /** * Sleeps for a short interval, throwing an exception if timeout has been reached. Used to facilitate a @@ -261,7 +260,6 @@ public class AbstractDosgiTest { protected static Option configLogging() {
[cxf-dosgi] branch master updated (966be4c -> b3a3ee4)
This is an automated email from the ASF dual-hosted git repository. amichai pushed a change to branch master in repository https://gitbox.apache.org/repos/asf/cxf-dosgi.git. from 966be4c Merge pull request #5 from amichair/DOSGI-280 new 5a905be Fix typo in bundle name new 230db05 Remove extra blank lines new 5c1e2c9 Remove leading whitespace new d0b8731 Add explicit block quotes in readme new 5c9c12a Remove redundant throws clause new 84309c1 Simplify MultiBundleTools new ef22f0e Fix typos new 77448df Delete unused empty test class new 6818159 Simplify array initialization new 7cc135d Fix skipped tests new 153eef0 Add missing @Override annotations new 97564d0 Migrate to diamond operator new 68591a2 Tiny simplifications new 47133d4 Fix mixed indentation styles new 344ab76 Upgrade tests to junit 4 new b3a3ee4 Remove trailing whitespace The 16 revisions listed above as "new" are entirely new to this repository and will be described in separate emails. The revisions listed as "add" were already present in the repository and have only been added to this reference. Summary of changes: NOTICE | 1 - Readme.md | 6 +- buildtools/cxf-checkstyle-suppressions.xml | 8 +- buildtools/cxf-checkstyle.xml | 89 ++-- buildtools/notice-supplements.xml | 1 - common/Readme.md | 2 +- common/bnd.bnd | 1 - .../cxf/dosgi/common/endpoint/ServerEndpoint.java | 6 +- .../common/httpservice/HttpServiceManager.java | 3 +- .../httpservice/SecurityDelegatingHttpContext.java | 4 + .../cxf/dosgi/common/intent/IntentManager.java | 2 +- .../common/intent/impl/IntentManagerImpl.java | 42 +- .../cxf/dosgi/common/proxy/ExceptionMapper.java| 12 +- .../common/proxy/ServiceInvocationHandler.java | 3 +- .../common/httpservice/HttpServiceManagerTest.java | 20 +- .../SecurityDelegatingHttpContextTest.java | 83 ++-- .../common/intent/impl/IntentManagerImplTest.java | 2 +- .../common/proxy/ServiceInvocationHandlerTest.java | 16 +- .../cxf/dosgi/common/util/PropertyHelperTest.java | 24 +- .../org/apache/cxf/dosgi/common/util/Provider.java | 23 - .../apache/cxf/dosgi/dsw/decorator/Activator.java | 6 +- .../cxf/dosgi/dsw/decorator/DecorationParser.java | 2 +- .../cxf/dosgi/dsw/decorator/InterfaceRule.java | 8 +- .../decorator/ServiceDecoratorBundleListener.java | 5 +- .../dosgi/dsw/decorator/ServiceDecoratorImpl.java | 7 +- .../cxf/dosgi/dsw/decorator/InterfaceRuleTest.java | 52 +- .../ServiceDecoratorBundleListenerTest.java| 4 +- .../dsw/decorator/ServiceDecoratorImplTest.java| 66 +-- distribution/Readme.md | 8 +- .../features/src/main/resources/features.xml | 2 +- distribution/multi-bundle/pom.xml | 530 ++--- .../multi-bundle/src/main/assembly/assembly.xml| 118 ++--- distribution/repository/pom.xml| 4 +- itests/multi-bundle/pom.xml| 43 +- .../cxf/dosgi/itests/multi/AbstractDosgiTest.java | 21 +- .../cxf/dosgi/itests/multi/MultiBundleTools.java | 50 +- .../cxf/dosgi/itests/multi/TestCustomIntent.java | 7 +- .../cxf/dosgi/itests/multi/TestExportPolicy.java | 9 +- .../cxf/dosgi/itests/multi/TestExportService.java | 17 +- .../cxf/dosgi/itests/multi/TestImportService.java | 4 +- .../multi/customintent/ChangeTitleInterceptor.java | 3 +- .../multi/customintent/CustomIntentActivator.java | 12 +- .../multi-bundle/src/test/resources/rs-test1.xml | 1 - parent/pom.xml | 20 +- pom.xml| 7 +- provider-rs/pom.xml| 20 +- .../cxf/dosgi/dsw/handlers/rest/RsProvider.java| 21 +- .../rest/provider/RsProviderCustomTest.java| 5 +- .../cxf/dosgi/dsw/handlers/rest/provider/Task.java | 4 +- .../dsw/handlers/rest/simple/RsProviderTest.java | 10 +- .../cxf/dosgi/dsw/handlers/rest/simple/Task.java | 4 +- provider-ws/Readme.md | 3 +- provider-ws/pom.xml| 2 +- .../cxf/dosgi/dsw/handlers/ws/WsProvider.java | 21 +- .../cxf/dosgi/dsw/handlers/ws/WsdlSupport.java | 6 +- .../ws/PojoConfigurationTypeHandlerTest.java | 103 ++-- release_notes.md | 34 +- samples/Readme.md | 7 +- samples/features/src/main/resources/features.xml | 6 +- samples/pom.xml| 2 +- samples/repository/pom.xml | 5 +- samples/rest/README.md
[cxf-dosgi] 12/16: Migrate to diamond operator
This is an automated email from the ASF dual-hosted git repository. amichai pushed a commit to branch master in repository https://gitbox.apache.org/repos/asf/cxf-dosgi.git commit 97564d0a37d87210e6582e393e2cb3c5f86480cf Author: Amichai Rothman AuthorDate: Tue May 28 22:11:30 2019 +0300 Migrate to diamond operator --- .../common/httpservice/HttpServiceManager.java | 2 +- .../common/intent/impl/IntentManagerImpl.java | 14 - .../cxf/dosgi/common/proxy/ExceptionMapper.java| 4 +-- .../common/proxy/ServiceInvocationHandlerTest.java | 4 +-- .../cxf/dosgi/common/util/PropertyHelperTest.java | 4 +-- .../cxf/dosgi/dsw/decorator/DecorationParser.java | 2 +- .../cxf/dosgi/dsw/decorator/InterfaceRule.java | 4 +-- .../dosgi/dsw/decorator/ServiceDecoratorImpl.java | 4 +-- .../cxf/dosgi/dsw/decorator/InterfaceRuleTest.java | 32 +-- .../ServiceDecoratorBundleListenerTest.java| 2 +- .../dsw/decorator/ServiceDecoratorImplTest.java| 36 +++--- .../multi/customintent/CustomIntentActivator.java | 4 +-- .../cxf/dosgi/dsw/handlers/rest/RsProvider.java| 2 +- .../ws/PojoConfigurationTypeHandlerTest.java | 24 +++ .../dosgi/samples/rest/impl/TaskResourceImpl.java | 2 +- .../dosgi/samples/rest/impl/TaskResourceImpl.java | 2 +- .../dosgi/samples/soap/impl/TaskServiceImpl.java | 4 +-- 17 files changed, 73 insertions(+), 73 deletions(-) diff --git a/common/src/main/java/org/apache/cxf/dosgi/common/httpservice/HttpServiceManager.java b/common/src/main/java/org/apache/cxf/dosgi/common/httpservice/HttpServiceManager.java index 188..45f9723 100644 --- a/common/src/main/java/org/apache/cxf/dosgi/common/httpservice/HttpServiceManager.java +++ b/common/src/main/java/org/apache/cxf/dosgi/common/httpservice/HttpServiceManager.java @@ -74,7 +74,7 @@ public class HttpServiceManager { public void initFromConfig(Dictionary config) { if (config == null) { -config = new Hashtable(); +config = new Hashtable<>(); } this.httpBase = getWithDefault(config.get(KEY_HTTP_BASE), "http://localhost:8181;); this.cxfServletAlias = getWithDefault(config.get(KEY_CXF_SERVLET_ALIAS), "/cxf"); diff --git a/common/src/main/java/org/apache/cxf/dosgi/common/intent/impl/IntentManagerImpl.java b/common/src/main/java/org/apache/cxf/dosgi/common/intent/impl/IntentManagerImpl.java index 1cf26cf..b9b4525 100644 --- a/common/src/main/java/org/apache/cxf/dosgi/common/intent/impl/IntentManagerImpl.java +++ b/common/src/main/java/org/apache/cxf/dosgi/common/intent/impl/IntentManagerImpl.java @@ -51,7 +51,7 @@ public class IntentManagerImpl implements IntentManager { static final Logger LOG = LoggerFactory.getLogger(IntentManagerImpl.class); private static final int DEFAULT_INTENT_TIMEOUT = 3; -private final Map intentMap = new HashMap(); +private final Map intentMap = new HashMap<>(); private final long maxIntentWaitTime = DEFAULT_INTENT_TIMEOUT; private ServiceTracker tracker; @@ -100,7 +100,7 @@ public class IntentManagerImpl implements IntentManager { @SuppressWarnings("unchecked") public synchronized List getRequiredIntents(Set requiredIntents) { String[] intentNames = assertAllIntentsSupported(requiredIntents); -List intents = new ArrayList(); +List intents = new ArrayList<>(); for (String intentName : intentNames) { Object intent = intentMap.get(intentName); if (intent instanceof Callable) { @@ -139,7 +139,7 @@ public class IntentManagerImpl implements IntentManager { @Override public List getIntents(Class type, List intents) { -List result = new ArrayList(); +List result = new ArrayList<>(); for (Object intent : intents) { if (type.isInstance(intent)) { result.add(type.cast(intent)); @@ -182,7 +182,7 @@ public class IntentManagerImpl implements IntentManager { } private synchronized Set getMissingIntents(Collection requiredIntents) { -Set unsupportedIntents = new HashSet(); +Set unsupportedIntents = new HashSet<>(); unsupportedIntents.clear(); for (String ri : requiredIntents) { if (!intentMap.containsKey(ri)) { @@ -194,7 +194,7 @@ public class IntentManagerImpl implements IntentManager { @Override public Set getExported(Map sd) { -Set allIntents = new HashSet(); +Set allIntents = new HashSet<>(); Collection intents = PropertyHelper .getMultiValueProperty(sd.get(RemoteConstants.SERVICE_EXPORTED_INTENTS)); allIntents.addAll(parseIntents(intents)); @@ -226,11 +226,11 @@ public class IntentManagerImpl implements IntentManager { @Override public Set getImported(Map sd) { Collection intents =
[cxf-dosgi] 08/16: Delete unused empty test class
This is an automated email from the ASF dual-hosted git repository. amichai pushed a commit to branch master in repository https://gitbox.apache.org/repos/asf/cxf-dosgi.git commit 77448df0a25ce753871c4e7dcaf28b06b8601181 Author: Amichai Rothman AuthorDate: Tue May 28 21:04:25 2019 +0300 Delete unused empty test class --- .../org/apache/cxf/dosgi/common/util/Provider.java | 22 -- 1 file changed, 22 deletions(-) diff --git a/common/src/test/java/org/apache/cxf/dosgi/common/util/Provider.java b/common/src/test/java/org/apache/cxf/dosgi/common/util/Provider.java deleted file mode 100644 index 009c4a1..000 --- a/common/src/test/java/org/apache/cxf/dosgi/common/util/Provider.java +++ /dev/null @@ -1,22 +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.cxf.dosgi.common.util; - -public class Provider { -}
[cxf-dosgi] 16/16: Remove trailing whitespace
This is an automated email from the ASF dual-hosted git repository. amichai pushed a commit to branch master in repository https://gitbox.apache.org/repos/asf/cxf-dosgi.git commit b3a3ee467a2c94c1f81bcdfc5f99cff315878921 Author: Amichai Rothman AuthorDate: Wed May 29 00:17:18 2019 +0300 Remove trailing whitespace --- Readme.md| 4 ++-- buildtools/cxf-checkstyle.xml| 6 +++--- common/Readme.md | 2 +- .../cxf/dosgi/common/intent/impl/IntentManagerImpl.java | 4 ++-- .../dsw/decorator/ServiceDecoratorBundleListener.java| 2 +- .../dosgi/dsw/decorator/ServiceDecoratorImplTest.java| 2 +- distribution/Readme.md | 6 +++--- itests/multi-bundle/pom.xml | 6 +++--- .../apache/cxf/dosgi/itests/multi/TestExportService.java | 2 +- .../apache/cxf/dosgi/dsw/handlers/rest/RsProvider.java | 8 .../dosgi/dsw/handlers/rest/simple/RsProviderTest.java | 2 +- .../org/apache/cxf/dosgi/dsw/handlers/ws/WsProvider.java | 4 ++-- .../apache/cxf/dosgi/dsw/handlers/ws/WsdlSupport.java| 4 ++-- .../handlers/ws/PojoConfigurationTypeHandlerTest.java| 6 +++--- release_notes.md | 16 samples/Readme.md| 6 +++--- samples/rest/README.md | 8 samples/soap/README.md | 6 +++--- samples/ssl/README.md| 6 +++--- .../java/org/apache/cxf/dosgi/samples/ssl/SslIntent.java | 2 +- 20 files changed, 51 insertions(+), 51 deletions(-) diff --git a/Readme.md b/Readme.md index 22c95cd..afd8450 100644 --- a/Readme.md +++ b/Readme.md @@ -7,7 +7,7 @@ CXF DOSGi allows to easily publish and consume SOAP and REST services without us ## Modules * [common - Common services like intents and HTTPService support](common). -* [provider-ws - SOAP transport](provider-ws) +* [provider-ws - SOAP transport](provider-ws) * [provider-rs - REST transport](provider-rs) * [decorator - Support for exporting existing services](decorator) @@ -16,7 +16,7 @@ CXF DOSGi allows to easily publish and consume SOAP and REST services without us ## Intents -Intents allow a service to leverage CXF extensions like features. A service can list the named intents it requires. +Intents allow a service to leverage CXF extensions like features. A service can list the named intents it requires. It will then only be exported / imported once all the intents are available. This allows for example security restrictions or logging. For more information see [common module](common). diff --git a/buildtools/cxf-checkstyle.xml b/buildtools/cxf-checkstyle.xml index ce59e05..36dd94b 100644 --- a/buildtools/cxf-checkstyle.xml +++ b/buildtools/cxf-checkstyle.xml @@ -22,7 +22,7 @@ "http://www.puppycrawl.com/dtds/configuration_1_2.dtd;> @@ -231,7 +231,7 @@ - diff --git a/common/Readme.md b/common/Readme.md index fe2959d..2d6ccf3 100644 --- a/common/Readme.md +++ b/common/Readme.md @@ -7,7 +7,7 @@ Handles communication with the HttpService and Intents. In case a custom http context is used the providers will register a custom servlet. Besides this the HttpServiceManager also handles the creation of a default address if none is given and the conversion from the relative address specified on the service property to a fully qualified address. -Config pid `org.apache.cxf.dosgi.http` +Config pid `org.apache.cxf.dosgi.http` Key | Default | Description |-| diff --git a/common/src/main/java/org/apache/cxf/dosgi/common/intent/impl/IntentManagerImpl.java b/common/src/main/java/org/apache/cxf/dosgi/common/intent/impl/IntentManagerImpl.java index f1fd5ce..c3f6cb8 100644 --- a/common/src/main/java/org/apache/cxf/dosgi/common/intent/impl/IntentManagerImpl.java +++ b/common/src/main/java/org/apache/cxf/dosgi/common/intent/impl/IntentManagerImpl.java @@ -108,7 +108,7 @@ public class IntentManagerImpl implements IntentManager { List curIntents = ((Callable>)intent).call(); intents.addAll(curIntents); } catch (Exception e) { -throw new RuntimeException(e); +throw new RuntimeException(e); } } else if (intent instanceof IntentsProvider) { try { @@ -116,7 +116,7 @@ public class IntentManagerImpl implements IntentManager { List curIntents = provider.getIntents(); intents.addAll(curIntents); } catch (Exception e) { -throw new RuntimeException(e); +throw new
[cxf-dosgi] 15/16: Upgrade tests to junit 4
This is an automated email from the ASF dual-hosted git repository. amichai pushed a commit to branch master in repository https://gitbox.apache.org/repos/asf/cxf-dosgi.git commit 344ab766905477c2b77f039fb1bff6c8da5932fe Author: Amichai Rothman AuthorDate: Wed May 29 00:02:52 2019 +0300 Upgrade tests to junit 4 --- .../common/httpservice/HttpServiceManagerTest.java | 11 ++--- .../SecurityDelegatingHttpContextTest.java | 48 +- .../cxf/dosgi/common/util/PropertyHelperTest.java | 20 ++--- .../cxf/dosgi/dsw/decorator/InterfaceRuleTest.java | 17 ++-- .../dsw/decorator/ServiceDecoratorImplTest.java| 20 ++--- .../ws/PojoConfigurationTypeHandlerTest.java | 32 +++ 6 files changed, 100 insertions(+), 48 deletions(-) diff --git a/common/src/test/java/org/apache/cxf/dosgi/common/httpservice/HttpServiceManagerTest.java b/common/src/test/java/org/apache/cxf/dosgi/common/httpservice/HttpServiceManagerTest.java index cc7dfa9..29acce1 100644 --- a/common/src/test/java/org/apache/cxf/dosgi/common/httpservice/HttpServiceManagerTest.java +++ b/common/src/test/java/org/apache/cxf/dosgi/common/httpservice/HttpServiceManagerTest.java @@ -20,6 +20,7 @@ package org.apache.cxf.dosgi.common.httpservice; import static org.easymock.EasyMock.expect; import static org.easymock.EasyMock.expectLastCall; +import static org.junit.Assert.assertEquals; import java.util.Dictionary; @@ -33,7 +34,7 @@ import org.apache.cxf.BusFactory; import org.easymock.Capture; import org.easymock.EasyMock; import org.easymock.IMocksControl; -import org.junit.Assert; +import org.junit.Test; import org.osgi.framework.BundleContext; import org.osgi.framework.Filter; import org.osgi.framework.ServiceEvent; @@ -42,10 +43,9 @@ import org.osgi.framework.ServiceReference; import org.osgi.service.http.HttpContext; import org.osgi.service.http.HttpService; -import junit.framework.TestCase; - -public class HttpServiceManagerTest extends TestCase { +public class HttpServiceManagerTest { +@Test public void testGetAbsoluteAddress() { HttpServiceManager manager = new HttpServiceManager(); manager.initFromConfig(null); @@ -57,6 +57,7 @@ public class HttpServiceManagerTest extends TestCase { assertEquals("http://localhost:8181/mycontext/myservice;, address2); } +@Test public void testRegisterAndUnregisterServlet() throws Exception { IMocksControl c = EasyMock.createControl(); BundleContext dswContext = c.createMock(BundleContext.class); @@ -99,7 +100,7 @@ public class HttpServiceManagerTest extends TestCase { @SuppressWarnings("rawtypes") public void registerServlet(String alias, Servlet servlet, Dictionary initparams, HttpContext context) throws ServletException { -Assert.assertEquals("/myService", alias); +assertEquals("/myService", alias); servlet.init(config); } diff --git a/common/src/test/java/org/apache/cxf/dosgi/common/httpservice/SecurityDelegatingHttpContextTest.java b/common/src/test/java/org/apache/cxf/dosgi/common/httpservice/SecurityDelegatingHttpContextTest.java index aceff54..068de12 100644 --- a/common/src/test/java/org/apache/cxf/dosgi/common/httpservice/SecurityDelegatingHttpContextTest.java +++ b/common/src/test/java/org/apache/cxf/dosgi/common/httpservice/SecurityDelegatingHttpContextTest.java @@ -30,17 +30,20 @@ import javax.servlet.http.HttpServletRequest; import javax.servlet.http.HttpServletResponse; import org.easymock.EasyMock; -import org.junit.Assert; +import org.junit.Before; +import org.junit.Test; import org.osgi.framework.BundleContext; import org.osgi.framework.ServiceReference; import org.osgi.service.http.HttpContext; -import junit.framework.TestCase; +import static org.junit.Assert.assertEquals; +import static org.junit.Assert.assertFalse; +import static org.junit.Assert.assertTrue; @SuppressWarnings({ "unchecked", "rawtypes" }) -public class SecurityDelegatingHttpContextTest extends TestCase { +public class SecurityDelegatingHttpContextTest { protected HttpContext defaultHttpContext; protected SecurityDelegatingHttpContext httpContext; @@ -50,7 +53,7 @@ public class SecurityDelegatingHttpContextTest extends TestCase { protected String mimeType; protected URL url; // does not need to exist -@Override +@Before public void setUp() throws Exception { mimeType = "text/xml"; url = new URL("file:test.xml"); // does not need to exist @@ -67,6 +70,7 @@ public class SecurityDelegatingHttpContextTest extends TestCase { EasyMock.replay(defaultHttpContext); } +@Test public void testFilterRequired() throws Exception { // Mock up the service references ServiceReference[] serviceReferences = {}; @@ -89,14 +93,15 @@ public class SecurityDelegatingHttpContextTest extends TestCase
[cxf-dosgi] 14/16: Fix mixed indentation styles
This is an automated email from the ASF dual-hosted git repository. amichai pushed a commit to branch master in repository https://gitbox.apache.org/repos/asf/cxf-dosgi.git commit 47133d4b479704f17b9657a88e8bbba104994afa Author: Amichai Rothman AuthorDate: Tue May 28 22:52:39 2019 +0300 Fix mixed indentation styles --- buildtools/cxf-checkstyle.xml | 64 +-- distribution/multi-bundle/pom.xml | 528 ++--- .../multi-bundle/src/main/assembly/assembly.xml| 118 ++--- distribution/repository/pom.xml| 2 +- itests/multi-bundle/pom.xml| 22 +- parent/pom.xml | 14 +- provider-rs/pom.xml| 16 +- samples/rest/impl-jackson/pom.xml | 36 +- samples/rest/impl/pom.xml | 6 +- 9 files changed, 403 insertions(+), 403 deletions(-) diff --git a/buildtools/cxf-checkstyle.xml b/buildtools/cxf-checkstyle.xml index 9d54896..ce59e05 100644 --- a/buildtools/cxf-checkstyle.xml +++ b/buildtools/cxf-checkstyle.xml @@ -18,8 +18,8 @@ under the License. --> http://www.puppycrawl.com/dtds/configuration_1_2.dtd;> + "-//Puppy Crawl//DTD Check Configuration 1.2//EN" + "http://www.puppycrawl.com/dtds/configuration_1_2.dtd;> - + @@ -102,7 +102,7 @@ - + @@ -258,35 +258,35 @@ - - + + - + + + + + + + + + + + + + + + + + + http://www.apache.org/licenses/LIC [...] + + + + + + + - - - - - - - - - - - - - - - - http://www.apache.org [...] - - - - - - - - diff --git a/distribution/multi-bundle/pom.xml b/distribution/multi-bundle/pom.xml index ff35945..550470e 100644 --- a/distribution/multi-bundle/pom.xml +++ b/distribution/multi-bundle/pom.xml @@ -1,66 +1,66 @@ +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. --> http://maven.apache.org/POM/4.0.0; xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance; xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd;> - 4.0.0 - cxf-dosgi-multibundle-distribution - CXF DOSGi Multi-Bundle Distribution - http://cxf.apache.org +4.0.0 +cxf-dosgi-multibundle-distribution +CXF DOSGi Multi-Bundle Distribution +http://cxf.apache.org - - org.apache.cxf.dosgi - cxf-dosgi-distribution-parent - 2.4.0-SNAPSHOT - ../pom.xml - + +org.apache.cxf.dosgi +cxf-dosgi-distribution-parent +2.4.0-SNAPSHOT +../pom.xml + - - ${project.version} - ../.. - 4.1.2 - + +${project.version} +../.. +4.1.2 + - - - - org.apache.felix - org.apache.felix.framework - - - org.apache.felix - org.apache.felix.eventadmin - 1.4.6 - - - org.apache.felix - org.apache.felix.configadmin - 1.8.8 - - - org.apache.felix - org.apache.felix.metatype - 1.1.2 - - - kxml2 - net.sf.kxml - - - - -
[cxf-dosgi] 05/16: Remove redundant throws clause
This is an automated email from the ASF dual-hosted git repository. amichai pushed a commit to branch master in repository https://gitbox.apache.org/repos/asf/cxf-dosgi.git commit 5c9c12a6e06e51b4dec7ee0042789101dc712f57 Author: Amichai Rothman AuthorDate: Tue May 28 15:30:58 2019 +0300 Remove redundant throws clause --- .../apache/cxf/dosgi/common/endpoint/ServerEndpoint.java| 4 +--- .../org/apache/cxf/dosgi/common/proxy/ExceptionMapper.java | 2 +- .../dosgi/common/httpservice/HttpServiceManagerTest.java| 5 ++--- .../httpservice/SecurityDelegatingHttpContextTest.java | 13 ++--- .../java/org/apache/cxf/dosgi/dsw/decorator/Activator.java | 4 ++-- .../apache/cxf/dosgi/dsw/decorator/InterfaceRuleTest.java | 2 +- .../cxf/dosgi/dsw/decorator/ServiceDecoratorImplTest.java | 4 ++-- .../apache/cxf/dosgi/itests/multi/AbstractDosgiTest.java| 2 +- .../org/apache/cxf/dosgi/itests/multi/MultiBundleTools.java | 4 ++-- .../org/apache/cxf/dosgi/itests/multi/TestCustomIntent.java | 4 ++-- .../org/apache/cxf/dosgi/itests/multi/TestExportPolicy.java | 4 ++-- .../apache/cxf/dosgi/itests/multi/TestExportService.java| 4 ++-- .../apache/cxf/dosgi/itests/multi/TestImportService.java| 4 ++-- .../itests/multi/customintent/CustomIntentActivator.java| 4 ++-- .../dsw/handlers/rest/provider/RsProviderCustomTest.java| 2 +- .../dsw/handlers/ws/PojoConfigurationTypeHandlerTest.java | 12 ++-- .../cxf/dosgi/samples/security/SampleSecurityFilter.java| 2 +- 17 files changed, 36 insertions(+), 40 deletions(-) diff --git a/common/src/main/java/org/apache/cxf/dosgi/common/endpoint/ServerEndpoint.java b/common/src/main/java/org/apache/cxf/dosgi/common/endpoint/ServerEndpoint.java index a0ad662..08f5eb7 100644 --- a/common/src/main/java/org/apache/cxf/dosgi/common/endpoint/ServerEndpoint.java +++ b/common/src/main/java/org/apache/cxf/dosgi/common/endpoint/ServerEndpoint.java @@ -18,8 +18,6 @@ */ package org.apache.cxf.dosgi.common.endpoint; -import java.io.IOException; - import org.apache.aries.rsa.spi.Endpoint; import org.apache.cxf.endpoint.Server; import org.osgi.service.remoteserviceadmin.EndpointDescription; @@ -38,7 +36,7 @@ public class ServerEndpoint implements Endpoint { } @Override -public void close() throws IOException { +public void close() { this.server.destroy(); } diff --git a/common/src/main/java/org/apache/cxf/dosgi/common/proxy/ExceptionMapper.java b/common/src/main/java/org/apache/cxf/dosgi/common/proxy/ExceptionMapper.java index 4601d9c..01d7ef4 100644 --- a/common/src/main/java/org/apache/cxf/dosgi/common/proxy/ExceptionMapper.java +++ b/common/src/main/java/org/apache/cxf/dosgi/common/proxy/ExceptionMapper.java @@ -34,7 +34,7 @@ public class ExceptionMapper { introspectTypeForExceptions(iType); } -public Throwable mapException(Method m, Throwable ex) throws Throwable { +public Throwable mapException(Method m, Throwable ex) { Throwable cause = ex.getCause() == null ? ex : ex.getCause(); Set> excTypes = exceptionsMap.get(m); if (excTypes != null) { diff --git a/common/src/test/java/org/apache/cxf/dosgi/common/httpservice/HttpServiceManagerTest.java b/common/src/test/java/org/apache/cxf/dosgi/common/httpservice/HttpServiceManagerTest.java index 1f49f09..a97a330 100644 --- a/common/src/test/java/org/apache/cxf/dosgi/common/httpservice/HttpServiceManagerTest.java +++ b/common/src/test/java/org/apache/cxf/dosgi/common/httpservice/HttpServiceManagerTest.java @@ -41,7 +41,6 @@ import org.osgi.framework.ServiceListener; import org.osgi.framework.ServiceReference; import org.osgi.service.http.HttpContext; import org.osgi.service.http.HttpService; -import org.osgi.service.http.NamespaceException; import junit.framework.TestCase; @@ -98,12 +97,12 @@ public class HttpServiceManagerTest extends TestCase { @SuppressWarnings("rawtypes") public void registerServlet(String alias, Servlet servlet, Dictionary initparams, HttpContext context) -throws ServletException, NamespaceException { +throws ServletException { Assert.assertEquals("/myService", alias); servlet.init(config); } -public void registerResources(String alias, String name, HttpContext context) throws NamespaceException { +public void registerResources(String alias, String name, HttpContext context) { throw new RuntimeException("This method should not be called"); } diff --git a/common/src/test/java/org/apache/cxf/dosgi/common/httpservice/SecurityDelegatingHttpContextTest.java b/common/src/test/java/org/apache/cxf/dosgi/common/httpservice/SecurityDelegatingHttpContextTest.java index aac1204..8b36548 100644 --- a/common/src/test/java/org/apache/cxf/dosgi/common/httpservice/SecurityDelegatingHttpContextTest.java +++
[cxf-dosgi] 13/16: Tiny simplifications
This is an automated email from the ASF dual-hosted git repository. amichai pushed a commit to branch master in repository https://gitbox.apache.org/repos/asf/cxf-dosgi.git commit 68591a25ac72c977ec02994c674469745d00b293 Author: Amichai Rothman AuthorDate: Tue May 28 22:27:38 2019 +0300 Tiny simplifications --- .../org/apache/cxf/dosgi/common/intent/impl/IntentManagerImpl.java | 2 +- .../apache/cxf/dosgi/common/proxy/ServiceInvocationHandlerTest.java | 6 -- .../main/java/org/apache/cxf/dosgi/dsw/decorator/InterfaceRule.java | 2 +- .../cxf/dosgi/itests/multi/customintent/ChangeTitleInterceptor.java | 2 +- .../cxf/dosgi/dsw/handlers/ws/PojoConfigurationTypeHandlerTest.java | 3 +-- .../api/src/main/java/org/apache/cxf/dosgi/samples/rest/Task.java | 2 +- .../api/src/main/java/org/apache/cxf/dosgi/samples/soap/Task.java | 2 +- 7 files changed, 10 insertions(+), 9 deletions(-) diff --git a/common/src/main/java/org/apache/cxf/dosgi/common/intent/impl/IntentManagerImpl.java b/common/src/main/java/org/apache/cxf/dosgi/common/intent/impl/IntentManagerImpl.java index b9b4525..f1fd5ce 100644 --- a/common/src/main/java/org/apache/cxf/dosgi/common/intent/impl/IntentManagerImpl.java +++ b/common/src/main/java/org/apache/cxf/dosgi/common/intent/impl/IntentManagerImpl.java @@ -134,7 +134,7 @@ public class IntentManagerImpl implements IntentManager { if (selectedIntents.size() > 1) { LOG.warn("More than one intent of type " + type + " present. Using only the first one."); } -return (T)selectedIntents.iterator().next(); +return selectedIntents.iterator().next(); } @Override diff --git a/common/src/test/java/org/apache/cxf/dosgi/common/proxy/ServiceInvocationHandlerTest.java b/common/src/test/java/org/apache/cxf/dosgi/common/proxy/ServiceInvocationHandlerTest.java index 985a9a0..fbdeaa7 100644 --- a/common/src/test/java/org/apache/cxf/dosgi/common/proxy/ServiceInvocationHandlerTest.java +++ b/common/src/test/java/org/apache/cxf/dosgi/common/proxy/ServiceInvocationHandlerTest.java @@ -33,7 +33,9 @@ import org.junit.Test; public class ServiceInvocationHandlerTest { -private static final Map OBJECT_METHODS = new HashMap<>(); { +private static final Map OBJECT_METHODS = new HashMap<>(); + +{ for (Method m : Object.class.getMethods()) { OBJECT_METHODS.put(m.getName(), m); } @@ -42,7 +44,7 @@ public class ServiceInvocationHandlerTest { @Test public void testInvoke() throws Throwable { ServiceInvocationHandler sih = new ServiceInvocationHandler("hello", String.class); -Method m = String.class.getMethod("length", new Class[] {}); +Method m = String.class.getMethod("length"); assertEquals(5, sih.invoke(null, m, new Object[] {})); } diff --git a/decorator/src/main/java/org/apache/cxf/dosgi/dsw/decorator/InterfaceRule.java b/decorator/src/main/java/org/apache/cxf/dosgi/dsw/decorator/InterfaceRule.java index 02578f3..00c2848 100644 --- a/decorator/src/main/java/org/apache/cxf/dosgi/dsw/decorator/InterfaceRule.java +++ b/decorator/src/main/java/org/apache/cxf/dosgi/dsw/decorator/InterfaceRule.java @@ -54,7 +54,7 @@ public class InterfaceRule implements Rule { if (type != null && !String.class.getName().equals(type)) { try { Class cls = getClass().getClassLoader().loadClass(type); -Constructor ctor = cls.getConstructor(new Class[] {String.class}); +Constructor ctor = cls.getConstructor(String.class); obj = ctor.newInstance(value); } catch (Throwable th) { LOG.warn("Could not handle property '" + name diff --git a/itests/multi-bundle/src/test/java/org/apache/cxf/dosgi/itests/multi/customintent/ChangeTitleInterceptor.java b/itests/multi-bundle/src/test/java/org/apache/cxf/dosgi/itests/multi/customintent/ChangeTitleInterceptor.java index 066117b..a3c0bef 100644 --- a/itests/multi-bundle/src/test/java/org/apache/cxf/dosgi/itests/multi/customintent/ChangeTitleInterceptor.java +++ b/itests/multi-bundle/src/test/java/org/apache/cxf/dosgi/itests/multi/customintent/ChangeTitleInterceptor.java @@ -41,7 +41,7 @@ public final class ChangeTitleInterceptor extends AbstractPhaseInterceptor
buildbot failure in on cxf-site-production
The Buildbot has detected a new failure on builder cxf-site-production while building . Full details are available at: https://ci.apache.org/builders/cxf-site-production/builds/32638 Buildbot URL: https://ci.apache.org/ Buildslave for this Build: bb-cms-slave Build Reason: The Nightly scheduler named 'cxf-site-production' triggered this build Build Source Stamp: [branch cxf/web] HEAD Blamelist: BUILD FAILED: failed compile Sincerely, -The Buildbot
[cxf] branch 3.2.x-fixes updated: Recording .gitmergeinfo Changes
This is an automated email from the ASF dual-hosted git repository. ffang pushed a commit to branch 3.2.x-fixes in repository https://gitbox.apache.org/repos/asf/cxf.git The following commit(s) were added to refs/heads/3.2.x-fixes by this push: new 88689a8 Recording .gitmergeinfo Changes 88689a8 is described below commit 88689a8160dc6f090c38b307b0d6f891e5e0ac5a Author: Freeman Fang AuthorDate: Tue May 28 12:15:07 2019 -0400 Recording .gitmergeinfo Changes --- .gitmergeinfo | 5 + 1 file changed, 5 insertions(+) diff --git a/.gitmergeinfo b/.gitmergeinfo index 31a3bc7..8e34b78 100644 --- a/.gitmergeinfo +++ b/.gitmergeinfo @@ -106,6 +106,7 @@ B 34b75cdf57da30d595ee865c4774b8638b7da7ed B 35109bda0481badb8ea7294d232de02fa8e9408f B 356e467580a8351e8b5b3744659ad27a26a62ce4 B 35fd40f5b5e043f0044dce9286a9ce922bc30d2c +B 36428ee52da64efb853f8cc9d249d3bfc89d17fb B 3671c30616bec8e08f5970481cad77d5c17ef437 B 3687dd4f8d0c3f176724c10ceb49412dbba860ee B 375e5e1db0de3a3bc4e4cc2907ff923cb8c13062 @@ -192,6 +193,7 @@ B 59a74cf86b42143a71b23c6e67a494a57dc645e7 B 5a5d6eab2748d03508d51ee036701244ad0cfe25 B 5a72b4170110d58fb6186fd7ce9f5339b9550f5e B 5b11f39743278a06fdf174e89b0178a7f9d86fbb +B 5b2f078eda2ede0f6afb12b146869403c1c2d3fb B 5ce20d7f3c7bf0c028f290a9a92704662adc8832 B 5cf3301c9bbf655a05cb7fcc0ed29d5cc2269142 B 5d164a22c1934f6c499d12146c6ab9d59b13e6ee @@ -201,6 +203,7 @@ B 5dfd0e0ee068c0f424a2a9ac513ebf74b7e7b618 B 5ecf2214e4cfa0992da3ca74cd92128a3048b4f4 B 5f102913d6e112ea6a2176f45aaee4890adc1a6a B 5fdfd70af65f53b0bd73ecfc10906e28648ede94 +B 605e2ec9844a890a0c5a1b56a16c1f603be61bcf B 60b0165afccb03816ada90271d1bfc66a6c2eb52 B 60c4c6418a285d71fc197dc953332d987e7651d9 B 612b03ea00b8a9e747411dbfa9a4eb1c6ff4b529 @@ -219,6 +222,7 @@ B 65297e7f2a7a13f90b0f90fee8baebd3f742ad87 B 65cdeda9a3089c93a45262e2ea6ec4e14abafceb B 6650dc0d114e229737ba85a1e28c146e24c7c606 B 67491a02dd7135947e091e67fde02b70c3a13b31 +B 675222439f1a9873ee7ffaa81f2301cec0664e4d B 6756c49b7b8d949c09fa98cc9c5725b90ed5370b B 687dd36db702dd8a013d49c71fc4d3afe4323a0c B 68af13530379662fc99a716d635d4aab7c5fb027 @@ -403,6 +407,7 @@ B bfdf209e171ac16e6ae962fd8ef0bf7356c7898d B bff521fc91218248e809b23e292fbaa4747cb36c B c2d9000c1872973d4ad6e30075d320da167d3c2d B c489d553a5398c457b05b79f4fc24304cf39a113 +B c55faf9728791395ff7749beb50781b1a710c477 B c58dda66f5531e0cf1b164955a38c4e31f09c13e B c5f38aff250d2237f3eaa6dffcbeef905ad535e0 B c62f3fba0fe7b02f7ff6597cfc7227ebf98830af
[cxf] branch 3.2.x-fixes updated: [CXF-8049]org.apache.cxf.common.util.Compiler fails to compile if a classpath entry contains spaces
This is an automated email from the ASF dual-hosted git repository. ffang pushed a commit to branch 3.2.x-fixes in repository https://gitbox.apache.org/repos/asf/cxf.git The following commit(s) were added to refs/heads/3.2.x-fixes by this push: new 3c65816 [CXF-8049]org.apache.cxf.common.util.Compiler fails to compile if a classpath entry contains spaces 3c65816 is described below commit 3c65816805573e7a5da2a77b9c18559f940f29c7 Author: Freeman Fang AuthorDate: Tue May 28 12:13:46 2019 -0400 [CXF-8049]org.apache.cxf.common.util.Compiler fails to compile if a classpath entry contains spaces --- .../java/org/apache/cxf/common/util/Compiler.java | 29 -- 1 file changed, 27 insertions(+), 2 deletions(-) diff --git a/core/src/main/java/org/apache/cxf/common/util/Compiler.java b/core/src/main/java/org/apache/cxf/common/util/Compiler.java index ebf1f4c..c69a4a8 100644 --- a/core/src/main/java/org/apache/cxf/common/util/Compiler.java +++ b/core/src/main/java/org/apache/cxf/common/util/Compiler.java @@ -85,6 +85,31 @@ public class Compiler { classPath = StringUtils.isEmpty(s) ? null : s; } +// https://issues.apache.org/jira/browse/CXF-8049 +private String getSystemClassPath() { +String javaClasspath = SystemPropertyAction.getProperty("java.class.path"); + +if (!StringUtils.isEmpty(javaClasspath)) { +List correctedEntries = new ArrayList<>(); + +String[] toks = javaClasspath.split(File.pathSeparator); + +for (String tok: toks) { +// if any classpath entry contains a whitespace char, +// enclose the entry in double quotes +if (tok.matches(".*\\s+.*")) { +correctedEntries.add("\"" + tok + "\""); +} else { +correctedEntries.add(tok); +} +} + +return String.join(File.pathSeparator, correctedEntries); +} + +return javaClasspath; +} + protected void addArgs(List list) { if (!StringUtils.isEmpty(encoding)) { list.add("-encoding"); @@ -103,8 +128,8 @@ public class Compiler { } if (StringUtils.isEmpty(classPath)) { -String javaClasspath = SystemPropertyAction.getProperty("java.class.path"); -boolean classpathSetted = javaClasspath != null ? true : false; +String javaClasspath = getSystemClassPath(); +boolean classpathSetted = !StringUtils.isEmpty(javaClasspath); if (!classpathSetted) { File f = new File(getClass().getClassLoader().getResource(".").getFile()); f = new File(f, "../lib");
[cxf] branch master updated: [CXF-8049]a bit enhancement
This is an automated email from the ASF dual-hosted git repository. ffang pushed a commit to branch master in repository https://gitbox.apache.org/repos/asf/cxf.git The following commit(s) were added to refs/heads/master by this push: new 605e2ec [CXF-8049]a bit enhancement 605e2ec is described below commit 605e2ec9844a890a0c5a1b56a16c1f603be61bcf Author: Freeman Fang AuthorDate: Tue May 28 11:26:59 2019 -0400 [CXF-8049]a bit enhancement --- core/src/main/java/org/apache/cxf/common/util/Compiler.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/core/src/main/java/org/apache/cxf/common/util/Compiler.java b/core/src/main/java/org/apache/cxf/common/util/Compiler.java index a4461c7..7ddb7d0 100644 --- a/core/src/main/java/org/apache/cxf/common/util/Compiler.java +++ b/core/src/main/java/org/apache/cxf/common/util/Compiler.java @@ -107,7 +107,7 @@ public class Compiler { return String.join(File.pathSeparator, correctedEntries); } -return ""; +return javaClasspath; } protected void addArgs(List list) {
[cxf] branch master updated (493f5de -> 647156c)
This is an automated email from the ASF dual-hosted git repository. ffang pushed a change to branch master in repository https://gitbox.apache.org/repos/asf/cxf.git. from 493f5de Update jcache & ehcache3 versions new 5b2f078 CXF-8049: Enclosing class path entries that contain whitespaces in double quotes new 36428ee CXF-8049: Compile failed new 6752224 CXF-8049: Checkstyle related changes new c55faf9 CXF-8049: More Checkstyle pain new 647156c Merge pull request #558 from vadakr/CXF-8049 The 15003 revisions listed above as "new" are entirely new to this repository and will be described in separate emails. The revisions listed as "add" were already present in the repository and have only been added to this reference. Summary of changes: .../java/org/apache/cxf/common/util/Compiler.java | 27 +- 1 file changed, 26 insertions(+), 1 deletion(-)
[cxf] branch 3.2.x-fixes updated: .Revert "Updating Commons Lang"
This is an automated email from the ASF dual-hosted git repository. coheigea pushed a commit to branch 3.2.x-fixes in repository https://gitbox.apache.org/repos/asf/cxf.git The following commit(s) were added to refs/heads/3.2.x-fixes by this push: new a40321a .Revert "Updating Commons Lang" a40321a is described below commit a40321a897e1486eb71d4a684bb476818aea0c05 Author: Colm O hEigeartaigh AuthorDate: Tue May 28 12:40:26 2019 +0100 .Revert "Updating Commons Lang" This reverts commit 44382f14f369ba9337db4b266534636e37a96b8c. --- parent/pom.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/parent/pom.xml b/parent/pom.xml index 1bf5793..3fd62d1 100644 --- a/parent/pom.xml +++ b/parent/pom.xml @@ -81,7 +81,7 @@ 1.1.0 1.12 3.2.2 -3.9 +3.8.1 1.6 10.14.2.0 3.2.6
[cxf] branch 3.2.x-fixes updated: Updating Commons Lang
This is an automated email from the ASF dual-hosted git repository. coheigea pushed a commit to branch 3.2.x-fixes in repository https://gitbox.apache.org/repos/asf/cxf.git The following commit(s) were added to refs/heads/3.2.x-fixes by this push: new 44382f1 Updating Commons Lang 44382f1 is described below commit 44382f14f369ba9337db4b266534636e37a96b8c Author: Colm O hEigeartaigh AuthorDate: Tue May 28 12:38:53 2019 +0100 Updating Commons Lang --- parent/pom.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/parent/pom.xml b/parent/pom.xml index 3fd62d1..1bf5793 100644 --- a/parent/pom.xml +++ b/parent/pom.xml @@ -81,7 +81,7 @@ 1.1.0 1.12 3.2.2 -3.8.1 +3.9 1.6 10.14.2.0 3.2.6
[cxf-dosgi] branch master updated: DOSGI-280 - Upgrade to Aries RSA 1.14.0
This is an automated email from the ASF dual-hosted git repository. coheigea pushed a commit to branch master in repository https://gitbox.apache.org/repos/asf/cxf-dosgi.git The following commit(s) were added to refs/heads/master by this push: new 618ad8f DOSGI-280 - Upgrade to Aries RSA 1.14.0 new 966be4c Merge pull request #5 from amichair/DOSGI-280 618ad8f is described below commit 618ad8fb748efd67ac5232fd50400b81dc5be953 Author: Amichai Rothman AuthorDate: Tue May 28 12:32:00 2019 +0300 DOSGI-280 - Upgrade to Aries RSA 1.14.0 --- distribution/multi-bundle/distro.bndrun | 12 ++-- parent/pom.xml | 2 +- samples/soap/soap.bndrun| 8 3 files changed, 11 insertions(+), 11 deletions(-) diff --git a/distribution/multi-bundle/distro.bndrun b/distribution/multi-bundle/distro.bndrun index c3f99d0..6ea840f 100644 --- a/distribution/multi-bundle/distro.bndrun +++ b/distribution/multi-bundle/distro.bndrun @@ -73,12 +73,12 @@ org.apache.cxf.dosgi.cxf-dosgi-common;version='[2.4.0,2.4.1)',\ org.apache.cxf.dosgi.cxf-dosgi-provider-rs;version='[2.4.0,2.4.1)',\ org.apache.cxf.dosgi.cxf-dosgi-provider-ws;version='[2.4.0,2.4.1)',\ - org.apache.aries.rsa.core;version='[1.12.0,1.13.0)',\ - org.apache.aries.rsa.discovery.command;version='[1.12.0,1.13.0)',\ - org.apache.aries.rsa.discovery.local;version='[1.12.0,1.13.0)',\ - org.apache.aries.rsa.discovery.zookeeper;version='[1.12.0,1.13.0)',\ - org.apache.aries.rsa.spi;version='[1.12.0,1.13.0)',\ - org.apache.aries.rsa.topology-manager;version='[1.12.0,1.13.0)',\ + org.apache.aries.rsa.core;version='[1.14.0,1.15.0)',\ + org.apache.aries.rsa.discovery.command;version='[1.14.0,1.15.0)',\ + org.apache.aries.rsa.discovery.local;version='[1.14.0,1.15.0)',\ + org.apache.aries.rsa.discovery.zookeeper;version='[1.14.0,1.15.0)',\ + org.apache.aries.rsa.spi;version='[1.14.0,1.15.0)',\ + org.apache.aries.rsa.topology-manager;version='[1.14.0,1.15.0)',\ org.apache.cxf.cxf-core;version='[3.3.0,3.4.0)',\ org.apache.cxf.cxf-rt-bindings-soap;version='[3.3.0,3.4.0)',\ org.apache.cxf.cxf-rt-bindings-xml;version='[3.3.0,3.4.0)',\ diff --git a/parent/pom.xml b/parent/pom.xml index e0f2a61..951752b 100644 --- a/parent/pom.xml +++ b/parent/pom.xml @@ -29,7 +29,7 @@ 6.0.0 6.0.0 -1.13.0 +1.14.0 3.3.2 5.6.8 3.4.14 diff --git a/samples/soap/soap.bndrun b/samples/soap/soap.bndrun index 3331134..151fafd 100644 --- a/samples/soap/soap.bndrun +++ b/samples/soap/soap.bndrun @@ -56,10 +56,10 @@ org.fusesource.jansi;version='[1.13.0,1.13.1)',\ javax.annotation-api;version='[1.2.0,1.2.1)',\ org.apache.servicemix.specs.jsr339-api-2.0.1;version='[2.6.0,2.6.1)',\ - org.apache.aries.rsa.core;version='[1.11.0,1.11.1)',\ - org.apache.aries.rsa.discovery.command;version='[1.11.0,1.11.1)',\ - org.apache.aries.rsa.spi;version='[1.11.0,1.11.1)',\ - org.apache.aries.rsa.topology-manager;version='[1.11.0,1.11.1)',\ + org.apache.aries.rsa.core;version='[1.14.0,1.15.0)',\ + org.apache.aries.rsa.discovery.command;version='[1.14.0,1.15.0)',\ + org.apache.aries.rsa.spi;version='[1.14.0,1.15.0)',\ + org.apache.aries.rsa.topology-manager;version='[1.14.0,1.15.0)',\ org.apache.cxf.cxf-core;version='[3.1.12,3.1.13)',\ org.apache.cxf.cxf-rt-bindings-soap;version='[3.1.12,3.1.13)',\ org.apache.cxf.cxf-rt-bindings-xml;version='[3.1.12,3.1.13)',\
[cxf-dosgi] branch master updated: DOSGI-279 - Upgrade to CXF 3.2.2
This is an automated email from the ASF dual-hosted git repository. coheigea pushed a commit to branch master in repository https://gitbox.apache.org/repos/asf/cxf-dosgi.git The following commit(s) were added to refs/heads/master by this push: new 96315b1 DOSGI-279 - Upgrade to CXF 3.2.2 new 2633ee0 Merge pull request #6 from amichair/DOSGI-279 96315b1 is described below commit 96315b1ca5a584d5b7418a463329465be7b68a59 Author: Amichai Rothman AuthorDate: Mon May 27 22:58:03 2019 +0300 DOSGI-279 - Upgrade to CXF 3.2.2 --- distribution/multi-bundle/distro.bndrun| 24 +++--- distribution/multi-bundle/pom.xml | 12 --- .../cxf/dosgi/itests/multi/AbstractDosgiTest.java | 11 ++ parent/pom.xml | 2 +- 4 files changed, 33 insertions(+), 16 deletions(-) diff --git a/distribution/multi-bundle/distro.bndrun b/distribution/multi-bundle/distro.bndrun index 578e831..c3f99d0 100644 --- a/distribution/multi-bundle/distro.bndrun +++ b/distribution/multi-bundle/distro.bndrun @@ -79,18 +79,18 @@ org.apache.aries.rsa.discovery.zookeeper;version='[1.12.0,1.13.0)',\ org.apache.aries.rsa.spi;version='[1.12.0,1.13.0)',\ org.apache.aries.rsa.topology-manager;version='[1.12.0,1.13.0)',\ - org.apache.cxf.cxf-core;version='[3.2.5,3.3.0)',\ - org.apache.cxf.cxf-rt-bindings-soap;version='[3.2.5,3.3.0)',\ - org.apache.cxf.cxf-rt-bindings-xml;version='[3.2.5,3.3.0)',\ - org.apache.cxf.cxf-rt-databinding-aegis;version='[3.2.5,3.3.0)',\ - org.apache.cxf.cxf-rt-databinding-jaxb;version='[3.2.5,3.3.0)',\ - org.apache.cxf.cxf-rt-frontend-jaxrs;version='[3.2.5,3.3.0)',\ - org.apache.cxf.cxf-rt-frontend-jaxws;version='[3.2.5,3.3.0)',\ - org.apache.cxf.cxf-rt-frontend-simple;version='[3.2.5,3.3.0)',\ - org.apache.cxf.cxf-rt-rs-client;version='[3.2.5,3.3.0)',\ - org.apache.cxf.cxf-rt-rs-service-description-swagger;version='[3.2.5,3.3.0)',\ - org.apache.cxf.cxf-rt-transports-http;version='[3.2.5,3.3.0)',\ - org.apache.cxf.cxf-rt-wsdl;version='[3.2.5,3.3.0)',\ + org.apache.cxf.cxf-core;version='[3.3.0,3.4.0)',\ + org.apache.cxf.cxf-rt-bindings-soap;version='[3.3.0,3.4.0)',\ + org.apache.cxf.cxf-rt-bindings-xml;version='[3.3.0,3.4.0)',\ + org.apache.cxf.cxf-rt-databinding-aegis;version='[3.3.0,3.4.0)',\ + org.apache.cxf.cxf-rt-databinding-jaxb;version='[3.3.0,3.4.0)',\ + org.apache.cxf.cxf-rt-frontend-jaxrs;version='[3.3.0,3.4.0)',\ + org.apache.cxf.cxf-rt-frontend-jaxws;version='[3.3.0,3.4.0)',\ + org.apache.cxf.cxf-rt-frontend-simple;version='[3.3.0,3.4.0)',\ + org.apache.cxf.cxf-rt-rs-client;version='[3.3.0,3.4.0)',\ + org.apache.cxf.cxf-rt-rs-service-description-swagger;version='[3.3.0,3.4.0)',\ + org.apache.cxf.cxf-rt-transports-http;version='[3.3.0,3.4.0)',\ + org.apache.cxf.cxf-rt-wsdl;version='[3.3.0,3.4.0)',\ org.apache.ws.xmlschema.core;version='[2.2.3,2.2.4)',\ org.apache.felix.gogo.command;version='[1.0.2,1.0.3)',\ org.apache.felix.gogo.jline;version='[1.1.0,1.1.1)',\ diff --git a/distribution/multi-bundle/pom.xml b/distribution/multi-bundle/pom.xml index 754502d..6f1924f 100644 --- a/distribution/multi-bundle/pom.xml +++ b/distribution/multi-bundle/pom.xml @@ -156,7 +156,13 @@ - + + +javax.xml.soap +javax.xml.soap-api +1.4.0 + + org.webjars @@ -176,7 +182,7 @@ org.apache.commons commons-lang3 - 3.8.1 + 3.9 com.fasterxml.jackson.core @@ -242,7 +248,7 @@ biz.aQute.bnd bnd-export-maven-plugin - 3.4.0 + 4.2.0 true false diff --git a/itests/multi-bundle/src/test/java/org/apache/cxf/dosgi/itests/multi/AbstractDosgiTest.java b/itests/multi-bundle/src/test/java/org/apache/cxf/dosgi/itests/multi/AbstractDosgiTest.java index 9cc5ab4..9be797e 100644 --- a/itests/multi-bundle/src/test/java/org/apache/cxf/dosgi/itests/multi/AbstractDosgiTest.java +++ b/itests/multi-bundle/src/test/java/org/apache/cxf/dosgi/itests/multi/AbstractDosgiTest.java @@ -20,6 +20,7 @@ package org.apache.cxf.dosgi.itests.multi; import static org.ops4j.pax.exam.CoreOptions.composite; import static org.ops4j.pax.exam.CoreOptions.mavenBundle; +import static org.ops4j.pax.exam.CoreOptions.systemPackage; import static