GaeAuthFilter and RequestFactory

44 views
Skip to first unread message

Bernd

unread,
Oct 23, 2011, 7:18:55 AM10/23/11
to google-we...@googlegroups.com
Hi,

I have implemented the GaeAuthFilter (from expenses example ) in my GWT Application.

    <filter-mapping>
        <filter-name>GaeAuthFilter</filter-name>
        <url-pattern>/gwtRequest/*</url-pattern>
    </filter-mapping>

So all calls to gwtRequests will be filtered and the authentication will be checked.
My problem is that when a request is catched the created LoginUrl simply uses a GET command and fails after login.

      response.setHeader("login", userService.createLoginURL(request.getRequestURI()));

He simply tried to load the URL http://127.0.0.1:8888/gwtRequest with no further data included. So I get this error:

HTTP method GET is not supported by this URL

How can I resolve this problem?

Thx for your help

 

Thomas Broyer

unread,
Oct 23, 2011, 12:26:58 PM10/23/11
to google-we...@googlegroups.com
Do not use request.getRequestURI() as an argument to createLoginURL. Instead, pass the URL as a header in the request. See http://code.google.com/p/google-web-toolkit/source/browse/trunk/samples/mobilewebapp/src/main/java/com/google/gwt/sample/gaerequest/

Bernd

unread,
Oct 31, 2011, 11:50:02 AM10/31/11
to google-we...@googlegroups.com
Thank you for your help. It works now.
Reply all
Reply to author
Forward
0 new messages