Author: heiko.braun(a)jboss.com
Date: 2008-03-08 14:08:49 -0500 (Sat, 08 Mar 2008)
New Revision: 5896
Added:
stack/native/branches/hbraun/src/main/java/org/jboss/wsf/stack/jbws/standalone/
stack/native/branches/hbraun/src/main/java/org/jboss/wsf/stack/jbws/standalone/EmbeddedBootstrap.java
stack/native/branches/hbraun/src/main/java/org/jboss/wsf/stack/jbws/standalone/HttpEndpointPublishAspect.java
stack/native/branches/hbraun/src/main/java/org/jboss/wsf/stack/jbws/standalone/InvocationHandlerJSE.java
stack/native/branches/hbraun/src/main/java/org/jboss/wsf/stack/jbws/standalone/JSEInvocationHandlerFactory.java
stack/native/branches/hbraun/src/main/java/org/jboss/wsf/stack/jbws/standalone/NoopWebServiceContextFactory.java
stack/native/branches/hbraun/src/main/java/org/jboss/wsf/stack/jbws/standalone/StandaloneContainer.java
stack/native/branches/hbraun/src/main/java/org/jboss/wsf/stack/jbws/standalone/StandaloneServerConfig.java
stack/native/branches/hbraun/src/main/java/org/jboss/wsf/stack/jbws/standalone/standalone-config.xml
stack/native/branches/hbraun/src/main/resources/jbossws-standalone.jar/
stack/native/branches/hbraun/src/main/resources/jbossws-standalone.jar/META-INF/
stack/native/branches/hbraun/src/main/resources/jbossws-standalone.jar/META-INF/services/
stack/native/branches/hbraun/src/main/resources/jbossws-standalone.jar/META-INF/services/org.jboss.wsf.spi.deployment.DeploymentModelFactory
stack/native/branches/hbraun/src/main/resources/jbossws-standalone.jar/META-INF/services/org.jboss.wsf.spi.invocation.InvocationHandlerFactory
stack/native/branches/hbraun/src/main/resources/jbossws-standalone.jar/META-INF/services/org.jboss.wsf.spi.invocation.WebServiceContextFactory
stack/native/branches/hbraun/src/main/resources/jbossws-standalone.jar/META-INF/services/org.jboss.wsf.spi.management.ServerConfigFactory
stack/native/branches/hbraun/src/test/java/org/jboss/test/ws/container/
stack/native/branches/hbraun/src/test/java/org/jboss/test/ws/container/ContainerTestCase.java
stack/native/branches/hbraun/src/test/java/org/jboss/test/ws/container/HelloWorldEndpoint.java
stack/native/branches/hbraun/src/test/java/org/jboss/test/ws/container/HelloWorldSEI.java
Modified:
stack/native/branches/hbraun/build.xml
Log:
Embedded container first cut
Modified: stack/native/branches/hbraun/build.xml
===================================================================
--- stack/native/branches/hbraun/build.xml 2008-03-08 19:07:17 UTC (rev 5895)
+++ stack/native/branches/hbraun/build.xml 2008-03-08 19:08:49 UTC (rev 5896)
@@ -154,6 +154,12 @@
<classpath path="${core.output.classes14.dir}"/>
<classpath refid="thirdparty.classpath"/>
</javac>
+
+ <copy todir="${core.output.classes.dir}">
+ <fileset dir="${core.java.dir}">
+ <include name="**/*.xml"/>
+ </fileset>
+ </copy>
</target>
<!-- Compile etc files (manifests and such) -->
@@ -257,7 +263,7 @@
<jar jarfile="${core.output.lib.dir}/jbossws-core.jar"
manifest="${core.output.etc.dir}/default.mf">
<fileset dir="${core.output.classes.dir}">
<include name="org/jboss/annotation/**"/>
- <include name="org/jboss/wsf/stack/jbws/**"/>
+ <include name="org/jboss/wsf/stack/jbws/*"/>
<include name="org/jboss/ws/**"/>
</fileset>
<fileset dir="${core.resources.dir}">
@@ -267,7 +273,17 @@
<metainf dir="${core.resources.dir}/jbossws-core.jar/META-INF"/>
</jar>
- <!-- Build jbossws-client.jar -->
+ <!-- Build jbossws-standalone.jar -->
+ <mkdir dir="${core.output.lib.dir}"/>
+ <jar jarfile="${core.output.lib.dir}/jbossws-standalone.jar"
manifest="${core.output.etc.dir}/default.mf">
+ <fileset dir="${core.output.classes.dir}">
+ <include name="org/jboss/wsf/stack/jbws/standalone/**"/>
+ </fileset>
+ <metainf
dir="${core.resources.dir}/jbossws-standalone.jar/META-INF"/>
+ </jar>
+
+
+ <!-- Build jbossws-client.jar -->
<jar jarfile="${core.output.lib.dir}/jbossws-client.jar"
manifest="${core.output.etc.dir}/default.mf">
<fileset dir="${core.output.classes.dir}">
<include name="org/jboss/wsf/**"/>
Added:
stack/native/branches/hbraun/src/main/java/org/jboss/wsf/stack/jbws/standalone/EmbeddedBootstrap.java
===================================================================
---
stack/native/branches/hbraun/src/main/java/org/jboss/wsf/stack/jbws/standalone/EmbeddedBootstrap.java
(rev 0)
+++
stack/native/branches/hbraun/src/main/java/org/jboss/wsf/stack/jbws/standalone/EmbeddedBootstrap.java 2008-03-08
19:08:49 UTC (rev 5896)
@@ -0,0 +1,81 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2006, Red Hat Middleware LLC, and individual contributors
+ * as indicated by the @author tags. See the copyright.txt file 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.stack.jbws.standalone;
+
+import org.jboss.kernel.plugins.deployment.xml.BasicXMLDeployer;
+import org.jboss.kernel.plugins.bootstrap.basic.BasicBootstrap;
+
+import java.net.URL;
+
+/**
+ * Add a BasicXMLDeployer to the BasicBootstrap so that we can parse
+ * XML descriptors for the beans (*-beans.xml).
+ *
+ * @author <a href="mailto:mark.newton@jboss.org">Mark Newton</a>
+ */
+public class EmbeddedBootstrap extends BasicBootstrap
+{
+
+ protected BasicXMLDeployer deployer;
+
+ public EmbeddedBootstrap() throws Exception {
+ super();
+ }
+
+ public void bootstrap() throws Throwable {
+ super.bootstrap();
+ deployer = new BasicXMLDeployer(getKernel());
+ Runtime.getRuntime().addShutdownHook(new Shutdown());
+ }
+
+ public void deploy(URL url) {
+ try {
+ // Workaround the fact that the BasicXMLDeployer does not handle redeployment
correctly
+ if (deployer.getDeploymentNames().contains(url.toString())) {
+ System.out.println("Service is already deployed.");
+ return;
+ }
+ deployer.deploy(url);
+ } catch (Throwable t) {
+ throw new RuntimeException("Error during deployment: " + url, t);
+ }
+ }
+
+ public void undeploy(URL url) {
+ if (!deployer.getDeploymentNames().contains(url.toString())) {
+ System.out.println("Service is already undeployed.");
+ return;
+ }
+ try {
+ deployer.undeploy(url);
+ } catch (Throwable t) {
+ throw new RuntimeException("Error during undeployment: " + url, t);
+ }
+ }
+
+ protected class Shutdown extends Thread {
+ public void run() {
+ log.info("Shutting down");
+ deployer.shutdown();
+ }
+ }
+}
\ No newline at end of file
Property changes on:
stack/native/branches/hbraun/src/main/java/org/jboss/wsf/stack/jbws/standalone/EmbeddedBootstrap.java
___________________________________________________________________
Name: svn:keywords
+ Id Revision
Name: svn:eol-style
+ LF
Added:
stack/native/branches/hbraun/src/main/java/org/jboss/wsf/stack/jbws/standalone/HttpEndpointPublishAspect.java
===================================================================
---
stack/native/branches/hbraun/src/main/java/org/jboss/wsf/stack/jbws/standalone/HttpEndpointPublishAspect.java
(rev 0)
+++
stack/native/branches/hbraun/src/main/java/org/jboss/wsf/stack/jbws/standalone/HttpEndpointPublishAspect.java 2008-03-08
19:08:49 UTC (rev 5896)
@@ -0,0 +1,62 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2006, Red Hat Middleware LLC, and individual contributors
+ * as indicated by the @author tags. See the copyright.txt file 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.stack.jbws.standalone;
+
+import org.jboss.wsf.spi.SPIProvider;
+import org.jboss.wsf.spi.SPIProviderResolver;
+import org.jboss.wsf.spi.deployment.Deployment;
+import org.jboss.wsf.spi.deployment.DeploymentAspect;
+import org.jboss.wsf.spi.deployment.Endpoint;
+import org.jboss.wsf.spi.transport.*;
+
+/**
+ * @author Heiko.Braun <heiko.braun(a)jboss.com>
+ */
+public class HttpEndpointPublishAspect extends DeploymentAspect
+{
+
+ public void start(Deployment dep)
+ {
+ String webcontext = dep.getService().getContextRoot();
+ assert webcontext!=null;
+ assert dep.getService().getEndpoints().size()>0;
+
+ Endpoint endpoint = dep.getService().getEndpoints().get(0);
+ String urlPattern = endpoint.getURLPattern();
+
+ SPIProvider spi = SPIProviderResolver.getInstance().getProvider();
+ TransportManagerFactory tmf = spi.getSPI(TransportManagerFactory.class);
+ TransportManager<HttpSpec> http = tmf.createTransportManager(Protocol.HTTP);
+
+ HttpSpec spec = new HttpSpec(webcontext, urlPattern);
+ ListenerRef ref = http.createListener(endpoint, spec);
+
+ // Update endpoint address
+ endpoint.setAddress(ref.getAddress().toString());
+ endpoint.addAttachment(ListenerRef.class, ref);
+ }
+
+ public void stop(Deployment dep)
+ {
+ super.stop(dep);
+ }
+}
Property changes on:
stack/native/branches/hbraun/src/main/java/org/jboss/wsf/stack/jbws/standalone/HttpEndpointPublishAspect.java
___________________________________________________________________
Name: svn:keywords
+ Id Revision
Name: svn:eol-style
+ LF
Added:
stack/native/branches/hbraun/src/main/java/org/jboss/wsf/stack/jbws/standalone/InvocationHandlerJSE.java
===================================================================
---
stack/native/branches/hbraun/src/main/java/org/jboss/wsf/stack/jbws/standalone/InvocationHandlerJSE.java
(rev 0)
+++
stack/native/branches/hbraun/src/main/java/org/jboss/wsf/stack/jbws/standalone/InvocationHandlerJSE.java 2008-03-08
19:08:49 UTC (rev 5896)
@@ -0,0 +1,112 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2006, Red Hat Middleware LLC, and individual contributors
+ * as indicated by the @author tags. See the copyright.txt file 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.stack.jbws.standalone;
+
+import org.jboss.wsf.spi.invocation.InvocationHandler;
+import org.jboss.wsf.spi.invocation.Invocation;
+import org.jboss.wsf.spi.invocation.InvocationContext;
+import org.jboss.wsf.spi.deployment.Endpoint;
+import org.jboss.wsf.common.JavaUtils;
+
+import javax.xml.ws.WebServiceContext;
+import java.lang.reflect.Method;
+
+/**
+ * @author Heiko.Braun <heiko.braun(a)jboss.com>
+ */
+public class InvocationHandlerJSE extends InvocationHandler
+{
+ public InvocationHandlerJSE()
+ {
+ }
+
+ public Invocation createInvocation()
+ {
+ return new Invocation();
+ }
+
+ public void init(Endpoint ep)
+ {
+ }
+
+ protected Object getTargetBean(Endpoint ep, Invocation epInv)
+ {
+ InvocationContext invCtx = epInv.getInvocationContext();
+ Object targetBean = invCtx.getTargetBean();
+ if (targetBean == null)
+ {
+ try
+ {
+ Class epImpl = ep.getTargetBeanClass();
+ targetBean = epImpl.newInstance();
+ invCtx.setTargetBean(targetBean);
+ }
+ catch (Exception ex)
+ {
+ throw new IllegalStateException("Cannot get target bean instance",
ex);
+ }
+ }
+ return targetBean;
+ }
+
+ public void invoke(Endpoint ep, Invocation epInv) throws Exception
+ {
+ try
+ {
+ Object targetBean = getTargetBean(ep, epInv);
+
+ InvocationContext invContext = epInv.getInvocationContext();
+ WebServiceContext wsContext =
invContext.getAttachment(WebServiceContext.class);
+ if (wsContext != null)
+ {
+ // TODO: ResourceInjection not supported
+ }
+
+ Method method = getImplMethod(targetBean.getClass(), epInv.getJavaMethod());
+ Object retObj = method.invoke(targetBean, epInv.getArgs());
+ epInv.setReturnValue(retObj);
+ }
+ catch (Exception e)
+ {
+ handleInvocationException(e);
+ }
+ }
+
+ protected Method getImplMethod(Class implClass, Method seiMethod) throws
ClassNotFoundException, NoSuchMethodException
+ {
+ String methodName = seiMethod.getName();
+ Class[] paramTypes = seiMethod.getParameterTypes();
+ for (int i = 0; i < paramTypes.length; i++)
+ {
+ Class paramType = paramTypes[i];
+ if (JavaUtils.isPrimitive(paramType) == false)
+ {
+ String paramTypeName = paramType.getName();
+ paramType = JavaUtils.loadJavaType(paramTypeName);
+ paramTypes[i] = paramType;
+ }
+ }
+
+ Method implMethod = implClass.getMethod(methodName, paramTypes);
+ return implMethod;
+ }
+}
\ No newline at end of file
Property changes on:
stack/native/branches/hbraun/src/main/java/org/jboss/wsf/stack/jbws/standalone/InvocationHandlerJSE.java
___________________________________________________________________
Name: svn:keywords
+ Id Revision
Name: svn:eol-style
+ LF
Added:
stack/native/branches/hbraun/src/main/java/org/jboss/wsf/stack/jbws/standalone/JSEInvocationHandlerFactory.java
===================================================================
---
stack/native/branches/hbraun/src/main/java/org/jboss/wsf/stack/jbws/standalone/JSEInvocationHandlerFactory.java
(rev 0)
+++
stack/native/branches/hbraun/src/main/java/org/jboss/wsf/stack/jbws/standalone/JSEInvocationHandlerFactory.java 2008-03-08
19:08:49 UTC (rev 5896)
@@ -0,0 +1,51 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2006, Red Hat Middleware LLC, and individual contributors
+ * as indicated by the @author tags. See the copyright.txt file 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.stack.jbws.standalone;
+
+import org.jboss.wsf.spi.invocation.InvocationHandler;
+import org.jboss.wsf.spi.invocation.InvocationHandlerFactory;
+import org.jboss.wsf.spi.invocation.InvocationType;
+
+/**
+ * @author Heiko.Braun <heiko.braun(a)jboss.com>
+ */
+public class JSEInvocationHandlerFactory extends InvocationHandlerFactory
+{
+ public InvocationHandler newInvocationHandler(InvocationType type)
+ {
+ InvocationHandler handler = null;
+
+ switch(type)
+ {
+ case JAXWS_JSE:
+ handler = new InvocationHandlerJSE();
+ break;
+ }
+
+ if(null == handler)
+ throw new IllegalArgumentException("Unable to resolve
spi.invocation.InvocationHandler for type " +type);
+
+ return handler;
+ }
+
+}
+
Added:
stack/native/branches/hbraun/src/main/java/org/jboss/wsf/stack/jbws/standalone/NoopWebServiceContextFactory.java
===================================================================
---
stack/native/branches/hbraun/src/main/java/org/jboss/wsf/stack/jbws/standalone/NoopWebServiceContextFactory.java
(rev 0)
+++
stack/native/branches/hbraun/src/main/java/org/jboss/wsf/stack/jbws/standalone/NoopWebServiceContextFactory.java 2008-03-08
19:08:49 UTC (rev 5896)
@@ -0,0 +1,61 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2006, Red Hat Middleware LLC, and individual contributors
+ * as indicated by the @author tags. See the copyright.txt file 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.stack.jbws.standalone;
+
+import org.jboss.wsf.spi.invocation.ExtensibleWebServiceContext;
+import org.jboss.wsf.spi.invocation.InvocationType;
+import org.jboss.wsf.spi.invocation.WebServiceContextFactory;
+
+import javax.xml.ws.handler.MessageContext;
+import java.security.Principal;
+
+/**
+ * @author Heiko.Braun <heiko.braun(a)jboss.com>
+ */
+public class NoopWebServiceContextFactory extends WebServiceContextFactory
+{
+ final static ExtensibleWebServiceContext NOOP_CONTEXT = new
NoopWebServiceContext(null);
+
+ public ExtensibleWebServiceContext newWebServiceContext(InvocationType type,
MessageContext messageContext)
+ {
+ return NOOP_CONTEXT;
+ }
+
+ static class NoopWebServiceContext extends ExtensibleWebServiceContext
+ {
+
+ public NoopWebServiceContext(MessageContext messageContext)
+ {
+ super(messageContext);
+ }
+
+ public Principal getUserPrincipal()
+ {
+ throw new RuntimeException("Noop");
+ }
+
+ public boolean isUserInRole(String role)
+ {
+ throw new RuntimeException("Noop");
+ }
+ }
+}
Property changes on:
stack/native/branches/hbraun/src/main/java/org/jboss/wsf/stack/jbws/standalone/NoopWebServiceContextFactory.java
___________________________________________________________________
Name: svn:keywords
+ Id Revision
Name: svn:eol-style
+ LF
Added:
stack/native/branches/hbraun/src/main/java/org/jboss/wsf/stack/jbws/standalone/StandaloneContainer.java
===================================================================
---
stack/native/branches/hbraun/src/main/java/org/jboss/wsf/stack/jbws/standalone/StandaloneContainer.java
(rev 0)
+++
stack/native/branches/hbraun/src/main/java/org/jboss/wsf/stack/jbws/standalone/StandaloneContainer.java 2008-03-08
19:08:49 UTC (rev 5896)
@@ -0,0 +1,127 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2006, Red Hat Middleware LLC, and individual contributors
+ * as indicated by the @author tags. See the copyright.txt file 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.stack.jbws.standalone;
+
+import org.jboss.wsf.spi.SPIProvider;
+import org.jboss.wsf.spi.SPIProviderResolver;
+import org.jboss.wsf.spi.Container;
+import org.jboss.wsf.spi.transport.TransportManager;
+import org.jboss.wsf.spi.transport.HttpSpec;
+import org.jboss.wsf.spi.transport.TransportManagerFactory;
+import org.jboss.wsf.spi.transport.Protocol;
+import org.jboss.wsf.spi.deployment.Endpoint;
+import org.jboss.wsf.spi.deployment.DeploymentAspectManager;
+import org.jboss.wsf.spi.deployment.DeploymentAspectManagerFactory;
+import org.jboss.wsf.spi.deployment.Deployment;
+import org.jboss.wsf.spi.management.EndpointRegistry;
+import org.jboss.wsf.spi.management.EndpointRegistryFactory;
+import org.jboss.kernel.Kernel;
+import org.jboss.kernel.spi.dependency.KernelController;
+import org.jboss.kernel.spi.registry.KernelBus;
+
+import java.net.URL;
+
+/**
+ * A JBossWS container that bootstraps through
+ * the {@link org.jboss.wsf.spi.SPIProvider}
+ *
+ * @author Heiko.Braun <heiko.braun(a)jboss.com>
+ */
+public class StandaloneContainer implements Container
+{
+ private SPIProvider spi;
+
+ private Kernel kernel;
+ private KernelController controller;
+ private KernelBus bus;
+
+ private EndpointRegistry registry;
+ private TransportManager<HttpSpec> httpTransport;
+ private DeploymentAspectManager deploymentManager;
+
+ private StandaloneContainer(Kernel kernel, KernelController controller, KernelBus
bus)
+ {
+ this.kernel = kernel;
+ this.controller = controller;
+ this.bus = bus;
+ this.spi = SPIProviderResolver.getInstance().getProvider();
+ }
+
+ public static StandaloneContainer bootstrap(URL jbosswsBeansXml) throws Exception
+ {
+ EmbeddedBootstrap bootstrap = new EmbeddedBootstrap();
+ bootstrap.run();
+ bootstrap.deploy(jbosswsBeansXml);
+
+ Kernel kernel = bootstrap.getKernel();
+ StandaloneContainer container = new StandaloneContainer(kernel,
kernel.getController(), kernel.getBus());
+ container.assemble();
+ return container;
+ }
+
+ private void assemble()
+ {
+ // Registry
+ EndpointRegistryFactory erf = spi.getSPI(EndpointRegistryFactory.class);
+ registry = erf.getEndpointRegistry();
+
+ // Http Transport
+ TransportManagerFactory tmf = spi.getSPI(TransportManagerFactory.class);
+ httpTransport = tmf.createTransportManager(Protocol.HTTP);
+
+ // DeploymentAspcetManager
+ DeploymentAspectManagerFactory daf =
spi.getSPI(DeploymentAspectManagerFactory.class);
+ deploymentManager =
daf.getDeploymentAspectManager("WSDeploymentAspectManagerJSE");
+ }
+
+ public void publish(Deployment deployment)
+ {
+ /*
+ 1. create runtime model (deployment aspects)
+ 2. add request handler
+ 3. add invocation handler
+ 4. register endpoint
+ 5. create transport listener
+ */
+ deploymentManager.deploy(deployment);
+
+ }
+
+ public void remove(Deployment deployment)
+ {
+ /*
+ 1. remove transport listener
+ 2. remove endpoint from registry
+ */
+ }
+
+
+ public void publish(Endpoint endpoint)
+ {
+
+ }
+
+ public void remove(Endpoint endpoint)
+ {
+
+ }
+}
\ No newline at end of file
Property changes on:
stack/native/branches/hbraun/src/main/java/org/jboss/wsf/stack/jbws/standalone/StandaloneContainer.java
___________________________________________________________________
Name: svn:keywords
+ Id Revision
Name: svn:eol-style
+ LF
Added:
stack/native/branches/hbraun/src/main/java/org/jboss/wsf/stack/jbws/standalone/StandaloneServerConfig.java
===================================================================
---
stack/native/branches/hbraun/src/main/java/org/jboss/wsf/stack/jbws/standalone/StandaloneServerConfig.java
(rev 0)
+++
stack/native/branches/hbraun/src/main/java/org/jboss/wsf/stack/jbws/standalone/StandaloneServerConfig.java 2008-03-08
19:08:49 UTC (rev 5896)
@@ -0,0 +1,94 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2006, Red Hat Middleware LLC, and individual contributors
+ * as indicated by the @author tags. See the copyright.txt file 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.stack.jbws.standalone;
+
+import org.jboss.wsf.spi.management.ServerConfig;
+
+import java.io.File;
+import java.net.UnknownHostException;
+
+/**
+ * @author Heiko.Braun <heiko.braun(a)jboss.com>
+ */
+public class StandaloneServerConfig implements ServerConfig
+{
+
+ public String getImplementationTitle()
+ {
+ return "JBossWS Standalone";
+ }
+
+ public String getImplementationVersion()
+ {
+ return "3.0.0";
+ }
+
+ public File getServerTempDir()
+ {
+ return new File("/tmp"); // TODO: change to default
+ }
+
+ public File getServerDataDir()
+ {
+ return new File("/tmp"); //To change body of implemented methods use
File | Settings | File Templates.
+ }
+
+ public String getWebServiceHost()
+ {
+ return "localhost"; //To change body of implemented methods use File |
Settings | File Templates.
+ }
+
+ public void setWebServiceHost(String host) throws UnknownHostException
+ {
+ //To change body of implemented methods use File | Settings | File Templates.
+ }
+
+ public int getWebServicePort()
+ {
+ return 20000; // introduce constant
+ }
+
+ public void setWebServicePort(int port)
+ {
+ //To change body of implemented methods use File | Settings | File Templates.
+ }
+
+ public int getWebServiceSecurePort()
+ {
+ return 20001; // TODO: constant
+ }
+
+ public void setWebServiceSecurePort(int port)
+ {
+ //To change body of implemented methods use File | Settings | File Templates.
+ }
+
+ public boolean isModifySOAPAddress()
+ {
+ return true;
+ }
+
+ public void setModifySOAPAddress(boolean flag)
+ {
+
+ }
+}
Property changes on:
stack/native/branches/hbraun/src/main/java/org/jboss/wsf/stack/jbws/standalone/StandaloneServerConfig.java
___________________________________________________________________
Name: svn:keywords
+ Id Revision
Name: svn:eol-style
+ LF
Added:
stack/native/branches/hbraun/src/main/java/org/jboss/wsf/stack/jbws/standalone/standalone-config.xml
===================================================================
---
stack/native/branches/hbraun/src/main/java/org/jboss/wsf/stack/jbws/standalone/standalone-config.xml
(rev 0)
+++
stack/native/branches/hbraun/src/main/java/org/jboss/wsf/stack/jbws/standalone/standalone-config.xml 2008-03-08
19:08:49 UTC (rev 5896)
@@ -0,0 +1,130 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<deployment
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="urn:jboss:bean-deployer:2.0 bean-deployer_2_0.xsd"
xmlns="urn:jboss:bean-deployer:2.0">
+
+ <!--
+ ======================================================================
+ SPI Implementations
+ ======================================================================
+ -->
+
+ <bean name="WSKernelLocator"
class="org.jboss.wsf.spi.util.KernelLocator">
+ <property name="kernel"><inject
bean="jboss.kernel:service=Kernel"/></property>
+ </bean>
+
+ <bean name="WSServerConfig"
class="org.jboss.wsf.stack.jbws.standalone.StandaloneServerConfig">
+ <property name="webServiceHost">localhost</property>
+ <property name="modifySOAPAddress">true</property>
+ </bean>
+
+ <!-- The registry for web service endpoints -->
+ <bean name="WSEndpointRegistry"
class="org.jboss.wsf.framework.management.DefaultEndpointRegistry"/>
+
+ <!--
+ ======================================================================
+ Standalone DeploymentAspectManager
+ ======================================================================
+ -->
+
+ <bean name="WSDeploymentAspectManagerJSE"
class="org.jboss.wsf.framework.deployment.DeploymentAspectManagerImpl">
+ <property
name="name">WSDeploymentAspectManagerJSE</property>
+ </bean>
+
+ <!--
+ ======================================================================
+ Container deployment aspects
+ ======================================================================
+ -->
+
+ <bean name="WSEndpointLifecycleDeploymentAspect"
class="org.jboss.wsf.framework.deployment.EndpointLifecycleDeploymentAspect">
+ <property name="requires">LAST_DEPLOYMENT_ASPECT</property>
+ </bean>
+
+ <bean name="WSEndpointRegistryDeploymentAspect"
class="org.jboss.wsf.framework.deployment.EndpointRegistryDeploymentAspect">
+ <property name="provides">RegisteredEndpoint</property>
+ </bean>
+
+ <bean name="WSHttpTransportDeploymentAspect"
class="org.jboss.wsf.stack.jbws.standalone.HttpEndpointPublishAspect">
+ <property name="requires">RegisteredEndpoint</property>
+ <property name="provides">HttpTransport</property>
+ </bean>
+
+ <bean name="WSDeploymentAspectInstallerJSE"
class="org.jboss.wsf.framework.deployment.DeploymentAspectInstaller">
+ <property name="manager"><inject
bean="WSDeploymentAspectManagerJSE"/></property>
+ <property name="sortAspectsOnCreate">false</property>
+ <property name="aspects">
+ <set class="java.util.HashSet"
elementClass="org.jboss.wsf.spi.deployment.DeploymentAspect">
+ <inject bean="WSEndpointRegistryDeploymentAspect"/>
+ <inject bean="WSEndpointLifecycleDeploymentAspect"/>
+ </set>
+ </property>
+ </bean>
+
+ <!--
+ ==============================================================================
+ Stack deployment aspects
+ ==============================================================================
+ -->
+
+ <bean name="WSNativeEagerInitializeDeploymentAspect"
class="org.jboss.wsf.stack.jbws.EagerInitializeDeploymentAspect">
+ <property name="requires">UnifiedMetaDataModel</property>
+ <property
name="provides">InitializedMetaDataModel</property>
+ </bean>
+
+ <bean name="WSNativeEndpointHandlerDeploymentAspect"
class="org.jboss.wsf.framework.deployment.EndpointHandlerDeploymentAspect">
+ <!--property name="requires">ContainerEndpointHandler,
ContainerMetaData</property-->
+ <property name="provides">StackEndpointHandler</property>
+ </bean>
+
+ <bean name="WSNativeEventingDeploymentAspect"
class="org.jboss.wsf.stack.jbws.EventingDeploymentAspect">
+ <property name="requires">UnifiedMetaDataModel</property>
+ </bean>
+
+ <bean name="WSNativePublishContractDeploymentAspect"
class="org.jboss.wsf.stack.jbws.PublishContractDeploymentAspect">
+ <property name="requires">UnifiedMetaDataModel</property>
+ <property name="provides">PublishedContract</property>
+ </bean>
+
+ <bean name="WSNativeServiceEndpointInvokerDeploymentAspect"
class="org.jboss.wsf.stack.jbws.ServiceEndpointInvokerDeploymentAspect">
+ <property name="requires">UnifiedMetaDataModel</property>
+ </bean>
+
+ <bean name="WSNativeRMDeploymentAspect"
class="org.jboss.ws.extensions.wsrm.server.RMDeploymentAspect">
+ <property name="requires">StackEndpointHandler,
UnifiedMetaDataModel</property>
+ </bean>
+
+ <bean name="WSNativeUnifiedMetaDataDeploymentAspect"
class="org.jboss.wsf.stack.jbws.UnifiedMetaDataDeploymentAspect">
+ <property name="provides">UnifiedMetaDataModel</property>
+ </bean>
+
+ <!-- Deployment aspect installer -->
+
+ <bean name="WSNativeDeploymentAspectInstallerJSE"
class="org.jboss.wsf.framework.deployment.DeploymentAspectInstaller">
+ <property name="manager"><inject
bean="WSDeploymentAspectManagerJSE"/></property>
+ <property name="sortAspectsOnCreate">true</property>
+ <property name="aspects">
+ <set class="java.util.HashSet"
elementClass="org.jboss.wsf.spi.deployment.DeploymentAspect">
+ <inject bean="WSNativeEndpointHandlerDeploymentAspect"/>
+ <inject bean="WSNativeEventingDeploymentAspect"/>
+ <inject bean="WSNativePublishContractDeploymentAspect"/>
+ <inject
bean="WSNativeServiceEndpointInvokerDeploymentAspect"/>
+ <inject bean="WSNativeRMDeploymentAspect"/>
+ <inject bean="WSNativeUnifiedMetaDataDeploymentAspect"/>
+ <inject bean="WSNativeEagerInitializeDeploymentAspect"/>
+ <inject bean="WSHttpTransportDeploymentAspect"/>
+ </set>
+ </property>
+ <depends>WSDeploymentAspectManagerJSE</depends>
+ </bean>
+
+ <!--
+ ==============================================================================
+ Stack specific beans (not SPI)
+ ==============================================================================
+ -->
+
+ <!-- A subscription manager for WS-Eventing -->
+ <bean name="WSSubscriptionManager"
class="org.jboss.ws.extensions.eventing.mgmt.SubscriptionManager">
+ <property name="bindAddress">localhost</property>
+ </bean>
+
+</deployment>
Property changes on:
stack/native/branches/hbraun/src/main/java/org/jboss/wsf/stack/jbws/standalone/standalone-config.xml
___________________________________________________________________
Name: svn:keywords
+ Id Revision
Name: svn:eol-style
+ LF
Added:
stack/native/branches/hbraun/src/main/resources/jbossws-standalone.jar/META-INF/services/org.jboss.wsf.spi.deployment.DeploymentModelFactory
===================================================================
---
stack/native/branches/hbraun/src/main/resources/jbossws-standalone.jar/META-INF/services/org.jboss.wsf.spi.deployment.DeploymentModelFactory
(rev 0)
+++
stack/native/branches/hbraun/src/main/resources/jbossws-standalone.jar/META-INF/services/org.jboss.wsf.spi.deployment.DeploymentModelFactory 2008-03-08
19:08:49 UTC (rev 5896)
@@ -0,0 +1 @@
+org.jboss.wsf.framework.deployment.ArchiveDeploymentModelFactory
\ No newline at end of file
Added:
stack/native/branches/hbraun/src/main/resources/jbossws-standalone.jar/META-INF/services/org.jboss.wsf.spi.invocation.InvocationHandlerFactory
===================================================================
---
stack/native/branches/hbraun/src/main/resources/jbossws-standalone.jar/META-INF/services/org.jboss.wsf.spi.invocation.InvocationHandlerFactory
(rev 0)
+++
stack/native/branches/hbraun/src/main/resources/jbossws-standalone.jar/META-INF/services/org.jboss.wsf.spi.invocation.InvocationHandlerFactory 2008-03-08
19:08:49 UTC (rev 5896)
@@ -0,0 +1 @@
+org.jboss.wsf.stack.jbws.standalone.JSEInvocationHandlerFactory
\ No newline at end of file
Added:
stack/native/branches/hbraun/src/main/resources/jbossws-standalone.jar/META-INF/services/org.jboss.wsf.spi.invocation.WebServiceContextFactory
===================================================================
---
stack/native/branches/hbraun/src/main/resources/jbossws-standalone.jar/META-INF/services/org.jboss.wsf.spi.invocation.WebServiceContextFactory
(rev 0)
+++
stack/native/branches/hbraun/src/main/resources/jbossws-standalone.jar/META-INF/services/org.jboss.wsf.spi.invocation.WebServiceContextFactory 2008-03-08
19:08:49 UTC (rev 5896)
@@ -0,0 +1 @@
+org.jboss.wsf.stack.jbws.standalone.NoopWebServiceContextFactory
\ No newline at end of file
Added:
stack/native/branches/hbraun/src/main/resources/jbossws-standalone.jar/META-INF/services/org.jboss.wsf.spi.management.ServerConfigFactory
===================================================================
---
stack/native/branches/hbraun/src/main/resources/jbossws-standalone.jar/META-INF/services/org.jboss.wsf.spi.management.ServerConfigFactory
(rev 0)
+++
stack/native/branches/hbraun/src/main/resources/jbossws-standalone.jar/META-INF/services/org.jboss.wsf.spi.management.ServerConfigFactory 2008-03-08
19:08:49 UTC (rev 5896)
@@ -0,0 +1 @@
+org.jboss.wsf.framework.management.ServerConfigFactoryImpl
\ No newline at end of file
Added:
stack/native/branches/hbraun/src/test/java/org/jboss/test/ws/container/ContainerTestCase.java
===================================================================
---
stack/native/branches/hbraun/src/test/java/org/jboss/test/ws/container/ContainerTestCase.java
(rev 0)
+++
stack/native/branches/hbraun/src/test/java/org/jboss/test/ws/container/ContainerTestCase.java 2008-03-08
19:08:49 UTC (rev 5896)
@@ -0,0 +1,160 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2006, Red Hat Middleware LLC, and individual contributors
+ * as indicated by the @author tags. See the copyright.txt file 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.test.ws.container;
+
+import junit.framework.TestCase;
+import org.jboss.dependency.spi.ControllerContext;
+import org.jboss.kernel.Kernel;
+import org.jboss.kernel.spi.dependency.KernelController;
+import org.jboss.kernel.spi.registry.KernelBus;
+import org.jboss.wsf.common.ResourceLoaderAdapter;
+import org.jboss.wsf.spi.SPIProvider;
+import org.jboss.wsf.spi.SPIProviderResolver;
+import org.jboss.wsf.spi.deployment.ArchiveDeployment;
+import org.jboss.wsf.spi.deployment.Deployment;
+import org.jboss.wsf.spi.deployment.DeploymentModelFactory;
+import org.jboss.wsf.spi.deployment.Endpoint;
+import org.jboss.wsf.stack.jbws.standalone.EmbeddedBootstrap;
+import org.jboss.wsf.stack.jbws.standalone.StandaloneContainer;
+
+import javax.xml.ws.Service;
+import javax.xml.namespace.QName;
+import java.net.URL;
+import java.net.URLConnection;
+import java.io.IOException;
+import java.io.BufferedReader;
+import java.io.InputStreamReader;
+
+/**
+ * @author Heiko.Braun <heiko.braun(a)jboss.com>
+ */
+public class ContainerTestCase extends TestCase
+{
+ private URL standaloneConfig;
+
+ protected void setUp() throws Exception
+ {
+ ClassLoader cl =
org.jboss.wsf.stack.jbws.standalone.StandaloneContainer.class.getClassLoader();
+ String config =
"org/jboss/wsf/stack/jbws/standalone/standalone-config.xml";
+ standaloneConfig = cl.getResource(config);
+ if(null==standaloneConfig)
+ throw new RuntimeException("Unable to read config: "+config);
+ }
+
+ /**
+ * Check if the bootstrap in setup() works correctly
+ * @throws Exception
+ */
+ public void testBootStrap() throws Exception
+ {
+ EmbeddedBootstrap bootstrap = new EmbeddedBootstrap();
+ bootstrap.run();
+ bootstrap.deploy(standaloneConfig);
+
+ Kernel kernel = bootstrap.getKernel();
+ KernelController controller = kernel.getController();
+ KernelBus bus = kernel.getBus();
+
+ String beanName = "WSNativeDeploymentAspectInstallerJSE";
+ ControllerContext context = controller.getInstalledContext(beanName);
+ assertNotNull("Unable to retrieve "+beanName, context);
+
+ System.out.println("WSDeploymentAspectManagerJSE: " +
context.getTarget());
+ }
+
+ /**
+ * During instantation the the standalone container
+ * goes through the SPIProvider to get all required {@link
org.jboss.wsf.spi.SPIView}'s
+ * to properly staff itself.
+ * However this requires a successfully bootstrapped container.
+ * @throws Exception
+ */
+ public void testEmbeddedContainer() throws Exception
+ {
+ SPIProvider spi = SPIProviderResolver.getInstance().getProvider();
+ DeploymentModelFactory modelFactory = spi.getSPI(DeploymentModelFactory.class);
+
+ // Deployment
+ ClassLoader contextClassLoader = Thread.currentThread().getContextClassLoader();
+ Deployment dep = modelFactory.newDeployment("HelloWorldDeployment",
contextClassLoader);
+ dep.setRuntimeClassLoader(contextClassLoader);
+
+ // TODO: Hack, should this become another DeploymentAspect?
+ ((ArchiveDeployment)dep).setRootFile(new ResourceLoaderAdapter());
+
+ dep.setType(Deployment.DeploymentType.JAXWS_JSE);
+ dep.setService(modelFactory.newService());
+
+ // Service
+ dep.getService().setContextRoot("/hello");
+
+ // Endpoint
+ Endpoint endpoint =
modelFactory.newEndpoint("org.jboss.test.ws.container.HelloWorldEndpoint");
+ endpoint.setShortName("hello");
+ endpoint.setURLPattern("/endpoint");
+ dep.getService().addEndpoint(endpoint);
+
+ long start = System.currentTimeMillis();
+ StandaloneContainer container = StandaloneContainer.bootstrap(standaloneConfig);
+ System.out.println("Bootstrap: " + (System.currentTimeMillis()-start) +
" ms");
+ start = System.currentTimeMillis();
+ container.publish(dep);
+ System.out.println("Publish: " + (System.currentTimeMillis()-start) +
" ms");
+
+
+ // OK, let's try to invoke the endpoint
+ String wsdl = GETRequest("/hello/endpoint?wsdl");
+ assertNotNull("Unable to retrieve WSDL", wsdl);
+
+ Service service = Service.create(
+ new URL("http://localhost:20000/hello/endpoint?wsdl"),
+ new
QName("http://container.ws.test.jboss.org/",
"HelloWorldEndpointService")
+ );
+
+ HelloWorldSEI port = service.getPort(HelloWorldSEI.class);
+ String response = port.hello("StandaloneContainer");
+ assertEquals("Hello StandaloneContainer", response);
+ }
+
+ public static String GETRequest(String context)
+ throws IOException
+ {
+ if(context.startsWith("/"))
+ context = context.substring(1);
+
+ URLConnection con = new
URL("http://localhost:20000/"+context).openConnection();
+ con.connect();
+
+ BufferedReader in = new BufferedReader(
+ new InputStreamReader(
+ con.getInputStream()
+ )
+ );
+
+ String inputLine;
+ StringBuffer sb = new StringBuffer();
+ while ((inputLine = in.readLine()) != null)
+ sb.append(inputLine);
+ in.close();
+ return sb.toString();
+ }
+}
Property changes on:
stack/native/branches/hbraun/src/test/java/org/jboss/test/ws/container/ContainerTestCase.java
___________________________________________________________________
Name: svn:keywords
+ Id Revision
Name: svn:eol-style
+ LF
Added:
stack/native/branches/hbraun/src/test/java/org/jboss/test/ws/container/HelloWorldEndpoint.java
===================================================================
---
stack/native/branches/hbraun/src/test/java/org/jboss/test/ws/container/HelloWorldEndpoint.java
(rev 0)
+++
stack/native/branches/hbraun/src/test/java/org/jboss/test/ws/container/HelloWorldEndpoint.java 2008-03-08
19:08:49 UTC (rev 5896)
@@ -0,0 +1,38 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2006, Red Hat Middleware LLC, and individual contributors
+ * as indicated by the @author tags. See the copyright.txt file 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.test.ws.container;
+
+import javax.jws.WebService;
+import javax.jws.WebMethod;
+
+/**
+ * @author Heiko.Braun <heiko.braun(a)jboss.com>
+ */
+@WebService
+public class HelloWorldEndpoint implements HelloWorldSEI
+{
+ @WebMethod
+ public String hello(String name)
+ {
+ return "Hello " + name;
+ }
+}
\ No newline at end of file
Property changes on:
stack/native/branches/hbraun/src/test/java/org/jboss/test/ws/container/HelloWorldEndpoint.java
___________________________________________________________________
Name: svn:keywords
+ Id Revision
Name: svn:eol-style
+ LF
Added:
stack/native/branches/hbraun/src/test/java/org/jboss/test/ws/container/HelloWorldSEI.java
===================================================================
---
stack/native/branches/hbraun/src/test/java/org/jboss/test/ws/container/HelloWorldSEI.java
(rev 0)
+++
stack/native/branches/hbraun/src/test/java/org/jboss/test/ws/container/HelloWorldSEI.java 2008-03-08
19:08:49 UTC (rev 5896)
@@ -0,0 +1,33 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2006, Red Hat Middleware LLC, and individual contributors
+ * as indicated by the @author tags. See the copyright.txt file 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.test.ws.container;
+
+import javax.jws.WebService;
+
+/**
+ * @author Heiko.Braun <heiko.braun(a)jboss.com>
+ */
+@WebService
+public interface HelloWorldSEI
+{
+ String hello(String name);
+}
Property changes on:
stack/native/branches/hbraun/src/test/java/org/jboss/test/ws/container/HelloWorldSEI.java
___________________________________________________________________
Name: svn:keywords
+ Id Revision
Name: svn:eol-style
+ LF