google-cloud-retail-v2 0.4.1 → 0.6.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (40) hide show
  1. checksums.yaml +4 -4
  2. data/lib/google/cloud/retail/v2/catalog_pb.rb +2 -2
  3. data/lib/google/cloud/retail/v2/catalog_service/client.rb +47 -46
  4. data/lib/google/cloud/retail/v2/catalog_service_pb.rb +2 -2
  5. data/lib/google/cloud/retail/v2/catalog_service_services_pb.rb +5 -5
  6. data/lib/google/cloud/retail/v2/common_pb.rb +2 -2
  7. data/lib/google/cloud/retail/v2/completion_service/client.rb +49 -50
  8. data/lib/google/cloud/retail/v2/completion_service/operations.rb +30 -21
  9. data/lib/google/cloud/retail/v2/completion_service.rb +2 -2
  10. data/lib/google/cloud/retail/v2/completion_service_pb.rb +2 -2
  11. data/lib/google/cloud/retail/v2/completion_service_services_pb.rb +7 -7
  12. data/lib/google/cloud/retail/v2/import_config_pb.rb +2 -2
  13. data/lib/google/cloud/retail/v2/prediction_service/client.rb +34 -39
  14. data/lib/google/cloud/retail/v2/prediction_service_pb.rb +2 -2
  15. data/lib/google/cloud/retail/v2/prediction_service_services_pb.rb +1 -1
  16. data/lib/google/cloud/retail/v2/product_pb.rb +2 -2
  17. data/lib/google/cloud/retail/v2/product_service/client.rb +74 -58
  18. data/lib/google/cloud/retail/v2/product_service/operations.rb +30 -21
  19. data/lib/google/cloud/retail/v2/product_service_pb.rb +3 -2
  20. data/lib/google/cloud/retail/v2/product_service_services_pb.rb +7 -7
  21. data/lib/google/cloud/retail/v2/purge_config_pb.rb +2 -2
  22. data/lib/google/cloud/retail/v2/search_service/client.rb +101 -79
  23. data/lib/google/cloud/retail/v2/search_service.rb +2 -2
  24. data/lib/google/cloud/retail/v2/search_service_pb.rb +11 -2
  25. data/lib/google/cloud/retail/v2/search_service_services_pb.rb +5 -5
  26. data/lib/google/cloud/retail/v2/user_event_pb.rb +2 -2
  27. data/lib/google/cloud/retail/v2/user_event_service/client.rb +56 -43
  28. data/lib/google/cloud/retail/v2/user_event_service/operations.rb +30 -21
  29. data/lib/google/cloud/retail/v2/user_event_service_pb.rb +2 -2
  30. data/lib/google/cloud/retail/v2/user_event_service_services_pb.rb +1 -1
  31. data/lib/google/cloud/retail/v2/version.rb +1 -1
  32. data/proto_docs/google/api/httpbody.rb +7 -3
  33. data/proto_docs/google/cloud/retail/v2/common.rb +3 -3
  34. data/proto_docs/google/cloud/retail/v2/completion_service.rb +9 -7
  35. data/proto_docs/google/cloud/retail/v2/import_config.rb +4 -4
  36. data/proto_docs/google/cloud/retail/v2/product.rb +22 -16
  37. data/proto_docs/google/cloud/retail/v2/product_service.rb +6 -6
  38. data/proto_docs/google/cloud/retail/v2/search_service.rb +141 -74
  39. data/proto_docs/google/cloud/retail/v2/user_event.rb +19 -7
  40. metadata +4 -4
@@ -41,13 +41,12 @@ module Google
41
41
  # See {::Google::Cloud::Retail::V2::PredictionService::Client::Configuration}
42
42
  # for a description of the configuration fields.
43
43
  #
44
- # ## Example
44
+ # @example
45
45
  #
46
- # To modify the configuration for all PredictionService clients:
47
- #
48
- # ::Google::Cloud::Retail::V2::PredictionService::Client.configure do |config|
49
- # config.timeout = 10.0
50
- # end
46
+ # # Modify the configuration for all PredictionService clients
47
+ # ::Google::Cloud::Retail::V2::PredictionService::Client.configure do |config|
48
+ # config.timeout = 10.0
49
+ # end
51
50
  #
52
51
  # @yield [config] Configure the Client client.
53
52
  # @yieldparam config [Client::Configuration]
