---------- Forwarded message ----------
From: Vishal Deshpande <[EMAIL PROTECTED]>
Date: Aug 7, 2006 3:27 PM
Subject: Question regarding wsdl level imports in Axis 2 ...
To: [EMAIL PROTECTED]



Hello Axis team,

I am a new user of Axis 2 and would like to ask you a few questions
about it as you seem to have great understanding on the subject.

We have a scenario where we have multiple services that are to be
exposed as web-services over Tomcat server. We are trying to use Axis
for our wsdl grunt-work, but would like to have a modular wsdl design
structure.

Ideally, I would like to have the schema elements separated into a say
ServiceType.wsdl and import these in the individual service wsdls like
ServiceA.wsdl, ServiceB.wsdl and so on where I have the service
bindings defined.

So far so good. I have the wsdls coded that way and I have Axis 2
generating the correct code. However, w.r.t creating jars, I was
trying to implement a similar logic, i.e have the schema elements and
its corresponding xsb bindings in a ServiceTypes.jar and have the
services in their own respective jars. This would have reduced the
need for having the schema elements in every single service jar, as I
could have the schema element jar in a shared location. That, for some
reason, when deployed, makes tomcat to go in an infinite loop on
import.

Now we do have the services deployed on the Tomcat as application
archive, instead of exploded jars. Can we use exploded jars with Axis2
as I feel that Tomcat would be better off importing things from a
flat-file architecture rather than through a jar. However, I may be
wrong. It may just be my wsdls are incorrectly formed. ANy help in
this matter is highly appreciated.

To summarise, I guess my questions are
  1. Are the attached wsdls incorrectly formed? Syntax error or design error?
  2. Can we split wsdls in a hierarchical fashion when using Axis 2
as in the attachments?
  3. Can we have a clean separation between reusable schema elements
and service bindings in seaprate jars or do we have to package things
together in a single jar?
  4. Does Axis 2 support having more than one wsdl in a single jar?

I have attached the shcema wsdl and service wsdl for you. I would be
glad if I can get some guidance on this matter.

Thanking you for your help,
-- Vishal Deshpande

This is what the tomcat shows in its log when trying to view the service.

org.apache.axis2.description.WSDL2AxisServiceBuilder.processImports(WSDL2AxisServiceBuilder.java
:895) at 
org.apache.axis2.description.WSDL2AxisServiceBuilder.processImports(WSDL2AxisServiceBuilder.java:895)
at 
org.apache.axis2.description.WSDL2AxisServiceBuilder.processImports(WSDL2AxisServiceBuilder.java:895)
at 
org.apache.axis2.description.WSDL2AxisServiceBuilder.populateService(WSDL2AxisServiceBuilder.java:217)
at 
org.apache.axis2.deployment.repository.util.ArchiveReader.processWSDLFile(ArchiveReader.java:192)
at 
org.apache.axis2.deployment.repository.util.ArchiveReader.processWSDLs(ArchiveReader.java:261)
at 
org.apache.axis2.deployment.DeploymentEngine.doDeploy(DeploymentEngine.java:604)
at 
org.apache.axis2.deployment.repository.util.WSInfoList.update(WSInfoList.java:195)
at 
org.apache.axis2.deployment.RepositoryListener.update(RepositoryListener.java:207)
at 
org.apache.axis2.deployment.RepositoryListener.checkServices(RepositoryListener.java:155)
at 
org.apache.axis2.deployment.DeploymentEngine.loadServices(DeploymentEngine.java:91)
at 
org.apache.axis2.deployment.WarBasedAxisConfigurator.loadServices(WarBasedAxisConfigurator.java:142)
at 
org.apache.axis2.context.ConfigurationContextFactory.createConfigurationContext(ConfigurationContextFactory.java:42)
at 
org.apache.axis2.transport.http.AxisServlet.initConfigContext(AxisServlet.java:213)
at org.apache.axis2.transport.http.AxisServlet.init(AxisServlet.java:182)
at 
org.apache.catalina.core.StandardWrapper.loadServlet(StandardWrapper.java:1105)
at org.apache.catalina.core.StandardWrapper.load(StandardWrapper.java:932)
at 
org.apache.catalina.core.StandardContext.loadOnStartup(StandardContext.java:3917)
at org.apache.catalina.core.StandardContext.start(StandardContext.java:4197)
at 
org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:759)
at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:739)
at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:524)
at org.apache.catalina.startup.HostConfig.deployWAR(HostConfig.java:809)
at org.apache.catalina.startup.HostConfig.deployWARs(HostConfig.java:698)
at org.apache.catalina.startup.HostConfig.deployApps(HostConfig.java:472)
at org.apache.catalina.startup.HostConfig.start(HostConfig.java:1112)
at org.apache.catalina.startup.HostConfig.lifecycleEvent(HostConfig.java:310)
at 
org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSupport.java:119)
at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1021)
at org.apache.catalina.core.StandardHost.start(StandardHost.java:718)
at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1013)
at org.apache.catalina.core.StandardEngine.start(StandardEngine.java:442)
at org.apache.catalina.core.StandardService.start(StandardService.java:450)
at org.apache.catalina.core.StandardServer.start(StandardServer.java:709)
at org.apache.catalina.startup.Catalina.start(Catalina.java:551) at
sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:64)
at 
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:615) at
org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:275) at
org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:413)



