cxf-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From dk...@apache.org
Subject svn commit: r666803 - in /cxf/trunk: distribution/bundle/ rt/bindings/corba/src/main/resources/META-INF/ rt/bindings/corba/src/main/resources/META-INF/cxf/ rt/bindings/http/src/main/resources/META-INF/ rt/bindings/http/src/main/resources/META-INF/cxf/ ...
Date Wed, 11 Jun 2008 19:43:59 GMT
Author: dkulp
Date: Wed Jun 11 12:43:58 2008
New Revision: 666803

URL: http://svn.apache.org/viewvc?rev=666803&view=rev
Log:
[CXF-1643] Move runtime extension information into META-INF/cxf so OSGi will find it

Added:
    cxf/trunk/rt/bindings/corba/src/main/resources/META-INF/cxf/bus-extensions.xml
      - copied unchanged from r666723, cxf/trunk/rt/bindings/corba/src/main/resources/META-INF/bus-extensions.xml
    cxf/trunk/rt/bindings/corba/src/main/resources/META-INF/cxf/extensions.xml
      - copied unchanged from r666723, cxf/trunk/rt/bindings/corba/src/main/resources/META-INF/extensions.xml
    cxf/trunk/rt/bindings/http/src/main/resources/META-INF/cxf/bus-extensions.xml
      - copied unchanged from r666723, cxf/trunk/rt/bindings/http/src/main/resources/META-INF/bus-extensions.xml
    cxf/trunk/rt/bindings/jbi/src/main/resources/META-INF/cxf/bus-extensions.xml
      - copied unchanged from r666723, cxf/trunk/rt/bindings/jbi/src/main/resources/META-INF/bus-extensions.xml
    cxf/trunk/rt/bindings/object/src/main/resources/META-INF/cxf/bus-extensions.xml
      - copied unchanged from r666723, cxf/trunk/rt/bindings/object/src/main/resources/META-INF/bus-extensions.xml
    cxf/trunk/rt/bindings/soap/src/main/resources/META-INF/cxf/bus-extensions.xml
      - copied unchanged from r666723, cxf/trunk/rt/bindings/soap/src/main/resources/META-INF/bus-extensions.xml
    cxf/trunk/rt/bindings/xml/src/main/resources/META-INF/cxf/bus-extensions.xml
      - copied unchanged from r666723, cxf/trunk/rt/bindings/xml/src/main/resources/META-INF/bus-extensions.xml
    cxf/trunk/rt/bindings/xml/src/main/resources/META-INF/cxf/extensions.xml
      - copied unchanged from r666723, cxf/trunk/rt/bindings/xml/src/main/resources/META-INF/extensions.xml
    cxf/trunk/rt/core/src/main/resources/META-INF/cxf/bus-extensions.xml
      - copied unchanged from r666723, cxf/trunk/rt/core/src/main/resources/META-INF/bus-extensions.xml
    cxf/trunk/rt/frontend/jaxrs/src/main/resources/META-INF/cxf/bus-extensions.xml
      - copied unchanged from r666723, cxf/trunk/rt/frontend/jaxrs/src/main/resources/META-INF/bus-extensions.xml
    cxf/trunk/rt/management/src/main/resources/META-INF/cxf/bus-extensions.xml
      - copied unchanged from r666723, cxf/trunk/rt/management/src/main/resources/META-INF/bus-extensions.xml
    cxf/trunk/rt/transports/http-jetty/src/main/resources/META-INF/cxf/bus-extensions.xml
      - copied unchanged from r666723, cxf/trunk/rt/transports/http-jetty/src/main/resources/META-INF/bus-extensions.xml
    cxf/trunk/rt/transports/http/src/main/resources/META-INF/cxf/extensions.xml
      - copied unchanged from r666723, cxf/trunk/rt/transports/http/src/main/resources/META-INF/extensions.xml
    cxf/trunk/rt/transports/jbi/src/main/resources/META-INF/cxf/bus-extensions.xml
      - copied unchanged from r666723, cxf/trunk/rt/transports/jbi/src/main/resources/META-INF/bus-extensions.xml
    cxf/trunk/rt/transports/jbi/src/main/resources/META-INF/cxf/extensions.xml
      - copied unchanged from r666723, cxf/trunk/rt/transports/jbi/src/main/resources/META-INF/extensions.xml
    cxf/trunk/rt/transports/jms/src/main/resources/META-INF/cxf/bus-extensions.xml
      - copied unchanged from r666723, cxf/trunk/rt/transports/jms/src/main/resources/META-INF/bus-extensions.xml
    cxf/trunk/rt/transports/jms/src/main/resources/META-INF/cxf/extensions.xml
      - copied unchanged from r666723, cxf/trunk/rt/transports/jms/src/main/resources/META-INF/extensions.xml
    cxf/trunk/rt/ws/addr/src/main/resources/META-INF/cxf/extensions.xml
      - copied unchanged from r666723, cxf/trunk/rt/ws/addr/src/main/resources/META-INF/extensions.xml
