Author: thomas.diesler(a)jboss.com
Date: 2007-08-01 10:33:13 -0400 (Wed, 01 Aug 2007)
New Revision: 4054
Added:
trunk/integration/jboss50/src/main/java/org/jboss/wsf/container/jboss50/serviceref/ServiceRefHandlerFactoryImpl.java
trunk/integration/jboss50/src/main/resources/jbossws-jboss50.jar/META-INF/services/org.jboss.wsf.spi.serviceref.ServiceRefHandlerFactory
Removed:
trunk/integration/spi/src/main/java/org/jboss/wsf/framework/serviceref/DefaultServiceRefHandlerFactory.java
Modified:
trunk/integration/jboss40/src/main/java/org/jboss/wsf/container/jboss40/WebServiceClientDeployer.java
trunk/integration/jboss50/src/main/resources/jbossws-jboss50.deployer/META-INF/jbossws-deployer-beans.xml
trunk/integration/spi/src/main/java/org/jboss/wsf/framework/DefaultSPIProviderResolver.java
Log:
Fix ServiceRefHandlerFactory for AS50
Modified:
trunk/integration/jboss40/src/main/java/org/jboss/wsf/container/jboss40/WebServiceClientDeployer.java
===================================================================
---
trunk/integration/jboss40/src/main/java/org/jboss/wsf/container/jboss40/WebServiceClientDeployer.java 2007-08-01
14:13:43 UTC (rev 4053)
+++
trunk/integration/jboss40/src/main/java/org/jboss/wsf/container/jboss40/WebServiceClientDeployer.java 2007-08-01
14:33:13 UTC (rev 4054)
@@ -34,9 +34,9 @@
import org.jboss.deployment.DeploymentInfo;
import org.jboss.system.ServiceMBeanSupport;
import org.jboss.webservice.metadata.serviceref.ServiceRefMetaData;
+import org.jboss.wsf.container.jboss50.serviceref.DefaultServiceRefHandlerFactory;
import org.jboss.wsf.framework.deployment.ResourceLoaderAdapter;
import org.jboss.wsf.framework.deployment.URLLoaderAdapter;
-import org.jboss.wsf.framework.serviceref.DefaultServiceRefHandlerFactory;
import org.jboss.wsf.spi.SPIProvider;
import org.jboss.wsf.spi.SPIProviderResolver;
import org.jboss.wsf.spi.deployment.UnifiedVirtualFile;
Added:
trunk/integration/jboss50/src/main/java/org/jboss/wsf/container/jboss50/serviceref/ServiceRefHandlerFactoryImpl.java
===================================================================
---
trunk/integration/jboss50/src/main/java/org/jboss/wsf/container/jboss50/serviceref/ServiceRefHandlerFactoryImpl.java
(rev 0)
+++
trunk/integration/jboss50/src/main/java/org/jboss/wsf/container/jboss50/serviceref/ServiceRefHandlerFactoryImpl.java 2007-08-01
14:33:13 UTC (rev 4054)
@@ -0,0 +1,41 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site:
http://www.fsf.org.
+ */
+package org.jboss.wsf.container.jboss50.serviceref;
+
+//$Id: ServiceRefHandlerFactory.java 4049 2007-08-01 11:26:30Z thomas.diesler(a)jboss.com
$
+
+import org.jboss.wsf.spi.serviceref.ServiceRefHandler;
+import org.jboss.wsf.spi.serviceref.ServiceRefHandlerFactory;
+
+/**
+ * A factory for the ServiceRefHandler
+ *
+ * @author Thomas.Diesler(a)jboss.org
+ * @since 05-May-2004
+ */
+public class ServiceRefHandlerFactoryImpl implements ServiceRefHandlerFactory
+{
+ public ServiceRefHandler getServiceRefHandler()
+ {
+ return new ServiceRefHandlerImpl();
+ }
+}
Modified:
trunk/integration/jboss50/src/main/resources/jbossws-jboss50.deployer/META-INF/jbossws-deployer-beans.xml
===================================================================
---
trunk/integration/jboss50/src/main/resources/jbossws-jboss50.deployer/META-INF/jbossws-deployer-beans.xml 2007-08-01
14:13:43 UTC (rev 4053)
+++
trunk/integration/jboss50/src/main/resources/jbossws-jboss50.deployer/META-INF/jbossws-deployer-beans.xml 2007-08-01
14:33:13 UTC (rev 4054)
@@ -17,10 +17,6 @@
<property name="mainDeployer"><inject
bean="MainDeployer"/></property>
</bean>
- <!-- Bind Service objects in client environment context -->
- <bean name="WSServiceRefHandler"
class="org.jboss.wsf.container.jboss50.serviceref.ServiceRefHandlerImpl">
- </bean>
-
<!--
*********************************************************************************************************************
Web Service deployment
Added:
trunk/integration/jboss50/src/main/resources/jbossws-jboss50.jar/META-INF/services/org.jboss.wsf.spi.serviceref.ServiceRefHandlerFactory
===================================================================
---
trunk/integration/jboss50/src/main/resources/jbossws-jboss50.jar/META-INF/services/org.jboss.wsf.spi.serviceref.ServiceRefHandlerFactory
(rev 0)
+++
trunk/integration/jboss50/src/main/resources/jbossws-jboss50.jar/META-INF/services/org.jboss.wsf.spi.serviceref.ServiceRefHandlerFactory 2007-08-01
14:33:13 UTC (rev 4054)
@@ -0,0 +1 @@
+org.jboss.wsf.container.jboss50.serviceref.ServiceRefHandlerFactoryImpl
\ No newline at end of file
Modified:
trunk/integration/spi/src/main/java/org/jboss/wsf/framework/DefaultSPIProviderResolver.java
===================================================================
---
trunk/integration/spi/src/main/java/org/jboss/wsf/framework/DefaultSPIProviderResolver.java 2007-08-01
14:13:43 UTC (rev 4053)
+++
trunk/integration/spi/src/main/java/org/jboss/wsf/framework/DefaultSPIProviderResolver.java 2007-08-01
14:33:13 UTC (rev 4054)
@@ -29,7 +29,6 @@
import org.jboss.wsf.framework.http.DefaultHttpContextFactory;
import org.jboss.wsf.framework.http.DefaultHttpServerFactory;
import org.jboss.wsf.framework.invocation.DefaultResourceInjectorFactory;
-import org.jboss.wsf.framework.serviceref.DefaultServiceRefHandlerFactory;
import org.jboss.wsf.spi.SPIProvider;
import org.jboss.wsf.spi.SPIProviderResolver;
import org.jboss.wsf.spi.WSFException;
@@ -101,10 +100,6 @@
{
returnType = (T)loadService(spiType,
DefaultResourceInjectorFactory.class.getName());
}
- else if (ServiceRefHandlerFactory.class.equals(spiType))
- {
- returnType = (T)loadService(spiType,
DefaultServiceRefHandlerFactory.class.getName());
- }
// SPI provided by either container or stack integration
@@ -132,6 +127,10 @@
{
returnType = (T)loadService(spiType, null);
}
+ else if (ServiceRefHandlerFactory.class.equals(spiType))
+ {
+ returnType = (T)loadService(spiType, null);
+ }
else if (WebServiceContextFactory.class.equals(spiType))
{
returnType = (T)loadService(spiType, null);
Deleted:
trunk/integration/spi/src/main/java/org/jboss/wsf/framework/serviceref/DefaultServiceRefHandlerFactory.java
===================================================================
---
trunk/integration/spi/src/main/java/org/jboss/wsf/framework/serviceref/DefaultServiceRefHandlerFactory.java 2007-08-01
14:13:43 UTC (rev 4053)
+++
trunk/integration/spi/src/main/java/org/jboss/wsf/framework/serviceref/DefaultServiceRefHandlerFactory.java 2007-08-01
14:33:13 UTC (rev 4054)
@@ -1,72 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site:
http://www.fsf.org.
- */
-package org.jboss.wsf.framework.serviceref;
-
-//$Id: ServiceRefHandlerFactory.java 4049 2007-08-01 11:26:30Z thomas.diesler(a)jboss.com
$
-
-import org.jboss.kernel.Kernel;
-import org.jboss.kernel.spi.registry.KernelRegistry;
-import org.jboss.kernel.spi.registry.KernelRegistryEntry;
-import org.jboss.wsf.common.ServiceLoader;
-import org.jboss.wsf.common.KernelLocator;
-import org.jboss.wsf.spi.serviceref.ServiceRefHandler;
-import org.jboss.wsf.spi.serviceref.ServiceRefHandlerFactory;
-
-/**
- * A factory for the ServiceRefHandler
- *
- * @author Thomas.Diesler(a)jboss.org
- * @since 05-May-2004
- */
-public class DefaultServiceRefHandlerFactory implements ServiceRefHandlerFactory
-{
- public ServiceRefHandler getServiceRefHandler()
- {
- ServiceRefHandler handler;
- if (KernelLocator.getKernel() != null)
- {
- handler = getServerSideServiceRefHandler();
- }
- else
- {
- handler = getClientSideServiceRefHandler();
- }
- return handler;
- }
-
- private ServiceRefHandler getServerSideServiceRefHandler()
- {
- Kernel kernel = KernelLocator.getKernel();
- KernelRegistry registry = kernel.getRegistry();
- KernelRegistryEntry entry = registry.getEntry(ServiceRefHandler.BEAN_NAME);
- ServiceRefHandler handler = (ServiceRefHandler)entry.getTarget();
- return handler;
- }
-
- private ServiceRefHandler getClientSideServiceRefHandler()
- {
- String propName = ServiceRefHandler.class.getName();
- String defaultImpl = "org.jboss.ws.integration.ServiceRefHandlerImpl";
- ServiceRefHandler handler = (ServiceRefHandler) ServiceLoader.loadService(propName,
defaultImpl);
- return handler;
- }
-}