cxf-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From dk...@apache.org
Subject svn commit: r1071451 [1/2] - in /cxf/trunk: api/src/main/java/org/apache/cxf/extension/ api/src/main/java/org/apache/cxf/wsdl/ common/xerces-xsd-validation/src/main/resources/META-INF/cxf/ rt/bindings/corba/src/main/java/org/apache/cxf/binding/corba/ws...
Date Thu, 17 Feb 2011 00:01:27 GMT
Author: dkulp
Date: Thu Feb 17 00:01:25 2011
New Revision: 1071451

URL: http://svn.apache.org/viewvc?rev=1071451&view=rev
Log:
Update ExtensionBus and extension to use the ConfiguredBeanLocator
Remove the changes to wsdl extension loading I made yesterday and
replace with mechanism already in place.
Make sure ALL functionaliy of Spring bus works with non-spring bus
If NO spring config or context is being used, use the extension bus.

Added:
    cxf/trunk/rt/bindings/xml/src/main/java/org/apache/cxf/binding/xml/wsdl11/XMLWSDLExtensionLoader.java   (with props)
    cxf/trunk/rt/frontend/jaxws/src/main/resources/META-INF/cxf/bus-extensions.xml
      - copied, changed from r1071449, cxf/trunk/common/xerces-xsd-validation/src/main/resources/META-INF/cxf/bus-extensions.xml
    cxf/trunk/rt/transports/http/src/main/java/org/apache/cxf/transport/http/HTTPWSDLExtensionLoader.java   (with props)
    cxf/trunk/rt/transports/jbi/src/main/java/org/apache/cxf/transport/jbi/wsdl11/JBIWSDLExtensionLoader.java   (with props)
    cxf/trunk/rt/transports/jms/src/main/java/org/apache/cxf/transport/jms/wsdl11/JMSWSDLExtensionLoader.java   (with props)
    cxf/trunk/rt/transports/local/src/main/resources/META-INF/cxf/bus-extensions.xml
      - copied, changed from r1071449, cxf/trunk/rt/frontend/jaxrs/src/main/resources/META-INF/cxf/bus-extensions.xml
    cxf/trunk/rt/ws/addr/src/main/java/org/apache/cxf/ws/addressing/AddressingWSDLExtensionLoader.java   (with props)
    cxf/trunk/rt/ws/addr/src/main/resources/META-INF/cxf/bus-extensions.xml
      - copied, changed from r1071449, cxf/trunk/rt/transports/jms/src/main/resources/META-INF/cxf/bus-extensions.xml
    cxf/trunk/rt/ws/policy/src/main/resources/META-INF/cxf/bus-extensions.xml   (with props)
    cxf/trunk/rt/ws/rm/src/main/resources/META-INF/cxf/bus-extensions.xml   (contents, props changed)
      - copied, changed from r1071449, cxf/trunk/rt/frontend/jaxrs/src/main/resources/META-INF/cxf/bus-extensions.xml
    cxf/trunk/rt/ws/security/src/main/resources/META-INF/cxf/bus-extensions.xml
      - copied, changed from r1071449, cxf/trunk/common/xerces-xsd-validation/src/main/resources/META-INF/cxf/bus-extensions.xml
Removed:
    cxf/trunk/rt/bindings/corba/src/main/resources/META-INF/cxf/wsdl-extensions.txt
    cxf/trunk/rt/bindings/xml/src/main/resources/META-INF/cxf/wsdl-extensions.txt
    cxf/trunk/rt/frontend/jaxrs/src/main/resources/META-INF/cxf/bus-extensions.xml
    cxf/trunk/rt/transports/http/src/main/resources/META-INF/cxf/wsdl-extensions.txt
    cxf/trunk/rt/transports/jbi/src/main/resources/META-INF/cxf/wsdl-extensions.txt
    cxf/trunk/rt/transports/jms/src/main/resources/META-INF/cxf/wsdl-extensions.txt
    cxf/trunk/rt/ws/addr/src/main/resources/META-INF/cxf/wsdl-extensions.txt
Modified:
    cxf/trunk/api/src/main/java/org/apache/cxf/extension/RegistryImpl.java
    cxf/trunk/api/src/main/java/org/apache/cxf/wsdl/JAXBExtensionHelper.java
    cxf/trunk/common/xerces-xsd-validation/src/main/resources/META-INF/cxf/bus-extensions.xml
    cxf/trunk/rt/bindings/corba/src/main/java/org/apache/cxf/binding/corba/wsdl/WSDLExtensionRegister.java
    cxf/trunk/rt/bindings/corba/src/main/resources/META-INF/cxf/bus-extensions.xml
    cxf/trunk/rt/bindings/object/src/main/java/org/apache/cxf/binding/object/ObjectBindingFactory.java
    cxf/trunk/rt/bindings/object/src/main/resources/META-INF/cxf/bus-extensions.xml
    cxf/trunk/rt/bindings/soap/src/main/resources/META-INF/cxf/bus-extensions.xml
    cxf/trunk/rt/bindings/xml/src/main/resources/META-INF/cxf/bus-extensions.xml
    cxf/trunk/rt/bindings/xml/src/main/resources/META-INF/cxf/cxf-extension-xml.xml
    cxf/trunk/rt/bindings/xml/src/test/java/org/apache/cxf/binding/xml/interceptor/TestBase.java
    cxf/trunk/rt/core/src/main/java/org/apache/cxf/bus/extension/DeferredMap.java
    cxf/trunk/rt/core/src/main/java/org/apache/cxf/bus/extension/ExtensionManager.java
    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/bus/spring/BusApplicationContext.java
    cxf/trunk/rt/core/src/main/java/org/apache/cxf/bus/spring/SpringBusFactory.java
    cxf/trunk/rt/core/src/main/java/org/apache/cxf/service/factory/FactoryBeanListenerManager.java
    cxf/trunk/rt/core/src/main/java/org/apache/cxf/wsdl11/WSDLManagerImpl.java
    cxf/trunk/rt/core/src/main/resources/META-INF/cxf/bus-extensions.xml
    cxf/trunk/rt/core/src/test/java/org/apache/cxf/bus/extension/ExtensionManagerTest.java
    cxf/trunk/rt/frontend/jaxws/src/test/java/org/apache/cxf/jaxws/AbstractJaxWsTest.java
    cxf/trunk/rt/transports/http/src/main/resources/META-INF/cxf/bus-extensions.xml
    cxf/trunk/rt/transports/http/src/main/resources/META-INF/cxf/cxf-extension-http.xml
    cxf/trunk/rt/transports/jbi/src/main/resources/META-INF/cxf/bus-extensions.xml
    cxf/trunk/rt/transports/jbi/src/main/resources/META-INF/cxf/cxf-extension-jbi.xml
    cxf/trunk/rt/transports/jms/src/main/resources/META-INF/cxf/bus-extensions.xml
    cxf/trunk/rt/transports/jms/src/main/resources/META-INF/cxf/cxf-extension-jms.xml
    cxf/trunk/rt/ws/addr/src/main/resources/META-INF/cxf/cxf-extension-addr.xml
    cxf/trunk/rt/ws/policy/src/main/java/org/apache/cxf/ws/policy/AssertionBuilderRegistryImpl.java
    cxf/trunk/rt/ws/policy/src/main/java/org/apache/cxf/ws/policy/PolicyBuilderImpl.java
    cxf/trunk/rt/ws/policy/src/main/java/org/apache/cxf/ws/policy/PolicyInterceptorProviderRegistryImpl.java
    cxf/trunk/rt/ws/policy/src/main/java/org/apache/cxf/ws/policy/attachment/external/DomainExpressionBuilderRegistry.java
    cxf/trunk/rt/ws/policy/src/main/resources/META-INF/cxf/cxf-extension-policy.xml
    cxf/trunk/rt/ws/security/src/main/java/org/apache/cxf/ws/security/policy/WSSecurityPolicyLoader.java
    cxf/trunk/systests/jaxws/src/test/java/org/apache/cxf/systest/jaxws/DocLitWrappedCodeFirstServiceImpl.java

Modified: cxf/trunk/api/src/main/java/org/apache/cxf/extension/RegistryImpl.java
URL: http://svn.apache.org/viewvc/cxf/trunk/api/src/main/java/org/apache/cxf/extension/RegistryImpl.java?rev=1071451&r1=1071450&r2=1071451&view=diff
==============================================================================
--- cxf/trunk/api/src/main/java/org/apache/cxf/extension/RegistryImpl.java (original)
+++ cxf/trunk/api/src/main/java/org/apache/cxf/extension/RegistryImpl.java Thu Feb 17 00:01:25 2011
@@ -41,7 +41,9 @@ public class RegistryImpl<K, T> implemen
         }
         entries = e;
     }
-    
+
+    protected void loadDynamic() {
+    }
 
     public void register(K k, T t) {
         entries.put(k, t);
@@ -52,6 +54,7 @@ public class RegistryImpl<K, T> implemen
     }
 
     public T get(K k) {
+        loadDynamic();
         return entries.get(k);
     }
 

Modified: cxf/trunk/api/src/main/java/org/apache/cxf/wsdl/JAXBExtensionHelper.java
URL: http://svn.apache.org/viewvc/cxf/trunk/api/src/main/java/org/apache/cxf/wsdl/JAXBExtensionHelper.java?rev=1071451&r1=1071450&r2=1071451&view=diff
==============================================================================
--- cxf/trunk/api/src/main/java/org/apache/cxf/wsdl/JAXBExtensionHelper.java (original)
+++ cxf/trunk/api/src/main/java/org/apache/cxf/wsdl/JAXBExtensionHelper.java Thu Feb 17 00:01:25 2011
@@ -94,14 +94,14 @@ public class JAXBExtensionHelper impleme
         throws JAXBException, ClassNotFoundException {
         Class<?> parentTypeClass = ClassLoaderUtils.loadClass(parentType, JAXBExtensionHelper.class);
 
-        Class<? extends TExtensibilityElementImpl> elementTypeClass = 
+        Class<? extends ExtensibilityElement> elementTypeClass = 
             ClassLoaderUtils.loadClass(elementType, JAXBExtensionHelper.class)
-                .asSubclass(TExtensibilityElementImpl.class);
+                .asSubclass(ExtensibilityElement.class);
         addExtensions(registry, parentTypeClass, elementTypeClass, namespace);
     }
     public static void addExtensions(ExtensionRegistry registry,
                                      Class<?> parentType,
-                                     Class<? extends TExtensibilityElementImpl> cls)
+                                     Class<? extends ExtensibilityElement> cls)
         throws JAXBException {
         addExtensions(registry, parentType, cls, null);
     }

Modified: cxf/trunk/common/xerces-xsd-validation/src/main/resources/META-INF/cxf/bus-extensions.xml
URL: http://svn.apache.org/viewvc/cxf/trunk/common/xerces-xsd-validation/src/main/resources/META-INF/cxf/bus-extensions.xml?rev=1071451&r1=1071450&r2=1071451&view=diff
==============================================================================
--- cxf/trunk/common/xerces-xsd-validation/src/main/resources/META-INF/cxf/bus-extensions.xml (original)
+++ cxf/trunk/common/xerces-xsd-validation/src/main/resources/META-INF/cxf/bus-extensions.xml Thu Feb 17 00:01:25 2011
@@ -19,5 +19,5 @@
 -->
 <extensions xmlns="http://cxf.apache.org/bus/extension">
     <extension class="org.apache.cxf.xsdvalidation.XercesXsdValidationImpl"
-           interface="org.apache.cxf.common.xmlschema.XmlSchemaValidationManager"/>
+           interface="org.apache.cxf.common.xmlschema.XmlSchemaValidationManager" deferred="true"/>
 </extensions>