Removed:
    cxf/trunk/rt/bindings/corba/src/main/resources/META-INF/bus-extensions.xml
    cxf/trunk/rt/bindings/corba/src/main/resources/META-INF/extensions.xml
    cxf/trunk/rt/bindings/http/src/main/resources/META-INF/bus-extensions.xml
    cxf/trunk/rt/bindings/jbi/src/main/resources/META-INF/bus-extensions.xml
    cxf/trunk/rt/bindings/object/src/main/resources/META-INF/bus-extensions.xml
    cxf/trunk/rt/bindings/soap/src/main/resources/META-INF/bus-extensions.xml
    cxf/trunk/rt/bindings/xml/src/main/resources/META-INF/bus-extensions.xml
    cxf/trunk/rt/bindings/xml/src/main/resources/META-INF/extensions.xml
    cxf/trunk/rt/core/src/main/resources/META-INF/bus-extensions.xml
    cxf/trunk/rt/frontend/jaxrs/src/main/resources/META-INF/bus-extensions.xml
    cxf/trunk/rt/management/src/main/resources/META-INF/bus-extensions.xml
    cxf/trunk/rt/transports/http-jetty/src/main/resources/META-INF/bus-extensions.xml
    cxf/trunk/rt/transports/http/src/main/resources/META-INF/extensions.xml
    cxf/trunk/rt/transports/jbi/src/main/resources/META-INF/bus-extensions.xml
    cxf/trunk/rt/transports/jbi/src/main/resources/META-INF/extensions.xml
    cxf/trunk/rt/transports/jms/src/main/resources/META-INF/bus-extensions.xml
    cxf/trunk/rt/transports/jms/src/main/resources/META-INF/extensions.xml
    cxf/trunk/rt/ws/addr/src/main/resources/META-INF/extensions.xml
Modified:
    cxf/trunk/distribution/bundle/pom.xml
    cxf/trunk/rt/core/src/main/java/org/apache/cxf/bus/extension/ExtensionManagerBus.java
    cxf/trunk/rt/core/src/main/java/org/apache/cxf/bus/extension/ExtensionManagerImpl.java
    cxf/trunk/rt/core/src/main/java/org/apache/cxf/wsdl11/WSDLManagerImpl.java

Modified: cxf/trunk/distribution/bundle/pom.xml
URL: http://svn.apache.org/viewvc/cxf/trunk/distribution/bundle/pom.xml?rev=666803&r1=666802&r2=666803&view=diff
==============================================================================
--- cxf/trunk/distribution/bundle/pom.xml (original)
+++ cxf/trunk/distribution/bundle/pom.xml Wed Jun 11 12:43:58 2008
@@ -361,8 +361,23 @@
                                     <resource>META-INF/extensions.xml</resource>
                                 </transformer>
                                 <transformer implementation="org.apache.maven.plugins.shade.resource.XmlAppendingTransformer">
+                                    <resource>META-INF/cxf/extensions.xml</resource>
+                                </transformer>
+                                <transformer implementation="org.apache.maven.plugins.shade.resource.XmlAppendingTransformer">
                                     <resource>META-INF/bus-extensions.xml</resource>
                                 </transformer>
+                                <transformer implementation="org.apache.maven.plugins.shade.resource.XmlAppendingTransformer">
+                                    <resource>META-INF/cxf/bus-extensions.xml</resource>
+                                </transformer>
+                                <transformer implementation="org.apache.maven.plugins.shade.resource.XmlAppendingTransformer">
+                                    <resource>META-INF/service.validator.xml</resource>
+                                </transformer>
+                                <transformer implementation="org.apache.maven.plugins.shade.resource.XmlAppendingTransformer">
+                                    <resource>META-INF/wsdl.plugin.xml</resource>
+                                </transformer>                     
+                                <transformer implementation="org.apache.maven.plugins.shade.resource.XmlAppendingTransformer">
+                                    <resource>META-INF/tools.service.validator.xml</resource>
+                                </transformer>                                    
      
                                 <transformer implementation="org.apache.cxf.maven.PluginTransformer">
                                     <resource>META-INF/tools-plugin.xml</resource>
                                 </transformer>

Modified: cxf/trunk/rt/core/src/main/java/org/apache/cxf/bus/extension/ExtensionManagerBus.java
URL: http://svn.apache.org/viewvc/cxf/trunk/rt/core/src/main/java/org/apache/cxf/bus/extension/ExtensionManagerBus.java?rev=666803&r1=666802&r2=666803&view=diff
==============================================================================
--- cxf/trunk/rt/core/src/main/java/org/apache/cxf/bus/extension/ExtensionManagerBus.java
(original)
+++ cxf/trunk/rt/core/src/main/java/org/apache/cxf/bus/extension/ExtensionManagerBus.java
Wed Jun 11 12:43:58 2008
@@ -54,8 +54,6 @@
     private static final String BUS_ID_PROPERTY_NAME = "org.apache.cxf.bus.id";
     
     