@@ -65,9 +64,9 @@ module Google
65
64
  end
66
65
  default_config = Client::Configuration.new parent_config
67
66
 
68
- default_config.timeout = 60.0
67
+ default_config.timeout = 5.0
69
68
  default_config.retry_policy = {
70
- initial_delay: 0.1, max_delay: 60.0, multiplier: 1.3, retry_codes: [14, 4]
69
+ initial_delay: 0.1, max_delay: 5.0, multiplier: 1.3, retry_codes: [14, 4]
71
70
  }
72
71
 
73
72
  default_config
@@ -99,19 +98,15 @@ module Google
99
98
  ##
100
99
  # Create a new PredictionService client object.
101
100
  #
102
- # ## Examples
103
- #
104
- # To create a new PredictionService client with the default
105
- # configuration:
101
+ # @example
106
102
  #
107
- # client = ::Google::Cloud::Retail::V2::PredictionService::Client.new
103
+ # # Create a client using the default configuration
104
+ # client = ::Google::Cloud::Retail::V2::PredictionService::Client.new
108
105
  #
109
- # To create a new PredictionService client with a custom
110
- # configuration:
111
- #
112
- # client = ::Google::Cloud::Retail::V2::PredictionService::Client.new do |config|
113
- # config.timeout = 10.0
114
- # end
106
+ # # Create a client using a custom configuration
107
+ # client = ::Google::Cloud::Retail::V2::PredictionService::Client.new do |config|
108
+ # config.timeout = 10.0
109
+ # end
115
110
  #
116
111
  # @yield [config] Configure the PredictionService client.
117
112
  # @yieldparam config [Client::Configuration]
@@ -131,10 +126,9 @@ module Google
131
126
 
132
127
  # Create credentials
133
128
  credentials = @config.credentials
134
- # Use self-signed JWT if the scope and endpoint are unchanged from default,
129
+ # Use self-signed JWT if the endpoint is unchanged from default,
135
130
  # but only if the default endpoint does not have a region prefix.
136
- enable_self_signed_jwt = @config.scope == Client.configure.scope &&
137
- @config.endpoint == Client.configure.endpoint &&
131
+ enable_self_signed_jwt = @config.endpoint == Client.configure.endpoint &&
138
132
  !@config.endpoint.split(".").first.include?("-")
139
133
  credentials ||= Credentials.default scope: @config.scope,
140
134
  enable_self_signed_jwt: enable_self_signed_jwt
@@ -306,7 +300,9 @@ module Google
306
300
  options.apply_defaults timeout: @config.rpcs.predict.timeout,
307
301
  metadata: metadata,
308
302
  retry_policy: @config.rpcs.predict.retry_policy
309
- options.apply_defaults metadata: @config.metadata,
303
+
304
+ options.apply_defaults timeout: @config.timeout,
305
+ metadata: @config.metadata,
310
306
  retry_policy: @config.retry_policy
311
307
 
312
308
  @prediction_service_stub.call_rpc :predict, request, options: options do |response, operation|
@@ -330,22 +326,21 @@ module Google
330
326
  # Configuration can be applied globally to all clients, or to a single client
331
327
  # on construction.
332
328
  #
333
- # # Examples
334
- #
335
- # To modify the global config, setting the timeout for predict
336
- # to 20 seconds, and all remaining timeouts to 10 seconds:
337
- #
338
- # ::Google::Cloud::Retail::V2::PredictionService::Client.configure do |config|
339
- # config.timeout = 10.0
340
- # config.rpcs.predict.timeout = 20.0
341
- # end
342
- #
343
- # To apply the above configuration only to a new client:
344
- #
345
- # client = ::Google::Cloud::Retail::V2::PredictionService::Client.new do |config|
346
- # config.timeout = 10.0
347
- # config.rpcs.predict.timeout = 20.0
348
- # end
329
+ # @example
330
+ #
331
+ # # Modify the global config, setting the timeout for
332
+ # # predict to 20 seconds,
333
+ # # and all remaining timeouts to 10 seconds.
334
+ # ::Google::Cloud::Retail::V2::PredictionService::Client.configure do |config|
335
+ # config.timeout = 10.0
336
+ # config.rpcs.predict.timeout = 20.0
337
+ # end
338
+ #
339
+ # # Apply the above configuration only to a new client.
340
+ # client = ::Google::Cloud::Retail::V2::PredictionService::Client.new do |config|
341
+ # config.timeout = 10.0
342
+ # config.rpcs.predict.timeout = 20.0
343
+ # end
349
344
  #
