google-cloud-vision_ai-v1 0.2.0 → 0.4.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.
- checksums.yaml +4 -4
- data/README.md +31 -21
- data/lib/google/cloud/vision_ai/v1/app_platform/client.rb +57 -27
- data/lib/google/cloud/vision_ai/v1/app_platform/operations.rb +19 -15
- data/lib/google/cloud/vision_ai/v1/app_platform/rest/client.rb +53 -27
- data/lib/google/cloud/vision_ai/v1/app_platform/rest/operations.rb +50 -38
- data/lib/google/cloud/vision_ai/v1/app_platform/rest/service_stub.rb +222 -158
- data/lib/google/cloud/vision_ai/v1/health_check_service/client.rb +36 -2
- data/lib/google/cloud/vision_ai/v1/health_check_service/rest/client.rb +36 -2
- data/lib/google/cloud/vision_ai/v1/health_check_service/rest/service_stub.rb +22 -8
- data/lib/google/cloud/vision_ai/v1/live_video_analytics/client.rb +50 -19
- data/lib/google/cloud/vision_ai/v1/live_video_analytics/operations.rb +19 -15
- data/lib/google/cloud/vision_ai/v1/live_video_analytics/rest/client.rb +47 -19
- data/lib/google/cloud/vision_ai/v1/live_video_analytics/rest/operations.rb +50 -38
- data/lib/google/cloud/vision_ai/v1/live_video_analytics/rest/service_stub.rb +158 -110
- data/lib/google/cloud/vision_ai/v1/streaming_service/client.rb +36 -7
- data/lib/google/cloud/vision_ai/v1/streaming_service/rest/client.rb +36 -4
- data/lib/google/cloud/vision_ai/v1/streaming_service/rest/service_stub.rb +38 -20
- data/lib/google/cloud/vision_ai/v1/streams_service/client.rb +54 -24
- data/lib/google/cloud/vision_ai/v1/streams_service/operations.rb +19 -15
- data/lib/google/cloud/vision_ai/v1/streams_service/rest/client.rb +50 -24
- data/lib/google/cloud/vision_ai/v1/streams_service/rest/operations.rb +50 -38
- data/lib/google/cloud/vision_ai/v1/streams_service/rest/service_stub.rb +198 -140
- data/lib/google/cloud/vision_ai/v1/version.rb +1 -1
- data/lib/google/cloud/vision_ai/v1/warehouse/client.rb +71 -64
- data/lib/google/cloud/vision_ai/v1/warehouse/operations.rb +19 -15
- data/lib/google/cloud/vision_ai/v1/warehouse/rest/client.rb +70 -63
- data/lib/google/cloud/vision_ai/v1/warehouse/rest/operations.rb +50 -38
- data/lib/google/cloud/vision_ai/v1/warehouse/rest/service_stub.rb +510 -374
- data/proto_docs/google/api/client.rb +39 -0
- data/proto_docs/google/cloud/visionai/v1/annotations.rb +4 -0
- data/proto_docs/google/cloud/visionai/v1/lva.rb +8 -0
- data/proto_docs/google/cloud/visionai/v1/platform.rb +44 -0
- data/proto_docs/google/cloud/visionai/v1/streaming_resources.rb +4 -0
- data/proto_docs/google/cloud/visionai/v1/streaming_service.rb +32 -0
- data/proto_docs/google/cloud/visionai/v1/warehouse.rb +64 -0
- data/proto_docs/google/longrunning/operations.rb +23 -14
- data/proto_docs/google/protobuf/struct.rb +12 -0
- data/proto_docs/google/type/datetime.rb +4 -0
- metadata +6 -9
@@ -196,14 +196,26 @@ module Google
|
|
196
196
|
universe_domain: @config.universe_domain,
|
197
197
|
channel_args: @config.channel_args,
|
198
198
|
interceptors: @config.interceptors,
|
199
|
-
channel_pool_config: @config.channel_pool
|
199
|
+
channel_pool_config: @config.channel_pool,
|
200
|
+
logger: @config.logger
|
200
201
|
)
|
201
202
|
|
203
|
+
@warehouse_stub.stub_logger&.info do |entry|
|
204
|
+
entry.set_system_name
|
205
|
+
entry.set_service
|
206
|
+
entry.message = "Created client for #{entry.service}"
|
207
|
+
entry.set_credentials_fields credentials
|
208
|
+
entry.set "customEndpoint", @config.endpoint if @config.endpoint
|
209
|
+
entry.set "defaultTimeout", @config.timeout if @config.timeout
|
210
|
+
entry.set "quotaProject", @quota_project_id if @quota_project_id
|
211
|
+
end
|
212
|
+
|
202
213
|
@location_client = Google::Cloud::Location::Locations::Client.new do |config|
|
203
214
|
config.credentials = credentials
|
204
215
|
config.quota_project = @quota_project_id
|
205
216
|
config.endpoint = @warehouse_stub.endpoint
|
206
217
|
config.universe_domain = @warehouse_stub.universe_domain
|
218
|
+
config.logger = @warehouse_stub.logger if config.respond_to? :logger=
|
207
219
|
end
|
208
220
|
|
209
221
|
@iam_policy_client = Google::Iam::V1::IAMPolicy::Client.new do |config|
|
@@ -211,6 +223,7 @@ module Google
|
|
211
223
|
config.quota_project = @quota_project_id
|
212
224
|
config.endpoint = @warehouse_stub.endpoint
|
213
225
|
config.universe_domain = @warehouse_stub.universe_domain
|
226
|
+
config.logger = @warehouse_stub.logger if config.respond_to? :logger=
|
214
227
|
end
|
215
228
|
end
|
216
229
|
|
@@ -235,6 +248,15 @@ module Google
|
|
235
248
|
#
|
236
249
|
attr_reader :iam_policy_client
|
237
250
|
|
251
|
+
##
|
252
|
+
# The logger used for request/response debug logging.
|
253
|
+
#
|
254
|
+
# @return [Logger]
|
255
|
+
#
|
256
|
+
def logger
|
257
|
+
@warehouse_stub.logger
|
258
|
+
end
|
259
|
+
|
238
260
|
# Service calls
|
239
261
|
|
240
262
|
##
|
@@ -329,7 +351,6 @@ module Google
|
|
329
351
|
|
330
352
|
@warehouse_stub.call_rpc :create_asset, request, options: options do |response, operation|
|
331
353
|
yield response, operation if block_given?
|
332
|
-
return response
|
333
354
|
end
|
334
355
|
rescue ::GRPC::BadStatus => e
|
335
356
|
raise ::Google::Cloud::Error.from_error(e)
|
@@ -421,7 +442,6 @@ module Google
|
|
421
442
|
|
422
443
|
@warehouse_stub.call_rpc :update_asset, request, options: options do |response, operation|
|
423
444
|
yield response, operation if block_given?
|
424
|
-
return response
|
425
445
|
end
|
426
446
|
rescue ::GRPC::BadStatus => e
|
427
447
|
raise ::Google::Cloud::Error.from_error(e)
|
@@ -509,7 +529,6 @@ module Google
|
|
509
529
|
|
510
530
|
@warehouse_stub.call_rpc :get_asset, request, options: options do |response, operation|
|
511
531
|
yield response, operation if block_given?
|
512
|
-
return response
|
513
532
|
end
|
514
533
|
rescue ::GRPC::BadStatus => e
|
515
534
|
raise ::Google::Cloud::Error.from_error(e)
|
@@ -618,7 +637,7 @@ module Google
|
|
618
637
|
@warehouse_stub.call_rpc :list_assets, request, options: options do |response, operation|
|
619
638
|
response = ::Gapic::PagedEnumerable.new @warehouse_stub, :list_assets, request, response, operation, options
|
620
639
|
yield response, operation if block_given?
|
621
|
-
|
640
|
+
throw :response, response
|
622
641
|
end
|
623
642
|
rescue ::GRPC::BadStatus => e
|
624
643
|
raise ::Google::Cloud::Error.from_error(e)
|
@@ -714,7 +733,7 @@ module Google
|
|
714
733
|
@warehouse_stub.call_rpc :delete_asset, request, options: options do |response, operation|
|
715
734
|
response = ::Gapic::Operation.new response, @operations_client, options: options
|
716
735
|
yield response, operation if block_given?
|
717
|
-
|
736
|
+
throw :response, response
|
718
737
|
end
|
719
738
|
rescue ::GRPC::BadStatus => e
|
720
739
|
raise ::Google::Cloud::Error.from_error(e)
|
@@ -821,7 +840,7 @@ module Google
|
|
821
840
|
@warehouse_stub.call_rpc :upload_asset, request, options: options do |response, operation|
|
822
841
|
response = ::Gapic::Operation.new response, @operations_client, options: options
|
823
842
|
yield response, operation if block_given?
|
824
|
-
|
843
|
+
throw :response, response
|
825
844
|
end
|
826
845
|
rescue ::GRPC::BadStatus => e
|
827
846
|
raise ::Google::Cloud::Error.from_error(e)
|
@@ -911,7 +930,6 @@ module Google
|
|
911
930
|
|
912
931
|
@warehouse_stub.call_rpc :generate_retrieval_url, request, options: options do |response, operation|
|
913
932
|
yield response, operation if block_given?
|
914
|
-
return response
|
915
933
|
end
|
916
934
|
rescue ::GRPC::BadStatus => e
|
917
935
|
raise ::Google::Cloud::Error.from_error(e)
|
@@ -1007,7 +1025,7 @@ module Google
|
|
1007
1025
|
@warehouse_stub.call_rpc :analyze_asset, request, options: options do |response, operation|
|
1008
1026
|
response = ::Gapic::Operation.new response, @operations_client, options: options
|
1009
1027
|
yield response, operation if block_given?
|
1010
|
-
|
1028
|
+
throw :response, response
|
1011
1029
|
end
|
1012
1030
|
rescue ::GRPC::BadStatus => e
|
1013
1031
|
raise ::Google::Cloud::Error.from_error(e)
|
@@ -1108,7 +1126,7 @@ module Google
|
|
1108
1126
|
@warehouse_stub.call_rpc :index_asset, request, options: options do |response, operation|
|
1109
1127
|
response = ::Gapic::Operation.new response, @operations_client, options: options
|
1110
1128
|
yield response, operation if block_given?
|
1111
|
-
|
1129
|
+
throw :response, response
|
1112
1130
|
end
|
1113
1131
|
rescue ::GRPC::BadStatus => e
|
1114
1132
|
raise ::Google::Cloud::Error.from_error(e)
|
@@ -1209,7 +1227,7 @@ module Google
|
|
1209
1227
|
@warehouse_stub.call_rpc :remove_index_asset, request, options: options do |response, operation|
|
1210
1228
|
response = ::Gapic::Operation.new response, @operations_client, options: options
|
1211
1229
|
yield response, operation if block_given?
|
1212
|
-
|
1230
|
+
throw :response, response
|
1213
1231
|
end
|
1214
1232
|
rescue ::GRPC::BadStatus => e
|
1215
1233
|
raise ::Google::Cloud::Error.from_error(e)
|
@@ -1318,7 +1336,7 @@ module Google
|
|
1318
1336
|
@warehouse_stub.call_rpc :view_indexed_assets, request, options: options do |response, operation|
|
1319
1337
|
response = ::Gapic::PagedEnumerable.new @warehouse_stub, :view_indexed_assets, request, response, operation, options
|
1320
1338
|
yield response, operation if block_given?
|
1321
|
-
|
1339
|
+
throw :response, response
|
1322
1340
|
end
|
1323
1341
|
rescue ::GRPC::BadStatus => e
|
1324
1342
|
raise ::Google::Cloud::Error.from_error(e)
|
@@ -1424,7 +1442,7 @@ module Google
|
|
1424
1442
|
@warehouse_stub.call_rpc :create_index, request, options: options do |response, operation|
|
1425
1443
|
response = ::Gapic::Operation.new response, @operations_client, options: options
|
1426
1444
|
yield response, operation if block_given?
|
1427
|
-
|
1445
|
+
throw :response, response
|
1428
1446
|
end
|
1429
1447
|
rescue ::GRPC::BadStatus => e
|
1430
1448
|
raise ::Google::Cloud::Error.from_error(e)
|
@@ -1527,7 +1545,7 @@ module Google
|
|
1527
1545
|
@warehouse_stub.call_rpc :update_index, request, options: options do |response, operation|
|
1528
1546
|
response = ::Gapic::Operation.new response, @operations_client, options: options
|
1529
1547
|
yield response, operation if block_given?
|
1530
|
-
|
1548
|
+
throw :response, response
|
1531
1549
|
end
|
1532
1550
|
rescue ::GRPC::BadStatus => e
|
1533
1551
|
raise ::Google::Cloud::Error.from_error(e)
|
@@ -1615,7 +1633,6 @@ module Google
|
|
1615
1633
|
|
1616
1634
|
@warehouse_stub.call_rpc :get_index, request, options: options do |response, operation|
|
1617
1635
|
yield response, operation if block_given?
|
1618
|
-
return response
|
1619
1636
|
end
|
1620
1637
|
rescue ::GRPC::BadStatus => e
|
1621
1638
|
raise ::Google::Cloud::Error.from_error(e)
|
@@ -1719,7 +1736,7 @@ module Google
|
|
1719
1736
|
@warehouse_stub.call_rpc :list_indexes, request, options: options do |response, operation|
|
1720
1737
|
response = ::Gapic::PagedEnumerable.new @warehouse_stub, :list_indexes, request, response, operation, options
|
1721
1738
|
yield response, operation if block_given?
|
1722
|
-
|
1739
|
+
throw :response, response
|
1723
1740
|
end
|
1724
1741
|
rescue ::GRPC::BadStatus => e
|
1725
1742
|
raise ::Google::Cloud::Error.from_error(e)
|
@@ -1816,7 +1833,7 @@ module Google
|
|
1816
1833
|
@warehouse_stub.call_rpc :delete_index, request, options: options do |response, operation|
|
1817
1834
|
response = ::Gapic::Operation.new response, @operations_client, options: options
|
1818
1835
|
yield response, operation if block_given?
|
1819
|
-
|
1836
|
+
throw :response, response
|
1820
1837
|
end
|
1821
1838
|
rescue ::GRPC::BadStatus => e
|
1822
1839
|
raise ::Google::Cloud::Error.from_error(e)
|
@@ -1912,7 +1929,7 @@ module Google
|
|
1912
1929
|
@warehouse_stub.call_rpc :create_corpus, request, options: options do |response, operation|
|
1913
1930
|
response = ::Gapic::Operation.new response, @operations_client, options: options
|
1914
1931
|
yield response, operation if block_given?
|
1915
|
-
|
1932
|
+
throw :response, response
|
1916
1933
|
end
|
1917
1934
|
rescue ::GRPC::BadStatus => e
|
1918
1935
|
raise ::Google::Cloud::Error.from_error(e)
|
@@ -1998,7 +2015,6 @@ module Google
|
|
1998
2015
|
|
1999
2016
|
@warehouse_stub.call_rpc :get_corpus, request, options: options do |response, operation|
|
2000
2017
|
yield response, operation if block_given?
|
2001
|
-
return response
|
2002
2018
|
end
|
2003
2019
|
rescue ::GRPC::BadStatus => e
|
2004
2020
|
raise ::Google::Cloud::Error.from_error(e)
|
@@ -2086,7 +2102,6 @@ module Google
|
|
2086
2102
|
|
2087
2103
|
@warehouse_stub.call_rpc :update_corpus, request, options: options do |response, operation|
|
2088
2104
|
yield response, operation if block_given?
|
2089
|
-
return response
|
2090
2105
|
end
|
2091
2106
|
rescue ::GRPC::BadStatus => e
|
2092
2107
|
raise ::Google::Cloud::Error.from_error(e)
|
@@ -2195,7 +2210,7 @@ module Google
|
|
2195
2210
|
@warehouse_stub.call_rpc :list_corpora, request, options: options do |response, operation|
|
2196
2211
|
response = ::Gapic::PagedEnumerable.new @warehouse_stub, :list_corpora, request, response, operation, options
|
2197
2212
|
yield response, operation if block_given?
|
2198
|
-
|
2213
|
+
throw :response, response
|
2199
2214
|
end
|
2200
2215
|
rescue ::GRPC::BadStatus => e
|
2201
2216
|
raise ::Google::Cloud::Error.from_error(e)
|
@@ -2282,7 +2297,6 @@ module Google
|
|
2282
2297
|
|
2283
2298
|
@warehouse_stub.call_rpc :delete_corpus, request, options: options do |response, operation|
|
2284
2299
|
yield response, operation if block_given?
|
2285
|
-
return response
|
2286
2300
|
end
|
2287
2301
|
rescue ::GRPC::BadStatus => e
|
2288
2302
|
raise ::Google::Cloud::Error.from_error(e)
|
@@ -2378,7 +2392,7 @@ module Google
|
|
2378
2392
|
@warehouse_stub.call_rpc :analyze_corpus, request, options: options do |response, operation|
|
2379
2393
|
response = ::Gapic::Operation.new response, @operations_client, options: options
|
2380
2394
|
yield response, operation if block_given?
|
2381
|
-
|
2395
|
+
throw :response, response
|
2382
2396
|
end
|
2383
2397
|
rescue ::GRPC::BadStatus => e
|
2384
2398
|
raise ::Google::Cloud::Error.from_error(e)
|
@@ -2468,7 +2482,6 @@ module Google
|
|
2468
2482
|
|
2469
2483
|
@warehouse_stub.call_rpc :create_data_schema, request, options: options do |response, operation|
|
2470
2484
|
yield response, operation if block_given?
|
2471
|
-
return response
|
2472
2485
|
end
|
2473
2486
|
rescue ::GRPC::BadStatus => e
|
2474
2487
|
raise ::Google::Cloud::Error.from_error(e)
|
@@ -2558,7 +2571,6 @@ module Google
|
|
2558
2571
|
|
2559
2572
|
@warehouse_stub.call_rpc :update_data_schema, request, options: options do |response, operation|
|
2560
2573
|
yield response, operation if block_given?
|
2561
|
-
return response
|
2562
2574
|
end
|
2563
2575
|
rescue ::GRPC::BadStatus => e
|
2564
2576
|
raise ::Google::Cloud::Error.from_error(e)
|
@@ -2646,7 +2658,6 @@ module Google
|
|
2646
2658
|
|
2647
2659
|
@warehouse_stub.call_rpc :get_data_schema, request, options: options do |response, operation|
|
2648
2660
|
yield response, operation if block_given?
|
2649
|
-
return response
|
2650
2661
|
end
|
2651
2662
|
rescue ::GRPC::BadStatus => e
|
2652
2663
|
raise ::Google::Cloud::Error.from_error(e)
|
@@ -2734,7 +2745,6 @@ module Google
|
|
2734
2745
|
|
2735
2746
|
@warehouse_stub.call_rpc :delete_data_schema, request, options: options do |response, operation|
|
2736
2747
|
yield response, operation if block_given?
|
2737
|
-
return response
|
2738
2748
|
end
|
2739
2749
|
rescue ::GRPC::BadStatus => e
|
2740
2750
|
raise ::Google::Cloud::Error.from_error(e)
|
@@ -2837,7 +2847,7 @@ module Google
|
|
2837
2847
|
@warehouse_stub.call_rpc :list_data_schemas, request, options: options do |response, operation|
|
2838
2848
|
response = ::Gapic::PagedEnumerable.new @warehouse_stub, :list_data_schemas, request, response, operation, options
|
2839
2849
|
yield response, operation if block_given?
|
2840
|
-
|
2850
|
+
throw :response, response
|
2841
2851
|
end
|
2842
2852
|
rescue ::GRPC::BadStatus => e
|
2843
2853
|
raise ::Google::Cloud::Error.from_error(e)
|
@@ -2935,7 +2945,6 @@ module Google
|
|
2935
2945
|
|
2936
2946
|
@warehouse_stub.call_rpc :create_annotation, request, options: options do |response, operation|
|
2937
2947
|
yield response, operation if block_given?
|
2938
|
-
return response
|
2939
2948
|
end
|
2940
2949
|
rescue ::GRPC::BadStatus => e
|
2941
2950
|
raise ::Google::Cloud::Error.from_error(e)
|
@@ -3023,7 +3032,6 @@ module Google
|
|
3023
3032
|
|
3024
3033
|
@warehouse_stub.call_rpc :get_annotation, request, options: options do |response, operation|
|
3025
3034
|
yield response, operation if block_given?
|
3026
|
-
return response
|
3027
3035
|
end
|
3028
3036
|
rescue ::GRPC::BadStatus => e
|
3029
3037
|
raise ::Google::Cloud::Error.from_error(e)
|
@@ -3142,7 +3150,7 @@ module Google
|
|
3142
3150
|
@warehouse_stub.call_rpc :list_annotations, request, options: options do |response, operation|
|
3143
3151
|
response = ::Gapic::PagedEnumerable.new @warehouse_stub, :list_annotations, request, response, operation, options
|
3144
3152
|
yield response, operation if block_given?
|
3145
|
-
|
3153
|
+
throw :response, response
|
3146
3154
|
end
|
3147
3155
|
rescue ::GRPC::BadStatus => e
|
3148
3156
|
raise ::Google::Cloud::Error.from_error(e)
|
@@ -3233,7 +3241,6 @@ module Google
|
|
3233
3241
|
|
3234
3242
|
@warehouse_stub.call_rpc :update_annotation, request, options: options do |response, operation|
|
3235
3243
|
yield response, operation if block_given?
|
3236
|
-
return response
|
3237
3244
|
end
|
3238
3245
|
rescue ::GRPC::BadStatus => e
|
3239
3246
|
raise ::Google::Cloud::Error.from_error(e)
|
@@ -3321,7 +3328,6 @@ module Google
|
|
3321
3328
|
|
3322
3329
|
@warehouse_stub.call_rpc :delete_annotation, request, options: options do |response, operation|
|
3323
3330
|
yield response, operation if block_given?
|
3324
|
-
return response
|
3325
3331
|
end
|
3326
3332
|
rescue ::GRPC::BadStatus => e
|
3327
3333
|
raise ::Google::Cloud::Error.from_error(e)
|
@@ -3403,7 +3409,6 @@ module Google
|
|
3403
3409
|
|
3404
3410
|
@warehouse_stub.call_rpc :ingest_asset, request, options: options do |response, operation|
|
3405
3411
|
yield response, operation if block_given?
|
3406
|
-
return response
|
3407
3412
|
end
|
3408
3413
|
rescue ::GRPC::BadStatus => e
|
3409
3414
|
raise ::Google::Cloud::Error.from_error(e)
|
@@ -3498,7 +3503,6 @@ module Google
|
|
3498
3503
|
|
3499
3504
|
@warehouse_stub.call_rpc :clip_asset, request, options: options do |response, operation|
|
3500
3505
|
yield response, operation if block_given?
|
3501
|
-
return response
|
3502
3506
|
end
|
3503
3507
|
rescue ::GRPC::BadStatus => e
|
3504
3508
|
raise ::Google::Cloud::Error.from_error(e)
|
@@ -3594,7 +3598,6 @@ module Google
|
|
3594
3598
|
|
3595
3599
|
@warehouse_stub.call_rpc :generate_hls_uri, request, options: options do |response, operation|
|
3596
3600
|
yield response, operation if block_given?
|
3597
|
-
return response
|
3598
3601
|
end
|
3599
3602
|
rescue ::GRPC::BadStatus => e
|
3600
3603
|
raise ::Google::Cloud::Error.from_error(e)
|
@@ -3697,7 +3700,7 @@ module Google
|
|
3697
3700
|
@warehouse_stub.call_rpc :import_assets, request, options: options do |response, operation|
|
3698
3701
|
response = ::Gapic::Operation.new response, @operations_client, options: options
|
3699
3702
|
yield response, operation if block_given?
|
3700
|
-
|
3703
|
+
throw :response, response
|
3701
3704
|
end
|
3702
3705
|
rescue ::GRPC::BadStatus => e
|
3703
3706
|
raise ::Google::Cloud::Error.from_error(e)
|
@@ -3806,7 +3809,6 @@ module Google
|
|
3806
3809
|
|
3807
3810
|
@warehouse_stub.call_rpc :create_search_config, request, options: options do |response, operation|
|
3808
3811
|
yield response, operation if block_given?
|
3809
|
-
return response
|
3810
3812
|
end
|
3811
3813
|
rescue ::GRPC::BadStatus => e
|
3812
3814
|
raise ::Google::Cloud::Error.from_error(e)
|
@@ -3912,7 +3914,6 @@ module Google
|
|
3912
3914
|
|
3913
3915
|
@warehouse_stub.call_rpc :update_search_config, request, options: options do |response, operation|
|
3914
3916
|
yield response, operation if block_given?
|
3915
|
-
return response
|
3916
3917
|
end
|
3917
3918
|
rescue ::GRPC::BadStatus => e
|
3918
3919
|
raise ::Google::Cloud::Error.from_error(e)
|
@@ -4000,7 +4001,6 @@ module Google
|
|
4000
4001
|
|
4001
4002
|
@warehouse_stub.call_rpc :get_search_config, request, options: options do |response, operation|
|
4002
4003
|
yield response, operation if block_given?
|
4003
|
-
return response
|
4004
4004
|
end
|
4005
4005
|
rescue ::GRPC::BadStatus => e
|
4006
4006
|
raise ::Google::Cloud::Error.from_error(e)
|
@@ -4091,7 +4091,6 @@ module Google
|
|
4091
4091
|
|
4092
4092
|
@warehouse_stub.call_rpc :delete_search_config, request, options: options do |response, operation|
|
4093
4093
|
yield response, operation if block_given?
|
4094
|
-
return response
|
4095
4094
|
end
|
4096
4095
|
rescue ::GRPC::BadStatus => e
|
4097
4096
|
raise ::Google::Cloud::Error.from_error(e)
|
@@ -4195,7 +4194,7 @@ module Google
|
|
4195
4194
|
@warehouse_stub.call_rpc :list_search_configs, request, options: options do |response, operation|
|
4196
4195
|
response = ::Gapic::PagedEnumerable.new @warehouse_stub, :list_search_configs, request, response, operation, options
|
4197
4196
|
yield response, operation if block_given?
|
4198
|
-
|
4197
|
+
throw :response, response
|
4199
4198
|
end
|
4200
4199
|
rescue ::GRPC::BadStatus => e
|
4201
4200
|
raise ::Google::Cloud::Error.from_error(e)
|
@@ -4287,7 +4286,6 @@ module Google
|
|
4287
4286
|
|
4288
4287
|
@warehouse_stub.call_rpc :create_search_hypernym, request, options: options do |response, operation|
|
4289
4288
|
yield response, operation if block_given?
|
4290
|
-
return response
|
4291
4289
|
end
|
4292
4290
|
rescue ::GRPC::BadStatus => e
|
4293
4291
|
raise ::Google::Cloud::Error.from_error(e)
|
@@ -4379,7 +4377,6 @@ module Google
|
|
4379
4377
|
|
4380
4378
|
@warehouse_stub.call_rpc :update_search_hypernym, request, options: options do |response, operation|
|
4381
4379
|
yield response, operation if block_given?
|
4382
|
-
return response
|
4383
4380
|
end
|
4384
4381
|
rescue ::GRPC::BadStatus => e
|
4385
4382
|
raise ::Google::Cloud::Error.from_error(e)
|
@@ -4467,7 +4464,6 @@ module Google
|
|
4467
4464
|
|
4468
4465
|
@warehouse_stub.call_rpc :get_search_hypernym, request, options: options do |response, operation|
|
4469
4466
|
yield response, operation if block_given?
|
4470
|
-
return response
|
4471
4467
|
end
|
4472
4468
|
rescue ::GRPC::BadStatus => e
|
4473
4469
|
raise ::Google::Cloud::Error.from_error(e)
|
@@ -4555,7 +4551,6 @@ module Google
|
|
4555
4551
|
|
4556
4552
|
@warehouse_stub.call_rpc :delete_search_hypernym, request, options: options do |response, operation|
|
4557
4553
|
yield response, operation if block_given?
|
4558
|
-
return response
|
4559
4554
|
end
|
4560
4555
|
rescue ::GRPC::BadStatus => e
|
4561
4556
|
raise ::Google::Cloud::Error.from_error(e)
|
@@ -4659,7 +4654,7 @@ module Google
|
|
4659
4654
|
@warehouse_stub.call_rpc :list_search_hypernyms, request, options: options do |response, operation|
|
4660
4655
|
response = ::Gapic::PagedEnumerable.new @warehouse_stub, :list_search_hypernyms, request, response, operation, options
|
4661
4656
|
yield response, operation if block_given?
|
4662
|
-
|
4657
|
+
throw :response, response
|
4663
4658
|
end
|
4664
4659
|
rescue ::GRPC::BadStatus => e
|
4665
4660
|
raise ::Google::Cloud::Error.from_error(e)
|
@@ -4779,7 +4774,7 @@ module Google
|
|
4779
4774
|
@warehouse_stub.call_rpc :search_assets, request, options: options do |response, operation|
|
4780
4775
|
response = ::Gapic::PagedEnumerable.new @warehouse_stub, :search_assets, request, response, operation, options
|
4781
4776
|
yield response, operation if block_given?
|
4782
|
-
|
4777
|
+
throw :response, response
|
4783
4778
|
end
|
4784
4779
|
rescue ::GRPC::BadStatus => e
|
4785
4780
|
raise ::Google::Cloud::Error.from_error(e)
|
@@ -4805,8 +4800,12 @@ module Google
|
|
4805
4800
|
#
|
4806
4801
|
# @param image_query [::Google::Cloud::VisionAI::V1::ImageQuery, ::Hash]
|
4807
4802
|
# An image-only query.
|
4803
|
+
#
|
4804
|
+
# Note: The following fields are mutually exclusive: `image_query`, `text_query`. If a field in that set is populated, all other fields in the set will automatically be cleared.
|
4808
4805
|
# @param text_query [::String]
|
4809
4806
|
# A text-only query.
|
4807
|
+
#
|
4808
|
+
# Note: The following fields are mutually exclusive: `text_query`, `image_query`. If a field in that set is populated, all other fields in the set will automatically be cleared.
|
4810
4809
|
# @param index_endpoint [::String]
|
4811
4810
|
# Required. The index endpoint to search.
|
4812
4811
|
# Format:
|
@@ -4890,7 +4889,7 @@ module Google
|
|
4890
4889
|
@warehouse_stub.call_rpc :search_index_endpoint, request, options: options do |response, operation|
|
4891
4890
|
response = ::Gapic::PagedEnumerable.new @warehouse_stub, :search_index_endpoint, request, response, operation, options
|
4892
4891
|
yield response, operation if block_given?
|
4893
|
-
|
4892
|
+
throw :response, response
|
4894
4893
|
end
|
4895
4894
|
rescue ::GRPC::BadStatus => e
|
4896
4895
|
raise ::Google::Cloud::Error.from_error(e)
|
@@ -4994,7 +4993,7 @@ module Google
|
|
4994
4993
|
@warehouse_stub.call_rpc :create_index_endpoint, request, options: options do |response, operation|
|
4995
4994
|
response = ::Gapic::Operation.new response, @operations_client, options: options
|
4996
4995
|
yield response, operation if block_given?
|
4997
|
-
|
4996
|
+
throw :response, response
|
4998
4997
|
end
|
4999
4998
|
rescue ::GRPC::BadStatus => e
|
5000
4999
|
raise ::Google::Cloud::Error.from_error(e)
|
@@ -5080,7 +5079,6 @@ module Google
|
|
5080
5079
|
|
5081
5080
|
@warehouse_stub.call_rpc :get_index_endpoint, request, options: options do |response, operation|
|
5082
5081
|
yield response, operation if block_given?
|
5083
|
-
return response
|
5084
5082
|
end
|
5085
5083
|
rescue ::GRPC::BadStatus => e
|
5086
5084
|
raise ::Google::Cloud::Error.from_error(e)
|
@@ -5190,7 +5188,7 @@ module Google
|
|
5190
5188
|
@warehouse_stub.call_rpc :list_index_endpoints, request, options: options do |response, operation|
|
5191
5189
|
response = ::Gapic::PagedEnumerable.new @warehouse_stub, :list_index_endpoints, request, response, operation, options
|
5192
5190
|
yield response, operation if block_given?
|
5193
|
-
|
5191
|
+
throw :response, response
|
5194
5192
|
end
|
5195
5193
|
rescue ::GRPC::BadStatus => e
|
5196
5194
|
raise ::Google::Cloud::Error.from_error(e)
|
@@ -5292,7 +5290,7 @@ module Google
|
|
5292
5290
|
@warehouse_stub.call_rpc :update_index_endpoint, request, options: options do |response, operation|
|
5293
5291
|
response = ::Gapic::Operation.new response, @operations_client, options: options
|
5294
5292
|
yield response, operation if block_given?
|
5295
|
-
|
5293
|
+
throw :response, response
|
5296
5294
|
end
|
5297
5295
|
rescue ::GRPC::BadStatus => e
|
5298
5296
|
raise ::Google::Cloud::Error.from_error(e)
|
@@ -5386,7 +5384,7 @@ module Google
|
|
5386
5384
|
@warehouse_stub.call_rpc :delete_index_endpoint, request, options: options do |response, operation|
|
5387
5385
|
response = ::Gapic::Operation.new response, @operations_client, options: options
|
5388
5386
|
yield response, operation if block_given?
|
5389
|
-
|
5387
|
+
throw :response, response
|
5390
5388
|
end
|
5391
5389
|
rescue ::GRPC::BadStatus => e
|
5392
5390
|
raise ::Google::Cloud::Error.from_error(e)
|
@@ -5484,7 +5482,7 @@ module Google
|
|
5484
5482
|
@warehouse_stub.call_rpc :deploy_index, request, options: options do |response, operation|
|
5485
5483
|
response = ::Gapic::Operation.new response, @operations_client, options: options
|
5486
5484
|
yield response, operation if block_given?
|
5487
|
-
|
5485
|
+
throw :response, response
|
5488
5486
|
end
|
5489
5487
|
rescue ::GRPC::BadStatus => e
|
5490
5488
|
raise ::Google::Cloud::Error.from_error(e)
|
@@ -5580,7 +5578,7 @@ module Google
|
|
5580
5578
|
@warehouse_stub.call_rpc :undeploy_index, request, options: options do |response, operation|
|
5581
5579
|
response = ::Gapic::Operation.new response, @operations_client, options: options
|
5582
5580
|
yield response, operation if block_given?
|
5583
|
-
|
5581
|
+
throw :response, response
|
5584
5582
|
end
|
5585
5583
|
rescue ::GRPC::BadStatus => e
|
5586
5584
|
raise ::Google::Cloud::Error.from_error(e)
|
@@ -5685,7 +5683,7 @@ module Google
|
|
5685
5683
|
@warehouse_stub.call_rpc :create_collection, request, options: options do |response, operation|
|
5686
5684
|
response = ::Gapic::Operation.new response, @operations_client, options: options
|
5687
5685
|
yield response, operation if block_given?
|
5688
|
-
|
5686
|
+
throw :response, response
|
5689
5687
|
end
|
5690
5688
|
rescue ::GRPC::BadStatus => e
|
5691
5689
|
raise ::Google::Cloud::Error.from_error(e)
|
@@ -5780,7 +5778,7 @@ module Google
|
|
5780
5778
|
@warehouse_stub.call_rpc :delete_collection, request, options: options do |response, operation|
|
5781
5779
|
response = ::Gapic::Operation.new response, @operations_client, options: options
|
5782
5780
|
yield response, operation if block_given?
|
5783
|
-
|
5781
|
+
throw :response, response
|
5784
5782
|
end
|
5785
5783
|
rescue ::GRPC::BadStatus => e
|
5786
5784
|
raise ::Google::Cloud::Error.from_error(e)
|
@@ -5867,7 +5865,6 @@ module Google
|
|
5867
5865
|
|
5868
5866
|
@warehouse_stub.call_rpc :get_collection, request, options: options do |response, operation|
|
5869
5867
|
yield response, operation if block_given?
|
5870
|
-
return response
|
5871
5868
|
end
|
5872
5869
|
rescue ::GRPC::BadStatus => e
|
5873
5870
|
raise ::Google::Cloud::Error.from_error(e)
|
@@ -5965,7 +5962,6 @@ module Google
|
|
5965
5962
|
|
5966
5963
|
@warehouse_stub.call_rpc :update_collection, request, options: options do |response, operation|
|
5967
5964
|
yield response, operation if block_given?
|
5968
|
-
return response
|
5969
5965
|
end
|
5970
5966
|
rescue ::GRPC::BadStatus => e
|
5971
5967
|
raise ::Google::Cloud::Error.from_error(e)
|
@@ -6067,7 +6063,7 @@ module Google
|
|
6067
6063
|
@warehouse_stub.call_rpc :list_collections, request, options: options do |response, operation|
|
6068
6064
|
response = ::Gapic::PagedEnumerable.new @warehouse_stub, :list_collections, request, response, operation, options
|
6069
6065
|
yield response, operation if block_given?
|
6070
|
-
|
6066
|
+
throw :response, response
|
6071
6067
|
end
|
6072
6068
|
rescue ::GRPC::BadStatus => e
|
6073
6069
|
raise ::Google::Cloud::Error.from_error(e)
|
@@ -6153,7 +6149,6 @@ module Google
|
|
6153
6149
|
|
6154
6150
|
@warehouse_stub.call_rpc :add_collection_item, request, options: options do |response, operation|
|
6155
6151
|
yield response, operation if block_given?
|
6156
|
-
return response
|
6157
6152
|
end
|
6158
6153
|
rescue ::GRPC::BadStatus => e
|
6159
6154
|
raise ::Google::Cloud::Error.from_error(e)
|
@@ -6239,7 +6234,6 @@ module Google
|
|
6239
6234
|
|
6240
6235
|
@warehouse_stub.call_rpc :remove_collection_item, request, options: options do |response, operation|
|
6241
6236
|
yield response, operation if block_given?
|
6242
|
-
return response
|
6243
6237
|
end
|
6244
6238
|
rescue ::GRPC::BadStatus => e
|
6245
6239
|
raise ::Google::Cloud::Error.from_error(e)
|
@@ -6342,7 +6336,7 @@ module Google
|
|
6342
6336
|
@warehouse_stub.call_rpc :view_collection_items, request, options: options do |response, operation|
|
6343
6337
|
response = ::Gapic::PagedEnumerable.new @warehouse_stub, :view_collection_items, request, response, operation, options
|
6344
6338
|
yield response, operation if block_given?
|
6345
|
-
|
6339
|
+
throw :response, response
|
6346
6340
|
end
|
6347
6341
|
rescue ::GRPC::BadStatus => e
|
6348
6342
|
raise ::Google::Cloud::Error.from_error(e)
|
@@ -6392,6 +6386,13 @@ module Google
|
|
6392
6386
|
# * (`GRPC::Core::Channel`) a gRPC channel with included credentials
|
6393
6387
|
# * (`GRPC::Core::ChannelCredentials`) a gRPC credentails object
|
6394
6388
|
# * (`nil`) indicating no credentials
|
6389
|
+
#
|
6390
|
+
# Warning: If you accept a credential configuration (JSON file or Hash) from an
|
6391
|
+
# external source for authentication to Google Cloud, you must validate it before
|
6392
|
+
# providing it to a Google API client library. Providing an unvalidated credential
|
6393
|
+
# configuration to Google APIs can compromise the security of your systems and data.
|
6394
|
+
# For more information, refer to [Validate credential configurations from external
|
6395
|
+
# sources](https://cloud.google.com/docs/authentication/external/externally-sourced-credentials).
|
6395
6396
|
# @return [::Object]
|
6396
6397
|
# @!attribute [rw] scope
|
6397
6398
|
# The OAuth scopes
|
@@ -6431,6 +6432,11 @@ module Google
|
|
6431
6432
|
# default endpoint URL. The default value of nil uses the environment
|
6432
6433
|
# universe (usually the default "googleapis.com" universe).
|
6433
6434
|
# @return [::String,nil]
|
6435
|
+
# @!attribute [rw] logger
|
6436
|
+
# A custom logger to use for request/response debug logging, or the value
|
6437
|
+
# `:default` (the default) to construct a default logger, or `nil` to
|
6438
|
+
# explicitly disable logging.
|
6439
|
+
# @return [::Logger,:default,nil]
|
6434
6440
|
#
|
6435
6441
|
class Configuration
|
6436
6442
|
extend ::Gapic::Config
|
@@ -6455,6 +6461,7 @@ module Google
|
|
6455
6461
|
config_attr :retry_policy, nil, ::Hash, ::Proc, nil
|
6456
6462
|
config_attr :quota_project, nil, ::String, nil
|
6457
6463
|
config_attr :universe_domain, nil, ::String, nil
|
6464
|
+
config_attr :logger, :default, ::Logger, nil, :default
|
6458
6465
|
|
6459
6466
|
# @private
|
6460
6467
|
def initialize parent_config = nil
|