lib/google/cloud/apigee_connect/v1/tether/client.rb in google-cloud-apigee_connect-v1-0.7.0 vs lib/google/cloud/apigee_connect/v1/tether/client.rb in google-cloud-apigee_connect-v1-1.0.0
- old
+ new
@@ -31,10 +31,13 @@
# services in data planes that runs in a remote datacenter without
# requiring customers to open firewalls on their runtime plane.
#
class Client
# @private
+ API_VERSION = ""
+
+ # @private
DEFAULT_ENDPOINT_TEMPLATE = "apigeeconnect.$UNIVERSE_DOMAIN$"
# @private
attr_reader :tether_stub
@@ -220,13 +223,14 @@
options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
# Customize the options with defaults
metadata = @config.rpcs.egress.metadata.to_h
- # Set x-goog-api-client and x-goog-user-project headers
+ # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
lib_name: @config.lib_name, lib_version: @config.lib_version,
gapic_version: ::Google::Cloud::ApigeeConnect::V1::VERSION
+ metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
options.apply_defaults timeout: @config.rpcs.egress.timeout,
metadata: metadata,
retry_policy: @config.rpcs.egress.retry_policy