350
345
  # @!attribute [rw] endpoint
351
346
  # The hostname or hostname:port of the service endpoint.
@@ -1,13 +1,13 @@
1
1
  # Generated by the protocol buffer compiler. DO NOT EDIT!
2
2
  # source: google/cloud/retail/v2/prediction_service.proto
3
3
 
4
- require 'google/protobuf'
5
-
6
4
  require 'google/api/annotations_pb'
7
5
  require 'google/api/client_pb'
8
6
  require 'google/api/field_behavior_pb'
9
7
  require 'google/cloud/retail/v2/user_event_pb'
10
8
  require 'google/protobuf/struct_pb'
9
+ require 'google/protobuf'
10
+
11
11
  Google::Protobuf::DescriptorPool.generated_pool.build do
12
12
  add_file("google/cloud/retail/v2/prediction_service.proto", :syntax => :proto3) do
13
13
  add_message "google.cloud.retail.v2.PredictRequest" do
@@ -27,7 +27,7 @@ module Google
27
27
  # Service for making recommendation prediction.
28
28
  class Service
29
29
 
30
- include GRPC::GenericService
30
+ include ::GRPC::GenericService
31
31
 
32
32
  self.marshal_class_method = :encode
33
33
  self.unmarshal_class_method = :decode
@@ -1,8 +1,6 @@
1
1
  # Generated by the protocol buffer compiler. DO NOT EDIT!
2
2
  # source: google/cloud/retail/v2/product.proto
3
3
 
4
- require 'google/protobuf'
5
-
6
4
  require 'google/api/annotations_pb'
7
5
  require 'google/api/field_behavior_pb'
8
6
  require 'google/api/resource_pb'
@@ -11,6 +9,8 @@ require 'google/protobuf/duration_pb'
11
9
  require 'google/protobuf/field_mask_pb'
12
10
  require 'google/protobuf/timestamp_pb'
13
11
  require 'google/protobuf/wrappers_pb'
12
+ require 'google/protobuf'
13
+
14
14
  Google::Protobuf::DescriptorPool.generated_pool.build do
15
15
  add_file("google/cloud/retail/v2/product.proto", :syntax => :proto3) do
16
16
  add_message "google.cloud.retail.v2.Product" do
@@ -42,13 +42,12 @@ module Google
42
42
  # See {::Google::Cloud::Retail::V2::ProductService::Client::Configuration}
43
43
  # for a description of the configuration fields.
44
44
  #
45
- # ## Example
45
+ # @example
46
46
  #
47
- # To modify the configuration for all ProductService clients:
48
- #
49
- # ::Google::Cloud::Retail::V2::ProductService::Client.configure do |config|
50
- # config.timeout = 10.0
51
- # end
47
+ # # Modify the configuration for all ProductService clients
48
+ # ::Google::Cloud::Retail::V2::ProductService::Client.configure do |config|
49
+ # config.timeout = 10.0
50
+ # end
52
51
  #
53
52
  # @yield [config] Configure the Client client.
54
53
  # @yieldparam config [Client::Configuration]
@@ -66,9 +65,14 @@ module Google
66
65
  end
67
66
  default_config = Client::Configuration.new parent_config
68
67
 
69
- default_config.timeout = 60.0
68
+ default_config.timeout = 30.0
70
69
  default_config.retry_policy = {
71
- initial_delay: 0.1, max_delay: 60.0, multiplier: 1.3, retry_codes: [14, 4]
70
+ initial_delay: 0.1, max_delay: 30.0, multiplier: 1.3, retry_codes: [14, 4]
71
+ }
72
+
73
+ default_config.rpcs.import_products.timeout = 300.0
74
+ default_config.rpcs.import_products.retry_policy = {
75
+ initial_delay: 0.1, max_delay: 300.0, multiplier: 1.3, retry_codes: [14, 4]
72
76
  }
73
77
 
74
78
  default_config
@@ -100,19 +104,15 @@ module Google
100
104
  ##
101
105
  # Create a new ProductService client object.
102
106
  #
103
- # ## Examples
104
- #
105
- # To create a new ProductService client with the default
106
- # configuration:
107
- #
108
- # client = ::Google::Cloud::Retail::V2::ProductService::Client.new
107
+ # @example
109
108
  #
