lib/google/cloud/gaming/v1/realms_service/client.rb in google-cloud-gaming-v1-0.2.0 vs lib/google/cloud/gaming/v1/realms_service/client.rb in google-cloud-gaming-v1-0.3.0

- old
+ new

@@ -59,29 +59,29 @@ @configure ||= begin namespace = ["Google", "Cloud", "Gaming", "V1"] parent_config = while namespace.any? parent_name = namespace.join "::" parent_const = const_get parent_name - break parent_const.configure if parent_const&.respond_to? :configure + break parent_const.configure if parent_const.respond_to? :configure namespace.pop end default_config = Client::Configuration.new parent_config default_config.rpcs.list_realms.timeout = 60.0 default_config.rpcs.list_realms.retry_policy = { initial_delay: 1.0, - max_delay: 10.0, - multiplier: 1.3, - retry_codes: [14] + max_delay: 10.0, + multiplier: 1.3, + retry_codes: [14] } default_config.rpcs.get_realm.timeout = 60.0 default_config.rpcs.get_realm.retry_policy = { initial_delay: 1.0, - max_delay: 10.0, - multiplier: 1.3, - retry_codes: [14] + max_delay: 10.0, + multiplier: 1.3, + retry_codes: [14] } default_config.rpcs.create_realm.timeout = 60.0 default_config.rpcs.delete_realm.timeout = 60.0 @@ -89,13 +89,13 @@ default_config.rpcs.update_realm.timeout = 60.0 default_config.rpcs.preview_realm_update.timeout = 60.0 default_config.rpcs.preview_realm_update.retry_policy = { initial_delay: 1.0, - max_delay: 10.0, - multiplier: 1.3, - retry_codes: [14] + max_delay: 10.0, + multiplier: 1.3, + retry_codes: [14] } default_config end yield @configure if block_given? @@ -160,11 +160,11 @@ # Use self-signed JWT if the scope and endpoint are unchanged from default, # but only if the default endpoint does not have a region prefix. enable_self_signed_jwt = @config.scope == Client.configure.scope && @config.endpoint == Client.configure.endpoint && !@config.endpoint.split(".").first.include?("-") - credentials ||= Credentials.default scope: @config.scope, + credentials ||= Credentials.default scope: @config.scope, enable_self_signed_jwt: enable_self_signed_jwt if credentials.is_a?(String) || credentials.is_a?(Hash) credentials = Credentials.new credentials, scope: @config.scope end @quota_project_id = @config.quota_project @@ -723,11 +723,11 @@ allowed.any? { |klass| klass === value } end config_attr :scope, nil, ::String, ::Array, nil config_attr :lib_name, nil, ::String, nil config_attr :lib_version, nil, ::String, nil - config_attr(:channel_args, { "grpc.service_config_disable_resolution"=>1 }, ::Hash, nil) + config_attr(:channel_args, { "grpc.service_config_disable_resolution" => 1 }, ::Hash, nil) config_attr :interceptors, nil, ::Array, nil config_attr :timeout, nil, ::Numeric, nil config_attr :metadata, nil, ::Hash, nil config_attr :retry_policy, nil, ::Hash, ::Proc, nil config_attr :quota_project, nil, ::String, nil @@ -744,11 +744,11 @@ # @return [Rpcs] # def rpcs @rpcs ||= begin parent_rpcs = nil - parent_rpcs = @parent_config.rpcs if defined?(@parent_config) && @parent_config&.respond_to?(:rpcs) + parent_rpcs = @parent_config.rpcs if defined?(@parent_config) && @parent_config.respond_to?(:rpcs) Rpcs.new parent_rpcs end end ## @@ -800,20 +800,20 @@ # attr_reader :preview_realm_update # @private def initialize parent_rpcs = nil - list_realms_config = parent_rpcs&.list_realms if parent_rpcs&.respond_to? :list_realms + list_realms_config = parent_rpcs.list_realms if parent_rpcs.respond_to? :list_realms @list_realms = ::Gapic::Config::Method.new list_realms_config - get_realm_config = parent_rpcs&.get_realm if parent_rpcs&.respond_to? :get_realm + get_realm_config = parent_rpcs.get_realm if parent_rpcs.respond_to? :get_realm @get_realm = ::Gapic::Config::Method.new get_realm_config - create_realm_config = parent_rpcs&.create_realm if parent_rpcs&.respond_to? :create_realm + create_realm_config = parent_rpcs.create_realm if parent_rpcs.respond_to? :create_realm @create_realm = ::Gapic::Config::Method.new create_realm_config - delete_realm_config = parent_rpcs&.delete_realm if parent_rpcs&.respond_to? :delete_realm + delete_realm_config = parent_rpcs.delete_realm if parent_rpcs.respond_to? :delete_realm @delete_realm = ::Gapic::Config::Method.new delete_realm_config - update_realm_config = parent_rpcs&.update_realm if parent_rpcs&.respond_to? :update_realm + update_realm_config = parent_rpcs.update_realm if parent_rpcs.respond_to? :update_realm @update_realm = ::Gapic::Config::Method.new update_realm_config - preview_realm_update_config = parent_rpcs&.preview_realm_update if parent_rpcs&.respond_to? :preview_realm_update + preview_realm_update_config = parent_rpcs.preview_realm_update if parent_rpcs.respond_to? :preview_realm_update @preview_realm_update = ::Gapic::Config::Method.new preview_realm_update_config yield self if block_given? end end