Sébastien,

you can register a servlet to handle the URL paths; this is done it
the "WEB-INF/web.xml" file:

<web-app...
    <servlet-mapping>
        <servlet-name>handle_connect</servlet-name>
        <url-pattern>/_ah/channel/connected</url-pattern>
    </servlet-mapping>
    <servlet>
        <servlet-name>handle_connect</servlet-name>
        <servlet-class>org.example.MyConnectServlet</servlet-class>
    </servlet>
    ....

MyConnectServlet.java does then the job:

public class ErrorController extends HttpServlet
{
    @Override
    protected void doPost(HttpServletRequest req, HttpServletResponse
resp) throws ServletException, IOException
    {
        //Handle request and write response
    }
}

Hope this can help you.



On Jul 27, 12:00 pm, Sébastien Tromp <sebastien.tr...@gmail.com>
wrote:
> Hello,
>
> In the Presence sectiono of the Channel documentation, it says:
>
> When you enable channel_presence, your application receives POSTs to the
>
> > following URL paths:
>
> >    - POSTs to /_ah/channel/connected/ signal that the client has connected
> >    to the channel and can receive messages.
>
> >    - POSTs to /_ah/channel/disconnected/ signal that the client has
> >    disconnected from the channel.
>
> Your application can register handlers to these paths in order to receive
>
> > notifications. You can use these notifications to track which clients are
> > currently connected.
>
> However, I am clueless as to how to do that. How can I register a handle to
> these paths?
> I am currently using GAE 1.5.1, GWT and Guice.
>
> Thanks for any hint,
> --
> Sébastien Tromp

-- 
You received this message because you are subscribed to the Google Groups 
"Google App Engine for Java" group.
To post to this group, send email to google-appengine-java@googlegroups.com.
To unsubscribe from this group, send email to 
google-appengine-java+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/google-appengine-java?hl=en.

Reply via email to