110
- # To create a new ProductService client with a custom
111
- # configuration:
109
+ # # Create a client using the default configuration
110
+ # client = ::Google::Cloud::Retail::V2::ProductService::Client.new
112
111
  #
113
- # client = ::Google::Cloud::Retail::V2::ProductService::Client.new do |config|
114
- # config.timeout = 10.0
115
- # end
112
+ # # Create a client using a custom configuration
113
+ # client = ::Google::Cloud::Retail::V2::ProductService::Client.new do |config|
114
+ # config.timeout = 10.0
115
+ # end
116
116
  #
117
117
  # @yield [config] Configure the ProductService client.
118
118
  # @yieldparam config [Client::Configuration]
@@ -132,10 +132,9 @@ module Google
132
132
 
133
133
  # Create credentials
134
134
  credentials = @config.credentials
135
- # Use self-signed JWT if the scope and endpoint are unchanged from default,
135
+ # Use self-signed JWT if the endpoint is unchanged from default,
136
136
  # but only if the default endpoint does not have a region prefix.
137
- enable_self_signed_jwt = @config.scope == Client.configure.scope &&
138
- @config.endpoint == Client.configure.endpoint &&
137
+ enable_self_signed_jwt = @config.endpoint == Client.configure.endpoint &&
139
138
  !@config.endpoint.split(".").first.include?("-")
140
139
  credentials ||= Credentials.default scope: @config.scope,
141
140
  enable_self_signed_jwt: enable_self_signed_jwt
@@ -242,7 +241,9 @@ module Google
242
241
  options.apply_defaults timeout: @config.rpcs.create_product.timeout,
243
242
  metadata: metadata,
244
243
  retry_policy: @config.rpcs.create_product.retry_policy
245
- options.apply_defaults metadata: @config.metadata,
244
+
245
+ options.apply_defaults timeout: @config.timeout,
246
+ metadata: @config.metadata,
246
247
  retry_policy: @config.retry_policy
247
248
 
248
249
  @product_service_stub.call_rpc :create_product, request, options: options do |response, operation|
@@ -317,7 +318,9 @@ module Google
317
318
  options.apply_defaults timeout: @config.rpcs.get_product.timeout,
318
319
  metadata: metadata,
319
320
  retry_policy: @config.rpcs.get_product.retry_policy
320
- options.apply_defaults metadata: @config.metadata,
321
+
322
+ options.apply_defaults timeout: @config.timeout,
323
+ metadata: @config.metadata,
321
324
  retry_policy: @config.retry_policy
322
325
 
323
326
  @product_service_stub.call_rpc :get_product, request, options: options do |response, operation|
@@ -454,7 +457,9 @@ module Google
454
457
  options.apply_defaults timeout: @config.rpcs.list_products.timeout,
455
458
  metadata: metadata,
456
459
  retry_policy: @config.rpcs.list_products.retry_policy
457
- options.apply_defaults metadata: @config.metadata,
460
+
461
+ options.apply_defaults timeout: @config.timeout,
462
+ metadata: @config.metadata,
458
463
  retry_policy: @config.retry_policy
459
464
 
460
465
  @product_service_stub.call_rpc :list_products, request, options: options do |response, operation|
@@ -542,7 +547,9 @@ module Google
542
547
  options.apply_defaults timeout: @config.rpcs.update_product.timeout,
543
548
  metadata: metadata,
544
549
  retry_policy: @config.rpcs.update_product.retry_policy
545
- options.apply_defaults metadata: @config.metadata,
550
+
551
+ options.apply_defaults timeout: @config.timeout,
552
+ metadata: @config.metadata,
546
553
  retry_policy: @config.retry_policy
547
554
 
548
555
  @product_service_stub.call_rpc :update_product, request, options: options do |response, operation|
@@ -628,7 +635,9 @@ module Google
628
635
  options.apply_defaults timeout: @config.rpcs.delete_product.timeout,
629
636
  metadata: metadata,
630
637
  retry_policy: @config.rpcs.delete_product.retry_policy
631
- options.apply_defaults metadata: @config.metadata,
638
+
639
+ options.apply_defaults timeout: @config.timeout,
640
+ metadata: @config.metadata,
632
641
  retry_policy: @config.retry_policy
633
642
 
634
643
  @product_service_stub.call_rpc :delete_product, request, options: options do |response, operation|
