You are viewing a plain text version of this content. The canonical link for it is here.
Posted to soap-user@ws.apache.org by Jia YU <ji...@cs.mu.OZ.AU> on 2003/07/24 06:40:30 UTC

response time testing [urgent]

I set up a web services with soap2.2.

I want to time the response time on client sides. I wrote a loop to send
request 10 times to the Web services. the first one is very long others
are very short. if I start program again the result is same, first one
is long but others are short.

I attached the program pls help why? Do you have any idea how to do
timing for web services? 

I also time the myrpc.invoke() the result is same first time is long
others short.

What can cause this problem? some wrong with my program? I knew the
webservice use http service. it may have sock connection setup on the
first time, but my question is I create new soap connection everytime in
the loop,why the time is short after first query and why if I run new
program again the first time become very long too. how can http server
know it is different program rather than different soap call.


Please help!!!



***This is my test program
		String sName=commandLine.getFlagArg("-serviceName");

                GMDQuery g=null;
                long time=0;
                for(int i=0;i<10;i++){
                try{
			//create a class which is for soap query (code is below)
                      	g=new
			GMDQuery(gmdHost,Integer.parseInt(port),soapDir,soapServiceName); 
                        Price p=null;
                        long st=System.currentTimeMillis();   //start
time
                        p=g.getPrice(sName.trim());
                        long ft=System.currentTimeMillis();   //finish
time
                        time=(ft-st)+time;
                        System.out.println("Done: "+ (ft-st));
                        System.out.println(p.toString());
                        }catch(GMDQueryException e){
                                System.err.println(e.getMessage());
                                System.exit(2);
                        }

                        }//for

