Thank you for sharing your error and discovery here with us. As you've 
mentioned, the maximum number of tasks one can lease is 1000, as supported 
by this Go article about Leasing tasks with Pull Queues 
<https://cloud.google.com/appengine/docs/go/taskqueue/overview-pull#Go_Leasing_tasks>.
 
This is also the case for all other available runtimes. On a side note 
related to your earlier tests, the taskqueue.go source code 
<https://code.google.com/p/appengine-go/source/browse/appengine/taskqueue/taskqueue.go>
 
on line 355 reveals that supplying the *queueName* parameter with an empty 
string will be substituted with the value *"default":*

func lease(c appengine.Context, maxTasks int, queueName string, leaseTime 
> int, groupByTag bool, tag []byte) ([]*Task, error) {
>   if queueName == "" {
>     queueName = "default"
>   }
>   // ...
> }


If other issues arise with this same error message, feel free to contribute 
more tests, results and logs here.

Cheers,

On Tuesday, January 12, 2016 at 3:38:26 PM UTC-5, Andrew Haskell wrote:
>
> Nvm in my real code I was leasing 2000 tasks but the max I can lease is 
> actually 1000.
>
> On Tuesday, January 12, 2016 at 12:49:52 PM UTC-5, Andrew Haskell wrote:
>>
>> I'm using a pull queue in Appengine for Go and while locally leasing 
>> tasks worked just fine, when I deployed my code, the call to 
>> taskqueue.Lease gave me this error:
>>
>> API error 13 (taskqueue: INVALID_REQUEST) *internal.APIError
>>
>> My lease call was:
>>
>> tasks, err := taskqueue.Lease(ctx, 100, "pullqueue", 60)
>>
>> And it has happened no matter what parameters I pass in, like parameters 
>> for a blank queue name. Has anyone else gotten this error? Thanks in 
>> advance for the help!
>>
>

-- 
You received this message because you are subscribed to the Google Groups 
"Google App Engine" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at https://groups.google.com/group/google-appengine.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/google-appengine/6c35292a-0d9d-4ce6-bda1-feaa2dc9c99a%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to