@@ -735,7 +744,9 @@ module Google
735
744
  options.apply_defaults timeout: @config.rpcs.import_products.timeout,
736
745
  metadata: metadata,
737
746
  retry_policy: @config.rpcs.import_products.retry_policy
738
- options.apply_defaults metadata: @config.metadata,
747
+
748
+ options.apply_defaults timeout: @config.timeout,
749
+ metadata: @config.metadata,
739
750
  retry_policy: @config.retry_policy
740
751
 
741
752
  @product_service_stub.call_rpc :import_products, request, options: options do |response, operation|
@@ -786,8 +797,8 @@ module Google
786
797
  # {::Google::Cloud::Retail::V2::ProductService::Client#remove_fulfillment_places RemoveFulfillmentPlaces}.
787
798
  #
788
799
  # This feature is only available for users who have Retail Search enabled.
789
- # Contact Retail Support (retail-search-support@google.com) if you are
790
- # interested in using Retail Search.
800
+ # Please submit a form [here](https://cloud.google.com/contact) to contact
801
+ # cloud sales if you are interested in using Retail Search.
791
802
  #
792
803
  # @overload set_inventory(request, options = nil)
793
804
  # Pass arguments to `set_inventory` via a request object, either of type
@@ -856,7 +867,7 @@ module Google
856
867
  # {::Google::Cloud::Retail::V2::Product#name Product.name} is not found, the
857
868
  # inventory update will still be processed and retained for at most 1 day
858
869
  # until the {::Google::Cloud::Retail::V2::Product Product} is created. If set to
859
- # false, an INVALID_ARGUMENT error is returned if the
870
+ # false, a NOT_FOUND error is returned if the
860
871
  # {::Google::Cloud::Retail::V2::Product Product} is not found.
861
872
  #
862
873
  # @yield [response, operation] Access the result along with the RPC operation
@@ -893,7 +904,9 @@ module Google
893
904
  options.apply_defaults timeout: @config.rpcs.set_inventory.timeout,
894
905
  metadata: metadata,
895
906
  retry_policy: @config.rpcs.set_inventory.retry_policy
896
- options.apply_defaults metadata: @config.metadata,
907
+
908
+ options.apply_defaults timeout: @config.timeout,
909
+ metadata: @config.metadata,
897
910
  retry_policy: @config.retry_policy
898
911
 
899
912
  @product_service_stub.call_rpc :set_inventory, request, options: options do |response, operation|
@@ -919,8 +932,8 @@ module Google
919
932
  # {::Google::Cloud::Retail::V2::ProductService::Client#list_products ListProducts}.
920
933
  #
921
934
  # This feature is only available for users who have Retail Search enabled.
922
- # Contact Retail Support (retail-search-support@google.com) if you are
923
- # interested in using Retail Search.
935
+ # Please submit a form [here](https://cloud.google.com/contact) to contact
936
+ # cloud sales if you are interested in using Retail Search.
924
937
  #
925
938
  # @overload add_fulfillment_places(request, options = nil)
926
939
  # Pass arguments to `add_fulfillment_places` via a request object, either of type
@@ -989,8 +1002,8 @@ module Google
989
1002
  # If set to true, and the {::Google::Cloud::Retail::V2::Product Product} is not
990
1003
  # found, the fulfillment information will still be processed and retained for
991
1004
  # at most 1 day and processed once the
992
- # {::Google::Cloud::Retail::V2::Product Product} is created. If set to false, an
993
- # INVALID_ARGUMENT error is returned if the
1005
+ # {::Google::Cloud::Retail::V2::Product Product} is created. If set to false, a
1006
+ # NOT_FOUND error is returned if the
994
1007
  # {::Google::Cloud::Retail::V2::Product Product} is not found.
995
1008
  #
996
1009
  # @yield [response, operation] Access the result along with the RPC operation
@@ -1027,7 +1040,9 @@ module Google
1027
1040
  options.apply_defaults timeout: @config.rpcs.add_fulfillment_places.timeout,
1028
1041
  metadata: metadata,
1029
1042
  retry_policy: @config.rpcs.add_fulfillment_places.retry_policy
1030
- options.apply_defaults metadata: @config.metadata,
1043
+
1044
+ options.apply_defaults timeout: @config.timeout,
1045
+ metadata: @config.metadata,
1031
1046
  retry_policy: @config.retry_policy
1032
1047
 
