Skip to content
This repository has been archived by the owner on Jul 13, 2023. It is now read-only.

feat: accept google-gax instance as a parameter #743

Merged
merged 10 commits into from
Sep 21, 2022
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@
"segments": [
{
"start": 25,
"end": 92,
"end": 95,
"type": "FULL"
}
],
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,9 @@
function main(features) {
// [START videointelligence_v1_generated_VideoIntelligenceService_AnnotateVideo_async]
/**
* This snippet has been automatically generated and should be regarded as a code template only.
* It will require modifications to work.
* It may require correct/in-range values for request initialization.
* TODO(developer): Uncomment these variables before running the sample.
*/
/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@
"segments": [
{
"start": 25,
"end": 91,
"end": 94,
"type": "FULL"
}
],
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,9 @@
function main(features) {
// [START videointelligence_v1beta2_generated_VideoIntelligenceService_AnnotateVideo_async]
/**
* This snippet has been automatically generated and should be regarded as a code template only.
* It will require modifications to work.
* It may require correct/in-range values for request initialization.
* TODO(developer): Uncomment these variables before running the sample.
*/
/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@
"segments": [
{
"start": 25,
"end": 91,
"end": 94,
"type": "FULL"
}
],
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,9 @@
function main(features) {
// [START videointelligence_v1p1beta1_generated_VideoIntelligenceService_AnnotateVideo_async]
/**
* This snippet has been automatically generated and should be regarded as a code template only.
* It will require modifications to work.
* It may require correct/in-range values for request initialization.
* TODO(developer): Uncomment these variables before running the sample.
*/
/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@
"segments": [
{
"start": 25,
"end": 89,
"end": 92,
"type": "FULL"
}
],
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,9 @@
function main(features) {
// [START videointelligence_v1p2beta1_generated_VideoIntelligenceService_AnnotateVideo_async]
/**
* This snippet has been automatically generated and should be regarded as a code template only.
* It will require modifications to work.
* It may require correct/in-range values for request initialization.
* TODO(developer): Uncomment these variables before running the sample.
*/
/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@
"segments": [
{
"start": 25,
"end": 65,
"end": 68,
"type": "FULL"
}
],
Expand Down Expand Up @@ -66,7 +66,7 @@
"segments": [
{
"start": 25,
"end": 92,
"end": 95,
"type": "FULL"
}
],
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,9 @@
function main() {
// [START videointelligence_v1p3beta1_generated_StreamingVideoIntelligenceService_StreamingAnnotateVideo_async]
/**
* This snippet has been automatically generated and should be regarded as a code template only.
* It will require modifications to work.
* It may require correct/in-range values for request initialization.
* TODO(developer): Uncomment these variables before running the sample.
*/
/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,9 @@
function main(features) {
// [START videointelligence_v1p3beta1_generated_VideoIntelligenceService_AnnotateVideo_async]
/**
* This snippet has been automatically generated and should be regarded as a code template only.
* It will require modifications to work.
* It may require correct/in-range values for request initialization.
* TODO(developer): Uncomment these variables before running the sample.
*/
/**
Expand Down
5 changes: 3 additions & 2 deletions src/v1/video_intelligence_service_client.ts
Original file line number Diff line number Diff line change
Expand Up @@ -290,7 +290,8 @@ export class VideoIntelligenceServiceClient {
const apiCall = this._gaxModule.createApiCall(
callPromise,
this._defaults[methodName],
descriptor
descriptor,
this._opts.fallback
);

this.innerApiCalls[methodName] = apiCall;
Expand Down Expand Up @@ -513,7 +514,7 @@ export class VideoIntelligenceServiceClient {
const decodeOperation = new gax.Operation(
operation,
this.descriptors.longrunning.annotateVideo,
gax.createDefaultBackoffSettings()
this._gaxModule.createDefaultBackoffSettings()
);
return decodeOperation as LROperation<
protos.google.cloud.videointelligence.v1.AnnotateVideoResponse,
Expand Down
5 changes: 3 additions & 2 deletions src/v1beta2/video_intelligence_service_client.ts
Original file line number Diff line number Diff line change
Expand Up @@ -292,7 +292,8 @@ export class VideoIntelligenceServiceClient {
const apiCall = this._gaxModule.createApiCall(
callPromise,
this._defaults[methodName],
descriptor
descriptor,
this._opts.fallback
);

this.innerApiCalls[methodName] = apiCall;
Expand Down Expand Up @@ -514,7 +515,7 @@ export class VideoIntelligenceServiceClient {
const decodeOperation = new gax.Operation(
operation,
this.descriptors.longrunning.annotateVideo,
gax.createDefaultBackoffSettings()
this._gaxModule.createDefaultBackoffSettings()
);
return decodeOperation as LROperation<
protos.google.cloud.videointelligence.v1beta2.AnnotateVideoResponse,
Expand Down
5 changes: 3 additions & 2 deletions src/v1p1beta1/video_intelligence_service_client.ts
Original file line number Diff line number Diff line change
Expand Up @@ -292,7 +292,8 @@ export class VideoIntelligenceServiceClient {
const apiCall = this._gaxModule.createApiCall(
callPromise,
this._defaults[methodName],
descriptor
descriptor,
this._opts.fallback
);

this.innerApiCalls[methodName] = apiCall;
Expand Down Expand Up @@ -514,7 +515,7 @@ export class VideoIntelligenceServiceClient {
const decodeOperation = new gax.Operation(
operation,
this.descriptors.longrunning.annotateVideo,
gax.createDefaultBackoffSettings()
this._gaxModule.createDefaultBackoffSettings()
);
return decodeOperation as LROperation<
protos.google.cloud.videointelligence.v1p1beta1.AnnotateVideoResponse,
Expand Down
5 changes: 3 additions & 2 deletions src/v1p2beta1/video_intelligence_service_client.ts
Original file line number Diff line number Diff line change
Expand Up @@ -292,7 +292,8 @@ export class VideoIntelligenceServiceClient {
const apiCall = this._gaxModule.createApiCall(
callPromise,
this._defaults[methodName],
descriptor
descriptor,
this._opts.fallback
);

this.innerApiCalls[methodName] = apiCall;
Expand Down Expand Up @@ -512,7 +513,7 @@ export class VideoIntelligenceServiceClient {
const decodeOperation = new gax.Operation(
operation,
this.descriptors.longrunning.annotateVideo,
gax.createDefaultBackoffSettings()
this._gaxModule.createDefaultBackoffSettings()
);
return decodeOperation as LROperation<
protos.google.cloud.videointelligence.v1p2beta1.AnnotateVideoResponse,
Expand Down
3 changes: 2 additions & 1 deletion src/v1p3beta1/streaming_video_intelligence_service_client.ts
Original file line number Diff line number Diff line change
Expand Up @@ -248,7 +248,8 @@ export class StreamingVideoIntelligenceServiceClient {
const apiCall = this._gaxModule.createApiCall(
callPromise,
this._defaults[methodName],
descriptor
descriptor,
this._opts.fallback
);

this.innerApiCalls[methodName] = apiCall;
Expand Down
5 changes: 3 additions & 2 deletions src/v1p3beta1/video_intelligence_service_client.ts
Original file line number Diff line number Diff line change
Expand Up @@ -292,7 +292,8 @@ export class VideoIntelligenceServiceClient {
const apiCall = this._gaxModule.createApiCall(
callPromise,
this._defaults[methodName],
descriptor
descriptor,
this._opts.fallback
);

this.innerApiCalls[methodName] = apiCall;
Expand Down Expand Up @@ -515,7 +516,7 @@ export class VideoIntelligenceServiceClient {
const decodeOperation = new gax.Operation(
operation,
this.descriptors.longrunning.annotateVideo,
gax.createDefaultBackoffSettings()
this._gaxModule.createDefaultBackoffSettings()
);
return decodeOperation as LROperation<
protos.google.cloud.videointelligence.v1p3beta1.AnnotateVideoResponse,
Expand Down
Loading