cxf-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From serg...@apache.org
Subject git commit: [CXF-5410] Optionally disable HTTP OSGI transport
Date Thu, 24 Apr 2014 12:48:50 GMT
Repository: cxf
Updated Branches:
  refs/heads/master dc4f09b76 -> 7215e8683


[CXF-5410] Optionally disable HTTP OSGI transport


Project: http://git-wip-us.apache.org/repos/asf/cxf/repo
Commit: http://git-wip-us.apache.org/repos/asf/cxf/commit/7215e868
Tree: http://git-wip-us.apache.org/repos/asf/cxf/tree/7215e868
Diff: http://git-wip-us.apache.org/repos/asf/cxf/diff/7215e868

Branch: refs/heads/master
Commit: 7215e8683cbd61efbba96438c9c871aa49c3e5e7
Parents: dc4f09b
Author: Sergey Beryozkin <sberyozkin@talend.com>
Authored: Thu Apr 24 13:48:33 2014 +0100
Committer: Sergey Beryozkin <sberyozkin@talend.com>
Committed: Thu Apr 24 13:48:33 2014 +0100

----------------------------------------------------------------------
 .../cxf/transport/http/osgi/HTTPTransportActivator.java      | 8 ++++++++
 1 file changed, 8 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cxf/blob/7215e868/rt/transports/http/src/main/java/org/apache/cxf/transport/http/osgi/HTTPTransportActivator.java
----------------------------------------------------------------------
diff --git a/rt/transports/http/src/main/java/org/apache/cxf/transport/http/osgi/HTTPTransportActivator.java
b/rt/transports/http/src/main/java/org/apache/cxf/transport/http/osgi/HTTPTransportActivator.java
index 83b37f9..b0dff63 100644
--- a/rt/transports/http/src/main/java/org/apache/cxf/transport/http/osgi/HTTPTransportActivator.java
+++ b/rt/transports/http/src/main/java/org/apache/cxf/transport/http/osgi/HTTPTransportActivator.java
@@ -26,6 +26,7 @@ import javax.servlet.Servlet;
 
 import org.apache.cxf.bus.blueprint.BlueprintNameSpaceHandlerFactory;
 import org.apache.cxf.bus.blueprint.NamespaceHandlerRegisterer;
+import org.apache.cxf.common.util.PropertyUtils;
 import org.apache.cxf.transport.http.DestinationRegistry;
 import org.apache.cxf.transport.http.DestinationRegistryImpl;
 import org.apache.cxf.transport.http.HTTPConduitConfigurer;
@@ -43,7 +44,14 @@ import org.osgi.service.cm.ManagedServiceFactory;
 public class HTTPTransportActivator 
     implements BundleActivator {
     
+    private static final String DISABLE_DEFAULT_HTTP_TRANSPORT = "org.apache.cxf.osgi.http.transport.disable";
+    
     public void start(BundleContext context) throws Exception {
+        
+        if (PropertyUtils.isTrue(context.getProperty(DISABLE_DEFAULT_HTTP_TRANSPORT))) {
+            return;
+        }
+        
         ConfigAdminHttpConduitConfigurer conduitConfigurer = new ConfigAdminHttpConduitConfigurer();
         DestinationRegistry destinationRegistry = new DestinationRegistryImpl();
         HTTPTransportFactory transportFactory = new HTTPTransportFactory(destinationRegistry);


Mime
View raw message