1033
1048
  @product_service_stub.call_rpc :add_fulfillment_places, request, options: options do |response, operation|
@@ -1053,8 +1068,8 @@ module Google
1053
1068
  # {::Google::Cloud::Retail::V2::ProductService::Client#list_products ListProducts}.
1054
1069
  #
1055
1070
  # This feature is only available for users who have Retail Search enabled.
1056
- # Contact Retail Support (retail-search-support@google.com) if you are
1057
- # interested in using Retail Search.
1071
+ # Please submit a form [here](https://cloud.google.com/contact) to contact
1072
+ # cloud sales if you are interested in using Retail Search.
1058
1073
  #
1059
1074
  # @overload remove_fulfillment_places(request, options = nil)
1060
1075
  # Pass arguments to `remove_fulfillment_places` via a request object, either of type
@@ -1118,8 +1133,8 @@ module Google
1118
1133
  # If set to true, and the {::Google::Cloud::Retail::V2::Product Product} is not
1119
1134
  # found, the fulfillment information will still be processed and retained for
1120
1135
  # at most 1 day and processed once the
1121
- # {::Google::Cloud::Retail::V2::Product Product} is created. If set to false, an
1122
- # INVALID_ARGUMENT error is returned if the
1136
+ # {::Google::Cloud::Retail::V2::Product Product} is created. If set to false, a
1137
+ # NOT_FOUND error is returned if the
1123
1138
  # {::Google::Cloud::Retail::V2::Product Product} is not found.
1124
1139
  #
1125
1140
  # @yield [response, operation] Access the result along with the RPC operation
@@ -1156,7 +1171,9 @@ module Google
1156
1171
  options.apply_defaults timeout: @config.rpcs.remove_fulfillment_places.timeout,
1157
1172
  metadata: metadata,
1158
1173
  retry_policy: @config.rpcs.remove_fulfillment_places.retry_policy
1159
- options.apply_defaults metadata: @config.metadata,
1174
+
1175
+ options.apply_defaults timeout: @config.timeout,
1176
+ metadata: @config.metadata,
1160
1177
  retry_policy: @config.retry_policy
1161
1178
 
1162
1179
  @product_service_stub.call_rpc :remove_fulfillment_places, request, options: options do |response, operation|
@@ -1181,22 +1198,21 @@ module Google
1181
1198
  # Configuration can be applied globally to all clients, or to a single client
1182
1199
  # on construction.
1183
1200
  #
1184
- # # Examples
1185
- #
1186
- # To modify the global config, setting the timeout for create_product
1187
- # to 20 seconds, and all remaining timeouts to 10 seconds:
1188
- #
1189
- # ::Google::Cloud::Retail::V2::ProductService::Client.configure do |config|
1190
- # config.timeout = 10.0
1191
- # config.rpcs.create_product.timeout = 20.0
1192
- # end
1193
- #
1194
- # To apply the above configuration only to a new client:
1195
- #
1196
- # client = ::Google::Cloud::Retail::V2::ProductService::Client.new do |config|
1197
- # config.timeout = 10.0
1198
- # config.rpcs.create_product.timeout = 20.0
1199
- # end
1201
+ # @example
1202
+ #
1203
+ # # Modify the global config, setting the timeout for
1204
+ # # create_product to 20 seconds,
1205
+ # # and all remaining timeouts to 10 seconds.
1206
+ # ::Google::Cloud::Retail::V2::ProductService::Client.configure do |config|
1207
+ # config.timeout = 10.0
1208
+ # config.rpcs.create_product.timeout = 20.0
1209
+ # end
1210
+ #
1211
+ # # Apply the above configuration only to a new client.
1212
+ # client = ::Google::Cloud::Retail::V2::ProductService::Client.new do |config|
1213
+ # config.timeout = 10.0
1214
+ # config.rpcs.create_product.timeout = 20.0
1215
+ # end
1200
1216
  #
1201
1217
  # @!attribute [rw] endpoint
1202
1218
  # The hostname or hostname:port of the service endpoint.
@@ -169,7 +169,9 @@ module Google
169
169
  options.apply_defaults timeout: @config.rpcs.list_operations.timeout,
170
170
  metadata: metadata,
171
171
  retry_policy: @config.rpcs.list_operations.retry_policy
172
- options.apply_defaults metadata: @config.metadata,
172
+
173
+ options.apply_defaults timeout: @config.timeout,
174
+ metadata: @config.metadata,
173
175
  retry_policy: @config.retry_policy