Modified: cxf/trunk/rt/bindings/corba/src/main/java/org/apache/cxf/binding/corba/wsdl/WSDLExtensionRegister.java
URL: http://svn.apache.org/viewvc/cxf/trunk/rt/bindings/corba/src/main/java/org/apache/cxf/binding/corba/wsdl/WSDLExtensionRegister.java?rev=1071451&r1=1071450&r2=1071451&view=diff
==============================================================================
--- cxf/trunk/rt/bindings/corba/src/main/java/org/apache/cxf/binding/corba/wsdl/WSDLExtensionRegister.java (original)
+++ cxf/trunk/rt/bindings/corba/src/main/java/org/apache/cxf/binding/corba/wsdl/WSDLExtensionRegister.java Thu Feb 17 00:01:25 2011
@@ -36,11 +36,24 @@ public final class WSDLExtensionRegister
     private static final String YOKO_NAMESPACE = "http://schemas.apache.org/yoko/bindings/corba";
     
     public WSDLExtensionRegister(Bus b) {
-        registerYokoCompatibleExtensors(b);
+        WSDLManager manager = b.getExtension(WSDLManager.class);
+        registerCXFExtensors(manager);
+        registerYokoCompatibleExtensors(manager);
     }
     
-    void registerYokoCompatibleExtensors(Bus bus) {
-        WSDLManager manager = bus.getExtension(WSDLManager.class);
+    void registerCXFExtensors(WSDLManager manager) {
+        createExtensor(manager, javax.wsdl.Binding.class,
+                             org.apache.cxf.binding.corba.wsdl.BindingType.class);
+        createExtensor(manager, javax.wsdl.BindingOperation.class,
+                             org.apache.cxf.binding.corba.wsdl.OperationType.class);
+        createExtensor(manager, javax.wsdl.Definition.class,
+                             org.apache.cxf.binding.corba.wsdl.TypeMappingType.class);
+        createExtensor(manager, javax.wsdl.Port.class,
+                             org.apache.cxf.binding.corba.wsdl.AddressType.class);
+        createExtensor(manager, javax.wsdl.Port.class,
+                             org.apache.cxf.binding.corba.wsdl.PolicyType.class);
+    }
+    void registerYokoCompatibleExtensors(WSDLManager manager) {
         createCompatExtensor(manager, javax.wsdl.Binding.class,
                              org.apache.cxf.binding.corba.wsdl.BindingType.class);
         createCompatExtensor(manager, javax.wsdl.BindingOperation.class,
@@ -52,6 +65,18 @@ public final class WSDLExtensionRegister
         createCompatExtensor(manager, javax.wsdl.Port.class,
                              org.apache.cxf.binding.corba.wsdl.PolicyType.class);
     }
+    private void createExtensor(WSDLManager manager,
+                                Class<?> parentType,
+                                Class<? extends TExtensibilityElementImpl> elementType) {
+        try {
+            JAXBExtensionHelper.addExtensions(manager.getExtensionRegistry(),
+                                              parentType, 
+                                              elementType);
+        } catch (JAXBException e) {
+            //ignore, won't support CORBA
+        }
+        
+    }
 
     private void createCompatExtensor(WSDLManager manager,
                                       Class<?> parentType,

Modified: cxf/trunk/rt/bindings/corba/src/main/resources/META-INF/cxf/bus-extensions.xml
URL: http://svn.apache.org/viewvc/cxf/trunk/rt/bindings/corba/src/main/resources/META-INF/cxf/bus-extensions.xml?rev=1071451&r1=1071450&r2=1071451&view=diff
==============================================================================
--- cxf/trunk/rt/bindings/corba/src/main/resources/META-INF/cxf/bus-extensions.xml (original)
+++ cxf/trunk/rt/bindings/corba/src/main/resources/META-INF/cxf/bus-extensions.xml Thu Feb 17 00:01:25 2011
@@ -23,5 +23,6 @@
         <namespace>http://cxf.apache.org/bindings/corba</namespace>
         <namespace>http://schemas.apache.org/yoko/bindings/corba</namespace>
     </extension>
+    <extension class="org.apache.cxf.binding.corba.wsdl.WSDLExtensionRegister" deferred="true"/>
 
 </extensions>

Modified: cxf/trunk/rt/bindings/object/src/main/java/org/apache/cxf/binding/object/ObjectBindingFactory.java
URL: http://svn.apache.org/viewvc/cxf/trunk/rt/bindings/object/src/main/java/org/apache/cxf/binding/object/ObjectBindingFactory.java?rev=1071451&r1=1071450&r2=1071451&view=diff
==============================================================================
--- cxf/trunk/rt/bindings/object/src/main/java/org/apache/cxf/binding/object/ObjectBindingFactory.java (original)
+++ cxf/trunk/rt/bindings/object/src/main/java/org/apache/cxf/binding/object/ObjectBindingFactory.java Thu Feb 17 00:01:25 2011
@@ -38,6 +38,13 @@ public class ObjectBindingFactory extend
     private boolean initialized = true;
     private LocalServerListener listener;
     
+    public ObjectBindingFactory() {
+        
+    }
+    public ObjectBindingFactory(Bus b) {
+        super(b);
+    }
+    
     @PostConstruct
     public void initialize() {
         if (autoRegisterLocalEndpoint) {

Modified: cxf/trunk/rt/bindings/object/src/main/resources/META-INF/cxf/bus-extensions.xml
URL: http://svn.apache.org/viewvc/cxf/trunk/rt/bindings/object/src/main/resources/META-INF/cxf/bus-extensions.xml?rev=1071451&r1=1071450&r2=1071451&view=diff
==============================================================================
--- cxf/trunk/rt/bindings/object/src/main/resources/META-INF/cxf/bus-extensions.xml (original)
+++ cxf/trunk/rt/bindings/object/src/main/resources/META-INF/cxf/bus-extensions.xml Thu Feb 17 00:01:25 2011
@@ -19,9 +19,8 @@
 -->
 <extensions xmlns="http://cxf.apache.org/bus/extension">
 
-    <extension class="org.apache.cxf.binding.object.ObjectBindingFactory" 
-      interface="org.apache.cxf.binding.BindingFactory" deferred="true">
-        <namespace>http://cxf.apache.org/binding/object/</namespace>
+    <extension class="org.apache.cxf.binding.object.ObjectBindingFactory" deferred="true">
+        <namespace>http://cxf.apache.org/binding/object</namespace>
     </extension>
     
 </extensions>

Modified: cxf/trunk/rt/bindings/soap/src/main/resources/META-INF/cxf/bus-extensions.xml
URL: http://svn.apache.org/viewvc/cxf/trunk/rt/bindings/soap/src/main/resources/META-INF/cxf/bus-extensions.xml?rev=1071451&r1=1071450&r2=1071451&view=diff
==============================================================================
--- cxf/trunk/rt/bindings/soap/src/main/resources/META-INF/cxf/bus-extensions.xml (original)
+++ cxf/trunk/rt/bindings/soap/src/main/resources/META-INF/cxf/bus-extensions.xml Thu Feb 17 00:01:25 2011
@@ -19,23 +19,23 @@
 -->
 <extensions xmlns="http://cxf.apache.org/bus/extension">
 
-    <extension class="org.apache.cxf.binding.soap.SoapBindingFactory" 
-      interface="org.apache.cxf.binding.BindingFactory" deferred="true">
+    <extension class="org.apache.cxf.binding.soap.SoapBindingFactory" deferred="true">
         <namespace>http://schemas.xmlsoap.org/soap/</namespace>
         <namespace>http://schemas.xmlsoap.org/wsdl/soap/</namespace>
         <namespace>http://schemas.xmlsoap.org/wsdl/soap12/</namespace>
+        <namespace>http://schemas.xmlsoap.org/wsdl/soap/http</namespace>
         <namespace>http://www.w3.org/2003/05/soap/bindings/HTTP/</namespace>
         <namespace>http://www.w3.org/2010/soapjms/</namespace>
-        <namespace>http://schemas.xmlsoap.org/wsdl/soap/http</namespace>
-        <namespace>http://schemas.xmlsoap.org/soap/http</namespace>
     </extension>
     
-    <extension class="org.apache.cxf.binding.soap.SoapTransportFactory" 
-      interface="org.apache.cxf.transport.DestinationFactory" deferred="true">
+    <extension class="org.apache.cxf.binding.soap.SoapTransportFactory" deferred="true">
         <namespace>http://schemas.xmlsoap.org/soap/</namespace>
         <namespace>http://schemas.xmlsoap.org/wsdl/soap/</namespace>
         <namespace>http://schemas.xmlsoap.org/wsdl/soap12/</namespace>
-        <namespace>http://schemas.xmlsoap.org/soap/http</namespace>
         <namespace>http://schemas.xmlsoap.org/soap/http/</namespace>
+        <namespace>http://schemas.xmlsoap.org/wsdl/soap/http</namespace>
+        <namespace>http://www.w3.org/2010/soapjms/</namespace>
+        <namespace>http://www.w3.org/2003/05/soap/bindings/HTTP/</namespace>
+        <namespace>http://schemas.xmlsoap.org/soap/http</namespace>
     </extension>    
 </extensions>

Added: cxf/trunk/rt/bindings/xml/src/main/java/org/apache/cxf/binding/xml/wsdl11/XMLWSDLExtensionLoader.java
URL: http://svn.apache.org/viewvc/cxf/trunk/rt/bindings/xml/src/main/java/org/apache/cxf/binding/xml/wsdl11/XMLWSDLExtensionLoader.java?rev=1071451&view=auto
==============================================================================
--- cxf/trunk/rt/bindings/xml/src/main/java/org/apache/cxf/binding/xml/wsdl11/XMLWSDLExtensionLoader.java (added)
+++ cxf/trunk/rt/bindings/xml/src/main/java/org/apache/cxf/binding/xml/wsdl11/XMLWSDLExtensionLoader.java Thu Feb 17 00:01:25 2011
@@ -0,0 +1,66 @@
+/**
+ * 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.binding.xml.wsdl11;
+
+import javax.xml.bind.JAXBException;
+
+import org.apache.cxf.Bus;
+import org.apache.cxf.common.injection.NoJSR250Annotations;
+import org.apache.cxf.wsdl.JAXBExtensionHelper;
+import org.apache.cxf.wsdl.TExtensibilityElementImpl;
+import org.apache.cxf.wsdl.WSDLExtensionLoader;
+import org.apache.cxf.wsdl.WSDLManager;
+
+/**
+ * 
+ */
+@NoJSR250Annotations
+public final class XMLWSDLExtensionLoader implements WSDLExtensionLoader { 
+    
+    public XMLWSDLExtensionLoader(Bus b) {
+        setupBus(b);
+    }
+    public void setupBus(Bus b) {
+        WSDLManager manager = b.getExtension(WSDLManager.class);
+        registerExtensors(manager);
+    }
+    
+    public static void registerExtensors(WSDLManager manager) {
+        createExtensor(manager, javax.wsdl.BindingInput.class,
+                       org.apache.cxf.bindings.xformat.XMLBindingMessageFormat.class);
+        createExtensor(manager, javax.wsdl.BindingOutput.class, 
+                       org.apache.cxf.bindings.xformat.XMLBindingMessageFormat.class);
+        createExtensor(manager, javax.wsdl.Binding.class,
+                       org.apache.cxf.bindings.xformat.XMLFormatBinding.class);
+    }
+    
+    public static void createExtensor(WSDLManager manager,
+                                Class<?> parentType,
+                                Class<? extends TExtensibilityElementImpl> elementType) {
+        try {
+            JAXBExtensionHelper.addExtensions(manager.getExtensionRegistry(),
+                                              parentType, 
+                                              elementType);
+        } catch (JAXBException e) {
+            //ignore, won't support XML
+        }
+    }
+
+}

Propchange: cxf/trunk/rt/bindings/xml/src/main/java/org/apache/cxf/binding/xml/wsdl11/XMLWSDLExtensionLoader.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: cxf/trunk/rt/bindings/xml/src/main/java/org/apache/cxf/binding/xml/wsdl11/XMLWSDLExtensionLoader.java
------------------------------------------------------------------------------
    svn:keywords = Rev Date

Modified: cxf/trunk/rt/bindings/xml/src/main/resources/META-INF/cxf/bus-extensions.xml
URL: http://svn.apache.org/viewvc/cxf/trunk/rt/bindings/xml/src/main/resources/META-INF/cxf/bus-extensions.xml?rev=1071451&r1=1071450&r2=1071451&view=diff
==============================================================================
--- cxf/trunk/rt/bindings/xml/src/main/resources/META-INF/cxf/bus-extensions.xml (original)
+++ cxf/trunk/rt/bindings/xml/src/main/resources/META-INF/cxf/bus-extensions.xml Thu Feb 17 00:01:25 2011
@@ -24,5 +24,6 @@
         <namespace>http://www.w3.org/2004/08/wsdl/http</namespace>  
         <namespace>http://schemas.xmlsoap.org/wsdl/http/</namespace>       
     </extension>
+    <extension class="org.apache.cxf.binding.xml.wsdl11.XMLWSDLExtensionLoader" deferred="true"/>
     
 </extensions>

Modified: cxf/trunk/rt/bindings/xml/src/main/resources/META-INF/cxf/cxf-extension-xml.xml
URL: http://svn.apache.org/viewvc/cxf/trunk/rt/bindings/xml/src/main/resources/META-INF/cxf/cxf-extension-xml.xml?rev=1071451&r1=1071450&r2=1071451&view=diff
==============================================================================
--- cxf/trunk/rt/bindings/xml/src/main/resources/META-INF/cxf/cxf-extension-xml.xml (original)
+++ cxf/trunk/rt/bindings/xml/src/main/resources/META-INF/cxf/cxf-extension-xml.xml Thu Feb 17 00:01:25 2011
@@ -35,5 +35,10 @@ http://www.springframework.org/schema/be
         </property>
         <property name="bus" ref="cxf"/>
     </bean>
+    <bean class="org.apache.cxf.binding.xml.wsdl11.XMLWSDLExtensionLoader"
+      id="org.apache.cxf.binding.xml.wsdl11.XMLWSDLExtensionLoader"
+      lazy-init="true">
+      <constructor-arg ref="cxf"/>
+    </bean>
     
 </beans>

Modified: cxf/trunk/rt/bindings/xml/src/test/java/org/apache/cxf/binding/xml/interceptor/TestBase.java
URL: http://svn.apache.org/viewvc/cxf/trunk/rt/bindings/xml/src/test/java/org/apache/cxf/binding/xml/interceptor/TestBase.java?rev=1071451&r1=1071450&r2=1071451&view=diff
==============================================================================
--- cxf/trunk/rt/bindings/xml/src/test/java/org/apache/cxf/binding/xml/interceptor/TestBase.java (original)
+++ cxf/trunk/rt/bindings/xml/src/test/java/org/apache/cxf/binding/xml/interceptor/TestBase.java Thu Feb 17 00:01:25 2011
@@ -34,6 +34,7 @@ import org.apache.cxf.Bus;
 import org.apache.cxf.binding.Binding;
 import org.apache.cxf.binding.BindingFactoryManager;
 import org.apache.cxf.binding.xml.XMLBindingFactory;
+import org.apache.cxf.binding.xml.wsdl11.XMLWSDLExtensionLoader;
 import org.apache.cxf.endpoint.Endpoint;
 import org.apache.cxf.endpoint.EndpointImpl;
 import org.apache.cxf.jaxb.JAXBDataBinding;
@@ -116,7 +117,10 @@ public class TestBase extends Assert {
         control = EasyMock.createNiceControl();
         
         bus = control.createMock(Bus.class);
-        EasyMock.expect(bus.getExtension(WSDLManager.class)).andStubReturn(new WSDLManagerImpl());
+        
+        WSDLManagerImpl manager = new WSDLManagerImpl();
+        XMLWSDLExtensionLoader.registerExtensors(manager);
+        EasyMock.expect(bus.getExtension(WSDLManager.class)).andStubReturn(manager);
         
         BindingFactoryManager bindingFactoryManager = control.createMock(BindingFactoryManager.class);
         EasyMock.expect(bus.getExtension(BindingFactoryManager.class)).andStubReturn(bindingFactoryManager);

Modified: cxf/trunk/rt/core/src/main/java/org/apache/cxf/bus/extension/DeferredMap.java
URL: http://svn.apache.org/viewvc/cxf/trunk/rt/core/src/main/java/org/apache/cxf/bus/extension/DeferredMap.java?rev=1071451&r1=1071450&r2=1071451&view=diff
==============================================================================
--- cxf/trunk/rt/core/src/main/java/org/apache/cxf/bus/extension/DeferredMap.java (original)
+++ cxf/trunk/rt/core/src/main/java/org/apache/cxf/bus/extension/DeferredMap.java Thu Feb 17 00:01:25 2011
@@ -44,7 +44,7 @@ public class DeferredMap<V> extends Conc
 
         if (v == null) {
             String k = (String)key;
-            em.activateViaNS(k);
+            em.activateViaNS(k, type);
 
             v = em.getExtension(k, type);
             if (v != null) {

Modified: cxf/trunk/rt/core/src/main/java/org/apache/cxf/bus/extension/ExtensionManager.java
URL: http://svn.apache.org/viewvc/cxf/trunk/rt/core/src/main/java/org/apache/cxf/bus/extension/ExtensionManager.java?rev=1071451&r1=1071450&r2=1071451&view=diff
==============================================================================
--- cxf/trunk/rt/core/src/main/java/org/apache/cxf/bus/extension/ExtensionManager.java (original)
+++ cxf/trunk/rt/core/src/main/java/org/apache/cxf/bus/extension/ExtensionManager.java Thu Feb 17 00:01:25 2011
@@ -24,7 +24,7 @@ public interface ExtensionManager {
     
     <T> void activateAllByType(Class<T> type);
     
-    void activateViaNS(String namespace);
+    void activateViaNS(String namespace, Class<?> type);
     
     <T> T getExtension(String ns, Class<T> type);
 }

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=1071451&r1=1071450&r2=1071451&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 Thu Feb 17 00:01:25 2011
@@ -100,10 +100,6 @@ public class ExtensionManagerBus extends
                                   
         setState(BusState.INITIAL);
         
-        BusLifeCycleManager lifeCycleManager = this.getExtension(BusLifeCycleManager.class);
-        if (null != lifeCycleManager) {
-            lifeCycleManager.initComplete();
-        }
 
         DestinationFactoryManager dfm = this.getExtension(DestinationFactoryManager.class);
         if (null == dfm) {
@@ -130,8 +126,15 @@ public class ExtensionManagerBus extends
             ExtensionManagerImpl.BUS_EXTENSION_RESOURCE,
             ExtensionManagerImpl.BUS_EXTENSION_RESOURCE_COMPAT});
         
+        extensionManager.activateAllByType(ResourceResolver.class);
+        
         
         this.setExtension(extensionManager, ExtensionManager.class);
+        
+        BusLifeCycleManager lifeCycleManager = this.getExtension(BusLifeCycleManager.class);
+        if (null != lifeCycleManager) {
+            lifeCycleManager.initComplete();
+        }
     }
 
     public ExtensionManagerBus() {

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=1071451&r1=1071450&r2=1071451&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 Thu Feb 17 00:01:25 2011
@@ -27,6 +27,7 @@ import java.util.ArrayList;
 import java.util.Collection;
 import java.util.Enumeration;
 import java.util.Iterator;
+import java.util.LinkedList;
 import java.util.List;
 import java.util.Map;
 import java.util.concurrent.ConcurrentHashMap;
@@ -48,6 +49,9 @@ public class ExtensionManagerImpl implem
     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 static final String NO_NAMESPACES = "NO_NAMESPACE_BEANS";
+    
+    
     private final ClassLoader loader;
     private ResourceManager resourceManager;
     private Map<String, Collection<Extension>> deferred;
@@ -100,21 +104,27 @@ public class ExtensionManagerImpl implem
         }
     }
 
-    public synchronized void activateViaNS(String namespaceURI) {
+    public synchronized void activateViaNS(String namespaceURI, Class<?> type) {
         Collection<Extension> extensions = deferred.get(namespaceURI);
         if (null == extensions) {
             return;
         }
-        for (Extension e : extensions) {
-            loadAndRegister(e);
+        Iterator<Extension> it = extensions.iterator();
+        while (it.hasNext()) {
+            Extension e = it.next();
+            if (type == null || type.isAssignableFrom(e.getClassObject(loader))) {
+                loadAndRegister(e);
+                extensions.remove(e);
+            }
+        }
+        if (extensions.isEmpty()) {
+            deferred.remove(namespaceURI);
         }
-        extensions.clear();
-        deferred.remove(namespaceURI);
     }
     
     public synchronized void activateAll() {
         while (!deferred.isEmpty()) {
-            activateViaNS(deferred.keySet().iterator().next());
+            activateViaNS(deferred.keySet().iterator().next(), null);
         }
     }
     public synchronized <T> void activateAllByType(Class<T> type) {
@@ -136,28 +146,34 @@ public class ExtensionManagerImpl implem
     
     final void load(String resource) throws IOException {
         Enumeration<URL> urls = Thread.currentThread().getContextClassLoader().getResources(resource);
+        List<Extension> all = new LinkedList<Extension>();
         while (urls.hasMoreElements()) {
             URL url = urls.nextElement();
             
             InputStream is = url.openStream();
-            loadFragment(is);       
+            all.addAll(new ExtensionFragmentParser().getExtensions(is));       
         }
-        
-    }
-
-    final void loadFragment(InputStream is) {
-        List<Extension> extensions = new ExtensionFragmentParser().getExtensions(is);
-        for (Extension e : extensions) {
-            processExtension(e);
+        for (Extension e : all) {
+            if (e.isDeferred()) {
+                addDeferred(e);
+            }
+        }
+        for (Extension e : all) {
+            if (!e.isDeferred()) {
+                loadAndRegister(e);
+            }
         }
     }
-
-    final void processExtension(Extension e) {
-        
-        if (!e.isDeferred()) {
-            loadAndRegister(e);
+    final void addDeferred(Extension e) {
+        Collection<String> namespaces = e.getNamespaces();
+        if (namespaces.isEmpty()) {
+            Collection<Extension> extensions = deferred.get(NO_NAMESPACES);
+            if (null == extensions) {
+                extensions = new CopyOnWriteArrayList<Extension>();
+                deferred.put(NO_NAMESPACES, extensions);
+            }
+            extensions.add(e);
         } else {
-            Collection<String> namespaces = e.getNamespaces();
             for (String ns : namespaces) {
                 Collection<Extension> extensions = deferred.get(ns);
                 if (null == extensions) {
@@ -168,7 +184,6 @@ public class ExtensionManagerImpl implem
             }
         }
     }
-    
     final void loadAndRegister(Extension e) {
         
         Class<?> cls = null;

Modified: cxf/trunk/rt/core/src/main/java/org/apache/cxf/bus/spring/BusApplicationContext.java
URL: http://svn.apache.org/viewvc/cxf/trunk/rt/core/src/main/java/org/apache/cxf/bus/spring/BusApplicationContext.java?rev=1071451&r1=1071450&r2=1071451&view=diff
==============================================================================
--- cxf/trunk/rt/core/src/main/java/org/apache/cxf/bus/spring/BusApplicationContext.java (original)
+++ cxf/trunk/rt/core/src/main/java/org/apache/cxf/bus/spring/BusApplicationContext.java Thu Feb 17 00:01:25 2011
@@ -191,7 +191,7 @@ public class BusApplicationContext exten
         return res;
     }
     
-    protected Resource findResource(String cfgFile) {
+    public static Resource findResource(String cfgFile) {
         Resource cpr = new ClassPathResource(cfgFile);
         if (cpr.exists()) {
             return cpr;
@@ -207,7 +207,7 @@ public class BusApplicationContext exten
             //ignore
         }
         //try loading it our way
-        URL url = ClassLoaderUtils.getResource(cfgFile, this.getClass());
+        URL url = ClassLoaderUtils.getResource(cfgFile, BusApplicationContext.class);
         if (url != null) {
             cpr = new UrlResource(url);
             if (cpr.exists()) {

Modified: cxf/trunk/rt/core/src/main/java/org/apache/cxf/bus/spring/SpringBusFactory.java
URL: http://svn.apache.org/viewvc/cxf/trunk/rt/core/src/main/java/org/apache/cxf/bus/spring/SpringBusFactory.java?rev=1071451&r1=1071450&r2=1071451&view=diff
==============================================================================
--- cxf/trunk/rt/core/src/main/java/org/apache/cxf/bus/spring/SpringBusFactory.java (original)
+++ cxf/trunk/rt/core/src/main/java/org/apache/cxf/bus/spring/SpringBusFactory.java Thu Feb 17 00:01:25 2011
@@ -28,8 +28,10 @@ import org.apache.cxf.BusFactory;
 import org.apache.cxf.buslifecycle.BusLifeCycleListener;
 import org.apache.cxf.buslifecycle.BusLifeCycleManager;
 import org.apache.cxf.common.logging.LogUtils;
+import org.apache.cxf.configuration.Configurer;
 import org.springframework.beans.BeansException;
 import org.springframework.context.ApplicationContext;
+import org.springframework.core.io.Resource;
 
 public class SpringBusFactory extends BusFactory {
     
@@ -89,7 +91,14 @@ public class SpringBusFactory extends Bu
     }    
     
     public Bus createBus(String cfgFiles[], boolean includeDefaults) {
-        try {      
+        try {
+            String userCfgFile = System.getProperty(Configurer.USER_CFG_FILE_PROPERTY_NAME);
+            String sysCfgFileUrl = System.getProperty(Configurer.USER_CFG_FILE_PROPERTY_URL);
+            Resource r = BusApplicationContext.findResource(Configurer.DEFAULT_USER_CFG_FILE);
+            if (context == null && userCfgFile == null && cfgFiles == null && sysCfgFileUrl == null 
+                && (r == null || !r.exists()) && includeDefaults) {
+                return new org.apache.cxf.bus.CXFBusFactory().createBus();
+            }
             return finishCreatingBus(createApplicationContext(cfgFiles, includeDefaults));
         } catch (BeansException ex) {
             LogUtils.log(LOG, Level.WARNING, "APP_CONTEXT_CREATION_FAILED_MSG", ex, (Object[])null);

Modified: cxf/trunk/rt/core/src/main/java/org/apache/cxf/service/factory/FactoryBeanListenerManager.java
URL: http://svn.apache.org/viewvc/cxf/trunk/rt/core/src/main/java/org/apache/cxf/service/factory/FactoryBeanListenerManager.java?rev=1071451&r1=1071450&r2=1071451&view=diff
==============================================================================
--- cxf/trunk/rt/core/src/main/java/org/apache/cxf/service/factory/FactoryBeanListenerManager.java (original)
+++ cxf/trunk/rt/core/src/main/java/org/apache/cxf/service/factory/FactoryBeanListenerManager.java Thu Feb 17 00:01:25 2011
@@ -26,6 +26,7 @@ import javax.annotation.Resource;
 
 import org.apache.cxf.Bus;
 import org.apache.cxf.common.injection.NoJSR250Annotations;
+import org.apache.cxf.configuration.ConfiguredBeanLocator;
 
 /**
  * 
@@ -48,7 +49,17 @@ public class FactoryBeanListenerManager 
     @Resource
     public final void setBus(Bus bus) {
         this.bus = bus;
+        
         this.bus.setExtension(this, FactoryBeanListenerManager.class);
+        
+        ConfiguredBeanLocator loc = bus.getExtension(ConfiguredBeanLocator.class);
+        if (loc != null) {
+            for (FactoryBeanListener f : loc.getBeansOfType(FactoryBeanListener.class)) {
+                if (!listeners.contains(f)) {
+                    listeners.add(f);
+                }
+            }
+        }
     }
     
     public List<FactoryBeanListener> getListeners() {

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=1071451&r1=1071450&r2=1071451&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 Thu Feb 17 00:01:25 2011
@@ -19,9 +19,7 @@
 
 package org.apache.cxf.wsdl11;
 
-import java.io.BufferedReader;
 import java.io.IOException;
-import java.io.InputStreamReader;
 import java.net.URL;
 import java.util.ArrayList;
 import java.util.Collections;
@@ -56,12 +54,10 @@ import org.apache.cxf.Bus;
 import org.apache.cxf.BusException;
 import org.apache.cxf.catalog.CatalogWSDLLocator;
 import org.apache.cxf.common.WSDLConstants;
-import org.apache.cxf.common.classloader.ClassLoaderUtils;
 import org.apache.cxf.common.injection.NoJSR250Annotations;
 import org.apache.cxf.common.logging.LogUtils;
 import org.apache.cxf.common.util.CacheMap;
 import org.apache.cxf.common.util.PropertiesLoaderUtils;
-import org.apache.cxf.common.util.StringUtils;
 import org.apache.cxf.configuration.ConfiguredBeanLocator;
 import org.apache.cxf.service.model.ServiceSchemaInfo;
 import org.apache.cxf.staxutils.StaxUtils;
@@ -79,8 +75,7 @@ public class WSDLManagerImpl implements 
 
     private static final Logger LOG = LogUtils.getL7dLogger(WSDLManagerImpl.class);
 
-    private static final String EXTENSIONS_RESOURCE = "META-INF/cxf/wsdl-extensions.txt";
-    private static final String EXTENSIONS_RESOURCE_XML = "META-INF/cxf/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;
@@ -252,50 +247,14 @@ public class WSDLManagerImpl implements 
 
     private void registerInitialExtensions() throws BusException {
         registerInitialXmlExtensions(EXTENSIONS_RESOURCE_COMPAT);
-        registerInitialXmlExtensions(EXTENSIONS_RESOURCE_XML);
-        registerInitialExtensions(EXTENSIONS_RESOURCE);
-    }
-    private void registerInitialExtensions(String resource) throws BusException {
-        try {
-            for (URL url : ClassLoaderUtils.getResources(resource, this.getClass())) {
-                BufferedReader reader = new BufferedReader(new InputStreamReader(url.openStream(), "utf-8"));
-                String line = reader.readLine();
-                while (line != null) {
-                    line = line.trim();
-                    if (!line.startsWith("#")
-                        && !StringUtils.isEmpty(line)) {
-                        try {
-                            int idx = line.indexOf('=');
-                            String parentType = line.substring(0, idx);
-                            String elementType = line.substring(idx + 1);
-                            if (LOG.isLoggable(Level.FINE)) {
-                                LOG.fine("Registering extension: " + elementType 
-                                         + " for parent: " + parentType);
-                            }
-                            JAXBExtensionHelper.addExtensions(registry, parentType, elementType);
-                        } catch (ClassNotFoundException ex) {
-                            LOG.log(Level.WARNING, "EXTENSION_ADD_FAILED_MSG", ex);
-                        } catch (JAXBException ex) {
-                            LOG.log(Level.WARNING, "EXTENSION_ADD_FAILED_MSG", ex);
-                        }
-                    }
-                    line = reader.readLine();
-                }
-                reader.close();
-            }
-        } catch (IOException ex) {
-            throw new BusException(ex);
-        }
+        registerInitialXmlExtensions(EXTENSIONS_RESOURCE);
     }
     private void registerInitialXmlExtensions(String resource) throws BusException {
         Properties initialExtensions = null;
         try {
             initialExtensions = PropertiesLoaderUtils.loadAllProperties(resource, 
                                                                         Thread.currentThread()
-                                                                              .getContextClassLoader(),
-                                                                        LOG,
-                                                                        Level.WARNING,
-                                                                        "Use of {0} is deprecated.");
+                                                                              .getContextClassLoader());
         } catch (IOException ex) {
             throw new BusException(ex);
         }

Modified: cxf/trunk/rt/core/src/main/resources/META-INF/cxf/bus-extensions.xml
URL: http://svn.apache.org/viewvc/cxf/trunk/rt/core/src/main/resources/META-INF/cxf/bus-extensions.xml?rev=1071451&r1=1071450&r2=1071451&view=diff
==============================================================================
--- cxf/trunk/rt/core/src/main/resources/META-INF/cxf/bus-extensions.xml (original)
+++ cxf/trunk/rt/core/src/main/resources/META-INF/cxf/bus-extensions.xml Thu Feb 17 00:01:25 2011
@@ -26,23 +26,29 @@
 <!--    <extension class="org.apache.cxf.transport.ConduitInitiatorManagerImpl"-->
 <!--           interface="org.apache.cxf.transport.ConduitInitiatorManager"/>-->
     <extension class="org.apache.cxf.wsdl11.WSDLManagerImpl"
-           interface="org.apache.cxf.wsdl.WSDLManager"/>
+           interface="org.apache.cxf.wsdl.WSDLManager" deferred="true"/>
     <extension class="org.apache.cxf.phase.PhaseManagerImpl"
-           interface="org.apache.cxf.phase.PhaseManager"/>
+           interface="org.apache.cxf.phase.PhaseManager" deferred="true"/>
     <extension class="org.apache.cxf.workqueue.WorkQueueManagerImpl"
-       	   interface="org.apache.cxf.workqueue.WorkQueueManager"/>
+       	   interface="org.apache.cxf.workqueue.WorkQueueManager" deferred="true"/>
     <extension class="org.apache.cxf.buslifecycle.CXFBusLifeCycleManager"
-       	   interface="org.apache.cxf.buslifecycle.BusLifeCycleManager"/>   	   
+       	   interface="org.apache.cxf.buslifecycle.BusLifeCycleManager" deferred="true"/>   	   
     <extension class="org.apache.cxf.endpoint.ServerRegistryImpl"
-       	   interface="org.apache.cxf.endpoint.ServerRegistry"/>
+       	   interface="org.apache.cxf.endpoint.ServerRegistry" deferred="true"/>
     <extension class="org.apache.cxf.transport.http.QueryHandlerRegistryImpl"
-       	   interface="org.apache.cxf.transports.http.QueryHandlerRegistry"/> 
+       	   interface="org.apache.cxf.transports.http.QueryHandlerRegistry" deferred="true"/> 
     <extension class="org.apache.cxf.endpoint.EndpointResolverRegistryImpl"
-       	   interface="org.apache.cxf.endpoint.EndpointResolverRegistry"/>
+       	   interface="org.apache.cxf.endpoint.EndpointResolverRegistry" deferred="true"/>
     <extension class="org.apache.cxf.headers.HeaderManagerImpl"
-       	   interface="org.apache.cxf.headers.HeaderManager"/>
+       	   interface="org.apache.cxf.headers.HeaderManager" deferred="true"/>
     <extension class="org.apache.cxf.catalog.OASISCatalogManager"
-       	   interface="org.apache.cxf.catalog.OASISCatalogManager"/>
-    <extension class="org.apache.cxf.service.factory.FactoryBeanListenerManager"/>
+       	   interface="org.apache.cxf.catalog.OASISCatalogManager" deferred="true"/>
+    <extension class="org.apache.cxf.service.factory.FactoryBeanListenerManager" deferred="true"/>
+    <extension interface="org.apache.cxf.endpoint.ServerLifeCycleManager"
+        class="org.apache.cxf.endpoint.ServerLifeCycleManagerImpl"
+        deferred="true"/>
+    <extension interface="org.apache.cxf.endpoint.ClientLifeCycleManager"
+        class="org.apache.cxf.endpoint.ClientLifeCycleManagerImpl"
+        deferred="true"/>
            
 </extensions>

Modified: cxf/trunk/rt/core/src/test/java/org/apache/cxf/bus/extension/ExtensionManagerTest.java
URL: http://svn.apache.org/viewvc/cxf/trunk/rt/core/src/test/java/org/apache/cxf/bus/extension/ExtensionManagerTest.java?rev=1071451&r1=1071450&r2=1071451&view=diff
==============================================================================
--- cxf/trunk/rt/core/src/test/java/org/apache/cxf/bus/extension/ExtensionManagerTest.java (original)
+++ cxf/trunk/rt/core/src/test/java/org/apache/cxf/bus/extension/ExtensionManagerTest.java Thu Feb 17 00:01:25 2011
@@ -88,9 +88,9 @@ public class ExtensionManagerTest extend
         e.setClassname(extensionClass);       
         e.getNamespaces().add(ns);
         e.setDeferred(true);
-        manager.processExtension(e);
+        manager.addDeferred(e);
         assertNull(myService);
-        manager.activateViaNS(ns);
+        manager.activateViaNS(ns, null);
         assertNotNull(myService);
         assertEquals(1, myService.getActivationNamespaces().size());
         assertEquals(ns, myService.getActivationNamespaces().iterator().next());
@@ -98,7 +98,7 @@ public class ExtensionManagerTest extend
         // second activation should be a no-op
         
         MyService first = myService;        
-        manager.activateViaNS(ns);
+        manager.activateViaNS(ns, null);
         assertSame(first, myService);
         myService = null;
     }

Copied: cxf/trunk/rt/frontend/jaxws/src/main/resources/META-INF/cxf/bus-extensions.xml (from r1071449, cxf/trunk/common/xerces-xsd-validation/src/main/resources/META-INF/cxf/bus-extensions.xml)
URL: http://svn.apache.org/viewvc/cxf/trunk/rt/frontend/jaxws/src/main/resources/META-INF/cxf/bus-extensions.xml?p2=cxf/trunk/rt/frontend/jaxws/src/main/resources/META-INF/cxf/bus-extensions.xml&p1=cxf/trunk/common/xerces-xsd-validation/src/main/resources/META-INF/cxf/bus-extensions.xml&r1=1071449&r2=1071451&rev=1071451&view=diff
==============================================================================
--- cxf/trunk/common/xerces-xsd-validation/src/main/resources/META-INF/cxf/bus-extensions.xml (original)
+++ cxf/trunk/rt/frontend/jaxws/src/main/resources/META-INF/cxf/bus-extensions.xml Thu Feb 17 00:01:25 2011
@@ -18,6 +18,7 @@
   under the License.
 -->
 <extensions xmlns="http://cxf.apache.org/bus/extension">
-    <extension class="org.apache.cxf.xsdvalidation.XercesXsdValidationImpl"
-           interface="org.apache.cxf.common.xmlschema.XmlSchemaValidationManager"/>
+
+    <extension class="org.apache.cxf.jaxws.context.WebServiceContextResourceResolver" deferred="true"/>
+    
 </extensions>

Modified: cxf/trunk/rt/frontend/jaxws/src/test/java/org/apache/cxf/jaxws/AbstractJaxWsTest.java
URL: http://svn.apache.org/viewvc/cxf/trunk/rt/frontend/jaxws/src/test/java/org/apache/cxf/jaxws/AbstractJaxWsTest.java?rev=1071451&r1=1071450&r2=1071451&view=diff
==============================================================================
--- cxf/trunk/rt/frontend/jaxws/src/test/java/org/apache/cxf/jaxws/AbstractJaxWsTest.java (original)
+++ cxf/trunk/rt/frontend/jaxws/src/test/java/org/apache/cxf/jaxws/AbstractJaxWsTest.java Thu Feb 17 00:01:25 2011
@@ -30,8 +30,6 @@ import org.apache.cxf.test.AbstractCXFTe
 import org.apache.cxf.transport.ConduitInitiatorManager;
 import org.apache.cxf.transport.DestinationFactoryManager;
 import org.apache.cxf.transport.local.LocalTransportFactory;
-import org.apache.cxf.wsdl.WSDLManager;
-import org.apache.cxf.wsdl11.WSDLManagerImpl;
 import org.junit.Before;
 import org.junit.BeforeClass;
 
@@ -81,9 +79,5 @@ public abstract class AbstractJaxWsTest 
         extension.registerConduitInitiator("http://cxf.apache.org/transports/http", localTransport);
         extension.registerConduitInitiator("http://cxf.apache.org/transports/http/configuration",
                                            localTransport);
-        
-        WSDLManagerImpl manager = new WSDLManagerImpl();
-        manager.setBus(bus);
-        bus.setExtension(manager, WSDLManager.class);
     }
 }

Added: cxf/trunk/rt/transports/http/src/main/java/org/apache/cxf/transport/http/HTTPWSDLExtensionLoader.java
URL: http://svn.apache.org/viewvc/cxf/trunk/rt/transports/http/src/main/java/org/apache/cxf/transport/http/HTTPWSDLExtensionLoader.java?rev=1071451&view=auto
==============================================================================
--- cxf/trunk/rt/transports/http/src/main/java/org/apache/cxf/transport/http/HTTPWSDLExtensionLoader.java (added)
+++ cxf/trunk/rt/transports/http/src/main/java/org/apache/cxf/transport/http/HTTPWSDLExtensionLoader.java Thu Feb 17 00:01:25 2011
@@ -0,0 +1,59 @@
+/**
+ * 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.transport.http;
+
+import javax.wsdl.extensions.ExtensibilityElement;
+import javax.xml.bind.JAXBException;
+
+import org.apache.cxf.Bus;
+import org.apache.cxf.common.injection.NoJSR250Annotations;
+import org.apache.cxf.wsdl.JAXBExtensionHelper;
+import org.apache.cxf.wsdl.WSDLExtensionLoader;
+import org.apache.cxf.wsdl.WSDLManager;
+
+/**
+ * 
+ */
+@NoJSR250Annotations
+public final class HTTPWSDLExtensionLoader implements WSDLExtensionLoader { 
+    
+    public HTTPWSDLExtensionLoader(Bus b) {
+        WSDLManager manager = b.getExtension(WSDLManager.class);
+        
+        createExtensor(manager, javax.wsdl.Port.class, 
+                       org.apache.cxf.transports.http.configuration.HTTPClientPolicy.class);
+        createExtensor(manager, javax.wsdl.Port.class,
+                       org.apache.cxf.transports.http.configuration.HTTPServerPolicy.class);
+        createExtensor(manager, javax.wsdl.Port.class,
+                       org.apache.cxf.wsdl.http.AddressType.class);
+    }
+    public void createExtensor(WSDLManager manager,
+                                Class<?> parentType,
+                                Class<? extends ExtensibilityElement> elementType) {
+        try {
+            JAXBExtensionHelper.addExtensions(manager.getExtensionRegistry(),
+                                              parentType, 
+                                              elementType);
+        } catch (JAXBException e) {
+            //ignore, won't support XML
+        }
+    }
+
+}

Propchange: cxf/trunk/rt/transports/http/src/main/java/org/apache/cxf/transport/http/HTTPWSDLExtensionLoader.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: cxf/trunk/rt/transports/http/src/main/java/org/apache/cxf/transport/http/HTTPWSDLExtensionLoader.java
------------------------------------------------------------------------------
    svn:keywords = Rev Date

Modified: cxf/trunk/rt/transports/http/src/main/resources/META-INF/cxf/bus-extensions.xml
URL: http://svn.apache.org/viewvc/cxf/trunk/rt/transports/http/src/main/resources/META-INF/cxf/bus-extensions.xml?rev=1071451&r1=1071450&r2=1071451&view=diff
==============================================================================
--- cxf/trunk/rt/transports/http/src/main/resources/META-INF/cxf/bus-extensions.xml (original)
+++ cxf/trunk/rt/transports/http/src/main/resources/META-INF/cxf/bus-extensions.xml Thu Feb 17 00:01:25 2011
@@ -25,4 +25,9 @@
         <namespace>http://schemas.xmlsoap.org/wsdl/http</namespace>
         <namespace>http://schemas.xmlsoap.org/wsdl/http/</namespace>
     </extension>
+    <extension class="org.apache.cxf.transport.http.HTTPWSDLExtensionLoader"  deferred="true"/>
+    <extension class="org.apache.cxf.transport.http.policy.HTTPClientAssertionBuilder" deferred="true"/>
+    <extension class="org.apache.cxf.transport.http.policy.HTTPServerAssertionBuilder" deferred="true"/>
+    <extension class="org.apache.cxf.transport.http.policy.NoOpPolicyInterceptorProvider" deferred="true"/>
+    
 </extensions>

Modified: cxf/trunk/rt/transports/http/src/main/resources/META-INF/cxf/cxf-extension-http.xml
URL: http://svn.apache.org/viewvc/cxf/trunk/rt/transports/http/src/main/resources/META-INF/cxf/cxf-extension-http.xml?rev=1071451&r1=1071450&r2=1071451&view=diff
==============================================================================
--- cxf/trunk/rt/transports/http/src/main/resources/META-INF/cxf/cxf-extension-http.xml (original)
+++ cxf/trunk/rt/transports/http/src/main/resources/META-INF/cxf/cxf-extension-http.xml Thu Feb 17 00:01:25 2011
@@ -22,6 +22,9 @@
        xmlns:foo="http://cxf.apache.org/configuration/foo"
        xsi:schemaLocation="
 http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans.xsd">
+    <bean class="org.apache.cxf.transport.http.HTTPWSDLExtensionLoader"  lazy-init="true">
+        <constructor-arg ref="cxf"/>
+    </bean>
     
     <bean class="org.apache.cxf.transport.http.policy.HTTPClientAssertionBuilder"
 	  id="org.apache.cxf.transport.http.policy.HTTPClientAssertionBuilder" lazy-init="true"/>

Added: cxf/trunk/rt/transports/jbi/src/main/java/org/apache/cxf/transport/jbi/wsdl11/JBIWSDLExtensionLoader.java
URL: http://svn.apache.org/viewvc/cxf/trunk/rt/transports/jbi/src/main/java/org/apache/cxf/transport/jbi/wsdl11/JBIWSDLExtensionLoader.java?rev=1071451&view=auto
==============================================================================
--- cxf/trunk/rt/transports/jbi/src/main/java/org/apache/cxf/transport/jbi/wsdl11/JBIWSDLExtensionLoader.java (added)
+++ cxf/trunk/rt/transports/jbi/src/main/java/org/apache/cxf/transport/jbi/wsdl11/JBIWSDLExtensionLoader.java Thu Feb 17 00:01:25 2011
@@ -0,0 +1,55 @@
+/**
+ * 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.transport.jbi.wsdl11;
+
+import javax.wsdl.extensions.ExtensibilityElement;
+import javax.xml.bind.JAXBException;
+
+import org.apache.cxf.Bus;
+import org.apache.cxf.common.injection.NoJSR250Annotations;
+import org.apache.cxf.wsdl.JAXBExtensionHelper;
+import org.apache.cxf.wsdl.WSDLExtensionLoader;
+import org.apache.cxf.wsdl.WSDLManager;
+
+/**
+ * 
+ */
+@NoJSR250Annotations
+public final class JBIWSDLExtensionLoader implements WSDLExtensionLoader { 
+    
+    public JBIWSDLExtensionLoader(Bus b) {
+        WSDLManager manager = b.getExtension(WSDLManager.class);
+        
+        createExtensor(manager, javax.wsdl.Port.class,
+                       org.apache.cxf.transports.jbi.AddressType.class);
+    }
+    public void createExtensor(WSDLManager manager,
+                                Class<?> parentType,
+                                Class<? extends ExtensibilityElement> elementType) {
+        try {
+            JAXBExtensionHelper.addExtensions(manager.getExtensionRegistry(),
+                                              parentType, 
+                                              elementType);
+        } catch (JAXBException e) {
+            //ignore, won't support XML
+        }
+    }
+
+}

Propchange: cxf/trunk/rt/transports/jbi/src/main/java/org/apache/cxf/transport/jbi/wsdl11/JBIWSDLExtensionLoader.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: cxf/trunk/rt/transports/jbi/src/main/java/org/apache/cxf/transport/jbi/wsdl11/JBIWSDLExtensionLoader.java
------------------------------------------------------------------------------
    svn:keywords = Rev Date

Modified: cxf/trunk/rt/transports/jbi/src/main/resources/META-INF/cxf/bus-extensions.xml
URL: http://svn.apache.org/viewvc/cxf/trunk/rt/transports/jbi/src/main/resources/META-INF/cxf/bus-extensions.xml?rev=1071451&r1=1071450&r2=1071451&view=diff
==============================================================================
--- cxf/trunk/rt/transports/jbi/src/main/resources/META-INF/cxf/bus-extensions.xml (original)
+++ cxf/trunk/rt/transports/jbi/src/main/resources/META-INF/cxf/bus-extensions.xml Thu Feb 17 00:01:25 2011
@@ -23,5 +23,6 @@
       <namespace>http://cxf.apache.org/transports/jbi</namespace>
       <namespace>http://cxf.apache.org/transports/jbi/configuration</namespace>
     </extension>
+    <extension class="org.apache.cxf.transport.jbi.wsdl11.JBIWSDLExtensionLoader"  deferred="true"/>
         
 </extensions>

Modified: cxf/trunk/rt/transports/jbi/src/main/resources/META-INF/cxf/cxf-extension-jbi.xml
URL: http://svn.apache.org/viewvc/cxf/trunk/rt/transports/jbi/src/main/resources/META-INF/cxf/cxf-extension-jbi.xml?rev=1071451&r1=1071450&r2=1071451&view=diff
==============================================================================
--- cxf/trunk/rt/transports/jbi/src/main/resources/META-INF/cxf/cxf-extension-jbi.xml (original)
+++ cxf/trunk/rt/transports/jbi/src/main/resources/META-INF/cxf/cxf-extension-jbi.xml Thu Feb 17 00:01:25 2011
@@ -34,4 +34,10 @@ http://www.springframework.org/schema/be
             </list>
         </property>
     </bean>
+    
+    <bean class="org.apache.cxf.transport.jbi.wsdl11.JBIWSDLExtensionLoader"
+        id="org.apache.cxf.transport.jbi.wsdl11.JBIWSDLExtensionLoader"  lazy-init="true">
+        <constructor-arg ref="cxf"/>
+    </bean>
+    
 </beans>

Added: cxf/trunk/rt/transports/jms/src/main/java/org/apache/cxf/transport/jms/wsdl11/JMSWSDLExtensionLoader.java
URL: http://svn.apache.org/viewvc/cxf/trunk/rt/transports/jms/src/main/java/org/apache/cxf/transport/jms/wsdl11/JMSWSDLExtensionLoader.java?rev=1071451&view=auto
==============================================================================
--- cxf/trunk/rt/transports/jms/src/main/java/org/apache/cxf/transport/jms/wsdl11/JMSWSDLExtensionLoader.java (added)
+++ cxf/trunk/rt/transports/jms/src/main/java/org/apache/cxf/transport/jms/wsdl11/JMSWSDLExtensionLoader.java Thu Feb 17 00:01:25 2011
@@ -0,0 +1,118 @@
+/**
+ * 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.transport.jms.wsdl11;
+
+import javax.wsdl.extensions.ExtensibilityElement;
+import javax.xml.bind.JAXBException;
+
+import org.apache.cxf.Bus;
+import org.apache.cxf.common.injection.NoJSR250Annotations;
+import org.apache.cxf.wsdl.JAXBExtensionHelper;
+import org.apache.cxf.wsdl.WSDLExtensionLoader;
+import org.apache.cxf.wsdl.WSDLManager;
+
+/**
+ * 
+ */
+@NoJSR250Annotations
+public final class JMSWSDLExtensionLoader implements WSDLExtensionLoader { 
+    
+    public JMSWSDLExtensionLoader(Bus b) {
+        WSDLManager manager = b.getExtension(WSDLManager.class);
+        
+        createExtensor(manager, javax.wsdl.Port.class,
+                       org.apache.cxf.transport.jms.AddressType.class);
+        createExtensor(manager, javax.wsdl.Port.class,
+                       org.apache.cxf.transport.jms.ClientBehaviorPolicyType.class);
+        createExtensor(manager, javax.wsdl.Port.class,
+                       org.apache.cxf.transport.jms.ServerBehaviorPolicyType.class);
+        createExtensor(manager, javax.wsdl.Port.class,
+                       org.apache.cxf.transport.jms.ClientConfig.class);
+        createExtensor(manager, javax.wsdl.Port.class,
+                       org.apache.cxf.transport.jms.ServerConfig.class);
+        createExtensor(manager, javax.wsdl.Port.class,
+                       org.apache.cxf.transport.jms.SessionPoolType.class);
+
+        createExtensor(manager, javax.wsdl.Binding.class,
+                       org.apache.cxf.transport.jms.wsdl.JndiContextParameterType.class);
+        createExtensor(manager, javax.wsdl.Binding.class,
+                       org.apache.cxf.transport.jms.wsdl.JndiConnectionFactoryNameType.class);
+        createExtensor(manager, javax.wsdl.Binding.class,
+                       org.apache.cxf.transport.jms.wsdl.JndiInitialContextFactoryType.class);
+        createExtensor(manager, javax.wsdl.Binding.class,
+                       org.apache.cxf.transport.jms.wsdl.JndiURLType.class);
+        createExtensor(manager, javax.wsdl.Binding.class,
+                       org.apache.cxf.transport.jms.wsdl.DeliveryModeType.class);
+        createExtensor(manager, javax.wsdl.Binding.class,
+                       org.apache.cxf.transport.jms.wsdl.PriorityType.class);
+        createExtensor(manager, javax.wsdl.Binding.class,
+                       org.apache.cxf.transport.jms.wsdl.TimeToLiveType.class);
+        createExtensor(manager, javax.wsdl.Binding.class,
+                       org.apache.cxf.transport.jms.wsdl.ReplyToNameType.class);
+
+        createExtensor(manager, javax.wsdl.Port.class,
+                       org.apache.cxf.transport.jms.wsdl.JndiContextParameterType.class);
+        createExtensor(manager, javax.wsdl.Port.class,
+                       org.apache.cxf.transport.jms.wsdl.JndiConnectionFactoryNameType.class);
+        createExtensor(manager, javax.wsdl.Port.class,
+                       org.apache.cxf.transport.jms.wsdl.JndiInitialContextFactoryType.class);
+        createExtensor(manager, javax.wsdl.Port.class,
+                       org.apache.cxf.transport.jms.wsdl.JndiURLType.class);
+        createExtensor(manager, javax.wsdl.Port.class,
+                       org.apache.cxf.transport.jms.wsdl.DeliveryModeType.class);
+        createExtensor(manager, javax.wsdl.Port.class,
+                       org.apache.cxf.transport.jms.wsdl.PriorityType.class);
+        createExtensor(manager, javax.wsdl.Port.class,
+                       org.apache.cxf.transport.jms.wsdl.TimeToLiveType.class);
+        createExtensor(manager, javax.wsdl.Port.class,
+                       org.apache.cxf.transport.jms.wsdl.ReplyToNameType.class);
+            
+        createExtensor(manager, javax.wsdl.Service.class,
+                       org.apache.cxf.transport.jms.wsdl.JndiContextParameterType.class);
+        createExtensor(manager, javax.wsdl.Service.class,
+                       org.apache.cxf.transport.jms.wsdl.JndiConnectionFactoryNameType.class);
+        createExtensor(manager, javax.wsdl.Service.class,
+                       org.apache.cxf.transport.jms.wsdl.JndiInitialContextFactoryType.class);
+        createExtensor(manager, javax.wsdl.Service.class,
+                       org.apache.cxf.transport.jms.wsdl.JndiURLType.class);
+        createExtensor(manager, javax.wsdl.Service.class,
+                       org.apache.cxf.transport.jms.wsdl.DeliveryModeType.class);
+        createExtensor(manager, javax.wsdl.Service.class,
+                       org.apache.cxf.transport.jms.wsdl.PriorityType.class);
+        createExtensor(manager, javax.wsdl.Service.class,
+                       org.apache.cxf.transport.jms.wsdl.TimeToLiveType.class);
+        createExtensor(manager, javax.wsdl.Service.class,
+                       org.apache.cxf.transport.jms.wsdl.ReplyToNameType.class);
+        
+        
+    }
+    public void createExtensor(WSDLManager manager,
+                                Class<?> parentType,
+                                Class<? extends ExtensibilityElement> elementType) {
+        try {
+            JAXBExtensionHelper.addExtensions(manager.getExtensionRegistry(),
+                                              parentType, 
+                                              elementType);
+        } catch (JAXBException e) {
+            //ignore, won't support XML
+        }
+    }
+
+}

Propchange: cxf/trunk/rt/transports/jms/src/main/java/org/apache/cxf/transport/jms/wsdl11/JMSWSDLExtensionLoader.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: cxf/trunk/rt/transports/jms/src/main/java/org/apache/cxf/transport/jms/wsdl11/JMSWSDLExtensionLoader.java
------------------------------------------------------------------------------
    svn:keywords = Rev Date

Modified: cxf/trunk/rt/transports/jms/src/main/resources/META-INF/cxf/bus-extensions.xml
URL: http://svn.apache.org/viewvc/cxf/trunk/rt/transports/jms/src/main/resources/META-INF/cxf/bus-extensions.xml?rev=1071451&r1=1071450&r2=1071451&view=diff
==============================================================================
--- cxf/trunk/rt/transports/jms/src/main/resources/META-INF/cxf/bus-extensions.xml (original)
+++ cxf/trunk/rt/transports/jms/src/main/resources/META-INF/cxf/bus-extensions.xml Thu Feb 17 00:01:25 2011
@@ -23,5 +23,6 @@
         <namespace>http://cxf.apache.org/transports/jms</namespace>
         <namespace>http://cxf.apache.org/transports/jms/configuration</namespace>
     </extension>
+    <extension class="org.apache.cxf.transport.jms.wsdl11.JMSWSDLExtensionLoader" deferred="true"/>
         
 </extensions>

Modified: cxf/trunk/rt/transports/jms/src/main/resources/META-INF/cxf/cxf-extension-jms.xml
URL: http://svn.apache.org/viewvc/cxf/trunk/rt/transports/jms/src/main/resources/META-INF/cxf/cxf-extension-jms.xml?rev=1071451&r1=1071450&r2=1071451&view=diff
==============================================================================
--- cxf/trunk/rt/transports/jms/src/main/resources/META-INF/cxf/cxf-extension-jms.xml (original)
+++ cxf/trunk/rt/transports/jms/src/main/resources/META-INF/cxf/cxf-extension-jms.xml Thu Feb 17 00:01:25 2011
@@ -34,4 +34,10 @@ http://www.springframework.org/schema/be
             </list>
         </property>
     </bean>
+    <bean class="org.apache.cxf.transport.jms.wsdl11.JMSWSDLExtensionLoader"
+      id="org.apache.cxf.transport.jms.wsdl11.JMSWSDLExtensionLoader"
+      lazy-init="true">
+      <constructor-arg ref="cxf"/>
+    </bean>
+        
 </beans>

Copied: cxf/trunk/rt/transports/local/src/main/resources/META-INF/cxf/bus-extensions.xml (from r1071449, cxf/trunk/rt/frontend/jaxrs/src/main/resources/META-INF/cxf/bus-extensions.xml)
URL: http://svn.apache.org/viewvc/cxf/trunk/rt/transports/local/src/main/resources/META-INF/cxf/bus-extensions.xml?p2=cxf/trunk/rt/transports/local/src/main/resources/META-INF/cxf/bus-extensions.xml&p1=cxf/trunk/rt/frontend/jaxrs/src/main/resources/META-INF/cxf/bus-extensions.xml&r1=1071449&r2=1071451&rev=1071451&view=diff
==============================================================================
--- cxf/trunk/rt/frontend/jaxrs/src/main/resources/META-INF/cxf/bus-extensions.xml (original)
+++ cxf/trunk/rt/transports/local/src/main/resources/META-INF/cxf/bus-extensions.xml Thu Feb 17 00:01:25 2011
@@ -19,9 +19,7 @@
 -->
 <extensions xmlns="http://cxf.apache.org/bus/extension">
 
-    <extension class="org.apache.cxf.jaxrs.JAXRSBindingFactory" 
-      interface="org.apache.cxf.binding.BindingFactory" deferred="true">
-        <namespace>http://apache.org/cxf/binding/jaxrs</namespace>
+    <extension class="org.apache.cxf.transport.local.LocalTransportFactory"  deferred="true">
+        <namespace>http://cxf.apache.org/transports/local</namespace>
     </extension>
-    
 </extensions>

Added: cxf/trunk/rt/ws/addr/src/main/java/org/apache/cxf/ws/addressing/AddressingWSDLExtensionLoader.java
URL: http://svn.apache.org/viewvc/cxf/trunk/rt/ws/addr/src/main/java/org/apache/cxf/ws/addressing/AddressingWSDLExtensionLoader.java?rev=1071451&view=auto
==============================================================================
--- cxf/trunk/rt/ws/addr/src/main/java/org/apache/cxf/ws/addressing/AddressingWSDLExtensionLoader.java (added)
+++ cxf/trunk/rt/ws/addr/src/main/java/org/apache/cxf/ws/addressing/AddressingWSDLExtensionLoader.java Thu Feb 17 00:01:25 2011
@@ -0,0 +1,55 @@
+/**
+ * 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.ws.addressing;
+
+import javax.wsdl.extensions.ExtensibilityElement;
+import javax.xml.bind.JAXBException;
+
+import org.apache.cxf.Bus;
+import org.apache.cxf.common.injection.NoJSR250Annotations;
+import org.apache.cxf.wsdl.JAXBExtensionHelper;
+import org.apache.cxf.wsdl.WSDLExtensionLoader;
+import org.apache.cxf.wsdl.WSDLManager;
+
+/**
+ * 
+ */
+@NoJSR250Annotations
+public final class AddressingWSDLExtensionLoader implements WSDLExtensionLoader { 
+    
+    public AddressingWSDLExtensionLoader(Bus b) {
+        WSDLManager manager = b.getExtension(WSDLManager.class);
+        
+        createExtensor(manager, javax.wsdl.Binding.class,
+                       org.apache.cxf.ws.addressing.wsdl.UsingAddressing.class);        
+    }
+    public void createExtensor(WSDLManager manager,
+                                Class<?> parentType,
+                                Class<? extends ExtensibilityElement> elementType) {
+        try {
+            JAXBExtensionHelper.addExtensions(manager.getExtensionRegistry(),
+                                              parentType, 
+                                              elementType);
+        } catch (JAXBException e) {
+            //ignore, won't support XML
+        }
+    }
+
+}

Propchange: cxf/trunk/rt/ws/addr/src/main/java/org/apache/cxf/ws/addressing/AddressingWSDLExtensionLoader.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: cxf/trunk/rt/ws/addr/src/main/java/org/apache/cxf/ws/addressing/AddressingWSDLExtensionLoader.java
------------------------------------------------------------------------------
    svn:keywords = Rev Date

Copied: cxf/trunk/rt/ws/addr/src/main/resources/META-INF/cxf/bus-extensions.xml (from r1071449, cxf/trunk/rt/transports/jms/src/main/resources/META-INF/cxf/bus-extensions.xml)
URL: http://svn.apache.org/viewvc/cxf/trunk/rt/ws/addr/src/main/resources/META-INF/cxf/bus-extensions.xml?p2=cxf/trunk/rt/ws/addr/src/main/resources/META-INF/cxf/bus-extensions.xml&p1=cxf/trunk/rt/transports/jms/src/main/resources/META-INF/cxf/bus-extensions.xml&r1=1071449&r2=1071451&rev=1071451&view=diff
==============================================================================
--- cxf/trunk/rt/transports/jms/src/main/resources/META-INF/cxf/bus-extensions.xml (original)
+++ cxf/trunk/rt/ws/addr/src/main/resources/META-INF/cxf/bus-extensions.xml Thu Feb 17 00:01:25 2011
@@ -19,9 +19,12 @@
 -->
 <extensions xmlns="http://cxf.apache.org/bus/extension">
 
-    <extension class="org.apache.cxf.transport.jms.JMSTransportFactory" deferred="true">
-        <namespace>http://cxf.apache.org/transports/jms</namespace>
-        <namespace>http://cxf.apache.org/transports/jms/configuration</namespace>
-    </extension>
+    <extension class="org.apache.cxf.ws.addressing.policy.AddressingAssertionBuilder"
+      deferred="true"/>
+    <extension class="org.apache.cxf.ws.addressing.policy.UsingAddressingAssertionBuilder"
+      deferred="true"/>
+    <extension class="org.apache.cxf.ws.addressing.policy.AddressingPolicyInterceptorProvider"
+      deferred="true"/>
+    <extension class="org.apache.cxf.ws.addressing.AddressingWSDLExtensionLoader" deferred="true"/>
         
 </extensions>

Modified: cxf/trunk/rt/ws/addr/src/main/resources/META-INF/cxf/cxf-extension-addr.xml
URL: http://svn.apache.org/viewvc/cxf/trunk/rt/ws/addr/src/main/resources/META-INF/cxf/cxf-extension-addr.xml?rev=1071451&r1=1071450&r2=1071451&view=diff
==============================================================================
--- cxf/trunk/rt/ws/addr/src/main/resources/META-INF/cxf/cxf-extension-addr.xml (original)
+++ cxf/trunk/rt/ws/addr/src/main/resources/META-INF/cxf/cxf-extension-addr.xml Thu Feb 17 00:01:25 2011
@@ -35,5 +35,9 @@ http://www.springframework.org/schema/be
 	  id="org.apache.cxf.ws.addressing.policy.AddressingPolicyInterceptorProvider"
 	  lazy-init="true"/>
  
-    
+    <bean class="org.apache.cxf.ws.addressing.AddressingWSDLExtensionLoader"
+      id="org.apache.cxf.ws.addressing.AddressingWSDLExtensionLoader"
+      lazy-init="true">
+        <constructor-arg ref="cxf"/>
+    </bean>
 </beans>
\ No newline at end of file

Modified: cxf/trunk/rt/ws/policy/src/main/java/org/apache/cxf/ws/policy/AssertionBuilderRegistryImpl.java
URL: http://svn.apache.org/viewvc/cxf/trunk/rt/ws/policy/src/main/java/org/apache/cxf/ws/policy/AssertionBuilderRegistryImpl.java?rev=1071451&r1=1071450&r2=1071451&view=diff
==============================================================================
--- cxf/trunk/rt/ws/policy/src/main/java/org/apache/cxf/ws/policy/AssertionBuilderRegistryImpl.java (original)
+++ cxf/trunk/rt/ws/policy/src/main/java/org/apache/cxf/ws/policy/AssertionBuilderRegistryImpl.java Thu Feb 17 00:01:25 2011
@@ -110,6 +110,9 @@ public class AssertionBuilderRegistryImp
             ConfiguredBeanLocator c = bus.getExtension(ConfiguredBeanLocator.class);
             if (c != null) {
                 c.getBeansOfType(AssertionBuilderLoader.class);
+                for (AssertionBuilder b : c.getBeansOfType(AssertionBuilder.class)) {
+                    register(b);
+                }
             }
         }
     }

Modified: cxf/trunk/rt/ws/policy/src/main/java/org/apache/cxf/ws/policy/PolicyBuilderImpl.java
URL: http://svn.apache.org/viewvc/cxf/trunk/rt/ws/policy/src/main/java/org/apache/cxf/ws/policy/PolicyBuilderImpl.java?rev=1071451&r1=1071450&r2=1071451&view=diff
==============================================================================
--- cxf/trunk/rt/ws/policy/src/main/java/org/apache/cxf/ws/policy/PolicyBuilderImpl.java (original)
+++ cxf/trunk/rt/ws/policy/src/main/java/org/apache/cxf/ws/policy/PolicyBuilderImpl.java Thu Feb 17 00:01:25 2011
@@ -61,10 +61,18 @@ public class PolicyBuilderImpl implement
     private AssertionBuilderRegistry assertionBuilderRegistry;
     private Bus bus;
    
+    public PolicyBuilderImpl() {
+    }
+    
+    public PolicyBuilderImpl(Bus theBus) {
+        bus = theBus;
+        assertionBuilderRegistry = theBus.getExtension(AssertionBuilderRegistry.class);
+    }
+
     public Class<?> getRegistrationType() {
         return PolicyBuilder.class;
     }
- 
+    
     public void setBus(Bus theBus) {
         bus = theBus;
     }

Modified: cxf/trunk/rt/ws/policy/src/main/java/org/apache/cxf/ws/policy/PolicyInterceptorProviderRegistryImpl.java
URL: http://svn.apache.org/viewvc/cxf/trunk/rt/ws/policy/src/main/java/org/apache/cxf/ws/policy/PolicyInterceptorProviderRegistryImpl.java?rev=1071451&r1=1071450&r2=1071451&view=diff
==============================================================================
--- cxf/trunk/rt/ws/policy/src/main/java/org/apache/cxf/ws/policy/PolicyInterceptorProviderRegistryImpl.java (original)
+++ cxf/trunk/rt/ws/policy/src/main/java/org/apache/cxf/ws/policy/PolicyInterceptorProviderRegistryImpl.java Thu Feb 17 00:01:25 2011
@@ -82,12 +82,15 @@ public class PolicyInterceptorProviderRe
     public Class<?> getRegistrationType() {
         return PolicyInterceptorProviderRegistry.class;
     }
-    private synchronized void loadDynamic() {
+    protected synchronized void loadDynamic() {
         if (!dynamicLoaded && bus != null) {
             dynamicLoaded = true;
             ConfiguredBeanLocator c = bus.getExtension(ConfiguredBeanLocator.class);
             if (c != null) {
                 c.getBeansOfType(PolicyInterceptorProviderLoader.class);
+                for (PolicyInterceptorProvider b : c.getBeansOfType(PolicyInterceptorProvider.class)) {
+                    register(b);
+                }
             }
         }
     }

Modified: cxf/trunk/rt/ws/policy/src/main/java/org/apache/cxf/ws/policy/attachment/external/DomainExpressionBuilderRegistry.java
URL: http://svn.apache.org/viewvc/cxf/trunk/rt/ws/policy/src/main/java/org/apache/cxf/ws/policy/attachment/external/DomainExpressionBuilderRegistry.java?rev=1071451&r1=1071450&r2=1071451&view=diff
==============================================================================
--- cxf/trunk/rt/ws/policy/src/main/java/org/apache/cxf/ws/policy/attachment/external/DomainExpressionBuilderRegistry.java (original)
+++ cxf/trunk/rt/ws/policy/src/main/java/org/apache/cxf/ws/policy/attachment/external/DomainExpressionBuilderRegistry.java Thu Feb 17 00:01:25 2011
@@ -22,12 +22,16 @@ package org.apache.cxf.ws.policy.attachm
 import java.util.Map;
 import java.util.ResourceBundle;
 
+import javax.annotation.Resource;
 import javax.xml.namespace.QName;
 
 import org.w3c.dom.Element;
 
+import org.apache.cxf.Bus;
 import org.apache.cxf.common.i18n.BundleUtils;
 import org.apache.cxf.common.i18n.Message;
+import org.apache.cxf.common.injection.NoJSR250Annotations;
+import org.apache.cxf.configuration.ConfiguredBeanLocator;
 import org.apache.cxf.configuration.spring.MapProvider;
 import org.apache.cxf.extension.BusExtension;
 import org.apache.cxf.extension.RegistryImpl;
@@ -37,14 +41,21 @@ import org.apache.cxf.ws.policy.PolicyEx
 /**
  * 
  */
+@NoJSR250Annotations(unlessNull = "bus")
 public class DomainExpressionBuilderRegistry extends RegistryImpl<QName, DomainExpressionBuilder> 
     implements BusExtension {
     
     private static final ResourceBundle BUNDLE = BundleUtils.getBundle(AssertionBuilderRegistry.class);
     
+    private boolean dynamicLoaded;
+    private Bus bus;
     public DomainExpressionBuilderRegistry() {
         super(null);
     }
+    public DomainExpressionBuilderRegistry(Bus b) {
+        super(null);
+        setBus(b);
+    }
 
     public DomainExpressionBuilderRegistry(Map<QName, DomainExpressionBuilder> builders) {
         super(builders);
@@ -52,13 +63,34 @@ public class DomainExpressionBuilderRegi
     public DomainExpressionBuilderRegistry(MapProvider<QName, DomainExpressionBuilder> builders) {
         super(builders.createMap());
     }
-    
+    @Resource
+    public final void setBus(Bus b) {
+        bus = b;
+        if (b != null) {
+            b.setExtension(this, DomainExpressionBuilderRegistry.class);
+        }
+    }
+
     public Class<?> getRegistrationType() {
         return DomainExpressionBuilderRegistry.class;
     }
     
+    protected synchronized void loadDynamic() {
+        if (!dynamicLoaded && bus != null) {
+            dynamicLoaded = true;
+            ConfiguredBeanLocator c = bus.getExtension(ConfiguredBeanLocator.class);
+            if (c != null) {
+                for (DomainExpressionBuilder b : c.getBeansOfType(DomainExpressionBuilder.class)) {
+                    for  (QName q : b.getDomainExpressionTypes()) {
+                        register(q, b);
+                    }
+                }
+            }
+        }
+    }
+
     public DomainExpression build(Element element) {
-        
+        loadDynamic();
         DomainExpressionBuilder builder;
 
         QName qname = new QName(element.getNamespaceURI(), element.getLocalName());

Added: cxf/trunk/rt/ws/policy/src/main/resources/META-INF/cxf/bus-extensions.xml
URL: http://svn.apache.org/viewvc/cxf/trunk/rt/ws/policy/src/main/resources/META-INF/cxf/bus-extensions.xml?rev=1071451&view=auto
==============================================================================
--- cxf/trunk/rt/ws/policy/src/main/resources/META-INF/cxf/bus-extensions.xml (added)
+++ cxf/trunk/rt/ws/policy/src/main/resources/META-INF/cxf/bus-extensions.xml Thu Feb 17 00:01:25 2011
@@ -0,0 +1,52 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+  Licensed to the Apache Software Foundation (ASF) under one
+  or more contributor license agreements. See the NOTICE file
+  distributed with this work for additional information
+  regarding copyright ownership. The ASF licenses this file
+  to you under the Apache License, Version 2.0 (the
+  "License"); you may not use this file except in compliance
+  with the License. You may obtain a copy of the License at
+ 
+  http://www.apache.org/licenses/LICENSE-2.0
+ 
+  Unless required by applicable law or agreed to in writing,
+  software distributed under the License is distributed on an
+  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+  KIND, either express or implied. See the License for the
+  specific language governing permissions and limitations
+  under the License.
+-->
+<extensions xmlns="http://cxf.apache.org/bus/extension">
+
+    <extension class="org.apache.cxf.ws.policy.PolicyEngineImpl" 
+        interface="org.apache.cxf.ws.policy.PolicyEngine" deferred="false"/>
+    <extension interface="org.apache.cxf.ws.policy.AssertionBuilderRegistry" 
+        class="org.apache.cxf.ws.policy.AssertionBuilderRegistryImpl"
+        deferred="true"/>
+        
+    <extension interface="org.apache.cxf.ws.policy.PolicyInterceptorProviderRegistry"
+        class="org.apache.cxf.ws.policy.PolicyInterceptorProviderRegistryImpl" deferred="true"/>
+    <extension interface="org.apache.cxf.ws.policy.PolicyBuilder" 
+        class="org.apache.cxf.ws.policy.PolicyBuilderImpl"
+        deferred="true"/>
+    <extension class="org.apache.cxf.ws.policy.PolicyAnnotationListener" deferred="true"/>
+
+    <extension class="org.apache.cxf.ws.policy.attachment.ServiceModelPolicyProvider"
+      deferred="true"/>
+
+    <extension class="org.apache.cxf.ws.policy.attachment.external.DomainExpressionBuilderRegistry"
+          deferred="true"/>
+          
+    <extension class="org.apache.cxf.ws.policy.attachment.external.EndpointReferenceDomainExpressionBuilder"
+      deferred="true"/> 
+    <extension class="org.apache.cxf.ws.policy.attachment.wsdl11.Wsdl11AttachmentPolicyProvider"
+      deferred="true"/>
+    
+    <!-- MTOM Policy Support -->
+    <extension class="org.apache.cxf.ws.policy.mtom.MTOMAssertionBuilder"
+      deferred="true"/>
+    <extension class="org.apache.cxf.ws.policy.mtom.MTOMPolicyInterceptorProvider"
+      deferred="true"/>
+        
+</extensions>
\ No newline at end of file

Propchange: cxf/trunk/rt/ws/policy/src/main/resources/META-INF/cxf/bus-extensions.xml
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: cxf/trunk/rt/ws/policy/src/main/resources/META-INF/cxf/bus-extensions.xml
------------------------------------------------------------------------------
    svn:keywords = Rev Date

Propchange: cxf/trunk/rt/ws/policy/src/main/resources/META-INF/cxf/bus-extensions.xml
------------------------------------------------------------------------------
    svn:mime-type = text/xml

Modified: cxf/trunk/rt/ws/policy/src/main/resources/META-INF/cxf/cxf-extension-policy.xml
URL: http://svn.apache.org/viewvc/cxf/trunk/rt/ws/policy/src/main/resources/META-INF/cxf/cxf-extension-policy.xml?rev=1071451&r1=1071450&r2=1071451&view=diff
==============================================================================
--- cxf/trunk/rt/ws/policy/src/main/resources/META-INF/cxf/cxf-extension-policy.xml (original)
+++ cxf/trunk/rt/ws/policy/src/main/resources/META-INF/cxf/cxf-extension-policy.xml Thu Feb 17 00:01:25 2011
@@ -25,37 +25,18 @@ http://www.springframework.org/schema/be
     <bean id="org.apache.cxf.ws.policy.AssertionBuilderRegistry" 
     	class="org.apache.cxf.ws.policy.AssertionBuilderRegistryImpl" lazy-init="true">
     	<constructor-arg ref="cxf"/>
-        <constructor-arg>
-            <bean class="org.apache.cxf.configuration.spring.SpringBeanQNameMap">
-              <property name="type" value="org.apache.cxf.ws.policy.AssertionBuilder"/>
-              <property name="idsProperty" value="knownElements"/>
-              <property name="staticFieldName"  value="KNOWN_ELEMENTS"/>
-            </bean>
-        </constructor-arg>
     </bean>
     
     <bean id="org.apache.cxf.ws.policy.PolicyInterceptorProviderRegistry"
     	class="org.apache.cxf.ws.policy.PolicyInterceptorProviderRegistryImpl"
     	lazy-init="true">
     	<constructor-arg ref="cxf"/>
-        <constructor-arg>
-            <bean class="org.apache.cxf.configuration.spring.SpringBeanQNameMap">
-              <property name="type" value="org.apache.cxf.ws.policy.PolicyInterceptorProvider"/>
-              <property name="idsProperty" value="assertionTypes"/>
-              <property name="staticFieldName"  value="ASSERTION_TYPES"/>
-            </bean>
-        </constructor-arg>
     </bean>   
     
     <bean id="org.apache.cxf.ws.policy.attachment.external.DomainExpressionBuilderRegistry" 
           class="org.apache.cxf.ws.policy.attachment.external.DomainExpressionBuilderRegistry"
           lazy-init="true">
-        <constructor-arg>
-            <bean class="org.apache.cxf.configuration.spring.SpringBeanQNameMap">
-              <property name="type" value="org.apache.cxf.ws.policy.attachment.external.DomainExpressionBuilder"/>
-              <property name="idsProperty" value="domainExpressionTypes"/>
-            </bean>
-        </constructor-arg>
+        <constructor-arg ref="cxf"/>
     </bean>   
     
     <bean class="org.apache.cxf.ws.policy.attachment.external.EndpointReferenceDomainExpressionBuilder"
@@ -65,8 +46,7 @@ http://www.springframework.org/schema/be
     <bean id="org.apache.cxf.ws.policy.PolicyBuilder" 
     	class="org.apache.cxf.ws.policy.PolicyBuilderImpl"
     	lazy-init="true">
-        <property name="bus" ref="cxf"/>
-        <property name="assertionBuilderRegistry" ref="org.apache.cxf.ws.policy.AssertionBuilderRegistry"/>
+        <constructor-arg ref="cxf"/>
     </bean>
   
     <bean id="org.apache.cxf.ws.policy.PolicyEngine" 



Mime
View raw message