-    private static final String BUS_EXTENSION_RESOURCE = "META-INF/bus-extensions.xml";
-
     public ExtensionManagerBus(Map<Class, Object> e, Map<String, Object> properties)
{
         super(e);
 
@@ -85,7 +83,7 @@
         
         extensions.put(ResourceManager.class, resourceManager);
 
-        ExtensionManagerImpl em = new ExtensionManagerImpl(BUS_EXTENSION_RESOURCE, 
+        ExtensionManagerImpl em = new ExtensionManagerImpl(
                                  Thread.currentThread().getContextClassLoader(),
                                  extensions,
                                  resourceManager);

Modified: cxf/trunk/rt/core/src/main/java/org/apache/cxf/bus/extension/ExtensionManagerImpl.java
URL: http://svn.apache.org/viewvc/cxf/trunk/rt/core/src/main/java/org/apache/cxf/bus/extension/ExtensionManagerImpl.java?rev=666803&r1=666802&r2=666803&view=diff
==============================================================================
--- cxf/trunk/rt/core/src/main/java/org/apache/cxf/bus/extension/ExtensionManagerImpl.java
(original)
+++ cxf/trunk/rt/core/src/main/java/org/apache/cxf/bus/extension/ExtensionManagerImpl.java
Wed Jun 11 12:43:58 2008
@@ -42,7 +42,8 @@
     public static final String EXTENSIONMANAGER_PROPERTY_NAME = "extensionManager";
     public static final String ACTIVATION_NAMESPACES_PROPERTY_NAME = "activationNamespaces";
     public static final String ACTIVATION_NAMESPACES_SETTER_METHOD_NAME = "setActivationNamespaces";
-    public static final String BUS_EXTENSION_RESOURCE = "META-INF/bus-extensions.xml";
+    public static final String BUS_EXTENSION_RESOURCE_COMPAT = "META-INF/bus-extensions.xml";
+    public static final String BUS_EXTENSION_RESOURCE = "META-INF/cxf/bus-extensions.xml";
     
     private final ClassLoader loader;
     private ResourceManager resourceManager;
@@ -53,11 +54,18 @@
 
     public ExtensionManagerImpl(ClassLoader cl, Map<Class, Object> initialExtensions,

                                 ResourceManager rm) {
-        this(BUS_EXTENSION_RESOURCE, cl, initialExtensions, rm);
+        this(new String[] {BUS_EXTENSION_RESOURCE, BUS_EXTENSION_RESOURCE_COMPAT}, cl, initialExtensions,
rm);
     }
-    
-    public ExtensionManagerImpl(String resource, ClassLoader cl, Map<Class, Object>
initialExtensions, 
-        ResourceManager rm) {
+    public ExtensionManagerImpl(String resource, 
+                                ClassLoader cl, 
+                                Map<Class, Object> initialExtensions, 
+                                ResourceManager rm) {
+        this(new String[] {resource}, cl, initialExtensions, rm);
+    }    
+    public ExtensionManagerImpl(String resources[], 
+                                ClassLoader cl, 
+                                Map<Class, Object> initialExtensions, 
+                                ResourceManager rm) {
 
         loader = cl;
         activated = initialExtensions;
@@ -71,7 +79,9 @@
         deferred = new ConcurrentHashMap<String, Collection<Extension>>();
 
         try {
-            load(resource);
+            for (String resource : resources) {
+                load(resource);
+            }
         } catch (IOException ex) {
             throw new ExtensionException(ex);
         }

Modified: cxf/trunk/rt/core/src/main/java/org/apache/cxf/wsdl11/WSDLManagerImpl.java
URL: http://svn.apache.org/viewvc/cxf/trunk/rt/core/src/main/java/org/apache/cxf/wsdl11/WSDLManagerImpl.java?rev=666803&r1=666802&r2=666803&view=diff
==============================================================================
--- cxf/trunk/rt/core/src/main/java/org/apache/cxf/wsdl11/WSDLManagerImpl.java (original)
+++ cxf/trunk/rt/core/src/main/java/org/apache/cxf/wsdl11/WSDLManagerImpl.java Wed Jun 11
12:43:58 2008
@@ -69,7 +69,8 @@
 
     private static final Logger LOG = LogUtils.getL7dLogger(WSDLManagerImpl.class);
 
-    private static final String EXTENSIONS_RESOURCE = "META-INF/extensions.xml";
+    private static final String EXTENSIONS_RESOURCE = "META-INF/cxf/extensions.xml";
+    private static final String EXTENSIONS_RESOURCE_COMPAT = "META-INF/extensions.xml";
 
     final ExtensionRegistry registry;
     final WSDLFactory factory;
@@ -216,9 +217,13 @@
     }
 
     private void registerInitialExtensions() throws BusException {
+        registerInitialExtensions(EXTENSIONS_RESOURCE_COMPAT);
+        registerInitialExtensions(EXTENSIONS_RESOURCE);
+    }
+    private void registerInitialExtensions(String resource) throws BusException {
         Properties initialExtensions = null;
         try {
-            initialExtensions = PropertiesLoaderUtils.loadAllProperties(EXTENSIONS_RESOURCE,

+            initialExtensions = PropertiesLoaderUtils.loadAllProperties(resource, 
                                                                         Thread.currentThread()
                                                                               .getContextClassLoader());
         } catch (IOException ex) {



Mime
View raw message