• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Liutauras Vilda
  • Paul Clapham
Sheriffs:
  • paul wheaton
  • Tim Cooke
  • Henry Wong
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Piet Souris
Bartenders:
  • Mike London

why to keep login contolller as Spring REST service?

 
Ranch Hand
Posts: 2627
13
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
i have seen applications of spring where along with other functionalites. even login authentication is also kept as spring service.but what i didn't understand is that why to keep it as rest service.I mean what is the advantage which we get by keeping login as rest service?what would the GET request xml of login webservice show?
 
Bartender
Posts: 1682
7
Android Mac OS X IntelliJ IDE Spring Linux
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I think you will need to link the application you are looking at if its a tutorial. I don't quite understand the question. Typically you would use the Spring Security project for this kind of thing.

http://www.springsource.org/spring-security
 
ranger
Posts: 17347
11
Mac IntelliJ IDE Spring
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
My app is using REST for login because my app is. Single page app and if I wasn't a REST API it would be at least a two page app and require jsp pages. I don't want either in my app.
 
Monica Shiralkar
Ranch Hand
Posts: 2627
13
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
thanks.
ok.so what info would the GET method of this app or yours display as xml.?there lies my confusion
 
Mark Spritzler
ranger
Posts: 17347
11
Mac IntelliJ IDE Spring
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Monica. Shiralkar wrote:thanks.
ok.so what info would the GET method of this app or yours display as xml.?there lies my confusion



Which GET? The login? I don't have any GET for login, just POST for when the user enters their credentials. And for that I use Spring Security. For REST login, I do have to do some things manually in Spring Security, but that is like 4-5 lines of code. But to get a single page app, I am willing to write those few lines.

Mark
 
Mark Spritzler
ranger
Posts: 17347
11
Mac IntelliJ IDE Spring
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
OH, and I have no XML. I have json data being passed back and forth in my app through my AJAX calls.

Mark
 
reply
    Bookmark Topic Watch Topic
  • New Topic