I did some quick testing and I found out:

QueueFactory.getQueue("email-
queue").add(TaskOptions.Builder.withPayload(new
EmailTask(email)).url("/email-queue"));

that with above I can enqueue a deferred task in the another queue
(not default).
I had to to use the url("/email-queue") setting otherwise it was
pushed to the default __deferred__ handler.

I just configured the
com.google.apphosting.utils.servlet.DeferredTaskServlet and mapped it
to /email-queue

When I try System.out.println("queue name: " +
DeferredTaskContext.getCurrentRequest().getHeader("X-AppEngine-
QueueName"));
I see the correct e-mail-queue being printed thus so far everything
seems to work.

I also configured <task-retry-limit>5</task-retry-limit> for this
queue but this does not seem to work.

So the setup is working but the DeferredTask / DeferredTaskServlet do
not seem to look into the settings configured in queue.xml

Can somebody confirm this?

On Apr 22, 11:13 am, Marcel Overdijk <[email protected]> wrote:
> Maybe use additional mappings to
> com.google.apphosting.utils.servlet.DeferredTaskServlet
> The documentation on Deferred Tasks is a little bit sparse... Any
> pointers appreciated.
>
> Basically what I would like to do is have multiple queue defined with
> different throttling settings.
> And use DeferredTask to send them to one of the queues depending on
> the my needs.
>
> I would have no problem with configuring additional servlet mappings
> using com.google.apphosting.utils.servlet.DeferredTaskServlet
>
> On Apr 22, 8:58 am, Marcel Overdijk <[email protected]> wrote:
>
> > Is it possible to use Deferred Tasks outside the default queue?
>
> > I would like to setup multiple queues with different config settings.
>
> > For the Deferred Tasks a specific handler is setup at /_ah/queue/
> > __deferred__ so I wonder how that would work with multiple queues....

-- 
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 [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/google-appengine-java?hl=en.

Reply via email to