***My query class

		public class GMDQuery {
		        Call myrpc;
        		String servicePoint;
		
			public GMDQuery(String host, int port, String soapDir, String
soapServiceName) throws GMDQueryException{
	        	        Properties props = new Properties();
           
				servicePoint="http://"+host+":"+String.valueOf(port)+soapDir;
        			System.out.println("Current GMD is on "+servicePoint+"\n");

                		myrpc = new Call();
                	      myrpc.setTargetObjectURI(soapServiceName);
     			}

			public Price getPrice(String sName) throws GMDQueryException{
                		Element QueryPriceRoot=new Element("QUERY-PRICE");
                		QueryPriceRoot.addContent(new
Element("SERVICE_NAME").setText(sName));
                		Document QueryPrice=new Document(QueryPriceRoot);
                		XMLOutputter outputter=new XMLOutputter(" ",true);
                		String outReq=outputter.outputString(QueryPrice);

                		//for looking at xml message
                		//System.out.println(outReq);

            			myrpc.setMethodName("queryPrice");

            			String rxml=null;
            			try{
               				 rxml=executeSOAPQuery(outReq);
            				}catch(GMDQueryException e){
               				 throw e;
           			 }
					......
            			 return new Price(hPrice,sPrice);
        		}
			
			        private String executeSOAPQuery(String outReq) throws
GMDQueryException{

               
				myrpc.setEncodingStyleURI("http://schemas.xmlsoap.org/soap/encoding/");

                //Create a URL object, which represents the endpoint
                URL url=null;

                try{
                        url=new URL(servicePoint);
                }catch(java.net.MalformedURLException e){
                        throw new GMDQueryException(e.getMessage());
                }

                // Add Parameters
            if(!outReq.equals("")){
                        Vector myparams = new Vector(1);
                        myparams.addElement(new Parameter("inputReq",
String.class, outReq,null));
                        myrpc.setParams(myparams);
            }

                //Send the SOAP RPC request message using invoke()
method
                Response resp=null;

                try{
                        resp=myrpc.invoke(url," ");
                }catch(org.apache.soap.SOAPException e){
                        throw new GMDQueryException("connection error");
                }

                //Check the response.
                Parameter result=null;

                if(resp.generatedFault()){    //Error Occured
                        Fault fault=resp.getFault();
                        throw new GMDQueryException("GMD
Error:"+fault.getFaultString());
                }else {
                         result=resp.getReturnValue();
                }
                return result.getValue().toString();
        }

		





			
				






Re: response time testing [urgent]

Posted by Scott Nichol <sn...@scottnichol.com>.
I don't know the specifics of WebSphere.  As for speeding up performance, the currently nightly builds of Apache SOAP are faster than either the 2.3.1 or 2.2 release builds.  If you are using 2.3.1 and cannot move to a nightly build, on your client create the SOAPHTTPConnection separately from the Call and invoke SOAPHTTPConnection#setNoDelay with the argument set to Boolean.TRUE.  That will disable the Nagle algorithm which causes a delay on the order of 100s of milliseconds.

Scott Nichol

Do not send e-mail directly to this e-mail address,
because it is filtered to accept only mail from
specific mail lists.

----- Original Message ----- 
From: "Vishal Shah" <sh...@yahoo.com>
To: <so...@ws.apache.org>
Sent: Friday, July 25, 2003 1:35 PM
Subject: Re: response time testing [urgent]


> Is there anyway to improve the performance, overall ? I experienced the same thing. My service scope is a "request" type. Can the app server conjure up a dummy service (so as to load apache code first time as you mentioned below ) and be ready for the actual service traffic ? My understanding is WebSphere doesn't load it dynamically...The classes are deployed and ready-to-serve when the server is boot up.
>  
> Regards,
>  
> Scott Nichol <sn...@scottnichol.com> wrote:
> The long time for the first execution is probably time required for the JVM to load classes. Remember they are loaded dynamically as needed, not all at once when your app starts executing. There is a similar issue on the server. The first time any Apache SOAP service is invoked, tons of code has to be loaded, and it seems like it takes *forever*. The first time a different Apache SOAP service is invoked, the Apache SOAP code is loaded, but code for the service must be loaded, and there is a delay.
> 
> When I benchmark, I always write code to ignore the time of the first time through my loop so that I am not measuring the time required to load classes, etc.
> 
> Scott Nichol
> 
> Do not send e-mail directly to this e-mail address,
> because it is filtered to accept only mail from
> specific mail lists.
> ----- Original Message ----- 
> From: "Jia YU" 
> To: 
> Sent: Thursday, July 24, 2003 12:40 AM
> Subject: response time testing [urgent]
> 
> 
> > 
> > I set up a web services with soap2.2.
> > 
> > I want to time the response time on client sides. I wrote a loop to send
> > request 10 times to the Web services. the first one is very long others
> > are very short. if I start program again the result is same, first one
> > is long but others are short.
> > 
> > I attached the program pls help why? Do you have any idea how to do
> > timing for web services? 
> > 
> > I also time the myrpc.invoke() the result is same first time is long
> > others short.
> > 
> > What can cause this problem? some wrong with my program? I knew the
> > webservice use http service. it may have sock connection setup on the
> > first time, but my question is I create new soap connection everytime in
> > the loop,why the time is short after first query and why if I run new
> > program again the first time become very long too. how can http server
> > know it is different program rather than different soap call.
> > 
> > 
> > Please help!!!
> > 
> > 
> > 
> > ***This is my test program
> > String sName=commandLine.getFlagArg("-serviceName");
> > 
> > GMDQuery g=null;
> > long time=0;
> > for(int i=0;i<10;i++){
> > try{
> > //create a class which is for soap query (code is below)
> > g=new
> > GMDQuery(gmdHost,Integer.parseInt(port),soapDir,soapServiceName); 
> > Price p=null;
> > long st=System.currentTimeMillis(); //start
> > time
> > p=g.getPrice(sName.trim());
> > long ft=System.currentTimeMillis(); //finish
> > time
> > time=(ft-st)+time;
> > System.out.println("Done: "+ (ft-st));
> > System.out.println(p.toString());
> > }catch(GMDQueryException e){
> > System.err.println(e.getMessage());
> > System.exit(2);
> > }
> > 
> > }//for
> > 
> > ***My query class
> > 
> > public class GMDQuery {
> > Call myrpc;
> > String servicePoint;
> > 
> > public GMDQuery(String host, int port, String soapDir, String
> > soapServiceName) throws GMDQueryException{
> > Properties props = new Properties();
> > 
> > servicePoint="http://"+host+":"+String.valueOf(port)+soapDir;
> > System.out.println("Current GMD is on "+servicePoint+"\n");
> > 
> > myrpc = new Call();
> > myrpc.setTargetObjectURI(soapServiceName);
> > }
> > 
> > public Price getPrice(String sName) throws GMDQueryException{
> > Element QueryPriceRoot=new Element("QUERY-PRICE");
> > QueryPriceRoot.addContent(new
> > Element("SERVICE_NAME").setText(sName));
> > Document QueryPrice=new Document(QueryPriceRoot);
> > XMLOutputter outputter=new XMLOutputter(" ",true);
> > String outReq=outputter.outputString(QueryPrice);
> > 
> > //for looking at xml message
> > //System.out.println(outReq);
> > 
> > myrpc.setMethodName("queryPrice");
> > 
> > String rxml=null;
> > try{
> > rxml=executeSOAPQuery(outReq);
> > }catch(GMDQueryException e){
> > throw e;
> > }
> > ......
> > return new Price(hPrice,sPrice);
> > }
> > 
> > private String executeSOAPQuery(String outReq) throws
> > GMDQueryException{
> > 
> > 
> > myrpc.setEncodingStyleURI("http://schemas.xmlsoap.org/soap/encoding/");
> > 
> > //Create a URL object, which represents the endpoint
> > URL url=null;
> > 
> > try{
> > url=new URL(servicePoint);
> > }catch(java.net.MalformedURLException e){
> > throw new GMDQueryException(e.getMessage());
> > }
> > 
> > // Add Parameters
> > if(!outReq.equals("")){
> > Vector myparams = new Vector(1);
> > myparams.addElement(new Parameter("inputReq",
> > String.class, outReq,null));
> > myrpc.setParams(myparams);
> > }
> > 
> > //Send the SOAP RPC request message using invoke()
> > method
> > Response resp=null;
> > 
> > try{
> > resp=myrpc.invoke(url," ");
> > }catch(org.apache.soap.SOAPException e){
> > throw new GMDQueryException("connection error");
> > }
> > 
> > //Check the response.
> > Parameter result=null;
> > 
> > if(resp.generatedFault()){ //Error Occured
> > Fault fault=resp.getFault();
> > throw new GMDQueryException("GMD
> > Error:"+fault.getFaultString());
> > }else {
> > result=resp.getReturnValue();
> > }
> > return result.getValue().toString();
> > }
> > 
> > 
> > 
> > 
> > 
> > 
> > 
> > 
> > 
> > 
> > 
> > 
> > 
> > 
> > 
> 
> 
> ---------------------------------
> Do you Yahoo!?
> Yahoo! SiteBuilder - Free, easy-to-use web site design software

Re: response time testing [urgent]

Posted by Vishal Shah <sh...@yahoo.com>.
Is there anyway to improve the performance, overall ? I experienced the same thing. My service scope is a "request" type. Can the app server conjure up a dummy service (so as to load apache code first time as you mentioned below ) and be ready for the actual service traffic ? My understanding is WebSphere doesn't load it dynamically...The classes are deployed and ready-to-serve when the server is boot up.
 
Regards,
 
Scott Nichol <sn...@scottnichol.com> wrote:
The long time for the first execution is probably time required for the JVM to load classes. Remember they are loaded dynamically as needed, not all at once when your app starts executing. There is a similar issue on the server. The first time any Apache SOAP service is invoked, tons of code has to be loaded, and it seems like it takes *forever*. The first time a different Apache SOAP service is invoked, the Apache SOAP code is loaded, but code for the service must be loaded, and there is a delay.

When I benchmark, I always write code to ignore the time of the first time through my loop so that I am not measuring the time required to load classes, etc.

Scott Nichol

Do not send e-mail directly to this e-mail address,
because it is filtered to accept only mail from
specific mail lists.
----- Original Message ----- 
From: "Jia YU" 
To: 
Sent: Thursday, July 24, 2003 12:40 AM
Subject: response time testing [urgent]


> 
> I set up a web services with soap2.2.
> 
> I want to time the response time on client sides. I wrote a loop to send
> request 10 times to the Web services. the first one is very long others
> are very short. if I start program again the result is same, first one
> is long but others are short.
> 
> I attached the program pls help why? Do you have any idea how to do
> timing for web services? 
> 
> I also time the myrpc.invoke() the result is same first time is long
> others short.
> 
> What can cause this problem? some wrong with my program? I knew the
> webservice use http service. it may have sock connection setup on the
> first time, but my question is I create new soap connection everytime in
> the loop,why the time is short after first query and why if I run new
> program again the first time become very long too. how can http server
> know it is different program rather than different soap call.
> 
> 
> Please help!!!
> 
> 
> 
> ***This is my test program
> String sName=commandLine.getFlagArg("-serviceName");
> 
> GMDQuery g=null;
> long time=0;
> for(int i=0;i<10;i++){
> try{
> //create a class which is for soap query (code is below)
> g=new
> GMDQuery(gmdHost,Integer.parseInt(port),soapDir,soapServiceName); 
> Price p=null;
> long st=System.currentTimeMillis(); //start
> time
> p=g.getPrice(sName.trim());
> long ft=System.currentTimeMillis(); //finish
> time
> time=(ft-st)+time;
> System.out.println("Done: "+ (ft-st));
> System.out.println(p.toString());
> }catch(GMDQueryException e){
> System.err.println(e.getMessage());
> System.exit(2);
> }
> 
> }//for
> 
> ***My query class
> 
> public class GMDQuery {
> Call myrpc;
> String servicePoint;
> 
> public GMDQuery(String host, int port, String soapDir, String
> soapServiceName) throws GMDQueryException{
> Properties props = new Properties();
> 
> servicePoint="http://"+host+":"+String.valueOf(port)+soapDir;
> System.out.println("Current GMD is on "+servicePoint+"\n");
> 
> myrpc = new Call();
> myrpc.setTargetObjectURI(soapServiceName);
> }
> 
> public Price getPrice(String sName) throws GMDQueryException{
> Element QueryPriceRoot=new Element("QUERY-PRICE");
> QueryPriceRoot.addContent(new
> Element("SERVICE_NAME").setText(sName));
> Document QueryPrice=new Document(QueryPriceRoot);
> XMLOutputter outputter=new XMLOutputter(" ",true);
> String outReq=outputter.outputString(QueryPrice);
> 
> //for looking at xml message
> //System.out.println(outReq);
> 
> myrpc.setMethodName("queryPrice");
> 
> String rxml=null;
> try{
> rxml=executeSOAPQuery(outReq);
> }catch(GMDQueryException e){
> throw e;
> }
> ......
> return new Price(hPrice,sPrice);
> }
> 
> private String executeSOAPQuery(String outReq) throws
> GMDQueryException{
> 
> 
> myrpc.setEncodingStyleURI("http://schemas.xmlsoap.org/soap/encoding/");
> 
> //Create a URL object, which represents the endpoint
> URL url=null;
> 
> try{
> url=new URL(servicePoint);
> }catch(java.net.MalformedURLException e){
> throw new GMDQueryException(e.getMessage());
> }
> 
> // Add Parameters
> if(!outReq.equals("")){
> Vector myparams = new Vector(1);
> myparams.addElement(new Parameter("inputReq",
> String.class, outReq,null));
> myrpc.setParams(myparams);
> }
> 
> //Send the SOAP RPC request message using invoke()
> method
> Response resp=null;
> 
> try{
> resp=myrpc.invoke(url," ");
> }catch(org.apache.soap.SOAPException e){
> throw new GMDQueryException("connection error");
> }
> 
> //Check the response.
> Parameter result=null;
> 
> if(resp.generatedFault()){ //Error Occured
> Fault fault=resp.getFault();
> throw new GMDQueryException("GMD
> Error:"+fault.getFaultString());
> }else {
> result=resp.getReturnValue();
> }
> return result.getValue().toString();
> }
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 


---------------------------------
Do you Yahoo!?
Yahoo! SiteBuilder - Free, easy-to-use web site design software

Re: response time testing [urgent]

Posted by Scott Nichol <sn...@scottnichol.com>.
The long time for the first execution is probably time required for the JVM to load classes.  Remember they are loaded dynamically as needed, not all at once when your app starts executing.  There is a similar issue on the server.  The first time any Apache SOAP service is invoked, tons of code has to be loaded, and it seems like it takes *forever*.  The first time a different Apache SOAP service is invoked, the Apache SOAP code is loaded, but code for the service must be loaded, and there is a delay.

When I benchmark, I always write code to ignore the time of the first time through my loop so that I am not measuring the time required to load classes, etc.

Scott Nichol

Do not send e-mail directly to this e-mail address,
because it is filtered to accept only mail from
specific mail lists.
----- Original Message ----- 
From: "Jia YU" <ji...@cs.mu.OZ.AU>
To: <so...@ws.apache.org>
Sent: Thursday, July 24, 2003 12:40 AM
Subject: response time testing [urgent]


> 
> I set up a web services with soap2.2.
> 
> I want to time the response time on client sides. I wrote a loop to send
> request 10 times to the Web services. the first one is very long others
> are very short. if I start program again the result is same, first one
> is long but others are short.
> 
> I attached the program pls help why? Do you have any idea how to do
> timing for web services? 
> 
> I also time the myrpc.invoke() the result is same first time is long
> others short.
> 
> What can cause this problem? some wrong with my program? I knew the
> webservice use http service. it may have sock connection setup on the
> first time, but my question is I create new soap connection everytime in
> the loop,why the time is short after first query and why if I run new
> program again the first time become very long too. how can http server
> know it is different program rather than different soap call.
> 
> 
> Please help!!!
> 
> 
> 
> ***This is my test program
> String sName=commandLine.getFlagArg("-serviceName");
> 
>                 GMDQuery g=null;
>                 long time=0;
>                 for(int i=0;i<10;i++){
>                 try{
> //create a class which is for soap query (code is below)
>                       g=new
> GMDQuery(gmdHost,Integer.parseInt(port),soapDir,soapServiceName); 
>                         Price p=null;
>                         long st=System.currentTimeMillis();   //start
> time
>                         p=g.getPrice(sName.trim());
>                         long ft=System.currentTimeMillis();   //finish
> time
>                         time=(ft-st)+time;
>                         System.out.println("Done: "+ (ft-st));
>                         System.out.println(p.toString());
>                         }catch(GMDQueryException e){
>                                 System.err.println(e.getMessage());
>                                 System.exit(2);
>                         }
> 
>                         }//for
> 
> ***My query class
> 
> public class GMDQuery {
>         Call myrpc;
>         String servicePoint;
> 
> public GMDQuery(String host, int port, String soapDir, String
> soapServiceName) throws GMDQueryException{
>                 Properties props = new Properties();
>            
> servicePoint="http://"+host+":"+String.valueOf(port)+soapDir;
>         System.out.println("Current GMD is on "+servicePoint+"\n");
> 
>                 myrpc = new Call();
>                       myrpc.setTargetObjectURI(soapServiceName);
>      }
> 
> public Price getPrice(String sName) throws GMDQueryException{
>                 Element QueryPriceRoot=new Element("QUERY-PRICE");
>                 QueryPriceRoot.addContent(new
> Element("SERVICE_NAME").setText(sName));
>                 Document QueryPrice=new Document(QueryPriceRoot);
>                 XMLOutputter outputter=new XMLOutputter(" ",true);
>                 String outReq=outputter.outputString(QueryPrice);
> 
>                 //for looking at xml message
>                 //System.out.println(outReq);
> 
>             myrpc.setMethodName("queryPrice");
> 
>             String rxml=null;
>             try{
>                rxml=executeSOAPQuery(outReq);
>             }catch(GMDQueryException e){
>                throw e;
>            }
> ......
>             return new Price(hPrice,sPrice);
>         }
> 
>         private String executeSOAPQuery(String outReq) throws
> GMDQueryException{
> 
>                
> myrpc.setEncodingStyleURI("http://schemas.xmlsoap.org/soap/encoding/");
> 
>                 //Create a URL object, which represents the endpoint
>                 URL url=null;
> 
>                 try{
>                         url=new URL(servicePoint);
>                 }catch(java.net.MalformedURLException e){
>                         throw new GMDQueryException(e.getMessage());
>                 }
> 
>                 // Add Parameters
>             if(!outReq.equals("")){
>                         Vector myparams = new Vector(1);
>                         myparams.addElement(new Parameter("inputReq",
> String.class, outReq,null));
>                         myrpc.setParams(myparams);
>             }
> 
>                 //Send the SOAP RPC request message using invoke()
> method
>                 Response resp=null;
> 
>                 try{
>                         resp=myrpc.invoke(url," ");
>                 }catch(org.apache.soap.SOAPException e){
>                         throw new GMDQueryException("connection error");
>                 }
> 
>                 //Check the response.
>                 Parameter result=null;
> 
>                 if(resp.generatedFault()){    //Error Occured
>                         Fault fault=resp.getFault();
>                         throw new GMDQueryException("GMD
> Error:"+fault.getFaultString());
>                 }else {
>                          result=resp.getReturnValue();
>                 }
>                 return result.getValue().toString();
>         }
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 

Re: response time testing [urgent]

Posted by Daniel Zhang <zh...@clinicaltools.com>.
By reviewing your code, I guess the reason is that the program needs to 
create a new instance of class Price the first time you call 
g.getPrice(sName.trim()). The second time and later calls, instead of 
creating new object, it picks up the already created Price object  in 
memory pool. Therefore the first time is long and others are short. When 
program terminates, the system cleans the memory. Hence when you 
restart, program can not find Price object in memory and it needs to 
create a new one the first time which is time consuming. Later on it 
picks up from pool and it gets quicker.

All Java web services have the same observation. The first time program 
creates new objects and as long as you are in the same session, it can 
pull out from the memory pool whenever it needs. Look, truck always 
looks clumsy when it gets start first time. This is the so-called 
inertia which exists not only in physics but also in computer science. ;-)

-Daniel

Jia YU wrote:

>I set up a web services with soap2.2.
>
>I want to time the response time on client sides. I wrote a loop to send
>request 10 times to the Web services. the first one is very long others
>are very short. if I start program again the result is same, first one
>is long but others are short.
>
>I attached the program pls help why? Do you have any idea how to do
>timing for web services? 
>
>I also time the myrpc.invoke() the result is same first time is long
>others short.
>
>What can cause this problem? some wrong with my program? I knew the
>webservice use http service. it may have sock connection setup on the
>first time, but my question is I create new soap connection everytime in
>the loop,why the time is short after first query and why if I run new
>program again the first time become very long too. how can http server
>know it is different program rather than different soap call.
>
>
>Please help!!!
>
>
>
>***This is my test program
>		String sName=commandLine.getFlagArg("-serviceName");
>
>                GMDQuery g=null;
>                long time=0;
>                for(int i=0;i<10;i++){
>                try{
>			//create a class which is for soap query (code is below)
>                      	g=new
>			GMDQuery(gmdHost,Integer.parseInt(port),soapDir,soapServiceName); 
>                        Price p=null;
>                        long st=System.currentTimeMillis();   //start
>time
>                        p=g.getPrice(sName.trim());
>                        long ft=System.currentTimeMillis();   //finish
>time
>                        time=(ft-st)+time;
>                        System.out.println("Done: "+ (ft-st));
>                        System.out.println(p.toString());
>                        }catch(GMDQueryException e){
>                                System.err.println(e.getMessage());
>                                System.exit(2);
>                        }
>
>                        }//for
>
>***My query class
>
>		public class GMDQuery {
>		        Call myrpc;
>        		String servicePoint;
>		
>			public GMDQuery(String host, int port, String soapDir, String
>soapServiceName) throws GMDQueryException{
>	        	        Properties props = new Properties();
>           
>				servicePoint="http://"+host+":"+String.valueOf(port)+soapDir;
>        			System.out.println("Current GMD is on "+servicePoint+"\n");
>
>                		myrpc = new Call();
>                	      myrpc.setTargetObjectURI(soapServiceName);
>     			}
>
>			public Price getPrice(String sName) throws GMDQueryException{
>                		Element QueryPriceRoot=new Element("QUERY-PRICE");
>                		QueryPriceRoot.addContent(new
>Element("SERVICE_NAME").setText(sName));
>                		Document QueryPrice=new Document(QueryPriceRoot);
>                		XMLOutputter outputter=new XMLOutputter(" ",true);
>                		String outReq=outputter.outputString(QueryPrice);
>
>                		//for looking at xml message
>                		//System.out.println(outReq);
>
>            			myrpc.setMethodName("queryPrice");
>
>            			String rxml=null;
>            			try{
>               				 rxml=executeSOAPQuery(outReq);
>            				}catch(GMDQueryException e){
>               				 throw e;
>           			 }
>					......
>            			 return new Price(hPrice,sPrice);
>        		}
>			
>			        private String executeSOAPQuery(String outReq) throws
>GMDQueryException{
>
>               
>				myrpc.setEncodingStyleURI("http://schemas.xmlsoap.org/soap/encoding/");
>
>                //Create a URL object, which represents the endpoint
>                URL url=null;
>
>                try{
>                        url=new URL(servicePoint);
>                }catch(java.net.MalformedURLException e){
>                        throw new GMDQueryException(e.getMessage());
>                }
>
>                // Add Parameters
>            if(!outReq.equals("")){
>                        Vector myparams = new Vector(1);
>                        myparams.addElement(new Parameter("inputReq",
>String.class, outReq,null));
>                        myrpc.setParams(myparams);
>            }
>
>                //Send the SOAP RPC request message using invoke()
>method
>                Response resp=null;
>
>                try{
>                        resp=myrpc.invoke(url," ");
>                }catch(org.apache.soap.SOAPException e){
>                        throw new GMDQueryException("connection error");
>                }
>
>                //Check the response.
>                Parameter result=null;
>
>                if(resp.generatedFault()){    //Error Occured
>                        Fault fault=resp.getFault();
>                        throw new GMDQueryException("GMD
>Error:"+fault.getFaultString());
>                }else {
>                         result=resp.getReturnValue();
>                }
>                return result.getValue().toString();
>        }
>
>		
>
>
>
>
>
>			
>				
>
>
>
>
>  
>