tasks.TaskQueueBuilder class
Stay organized with collections
Save and categorize content based on your preferences.
Builder for creating a TaskQueueFunction
.
Signature:
export declare class TaskQueueBuilder
Methods
Method |
Modifiers |
Description |
onDispatch(handler) |
|
Creates a handler for tasks sent to a Google Cloud Tasks queue. |
tasks.TaskQueueBuilder.onDispatch()
Creates a handler for tasks sent to a Google Cloud Tasks queue.
Signature:
onDispatch(handler: (data: any, context: TaskContext) => void | Promise<void>): TaskQueueFunction;
Parameters
Parameter |
Type |
Description |
handler |
(data: any, context: TaskContext) => void | Promise<void> |
A callback to handle task requests. |
Returns:
TaskQueueFunction
A function you can export and deploy.
Except as otherwise noted, the content of this page is licensed under the Creative Commons Attribution 4.0 License, and code samples are licensed under the Apache 2.0 License. For details, see the Google Developers Site Policies. Java is a registered trademark of Oracle and/or its affiliates.
Last updated 2023-04-24 UTC.
[null,null,["Last updated 2023-04-24 UTC."],[],[],null,["Builder for creating a `TaskQueueFunction`.\n\n**Signature:** \n\n export declare class TaskQueueBuilder \n\nMethods\n\ntasks.TaskQueueBuilder.onDispatch()\n\nCreates a handler for tasks sent to a Google Cloud Tasks queue.\n\n**Signature:** \n\n onDispatch(handler: (data: any, context: TaskContext) =\u003e void | Promise\u003cvoid\u003e): TaskQueueFunction;\n\nParameters\n\n**Returns:**\n\n[TaskQueueFunction](./firebase-functions.tasks.taskqueuefunction.md#taskstaskqueuefunction_interface)\n\nA function you can export and deploy."]]