How does service know when session starts and finishes when its deployed in one of many sessions?
Submitted on June 13, 2006 - 01:25. Story : Project :
Q : When I deploy my service in one of the four sessions, how does my service know when its session starts and finishes. A : There are four session scopes that one can deploy his service in Apache Axis2. No matter which session scope you deploy your service in, it will notify when session starts and when the session finishes. Axis2 notifies service implementation class using Java reflection. Therefor, you have to add two more methods to your service implementation class to have this feature. Both at start and finish of session, it passes ServiceContext so you can store state properties there in service context to manage session.
//This method will called when session start
public void init(ServiceContext stctx){
.....
}
// This method will call when the session finish
public void destroy(ServiceContext stctx){
.....
}
(1 vote)
»
- Login or register to post comments
- Printer friendly version
- 1438 reads
Tag Cloud
Apache Synapse
Axis2
Axis2
Axis2/C
Axis2/C
Rampart/C
WSF/C
Data Services
data services
ESB
ESB
Identity Solution
Sandesha2/Java
Rampart/Java
Axis2/Java
ESB/Java
WSAS/Java
Synapse/Java
AXIOM/Java
JMS
Mashup server
Mashup Server
OpenID
open source
PHP
WSF/PHP
Proxy Services
Rampart
rampart
Rampart/Java
Registry
REST
security
SOA
soap
Spring
Synapse
Synapse
webinar
Web Services
WS-Security
WSAS
WSAS
wsdl
wsf
WSF/C
WSF/PHP
WSO2
WSO2 Registry
WSO2 WSF/PHP










