@google-cloud/discoveryengine 3.1.0 → 3.3.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/build/protos/google/cloud/discoveryengine/v1/search_service.proto +147 -19
- package/build/protos/protos.d.ts +608 -126
- package/build/protos/protos.js +1 -1
- package/build/protos/protos.json +185 -12
- package/build/src/v1/assistant_service_client.js +4 -4
- package/build/src/v1/cmek_config_service_client.js +9 -13
- package/build/src/v1/completion_service_client.js +10 -14
- package/build/src/v1/control_service_client.js +10 -10
- package/build/src/v1/conversational_search_service_client.js +21 -21
- package/build/src/v1/data_store_service_client.js +12 -16
- package/build/src/v1/document_service_client.js +15 -19
- package/build/src/v1/engine_service_client.js +12 -16
- package/build/src/v1/grounded_generation_service_client.js +6 -6
- package/build/src/v1/identity_mapping_store_service_client.js +16 -20
- package/build/src/v1/project_service_client.js +6 -10
- package/build/src/v1/rank_service_client.js +4 -4
- package/build/src/v1/recommendation_service_client.js +4 -4
- package/build/src/v1/schema_service_client.js +12 -16
- package/build/src/v1/search_service_client.d.ts +162 -24
- package/build/src/v1/search_service_client.js +123 -26
- package/build/src/v1/search_tuning_service_client.js +7 -11
- package/build/src/v1/serving_config_service_client.js +4 -4
- package/build/src/v1/session_service_client.js +10 -10
- package/build/src/v1/site_search_engine_service_client.js +24 -28
- package/build/src/v1/user_event_service_client.js +9 -13
- package/build/src/v1/user_license_service_client.js +9 -13
- package/build/src/v1alpha/acl_config_service_client.js +5 -5
- package/build/src/v1alpha/chunk_service_client.js +7 -7
- package/build/src/v1alpha/completion_service_client.js +8 -8
- package/build/src/v1alpha/control_service_client.js +10 -10
- package/build/src/v1alpha/conversational_search_service_client.js +20 -20
- package/build/src/v1alpha/data_store_service_client.js +12 -12
- package/build/src/v1alpha/document_service_client.js +14 -14
- package/build/src/v1alpha/engine_service_client.js +13 -13
- package/build/src/v1alpha/estimate_billing_service_client.js +4 -4
- package/build/src/v1alpha/evaluation_service_client.js +11 -11
- package/build/src/v1alpha/grounded_generation_service_client.js +4 -4
- package/build/src/v1alpha/project_service_client.js +6 -6
- package/build/src/v1alpha/rank_service_client.js +4 -4
- package/build/src/v1alpha/recommendation_service_client.js +4 -4
- package/build/src/v1alpha/sample_query_service_client.js +11 -11
- package/build/src/v1alpha/sample_query_set_service_client.js +10 -10
- package/build/src/v1alpha/schema_service_client.js +10 -10
- package/build/src/v1alpha/search_service_client.js +6 -6
- package/build/src/v1alpha/search_tuning_service_client.js +5 -5
- package/build/src/v1alpha/serving_config_service_client.js +8 -8
- package/build/src/v1alpha/session_service_client.js +13 -13
- package/build/src/v1alpha/site_search_engine_service_client.js +21 -21
- package/build/src/v1alpha/user_event_service_client.js +7 -7
- package/build/src/v1beta/acl_config_service_client.js +5 -5
- package/build/src/v1beta/assistant_service_client.js +11 -11
- package/build/src/v1beta/cmek_config_service_client.js +7 -7
- package/build/src/v1beta/completion_service_client.js +10 -10
- package/build/src/v1beta/control_service_client.js +10 -10
- package/build/src/v1beta/conversational_search_service_client.js +21 -21
- package/build/src/v1beta/data_store_service_client.js +10 -10
- package/build/src/v1beta/document_service_client.js +13 -13
- package/build/src/v1beta/engine_service_client.js +15 -15
- package/build/src/v1beta/evaluation_service_client.js +11 -11
- package/build/src/v1beta/grounded_generation_service_client.js +6 -6
- package/build/src/v1beta/identity_mapping_store_service_client.js +14 -14
- package/build/src/v1beta/license_config_service_client.js +11 -11
- package/build/src/v1beta/project_service_client.js +4 -4
- package/build/src/v1beta/rank_service_client.js +4 -4
- package/build/src/v1beta/recommendation_service_client.js +4 -4
- package/build/src/v1beta/sample_query_service_client.js +11 -11
- package/build/src/v1beta/sample_query_set_service_client.js +10 -10
- package/build/src/v1beta/schema_service_client.js +10 -10
- package/build/src/v1beta/search_service_client.js +9 -9
- package/build/src/v1beta/search_tuning_service_client.js +5 -5
- package/build/src/v1beta/serving_config_service_client.js +10 -10
- package/build/src/v1beta/session_service_client.js +10 -10
- package/build/src/v1beta/site_search_engine_service_client.js +22 -22
- package/build/src/v1beta/user_event_service_client.js +7 -7
- package/build/src/v1beta/user_license_service_client.js +8 -8
- package/build/src/v1beta/user_store_service_client.js +5 -5
- package/package.json +1 -1
|
@@ -282,7 +282,7 @@ class ConversationalSearchServiceClient {
|
|
|
282
282
|
'listSessions',
|
|
283
283
|
];
|
|
284
284
|
for (const methodName of conversationalSearchServiceStubMethods) {
|
|
285
|
-
const callPromise = this.conversationalSearchServiceStub.then(
|
|
285
|
+
const callPromise = this.conversationalSearchServiceStub.then(stub => (...args) => {
|
|
286
286
|
if (this._terminated) {
|
|
287
287
|
if (methodName in this.descriptors.stream) {
|
|
288
288
|
const stream = new stream_1.PassThrough({ objectMode: true });
|
|
@@ -387,7 +387,7 @@ class ConversationalSearchServiceClient {
|
|
|
387
387
|
this._gaxModule.routingHeader.fromParams({
|
|
388
388
|
name: request.name ?? '',
|
|
389
389
|
});
|
|
390
|
-
this.initialize().catch(
|
|
390
|
+
this.initialize().catch(err => {
|
|
391
391
|
throw err;
|
|
392
392
|
});
|
|
393
393
|
this._log.info('converseConversation request %j', request);
|
|
@@ -430,7 +430,7 @@ class ConversationalSearchServiceClient {
|
|
|
430
430
|
this._gaxModule.routingHeader.fromParams({
|
|
431
431
|
parent: request.parent ?? '',
|
|
432
432
|
});
|
|
433
|
-
this.initialize().catch(
|
|
433
|
+
this.initialize().catch(err => {
|
|
434
434
|
throw err;
|
|
435
435
|
});
|
|
436
436
|
this._log.info('createConversation request %j', request);
|
|
@@ -473,7 +473,7 @@ class ConversationalSearchServiceClient {
|
|
|
473
473
|
this._gaxModule.routingHeader.fromParams({
|
|
474
474
|
name: request.name ?? '',
|
|
475
475
|
});
|
|
476
|
-
this.initialize().catch(
|
|
476
|
+
this.initialize().catch(err => {
|
|
477
477
|
throw err;
|
|
478
478
|
});
|
|
479
479
|
this._log.info('deleteConversation request %j', request);
|
|
@@ -516,7 +516,7 @@ class ConversationalSearchServiceClient {
|
|
|
516
516
|
this._gaxModule.routingHeader.fromParams({
|
|
517
517
|
'conversation.name': request.conversation.name ?? '',
|
|
518
518
|
});
|
|
519
|
-
this.initialize().catch(
|
|
519
|
+
this.initialize().catch(err => {
|
|
520
520
|
throw err;
|
|
521
521
|
});
|
|
522
522
|
this._log.info('updateConversation request %j', request);
|
|
@@ -559,7 +559,7 @@ class ConversationalSearchServiceClient {
|
|
|
559
559
|
this._gaxModule.routingHeader.fromParams({
|
|
560
560
|
name: request.name ?? '',
|
|
561
561
|
});
|
|
562
|
-
this.initialize().catch(
|
|
562
|
+
this.initialize().catch(err => {
|
|
563
563
|
throw err;
|
|
564
564
|
});
|
|
565
565
|
this._log.info('getConversation request %j', request);
|
|
@@ -602,7 +602,7 @@ class ConversationalSearchServiceClient {
|
|
|
602
602
|
this._gaxModule.routingHeader.fromParams({
|
|
603
603
|
serving_config: request.servingConfig ?? '',
|
|
604
604
|
});
|
|
605
|
-
this.initialize().catch(
|
|
605
|
+
this.initialize().catch(err => {
|
|
606
606
|
throw err;
|
|
607
607
|
});
|
|
608
608
|
this._log.info('answerQuery request %j', request);
|
|
@@ -645,7 +645,7 @@ class ConversationalSearchServiceClient {
|
|
|
645
645
|
this._gaxModule.routingHeader.fromParams({
|
|
646
646
|
name: request.name ?? '',
|
|
647
647
|
});
|
|
648
|
-
this.initialize().catch(
|
|
648
|
+
this.initialize().catch(err => {
|
|
649
649
|
throw err;
|
|
650
650
|
});
|
|
651
651
|
this._log.info('getAnswer request %j', request);
|
|
@@ -688,7 +688,7 @@ class ConversationalSearchServiceClient {
|
|
|
688
688
|
this._gaxModule.routingHeader.fromParams({
|
|
689
689
|
parent: request.parent ?? '',
|
|
690
690
|
});
|
|
691
|
-
this.initialize().catch(
|
|
691
|
+
this.initialize().catch(err => {
|
|
692
692
|
throw err;
|
|
693
693
|
});
|
|
694
694
|
this._log.info('createSession request %j', request);
|
|
@@ -731,7 +731,7 @@ class ConversationalSearchServiceClient {
|
|
|
731
731
|
this._gaxModule.routingHeader.fromParams({
|
|
732
732
|
name: request.name ?? '',
|
|
733
733
|
});
|
|
734
|
-
this.initialize().catch(
|
|
734
|
+
this.initialize().catch(err => {
|
|
735
735
|
throw err;
|
|
736
736
|
});
|
|
737
737
|
this._log.info('deleteSession request %j', request);
|
|
@@ -774,7 +774,7 @@ class ConversationalSearchServiceClient {
|
|
|
774
774
|
this._gaxModule.routingHeader.fromParams({
|
|
775
775
|
'session.name': request.session.name ?? '',
|
|
776
776
|
});
|
|
777
|
-
this.initialize().catch(
|
|
777
|
+
this.initialize().catch(err => {
|
|
778
778
|
throw err;
|
|
779
779
|
});
|
|
780
780
|
this._log.info('updateSession request %j', request);
|
|
@@ -817,7 +817,7 @@ class ConversationalSearchServiceClient {
|
|
|
817
817
|
this._gaxModule.routingHeader.fromParams({
|
|
818
818
|
name: request.name ?? '',
|
|
819
819
|
});
|
|
820
|
-
this.initialize().catch(
|
|
820
|
+
this.initialize().catch(err => {
|
|
821
821
|
throw err;
|
|
822
822
|
});
|
|
823
823
|
this._log.info('getSession request %j', request);
|
|
@@ -949,7 +949,7 @@ class ConversationalSearchServiceClient {
|
|
|
949
949
|
this._gaxModule.routingHeader.fromParams({
|
|
950
950
|
serving_config: request.servingConfig ?? '',
|
|
951
951
|
});
|
|
952
|
-
this.initialize().catch(
|
|
952
|
+
this.initialize().catch(err => {
|
|
953
953
|
throw err;
|
|
954
954
|
});
|
|
955
955
|
this._log.info('streamAnswerQuery stream %j', options);
|
|
@@ -972,7 +972,7 @@ class ConversationalSearchServiceClient {
|
|
|
972
972
|
this._gaxModule.routingHeader.fromParams({
|
|
973
973
|
parent: request.parent ?? '',
|
|
974
974
|
});
|
|
975
|
-
this.initialize().catch(
|
|
975
|
+
this.initialize().catch(err => {
|
|
976
976
|
throw err;
|
|
977
977
|
});
|
|
978
978
|
const wrappedCallback = callback
|
|
@@ -1041,7 +1041,7 @@ class ConversationalSearchServiceClient {
|
|
|
1041
1041
|
});
|
|
1042
1042
|
const defaultCallSettings = this._defaults['listConversations'];
|
|
1043
1043
|
const callSettings = defaultCallSettings.merge(options);
|
|
1044
|
-
this.initialize().catch(
|
|
1044
|
+
this.initialize().catch(err => {
|
|
1045
1045
|
throw err;
|
|
1046
1046
|
});
|
|
1047
1047
|
this._log.info('listConversations stream %j', request);
|
|
@@ -1102,7 +1102,7 @@ class ConversationalSearchServiceClient {
|
|
|
1102
1102
|
});
|
|
1103
1103
|
const defaultCallSettings = this._defaults['listConversations'];
|
|
1104
1104
|
const callSettings = defaultCallSettings.merge(options);
|
|
1105
|
-
this.initialize().catch(
|
|
1105
|
+
this.initialize().catch(err => {
|
|
1106
1106
|
throw err;
|
|
1107
1107
|
});
|
|
1108
1108
|
this._log.info('listConversations iterate %j', request);
|
|
@@ -1125,7 +1125,7 @@ class ConversationalSearchServiceClient {
|
|
|
1125
1125
|
this._gaxModule.routingHeader.fromParams({
|
|
1126
1126
|
parent: request.parent ?? '',
|
|
1127
1127
|
});
|
|
1128
|
-
this.initialize().catch(
|
|
1128
|
+
this.initialize().catch(err => {
|
|
1129
1129
|
throw err;
|
|
1130
1130
|
});
|
|
1131
1131
|
const wrappedCallback = callback
|
|
@@ -1220,7 +1220,7 @@ class ConversationalSearchServiceClient {
|
|
|
1220
1220
|
});
|
|
1221
1221
|
const defaultCallSettings = this._defaults['listSessions'];
|
|
1222
1222
|
const callSettings = defaultCallSettings.merge(options);
|
|
1223
|
-
this.initialize().catch(
|
|
1223
|
+
this.initialize().catch(err => {
|
|
1224
1224
|
throw err;
|
|
1225
1225
|
});
|
|
1226
1226
|
this._log.info('listSessions stream %j', request);
|
|
@@ -1307,7 +1307,7 @@ class ConversationalSearchServiceClient {
|
|
|
1307
1307
|
});
|
|
1308
1308
|
const defaultCallSettings = this._defaults['listSessions'];
|
|
1309
1309
|
const callSettings = defaultCallSettings.merge(options);
|
|
1310
|
-
this.initialize().catch(
|
|
1310
|
+
this.initialize().catch(err => {
|
|
1311
1311
|
throw err;
|
|
1312
1312
|
});
|
|
1313
1313
|
this._log.info('listSessions iterate %j', request);
|
|
@@ -4296,11 +4296,11 @@ class ConversationalSearchServiceClient {
|
|
|
4296
4296
|
*/
|
|
4297
4297
|
close() {
|
|
4298
4298
|
if (this.conversationalSearchServiceStub && !this._terminated) {
|
|
4299
|
-
return this.conversationalSearchServiceStub.then(
|
|
4299
|
+
return this.conversationalSearchServiceStub.then(stub => {
|
|
4300
4300
|
this._log.info('ending gRPC channel');
|
|
4301
4301
|
this._terminated = true;
|
|
4302
4302
|
stub.close();
|
|
4303
|
-
this.locationsClient.close().catch(
|
|
4303
|
+
this.locationsClient.close().catch(err => {
|
|
4304
4304
|
throw err;
|
|
4305
4305
|
});
|
|
4306
4306
|
});
|
|
@@ -400,7 +400,7 @@ class DataStoreServiceClient {
|
|
|
400
400
|
'updateDataStore',
|
|
401
401
|
];
|
|
402
402
|
for (const methodName of dataStoreServiceStubMethods) {
|
|
403
|
-
const callPromise = this.dataStoreServiceStub.then(
|
|
403
|
+
const callPromise = this.dataStoreServiceStub.then(stub => (...args) => {
|
|
404
404
|
if (this._terminated) {
|
|
405
405
|
return Promise.reject('The client has already been closed.');
|
|
406
406
|
}
|
|
@@ -498,7 +498,7 @@ class DataStoreServiceClient {
|
|
|
498
498
|
this._gaxModule.routingHeader.fromParams({
|
|
499
499
|
name: request.name ?? '',
|
|
500
500
|
});
|
|
501
|
-
this.initialize().catch(
|
|
501
|
+
this.initialize().catch(err => {
|
|
502
502
|
throw err;
|
|
503
503
|
});
|
|
504
504
|
this._log.info('getDataStore request %j', request);
|
|
@@ -541,7 +541,7 @@ class DataStoreServiceClient {
|
|
|
541
541
|
this._gaxModule.routingHeader.fromParams({
|
|
542
542
|
'data_store.name': request.dataStore.name ?? '',
|
|
543
543
|
});
|
|
544
|
-
this.initialize().catch(
|
|
544
|
+
this.initialize().catch(err => {
|
|
545
545
|
throw err;
|
|
546
546
|
});
|
|
547
547
|
this._log.info('updateDataStore request %j', request);
|
|
@@ -584,7 +584,7 @@ class DataStoreServiceClient {
|
|
|
584
584
|
this._gaxModule.routingHeader.fromParams({
|
|
585
585
|
parent: request.parent ?? '',
|
|
586
586
|
});
|
|
587
|
-
this.initialize().catch(
|
|
587
|
+
this.initialize().catch(err => {
|
|
588
588
|
throw err;
|
|
589
589
|
});
|
|
590
590
|
const wrappedCallback = callback
|
|
@@ -636,7 +636,7 @@ class DataStoreServiceClient {
|
|
|
636
636
|
this._gaxModule.routingHeader.fromParams({
|
|
637
637
|
name: request.name ?? '',
|
|
638
638
|
});
|
|
639
|
-
this.initialize().catch(
|
|
639
|
+
this.initialize().catch(err => {
|
|
640
640
|
throw err;
|
|
641
641
|
});
|
|
642
642
|
const wrappedCallback = callback
|
|
@@ -688,7 +688,7 @@ class DataStoreServiceClient {
|
|
|
688
688
|
this._gaxModule.routingHeader.fromParams({
|
|
689
689
|
parent: request.parent ?? '',
|
|
690
690
|
});
|
|
691
|
-
this.initialize().catch(
|
|
691
|
+
this.initialize().catch(err => {
|
|
692
692
|
throw err;
|
|
693
693
|
});
|
|
694
694
|
const wrappedCallback = callback
|
|
@@ -760,7 +760,7 @@ class DataStoreServiceClient {
|
|
|
760
760
|
});
|
|
761
761
|
const defaultCallSettings = this._defaults['listDataStores'];
|
|
762
762
|
const callSettings = defaultCallSettings.merge(options);
|
|
763
|
-
this.initialize().catch(
|
|
763
|
+
this.initialize().catch(err => {
|
|
764
764
|
throw err;
|
|
765
765
|
});
|
|
766
766
|
this._log.info('listDataStores stream %j', request);
|
|
@@ -824,7 +824,7 @@ class DataStoreServiceClient {
|
|
|
824
824
|
});
|
|
825
825
|
const defaultCallSettings = this._defaults['listDataStores'];
|
|
826
826
|
const callSettings = defaultCallSettings.merge(options);
|
|
827
|
-
this.initialize().catch(
|
|
827
|
+
this.initialize().catch(err => {
|
|
828
828
|
throw err;
|
|
829
829
|
});
|
|
830
830
|
this._log.info('listDataStores iterate %j', request);
|
|
@@ -4041,11 +4041,11 @@ class DataStoreServiceClient {
|
|
|
4041
4041
|
*/
|
|
4042
4042
|
close() {
|
|
4043
4043
|
if (this.dataStoreServiceStub && !this._terminated) {
|
|
4044
|
-
return this.dataStoreServiceStub.then(
|
|
4044
|
+
return this.dataStoreServiceStub.then(stub => {
|
|
4045
4045
|
this._log.info('ending gRPC channel');
|
|
4046
4046
|
this._terminated = true;
|
|
4047
4047
|
stub.close();
|
|
4048
|
-
this.locationsClient.close().catch(
|
|
4048
|
+
this.locationsClient.close().catch(err => {
|
|
4049
4049
|
throw err;
|
|
4050
4050
|
});
|
|
4051
4051
|
void this.operationsClient.close();
|
|
@@ -405,7 +405,7 @@ class DocumentServiceClient {
|
|
|
405
405
|
'batchGetDocumentsMetadata',
|
|
406
406
|
];
|
|
407
407
|
for (const methodName of documentServiceStubMethods) {
|
|
408
|
-
const callPromise = this.documentServiceStub.then(
|
|
408
|
+
const callPromise = this.documentServiceStub.then(stub => (...args) => {
|
|
409
409
|
if (this._terminated) {
|
|
410
410
|
return Promise.reject('The client has already been closed.');
|
|
411
411
|
}
|
|
@@ -503,7 +503,7 @@ class DocumentServiceClient {
|
|
|
503
503
|
this._gaxModule.routingHeader.fromParams({
|
|
504
504
|
name: request.name ?? '',
|
|
505
505
|
});
|
|
506
|
-
this.initialize().catch(
|
|
506
|
+
this.initialize().catch(err => {
|
|
507
507
|
throw err;
|
|
508
508
|
});
|
|
509
509
|
this._log.info('getDocument request %j', request);
|
|
@@ -546,7 +546,7 @@ class DocumentServiceClient {
|
|
|
546
546
|
this._gaxModule.routingHeader.fromParams({
|
|
547
547
|
parent: request.parent ?? '',
|
|
548
548
|
});
|
|
549
|
-
this.initialize().catch(
|
|
549
|
+
this.initialize().catch(err => {
|
|
550
550
|
throw err;
|
|
551
551
|
});
|
|
552
552
|
this._log.info('createDocument request %j', request);
|
|
@@ -589,7 +589,7 @@ class DocumentServiceClient {
|
|
|
589
589
|
this._gaxModule.routingHeader.fromParams({
|
|
590
590
|
'document.name': request.document.name ?? '',
|
|
591
591
|
});
|
|
592
|
-
this.initialize().catch(
|
|
592
|
+
this.initialize().catch(err => {
|
|
593
593
|
throw err;
|
|
594
594
|
});
|
|
595
595
|
this._log.info('updateDocument request %j', request);
|
|
@@ -632,7 +632,7 @@ class DocumentServiceClient {
|
|
|
632
632
|
this._gaxModule.routingHeader.fromParams({
|
|
633
633
|
name: request.name ?? '',
|
|
634
634
|
});
|
|
635
|
-
this.initialize().catch(
|
|
635
|
+
this.initialize().catch(err => {
|
|
636
636
|
throw err;
|
|
637
637
|
});
|
|
638
638
|
this._log.info('deleteDocument request %j', request);
|
|
@@ -675,7 +675,7 @@ class DocumentServiceClient {
|
|
|
675
675
|
this._gaxModule.routingHeader.fromParams({
|
|
676
676
|
parent: request.parent ?? '',
|
|
677
677
|
});
|
|
678
|
-
this.initialize().catch(
|
|
678
|
+
this.initialize().catch(err => {
|
|
679
679
|
throw err;
|
|
680
680
|
});
|
|
681
681
|
this._log.info('batchGetDocumentsMetadata request %j', request);
|
|
@@ -718,7 +718,7 @@ class DocumentServiceClient {
|
|
|
718
718
|
this._gaxModule.routingHeader.fromParams({
|
|
719
719
|
parent: request.parent ?? '',
|
|
720
720
|
});
|
|
721
|
-
this.initialize().catch(
|
|
721
|
+
this.initialize().catch(err => {
|
|
722
722
|
throw err;
|
|
723
723
|
});
|
|
724
724
|
const wrappedCallback = callback
|
|
@@ -770,7 +770,7 @@ class DocumentServiceClient {
|
|
|
770
770
|
this._gaxModule.routingHeader.fromParams({
|
|
771
771
|
parent: request.parent ?? '',
|
|
772
772
|
});
|
|
773
|
-
this.initialize().catch(
|
|
773
|
+
this.initialize().catch(err => {
|
|
774
774
|
throw err;
|
|
775
775
|
});
|
|
776
776
|
const wrappedCallback = callback
|
|
@@ -822,7 +822,7 @@ class DocumentServiceClient {
|
|
|
822
822
|
this._gaxModule.routingHeader.fromParams({
|
|
823
823
|
parent: request.parent ?? '',
|
|
824
824
|
});
|
|
825
|
-
this.initialize().catch(
|
|
825
|
+
this.initialize().catch(err => {
|
|
826
826
|
throw err;
|
|
827
827
|
});
|
|
828
828
|
const wrappedCallback = callback
|
|
@@ -892,7 +892,7 @@ class DocumentServiceClient {
|
|
|
892
892
|
});
|
|
893
893
|
const defaultCallSettings = this._defaults['listDocuments'];
|
|
894
894
|
const callSettings = defaultCallSettings.merge(options);
|
|
895
|
-
this.initialize().catch(
|
|
895
|
+
this.initialize().catch(err => {
|
|
896
896
|
throw err;
|
|
897
897
|
});
|
|
898
898
|
this._log.info('listDocuments stream %j', request);
|
|
@@ -954,7 +954,7 @@ class DocumentServiceClient {
|
|
|
954
954
|
});
|
|
955
955
|
const defaultCallSettings = this._defaults['listDocuments'];
|
|
956
956
|
const callSettings = defaultCallSettings.merge(options);
|
|
957
|
-
this.initialize().catch(
|
|
957
|
+
this.initialize().catch(err => {
|
|
958
958
|
throw err;
|
|
959
959
|
});
|
|
960
960
|
this._log.info('listDocuments iterate %j', request);
|
|
@@ -4249,11 +4249,11 @@ class DocumentServiceClient {
|
|
|
4249
4249
|
*/
|
|
4250
4250
|
close() {
|
|
4251
4251
|
if (this.documentServiceStub && !this._terminated) {
|
|
4252
|
-
return this.documentServiceStub.then(
|
|
4252
|
+
return this.documentServiceStub.then(stub => {
|
|
4253
4253
|
this._log.info('ending gRPC channel');
|
|
4254
4254
|
this._terminated = true;
|
|
4255
4255
|
stub.close();
|
|
4256
|
-
this.locationsClient.close().catch(
|
|
4256
|
+
this.locationsClient.close().catch(err => {
|
|
4257
4257
|
throw err;
|
|
4258
4258
|
});
|
|
4259
4259
|
void this.operationsClient.close();
|
|
@@ -408,7 +408,7 @@ class EngineServiceClient {
|
|
|
408
408
|
'setIamPolicy',
|
|
409
409
|
];
|
|
410
410
|
for (const methodName of engineServiceStubMethods) {
|
|
411
|
-
const callPromise = this.engineServiceStub.then(
|
|
411
|
+
const callPromise = this.engineServiceStub.then(stub => (...args) => {
|
|
412
412
|
if (this._terminated) {
|
|
413
413
|
return Promise.reject('The client has already been closed.');
|
|
414
414
|
}
|
|
@@ -506,7 +506,7 @@ class EngineServiceClient {
|
|
|
506
506
|
this._gaxModule.routingHeader.fromParams({
|
|
507
507
|
'engine.name': request.engine.name ?? '',
|
|
508
508
|
});
|
|
509
|
-
this.initialize().catch(
|
|
509
|
+
this.initialize().catch(err => {
|
|
510
510
|
throw err;
|
|
511
511
|
});
|
|
512
512
|
this._log.info('updateEngine request %j', request);
|
|
@@ -549,7 +549,7 @@ class EngineServiceClient {
|
|
|
549
549
|
this._gaxModule.routingHeader.fromParams({
|
|
550
550
|
name: request.name ?? '',
|
|
551
551
|
});
|
|
552
|
-
this.initialize().catch(
|
|
552
|
+
this.initialize().catch(err => {
|
|
553
553
|
throw err;
|
|
554
554
|
});
|
|
555
555
|
this._log.info('getEngine request %j', request);
|
|
@@ -592,7 +592,7 @@ class EngineServiceClient {
|
|
|
592
592
|
this._gaxModule.routingHeader.fromParams({
|
|
593
593
|
name: request.name ?? '',
|
|
594
594
|
});
|
|
595
|
-
this.initialize().catch(
|
|
595
|
+
this.initialize().catch(err => {
|
|
596
596
|
throw err;
|
|
597
597
|
});
|
|
598
598
|
this._log.info('pauseEngine request %j', request);
|
|
@@ -635,7 +635,7 @@ class EngineServiceClient {
|
|
|
635
635
|
this._gaxModule.routingHeader.fromParams({
|
|
636
636
|
name: request.name ?? '',
|
|
637
637
|
});
|
|
638
|
-
this.initialize().catch(
|
|
638
|
+
this.initialize().catch(err => {
|
|
639
639
|
throw err;
|
|
640
640
|
});
|
|
641
641
|
this._log.info('resumeEngine request %j', request);
|
|
@@ -678,7 +678,7 @@ class EngineServiceClient {
|
|
|
678
678
|
this._gaxModule.routingHeader.fromParams({
|
|
679
679
|
resource: request.resource ?? '',
|
|
680
680
|
});
|
|
681
|
-
this.initialize().catch(
|
|
681
|
+
this.initialize().catch(err => {
|
|
682
682
|
throw err;
|
|
683
683
|
});
|
|
684
684
|
this._log.info('getIamPolicy request %j', request);
|
|
@@ -721,7 +721,7 @@ class EngineServiceClient {
|
|
|
721
721
|
this._gaxModule.routingHeader.fromParams({
|
|
722
722
|
resource: request.resource ?? '',
|
|
723
723
|
});
|
|
724
|
-
this.initialize().catch(
|
|
724
|
+
this.initialize().catch(err => {
|
|
725
725
|
throw err;
|
|
726
726
|
});
|
|
727
727
|
this._log.info('setIamPolicy request %j', request);
|
|
@@ -764,7 +764,7 @@ class EngineServiceClient {
|
|
|
764
764
|
this._gaxModule.routingHeader.fromParams({
|
|
765
765
|
parent: request.parent ?? '',
|
|
766
766
|
});
|
|
767
|
-
this.initialize().catch(
|
|
767
|
+
this.initialize().catch(err => {
|
|
768
768
|
throw err;
|
|
769
769
|
});
|
|
770
770
|
const wrappedCallback = callback
|
|
@@ -816,7 +816,7 @@ class EngineServiceClient {
|
|
|
816
816
|
this._gaxModule.routingHeader.fromParams({
|
|
817
817
|
name: request.name ?? '',
|
|
818
818
|
});
|
|
819
|
-
this.initialize().catch(
|
|
819
|
+
this.initialize().catch(err => {
|
|
820
820
|
throw err;
|
|
821
821
|
});
|
|
822
822
|
const wrappedCallback = callback
|
|
@@ -868,7 +868,7 @@ class EngineServiceClient {
|
|
|
868
868
|
this._gaxModule.routingHeader.fromParams({
|
|
869
869
|
name: request.name ?? '',
|
|
870
870
|
});
|
|
871
|
-
this.initialize().catch(
|
|
871
|
+
this.initialize().catch(err => {
|
|
872
872
|
throw err;
|
|
873
873
|
});
|
|
874
874
|
const wrappedCallback = callback
|
|
@@ -920,7 +920,7 @@ class EngineServiceClient {
|
|
|
920
920
|
this._gaxModule.routingHeader.fromParams({
|
|
921
921
|
parent: request.parent ?? '',
|
|
922
922
|
});
|
|
923
|
-
this.initialize().catch(
|
|
923
|
+
this.initialize().catch(err => {
|
|
924
924
|
throw err;
|
|
925
925
|
});
|
|
926
926
|
const wrappedCallback = callback
|
|
@@ -973,7 +973,7 @@ class EngineServiceClient {
|
|
|
973
973
|
});
|
|
974
974
|
const defaultCallSettings = this._defaults['listEngines'];
|
|
975
975
|
const callSettings = defaultCallSettings.merge(options);
|
|
976
|
-
this.initialize().catch(
|
|
976
|
+
this.initialize().catch(err => {
|
|
977
977
|
throw err;
|
|
978
978
|
});
|
|
979
979
|
this._log.info('listEngines stream %j', request);
|
|
@@ -1018,7 +1018,7 @@ class EngineServiceClient {
|
|
|
1018
1018
|
});
|
|
1019
1019
|
const defaultCallSettings = this._defaults['listEngines'];
|
|
1020
1020
|
const callSettings = defaultCallSettings.merge(options);
|
|
1021
|
-
this.initialize().catch(
|
|
1021
|
+
this.initialize().catch(err => {
|
|
1022
1022
|
throw err;
|
|
1023
1023
|
});
|
|
1024
1024
|
this._log.info('listEngines iterate %j', request);
|
|
@@ -4235,11 +4235,11 @@ class EngineServiceClient {
|
|
|
4235
4235
|
*/
|
|
4236
4236
|
close() {
|
|
4237
4237
|
if (this.engineServiceStub && !this._terminated) {
|
|
4238
|
-
return this.engineServiceStub.then(
|
|
4238
|
+
return this.engineServiceStub.then(stub => {
|
|
4239
4239
|
this._log.info('ending gRPC channel');
|
|
4240
4240
|
this._terminated = true;
|
|
4241
4241
|
stub.close();
|
|
4242
|
-
this.locationsClient.close().catch(
|
|
4242
|
+
this.locationsClient.close().catch(err => {
|
|
4243
4243
|
throw err;
|
|
4244
4244
|
});
|
|
4245
4245
|
void this.operationsClient.close();
|
|
@@ -397,7 +397,7 @@ class EvaluationServiceClient {
|
|
|
397
397
|
'listEvaluationResults',
|
|
398
398
|
];
|
|
399
399
|
for (const methodName of evaluationServiceStubMethods) {
|
|
400
|
-
const callPromise = this.evaluationServiceStub.then(
|
|
400
|
+
const callPromise = this.evaluationServiceStub.then(stub => (...args) => {
|
|
401
401
|
if (this._terminated) {
|
|
402
402
|
return Promise.reject('The client has already been closed.');
|
|
403
403
|
}
|
|
@@ -496,7 +496,7 @@ class EvaluationServiceClient {
|
|
|
496
496
|
this._gaxModule.routingHeader.fromParams({
|
|
497
497
|
name: request.name ?? '',
|
|
498
498
|
});
|
|
499
|
-
this.initialize().catch(
|
|
499
|
+
this.initialize().catch(err => {
|
|
500
500
|
throw err;
|
|
501
501
|
});
|
|
502
502
|
this._log.info('getEvaluation request %j', request);
|
|
@@ -539,7 +539,7 @@ class EvaluationServiceClient {
|
|
|
539
539
|
this._gaxModule.routingHeader.fromParams({
|
|
540
540
|
parent: request.parent ?? '',
|
|
541
541
|
});
|
|
542
|
-
this.initialize().catch(
|
|
542
|
+
this.initialize().catch(err => {
|
|
543
543
|
throw err;
|
|
544
544
|
});
|
|
545
545
|
const wrappedCallback = callback
|
|
@@ -591,7 +591,7 @@ class EvaluationServiceClient {
|
|
|
591
591
|
this._gaxModule.routingHeader.fromParams({
|
|
592
592
|
parent: request.parent ?? '',
|
|
593
593
|
});
|
|
594
|
-
this.initialize().catch(
|
|
594
|
+
this.initialize().catch(err => {
|
|
595
595
|
throw err;
|
|
596
596
|
});
|
|
597
597
|
const wrappedCallback = callback
|
|
@@ -660,7 +660,7 @@ class EvaluationServiceClient {
|
|
|
660
660
|
});
|
|
661
661
|
const defaultCallSettings = this._defaults['listEvaluations'];
|
|
662
662
|
const callSettings = defaultCallSettings.merge(options);
|
|
663
|
-
this.initialize().catch(
|
|
663
|
+
this.initialize().catch(err => {
|
|
664
664
|
throw err;
|
|
665
665
|
});
|
|
666
666
|
this._log.info('listEvaluations stream %j', request);
|
|
@@ -721,7 +721,7 @@ class EvaluationServiceClient {
|
|
|
721
721
|
});
|
|
722
722
|
const defaultCallSettings = this._defaults['listEvaluations'];
|
|
723
723
|
const callSettings = defaultCallSettings.merge(options);
|
|
724
|
-
this.initialize().catch(
|
|
724
|
+
this.initialize().catch(err => {
|
|
725
725
|
throw err;
|
|
726
726
|
});
|
|
727
727
|
this._log.info('listEvaluations iterate %j', request);
|
|
@@ -744,7 +744,7 @@ class EvaluationServiceClient {
|
|
|
744
744
|
this._gaxModule.routingHeader.fromParams({
|
|
745
745
|
evaluation: request.evaluation ?? '',
|
|
746
746
|
});
|
|
747
|
-
this.initialize().catch(
|
|
747
|
+
this.initialize().catch(err => {
|
|
748
748
|
throw err;
|
|
749
749
|
});
|
|
750
750
|
const wrappedCallback = callback
|
|
@@ -813,7 +813,7 @@ class EvaluationServiceClient {
|
|
|
813
813
|
});
|
|
814
814
|
const defaultCallSettings = this._defaults['listEvaluationResults'];
|
|
815
815
|
const callSettings = defaultCallSettings.merge(options);
|
|
816
|
-
this.initialize().catch(
|
|
816
|
+
this.initialize().catch(err => {
|
|
817
817
|
throw err;
|
|
818
818
|
});
|
|
819
819
|
this._log.info('listEvaluationResults stream %j', request);
|
|
@@ -874,7 +874,7 @@ class EvaluationServiceClient {
|
|
|
874
874
|
});
|
|
875
875
|
const defaultCallSettings = this._defaults['listEvaluationResults'];
|
|
876
876
|
const callSettings = defaultCallSettings.merge(options);
|
|
877
|
-
this.initialize().catch(
|
|
877
|
+
this.initialize().catch(err => {
|
|
878
878
|
throw err;
|
|
879
879
|
});
|
|
880
880
|
this._log.info('listEvaluationResults iterate %j', request);
|
|
@@ -4076,11 +4076,11 @@ class EvaluationServiceClient {
|
|
|
4076
4076
|
*/
|
|
4077
4077
|
close() {
|
|
4078
4078
|
if (this.evaluationServiceStub && !this._terminated) {
|
|
4079
|
-
return this.evaluationServiceStub.then(
|
|
4079
|
+
return this.evaluationServiceStub.then(stub => {
|
|
4080
4080
|
this._log.info('ending gRPC channel');
|
|
4081
4081
|
this._terminated = true;
|
|
4082
4082
|
stub.close();
|
|
4083
|
-
this.locationsClient.close().catch(
|
|
4083
|
+
this.locationsClient.close().catch(err => {
|
|
4084
4084
|
throw err;
|
|
4085
4085
|
});
|
|
4086
4086
|
void this.operationsClient.close();
|
|
@@ -265,7 +265,7 @@ class GroundedGenerationServiceClient {
|
|
|
265
265
|
'checkGrounding',
|
|
266
266
|
];
|
|
267
267
|
for (const methodName of groundedGenerationServiceStubMethods) {
|
|
268
|
-
const callPromise = this.groundedGenerationServiceStub.then(
|
|
268
|
+
const callPromise = this.groundedGenerationServiceStub.then(stub => (...args) => {
|
|
269
269
|
if (this._terminated) {
|
|
270
270
|
if (methodName in this.descriptors.stream) {
|
|
271
271
|
const stream = new stream_1.PassThrough({ objectMode: true });
|
|
@@ -368,7 +368,7 @@ class GroundedGenerationServiceClient {
|
|
|
368
368
|
this._gaxModule.routingHeader.fromParams({
|
|
369
369
|
location: request.location ?? '',
|
|
370
370
|
});
|
|
371
|
-
this.initialize().catch(
|
|
371
|
+
this.initialize().catch(err => {
|
|
372
372
|
throw err;
|
|
373
373
|
});
|
|
374
374
|
this._log.info('generateGroundedContent request %j', request);
|
|
@@ -411,7 +411,7 @@ class GroundedGenerationServiceClient {
|
|
|
411
411
|
this._gaxModule.routingHeader.fromParams({
|
|
412
412
|
grounding_config: request.groundingConfig ?? '',
|
|
413
413
|
});
|
|
414
|
-
this.initialize().catch(
|
|
414
|
+
this.initialize().catch(err => {
|
|
415
415
|
throw err;
|
|
416
416
|
});
|
|
417
417
|
this._log.info('checkGrounding request %j', request);
|
|
@@ -452,7 +452,7 @@ class GroundedGenerationServiceClient {
|
|
|
452
452
|
* region_tag:discoveryengine_v1beta_generated_GroundedGenerationService_StreamGenerateGroundedContent_async
|
|
453
453
|
*/
|
|
454
454
|
streamGenerateGroundedContent(options) {
|
|
455
|
-
this.initialize().catch(
|
|
455
|
+
this.initialize().catch(err => {
|
|
456
456
|
throw err;
|
|
457
457
|
});
|
|
458
458
|
this._log.info('streamGenerateGroundedContent stream %j', options);
|
|
@@ -3474,11 +3474,11 @@ class GroundedGenerationServiceClient {
|
|
|
3474
3474
|
*/
|
|
3475
3475
|
close() {
|
|
3476
3476
|
if (this.groundedGenerationServiceStub && !this._terminated) {
|
|
3477
|
-
return this.groundedGenerationServiceStub.then(
|
|
3477
|
+
return this.groundedGenerationServiceStub.then(stub => {
|
|
3478
3478
|
this._log.info('ending gRPC channel');
|
|
3479
3479
|
this._terminated = true;
|
|
3480
3480
|
stub.close();
|
|
3481
|
-
this.locationsClient.close().catch(
|
|
3481
|
+
this.locationsClient.close().catch(err => {
|
|
3482
3482
|
throw err;
|
|
3483
3483
|
});
|
|
3484
3484
|
});
|