You are viewing a plain text version of this content. The canonical link for it is here.
Posted to java-user@axis.apache.org by Lenny Wintfeld <le...@cecilrep.com> on 2006/11/28 00:13:32 UTC

Re: Question on the quickstartadb sample

Correction to the query below: I am using implementation code from "Code 
Listing 6" not "Code listing 1" and the params are called param3 and 
param4, not param0/param1 as shown in Code Listing 6. Sorry if this 
caused any confusion. -Lenny Wintfeld

Lenny Wintfeld wrote:
> I have used the eclipse Code Generator Wizard plugin with the 
> quickstartadb sample. It successfully created java code corresponding 
> to the quickstartadb's wsdl file "StockQuoteService.wsdl".  I added 
> the implementation of the StockQuoteServiceSkeleton shown in the Axis 
> 2 web quick start  guide page to the generated skeleton code (this is 
> "Code Listing 1" in 
> http://ws.apache.org/axis2/1_1/quickstartguide.html).   I have built 
> the code without problems, using eclipse. I created a .aar from the 
> class, services.xml and wsdl files,  and it deploys ok on a local 
> instance of Tomcat 5.5. I am also able to set breakpoints and single 
> step the code in the .aar in Tomcat using Eclipse 3.1.2. Running the 
> "getPrice" service returns the default value of 42.
>
> Single stepping shows that the  HashMap  "map"  in  Code Listing 1 is 
> being written with 100.0 to location "IBM" when the "update" web 
> service is invoked from the browser ( as shown in the Axis2 Quick 
> Start Guide) when I enter
>
> http://localhost:8080/axis2/rest/StockQuoteService/update?symbol=IBM&price=100 
>
>
> But when I subsequently  use the getPrice web service with  
> http://localhost:8080/axis2/rest/StockQuoteService/getPrice?symbol=IBM, 
> the return value from the HashMap is null, and I get another return of 
> 42 instead of 100.0!!!
>
> My questions are :
>
> 1. Is the web service unloaded from memory by Tomcat after each 
> invocation? If so, is there a way to prevent this from happening?
>
> 2. The Axis 2 Quick Start Guide clearly expects the new value to show 
> up after a update / getPrice sequence of web service calls.  Why is 
> this not happening with my build of the web service?  Is there some 
> hidden serialization / re-initialization of the HashMap that should be 
> happening behind the scenes which is not occurring? Or what?
>
> Before I start getting serious with this, I'd like to get a short 
> explanation of the above, if anyone can help me. Also, I have a total 
> of 3 days experience with Web Services development. The www is pretty 
> good for getting brief snips of information about Web Services, but is 
> there a GOOD book on this subject?
>
> Thanks in advance for your help.
>
> Lenny Wintfeld
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: axis-user-unsubscribe@ws.apache.org
> For additional commands, e-mail: axis-user-help@ws.apache.org
>
>
>


---------------------------------------------------------------------
To unsubscribe, e-mail: axis-user-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-user-help@ws.apache.org