174
176
 
175
177
  @operations_stub.call_rpc :list_operations, request, options: options do |response, operation|
@@ -239,7 +241,9 @@ module Google
239
241
  options.apply_defaults timeout: @config.rpcs.get_operation.timeout,
240
242
  metadata: metadata,
241
243
  retry_policy: @config.rpcs.get_operation.retry_policy
242
- options.apply_defaults metadata: @config.metadata,
244
+
245
+ options.apply_defaults timeout: @config.timeout,
246
+ metadata: @config.metadata,
243
247
  retry_policy: @config.retry_policy
244
248
 
245
249
  @operations_stub.call_rpc :get_operation, request, options: options do |response, operation|
@@ -309,7 +313,9 @@ module Google
309
313
  options.apply_defaults timeout: @config.rpcs.delete_operation.timeout,
310
314
  metadata: metadata,
311
315
  retry_policy: @config.rpcs.delete_operation.retry_policy
312
- options.apply_defaults metadata: @config.metadata,
316
+
317
+ options.apply_defaults timeout: @config.timeout,
318
+ metadata: @config.metadata,
313
319
  retry_policy: @config.retry_policy
314
320
 
315
321
  @operations_stub.call_rpc :delete_operation, request, options: options do |response, operation|
@@ -384,7 +390,9 @@ module Google
384
390
  options.apply_defaults timeout: @config.rpcs.cancel_operation.timeout,
385
391
  metadata: metadata,
386
392
  retry_policy: @config.rpcs.cancel_operation.retry_policy
387
- options.apply_defaults metadata: @config.metadata,
393
+
394
+ options.apply_defaults timeout: @config.timeout,
395
+ metadata: @config.metadata,
388
396
  retry_policy: @config.retry_policy
389
397
 
390
398
  @operations_stub.call_rpc :cancel_operation, request, options: options do |response, operation|
@@ -456,7 +464,9 @@ module Google
456
464
  options.apply_defaults timeout: @config.rpcs.wait_operation.timeout,
457
465
  metadata: metadata,
458
466
  retry_policy: @config.rpcs.wait_operation.retry_policy
459
- options.apply_defaults metadata: @config.metadata,
467
+
468
+ options.apply_defaults timeout: @config.timeout,
469
+ metadata: @config.metadata,
460
470
  retry_policy: @config.retry_policy
461
471
 
462
472
  @operations_stub.call_rpc :wait_operation, request, options: options do |response, operation|
@@ -481,22 +491,21 @@ module Google
481
491
  # Configuration can be applied globally to all clients, or to a single client
482
492
  # on construction.
483
493
  #
484
- # # Examples
485
- #
486
- # To modify the global config, setting the timeout for list_operations
487
- # to 20 seconds, and all remaining timeouts to 10 seconds:
488
- #
489
- # ::Google::Longrunning::Operations::Client.configure do |config|
490
- # config.timeout = 10.0
491
- # config.rpcs.list_operations.timeout = 20.0
492
- # end
493
- #
494
- # To apply the above configuration only to a new client:
495
- #
496
- # client = ::Google::Longrunning::Operations::Client.new do |config|
497
- # config.timeout = 10.0
498
- # config.rpcs.list_operations.timeout = 20.0
499
- # end
494
+ # @example
495
+ #
496
+ # # Modify the global config, setting the timeout for
497
+ # # list_operations to 20 seconds,
498
+ # # and all remaining timeouts to 10 seconds.
499
+ # ::Google::Longrunning::Operations::Client.configure do |config|
500
+ # config.timeout = 10.0
501
+ # config.rpcs.list_operations.timeout = 20.0
502
+ # end
503
+ #
504
+ # # Apply the above configuration only to a new client.
505
+ # client = ::Google::Longrunning::Operations::Client.new do |config|
506
+ # config.timeout = 10.0
507
+ # config.rpcs.list_operations.timeout = 20.0
508
+ # end
500
509
  #
501
510
  # @!attribute [rw] endpoint
502
511
  # The hostname or hostname:port of the service endpoint.
@@ -1,12 +1,11 @@
1
1
  # Generated by the protocol buffer compiler. DO NOT EDIT!
2
2
  # source: google/cloud/retail/v2/product_service.proto
3
3
 
4
- require 'google/protobuf'
5
-
6
4
  require 'google/api/annotations_pb'