--
============================
Srinath Perera:
  http://www.cs.indiana.edu/~hperera/
  http://www.bloglines.com/blog/hemapani
<?xml version="1.0" encoding="UTF-8"?>

<definitions xmlns="http://schemas.xmlsoap.org/wsdl/";
					targetNamespace="http://webmind/abraham";
					xmlns:tns="http://webmind/abraham";
					xmlns:xs="http://www.w3.org/2001/XMLSchema"; 
					xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/";					
					xmlns:wmindtypes="http://com/gsk/cix/esp/webmind/services/types"; >
										
	<documentation>
		This is the Abraham Service WSDL. It imports the element types, messages and port types from
		WebMindTypes.wsdl.
		
		Authors: Vishal Deshpande, Partha Rai Chowdhuri
	</documentation>
	
	<import namespace="http://com/gsk/cix/esp/webmind/services/types"; location="WebMindTypes.wsdl" />	

	<types>
		<xs:schema>
			<xs:import namespace="http://com/gsk/cix/esp/webmind/services/types"; />
		</xs:schema>
	</types>

	<!-- Bindings -->
	<binding name="JobBinding" type="wmindtypes:JobPort">
    	<soap:binding transport="http://schemas.xmlsoap.org/soap/http"; style="document"/>
    	
		<operation name="runJob">
			<soap:operation soapAction="runJob"/>
			<input name="RunRequest">
	    		<soap:body use="literal"/>
			</input>
			<output name="RunResponse"> 
				<soap:body use="literal"/>
		  	</output>
		</operation>
		
		<operation name="beginJob">
			<soap:operation soapAction="beginJob"/>
			<input name="BeginRequest">
	    		<soap:body use="literal"/>
	  		</input>
	  		<output name="BeginResponse"> 
	    		<soap:body use="literal"/>
	  		</output>
		</operation>		
    </binding>    
    <!-- End of Bindings -->
  
 	<!-- Service Definition -->
	<service name="Abraham">
		<port name="JobPort" binding="tns:JobBinding">
    		<soap:address location="http://hivemind.gsk.com:8080/axis2/services/abraham"/>
		</port>
	</service>
	<!-- End of Service Definition -->
</definitions>			
<?xml version="1.0" encoding="UTF-8"?>

