Copyright | (c) 2015 Brendan Hay |
---|---|
License | Mozilla Public License, v. 2.0. |
Maintainer | Brendan Hay <brendan.g.hay@gmail.com> |
Stability | auto-generated |
Portability | non-portable (GHC extensions) |
Safe Haskell | None |
Language | Haskell2010 |
Lease 1 or more tasks from a TaskQueue.
See: TaskQueue API Reference for taskqueue.tasks.lease
.
- type TasksLeaseResource = "taskqueue" :> ("v1beta2" :> ("projects" :> (Capture "project" Text :> ("taskqueues" :> (Capture "taskqueue" Text :> ("tasks" :> ("lease" :> (QueryParam "numTasks" (Textual Int32) :> (QueryParam "leaseSecs" (Textual Int32) :> (QueryParam "tag" Text :> (QueryParam "groupByTag" Bool :> (QueryParam "alt" AltJSON :> Post `[JSON]` Tasks))))))))))))
- tasksLease :: Text -> Text -> Int32 -> Int32 -> TasksLease
- data TasksLease
- tlTaskqueue :: Lens' TasksLease Text
- tlTag :: Lens' TasksLease (Maybe Text)
- tlProject :: Lens' TasksLease Text
- tlNumTasks :: Lens' TasksLease Int32
- tlLeaseSecs :: Lens' TasksLease Int32
- tlGroupByTag :: Lens' TasksLease (Maybe Bool)
REST Resource
type TasksLeaseResource = "taskqueue" :> ("v1beta2" :> ("projects" :> (Capture "project" Text :> ("taskqueues" :> (Capture "taskqueue" Text :> ("tasks" :> ("lease" :> (QueryParam "numTasks" (Textual Int32) :> (QueryParam "leaseSecs" (Textual Int32) :> (QueryParam "tag" Text :> (QueryParam "groupByTag" Bool :> (QueryParam "alt" AltJSON :> Post `[JSON]` Tasks)))))))))))) Source
A resource alias for taskqueue.tasks.lease
method which the
TasksLease
request conforms to.
Creating a Request
Creates a value of TasksLease
with the minimum fields required to make a request.
Use one of the following lenses to modify other fields as desired:
data TasksLease Source
Lease 1 or more tasks from a TaskQueue.
See: tasksLease
smart constructor.
Request Lenses
tlTaskqueue :: Lens' TasksLease Text Source
The taskqueue to lease a task from.
tlTag :: Lens' TasksLease (Maybe Text) Source
The tag allowed for tasks in the response. Must only be specified if group_by_tag is true. If group_by_tag is true and tag is not specified the tag will be that of the oldest task by eta, i.e. the first available tag
tlProject :: Lens' TasksLease Text Source
The project under which the queue lies.
tlNumTasks :: Lens' TasksLease Int32 Source
The number of tasks to lease.
tlLeaseSecs :: Lens' TasksLease Int32 Source
The lease in seconds.
tlGroupByTag :: Lens' TasksLease (Maybe Bool) Source
When true, all returned tasks will have the same tag