Author: mmerz
Date: Fri Feb 25 16:03:04 2005
New Revision: 155377
URL: http://svn.apache.org/viewcvs?view=rev&rev=155377
Log:
Negative tests for wsm-apt. Todo: needs to be automated; currently: writes into
log file only.
Added:
incubator/beehive/trunk/wsm/drt/negative/
incubator/beehive/trunk/wsm/drt/negative/WEB-INF/
incubator/beehive/trunk/wsm/drt/negative/WEB-INF/build-dist.xml
incubator/beehive/trunk/wsm/drt/negative/WEB-INF/build-svn.xml
incubator/beehive/trunk/wsm/drt/negative/WEB-INF/server-config.wsdd
incubator/beehive/trunk/wsm/drt/negative/WEB-INF/src/
incubator/beehive/trunk/wsm/drt/negative/WEB-INF/src/web/
incubator/beehive/trunk/wsm/drt/negative/WEB-INF/src/web/negative/
incubator/beehive/trunk/wsm/drt/negative/WEB-INF/src/web/negative/HandlerChainWithInvalidFile.jws
incubator/beehive/trunk/wsm/drt/negative/WEB-INF/src/web/negative/HandlerChainWithSOAPMessageHandlers.jws
incubator/beehive/trunk/wsm/drt/negative/WEB-INF/src/web/negative/OnewayWithCheckedException.jws
incubator/beehive/trunk/wsm/drt/negative/WEB-INF/src/web/negative/OnewayWithOutParameter.jws
incubator/beehive/trunk/wsm/drt/negative/WEB-INF/src/web/negative/OnewayWithReturn.jws
incubator/beehive/trunk/wsm/drt/negative/WEB-INF/src/web/negative/WebMethodNonPublic.jws
incubator/beehive/trunk/wsm/drt/negative/WEB-INF/src/web/negative/WebServiceAbstract.jws
incubator/beehive/trunk/wsm/drt/negative/WEB-INF/src/web/negative/WebServiceEndpointInterfaceWithEndpointInterface.jws
incubator/beehive/trunk/wsm/drt/negative/WEB-INF/src/web/negative/WebServiceEndpointInterfaceWithServiceName.jws
incubator/beehive/trunk/wsm/drt/negative/WEB-INF/src/web/negative/WebServiceFinal.jws
incubator/beehive/trunk/wsm/drt/negative/WEB-INF/src/web/negative/WebServiceNonPublic.jws
incubator/beehive/trunk/wsm/drt/negative/WEB-INF/src/web/negative/WebServiceWithFinalize.jws
incubator/beehive/trunk/wsm/drt/negative/WEB-INF/src/web/negative/WebServiceWithInvalidWsdlLocation.jws
incubator/beehive/trunk/wsm/drt/negative/WEB-INF/src/web/negative/WebServiceWithoutDefaultConstructor.jws
incubator/beehive/trunk/wsm/drt/negative/WEB-INF/web.xml
Added: incubator/beehive/trunk/wsm/drt/negative/WEB-INF/build-dist.xml
URL:
http://svn.apache.org/viewcvs/incubator/beehive/trunk/wsm/drt/negative/WEB-INF/build-dist.xml?view=auto&rev=155377
==============================================================================
--- incubator/beehive/trunk/wsm/drt/negative/WEB-INF/build-dist.xml (added)
+++ incubator/beehive/trunk/wsm/drt/negative/WEB-INF/build-dist.xml Fri Feb 25
16:03:04 2005
@@ -0,0 +1,135 @@
+<?xml version="1.0" ?>
+
+<!--
+ Copyright 2004 The Apache Software Foundation
+
+ Licensed 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.
+
+ $Header:$
+ -->
+
+<project name="Beehive/WSM Sample Web Services" default="build" basedir=".">
+
+ <import file="../../../beehive-imports.xml" />
+
+ <property name="service.name" value="wsm-samples" />
+
+ <property name="webapp.dir" location=".." />
+ <property name="web.inf.dir" location="${webapp.dir}/WEB-INF" />
+ <property name="attachments.dir" location="${web.inf.dir}/attachments" />
+ <property name="classes.dir" location="${web.inf.dir}/classes" />
+ <property name="gen.dir" location="${web.inf.dir}/gen" />
+ <property name="lib.dir" location="${web.inf.dir}/lib" />
+ <property name="src.dir" location="${web.inf.dir}/src" />
+ <property name="webservice.jar" value="${lib.dir}/${service.name}WS.jar" />
+ <property name="webservice.war" value="${service.name}WS.war" />
+
+ <path id="lib.path">
+ <fileset dir="${lib.dir}">
+ <include name="**/*.jar" />
+ </fileset>
+ </path>
+
+ <path id="build.classpath">
+ <path refid="lib.path"/>
+ <pathelement location="${classes.dir}"/>
+ </path>
+
+
+ <!-- ========================================= -->
+ <!-- deploy - build deployable artifact -->
+ <!-- ========================================= -->
+
+ <target name="deploy">
+ <antcall target="deploy.war" />
+ </target>
+
+
+ <!-- ========================================= -->
+ <!-- deploy.war - build deployable artifact -->
+ <!-- ========================================= -->
+
+ <target name="deploy.war">
+ <jar jarfile="${to.dir}/${webservice.war}">
+ <fileset dir="..">
+ <exclude name="${src.dir}/**" />
+ <exclude name="${gen.dir}/**" />
+ </fileset>
+ </jar>
+ </target>
+
+
+ <!-- ========================================= -->
+ <!-- build - build all binaries -->
+ <!-- ========================================= -->
+
+ <target name="build" depends="dirs">
+ <antcall target="deploy.beehive.webservice.runtime" />
+ <antcall target="build.beehive.webservice" />
+ <jar jarfile="${webservice.jar}">
+ <fileset dir="${classes.dir}" />
+ </jar>
+ </target>
+
+
+ <!-- ========================================= -->
+ <!-- clean - remove binary files -->
+ <!-- ========================================= -->
+
+ <target name="clean">
+ <delete dir="${attachments.dir}" />
+ <delete dir="${classes.dir}" />
+ <delete dir="${gen.dir}" />
+ <delete dir="${lib.dir}" />
+ <delete file="velocity.log" />
+ </target>
+
+
+ <!-- ========================================= -->
+ <!-- dirs - create dirs required for compile -->
+ <!-- ========================================= -->
+
+ <target name="dirs">
+ <mkdir dir="${attachments.dir}" />
+ <mkdir dir="${classes.dir}" />
+ <mkdir dir="${gen.dir}" />
+ <mkdir dir="${lib.dir}" />
+ </target>
+
+ <!-- copy all dependencies -->
+ <target name="deploy.beehive.webservice.runtime" depends="dirs">
+ <copy todir="${lib.dir}">
+ <fileset file="${beehive.home}/lib/common/*.jar" />
+ <fileset file="${beehive.home}/lib/controls/controls.jar" />
+ <fileset file="${beehive.home}/lib/wsm/*.jar" />
+ </copy>
+ </target>
+
+
+ <!-- build all beehive webservice binaries -->
+ <target name="build.beehive.webservice">
+ <taskdef name="apt"
+ classname="org.apache.beehive.controls.runtime.generator.AptTask"
+ classpathref="lib.path"
+ onerror="report" />
+ <apt
+ srcdir="${src.dir}"
+ destdir="${classes.dir}"
+ gendir="${gen.dir}"
+ classpathref="build.classpath"
+ compileByExtension="true"
+ srcExtensions="*.java,*.jws"
+ debug="true" />
+ </target>
+
+</project>
\ No newline at end of file
Added: incubator/beehive/trunk/wsm/drt/negative/WEB-INF/build-svn.xml
URL:
http://svn.apache.org/viewcvs/incubator/beehive/trunk/wsm/drt/negative/WEB-INF/build-svn.xml?view=auto&rev=155377
==============================================================================
--- incubator/beehive/trunk/wsm/drt/negative/WEB-INF/build-svn.xml (added)
+++ incubator/beehive/trunk/wsm/drt/negative/WEB-INF/build-svn.xml Fri Feb 25
16:03:04 2005
@@ -0,0 +1,140 @@
+<?xml version="1.0" ?>
+
+<!--
+ Copyright 2004 The Apache Software Foundation
+
+ Licensed 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.
+
+ $Header:$
+ -->
+
+<project name="wsm-negative-drts" default="build" basedir=".">
+
+ <import file="../../../../beehive-imports.xml" />
+
+ <property name="service.name" value="wsm-negative-drts" />
+
+ <property name="webapp.dir" location=".." />
+ <property name="web.inf.dir" value="${webapp.dir}/WEB-INF" />
+ <property name="lib.dir" value="${web.inf.dir}/lib" />
+ <property name="src.dir" value="${web.inf.dir}/src" />
+ <property name="attachments.dir" value="${web.inf.dir}/attachments" />
+ <property name="classes.dir" value="${web.inf.dir}/classes" />
+ <property name="gen.dir" value="${web.inf.dir}/.tmpbeansrc" />
+ <property name="webservice.jar" value="${lib.dir}/${service.name}WS.jar" />
+ <property name="webservice.war" value="${service.name}WS.war" />
+
+ <condition property="isJDK15">
+ <equals arg1="${ant.java.version}" arg2="1.5" />
+ </condition>
+
+ <path id="lib.path">
+ <fileset dir="${lib.dir}">
+ <include name="**/*.jar" />
+ </fileset>
+ </path>
+
+ <path id="build.classpath">
+ <path refid="lib.path"/>
+ <pathelement location="${classes.dir}"/>
+ </path>
+
+
+ <!-- ========================================= -->
+ <!-- deploy - build deployable artifact -->
+ <!-- ========================================= -->
+
+ <target name="deploy">
+ <antcall target="deploy.war" />
+ </target>
+
+
+ <!-- ========================================= -->
+ <!-- deploy.war - build deployable artifact -->
+ <!-- ========================================= -->
+
+ <target name="deploy.war">
+ <jar destfile="${to.dir}/${webservice.war}">
+ <fileset dir="${webapp.dir}">
+ <exclude name="WEB-INF/classes/**" />
+ <exclude name="WEB-INF/.tmpbeansrc/**" />
+ <exclude name="WEB-INF/src/**" />
+ <exclude name="**/*build*.xml" />
+ </fileset>
+ </jar>
+ </target>
+
+
+ <!-- ========================================= -->
+ <!-- build - create jar in ${lib.dir} -->
+ <!-- ========================================= -->
+
+ <target name="build" depends="dirs">
+ <antcall target="deploy.beehive.webservice.runtime" />
+ <antcall target="build.beehive.webservice" />
+ <jar jarfile="${webservice.jar}">
+ <fileset dir="${classes.dir}" />
+ </jar>
+ </target>
+
+
+ <!-- ========================================= -->
+ <!-- clean - remove binary files -->
+ <!-- ========================================= -->
+
+ <target name="clean">
+ <delete dir="${attachments.dir}" />
+ <delete file="velocity.log" />
+ <clean-webapp webappDir="${webapp.dir}" />
+ </target>
+
+
+ <!-- ========================================= -->
+ <!-- dirs - create dirs required for compile -->
+ <!-- ========================================= -->
+
+ <target name="dirs">
+ <mkdir dir="${lib.dir}" />
+ <mkdir dir="${attachments.dir}" />
+ <mkdir dir="${classes.dir}" />
+ <mkdir dir="${gen.dir}" />
+ </target>
+
+
+ <!-- ========================================= -->
+ <!-- deploy.beehive.webservice.runtime - -->
+ <!-- ========================================= -->
+
+ <target name="deploy.beehive.webservice.runtime">
+ <deploy-wsm webappDir="${webapp.dir}" />
+ </target>
+
+
+ <!-- build all beehive webservice binaries -->
+ <target name="build.beehive.webservice">
+ <taskdef name="apt"
+ classname="org.apache.beehive.controls.runtime.generator.AptTask"
+ classpathref="lib.path"
+ onerror="report" />
+ <apt
+ srcdir="${src.dir}"
+ destdir="${classes.dir}"
+ gendir="${gen.dir}"
+ classpathref="build.classpath"
+ compileByExtension="true"
+ srcExtensions="*.java,*.jws"
+ failonerror="false"
+ debug="true" />
+ </target>
+
+</project>
Added: incubator/beehive/trunk/wsm/drt/negative/WEB-INF/server-config.wsdd
URL:
http://svn.apache.org/viewcvs/incubator/beehive/trunk/wsm/drt/negative/WEB-INF/server-config.wsdd?view=auto&rev=155377
==============================================================================
--- incubator/beehive/trunk/wsm/drt/negative/WEB-INF/server-config.wsdd (added)
+++ incubator/beehive/trunk/wsm/drt/negative/WEB-INF/server-config.wsdd Fri Feb
25 16:03:04 2005
@@ -0,0 +1,46 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<deployment xmlns="http://xml.apache.org/axis/wsdd/"
xmlns:java="http://xml.apache.org/axis/wsdd/providers/java">
+ <globalConfiguration>
+ <parameter name="adminPassword" value="admin"/>
+ <parameter name="disablePrettyXML" value="true"/>
+ <parameter name="attachments.implementation"
value="org.apache.axis.attachments.AttachmentsImpl"/>
+ <parameter name="sendXsiTypes" value="true"/>
+ <parameter name="sendXMLDeclaration" value="true"/>
+ <requestFlow>
+ <handler
type="java:org.apache.beehive.wsm.axis.AnnotatedWebServiceDeploymentHandler">
+ <parameter name="scope" value="session"/>
+ </handler>
+ <handler type="java:org.apache.axis.handlers.JWSHandler">
+ <parameter name="scope" value="session"/>
+ </handler>
+ </requestFlow>
+ </globalConfiguration>
+ <handler name="LocalResponder"
type="java:org.apache.axis.transport.local.LocalResponder"/>
+ <handler name="URLMapper"
type="java:org.apache.axis.handlers.http.URLMapper"/>
+ <handler name="Authenticate"
type="java:org.apache.axis.handlers.SimpleAuthenticationHandler"/>
+ <service name="AdminService" provider="java:MSG">
+ <parameter name="allowedMethods" value="AdminService"/>
+ <parameter name="enableRemoteAdmin" value="false"/>
+ <parameter name="className" value="org.apache.axis.utils.Admin"/>
+ <namespace>http://xml.apache.org/axis/wsdd/</namespace>
+ </service>
+ <service name="Version" provider="java:RPC">
+ <parameter name="allowedMethods" value="getVersion"/>
+ <parameter name="className" value="org.apache.axis.Version"/>
+ </service>
+ <transport name="http">
+ <requestFlow>
+ <handler type="URLMapper"/>
+ <handler type="java:org.apache.axis.handlers.http.HTTPAuthHandler"/>
+ </requestFlow>
+ <parameter name="qs:list"
value="org.apache.axis.transport.http.QSListHandler"/>
+ <parameter name="qs:wsdl"
value="org.apache.axis.transport.http.QSWSDLHandler"/>
+ <parameter name="qs:method"
value="org.apache.axis.transport.http.QSMethodHandler"/>
+ </transport>
+ <transport name="local">
+ <responseFlow>
+ <handler type="LocalResponder"/>
+ </responseFlow>
+ </transport>
+</deployment>
+
Added:
incubator/beehive/trunk/wsm/drt/negative/WEB-INF/src/web/negative/HandlerChainWithInvalidFile.jws
URL:
http://svn.apache.org/viewcvs/incubator/beehive/trunk/wsm/drt/negative/WEB-INF/src/web/negative/HandlerChainWithInvalidFile.jws?view=auto&rev=155377
==============================================================================
---
incubator/beehive/trunk/wsm/drt/negative/WEB-INF/src/web/negative/HandlerChainWithInvalidFile.jws
(added)
+++
incubator/beehive/trunk/wsm/drt/negative/WEB-INF/src/web/negative/HandlerChainWithInvalidFile.jws
Fri Feb 25 16:03:04 2005
@@ -0,0 +1,35 @@
+package web.negative;
+
+/*
+ * Copyright 2001-2004 The Apache Software Foundation.
+ *
+ * Licensed 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.
+ */
+
+import javax.jws.HandlerChain;
+import javax.jws.WebMethod;
+import javax.jws.WebService;
+
+/**
+ * This web service has a HandlerChain annotations that refers to a
+ * non-existing file.
+ */
[EMAIL PROTECTED]
[EMAIL PROTECTED](file="InvalidFile.xml", name="InvalidFile")
+public class HandlerChainWithInvalidFile {
+
+ @WebMethod
+ public String sayHello(String name) {
+ return "Hello, " + name + "!";
+ }
+}
\ No newline at end of file
Added:
incubator/beehive/trunk/wsm/drt/negative/WEB-INF/src/web/negative/HandlerChainWithSOAPMessageHandlers.jws
URL:
http://svn.apache.org/viewcvs/incubator/beehive/trunk/wsm/drt/negative/WEB-INF/src/web/negative/HandlerChainWithSOAPMessageHandlers.jws?view=auto&rev=155377
==============================================================================
---
incubator/beehive/trunk/wsm/drt/negative/WEB-INF/src/web/negative/HandlerChainWithSOAPMessageHandlers.jws
(added)
+++
incubator/beehive/trunk/wsm/drt/negative/WEB-INF/src/web/negative/HandlerChainWithSOAPMessageHandlers.jws
Fri Feb 25 16:03:04 2005
@@ -0,0 +1,42 @@
+package web.negative;
+
+/*
+ * Copyright 2001-2004 The Apache Software Foundation.
+ *
+ * Licensed 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.
+ */
+
+import javax.jws.HandlerChain;
+import javax.jws.WebMethod;
+import javax.jws.WebService;
+import javax.jws.soap.InitParam;
+import javax.jws.soap.SOAPMessageHandler;
+import javax.jws.soap.SOAPMessageHandlers;
+
+/**
+ * This web service illegally defines SOAPMessageHandlers and a HandlerChain.
+ */
[EMAIL PROTECTED]
[EMAIL PROTECTED](file="HandlerConfig.xml", name="HandlerChain")
[EMAIL PROTECTED]({
+ @SOAPMessageHandler(className="web.soapmessagehandlers.EncryptionHandler",
[EMAIL PROTECTED]( name="offset", value="1")}),
+ @SOAPMessageHandler(className="web.soapmessagehandlers.EncryptionHandler",
[EMAIL PROTECTED]( name="offset", value="2")}),
+ @SOAPMessageHandler(className="web.soapmessagehandlers.EncryptionHandler",
[EMAIL PROTECTED]( name="offset", value="4")})
+})
+public class HandlerChainWithSOAPMessageHandlers {
+
+ @WebMethod
+ public String sayHello(String name) {
+ return "Hello, " + name + "!";
+ }
+}
\ No newline at end of file
Added:
incubator/beehive/trunk/wsm/drt/negative/WEB-INF/src/web/negative/OnewayWithCheckedException.jws
URL:
http://svn.apache.org/viewcvs/incubator/beehive/trunk/wsm/drt/negative/WEB-INF/src/web/negative/OnewayWithCheckedException.jws?view=auto&rev=155377
==============================================================================
---
incubator/beehive/trunk/wsm/drt/negative/WEB-INF/src/web/negative/OnewayWithCheckedException.jws
(added)
+++
incubator/beehive/trunk/wsm/drt/negative/WEB-INF/src/web/negative/OnewayWithCheckedException.jws
Fri Feb 25 16:03:04 2005
@@ -0,0 +1,34 @@
+package web.negative;
+
+/*
+ * Copyright 2001-2004 The Apache Software Foundation.
+ *
+ * Licensed 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.
+ */
+
+import javax.jws.Oneway;
+import javax.jws.WebMethod;
+import javax.jws.WebService;
+
[EMAIL PROTECTED]
+public class OnewayWithCheckedException {
+
+ /**
+ * This oneway method illegally throws a checked exception.
+ */
+ @WebMethod
+ @Oneway
+ public void sayHello() throws Exception {
+ throw new Exception("Hello!");
+ }
+}
Added:
incubator/beehive/trunk/wsm/drt/negative/WEB-INF/src/web/negative/OnewayWithOutParameter.jws
URL:
http://svn.apache.org/viewcvs/incubator/beehive/trunk/wsm/drt/negative/WEB-INF/src/web/negative/OnewayWithOutParameter.jws?view=auto&rev=155377
==============================================================================
---
incubator/beehive/trunk/wsm/drt/negative/WEB-INF/src/web/negative/OnewayWithOutParameter.jws
(added)
+++
incubator/beehive/trunk/wsm/drt/negative/WEB-INF/src/web/negative/OnewayWithOutParameter.jws
Fri Feb 25 16:03:04 2005
@@ -0,0 +1,37 @@
+package web.negative;
+
+/*
+ * Copyright 2001-2004 The Apache Software Foundation.
+ *
+ * Licensed 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.
+ */
+
+import javax.jws.Oneway;
+import javax.jws.WebMethod;
+import javax.jws.WebParam;
+import javax.jws.WebService;
+
+import javax.xml.rpc.holders.StringHolder;
+
[EMAIL PROTECTED]
+public class OnewayWithOutParameter {
+
+ /**
+ * This oneway method illegally defines an OUT parameter.
+ */
+ @WebMethod
+ @Oneway
+ public void sayHello(@WebParam(mode=WebParam.Mode.OUT) StringHolder
stringHolder) {
+ stringHolder.value = "Hello!";
+ }
+}
\ No newline at end of file
Added:
incubator/beehive/trunk/wsm/drt/negative/WEB-INF/src/web/negative/OnewayWithReturn.jws
URL:
http://svn.apache.org/viewcvs/incubator/beehive/trunk/wsm/drt/negative/WEB-INF/src/web/negative/OnewayWithReturn.jws?view=auto&rev=155377
==============================================================================
---
incubator/beehive/trunk/wsm/drt/negative/WEB-INF/src/web/negative/OnewayWithReturn.jws
(added)
+++
incubator/beehive/trunk/wsm/drt/negative/WEB-INF/src/web/negative/OnewayWithReturn.jws
Fri Feb 25 16:03:04 2005
@@ -0,0 +1,34 @@
+package web.negative;
+
+/*
+ * Copyright 2001-2004 The Apache Software Foundation.
+ *
+ * Licensed 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.
+ */
+
+import javax.jws.Oneway;
+import javax.jws.WebMethod;
+import javax.jws.WebService;
+
[EMAIL PROTECTED]
+public class OnewayWithReturn {
+
+ /**
+ * This @Oneway method illegally defines a return value.
+ */
+ @WebMethod
+ @Oneway
+ public String sayHello(String name) {
+ return "Hello, " + name + "!";
+ }
+}
Added:
incubator/beehive/trunk/wsm/drt/negative/WEB-INF/src/web/negative/WebMethodNonPublic.jws
URL:
http://svn.apache.org/viewcvs/incubator/beehive/trunk/wsm/drt/negative/WEB-INF/src/web/negative/WebMethodNonPublic.jws?view=auto&rev=155377
==============================================================================
---
incubator/beehive/trunk/wsm/drt/negative/WEB-INF/src/web/negative/WebMethodNonPublic.jws
(added)
+++
incubator/beehive/trunk/wsm/drt/negative/WEB-INF/src/web/negative/WebMethodNonPublic.jws
Fri Feb 25 16:03:04 2005
@@ -0,0 +1,32 @@
+package web.negative;
+
+/*
+ * Copyright 2001-2004 The Apache Software Foundation.
+ *
+ * Licensed 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.
+ */
+
+import javax.jws.WebMethod;
+import javax.jws.WebService;
+
[EMAIL PROTECTED]
+public class WebMethodNonPublic {
+
+ /**
+ * This web method is not public.
+ */
+ @WebMethod
+ String sayHello(String name) {
+ return "Hello, " + name + "!";
+ }
+}
\ No newline at end of file
Added:
incubator/beehive/trunk/wsm/drt/negative/WEB-INF/src/web/negative/WebServiceAbstract.jws
URL:
http://svn.apache.org/viewcvs/incubator/beehive/trunk/wsm/drt/negative/WEB-INF/src/web/negative/WebServiceAbstract.jws?view=auto&rev=155377
==============================================================================
---
incubator/beehive/trunk/wsm/drt/negative/WEB-INF/src/web/negative/WebServiceAbstract.jws
(added)
+++
incubator/beehive/trunk/wsm/drt/negative/WEB-INF/src/web/negative/WebServiceAbstract.jws
Fri Feb 25 16:03:04 2005
@@ -0,0 +1,32 @@
+package web.negative;
+
+/*
+ * Copyright 2001-2004 The Apache Software Foundation.
+ *
+ * Licensed 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.
+ */
+
+import javax.jws.WebMethod;
+import javax.jws.WebService;
+
+/**
+ * This web service class is abstract, which is illegal according to JSR-181.
+ */
[EMAIL PROTECTED]
+public abstract class WebServiceAbstract {
+
+ @WebMethod
+ public String sayHello(String name) {
+ return "Hello, " + name + "!";
+ }
+}
\ No newline at end of file
Added:
incubator/beehive/trunk/wsm/drt/negative/WEB-INF/src/web/negative/WebServiceEndpointInterfaceWithEndpointInterface.jws
URL:
http://svn.apache.org/viewcvs/incubator/beehive/trunk/wsm/drt/negative/WEB-INF/src/web/negative/WebServiceEndpointInterfaceWithEndpointInterface.jws?view=auto&rev=155377
==============================================================================
---
incubator/beehive/trunk/wsm/drt/negative/WEB-INF/src/web/negative/WebServiceEndpointInterfaceWithEndpointInterface.jws
(added)
+++
incubator/beehive/trunk/wsm/drt/negative/WEB-INF/src/web/negative/WebServiceEndpointInterfaceWithEndpointInterface.jws
Fri Feb 25 16:03:04 2005
@@ -0,0 +1,31 @@
+package web.negative;
+
+/*
+ * Copyright 2001-2004 The Apache Software Foundation.
+ *
+ * Licensed 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.
+ */
+
+import javax.jws.WebMethod;
+import javax.jws.WebService;
+
+/**
+ * This web service endpoint interface illegally refers to another endpoint
+ * interface.
+ */
[EMAIL
PROTECTED](endpointInterface="web.negative.WebServiceEndpointInterfaceWithServiceName")
+public interface WebServiceEndpointInterfaceWithEndpointInterface {
+
+ @WebMethod
+ public String sayHello(String name);
+}
Added:
incubator/beehive/trunk/wsm/drt/negative/WEB-INF/src/web/negative/WebServiceEndpointInterfaceWithServiceName.jws
URL:
http://svn.apache.org/viewcvs/incubator/beehive/trunk/wsm/drt/negative/WEB-INF/src/web/negative/WebServiceEndpointInterfaceWithServiceName.jws?view=auto&rev=155377
==============================================================================
---
incubator/beehive/trunk/wsm/drt/negative/WEB-INF/src/web/negative/WebServiceEndpointInterfaceWithServiceName.jws
(added)
+++
incubator/beehive/trunk/wsm/drt/negative/WEB-INF/src/web/negative/WebServiceEndpointInterfaceWithServiceName.jws
Fri Feb 25 16:03:04 2005
@@ -0,0 +1,31 @@
+package web.negative;
+
+/*
+ * Copyright 2001-2004 The Apache Software Foundation.
+ *
+ * Licensed 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.
+ */
+
+import javax.jws.WebMethod;
+import javax.jws.WebService;
+
+/**
+ * This web service is an endpoint interface that illegally defines
+ * @WebService.serviceName.
+ */
[EMAIL PROTECTED](name="Name", serviceName="ServiceName")
+public interface WebServiceEndpointInterfaceWithServiceName {
+
+ @WebMethod
+ public String sayHello(String name);
+}
\ No newline at end of file
Added:
incubator/beehive/trunk/wsm/drt/negative/WEB-INF/src/web/negative/WebServiceFinal.jws
URL:
http://svn.apache.org/viewcvs/incubator/beehive/trunk/wsm/drt/negative/WEB-INF/src/web/negative/WebServiceFinal.jws?view=auto&rev=155377
==============================================================================
---
incubator/beehive/trunk/wsm/drt/negative/WEB-INF/src/web/negative/WebServiceFinal.jws
(added)
+++
incubator/beehive/trunk/wsm/drt/negative/WEB-INF/src/web/negative/WebServiceFinal.jws
Fri Feb 25 16:03:04 2005
@@ -0,0 +1,32 @@
+package web.negative;
+
+/*
+ * Copyright 2001-2004 The Apache Software Foundation.
+ *
+ * Licensed 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.
+ */
+
+import javax.jws.WebMethod;
+import javax.jws.WebService;
+
+/**
+ * This web service class is "final", which is illegal according to JSR-181.
+ */
[EMAIL PROTECTED]
+public final class WebServiceFinal {
+
+ @WebMethod
+ public String sayHello(String name) {
+ return "Hello, " + name + "!";
+ }
+}
\ No newline at end of file
Added:
incubator/beehive/trunk/wsm/drt/negative/WEB-INF/src/web/negative/WebServiceNonPublic.jws
URL:
http://svn.apache.org/viewcvs/incubator/beehive/trunk/wsm/drt/negative/WEB-INF/src/web/negative/WebServiceNonPublic.jws?view=auto&rev=155377
==============================================================================
---
incubator/beehive/trunk/wsm/drt/negative/WEB-INF/src/web/negative/WebServiceNonPublic.jws
(added)
+++
incubator/beehive/trunk/wsm/drt/negative/WEB-INF/src/web/negative/WebServiceNonPublic.jws
Fri Feb 25 16:03:04 2005
@@ -0,0 +1,32 @@
+package web.negative;
+
+/*
+ * Copyright 2001-2004 The Apache Software Foundation.
+ *
+ * Licensed 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.
+ */
+
+import javax.jws.WebMethod;
+import javax.jws.WebService;
+
+/**
+ * This web service class is not public as required by JSR-181.
+ */
[EMAIL PROTECTED]
+class WebServiceNonPublic {
+
+ @WebMethod
+ public String hello(String name) {
+ return "Hello, " + name + "!";
+ }
+}
\ No newline at end of file
Added:
incubator/beehive/trunk/wsm/drt/negative/WEB-INF/src/web/negative/WebServiceWithFinalize.jws
URL:
http://svn.apache.org/viewcvs/incubator/beehive/trunk/wsm/drt/negative/WEB-INF/src/web/negative/WebServiceWithFinalize.jws?view=auto&rev=155377
==============================================================================
---
incubator/beehive/trunk/wsm/drt/negative/WEB-INF/src/web/negative/WebServiceWithFinalize.jws
(added)
+++
incubator/beehive/trunk/wsm/drt/negative/WEB-INF/src/web/negative/WebServiceWithFinalize.jws
Fri Feb 25 16:03:04 2005
@@ -0,0 +1,34 @@
+package web.negative;
+
+/*
+ * Copyright 2001-2004 The Apache Software Foundation.
+ *
+ * Licensed 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.
+ */
+
+import javax.jws.WebMethod;
+import javax.jws.WebService;
+
+/**
+ * This web service class illegally defines "finalize()".
+ */
[EMAIL PROTECTED]
+public class WebServiceWithFinalize {
+
+ public void finalize() { }
+
+ @WebMethod
+ public String sayHello(String name) {
+ return "Hello, " + name + "!";
+ }
+}
\ No newline at end of file
Added:
incubator/beehive/trunk/wsm/drt/negative/WEB-INF/src/web/negative/WebServiceWithInvalidWsdlLocation.jws
URL:
http://svn.apache.org/viewcvs/incubator/beehive/trunk/wsm/drt/negative/WEB-INF/src/web/negative/WebServiceWithInvalidWsdlLocation.jws?view=auto&rev=155377
==============================================================================
---
incubator/beehive/trunk/wsm/drt/negative/WEB-INF/src/web/negative/WebServiceWithInvalidWsdlLocation.jws
(added)
+++
incubator/beehive/trunk/wsm/drt/negative/WEB-INF/src/web/negative/WebServiceWithInvalidWsdlLocation.jws
Fri Feb 25 16:03:04 2005
@@ -0,0 +1,32 @@
+package web.negative;
+
+/*
+ * Copyright 2001-2004 The Apache Software Foundation.
+ *
+ * Licensed 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.
+ */
+
+import javax.jws.WebMethod;
+import javax.jws.WebService;
+
+/**
+ * This web service class refers to a non-existing WSDL file.
+ */
[EMAIL PROTECTED](wsdlLocation="InvalidWsdlLocation.wsdl")
+public class WebServiceWithInvalidWsdlLocation {
+
+ @WebMethod
+ public String sayHello(String name) {
+ return "Hello, " + name + "!";
+ }
+}
\ No newline at end of file
Added:
incubator/beehive/trunk/wsm/drt/negative/WEB-INF/src/web/negative/WebServiceWithoutDefaultConstructor.jws
URL:
http://svn.apache.org/viewcvs/incubator/beehive/trunk/wsm/drt/negative/WEB-INF/src/web/negative/WebServiceWithoutDefaultConstructor.jws?view=auto&rev=155377
==============================================================================
---
incubator/beehive/trunk/wsm/drt/negative/WEB-INF/src/web/negative/WebServiceWithoutDefaultConstructor.jws
(added)
+++
incubator/beehive/trunk/wsm/drt/negative/WEB-INF/src/web/negative/WebServiceWithoutDefaultConstructor.jws
Fri Feb 25 16:03:04 2005
@@ -0,0 +1,34 @@
+package web.negative;
+
+/*
+ * Copyright 2001-2004 The Apache Software Foundation.
+ *
+ * Licensed 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.
+ */
+
+import javax.jws.WebMethod;
+import javax.jws.WebService;
+
+/**
+ * This web service class does not define the required default constructor.
+ */
[EMAIL PROTECTED]
+public class WebServiceWithoutDefaultConstructor {
+
+ public WebServiceWithoutDefaultConstructor(int i) { }
+
+ @WebMethod
+ public String sayHello(String name) {
+ return "Hello, " + name + "!";
+ }
+}
\ No newline at end of file
Added: incubator/beehive/trunk/wsm/drt/negative/WEB-INF/web.xml
URL:
http://svn.apache.org/viewcvs/incubator/beehive/trunk/wsm/drt/negative/WEB-INF/web.xml?view=auto&rev=155377
==============================================================================
--- incubator/beehive/trunk/wsm/drt/negative/WEB-INF/web.xml (added)
+++ incubator/beehive/trunk/wsm/drt/negative/WEB-INF/web.xml Fri Feb 25
16:03:04 2005
@@ -0,0 +1,82 @@
+<?xml version="1.0" encoding="ISO-8859-1"?>
+
+<!DOCTYPE web-app PUBLIC "-//Sun Microsystems, Inc.//DTD Web
+Application 2.3//EN" "http://java.sun.com/dtd/web-app_2_3.dtd">
+
+<web-app>
+
+ <display-name>beehive-wsm negative drt tests</display-name>
+
+ <!-- configure beehive controls context -->
+ <filter>
+ <filter-name>ControlFilter</filter-name>
+
<filter-class>org.apache.beehive.controls.runtime.servlet.ControlFilter</filter-class>
+ </filter>
+ <filter-mapping>
+ <filter-name>ControlFilter</filter-name>
+ <url-pattern>*.jws</url-pattern>
+ </filter-mapping>
+
+ <!-- configure SOAP stack -->
+ <listener>
+
<listener-class>org.apache.axis.transport.http.AxisHTTPSessionListener</listener-class>
+ </listener>
+ <servlet>
+ <servlet-name>AxisServlet</servlet-name>
+ <display-name>Apache-Axis Servlet</display-name>
+ <servlet-class>
+ org.apache.axis.transport.http.AxisServlet
+ </servlet-class>
+ </servlet>
+
+ <!-- uncomment this if you want the admin servlet -->
+ <!--
+ <servlet>
+ <servlet-name>AdminServlet</servlet-name>
+ <display-name>Axis Admin Servlet</display-name>
+ <servlet-class>
+ org.apache.axis.transport.http.AdminServlet
+ </servlet-class>
+ <load-on-startup>100</load-on-startup>
+ </servlet>
+ -->
+
+ <servlet-mapping>
+ <servlet-name>AxisServlet</servlet-name>
+ <url-pattern>*.jws</url-pattern>
+ </servlet-mapping>
+
+ <!-- uncomment this if you want the admin servlet -->
+ <!--
+ <servlet-mapping>
+ <servlet-name>AdminServlet</servlet-name>
+ <url-pattern>/servlet/AdminServlet</url-pattern>
+ </servlet-mapping>
+ -->
+
+ <session-config>
+ <!-- Default to 5 minute session timeouts -->
+ <session-timeout>5</session-timeout>
+ </session-config>
+
+ <!-- currently the W3C havent settled on a media type for WSDL;
+ http://www.w3.org/TR/2003/WD-wsdl12-20030303/#ietf-draft
+ for now we go with the basic 'it's XML' response -->
+ <mime-mapping>
+ <extension>wsdl</extension>
+ <mime-type>text/xml</mime-type>
+ </mime-mapping>
+
+
+ <mime-mapping>
+ <extension>xsd</extension>
+ <mime-type>text/xml</mime-type>
+ </mime-mapping>
+
+ <welcome-file-list id="WelcomeFileList">
+ <welcome-file>index.html</welcome-file>
+ <welcome-file>index.jsp</welcome-file>
+ <welcome-file>index.jws</welcome-file>
+ </welcome-file-list>
+
+</web-app>