13

Similar to this question, I'm interested in what this SystemServiceServlet even is, and what it's relationship is to the /_ah/spi/ directory I see in the autogenerated web.xml.

What purpose do these serve? Why/when are the necessary? Thanks in advance!

Community
  • 1
  • 1
Bantha Fodder
  • 1,242
  • 1
  • 11
  • 19

2 Answers2

13

Behind the scenes each request to an Endpoint (a path in /_ah/api) is mapped to a request in the Endpoints Service Provider Interface (a path in /_ah/spi). The servlet SystemServiceServlet handles these requests. Without this mapping, requests to Endpoints will not succeed.

The Google Plugin for Eclipse adds the mapping automatically when you indicate that you wish to use Endpoints within your app. If you don't use GPE, you need to add the mapping manually.

Dan Holevoet
  • 9,183
  • 1
  • 33
  • 49
  • I've got a problem with this servlet and our cookie based authentication (Vosao CMS). The internal API "translation" that goes via the SystemServiceServlet seems to remember cookies between different users, creating a security nightmare for us. I've been decompiling the Endpoint classes, trying to get my around it. It seems to me a pretend-REST interface that hides RCP via some tricks like the SystemServiceServlet. Couldn't you build an authentic Rest interface from the ground up? – ZiglioUK Jan 16 '14 at 02:27
7

I think this is related to the Google Endpoints API. I enabled them on my project and saw this same change right after.

Bryce
  • 71
  • 1
  • 1
    Thanks @Bryce (+1) - I'll check the Endpoints API out. A few followups for you: Any idea as to why the Google-Eclipse plugin would include these constructs automatically? Do I need them in order to have a GAE app? How did you "enable" them on your project? – Bantha Fodder Oct 22 '12 at 16:57