axis-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From am am <akme...@yahoo.com>
Subject axis2 session scopes
Date Sun, 23 Jan 2011 12:11:50 GMT
I am starting on axis2 (1.5.4).
I am looking into the various session scopes for web services (request, 
soapsession etc).
By experimenting, I notice that in all scopes except the application scope, 
there is a new instance of my web service being created per service call.
Only by setting the scope to "application" in the services.xml, the web service 
is instantiated only once, and being re-used across all web service calls.
My testing for this, was actually a print statement in the web service 
constructor. The constructor was called for scope="request" or 
scope="soapsession" or scope="transportsession" for each ws call.
So my question is the following: Is this the case in axis2? And if yes, for 
non-trivial web services, isn't it very costly (to re-instantiate per service 
call)?
Is the recommended approach to use application scope services? Or my 
understanding is wrong here?

Thank you!


      
Mime
View raw message