<definitions xmlns="http://schemas.xmlsoap.org/wsdl/";
	targetNamespace="http://com/gsk/cix/esp/webmind/services/types"; xmlns:tns="http://com/gsk/cix/esp/webmind/services/types";
	xmlns:wdetails="http://com/gsk/cix/esp/webmind/services/types";
	xmlns:xsd="http://www.w3.org/2001/XMLSchema";
	xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/";>

	<documentation>
		This document describes the different element types used across
		multiple web-services (Abrahan, PCH, ...).
		
		Authors: Vishal Deshpande, Partha-Rai Chowdhuri.
	</documentation>

	<types>
		<xsd:schema targetNamespace="http://com/gsk/cix/esp/webmind/services/types";
			xmlns:tns="http://com/gsk/cix/esp/webmind/services/types";
			xmlns:soap11-enc="http://schemas.xmlsoap.org/soap/encoding/";
			xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance";
			xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/";
			xmlns="http://www.w3.org/2001/XMLSchema";>

			<import namespace="http://schemas.xmlsoap.org/soap/encoding/"; />
			
			<!-- Simple Data type definitions -->
			<xsd:element name="cfg_clnt_userNameElement" type="xsd:string" />
			<xsd:element name="cfg_clnt_machNameElement" type="xsd:string" />
			<xsd:element name="cfg_clnt_UserWordElement" type="xsd:string" />

			<xsd:element name="submission_idElement" type="xsd:int" />
			<xsd:element name="statusElement" type="xsd:int" />

			<xsd:element name="srvr_userNameElement" type="xsd:string" />
			<xsd:element name="srvr_userPassElement" type="xsd:string" />
			<xsd:element name="srvr_indirElement" type="xsd:string" />
			<xsd:element name="srvr_pathElement" type="xsd:string" />
			<xsd:element name="user_pathElement" type="xsd:string" />

			<xsd:element name="input_srvr_pathElement" type="xsd:string" />
			<xsd:element name="model_srvr_pathElement" type="xsd:string" />
			<xsd:element name="rslt_file_pathElement" type="xsd:string" />

			<xsd:element name="calc_propElement" type="xsd:string" />
			<xsd:element name="run_complete_pctElement" type="xsd:int" />

			<xsd:element name="clnt_execCountElement" type="xsd:int" />

			<xsd:element name="file_hashElement" type="xsd:string" />

			<xsd:element name="lv_valueElement" type="xsd:int" />

			<xsd:element name="jep_method_suffixElement" type="xsd:string" />

			<xsd:element name="incr_execCountElement" type="xsd:int" />
			<xsd:element name="rslt_execCountElement" type="xsd:int" />
			<xsd:element name="dont_deletFlagElement" type="xsd:boolean" />
			
			<!-- End of simple data type definitions -->
			
			<!-- Signifies the input elements for run method calls -->
			<xsd:element name="runElement">
				<xsd:complexType>
					<xsd:sequence>
						<xsd:element ref="tns:input_srvr_pathElement" />
						<xsd:element ref="tns:jep_method_suffixElement" />
						<xsd:element ref="tns:calc_propElement" />
						<xsd:element ref="tns:incr_execCountElement" />
						<xsd:element ref="tns:dont_deletFlagElement" />
						<xsd:element ref="tns:submission_idElement" />
					</xsd:sequence>
				</xsd:complexType>
			</xsd:element>
			
			<!-- Signifies the input elements for begin method calls -->
			<xsd:element name="beginElement">
				<xsd:complexType>
					<xsd:sequence>
						<xsd:element ref="tns:input_srvr_pathElement" />
						<xsd:element ref="tns:jep_method_suffixElement" />
						<xsd:element ref="tns:calc_propElement" />
						<xsd:element ref="tns:submission_idElement" />
					</xsd:sequence>
				</xsd:complexType>
			</xsd:element>

			<!-- Signifies the output elements for run and term method calls. i.e the response after job completion -->
			<xsd:element name="jobCompletionResponseElement">
				<xsd:complexType>
					<xsd:sequence>
						<xsd:element ref="tns:file_hashElement" />
						<xsd:element ref="tns:statusElement" />
						<xsd:element ref="tns:rslt_file_pathElement" />
						<xsd:element ref="tns:submission_idElement" />
					</xsd:sequence>
				</xsd:complexType>
			</xsd:element>
			
			<!-- Signifies the output elements for begin method calls -->
			<xsd:element name="jobBeginResponseElement">
				<xsd:complexType>
					<xsd:sequence>
						<xsd:element ref="tns:file_hashElement" />
						<xsd:element ref="tns:statusElement" />
						<xsd:element ref="tns:rslt_file_pathElement" />
						<xsd:element ref="tns:submission_idElement" />
					</xsd:sequence>
				</xsd:complexType>
			</xsd:element>

			<!-- Signifies the input elements for server config calls -->			
			<xsd:element name="cfgRequestElement">
				<xsd:complexType>
					<xsd:sequence>
						<xsd:element ref="tns:cfg_clnt_userNameElement" />
						<xsd:element ref="tns:cfg_clnt_machNameElement" />
						<xsd:element ref="tns:cfg_clnt_UserWordElement" />
					</xsd:sequence>
				</xsd:complexType>
			</xsd:element>

			<!-- Signifies the output elements from the server for config calls -->
			<xsd:element name="cfgResponseElement">
				<xsd:complexType>
					<xsd:sequence>
						<xsd:element ref="tns:srvr_indirElement" />
						<xsd:element ref="tns:srvr_userNameElement" />
						<xsd:element ref="tns:srvr_userPassElement" />
					</xsd:sequence>
				</xsd:complexType>
			</xsd:element>

			<!-- Signifies the elements to the server for ftp submit verification calls -->
			<xsd:element name="ftpVerifyRequestElement">
				<xsd:complexType>
					<xsd:sequence>
						<xsd:element ref="tns:srvr_pathElement" />
						<xsd:element ref="tns:user_pathElement" />
						<xsd:element ref="tns:file_hashElement" />
						<xsd:element ref="tns:clnt_execCountElement" />
					</xsd:sequence>
				</xsd:complexType>
			</xsd:element>

			<!-- Signifies the output elements from the server for ftp submit verification calls -->
			<xsd:element name="ftpVerifyResponseElement">
				<xsd:complexType>
					<xsd:sequence>
						<xsd:element ref="tns:submission_idElement" />
						<xsd:element ref="tns:statusElement" />
						<xsd:element ref="tns:clnt_execCountElement" />
					</xsd:sequence>
				</xsd:complexType>
			</xsd:element>


		</xsd:schema>
	</types>
	
	
	<!-- ****************************************************************************************** -->
	<!-- 										Common Messages and Ports													-->
	<!-- ****************************************************************************************** -->
	
	<!-- Begin Job Response Message -->
	<message name="RunJobRequest">
		<part name="parameters" element="tns:runElement"/>
	</message>

	<message name="BeginJobRequest">
		<part name="parameters" element="tns:beginElement" />
	</message>

	<!-- Message Passing Job Submission Id as Input -->
	<message name="JobSubmissionId">
		<part name="parameters" element="tns:submission_idElement"/>
	</message>
		
	<!-- Response corresponding to begin method calls -->
	<message name="BeginJobResponse">
		<part name="result" element="tns:jobBeginResponseElement"/>
	</message>
	
	<!-- Job Completion Response Message. Used as resonse for both Run and Terminate method calls -->
	<message name="JobCompletionResponse">
		<part name="result" element="tns:jobCompletionResponseElement"/>
	</message>	
	
	<!-- Status Request Response Message -->
	<message name="StatusResponse">
		<part name="result" element="tns:statusElement"/>
	</message>

	<!-- Server side Configuration Request Response Message for transport svcs setup -->
	<message name="ConfigRequest">
		<part name="parameters" element="tns:cfgRequestElement" />
	</message>
	<message name="ConfigResponse">
		<part name="result" element="tns:cfgResponseElement" />
	</message>

	<!-- Ftp submit verification Request Response Message -->
	<message name="FtpVerifyRequest">
		<part name="parameters" element="tns:ftpVerifyRequestElement" />
	</message>
	<message name="FtpVerifyResponse">
		<part name="result" element="tns:ftpVerifyResponseElement" />
	</message>

	<!-- End of Messages -->

	<!-- ****************************************************************************************** -->
		
	<!-- Port Type Definitions common across the suite -->	
	<portType name="JobPort">
	    <operation name="runJob">
	      <input name="RunRequest" message="tns:RunJobRequest" />
	      <output name="RunResponse" message="tns:JobCompletionResponse" />
	    </operation>
	    
	    <operation name="beginJob">
			<input name="BeginRequest" message="tns:BeginJobRequest" />
	      <output name="BeginResponse" message="tns:BeginJobResponse" />
	    </operation>
	</portType>
	
	<portType name="JobStatusAndTerminationPort">
		<operation name="jobStatus">
			<input name="StatusRequest" message="tns:JobSubmissionId" />
	      <output name="StatusResponse" message="tns:StatusResponse" />
	    </operation>
	    
	    <operation name="terminateJob">
	      <input name="TermJobRequest" message="tns:JobSubmissionId" />
	      <output name="TermJobResponse" message="tns:JobCompletionResponse" />
	    </operation>
	</portType>

	<portType name="TransportSvcsPort">
		<operation name="getServerConfig">
			<input name="ConfigRequest" message="tns:ConfigRequest" />
			<output name="ConfigResponse" message="tns:ConfigResponse" />
		</operation>

		<operation name="ftpVerify">
			<input name="FtpVerifyRequest" message="tns:FtpVerifyRequest" />
			<output name="FtpVerifyResponse" message="tns:FtpVerifyResponse" />
		</operation>
	</portType>

	<!-- End of Port Type Definitons -->	
	
	<!-- ****************************************************************************************** -->	
</definitions>
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to