7
5
  require 'google/api/client_pb'
8
6
  require 'google/api/field_behavior_pb'
9
7
  require 'google/api/resource_pb'
8
+ require 'google/cloud/retail/v2/common_pb'
10
9
  require 'google/cloud/retail/v2/import_config_pb'
11
10
  require 'google/cloud/retail/v2/product_pb'
12
11
  require 'google/cloud/retail/v2/purge_config_pb'
@@ -14,6 +13,8 @@ require 'google/longrunning/operations_pb'
14
13
  require 'google/protobuf/empty_pb'
15
14
  require 'google/protobuf/field_mask_pb'
16
15
  require 'google/protobuf/timestamp_pb'
16
+ require 'google/protobuf'
17
+
17
18
  Google::Protobuf::DescriptorPool.generated_pool.build do
18
19
  add_file("google/cloud/retail/v2/product_service.proto", :syntax => :proto3) do
19
20
  add_message "google.cloud.retail.v2.CreateProductRequest" do
@@ -28,7 +28,7 @@ module Google
28
28
  # of the customer's website.
29
29
  class Service
30
30
 
31
- include GRPC::GenericService
31
+ include ::GRPC::GenericService
32
32
 
33
33
  self.marshal_class_method = :encode
34
34
  self.unmarshal_class_method = :decode
@@ -90,8 +90,8 @@ module Google
90
90
  # [RemoveFulfillmentPlaces][google.cloud.retail.v2.ProductService.RemoveFulfillmentPlaces].
91
91
  #
92
92
  # This feature is only available for users who have Retail Search enabled.
93
- # Contact Retail Support (retail-search-support@google.com) if you are
94
- # interested in using Retail Search.
93
+ # Please submit a form [here](https://cloud.google.com/contact) to contact
94
+ # cloud sales if you are interested in using Retail Search.
95
95
  rpc :SetInventory, ::Google::Cloud::Retail::V2::SetInventoryRequest, ::Google::Longrunning::Operation
96
96
  # Incrementally adds place IDs to
97
97
  # [Product.fulfillment_info.place_ids][google.cloud.retail.v2.FulfillmentInfo.place_ids].
@@ -106,8 +106,8 @@ module Google
106
106
  # [ListProducts][google.cloud.retail.v2.ProductService.ListProducts].
107
107
  #
108
108
  # This feature is only available for users who have Retail Search enabled.
109
- # Contact Retail Support (retail-search-support@google.com) if you are
110
- # interested in using Retail Search.
109
+ # Please submit a form [here](https://cloud.google.com/contact) to contact
110
+ # cloud sales if you are interested in using Retail Search.
111
111
  rpc :AddFulfillmentPlaces, ::Google::Cloud::Retail::V2::AddFulfillmentPlacesRequest, ::Google::Longrunning::Operation
112
112
  # Incrementally removes place IDs from a
113
113
  # [Product.fulfillment_info.place_ids][google.cloud.retail.v2.FulfillmentInfo.place_ids].
@@ -122,8 +122,8 @@ module Google
122
122
  # [ListProducts][google.cloud.retail.v2.ProductService.ListProducts].
123
123
  #
124
124
  # This feature is only available for users who have Retail Search enabled.
125
- # Contact Retail Support (retail-search-support@google.com) if you are
126
- # interested in using Retail Search.
125
+ # Please submit a form [here](https://cloud.google.com/contact) to contact
126
+ # cloud sales if you are interested in using Retail Search.
127
127
  rpc :RemoveFulfillmentPlaces, ::Google::Cloud::Retail::V2::RemoveFulfillmentPlacesRequest, ::Google::Longrunning::Operation
128
128
  end
129
129
 
@@ -1,10 +1,10 @@
1
1
  # Generated by the protocol buffer compiler. DO NOT EDIT!
2
2
  # source: google/cloud/retail/v2/purge_config.proto
3
3
 
4
- require 'google/protobuf'
5
-
6
4
  require 'google/api/annotations_pb'
7
5
  require 'google/api/field_behavior_pb'
6
+ require 'google/protobuf'
7
+
8
8
  Google::Protobuf::DescriptorPool.generated_pool.build do
9
9
  add_file("google/cloud/retail/v2/purge_config.proto", :syntax => :proto3) do
10
10
  add_message "google.cloud.retail.v2.PurgeMetadata" do