diff --git a/api_names_out.yaml b/api_names_out.yaml index c6fdee29d..b65d3e162 100644 --- a/api_names_out.yaml +++ b/api_names_out.yaml @@ -136709,6 +136709,9 @@ "/serviceusage:v1beta1/HttpRule/restCollection": rest_collection "/serviceusage:v1beta1/HttpRule/restMethodName": rest_method_name "/serviceusage:v1beta1/HttpRule/selector": selector +"/serviceusage:v1beta1/ImportAdminOverridesRequest": import_admin_overrides_request +"/serviceusage:v1beta1/ImportAdminOverridesRequest/force": force +"/serviceusage:v1beta1/ImportAdminOverridesRequest/inlineSource": inline_source "/serviceusage:v1beta1/ImportAdminOverridesResponse": import_admin_overrides_response "/serviceusage:v1beta1/ImportAdminOverridesResponse/overrides": overrides "/serviceusage:v1beta1/ImportAdminOverridesResponse/overrides/override": override @@ -136984,6 +136987,8 @@ "/serviceusage:v1beta1/serviceusage.services.consumerQuotaMetrics.get": get_service_consumer_quota_metric "/serviceusage:v1beta1/serviceusage.services.consumerQuotaMetrics.get/name": name "/serviceusage:v1beta1/serviceusage.services.consumerQuotaMetrics.get/view": view +"/serviceusage:v1beta1/serviceusage.services.consumerQuotaMetrics.importAdminOverrides": import_consumer_quota_metric_admin_overrides +"/serviceusage:v1beta1/serviceusage.services.consumerQuotaMetrics.importAdminOverrides/parent": parent "/serviceusage:v1beta1/serviceusage.services.consumerQuotaMetrics.importConsumerOverrides": import_consumer_quota_metric_consumer_overrides "/serviceusage:v1beta1/serviceusage.services.consumerQuotaMetrics.importConsumerOverrides/parent": parent "/serviceusage:v1beta1/serviceusage.services.consumerQuotaMetrics.limits.adminOverrides.create": create_service_consumer_quota_metric_limit_admin_override diff --git a/generated/google/apis/serviceusage_v1beta1.rb b/generated/google/apis/serviceusage_v1beta1.rb index c93257d0c..6972e5abf 100644 --- a/generated/google/apis/serviceusage_v1beta1.rb +++ b/generated/google/apis/serviceusage_v1beta1.rb @@ -27,7 +27,7 @@ module Google # @see https://cloud.google.com/service-usage/ module ServiceusageV1beta1 VERSION = 'V1beta1' - REVISION = '20201021' + REVISION = '20201028' # View and manage your data across Google Cloud Platform services AUTH_CLOUD_PLATFORM = 'https://www.googleapis.com/auth/cloud-platform' diff --git a/generated/google/apis/serviceusage_v1beta1/classes.rb b/generated/google/apis/serviceusage_v1beta1/classes.rb index f324e884e..7cbc6b456 100644 --- a/generated/google/apis/serviceusage_v1beta1/classes.rb +++ b/generated/google/apis/serviceusage_v1beta1/classes.rb @@ -2193,6 +2193,36 @@ module Google end end + # Request message for ImportAdminOverrides + class ImportAdminOverridesRequest + include Google::Apis::Core::Hashable + + # Whether to force the creation of the quota overrides. If creating an override + # would cause the effective quota for the consumer to decrease by more than 10 + # percent, the call is rejected, as a safety measure to avoid accidentally + # decreasing quota too quickly. Setting the force parameter to true ignores this + # restriction. + # Corresponds to the JSON property `force` + # @return [Boolean] + attr_accessor :force + alias_method :force?, :force + + # Import data embedded in the request message + # Corresponds to the JSON property `inlineSource` + # @return [Google::Apis::ServiceusageV1beta1::OverrideInlineSource] + attr_accessor :inline_source + + def initialize(**args) + update!(**args) + end + + # Update properties of this object + def update!(**args) + @force = args[:force] if args.key?(:force) + @inline_source = args[:inline_source] if args.key?(:inline_source) + end + end + # Response message for ImportAdminOverrides class ImportAdminOverridesResponse include Google::Apis::Core::Hashable diff --git a/generated/google/apis/serviceusage_v1beta1/representations.rb b/generated/google/apis/serviceusage_v1beta1/representations.rb index b87f83520..2e5fc6767 100644 --- a/generated/google/apis/serviceusage_v1beta1/representations.rb +++ b/generated/google/apis/serviceusage_v1beta1/representations.rb @@ -280,6 +280,12 @@ module Google include Google::Apis::Core::JsonObjectSupport end + class ImportAdminOverridesRequest + class Representation < Google::Apis::Core::JsonRepresentation; end + + include Google::Apis::Core::JsonObjectSupport + end + class ImportAdminOverridesResponse class Representation < Google::Apis::Core::JsonRepresentation; end @@ -1030,6 +1036,15 @@ module Google end end + class ImportAdminOverridesRequest + # @private + class Representation < Google::Apis::Core::JsonRepresentation + property :force, as: 'force' + property :inline_source, as: 'inlineSource', class: Google::Apis::ServiceusageV1beta1::OverrideInlineSource, decorator: Google::Apis::ServiceusageV1beta1::OverrideInlineSource::Representation + + end + end + class ImportAdminOverridesResponse # @private class Representation < Google::Apis::Core::JsonRepresentation diff --git a/generated/google/apis/serviceusage_v1beta1/service.rb b/generated/google/apis/serviceusage_v1beta1/service.rb index a877ab07a..795aeb56f 100644 --- a/generated/google/apis/serviceusage_v1beta1/service.rb +++ b/generated/google/apis/serviceusage_v1beta1/service.rb @@ -389,6 +389,42 @@ module Google execute_or_queue_command(command, &block) end + # Create or update multiple admin overrides atomically, all on the same consumer, + # but on many different metrics or limits. The name field in the quota override + # message should not be set. + # @param [String] parent + # The resource name of the consumer. An example name would be: `projects/123/ + # services/compute.googleapis.com` + # @param [Google::Apis::ServiceusageV1beta1::ImportAdminOverridesRequest] import_admin_overrides_request_object + # @param [String] fields + # Selector specifying which fields to include in a partial response. + # @param [String] quota_user + # Available to use for quota purposes for server-side applications. Can be any + # arbitrary string assigned to a user, but should not exceed 40 characters. + # @param [Google::Apis::RequestOptions] options + # Request-specific options + # + # @yield [result, err] Result & error if block supplied + # @yieldparam result [Google::Apis::ServiceusageV1beta1::Operation] parsed result object + # @yieldparam err [StandardError] error object if request failed + # + # @return [Google::Apis::ServiceusageV1beta1::Operation] + # + # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried + # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification + # @raise [Google::Apis::AuthorizationError] Authorization is required + def import_consumer_quota_metric_admin_overrides(parent, import_admin_overrides_request_object = nil, fields: nil, quota_user: nil, options: nil, &block) + command = make_simple_command(:post, 'v1beta1/{+parent}/consumerQuotaMetrics:importAdminOverrides', options) + command.request_representation = Google::Apis::ServiceusageV1beta1::ImportAdminOverridesRequest::Representation + command.request_object = import_admin_overrides_request_object + command.response_representation = Google::Apis::ServiceusageV1beta1::Operation::Representation + command.response_class = Google::Apis::ServiceusageV1beta1::Operation + command.params['parent'] = parent unless parent.nil? + command.query['fields'] = fields unless fields.nil? + command.query['quotaUser'] = quota_user unless quota_user.nil? + execute_or_queue_command(command, &block) + end + # Create or update multiple consumer overrides atomically, all on the same # consumer, but on many different metrics or limits. The name field in the quota # override message should not be set. diff --git a/generated/google/apis/serviceusage_v1beta1/synth.metadata b/generated/google/apis/serviceusage_v1beta1/synth.metadata index ad685105d..7ee91b7ad 100644 --- a/generated/google/apis/serviceusage_v1beta1/synth.metadata +++ b/generated/google/apis/serviceusage_v1beta1/synth.metadata @@ -4,7 +4,7 @@ "git": { "name": ".", "remote": "https://github.com/googleapis/google-api-ruby-client.git", - "sha": "d53bec90ed2ca3cdd76158f2fc018b05fe3d2027" + "sha": "4d5b98ffca7eaf905a28939051f53ff2881aaf64" } } ]