• Post Reply Bookmark Topic Watch Topic
  • New Topic

Webservice Session Management  RSS feed

 
ajjju kumar
Greenhorn
Posts: 9
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hello All,

I am using Axis2 Webservice for the Application which i am doing ..Here i am worried where i can manage the Session in webservices..

Scenario :


Service taking uname and password and checks whether it is valid or not and if valid keeps the username into the session ..

After that it calls other webservices(webservice to webservice communication) and there by retrieving the username from session it has to bring certain values from Database and keeps the values into the session..

Please help me in session management and also how to manage session between 2 or more webservices and also the invalidation process..

Please help me in this..

I have no other option as i am invoking this service from mobile App..

Thanks in advance,

Ajju

 
Ulf Dittmer
Rancher
Posts: 42970
73
  • Likes 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
For starters I would advise to use a REST WS for the mobile app to access.

Furthermore, sessions are not really used with WS. After initial authentication you would send back to the client a cryptographically secure ID it would then send along to authenticate subsequent requests.
 
ajjju kumar
Greenhorn
Posts: 9
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thank you.. so, you say that we need to travel through the webservices along with the unique ID to get the request information of request and also fo further authentication ...

Why Axis 2 webservices(SOAP) is not recommended for Mobile App...?
 
Ulf Dittmer
Rancher
Posts: 42970
73
  • Likes 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
REST is the preferred approach for all WS these days. While SOAP has advantages over REST, it also has drawbacks in that there is more overhead in development and deployment. It it also much more verbose than REST - always a consideration for mobile. Plus, you need another library in your app (e.g. something like ksoap2 for Android), whereas basic HTTP -which is all that you need for REST- is supported in the base API of any serious mobile platform. SOAP APIs are also generally a non-starter for use in web pages via JavaScript.
 
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!