Socket
Socket
Sign inDemoInstall

@google-cloud/tasks

Package Overview
Dependencies
Maintainers
1
Versions
64
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@google-cloud/tasks - npm Package Compare versions

Comparing version 1.8.0 to 1.9.0

47

build/src/v2/cloud_tasks_client.d.ts

@@ -17,4 +17,9 @@ /// <reference types="node" />

private _terminated;
private _opts;
private _gaxModule;
private _gaxGrpc;
private _protos;
private _defaults;
auth: gax.GoogleAuth;
cloudTasksStub: Promise<{
cloudTasksStub?: Promise<{
[name: string]: Function;

@@ -44,4 +49,2 @@ }>;

* your project ID will be detected automatically.
* @param {function} [options.promise] - Custom promise module to use instead
* of native Promises.
* @param {string} [options.apiEndpoint] - The domain name of the

@@ -52,2 +55,16 @@ * API remote host.

/**
* Initialize the client.
* Performs asynchronous operations (such as authentication) and prepares the client.
* This function will be called automatically when any class method is called for the
* first time, but if you need to initialize it before calling an actual method,
* feel free to call initialize() directly.
*
* You can await on this method if you want to make sure the client is initialized.
*
* @returns {Promise} A promise that resolves to an authenticated service stub.
*/
initialize(): Promise<{
[name: string]: Function;
}>;
/**
* The DNS address for this API service.

@@ -121,3 +138,3 @@ */

* @param {string} request.filter
* `filter` can be used to specify a subset of queues. Any [Queue][google.cloud.tasks.v2.Queue]
* `filter` can be used to specify a subset of queues. Any {@link google.cloud.tasks.v2.Queue|Queue}
* field can be used as a filter and several operators as supported.

@@ -139,3 +156,3 @@ * For example: `<=, <, >=, >, !=, =, :`. The filter syntax is the same as

* even if more queues exist; use the
* [next_page_token][google.cloud.tasks.v2.ListQueuesResponse.next_page_token] in the
* {@link google.cloud.tasks.v2.ListQueuesResponse.next_page_token|next_page_token} in the
* response to determine if more queues exist.

@@ -147,6 +164,6 @@ * @param {string} request.pageToken

* request the next page of results, page_token must be the value of
* [next_page_token][google.cloud.tasks.v2.ListQueuesResponse.next_page_token] returned
* from the previous call to [ListQueues][google.cloud.tasks.v2.CloudTasks.ListQueues]
* {@link google.cloud.tasks.v2.ListQueuesResponse.next_page_token|next_page_token} returned
* from the previous call to {@link google.cloud.tasks.v2.CloudTasks.ListQueues|ListQueues}
* method. It is an error to switch the value of the
* [filter][google.cloud.tasks.v2.ListQueuesRequest.filter] while iterating through pages.
* {@link google.cloud.tasks.v2.ListQueuesRequest.filter|filter} while iterating through pages.
* @param {object} [options]

@@ -179,6 +196,6 @@ * Call options. See {@link https://googleapis.dev/nodejs/google-gax/latest/interfaces/CallOptions.html|CallOptions} for more details.

* @param {google.cloud.tasks.v2.Task.View} request.responseView
* The response_view specifies which subset of the [Task][google.cloud.tasks.v2.Task] will be
* The response_view specifies which subset of the {@link google.cloud.tasks.v2.Task|Task} will be
* returned.
*
* By default response_view is [BASIC][google.cloud.tasks.v2.Task.View.BASIC]; not all
* By default response_view is {@link google.cloud.tasks.v2.Task.View.BASIC|BASIC}; not all
* information is retrieved by default because some data, such as

@@ -189,5 +206,5 @@ * payloads, might be desirable to return only when needed because

*
* Authorization for [FULL][google.cloud.tasks.v2.Task.View.FULL] requires
* Authorization for {@link google.cloud.tasks.v2.Task.View.FULL|FULL} requires
* `cloudtasks.tasks.fullView` [Google IAM](https://cloud.google.com/iam/)
* permission on the [Task][google.cloud.tasks.v2.Task] resource.
* permission on the {@link google.cloud.tasks.v2.Task|Task} resource.
* @param {number} request.pageSize

@@ -197,3 +214,3 @@ * Maximum page size.

* Fewer tasks than requested might be returned, even if more tasks exist; use
* [next_page_token][google.cloud.tasks.v2.ListTasksResponse.next_page_token] in the response to
* {@link google.cloud.tasks.v2.ListTasksResponse.next_page_token|next_page_token} in the response to
* determine if more tasks exist.

@@ -208,4 +225,4 @@ *

* request the next page of results, page_token must be the value of
* [next_page_token][google.cloud.tasks.v2.ListTasksResponse.next_page_token] returned
* from the previous call to [ListTasks][google.cloud.tasks.v2.CloudTasks.ListTasks]
* {@link google.cloud.tasks.v2.ListTasksResponse.next_page_token|next_page_token} returned
* from the previous call to {@link google.cloud.tasks.v2.CloudTasks.ListTasks|ListTasks}
* method.

@@ -212,0 +229,0 @@ *

@@ -53,4 +53,2 @@ "use strict";

* your project ID will be detected automatically.
* @param {function} [options.promise] - Custom promise module to use instead
* of native Promises.
* @param {string} [options.apiEndpoint] - The domain name of the

@@ -83,11 +81,13 @@ * API remote host.

// But if we were explicitly requested to use fallback, let's do it now.
const gaxModule = !isBrowser && opts.fallback ? gax.fallback : gax;
this._gaxModule = !isBrowser && opts.fallback ? gax.fallback : gax;
// Create a `gaxGrpc` object, with any grpc-specific options
// sent to the client.
opts.scopes = this.constructor.scopes;
const gaxGrpc = new gaxModule.GrpcClient(opts);
this._gaxGrpc = new this._gaxModule.GrpcClient(opts);
// Save options to use in initialize() method.
this._opts = opts;
// Save the auth object to the client, for use by other methods.
this.auth = gaxGrpc.auth;
this.auth = this._gaxGrpc.auth;
// Determine the client header string.
const clientHeader = [`gax/${gaxModule.version}`, `gapic/${version}`];
const clientHeader = [`gax/${this._gaxModule.version}`, `gapic/${version}`];
if (typeof process !== 'undefined' && 'versions' in process) {

@@ -97,6 +97,6 @@ clientHeader.push(`gl-node/${process.versions.node}`);

else {
clientHeader.push(`gl-web/${gaxModule.version}`);
clientHeader.push(`gl-web/${this._gaxModule.version}`);
}
if (!opts.fallback) {
clientHeader.push(`grpc/${gaxGrpc.grpcVersion}`);
clientHeader.push(`grpc/${this._gaxGrpc.grpcVersion}`);
}

@@ -110,3 +110,3 @@ if (opts.libName && opts.libVersion) {

const nodejsProtoPath = path.join(__dirname, '..', '..', 'protos', 'protos.json');
const protos = gaxGrpc.loadProto(opts.fallback ? require('../../protos/protos.json') : nodejsProtoPath);
this._protos = this._gaxGrpc.loadProto(opts.fallback ? require('../../protos/protos.json') : nodejsProtoPath);
// This API contains "path templates"; forward-slash-separated

@@ -116,6 +116,6 @@ // identifiers to uniquely identify resources within the API.

this._pathTemplates = {
locationPathTemplate: new gaxModule.PathTemplate('projects/{project}/locations/{location}'),
projectPathTemplate: new gaxModule.PathTemplate('projects/{project}'),
queuePathTemplate: new gaxModule.PathTemplate('projects/{project}/locations/{location}/queues/{queue}'),
taskPathTemplate: new gaxModule.PathTemplate('projects/{project}/locations/{location}/queues/{queue}/tasks/{task}'),
locationPathTemplate: new this._gaxModule.PathTemplate('projects/{project}/locations/{location}'),
projectPathTemplate: new this._gaxModule.PathTemplate('projects/{project}'),
queuePathTemplate: new this._gaxModule.PathTemplate('projects/{project}/locations/{location}/queues/{queue}'),
taskPathTemplate: new this._gaxModule.PathTemplate('projects/{project}/locations/{location}/queues/{queue}/tasks/{task}'),
};

@@ -126,7 +126,7 @@ // Some of the methods on this service return "paged" results,

this._descriptors.page = {
listQueues: new gaxModule.PageDescriptor('pageToken', 'nextPageToken', 'queues'),
listTasks: new gaxModule.PageDescriptor('pageToken', 'nextPageToken', 'tasks'),
listQueues: new this._gaxModule.PageDescriptor('pageToken', 'nextPageToken', 'queues'),
listTasks: new this._gaxModule.PageDescriptor('pageToken', 'nextPageToken', 'tasks'),
};
// Put together the default options sent with requests.
const defaults = gaxGrpc.constructSettings('google.cloud.tasks.v2.CloudTasks', gapicConfig, opts.clientConfig || {}, { 'x-goog-api-client': clientHeader.join(' ') });
this._defaults = this._gaxGrpc.constructSettings('google.cloud.tasks.v2.CloudTasks', gapicConfig, opts.clientConfig || {}, { 'x-goog-api-client': clientHeader.join(' ') });
// Set up a dictionary of "inner API calls"; the core implementation

@@ -136,8 +136,25 @@ // of calling the API is handled in `google-gax`, with this code

this._innerApiCalls = {};
}
/**
* Initialize the client.
* Performs asynchronous operations (such as authentication) and prepares the client.
* This function will be called automatically when any class method is called for the
* first time, but if you need to initialize it before calling an actual method,
* feel free to call initialize() directly.
*
* You can await on this method if you want to make sure the client is initialized.
*
* @returns {Promise} A promise that resolves to an authenticated service stub.
*/
initialize() {
// If the client stub promise is already initialized, return immediately.
if (this.cloudTasksStub) {
return this.cloudTasksStub;
}
// Put together the "service stub" for
// google.cloud.tasks.v2.CloudTasks.
this.cloudTasksStub = gaxGrpc.createStub(opts.fallback
? protos.lookupService('google.cloud.tasks.v2.CloudTasks')
this.cloudTasksStub = this._gaxGrpc.createStub(this._opts.fallback
? this._protos.lookupService('google.cloud.tasks.v2.CloudTasks')
: // tslint:disable-next-line no-any
protos.google.cloud.tasks.v2.CloudTasks, opts);
this._protos.google.cloud.tasks.v2.CloudTasks, this._opts);
// Iterate over each of the methods that the service provides

@@ -172,3 +189,3 @@ // and create an API call method for each.

});
const apiCall = gaxModule.createApiCall(innerCallPromise, defaults[methodName], this._descriptors.page[methodName] ||
const apiCall = this._gaxModule.createApiCall(innerCallPromise, this._defaults[methodName], this._descriptors.page[methodName] ||
this._descriptors.stream[methodName] ||

@@ -180,2 +197,3 @@ this._descriptors.longrunning[methodName]);

}
return this.cloudTasksStub;
}

@@ -250,2 +268,3 @@ /**

});
this.initialize();
return this._innerApiCalls.getQueue(request, options, callback);

@@ -275,7 +294,7 @@ }

* Tasks' implementation of
* [ListLocations][google.cloud.location.Locations.ListLocations].
* {@link google.cloud.location.Locations.ListLocations|ListLocations}.
* @param {google.cloud.tasks.v2.Queue} request.queue
* Required. The queue to create.
*
* [Queue's name][google.cloud.tasks.v2.Queue.name] cannot be the same as an existing queue.
* {@link google.cloud.tasks.v2.Queue.name|Queue's name} cannot be the same as an existing queue.
* @param {object} [options]

@@ -303,2 +322,3 @@ * Call options. See {@link https://googleapis.dev/nodejs/google-gax/latest/interfaces/CallOptions.html|CallOptions} for more details.

});
this.initialize();
return this._innerApiCalls.createQueue(request, options, callback);

@@ -328,7 +348,7 @@ }

*
* The queue's [name][google.cloud.tasks.v2.Queue.name] must be specified.
* The queue's {@link google.cloud.tasks.v2.Queue.name|name} must be specified.
*
* Output only fields cannot be modified using UpdateQueue.
* Any value specified for an output only field will be ignored.
* The queue's [name][google.cloud.tasks.v2.Queue.name] cannot be changed.
* The queue's {@link google.cloud.tasks.v2.Queue.name|name} cannot be changed.
* @param {google.protobuf.FieldMask} request.updateMask

@@ -360,2 +380,3 @@ * A mask used to specify which fields of the queue are being updated.

});
this.initialize();
return this._innerApiCalls.updateQueue(request, options, callback);

@@ -405,2 +426,3 @@ }

});
this.initialize();
return this._innerApiCalls.deleteQueue(request, options, callback);

@@ -443,2 +465,3 @@ }

});
this.initialize();
return this._innerApiCalls.purgeQueue(request, options, callback);

@@ -451,5 +474,5 @@ }

* until the queue is resumed via
* [ResumeQueue][google.cloud.tasks.v2.CloudTasks.ResumeQueue]. Tasks can still be added
* {@link google.cloud.tasks.v2.CloudTasks.ResumeQueue|ResumeQueue}. Tasks can still be added
* when the queue is paused. A queue is paused if its
* [state][google.cloud.tasks.v2.Queue.state] is [PAUSED][google.cloud.tasks.v2.Queue.State.PAUSED].
* {@link google.cloud.tasks.v2.Queue.state|state} is {@link google.cloud.tasks.v2.Queue.State.PAUSED|PAUSED}.
*

@@ -483,2 +506,3 @@ * @param {Object} request

});
this.initialize();
return this._innerApiCalls.pauseQueue(request, options, callback);

@@ -490,6 +514,6 @@ }

* This method resumes a queue after it has been
* [PAUSED][google.cloud.tasks.v2.Queue.State.PAUSED] or
* [DISABLED][google.cloud.tasks.v2.Queue.State.DISABLED]. The state of a queue is stored
* in the queue's [state][google.cloud.tasks.v2.Queue.state]; after calling this method it
* will be set to [RUNNING][google.cloud.tasks.v2.Queue.State.RUNNING].
* {@link google.cloud.tasks.v2.Queue.State.PAUSED|PAUSED} or
* {@link google.cloud.tasks.v2.Queue.State.DISABLED|DISABLED}. The state of a queue is stored
* in the queue's {@link google.cloud.tasks.v2.Queue.state|state}; after calling this method it
* will be set to {@link google.cloud.tasks.v2.Queue.State.RUNNING|RUNNING}.
*

@@ -529,6 +553,7 @@ * WARNING: Resuming many high-QPS queues at the same time can

});
this.initialize();
return this._innerApiCalls.resumeQueue(request, options, callback);
}
/**
* Gets the access control policy for a [Queue][google.cloud.tasks.v2.Queue].
* Gets the access control policy for a {@link google.cloud.tasks.v2.Queue|Queue}.
* Returns an empty policy if the resource exists and does not have a policy

@@ -567,6 +592,7 @@ * set.

});
this.initialize();
return this._innerApiCalls.getIamPolicy(request, options, callback);
}
/**
* Sets the access control policy for a [Queue][google.cloud.tasks.v2.Queue]. Replaces any existing
* Sets the access control policy for a {@link google.cloud.tasks.v2.Queue|Queue}. Replaces any existing
* policy.

@@ -607,8 +633,9 @@ *

});
this.initialize();
return this._innerApiCalls.setIamPolicy(request, options, callback);
}
/**
* Returns permissions that a caller has on a [Queue][google.cloud.tasks.v2.Queue].
* Returns permissions that a caller has on a {@link google.cloud.tasks.v2.Queue|Queue}.
* If the resource does not exist, this will return an empty set of
* permissions, not a [NOT_FOUND][google.rpc.Code.NOT_FOUND] error.
* permissions, not a {@link google.rpc.Code.NOT_FOUND|NOT_FOUND} error.
*

@@ -643,2 +670,3 @@ * Note: This operation is designed to be used for building permission-aware

});
this.initialize();
return this._innerApiCalls.testIamPermissions(request, options, callback);

@@ -655,6 +683,6 @@ }

* @param {google.cloud.tasks.v2.Task.View} request.responseView
* The response_view specifies which subset of the [Task][google.cloud.tasks.v2.Task] will be
* The response_view specifies which subset of the {@link google.cloud.tasks.v2.Task|Task} will be
* returned.
*
* By default response_view is [BASIC][google.cloud.tasks.v2.Task.View.BASIC]; not all
* By default response_view is {@link google.cloud.tasks.v2.Task.View.BASIC|BASIC}; not all
* information is retrieved by default because some data, such as

@@ -665,5 +693,5 @@ * payloads, might be desirable to return only when needed because

*
* Authorization for [FULL][google.cloud.tasks.v2.Task.View.FULL] requires
* Authorization for {@link google.cloud.tasks.v2.Task.View.FULL|FULL} requires
* `cloudtasks.tasks.fullView` [Google IAM](https://cloud.google.com/iam/)
* permission on the [Task][google.cloud.tasks.v2.Task] resource.
* permission on the {@link google.cloud.tasks.v2.Task|Task} resource.
* @param {object} [options]

@@ -691,2 +719,3 @@ * Call options. See {@link https://googleapis.dev/nodejs/google-gax/latest/interfaces/CallOptions.html|CallOptions} for more details.

});
this.initialize();
return this._innerApiCalls.getTask(request, options, callback);

@@ -713,8 +742,8 @@ }

* `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID/tasks/TASK_ID`.
* The user can optionally specify a task [name][google.cloud.tasks.v2.Task.name]. If a
* The user can optionally specify a task {@link google.cloud.tasks.v2.Task.name|name}. If a
* name is not specified then the system will generate a random
* unique task id, which will be set in the task returned in the
* [response][google.cloud.tasks.v2.Task.name].
* {@link google.cloud.tasks.v2.Task.name|response}.
*
* If [schedule_time][google.cloud.tasks.v2.Task.schedule_time] is not set or is in the
* If {@link google.cloud.tasks.v2.Task.schedule_time|schedule_time} is not set or is in the
* past then Cloud Tasks will set it to the current time.

@@ -727,3 +756,3 @@ *

* that was deleted or executed recently then the call will fail
* with [ALREADY_EXISTS][google.rpc.Code.ALREADY_EXISTS].
* with {@link google.rpc.Code.ALREADY_EXISTS|ALREADY_EXISTS}.
* If the task's queue was created using Cloud Tasks, then another task with

@@ -736,3 +765,3 @@ * the same name can't be created for ~1hour after the original task was

* Because there is an extra lookup cost to identify duplicate task
* names, these [CreateTask][google.cloud.tasks.v2.CloudTasks.CreateTask] calls have significantly
* names, these {@link google.cloud.tasks.v2.CloudTasks.CreateTask|CreateTask} calls have significantly
* increased latency. Using hashed strings for the task id or for

@@ -746,6 +775,6 @@ * the prefix of the task id is recommended. Choosing task ids that

* @param {google.cloud.tasks.v2.Task.View} request.responseView
* The response_view specifies which subset of the [Task][google.cloud.tasks.v2.Task] will be
* The response_view specifies which subset of the {@link google.cloud.tasks.v2.Task|Task} will be
* returned.
*
* By default response_view is [BASIC][google.cloud.tasks.v2.Task.View.BASIC]; not all
* By default response_view is {@link google.cloud.tasks.v2.Task.View.BASIC|BASIC}; not all
* information is retrieved by default because some data, such as

@@ -756,5 +785,5 @@ * payloads, might be desirable to return only when needed because

*
* Authorization for [FULL][google.cloud.tasks.v2.Task.View.FULL] requires
* Authorization for {@link google.cloud.tasks.v2.Task.View.FULL|FULL} requires
* `cloudtasks.tasks.fullView` [Google IAM](https://cloud.google.com/iam/)
* permission on the [Task][google.cloud.tasks.v2.Task] resource.
* permission on the {@link google.cloud.tasks.v2.Task|Task} resource.
* @param {object} [options]

@@ -782,2 +811,3 @@ * Call options. See {@link https://googleapis.dev/nodejs/google-gax/latest/interfaces/CallOptions.html|CallOptions} for more details.

});
this.initialize();
return this._innerApiCalls.createTask(request, options, callback);

@@ -819,2 +849,3 @@ }

});
this.initialize();
return this._innerApiCalls.deleteTask(request, options, callback);

@@ -826,7 +857,7 @@ }

* When this method is called, Cloud Tasks will dispatch the task, even if
* the task is already running, the queue has reached its [RateLimits][google.cloud.tasks.v2.RateLimits] or
* is [PAUSED][google.cloud.tasks.v2.Queue.State.PAUSED].
* the task is already running, the queue has reached its {@link google.cloud.tasks.v2.RateLimits|RateLimits} or
* is {@link google.cloud.tasks.v2.Queue.State.PAUSED|PAUSED}.
*
* This command is meant to be used for manual debugging. For
* example, [RunTask][google.cloud.tasks.v2.CloudTasks.RunTask] can be used to retry a failed
* example, {@link google.cloud.tasks.v2.CloudTasks.RunTask|RunTask} can be used to retry a failed
* task after a fix has been made or to manually force a task to be

@@ -836,3 +867,3 @@ * dispatched now.

* The dispatched task is returned. That is, the task that is returned
* contains the [status][Task.status] after the task is dispatched but
* contains the {@link Task.status|status} after the task is dispatched but
* before the task is received by its target.

@@ -842,8 +873,8 @@ *

* target, then the task will be deleted; otherwise the task's
* [schedule_time][google.cloud.tasks.v2.Task.schedule_time] will be reset to the time that
* [RunTask][google.cloud.tasks.v2.CloudTasks.RunTask] was called plus the retry delay specified
* in the queue's [RetryConfig][google.cloud.tasks.v2.RetryConfig].
* {@link google.cloud.tasks.v2.Task.schedule_time|schedule_time} will be reset to the time that
* {@link google.cloud.tasks.v2.CloudTasks.RunTask|RunTask} was called plus the retry delay specified
* in the queue's {@link google.cloud.tasks.v2.RetryConfig|RetryConfig}.
*
* [RunTask][google.cloud.tasks.v2.CloudTasks.RunTask] returns
* [NOT_FOUND][google.rpc.Code.NOT_FOUND] when it is called on a
* {@link google.cloud.tasks.v2.CloudTasks.RunTask|RunTask} returns
* {@link google.rpc.Code.NOT_FOUND|NOT_FOUND} when it is called on a
* task that has already succeeded or permanently failed.

@@ -857,6 +888,6 @@ *

* @param {google.cloud.tasks.v2.Task.View} request.responseView
* The response_view specifies which subset of the [Task][google.cloud.tasks.v2.Task] will be
* The response_view specifies which subset of the {@link google.cloud.tasks.v2.Task|Task} will be
* returned.
*
* By default response_view is [BASIC][google.cloud.tasks.v2.Task.View.BASIC]; not all
* By default response_view is {@link google.cloud.tasks.v2.Task.View.BASIC|BASIC}; not all
* information is retrieved by default because some data, such as

@@ -867,5 +898,5 @@ * payloads, might be desirable to return only when needed because

*
* Authorization for [FULL][google.cloud.tasks.v2.Task.View.FULL] requires
* Authorization for {@link google.cloud.tasks.v2.Task.View.FULL|FULL} requires
* `cloudtasks.tasks.fullView` [Google IAM](https://cloud.google.com/iam/)
* permission on the [Task][google.cloud.tasks.v2.Task] resource.
* permission on the {@link google.cloud.tasks.v2.Task|Task} resource.
* @param {object} [options]

@@ -893,2 +924,3 @@ * Call options. See {@link https://googleapis.dev/nodejs/google-gax/latest/interfaces/CallOptions.html|CallOptions} for more details.

});
this.initialize();
return this._innerApiCalls.runTask(request, options, callback);

@@ -907,3 +939,3 @@ }

* @param {string} request.filter
* `filter` can be used to specify a subset of queues. Any [Queue][google.cloud.tasks.v2.Queue]
* `filter` can be used to specify a subset of queues. Any {@link google.cloud.tasks.v2.Queue|Queue}
* field can be used as a filter and several operators as supported.

@@ -925,3 +957,3 @@ * For example: `<=, <, >=, >, !=, =, :`. The filter syntax is the same as

* even if more queues exist; use the
* [next_page_token][google.cloud.tasks.v2.ListQueuesResponse.next_page_token] in the
* {@link google.cloud.tasks.v2.ListQueuesResponse.next_page_token|next_page_token} in the
* response to determine if more queues exist.

@@ -933,6 +965,6 @@ * @param {string} request.pageToken

* request the next page of results, page_token must be the value of
* [next_page_token][google.cloud.tasks.v2.ListQueuesResponse.next_page_token] returned
* from the previous call to [ListQueues][google.cloud.tasks.v2.CloudTasks.ListQueues]
* {@link google.cloud.tasks.v2.ListQueuesResponse.next_page_token|next_page_token} returned
* from the previous call to {@link google.cloud.tasks.v2.CloudTasks.ListQueues|ListQueues}
* method. It is an error to switch the value of the
* [filter][google.cloud.tasks.v2.ListQueuesRequest.filter] while iterating through pages.
* {@link google.cloud.tasks.v2.ListQueuesRequest.filter|filter} while iterating through pages.
* @param {object} [options]

@@ -972,2 +1004,3 @@ * Call options. See {@link https://googleapis.dev/nodejs/google-gax/latest/interfaces/CallOptions.html|CallOptions} for more details.

});
this.initialize();
return this._innerApiCalls.listQueues(request, options, callback);

@@ -994,3 +1027,3 @@ }

* @param {string} request.filter
* `filter` can be used to specify a subset of queues. Any [Queue][google.cloud.tasks.v2.Queue]
* `filter` can be used to specify a subset of queues. Any {@link google.cloud.tasks.v2.Queue|Queue}
* field can be used as a filter and several operators as supported.

@@ -1012,3 +1045,3 @@ * For example: `<=, <, >=, >, !=, =, :`. The filter syntax is the same as

* even if more queues exist; use the
* [next_page_token][google.cloud.tasks.v2.ListQueuesResponse.next_page_token] in the
* {@link google.cloud.tasks.v2.ListQueuesResponse.next_page_token|next_page_token} in the
* response to determine if more queues exist.

@@ -1020,6 +1053,6 @@ * @param {string} request.pageToken

* request the next page of results, page_token must be the value of
* [next_page_token][google.cloud.tasks.v2.ListQueuesResponse.next_page_token] returned
* from the previous call to [ListQueues][google.cloud.tasks.v2.CloudTasks.ListQueues]
* {@link google.cloud.tasks.v2.ListQueuesResponse.next_page_token|next_page_token} returned
* from the previous call to {@link google.cloud.tasks.v2.CloudTasks.ListQueues|ListQueues}
* method. It is an error to switch the value of the
* [filter][google.cloud.tasks.v2.ListQueuesRequest.filter] while iterating through pages.
* {@link google.cloud.tasks.v2.ListQueuesRequest.filter|filter} while iterating through pages.
* @param {object} [options]

@@ -1039,2 +1072,3 @@ * Call options. See {@link https://googleapis.dev/nodejs/google-gax/latest/interfaces/CallOptions.html|CallOptions} for more details.

const callSettings = new gax.CallSettings(options);
this.initialize();
return this._descriptors.page.listQueues.createStream(this._innerApiCalls.listQueues, request, callSettings);

@@ -1045,5 +1079,5 @@ }

*
* By default, only the [BASIC][google.cloud.tasks.v2.Task.View.BASIC] view is retrieved
* By default, only the {@link google.cloud.tasks.v2.Task.View.BASIC|BASIC} view is retrieved
* due to performance considerations;
* [response_view][google.cloud.tasks.v2.ListTasksRequest.response_view] controls the
* {@link google.cloud.tasks.v2.ListTasksRequest.response_view|response_view} controls the
* subset of information which is returned.

@@ -1060,6 +1094,6 @@ *

* @param {google.cloud.tasks.v2.Task.View} request.responseView
* The response_view specifies which subset of the [Task][google.cloud.tasks.v2.Task] will be
* The response_view specifies which subset of the {@link google.cloud.tasks.v2.Task|Task} will be
* returned.
*
* By default response_view is [BASIC][google.cloud.tasks.v2.Task.View.BASIC]; not all
* By default response_view is {@link google.cloud.tasks.v2.Task.View.BASIC|BASIC}; not all
* information is retrieved by default because some data, such as

@@ -1070,5 +1104,5 @@ * payloads, might be desirable to return only when needed because

*
* Authorization for [FULL][google.cloud.tasks.v2.Task.View.FULL] requires
* Authorization for {@link google.cloud.tasks.v2.Task.View.FULL|FULL} requires
* `cloudtasks.tasks.fullView` [Google IAM](https://cloud.google.com/iam/)
* permission on the [Task][google.cloud.tasks.v2.Task] resource.
* permission on the {@link google.cloud.tasks.v2.Task|Task} resource.
* @param {number} request.pageSize

@@ -1078,3 +1112,3 @@ * Maximum page size.

* Fewer tasks than requested might be returned, even if more tasks exist; use
* [next_page_token][google.cloud.tasks.v2.ListTasksResponse.next_page_token] in the response to
* {@link google.cloud.tasks.v2.ListTasksResponse.next_page_token|next_page_token} in the response to
* determine if more tasks exist.

@@ -1089,4 +1123,4 @@ *

* request the next page of results, page_token must be the value of
* [next_page_token][google.cloud.tasks.v2.ListTasksResponse.next_page_token] returned
* from the previous call to [ListTasks][google.cloud.tasks.v2.CloudTasks.ListTasks]
* {@link google.cloud.tasks.v2.ListTasksResponse.next_page_token|next_page_token} returned
* from the previous call to {@link google.cloud.tasks.v2.CloudTasks.ListTasks|ListTasks}
* method.

@@ -1129,2 +1163,3 @@ *

});
this.initialize();
return this._innerApiCalls.listTasks(request, options, callback);

@@ -1151,6 +1186,6 @@ }

* @param {google.cloud.tasks.v2.Task.View} request.responseView
* The response_view specifies which subset of the [Task][google.cloud.tasks.v2.Task] will be
* The response_view specifies which subset of the {@link google.cloud.tasks.v2.Task|Task} will be
* returned.
*
* By default response_view is [BASIC][google.cloud.tasks.v2.Task.View.BASIC]; not all
* By default response_view is {@link google.cloud.tasks.v2.Task.View.BASIC|BASIC}; not all
* information is retrieved by default because some data, such as

@@ -1161,5 +1196,5 @@ * payloads, might be desirable to return only when needed because

*
* Authorization for [FULL][google.cloud.tasks.v2.Task.View.FULL] requires
* Authorization for {@link google.cloud.tasks.v2.Task.View.FULL|FULL} requires
* `cloudtasks.tasks.fullView` [Google IAM](https://cloud.google.com/iam/)
* permission on the [Task][google.cloud.tasks.v2.Task] resource.
* permission on the {@link google.cloud.tasks.v2.Task|Task} resource.
* @param {number} request.pageSize

@@ -1169,3 +1204,3 @@ * Maximum page size.

* Fewer tasks than requested might be returned, even if more tasks exist; use
* [next_page_token][google.cloud.tasks.v2.ListTasksResponse.next_page_token] in the response to
* {@link google.cloud.tasks.v2.ListTasksResponse.next_page_token|next_page_token} in the response to
* determine if more tasks exist.

@@ -1180,4 +1215,4 @@ *

* request the next page of results, page_token must be the value of
* [next_page_token][google.cloud.tasks.v2.ListTasksResponse.next_page_token] returned
* from the previous call to [ListTasks][google.cloud.tasks.v2.CloudTasks.ListTasks]
* {@link google.cloud.tasks.v2.ListTasksResponse.next_page_token|next_page_token} returned
* from the previous call to {@link google.cloud.tasks.v2.CloudTasks.ListTasks|ListTasks}
* method.

@@ -1200,2 +1235,3 @@ *

const callSettings = new gax.CallSettings(options);
this.initialize();
return this._descriptors.page.listTasks.createStream(this._innerApiCalls.listTasks, request, callSettings);

@@ -1369,2 +1405,3 @@ }

close() {
this.initialize();
if (!this._terminated) {

@@ -1371,0 +1408,0 @@ return this.cloudTasksStub.then(stub => {

@@ -17,4 +17,9 @@ /// <reference types="node" />

private _terminated;
private _opts;
private _gaxModule;
private _gaxGrpc;
private _protos;
private _defaults;
auth: gax.GoogleAuth;
cloudTasksStub: Promise<{
cloudTasksStub?: Promise<{
[name: string]: Function;

@@ -44,4 +49,2 @@ }>;

* your project ID will be detected automatically.
* @param {function} [options.promise] - Custom promise module to use instead
* of native Promises.
* @param {string} [options.apiEndpoint] - The domain name of the

@@ -52,2 +55,16 @@ * API remote host.

/**
* Initialize the client.
* Performs asynchronous operations (such as authentication) and prepares the client.
* This function will be called automatically when any class method is called for the
* first time, but if you need to initialize it before calling an actual method,
* feel free to call initialize() directly.
*
* You can await on this method if you want to make sure the client is initialized.
*
* @returns {Promise} A promise that resolves to an authenticated service stub.
*/
initialize(): Promise<{
[name: string]: Function;
}>;
/**
* The DNS address for this API service.

@@ -129,3 +146,3 @@ */

* @param {string} request.filter
* `filter` can be used to specify a subset of queues. Any [Queue][google.cloud.tasks.v2beta2.Queue]
* `filter` can be used to specify a subset of queues. Any {@link google.cloud.tasks.v2beta2.Queue|Queue}
* field can be used as a filter and several operators as supported.

@@ -147,3 +164,3 @@ * For example: `<=, <, >=, >, !=, =, :`. The filter syntax is the same as

* even if more queues exist; use the
* [next_page_token][google.cloud.tasks.v2beta2.ListQueuesResponse.next_page_token] in the
* {@link google.cloud.tasks.v2beta2.ListQueuesResponse.next_page_token|next_page_token} in the
* response to determine if more queues exist.

@@ -155,6 +172,6 @@ * @param {string} request.pageToken

* request the next page of results, page_token must be the value of
* [next_page_token][google.cloud.tasks.v2beta2.ListQueuesResponse.next_page_token] returned
* from the previous call to [ListQueues][google.cloud.tasks.v2beta2.CloudTasks.ListQueues]
* {@link google.cloud.tasks.v2beta2.ListQueuesResponse.next_page_token|next_page_token} returned
* from the previous call to {@link google.cloud.tasks.v2beta2.CloudTasks.ListQueues|ListQueues}
* method. It is an error to switch the value of the
* [filter][google.cloud.tasks.v2beta2.ListQueuesRequest.filter] while iterating through pages.
* {@link google.cloud.tasks.v2beta2.ListQueuesRequest.filter|filter} while iterating through pages.
* @param {object} [options]

@@ -187,6 +204,6 @@ * Call options. See {@link https://googleapis.dev/nodejs/google-gax/latest/interfaces/CallOptions.html|CallOptions} for more details.

* @param {google.cloud.tasks.v2beta2.Task.View} request.responseView
* The response_view specifies which subset of the [Task][google.cloud.tasks.v2beta2.Task] will be
* The response_view specifies which subset of the {@link google.cloud.tasks.v2beta2.Task|Task} will be
* returned.
*
* By default response_view is [BASIC][google.cloud.tasks.v2beta2.Task.View.BASIC]; not all
* By default response_view is {@link google.cloud.tasks.v2beta2.Task.View.BASIC|BASIC}; not all
* information is retrieved by default because some data, such as

@@ -197,5 +214,5 @@ * payloads, might be desirable to return only when needed because

*
* Authorization for [FULL][google.cloud.tasks.v2beta2.Task.View.FULL] requires
* Authorization for {@link google.cloud.tasks.v2beta2.Task.View.FULL|FULL} requires
* `cloudtasks.tasks.fullView` [Google IAM](https://cloud.google.com/iam/)
* permission on the [Task][google.cloud.tasks.v2beta2.Task] resource.
* permission on the {@link google.cloud.tasks.v2beta2.Task|Task} resource.
* @param {number} request.pageSize

@@ -205,3 +222,3 @@ * Maximum page size.

* Fewer tasks than requested might be returned, even if more tasks exist; use
* [next_page_token][google.cloud.tasks.v2beta2.ListTasksResponse.next_page_token] in the response to
* {@link google.cloud.tasks.v2beta2.ListTasksResponse.next_page_token|next_page_token} in the response to
* determine if more tasks exist.

@@ -216,4 +233,4 @@ *

* request the next page of results, page_token must be the value of
* [next_page_token][google.cloud.tasks.v2beta2.ListTasksResponse.next_page_token] returned
* from the previous call to [ListTasks][google.cloud.tasks.v2beta2.CloudTasks.ListTasks]
* {@link google.cloud.tasks.v2beta2.ListTasksResponse.next_page_token|next_page_token} returned
* from the previous call to {@link google.cloud.tasks.v2beta2.CloudTasks.ListTasks|ListTasks}
* method.

@@ -220,0 +237,0 @@ *

@@ -17,4 +17,9 @@ /// <reference types="node" />

private _terminated;
private _opts;
private _gaxModule;
private _gaxGrpc;
private _protos;
private _defaults;
auth: gax.GoogleAuth;
cloudTasksStub: Promise<{
cloudTasksStub?: Promise<{
[name: string]: Function;

@@ -44,4 +49,2 @@ }>;

* your project ID will be detected automatically.
* @param {function} [options.promise] - Custom promise module to use instead
* of native Promises.
* @param {string} [options.apiEndpoint] - The domain name of the

@@ -52,2 +55,16 @@ * API remote host.

/**
* Initialize the client.
* Performs asynchronous operations (such as authentication) and prepares the client.
* This function will be called automatically when any class method is called for the
* first time, but if you need to initialize it before calling an actual method,
* feel free to call initialize() directly.
*
* You can await on this method if you want to make sure the client is initialized.
*
* @returns {Promise} A promise that resolves to an authenticated service stub.
*/
initialize(): Promise<{
[name: string]: Function;
}>;
/**
* The DNS address for this API service.

@@ -121,3 +138,3 @@ */

* @param {string} request.filter
* `filter` can be used to specify a subset of queues. Any [Queue][google.cloud.tasks.v2beta3.Queue]
* `filter` can be used to specify a subset of queues. Any {@link google.cloud.tasks.v2beta3.Queue|Queue}
* field can be used as a filter and several operators as supported.

@@ -139,3 +156,3 @@ * For example: `<=, <, >=, >, !=, =, :`. The filter syntax is the same as

* even if more queues exist; use the
* [next_page_token][google.cloud.tasks.v2beta3.ListQueuesResponse.next_page_token] in the
* {@link google.cloud.tasks.v2beta3.ListQueuesResponse.next_page_token|next_page_token} in the
* response to determine if more queues exist.

@@ -147,6 +164,6 @@ * @param {string} request.pageToken

* request the next page of results, page_token must be the value of
* [next_page_token][google.cloud.tasks.v2beta3.ListQueuesResponse.next_page_token] returned
* from the previous call to [ListQueues][google.cloud.tasks.v2beta3.CloudTasks.ListQueues]
* {@link google.cloud.tasks.v2beta3.ListQueuesResponse.next_page_token|next_page_token} returned
* from the previous call to {@link google.cloud.tasks.v2beta3.CloudTasks.ListQueues|ListQueues}
* method. It is an error to switch the value of the
* [filter][google.cloud.tasks.v2beta3.ListQueuesRequest.filter] while iterating through pages.
* {@link google.cloud.tasks.v2beta3.ListQueuesRequest.filter|filter} while iterating through pages.
* @param {object} [options]

@@ -179,6 +196,6 @@ * Call options. See {@link https://googleapis.dev/nodejs/google-gax/latest/interfaces/CallOptions.html|CallOptions} for more details.

* @param {google.cloud.tasks.v2beta3.Task.View} request.responseView
* The response_view specifies which subset of the [Task][google.cloud.tasks.v2beta3.Task] will be
* The response_view specifies which subset of the {@link google.cloud.tasks.v2beta3.Task|Task} will be
* returned.
*
* By default response_view is [BASIC][google.cloud.tasks.v2beta3.Task.View.BASIC]; not all
* By default response_view is {@link google.cloud.tasks.v2beta3.Task.View.BASIC|BASIC}; not all
* information is retrieved by default because some data, such as

@@ -189,5 +206,5 @@ * payloads, might be desirable to return only when needed because

*
* Authorization for [FULL][google.cloud.tasks.v2beta3.Task.View.FULL] requires
* Authorization for {@link google.cloud.tasks.v2beta3.Task.View.FULL|FULL} requires
* `cloudtasks.tasks.fullView` [Google IAM](https://cloud.google.com/iam/)
* permission on the [Task][google.cloud.tasks.v2beta3.Task] resource.
* permission on the {@link google.cloud.tasks.v2beta3.Task|Task} resource.
* @param {number} request.pageSize

@@ -197,3 +214,3 @@ * Maximum page size.

* Fewer tasks than requested might be returned, even if more tasks exist; use
* [next_page_token][google.cloud.tasks.v2beta3.ListTasksResponse.next_page_token] in the response to
* {@link google.cloud.tasks.v2beta3.ListTasksResponse.next_page_token|next_page_token} in the response to
* determine if more tasks exist.

@@ -208,4 +225,4 @@ *

* request the next page of results, page_token must be the value of
* [next_page_token][google.cloud.tasks.v2beta3.ListTasksResponse.next_page_token] returned
* from the previous call to [ListTasks][google.cloud.tasks.v2beta3.CloudTasks.ListTasks]
* {@link google.cloud.tasks.v2beta3.ListTasksResponse.next_page_token|next_page_token} returned
* from the previous call to {@link google.cloud.tasks.v2beta3.CloudTasks.ListTasks|ListTasks}
* method.

@@ -212,0 +229,0 @@ *

@@ -53,4 +53,2 @@ "use strict";

* your project ID will be detected automatically.
* @param {function} [options.promise] - Custom promise module to use instead
* of native Promises.
* @param {string} [options.apiEndpoint] - The domain name of the

@@ -83,11 +81,13 @@ * API remote host.

// But if we were explicitly requested to use fallback, let's do it now.
const gaxModule = !isBrowser && opts.fallback ? gax.fallback : gax;
this._gaxModule = !isBrowser && opts.fallback ? gax.fallback : gax;
// Create a `gaxGrpc` object, with any grpc-specific options
// sent to the client.
opts.scopes = this.constructor.scopes;
const gaxGrpc = new gaxModule.GrpcClient(opts);
this._gaxGrpc = new this._gaxModule.GrpcClient(opts);
// Save options to use in initialize() method.
this._opts = opts;
// Save the auth object to the client, for use by other methods.
this.auth = gaxGrpc.auth;
this.auth = this._gaxGrpc.auth;
// Determine the client header string.
const clientHeader = [`gax/${gaxModule.version}`, `gapic/${version}`];
const clientHeader = [`gax/${this._gaxModule.version}`, `gapic/${version}`];
if (typeof process !== 'undefined' && 'versions' in process) {

@@ -97,6 +97,6 @@ clientHeader.push(`gl-node/${process.versions.node}`);

else {
clientHeader.push(`gl-web/${gaxModule.version}`);
clientHeader.push(`gl-web/${this._gaxModule.version}`);
}
if (!opts.fallback) {
clientHeader.push(`grpc/${gaxGrpc.grpcVersion}`);
clientHeader.push(`grpc/${this._gaxGrpc.grpcVersion}`);
}

@@ -110,3 +110,3 @@ if (opts.libName && opts.libVersion) {

const nodejsProtoPath = path.join(__dirname, '..', '..', 'protos', 'protos.json');
const protos = gaxGrpc.loadProto(opts.fallback ? require('../../protos/protos.json') : nodejsProtoPath);
this._protos = this._gaxGrpc.loadProto(opts.fallback ? require('../../protos/protos.json') : nodejsProtoPath);
// This API contains "path templates"; forward-slash-separated

@@ -116,6 +116,6 @@ // identifiers to uniquely identify resources within the API.

this._pathTemplates = {
locationPathTemplate: new gaxModule.PathTemplate('projects/{project}/locations/{location}'),
projectPathTemplate: new gaxModule.PathTemplate('projects/{project}'),
queuePathTemplate: new gaxModule.PathTemplate('projects/{project}/locations/{location}/queues/{queue}'),
taskPathTemplate: new gaxModule.PathTemplate('projects/{project}/locations/{location}/queues/{queue}/tasks/{task}'),
locationPathTemplate: new this._gaxModule.PathTemplate('projects/{project}/locations/{location}'),
projectPathTemplate: new this._gaxModule.PathTemplate('projects/{project}'),
queuePathTemplate: new this._gaxModule.PathTemplate('projects/{project}/locations/{location}/queues/{queue}'),
taskPathTemplate: new this._gaxModule.PathTemplate('projects/{project}/locations/{location}/queues/{queue}/tasks/{task}'),
};

@@ -126,7 +126,7 @@ // Some of the methods on this service return "paged" results,

this._descriptors.page = {
listQueues: new gaxModule.PageDescriptor('pageToken', 'nextPageToken', 'queues'),
listTasks: new gaxModule.PageDescriptor('pageToken', 'nextPageToken', 'tasks'),
listQueues: new this._gaxModule.PageDescriptor('pageToken', 'nextPageToken', 'queues'),
listTasks: new this._gaxModule.PageDescriptor('pageToken', 'nextPageToken', 'tasks'),
};
// Put together the default options sent with requests.
const defaults = gaxGrpc.constructSettings('google.cloud.tasks.v2beta3.CloudTasks', gapicConfig, opts.clientConfig || {}, { 'x-goog-api-client': clientHeader.join(' ') });
this._defaults = this._gaxGrpc.constructSettings('google.cloud.tasks.v2beta3.CloudTasks', gapicConfig, opts.clientConfig || {}, { 'x-goog-api-client': clientHeader.join(' ') });
// Set up a dictionary of "inner API calls"; the core implementation

@@ -136,8 +136,25 @@ // of calling the API is handled in `google-gax`, with this code

this._innerApiCalls = {};
}
/**
* Initialize the client.
* Performs asynchronous operations (such as authentication) and prepares the client.
* This function will be called automatically when any class method is called for the
* first time, but if you need to initialize it before calling an actual method,
* feel free to call initialize() directly.
*
* You can await on this method if you want to make sure the client is initialized.
*
* @returns {Promise} A promise that resolves to an authenticated service stub.
*/
initialize() {
// If the client stub promise is already initialized, return immediately.
if (this.cloudTasksStub) {
return this.cloudTasksStub;
}
// Put together the "service stub" for
// google.cloud.tasks.v2beta3.CloudTasks.
this.cloudTasksStub = gaxGrpc.createStub(opts.fallback
? protos.lookupService('google.cloud.tasks.v2beta3.CloudTasks')
this.cloudTasksStub = this._gaxGrpc.createStub(this._opts.fallback
? this._protos.lookupService('google.cloud.tasks.v2beta3.CloudTasks')
: // tslint:disable-next-line no-any
protos.google.cloud.tasks.v2beta3.CloudTasks, opts);
this._protos.google.cloud.tasks.v2beta3.CloudTasks, this._opts);
// Iterate over each of the methods that the service provides

@@ -172,3 +189,3 @@ // and create an API call method for each.

});
const apiCall = gaxModule.createApiCall(innerCallPromise, defaults[methodName], this._descriptors.page[methodName] ||
const apiCall = this._gaxModule.createApiCall(innerCallPromise, this._defaults[methodName], this._descriptors.page[methodName] ||
this._descriptors.stream[methodName] ||

@@ -180,2 +197,3 @@ this._descriptors.longrunning[methodName]);

}
return this.cloudTasksStub;
}

@@ -250,2 +268,3 @@ /**

});
this.initialize();
return this._innerApiCalls.getQueue(request, options, callback);

@@ -275,7 +294,7 @@ }

* Tasks' implementation of
* [ListLocations][google.cloud.location.Locations.ListLocations].
* {@link google.cloud.location.Locations.ListLocations|ListLocations}.
* @param {google.cloud.tasks.v2beta3.Queue} request.queue
* Required. The queue to create.
*
* [Queue's name][google.cloud.tasks.v2beta3.Queue.name] cannot be the same as an existing queue.
* {@link google.cloud.tasks.v2beta3.Queue.name|Queue's name} cannot be the same as an existing queue.
* @param {object} [options]

@@ -303,2 +322,3 @@ * Call options. See {@link https://googleapis.dev/nodejs/google-gax/latest/interfaces/CallOptions.html|CallOptions} for more details.

});
this.initialize();
return this._innerApiCalls.createQueue(request, options, callback);

@@ -328,7 +348,7 @@ }

*
* The queue's [name][google.cloud.tasks.v2beta3.Queue.name] must be specified.
* The queue's {@link google.cloud.tasks.v2beta3.Queue.name|name} must be specified.
*
* Output only fields cannot be modified using UpdateQueue.
* Any value specified for an output only field will be ignored.
* The queue's [name][google.cloud.tasks.v2beta3.Queue.name] cannot be changed.
* The queue's {@link google.cloud.tasks.v2beta3.Queue.name|name} cannot be changed.
* @param {google.protobuf.FieldMask} request.updateMask

@@ -360,2 +380,3 @@ * A mask used to specify which fields of the queue are being updated.

});
this.initialize();
return this._innerApiCalls.updateQueue(request, options, callback);

@@ -405,2 +426,3 @@ }

});
this.initialize();
return this._innerApiCalls.deleteQueue(request, options, callback);

@@ -443,2 +465,3 @@ }

});
this.initialize();
return this._innerApiCalls.purgeQueue(request, options, callback);

@@ -451,5 +474,5 @@ }

* until the queue is resumed via
* [ResumeQueue][google.cloud.tasks.v2beta3.CloudTasks.ResumeQueue]. Tasks can still be added
* {@link google.cloud.tasks.v2beta3.CloudTasks.ResumeQueue|ResumeQueue}. Tasks can still be added
* when the queue is paused. A queue is paused if its
* [state][google.cloud.tasks.v2beta3.Queue.state] is [PAUSED][google.cloud.tasks.v2beta3.Queue.State.PAUSED].
* {@link google.cloud.tasks.v2beta3.Queue.state|state} is {@link google.cloud.tasks.v2beta3.Queue.State.PAUSED|PAUSED}.
*

@@ -483,2 +506,3 @@ * @param {Object} request

});
this.initialize();
return this._innerApiCalls.pauseQueue(request, options, callback);

@@ -490,6 +514,6 @@ }

* This method resumes a queue after it has been
* [PAUSED][google.cloud.tasks.v2beta3.Queue.State.PAUSED] or
* [DISABLED][google.cloud.tasks.v2beta3.Queue.State.DISABLED]. The state of a queue is stored
* in the queue's [state][google.cloud.tasks.v2beta3.Queue.state]; after calling this method it
* will be set to [RUNNING][google.cloud.tasks.v2beta3.Queue.State.RUNNING].
* {@link google.cloud.tasks.v2beta3.Queue.State.PAUSED|PAUSED} or
* {@link google.cloud.tasks.v2beta3.Queue.State.DISABLED|DISABLED}. The state of a queue is stored
* in the queue's {@link google.cloud.tasks.v2beta3.Queue.state|state}; after calling this method it
* will be set to {@link google.cloud.tasks.v2beta3.Queue.State.RUNNING|RUNNING}.
*

@@ -529,6 +553,7 @@ * WARNING: Resuming many high-QPS queues at the same time can

});
this.initialize();
return this._innerApiCalls.resumeQueue(request, options, callback);
}
/**
* Gets the access control policy for a [Queue][google.cloud.tasks.v2beta3.Queue].
* Gets the access control policy for a {@link google.cloud.tasks.v2beta3.Queue|Queue}.
* Returns an empty policy if the resource exists and does not have a policy

@@ -567,6 +592,7 @@ * set.

});
this.initialize();
return this._innerApiCalls.getIamPolicy(request, options, callback);
}
/**
* Sets the access control policy for a [Queue][google.cloud.tasks.v2beta3.Queue]. Replaces any existing
* Sets the access control policy for a {@link google.cloud.tasks.v2beta3.Queue|Queue}. Replaces any existing
* policy.

@@ -607,8 +633,9 @@ *

});
this.initialize();
return this._innerApiCalls.setIamPolicy(request, options, callback);
}
/**
* Returns permissions that a caller has on a [Queue][google.cloud.tasks.v2beta3.Queue].
* Returns permissions that a caller has on a {@link google.cloud.tasks.v2beta3.Queue|Queue}.
* If the resource does not exist, this will return an empty set of
* permissions, not a [NOT_FOUND][google.rpc.Code.NOT_FOUND] error.
* permissions, not a {@link google.rpc.Code.NOT_FOUND|NOT_FOUND} error.
*

@@ -643,2 +670,3 @@ * Note: This operation is designed to be used for building permission-aware

});
this.initialize();
return this._innerApiCalls.testIamPermissions(request, options, callback);

@@ -655,6 +683,6 @@ }

* @param {google.cloud.tasks.v2beta3.Task.View} request.responseView
* The response_view specifies which subset of the [Task][google.cloud.tasks.v2beta3.Task] will be
* The response_view specifies which subset of the {@link google.cloud.tasks.v2beta3.Task|Task} will be
* returned.
*
* By default response_view is [BASIC][google.cloud.tasks.v2beta3.Task.View.BASIC]; not all
* By default response_view is {@link google.cloud.tasks.v2beta3.Task.View.BASIC|BASIC}; not all
* information is retrieved by default because some data, such as

@@ -665,5 +693,5 @@ * payloads, might be desirable to return only when needed because

*
* Authorization for [FULL][google.cloud.tasks.v2beta3.Task.View.FULL] requires
* Authorization for {@link google.cloud.tasks.v2beta3.Task.View.FULL|FULL} requires
* `cloudtasks.tasks.fullView` [Google IAM](https://cloud.google.com/iam/)
* permission on the [Task][google.cloud.tasks.v2beta3.Task] resource.
* permission on the {@link google.cloud.tasks.v2beta3.Task|Task} resource.
* @param {object} [options]

@@ -691,2 +719,3 @@ * Call options. See {@link https://googleapis.dev/nodejs/google-gax/latest/interfaces/CallOptions.html|CallOptions} for more details.

});
this.initialize();
return this._innerApiCalls.getTask(request, options, callback);

@@ -713,8 +742,8 @@ }

* `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID/tasks/TASK_ID`.
* The user can optionally specify a task [name][google.cloud.tasks.v2beta3.Task.name]. If a
* The user can optionally specify a task {@link google.cloud.tasks.v2beta3.Task.name|name}. If a
* name is not specified then the system will generate a random
* unique task id, which will be set in the task returned in the
* [response][google.cloud.tasks.v2beta3.Task.name].
* {@link google.cloud.tasks.v2beta3.Task.name|response}.
*
* If [schedule_time][google.cloud.tasks.v2beta3.Task.schedule_time] is not set or is in the
* If {@link google.cloud.tasks.v2beta3.Task.schedule_time|schedule_time} is not set or is in the
* past then Cloud Tasks will set it to the current time.

@@ -727,3 +756,3 @@ *

* that was deleted or executed recently then the call will fail
* with [ALREADY_EXISTS][google.rpc.Code.ALREADY_EXISTS].
* with {@link google.rpc.Code.ALREADY_EXISTS|ALREADY_EXISTS}.
* If the task's queue was created using Cloud Tasks, then another task with

@@ -736,3 +765,3 @@ * the same name can't be created for ~1hour after the original task was

* Because there is an extra lookup cost to identify duplicate task
* names, these [CreateTask][google.cloud.tasks.v2beta3.CloudTasks.CreateTask] calls have significantly
* names, these {@link google.cloud.tasks.v2beta3.CloudTasks.CreateTask|CreateTask} calls have significantly
* increased latency. Using hashed strings for the task id or for

@@ -746,6 +775,6 @@ * the prefix of the task id is recommended. Choosing task ids that

* @param {google.cloud.tasks.v2beta3.Task.View} request.responseView
* The response_view specifies which subset of the [Task][google.cloud.tasks.v2beta3.Task] will be
* The response_view specifies which subset of the {@link google.cloud.tasks.v2beta3.Task|Task} will be
* returned.
*
* By default response_view is [BASIC][google.cloud.tasks.v2beta3.Task.View.BASIC]; not all
* By default response_view is {@link google.cloud.tasks.v2beta3.Task.View.BASIC|BASIC}; not all
* information is retrieved by default because some data, such as

@@ -756,5 +785,5 @@ * payloads, might be desirable to return only when needed because

*
* Authorization for [FULL][google.cloud.tasks.v2beta3.Task.View.FULL] requires
* Authorization for {@link google.cloud.tasks.v2beta3.Task.View.FULL|FULL} requires
* `cloudtasks.tasks.fullView` [Google IAM](https://cloud.google.com/iam/)
* permission on the [Task][google.cloud.tasks.v2beta3.Task] resource.
* permission on the {@link google.cloud.tasks.v2beta3.Task|Task} resource.
* @param {object} [options]

@@ -782,2 +811,3 @@ * Call options. See {@link https://googleapis.dev/nodejs/google-gax/latest/interfaces/CallOptions.html|CallOptions} for more details.

});
this.initialize();
return this._innerApiCalls.createTask(request, options, callback);

@@ -819,2 +849,3 @@ }

});
this.initialize();
return this._innerApiCalls.deleteTask(request, options, callback);

@@ -826,7 +857,7 @@ }

* When this method is called, Cloud Tasks will dispatch the task, even if
* the task is already running, the queue has reached its [RateLimits][google.cloud.tasks.v2beta3.RateLimits] or
* is [PAUSED][google.cloud.tasks.v2beta3.Queue.State.PAUSED].
* the task is already running, the queue has reached its {@link google.cloud.tasks.v2beta3.RateLimits|RateLimits} or
* is {@link google.cloud.tasks.v2beta3.Queue.State.PAUSED|PAUSED}.
*
* This command is meant to be used for manual debugging. For
* example, [RunTask][google.cloud.tasks.v2beta3.CloudTasks.RunTask] can be used to retry a failed
* example, {@link google.cloud.tasks.v2beta3.CloudTasks.RunTask|RunTask} can be used to retry a failed
* task after a fix has been made or to manually force a task to be

@@ -836,3 +867,3 @@ * dispatched now.

* The dispatched task is returned. That is, the task that is returned
* contains the [status][Task.status] after the task is dispatched but
* contains the {@link Task.status|status} after the task is dispatched but
* before the task is received by its target.

@@ -842,8 +873,8 @@ *

* target, then the task will be deleted; otherwise the task's
* [schedule_time][google.cloud.tasks.v2beta3.Task.schedule_time] will be reset to the time that
* [RunTask][google.cloud.tasks.v2beta3.CloudTasks.RunTask] was called plus the retry delay specified
* in the queue's [RetryConfig][google.cloud.tasks.v2beta3.RetryConfig].
* {@link google.cloud.tasks.v2beta3.Task.schedule_time|schedule_time} will be reset to the time that
* {@link google.cloud.tasks.v2beta3.CloudTasks.RunTask|RunTask} was called plus the retry delay specified
* in the queue's {@link google.cloud.tasks.v2beta3.RetryConfig|RetryConfig}.
*
* [RunTask][google.cloud.tasks.v2beta3.CloudTasks.RunTask] returns
* [NOT_FOUND][google.rpc.Code.NOT_FOUND] when it is called on a
* {@link google.cloud.tasks.v2beta3.CloudTasks.RunTask|RunTask} returns
* {@link google.rpc.Code.NOT_FOUND|NOT_FOUND} when it is called on a
* task that has already succeeded or permanently failed.

@@ -857,6 +888,6 @@ *

* @param {google.cloud.tasks.v2beta3.Task.View} request.responseView
* The response_view specifies which subset of the [Task][google.cloud.tasks.v2beta3.Task] will be
* The response_view specifies which subset of the {@link google.cloud.tasks.v2beta3.Task|Task} will be
* returned.
*
* By default response_view is [BASIC][google.cloud.tasks.v2beta3.Task.View.BASIC]; not all
* By default response_view is {@link google.cloud.tasks.v2beta3.Task.View.BASIC|BASIC}; not all
* information is retrieved by default because some data, such as

@@ -867,5 +898,5 @@ * payloads, might be desirable to return only when needed because

*
* Authorization for [FULL][google.cloud.tasks.v2beta3.Task.View.FULL] requires
* Authorization for {@link google.cloud.tasks.v2beta3.Task.View.FULL|FULL} requires
* `cloudtasks.tasks.fullView` [Google IAM](https://cloud.google.com/iam/)
* permission on the [Task][google.cloud.tasks.v2beta3.Task] resource.
* permission on the {@link google.cloud.tasks.v2beta3.Task|Task} resource.
* @param {object} [options]

@@ -893,2 +924,3 @@ * Call options. See {@link https://googleapis.dev/nodejs/google-gax/latest/interfaces/CallOptions.html|CallOptions} for more details.

});
this.initialize();
return this._innerApiCalls.runTask(request, options, callback);

@@ -907,3 +939,3 @@ }

* @param {string} request.filter
* `filter` can be used to specify a subset of queues. Any [Queue][google.cloud.tasks.v2beta3.Queue]
* `filter` can be used to specify a subset of queues. Any {@link google.cloud.tasks.v2beta3.Queue|Queue}
* field can be used as a filter and several operators as supported.

@@ -925,3 +957,3 @@ * For example: `<=, <, >=, >, !=, =, :`. The filter syntax is the same as

* even if more queues exist; use the
* [next_page_token][google.cloud.tasks.v2beta3.ListQueuesResponse.next_page_token] in the
* {@link google.cloud.tasks.v2beta3.ListQueuesResponse.next_page_token|next_page_token} in the
* response to determine if more queues exist.

@@ -933,6 +965,6 @@ * @param {string} request.pageToken

* request the next page of results, page_token must be the value of
* [next_page_token][google.cloud.tasks.v2beta3.ListQueuesResponse.next_page_token] returned
* from the previous call to [ListQueues][google.cloud.tasks.v2beta3.CloudTasks.ListQueues]
* {@link google.cloud.tasks.v2beta3.ListQueuesResponse.next_page_token|next_page_token} returned
* from the previous call to {@link google.cloud.tasks.v2beta3.CloudTasks.ListQueues|ListQueues}
* method. It is an error to switch the value of the
* [filter][google.cloud.tasks.v2beta3.ListQueuesRequest.filter] while iterating through pages.
* {@link google.cloud.tasks.v2beta3.ListQueuesRequest.filter|filter} while iterating through pages.
* @param {object} [options]

@@ -972,2 +1004,3 @@ * Call options. See {@link https://googleapis.dev/nodejs/google-gax/latest/interfaces/CallOptions.html|CallOptions} for more details.

});
this.initialize();
return this._innerApiCalls.listQueues(request, options, callback);

@@ -994,3 +1027,3 @@ }

* @param {string} request.filter
* `filter` can be used to specify a subset of queues. Any [Queue][google.cloud.tasks.v2beta3.Queue]
* `filter` can be used to specify a subset of queues. Any {@link google.cloud.tasks.v2beta3.Queue|Queue}
* field can be used as a filter and several operators as supported.

@@ -1012,3 +1045,3 @@ * For example: `<=, <, >=, >, !=, =, :`. The filter syntax is the same as

* even if more queues exist; use the
* [next_page_token][google.cloud.tasks.v2beta3.ListQueuesResponse.next_page_token] in the
* {@link google.cloud.tasks.v2beta3.ListQueuesResponse.next_page_token|next_page_token} in the
* response to determine if more queues exist.

@@ -1020,6 +1053,6 @@ * @param {string} request.pageToken

* request the next page of results, page_token must be the value of
* [next_page_token][google.cloud.tasks.v2beta3.ListQueuesResponse.next_page_token] returned
* from the previous call to [ListQueues][google.cloud.tasks.v2beta3.CloudTasks.ListQueues]
* {@link google.cloud.tasks.v2beta3.ListQueuesResponse.next_page_token|next_page_token} returned
* from the previous call to {@link google.cloud.tasks.v2beta3.CloudTasks.ListQueues|ListQueues}
* method. It is an error to switch the value of the
* [filter][google.cloud.tasks.v2beta3.ListQueuesRequest.filter] while iterating through pages.
* {@link google.cloud.tasks.v2beta3.ListQueuesRequest.filter|filter} while iterating through pages.
* @param {object} [options]

@@ -1039,2 +1072,3 @@ * Call options. See {@link https://googleapis.dev/nodejs/google-gax/latest/interfaces/CallOptions.html|CallOptions} for more details.

const callSettings = new gax.CallSettings(options);
this.initialize();
return this._descriptors.page.listQueues.createStream(this._innerApiCalls.listQueues, request, callSettings);

@@ -1045,5 +1079,5 @@ }

*
* By default, only the [BASIC][google.cloud.tasks.v2beta3.Task.View.BASIC] view is retrieved
* By default, only the {@link google.cloud.tasks.v2beta3.Task.View.BASIC|BASIC} view is retrieved
* due to performance considerations;
* [response_view][google.cloud.tasks.v2beta3.ListTasksRequest.response_view] controls the
* {@link google.cloud.tasks.v2beta3.ListTasksRequest.response_view|response_view} controls the
* subset of information which is returned.

@@ -1060,6 +1094,6 @@ *

* @param {google.cloud.tasks.v2beta3.Task.View} request.responseView
* The response_view specifies which subset of the [Task][google.cloud.tasks.v2beta3.Task] will be
* The response_view specifies which subset of the {@link google.cloud.tasks.v2beta3.Task|Task} will be
* returned.
*
* By default response_view is [BASIC][google.cloud.tasks.v2beta3.Task.View.BASIC]; not all
* By default response_view is {@link google.cloud.tasks.v2beta3.Task.View.BASIC|BASIC}; not all
* information is retrieved by default because some data, such as

@@ -1070,5 +1104,5 @@ * payloads, might be desirable to return only when needed because

*
* Authorization for [FULL][google.cloud.tasks.v2beta3.Task.View.FULL] requires
* Authorization for {@link google.cloud.tasks.v2beta3.Task.View.FULL|FULL} requires
* `cloudtasks.tasks.fullView` [Google IAM](https://cloud.google.com/iam/)
* permission on the [Task][google.cloud.tasks.v2beta3.Task] resource.
* permission on the {@link google.cloud.tasks.v2beta3.Task|Task} resource.
* @param {number} request.pageSize

@@ -1078,3 +1112,3 @@ * Maximum page size.

* Fewer tasks than requested might be returned, even if more tasks exist; use
* [next_page_token][google.cloud.tasks.v2beta3.ListTasksResponse.next_page_token] in the response to
* {@link google.cloud.tasks.v2beta3.ListTasksResponse.next_page_token|next_page_token} in the response to
* determine if more tasks exist.

@@ -1089,4 +1123,4 @@ *

* request the next page of results, page_token must be the value of
* [next_page_token][google.cloud.tasks.v2beta3.ListTasksResponse.next_page_token] returned
* from the previous call to [ListTasks][google.cloud.tasks.v2beta3.CloudTasks.ListTasks]
* {@link google.cloud.tasks.v2beta3.ListTasksResponse.next_page_token|next_page_token} returned
* from the previous call to {@link google.cloud.tasks.v2beta3.CloudTasks.ListTasks|ListTasks}
* method.

@@ -1129,2 +1163,3 @@ *

});
this.initialize();
return this._innerApiCalls.listTasks(request, options, callback);

@@ -1151,6 +1186,6 @@ }

* @param {google.cloud.tasks.v2beta3.Task.View} request.responseView
* The response_view specifies which subset of the [Task][google.cloud.tasks.v2beta3.Task] will be
* The response_view specifies which subset of the {@link google.cloud.tasks.v2beta3.Task|Task} will be
* returned.
*
* By default response_view is [BASIC][google.cloud.tasks.v2beta3.Task.View.BASIC]; not all
* By default response_view is {@link google.cloud.tasks.v2beta3.Task.View.BASIC|BASIC}; not all
* information is retrieved by default because some data, such as

@@ -1161,5 +1196,5 @@ * payloads, might be desirable to return only when needed because

*
* Authorization for [FULL][google.cloud.tasks.v2beta3.Task.View.FULL] requires
* Authorization for {@link google.cloud.tasks.v2beta3.Task.View.FULL|FULL} requires
* `cloudtasks.tasks.fullView` [Google IAM](https://cloud.google.com/iam/)
* permission on the [Task][google.cloud.tasks.v2beta3.Task] resource.
* permission on the {@link google.cloud.tasks.v2beta3.Task|Task} resource.
* @param {number} request.pageSize

@@ -1169,3 +1204,3 @@ * Maximum page size.

* Fewer tasks than requested might be returned, even if more tasks exist; use
* [next_page_token][google.cloud.tasks.v2beta3.ListTasksResponse.next_page_token] in the response to
* {@link google.cloud.tasks.v2beta3.ListTasksResponse.next_page_token|next_page_token} in the response to
* determine if more tasks exist.

@@ -1180,4 +1215,4 @@ *

* request the next page of results, page_token must be the value of
* [next_page_token][google.cloud.tasks.v2beta3.ListTasksResponse.next_page_token] returned
* from the previous call to [ListTasks][google.cloud.tasks.v2beta3.CloudTasks.ListTasks]
* {@link google.cloud.tasks.v2beta3.ListTasksResponse.next_page_token|next_page_token} returned
* from the previous call to {@link google.cloud.tasks.v2beta3.CloudTasks.ListTasks|ListTasks}
* method.

@@ -1200,2 +1235,3 @@ *

const callSettings = new gax.CallSettings(options);
this.initialize();
return this._descriptors.page.listTasks.createStream(this._innerApiCalls.listTasks, request, callSettings);

@@ -1369,2 +1405,3 @@ }

close() {
this.initialize();
if (!this._terminated) {

@@ -1371,0 +1408,0 @@ return this.cloudTasksStub.then(stub => {

@@ -7,2 +7,9 @@ # Changelog

## [1.9.0](https://www.github.com/googleapis/nodejs-tasks/compare/v1.8.0...v1.9.0) (2020-03-06)
### Features
* deferred client initialization ([#370](https://www.github.com/googleapis/nodejs-tasks/issues/370)) ([05fdd69](https://www.github.com/googleapis/nodejs-tasks/commit/05fdd6987c916da04c62193fe0f1081c23b85cbe))
## [1.8.0](https://www.github.com/googleapis/nodejs-tasks/compare/v1.7.3...v1.8.0) (2020-02-29)

@@ -9,0 +16,0 @@

{
"name": "@google-cloud/tasks",
"description": "Cloud Tasks API client for Node.js",
"version": "1.8.0",
"version": "1.9.0",
"license": "Apache-2.0",

@@ -6,0 +6,0 @@ "author": "Google LLC",

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc