Autogenerated update (2019-08-23)

Update:
- analyticsreporting_v4
- cloudtasks_v2
- genomics_v2alpha1
- monitoring_v3
- pagespeedonline_v5
- pubsub_v1
- run_v1alpha1
This commit is contained in:
Google APIs 2019-08-23 00:37:52 +00:00
parent 177d39d36e
commit 8f7374dc00
25 changed files with 2284 additions and 60 deletions

View File

@ -25,7 +25,7 @@ module Google
# @see https://developers.google.com/analytics/devguides/reporting/core/v4/ # @see https://developers.google.com/analytics/devguides/reporting/core/v4/
module AnalyticsreportingV4 module AnalyticsreportingV4
VERSION = 'V4' VERSION = 'V4'
REVISION = '20190719' REVISION = '20190821'
# View and manage your Google Analytics data # View and manage your Google Analytics data
AUTH_ANALYTICS = 'https://www.googleapis.com/auth/analytics' AUTH_ANALYTICS = 'https://www.googleapis.com/auth/analytics'

View File

@ -33,7 +33,9 @@ module Google
class Activity class Activity
include Google::Apis::Core::Hashable include Google::Apis::Core::Hashable
# Timestamp of the activity. # Timestamp of the activity. If activities for a visit cross midnight and
# occur in two separate dates, then two sessions (one per date)
# share the session identifier.
# Corresponds to the JSON property `activityTime` # Corresponds to the JSON property `activityTime`
# @return [String] # @return [String]
attr_accessor :activity_time attr_accessor :activity_time

View File

@ -0,0 +1,37 @@
# Copyright 2015 Google Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
require 'google/apis/bigqueryreservation_v1/service.rb'
require 'google/apis/bigqueryreservation_v1/classes.rb'
require 'google/apis/bigqueryreservation_v1/representations.rb'
module Google
module Apis
# BigQuery Reservation API
#
# A service to modify your BigQuery flat-rate reservations.
#
# @see https://cloud.google.com/bigquery/
module BigqueryreservationV1
VERSION = 'V1'
REVISION = '20190816'
# View and manage your data in Google BigQuery
AUTH_BIGQUERY = 'https://www.googleapis.com/auth/bigquery'
# View and manage your data across Google Cloud Platform services
AUTH_CLOUD_PLATFORM = 'https://www.googleapis.com/auth/cloud-platform'
end
end
end

View File

@ -0,0 +1,216 @@
# Copyright 2015 Google Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
require 'date'
require 'google/apis/core/base_service'
require 'google/apis/core/json_representation'
require 'google/apis/core/hashable'
require 'google/apis/errors'
module Google
module Apis
module BigqueryreservationV1
# The metadata for operation returned from
# ReservationService.CreateSlotPool.
class CreateSlotPoolMetadata
include Google::Apis::Core::Hashable
# Resource name of the slot pool that is being created. E.g.,
# projects/myproject/locations/us-central1/reservations/foo/slotPools/123
# Corresponds to the JSON property `slotPool`
# @return [String]
attr_accessor :slot_pool
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@slot_pool = args[:slot_pool] if args.key?(:slot_pool)
end
end
# A generic empty message that you can re-use to avoid defining duplicated
# empty messages in your APIs. A typical example is to use it as the request
# or the response type of an API method. For instance:
# service Foo `
# rpc Bar(google.protobuf.Empty) returns (google.protobuf.Empty);
# `
# The JSON representation for `Empty` is empty JSON object ````.
class Empty
include Google::Apis::Core::Hashable
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
end
end
# The response message for Operations.ListOperations.
class ListOperationsResponse
include Google::Apis::Core::Hashable
# The standard List next-page token.
# Corresponds to the JSON property `nextPageToken`
# @return [String]
attr_accessor :next_page_token
# A list of operations that matches the specified filter in the request.
# Corresponds to the JSON property `operations`
# @return [Array<Google::Apis::BigqueryreservationV1::Operation>]
attr_accessor :operations
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@next_page_token = args[:next_page_token] if args.key?(:next_page_token)
@operations = args[:operations] if args.key?(:operations)
end
end
# BigQuery-specific metadata about a location. This will be set on
# google.cloud.location.Location.metadata in Cloud Location API
# responses.
class LocationMetadata
include Google::Apis::Core::Hashable
# The legacy BigQuery location ID, e.g. “EU” for the “europe” location.
# This is for any API consumers that need the legacy “US” and “EU” locations.
# Corresponds to the JSON property `legacyLocationId`
# @return [String]
attr_accessor :legacy_location_id
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@legacy_location_id = args[:legacy_location_id] if args.key?(:legacy_location_id)
end
end
# This resource represents a long-running operation that is the result of a
# network API call.
class Operation
include Google::Apis::Core::Hashable
# If the value is `false`, it means the operation is still in progress.
# If `true`, the operation is completed, and either `error` or `response` is
# available.
# Corresponds to the JSON property `done`
# @return [Boolean]
attr_accessor :done
alias_method :done?, :done
# The `Status` type defines a logical error model that is suitable for
# different programming environments, including REST APIs and RPC APIs. It is
# used by [gRPC](https://github.com/grpc). Each `Status` message contains
# three pieces of data: error code, error message, and error details.
# You can find out more about this error model and how to work with it in the
# [API Design Guide](https://cloud.google.com/apis/design/errors).
# Corresponds to the JSON property `error`
# @return [Google::Apis::BigqueryreservationV1::Status]
attr_accessor :error
# Service-specific metadata associated with the operation. It typically
# contains progress information and common metadata such as create time.
# Some services might not provide such metadata. Any method that returns a
# long-running operation should document the metadata type, if any.
# Corresponds to the JSON property `metadata`
# @return [Hash<String,Object>]
attr_accessor :metadata
# The server-assigned name, which is only unique within the same service that
# originally returns it. If you use the default HTTP mapping, the
# `name` should be a resource name ending with `operations/`unique_id``.
# Corresponds to the JSON property `name`
# @return [String]
attr_accessor :name
# The normal response of the operation in case of success. If the original
# method returns no data on success, such as `Delete`, the response is
# `google.protobuf.Empty`. If the original method is standard
# `Get`/`Create`/`Update`, the response should be the resource. For other
# methods, the response should have the type `XxxResponse`, where `Xxx`
# is the original method name. For example, if the original method name
# is `TakeSnapshot()`, the inferred response type is
# `TakeSnapshotResponse`.
# Corresponds to the JSON property `response`
# @return [Hash<String,Object>]
attr_accessor :response
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@done = args[:done] if args.key?(:done)
@error = args[:error] if args.key?(:error)
@metadata = args[:metadata] if args.key?(:metadata)
@name = args[:name] if args.key?(:name)
@response = args[:response] if args.key?(:response)
end
end
# The `Status` type defines a logical error model that is suitable for
# different programming environments, including REST APIs and RPC APIs. It is
# used by [gRPC](https://github.com/grpc). Each `Status` message contains
# three pieces of data: error code, error message, and error details.
# You can find out more about this error model and how to work with it in the
# [API Design Guide](https://cloud.google.com/apis/design/errors).
class Status
include Google::Apis::Core::Hashable
# The status code, which should be an enum value of google.rpc.Code.
# Corresponds to the JSON property `code`
# @return [Fixnum]
attr_accessor :code
# A list of messages that carry the error details. There is a common set of
# message types for APIs to use.
# Corresponds to the JSON property `details`
# @return [Array<Hash<String,Object>>]
attr_accessor :details
# A developer-facing error message, which should be in English. Any
# user-facing error message should be localized and sent in the
# google.rpc.Status.details field, or localized by the client.
# Corresponds to the JSON property `message`
# @return [String]
attr_accessor :message
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@code = args[:code] if args.key?(:code)
@details = args[:details] if args.key?(:details)
@message = args[:message] if args.key?(:message)
end
end
end
end
end

View File

@ -0,0 +1,112 @@
# Copyright 2015 Google Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
require 'date'
require 'google/apis/core/base_service'
require 'google/apis/core/json_representation'
require 'google/apis/core/hashable'
require 'google/apis/errors'
module Google
module Apis
module BigqueryreservationV1
class CreateSlotPoolMetadata
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class Empty
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class ListOperationsResponse
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class LocationMetadata
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class Operation
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class Status
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class CreateSlotPoolMetadata
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :slot_pool, as: 'slotPool'
end
end
class Empty
# @private
class Representation < Google::Apis::Core::JsonRepresentation
end
end
class ListOperationsResponse
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :next_page_token, as: 'nextPageToken'
collection :operations, as: 'operations', class: Google::Apis::BigqueryreservationV1::Operation, decorator: Google::Apis::BigqueryreservationV1::Operation::Representation
end
end
class LocationMetadata
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :legacy_location_id, as: 'legacyLocationId'
end
end
class Operation
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :done, as: 'done'
property :error, as: 'error', class: Google::Apis::BigqueryreservationV1::Status, decorator: Google::Apis::BigqueryreservationV1::Status::Representation
hash :metadata, as: 'metadata'
property :name, as: 'name'
hash :response, as: 'response'
end
end
class Status
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :code, as: 'code'
collection :details, as: 'details'
property :message, as: 'message'
end
end
end
end
end

View File

@ -0,0 +1,139 @@
# Copyright 2015 Google Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
require 'google/apis/core/base_service'
require 'google/apis/core/json_representation'
require 'google/apis/core/hashable'
require 'google/apis/errors'
module Google
module Apis
module BigqueryreservationV1
# BigQuery Reservation API
#
# A service to modify your BigQuery flat-rate reservations.
#
# @example
# require 'google/apis/bigqueryreservation_v1'
#
# Bigqueryreservation = Google::Apis::BigqueryreservationV1 # Alias the module
# service = Bigqueryreservation::BigQueryReservationService.new
#
# @see https://cloud.google.com/bigquery/
class BigQueryReservationService < Google::Apis::Core::BaseService
# @return [String]
# API key. Your API key identifies your project and provides you with API access,
# quota, and reports. Required unless you provide an OAuth 2.0 token.
attr_accessor :key
# @return [String]
# 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.
attr_accessor :quota_user
def initialize
super('https://bigqueryreservation.googleapis.com/', '')
@batch_path = 'batch'
end
# Deletes a long-running operation. This method indicates that the client is
# no longer interested in the operation result. It does not cancel the
# operation. If the server doesn't support this method, it returns
# `google.rpc.Code.UNIMPLEMENTED`.
# @param [String] name
# The name of the operation resource to be deleted.
# @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::BigqueryreservationV1::Empty] parsed result object
# @yieldparam err [StandardError] error object if request failed
#
# @return [Google::Apis::BigqueryreservationV1::Empty]
#
# @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 delete_operation(name, fields: nil, quota_user: nil, options: nil, &block)
command = make_simple_command(:delete, 'v1/{+name}', options)
command.response_representation = Google::Apis::BigqueryreservationV1::Empty::Representation
command.response_class = Google::Apis::BigqueryreservationV1::Empty
command.params['name'] = name unless name.nil?
command.query['fields'] = fields unless fields.nil?
command.query['quotaUser'] = quota_user unless quota_user.nil?
execute_or_queue_command(command, &block)
end
# Lists operations that match the specified filter in the request. If the
# server doesn't support this method, it returns `UNIMPLEMENTED`.
# NOTE: the `name` binding allows API services to override the binding
# to use different resource name schemes, such as `users/*/operations`. To
# override the binding, API services can add a binding such as
# `"/v1/`name=users/*`/operations"` to their service configuration.
# For backwards compatibility, the default name includes the operations
# collection id, however overriding users must ensure the name binding
# is the parent resource, without the operations collection id.
# @param [String] name
# The name of the operation's parent resource.
# @param [String] filter
# The standard list filter.
# @param [Fixnum] page_size
# The standard list page size.
# @param [String] page_token
# The standard list page token.
# @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::BigqueryreservationV1::ListOperationsResponse] parsed result object
# @yieldparam err [StandardError] error object if request failed
#
# @return [Google::Apis::BigqueryreservationV1::ListOperationsResponse]
#
# @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 list_operations(name, filter: nil, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil, &block)
command = make_simple_command(:get, 'v1/{+name}', options)
command.response_representation = Google::Apis::BigqueryreservationV1::ListOperationsResponse::Representation
command.response_class = Google::Apis::BigqueryreservationV1::ListOperationsResponse
command.params['name'] = name unless name.nil?
command.query['filter'] = filter unless filter.nil?
command.query['pageSize'] = page_size unless page_size.nil?
command.query['pageToken'] = page_token unless page_token.nil?
command.query['fields'] = fields unless fields.nil?
command.query['quotaUser'] = quota_user unless quota_user.nil?
execute_or_queue_command(command, &block)
end
protected
def apply_command_defaults(command)
command.query['key'] = key unless key.nil?
command.query['quotaUser'] = quota_user unless quota_user.nil?
end
end
end
end
end

View File

@ -0,0 +1,37 @@
# Copyright 2015 Google Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
require 'google/apis/bigqueryreservation_v1alpha2/service.rb'
require 'google/apis/bigqueryreservation_v1alpha2/classes.rb'
require 'google/apis/bigqueryreservation_v1alpha2/representations.rb'
module Google
module Apis
# BigQuery Reservation API
#
# A service to modify your BigQuery flat-rate reservations.
#
# @see https://cloud.google.com/bigquery/
module BigqueryreservationV1alpha2
VERSION = 'V1alpha2'
REVISION = '20190816'
# View and manage your data in Google BigQuery
AUTH_BIGQUERY = 'https://www.googleapis.com/auth/bigquery'
# View and manage your data across Google Cloud Platform services
AUTH_CLOUD_PLATFORM = 'https://www.googleapis.com/auth/cloud-platform'
end
end
end

View File

@ -0,0 +1,514 @@
# Copyright 2015 Google Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
require 'date'
require 'google/apis/core/base_service'
require 'google/apis/core/json_representation'
require 'google/apis/core/hashable'
require 'google/apis/errors'
module Google
module Apis
module BigqueryreservationV1alpha2
# The metadata for operation returned from
# ReservationService.CreateSlotPool.
class CreateSlotPoolMetadata
include Google::Apis::Core::Hashable
# Resource name of the slot pool that is being created. E.g.,
# projects/myproject/locations/us-central1/reservations/foo/slotPools/123
# Corresponds to the JSON property `slotPool`
# @return [String]
attr_accessor :slot_pool
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@slot_pool = args[:slot_pool] if args.key?(:slot_pool)
end
end
# A generic empty message that you can re-use to avoid defining duplicated
# empty messages in your APIs. A typical example is to use it as the request
# or the response type of an API method. For instance:
# service Foo `
# rpc Bar(google.protobuf.Empty) returns (google.protobuf.Empty);
# `
# The JSON representation for `Empty` is empty JSON object ````.
class Empty
include Google::Apis::Core::Hashable
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
end
end
# The response message for Locations.ListLocations.
class ListLocationsResponse
include Google::Apis::Core::Hashable
# A list of locations that matches the specified filter in the request.
# Corresponds to the JSON property `locations`
# @return [Array<Google::Apis::BigqueryreservationV1alpha2::Location>]
attr_accessor :locations
# The standard List next-page token.
# Corresponds to the JSON property `nextPageToken`
# @return [String]
attr_accessor :next_page_token
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@locations = args[:locations] if args.key?(:locations)
@next_page_token = args[:next_page_token] if args.key?(:next_page_token)
end
end
# The response for ReservationService.ListReservationGrants.
class ListReservationGrantsResponse
include Google::Apis::Core::Hashable
# Token to retrieve the next page of results, or empty if there are no
# more results in the list.
# Corresponds to the JSON property `nextPageToken`
# @return [String]
attr_accessor :next_page_token
# List of reservation grants visible to the user.
# Corresponds to the JSON property `reservationGrants`
# @return [Array<Google::Apis::BigqueryreservationV1alpha2::ReservationGrant>]
attr_accessor :reservation_grants
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@next_page_token = args[:next_page_token] if args.key?(:next_page_token)
@reservation_grants = args[:reservation_grants] if args.key?(:reservation_grants)
end
end
# The response for ReservationService.ListReservations.
class ListReservationsResponse
include Google::Apis::Core::Hashable
# Token to retrieve the next page of results, or empty if there are no
# more results in the list.
# Corresponds to the JSON property `nextPageToken`
# @return [String]
attr_accessor :next_page_token
# List of reservations visible to the user.
# Corresponds to the JSON property `reservations`
# @return [Array<Google::Apis::BigqueryreservationV1alpha2::Reservation>]
attr_accessor :reservations
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@next_page_token = args[:next_page_token] if args.key?(:next_page_token)
@reservations = args[:reservations] if args.key?(:reservations)
end
end
# The response for ReservationService.ListSlotPools.
class ListSlotPoolsResponse
include Google::Apis::Core::Hashable
# Token to retrieve the next page of results, or empty if there are no
# more results in the list.
# Corresponds to the JSON property `nextPageToken`
# @return [String]
attr_accessor :next_page_token
# List of slot pools visible to the user.
# Corresponds to the JSON property `slotPools`
# @return [Array<Google::Apis::BigqueryreservationV1alpha2::SlotPool>]
attr_accessor :slot_pools
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@next_page_token = args[:next_page_token] if args.key?(:next_page_token)
@slot_pools = args[:slot_pools] if args.key?(:slot_pools)
end
end
# A resource that represents Google Cloud Platform location.
class Location
include Google::Apis::Core::Hashable
# The friendly name for this location, typically a nearby city name.
# For example, "Tokyo".
# Corresponds to the JSON property `displayName`
# @return [String]
attr_accessor :display_name
# Cross-service attributes for the location. For example
# `"cloud.googleapis.com/region": "us-east1"`
# Corresponds to the JSON property `labels`
# @return [Hash<String,String>]
attr_accessor :labels
# The canonical id for this location. For example: `"us-east1"`.
# Corresponds to the JSON property `locationId`
# @return [String]
attr_accessor :location_id
# Service-specific metadata. For example the available capacity at the given
# location.
# Corresponds to the JSON property `metadata`
# @return [Hash<String,Object>]
attr_accessor :metadata
# Resource name for the location, which may vary between implementations.
# For example: `"projects/example-project/locations/us-east1"`
# Corresponds to the JSON property `name`
# @return [String]
attr_accessor :name
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@display_name = args[:display_name] if args.key?(:display_name)
@labels = args[:labels] if args.key?(:labels)
@location_id = args[:location_id] if args.key?(:location_id)
@metadata = args[:metadata] if args.key?(:metadata)
@name = args[:name] if args.key?(:name)
end
end
# BigQuery-specific metadata about a location. This will be set on
# google.cloud.location.Location.metadata in Cloud Location API
# responses.
class LocationMetadata
include Google::Apis::Core::Hashable
# The legacy BigQuery location ID, e.g. “EU” for the “europe” location.
# This is for any API consumers that need the legacy “US” and “EU” locations.
# Corresponds to the JSON property `legacyLocationId`
# @return [String]
attr_accessor :legacy_location_id
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@legacy_location_id = args[:legacy_location_id] if args.key?(:legacy_location_id)
end
end
# This resource represents a long-running operation that is the result of a
# network API call.
class Operation
include Google::Apis::Core::Hashable
# If the value is `false`, it means the operation is still in progress.
# If `true`, the operation is completed, and either `error` or `response` is
# available.
# Corresponds to the JSON property `done`
# @return [Boolean]
attr_accessor :done
alias_method :done?, :done
# The `Status` type defines a logical error model that is suitable for
# different programming environments, including REST APIs and RPC APIs. It is
# used by [gRPC](https://github.com/grpc). Each `Status` message contains
# three pieces of data: error code, error message, and error details.
# You can find out more about this error model and how to work with it in the
# [API Design Guide](https://cloud.google.com/apis/design/errors).
# Corresponds to the JSON property `error`
# @return [Google::Apis::BigqueryreservationV1alpha2::Status]
attr_accessor :error
# Service-specific metadata associated with the operation. It typically
# contains progress information and common metadata such as create time.
# Some services might not provide such metadata. Any method that returns a
# long-running operation should document the metadata type, if any.
# Corresponds to the JSON property `metadata`
# @return [Hash<String,Object>]
attr_accessor :metadata
# The server-assigned name, which is only unique within the same service that
# originally returns it. If you use the default HTTP mapping, the
# `name` should be a resource name ending with `operations/`unique_id``.
# Corresponds to the JSON property `name`
# @return [String]
attr_accessor :name
# The normal response of the operation in case of success. If the original
# method returns no data on success, such as `Delete`, the response is
# `google.protobuf.Empty`. If the original method is standard
# `Get`/`Create`/`Update`, the response should be the resource. For other
# methods, the response should have the type `XxxResponse`, where `Xxx`
# is the original method name. For example, if the original method name
# is `TakeSnapshot()`, the inferred response type is
# `TakeSnapshotResponse`.
# Corresponds to the JSON property `response`
# @return [Hash<String,Object>]
attr_accessor :response
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@done = args[:done] if args.key?(:done)
@error = args[:error] if args.key?(:error)
@metadata = args[:metadata] if args.key?(:metadata)
@name = args[:name] if args.key?(:name)
@response = args[:response] if args.key?(:response)
end
end
# A reservation is a mechanism used to guarantee slots to users.
class Reservation
include Google::Apis::Core::Hashable
# The resource name of the reservation, e.g.,
# "projects/*/locations/*/reservations/dev/team/product". Reservation names
# (e.g., "dev/team/product") exceeding a depth of six will fail with
# `google.rpc.Code.INVALID_ARGUMENT`.
# Corresponds to the JSON property `name`
# @return [String]
attr_accessor :name
# Maximum slots available to this reservation and its children. A slot is a
# unit of computational power in BigQuery, and serves as the unit of
# parallelism. In a scan of a multi-partitioned table, a single slot operates
# on a single partition of the table.
# If the new reservation's slot capacity exceed the parent's slot capacity or
# if total slot capacity of the new reservation and its siblings exceeds the
# parent's slot capacity, the request will fail with
# `google.rpc.Code.RESOURCE_EXHAUSTED`.
# Corresponds to the JSON property `slotCapacity`
# @return [Fixnum]
attr_accessor :slot_capacity
# If true, any query using this reservation will also be submitted to the
# parent reservation. This allows the query to share the additional slot
# capacity of the parent with other queries in the parent reservation. If the
# parent also has this field set to true, then this process will continue
# until it encounters a reservation for which this is false.
# If false, a query using this reservation will
# execute with the maximum slot capacity as specified above.
# If not specified, default value is true.
# Ignored for top-level reservation.
# Corresponds to the JSON property `useParentReservation`
# @return [Boolean]
attr_accessor :use_parent_reservation
alias_method :use_parent_reservation?, :use_parent_reservation
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@name = args[:name] if args.key?(:name)
@slot_capacity = args[:slot_capacity] if args.key?(:slot_capacity)
@use_parent_reservation = args[:use_parent_reservation] if args.key?(:use_parent_reservation)
end
end
# A ReservationGrant allows a project to submit jobs
# of a certain type using slots from the specified reservation.
class ReservationGrant
include Google::Apis::Core::Hashable
# The resource which will use the reservation. E.g.
# projects/myproject, folders/123, organizations/456.
# Corresponds to the JSON property `grantee`
# @return [String]
attr_accessor :grantee
# Which type of jobs will use the reservation.
# Corresponds to the JSON property `jobType`
# @return [String]
attr_accessor :job_type
# Output only. Name of the resource. E.g.:
# projects/myproject/locations/eu/reservationGrants/123.
# Corresponds to the JSON property `name`
# @return [String]
attr_accessor :name
# Resource name of the reservation.
# E.g., projects/myproject/locations/eu/reservations/my_reservation.
# This reservation must be in the same location as the grant.
# This reservation should belong to the same parent project.
# Corresponds to the JSON property `reservation`
# @return [String]
attr_accessor :reservation
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@grantee = args[:grantee] if args.key?(:grantee)
@job_type = args[:job_type] if args.key?(:job_type)
@name = args[:name] if args.key?(:name)
@reservation = args[:reservation] if args.key?(:reservation)
end
end
# The response for ReservationService.SearchReservationGrants.
class SearchReservationGrantsResponse
include Google::Apis::Core::Hashable
# Token to retrieve the next page of results, or empty if there are no
# more results in the list.
# Corresponds to the JSON property `nextPageToken`
# @return [String]
attr_accessor :next_page_token
# List of reservation grants visible to the user.
# Corresponds to the JSON property `reservationGrants`
# @return [Array<Google::Apis::BigqueryreservationV1alpha2::ReservationGrant>]
attr_accessor :reservation_grants
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@next_page_token = args[:next_page_token] if args.key?(:next_page_token)
@reservation_grants = args[:reservation_grants] if args.key?(:reservation_grants)
end
end
# Slot pool is a way to purchase slots with some minimum committed period of
# usage. Slot pool is immutable and cannot be deleted until the end of the
# commitment period. After the end of the commitment period, slots are still
# available but can be freely removed any time.
# A slot pool resource exists as a child resource of a top-level reservation.
# Sum of all the ACTIVE pools slot_count is always equal to the reservation
# slot_capacity.
class SlotPool
include Google::Apis::Core::Hashable
# Output only. The end of the commitment period. Slot pool cannot be
# removed before commitment_end_time. It is applicable only for ACTIVE slot
# pools and is computed as a combination of the plan and the time when the
# slot pool became ACTIVE.
# Corresponds to the JSON property `commitmentEndTime`
# @return [String]
attr_accessor :commitment_end_time
# Output only. The resource name of the slot pool, e.g.,
# projects/myproject/locations/us-central1/reservations/myreservation/
# slotPools/123
# Corresponds to the JSON property `name`
# @return [String]
attr_accessor :name
# Slot pool commitment plan.
# Corresponds to the JSON property `plan`
# @return [String]
attr_accessor :plan
# Number of slots in this pool.
# Corresponds to the JSON property `slotCount`
# @return [Fixnum]
attr_accessor :slot_count
# Output only.
# Corresponds to the JSON property `state`
# @return [String]
attr_accessor :state
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@commitment_end_time = args[:commitment_end_time] if args.key?(:commitment_end_time)
@name = args[:name] if args.key?(:name)
@plan = args[:plan] if args.key?(:plan)
@slot_count = args[:slot_count] if args.key?(:slot_count)
@state = args[:state] if args.key?(:state)
end
end
# The `Status` type defines a logical error model that is suitable for
# different programming environments, including REST APIs and RPC APIs. It is
# used by [gRPC](https://github.com/grpc). Each `Status` message contains
# three pieces of data: error code, error message, and error details.
# You can find out more about this error model and how to work with it in the
# [API Design Guide](https://cloud.google.com/apis/design/errors).
class Status
include Google::Apis::Core::Hashable
# The status code, which should be an enum value of google.rpc.Code.
# Corresponds to the JSON property `code`
# @return [Fixnum]
attr_accessor :code
# A list of messages that carry the error details. There is a common set of
# message types for APIs to use.
# Corresponds to the JSON property `details`
# @return [Array<Hash<String,Object>>]
attr_accessor :details
# A developer-facing error message, which should be in English. Any
# user-facing error message should be localized and sent in the
# google.rpc.Status.details field, or localized by the client.
# Corresponds to the JSON property `message`
# @return [String]
attr_accessor :message
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@code = args[:code] if args.key?(:code)
@details = args[:details] if args.key?(:details)
@message = args[:message] if args.key?(:message)
end
end
end
end
end

View File

@ -0,0 +1,237 @@
# Copyright 2015 Google Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
require 'date'
require 'google/apis/core/base_service'
require 'google/apis/core/json_representation'
require 'google/apis/core/hashable'
require 'google/apis/errors'
module Google
module Apis
module BigqueryreservationV1alpha2
class CreateSlotPoolMetadata
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class Empty
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class ListLocationsResponse
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class ListReservationGrantsResponse
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class ListReservationsResponse
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class ListSlotPoolsResponse
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class Location
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class LocationMetadata
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class Operation
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class Reservation
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class ReservationGrant
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class SearchReservationGrantsResponse
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class SlotPool
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class Status
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class CreateSlotPoolMetadata
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :slot_pool, as: 'slotPool'
end
end
class Empty
# @private
class Representation < Google::Apis::Core::JsonRepresentation
end
end
class ListLocationsResponse
# @private
class Representation < Google::Apis::Core::JsonRepresentation
collection :locations, as: 'locations', class: Google::Apis::BigqueryreservationV1alpha2::Location, decorator: Google::Apis::BigqueryreservationV1alpha2::Location::Representation
property :next_page_token, as: 'nextPageToken'
end
end
class ListReservationGrantsResponse
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :next_page_token, as: 'nextPageToken'
collection :reservation_grants, as: 'reservationGrants', class: Google::Apis::BigqueryreservationV1alpha2::ReservationGrant, decorator: Google::Apis::BigqueryreservationV1alpha2::ReservationGrant::Representation
end
end
class ListReservationsResponse
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :next_page_token, as: 'nextPageToken'
collection :reservations, as: 'reservations', class: Google::Apis::BigqueryreservationV1alpha2::Reservation, decorator: Google::Apis::BigqueryreservationV1alpha2::Reservation::Representation
end
end
class ListSlotPoolsResponse
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :next_page_token, as: 'nextPageToken'
collection :slot_pools, as: 'slotPools', class: Google::Apis::BigqueryreservationV1alpha2::SlotPool, decorator: Google::Apis::BigqueryreservationV1alpha2::SlotPool::Representation
end
end
class Location
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :display_name, as: 'displayName'
hash :labels, as: 'labels'
property :location_id, as: 'locationId'
hash :metadata, as: 'metadata'
property :name, as: 'name'
end
end
class LocationMetadata
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :legacy_location_id, as: 'legacyLocationId'
end
end
class Operation
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :done, as: 'done'
property :error, as: 'error', class: Google::Apis::BigqueryreservationV1alpha2::Status, decorator: Google::Apis::BigqueryreservationV1alpha2::Status::Representation
hash :metadata, as: 'metadata'
property :name, as: 'name'
hash :response, as: 'response'
end
end
class Reservation
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :name, as: 'name'
property :slot_capacity, :numeric_string => true, as: 'slotCapacity'
property :use_parent_reservation, as: 'useParentReservation'
end
end
class ReservationGrant
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :grantee, as: 'grantee'
property :job_type, as: 'jobType'
property :name, as: 'name'
property :reservation, as: 'reservation'
end
end
class SearchReservationGrantsResponse
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :next_page_token, as: 'nextPageToken'
collection :reservation_grants, as: 'reservationGrants', class: Google::Apis::BigqueryreservationV1alpha2::ReservationGrant, decorator: Google::Apis::BigqueryreservationV1alpha2::ReservationGrant::Representation
end
end
class SlotPool
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :commitment_end_time, as: 'commitmentEndTime'
property :name, as: 'name'
property :plan, as: 'plan'
property :slot_count, :numeric_string => true, as: 'slotCount'
property :state, as: 'state'
end
end
class Status
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :code, as: 'code'
collection :details, as: 'details'
property :message, as: 'message'
end
end
end
end
end

View File

@ -0,0 +1,714 @@
# Copyright 2015 Google Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
require 'google/apis/core/base_service'
require 'google/apis/core/json_representation'
require 'google/apis/core/hashable'
require 'google/apis/errors'
module Google
module Apis
module BigqueryreservationV1alpha2
# BigQuery Reservation API
#
# A service to modify your BigQuery flat-rate reservations.
#
# @example
# require 'google/apis/bigqueryreservation_v1alpha2'
#
# Bigqueryreservation = Google::Apis::BigqueryreservationV1alpha2 # Alias the module
# service = Bigqueryreservation::BigQueryReservationService.new
#
# @see https://cloud.google.com/bigquery/
class BigQueryReservationService < Google::Apis::Core::BaseService
# @return [String]
# API key. Your API key identifies your project and provides you with API access,
# quota, and reports. Required unless you provide an OAuth 2.0 token.
attr_accessor :key
# @return [String]
# 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.
attr_accessor :quota_user
def initialize
super('https://bigqueryreservation.googleapis.com/', '')
@batch_path = 'batch'
end
# Gets information about a location.
# @param [String] name
# Resource name for the location.
# @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::BigqueryreservationV1alpha2::Location] parsed result object
# @yieldparam err [StandardError] error object if request failed
#
# @return [Google::Apis::BigqueryreservationV1alpha2::Location]
#
# @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 get_project_location(name, fields: nil, quota_user: nil, options: nil, &block)
command = make_simple_command(:get, 'v1alpha2/{+name}', options)
command.response_representation = Google::Apis::BigqueryreservationV1alpha2::Location::Representation
command.response_class = Google::Apis::BigqueryreservationV1alpha2::Location
command.params['name'] = name unless name.nil?
command.query['fields'] = fields unless fields.nil?
command.query['quotaUser'] = quota_user unless quota_user.nil?
execute_or_queue_command(command, &block)
end
# Lists information about the supported locations for this service.
# @param [String] name
# The resource that owns the locations collection, if applicable.
# @param [String] filter
# The standard list filter.
# @param [Fixnum] page_size
# The standard list page size.
# @param [String] page_token
# The standard list page token.
# @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::BigqueryreservationV1alpha2::ListLocationsResponse] parsed result object
# @yieldparam err [StandardError] error object if request failed
#
# @return [Google::Apis::BigqueryreservationV1alpha2::ListLocationsResponse]
#
# @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 list_project_locations(name, filter: nil, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil, &block)
command = make_simple_command(:get, 'v1alpha2/{+name}/locations', options)
command.response_representation = Google::Apis::BigqueryreservationV1alpha2::ListLocationsResponse::Representation
command.response_class = Google::Apis::BigqueryreservationV1alpha2::ListLocationsResponse
command.params['name'] = name unless name.nil?
command.query['filter'] = filter unless filter.nil?
command.query['pageSize'] = page_size unless page_size.nil?
command.query['pageToken'] = page_token unless page_token.nil?
command.query['fields'] = fields unless fields.nil?
command.query['quotaUser'] = quota_user unless quota_user.nil?
execute_or_queue_command(command, &block)
end
# Look up grants for a specified resource for a particular region.
# If the request is about a project:
# 1) Grants created on the project will be returned if they exist.
# 2) Otherwise grants created on the closest ancestor will be returned.
# 3) Grants for different JobTypes will all be returned.
# Same logic applies if the request is about a folder.
# If the request is about an organization, then grants created on the
# organization will be returned (organization doesn't have ancestors).
# Comparing to ListReservationGrants, there are two behavior
# differences:
# 1) permission on the grantee will be verified in this API.
# 2) Hierarchy lookup (project->folder->organization) happens in this API.
# @param [String] parent
# The parent resource name (containing project and location), which owns the
# grants. e.g.:
# "projects/myproject/locations/us-central1".
# @param [Fixnum] page_size
# The maximum number of items to return.
# @param [String] page_token
# The next_page_token value returned from a previous List request, if any.
# @param [String] query
# Please specify resource name as grantee in the query.
# e.g., "grantee=projects/myproject"
# "grantee=folders/123"
# "grantee=organizations/456"
# @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::BigqueryreservationV1alpha2::SearchReservationGrantsResponse] parsed result object
# @yieldparam err [StandardError] error object if request failed
#
# @return [Google::Apis::BigqueryreservationV1alpha2::SearchReservationGrantsResponse]
#
# @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 search_project_location_reservation_grants(parent, page_size: nil, page_token: nil, query: nil, fields: nil, quota_user: nil, options: nil, &block)
command = make_simple_command(:get, 'v1alpha2/{+parent}:SearchReservationGrants', options)
command.response_representation = Google::Apis::BigqueryreservationV1alpha2::SearchReservationGrantsResponse::Representation
command.response_class = Google::Apis::BigqueryreservationV1alpha2::SearchReservationGrantsResponse
command.params['parent'] = parent unless parent.nil?
command.query['pageSize'] = page_size unless page_size.nil?
command.query['pageToken'] = page_token unless page_token.nil?
command.query['query'] = query unless query.nil?
command.query['fields'] = fields unless fields.nil?
command.query['quotaUser'] = quota_user unless quota_user.nil?
execute_or_queue_command(command, &block)
end
# Starts asynchronous cancellation on a long-running operation. The server
# makes a best effort to cancel the operation, but success is not
# guaranteed. If the server doesn't support this method, it returns
# `google.rpc.Code.UNIMPLEMENTED`. Clients can use
# Operations.GetOperation or
# other methods to check whether the cancellation succeeded or whether the
# operation completed despite cancellation. On successful cancellation,
# the operation is not deleted; instead, it becomes an operation with
# an Operation.error value with a google.rpc.Status.code of 1,
# corresponding to `Code.CANCELLED`.
# @param [String] name
# The name of the operation resource to be cancelled.
# @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::BigqueryreservationV1alpha2::Empty] parsed result object
# @yieldparam err [StandardError] error object if request failed
#
# @return [Google::Apis::BigqueryreservationV1alpha2::Empty]
#
# @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 cancel_project_location_operation(name, fields: nil, quota_user: nil, options: nil, &block)
command = make_simple_command(:post, 'v1alpha2/{+name}:cancel', options)
command.response_representation = Google::Apis::BigqueryreservationV1alpha2::Empty::Representation
command.response_class = Google::Apis::BigqueryreservationV1alpha2::Empty
command.params['name'] = name unless name.nil?
command.query['fields'] = fields unless fields.nil?
command.query['quotaUser'] = quota_user unless quota_user.nil?
execute_or_queue_command(command, &block)
end
# Gets the latest state of a long-running operation. Clients can use this
# method to poll the operation result at intervals as recommended by the API
# service.
# @param [String] name
# The name of the operation resource.
# @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::BigqueryreservationV1alpha2::Operation] parsed result object
# @yieldparam err [StandardError] error object if request failed
#
# @return [Google::Apis::BigqueryreservationV1alpha2::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 get_project_location_operation(name, fields: nil, quota_user: nil, options: nil, &block)
command = make_simple_command(:get, 'v1alpha2/{+name}', options)
command.response_representation = Google::Apis::BigqueryreservationV1alpha2::Operation::Representation
command.response_class = Google::Apis::BigqueryreservationV1alpha2::Operation
command.params['name'] = name unless name.nil?
command.query['fields'] = fields unless fields.nil?
command.query['quotaUser'] = quota_user unless quota_user.nil?
execute_or_queue_command(command, &block)
end
# Returns `google.rpc.Code.PERMISSION_DENIED` if user does not have
# 'bigquery.admin' permissions on the project using the reservation
# and the project that owns this reservation.
# Returns `google.rpc.Code.INVALID_ARGUMENT` when location of the grant
# does not match location of the reservation.
# @param [String] parent
# The parent resource name of the reservation grant
# E.g.: projects/myproject/location/eu.
# @param [Google::Apis::BigqueryreservationV1alpha2::ReservationGrant] reservation_grant_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::BigqueryreservationV1alpha2::ReservationGrant] parsed result object
# @yieldparam err [StandardError] error object if request failed
#
# @return [Google::Apis::BigqueryreservationV1alpha2::ReservationGrant]
#
# @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 create_project_location_reservation_grant(parent, reservation_grant_object = nil, fields: nil, quota_user: nil, options: nil, &block)
command = make_simple_command(:post, 'v1alpha2/{+parent}/reservationGrants', options)
command.request_representation = Google::Apis::BigqueryreservationV1alpha2::ReservationGrant::Representation
command.request_object = reservation_grant_object
command.response_representation = Google::Apis::BigqueryreservationV1alpha2::ReservationGrant::Representation
command.response_class = Google::Apis::BigqueryreservationV1alpha2::ReservationGrant
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
# Deletes a reservation grant. No expansion will happen.
# E.g:
# organizationA contains project1 and project2. Reservation res1 exists.
# CreateReservationGrant was invoked previously and following grants were
# created explicitly:
# <organizationA, res1>
# <project1, res1>
# Then deletion of <organizationA, res1> won't affect <project1, res1>. After
# deletion of <organizationA, res1>, queries from project1 will still use
# res1, while queries from project2 will use on-demand mode.
# @param [String] name
# Name of the resource, e.g.:
# projects/myproject/locations/eu/reservationGrants/123
# @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::BigqueryreservationV1alpha2::Empty] parsed result object
# @yieldparam err [StandardError] error object if request failed
#
# @return [Google::Apis::BigqueryreservationV1alpha2::Empty]
#
# @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 delete_project_location_reservation_grant(name, fields: nil, quota_user: nil, options: nil, &block)
command = make_simple_command(:delete, 'v1alpha2/{+name}', options)
command.response_representation = Google::Apis::BigqueryreservationV1alpha2::Empty::Representation
command.response_class = Google::Apis::BigqueryreservationV1alpha2::Empty
command.params['name'] = name unless name.nil?
command.query['fields'] = fields unless fields.nil?
command.query['quotaUser'] = quota_user unless quota_user.nil?
execute_or_queue_command(command, &block)
end
# Lists reservation grants.
# Only explicitly created grants will be returned. E.g:
# organizationA contains project1 and project2. Reservation res1 exists.
# CreateReservationGrant was invoked previously and following grants were
# created explicitly:
# <organizationA, res1>
# <project1, res1>
# Then this API will just return the above two grants for reservation res1,
# and no expansion/merge will happen.
# @param [String] parent
# The parent resource name e.g.: projects/myproject/location/eu.
# @param [Fixnum] page_size
# The maximum number of items to return.
# @param [String] page_token
# The next_page_token value returned from a previous List request, if any.
# @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::BigqueryreservationV1alpha2::ListReservationGrantsResponse] parsed result object
# @yieldparam err [StandardError] error object if request failed
#
# @return [Google::Apis::BigqueryreservationV1alpha2::ListReservationGrantsResponse]
#
# @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 list_project_location_reservation_grants(parent, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil, &block)
command = make_simple_command(:get, 'v1alpha2/{+parent}/reservationGrants', options)
command.response_representation = Google::Apis::BigqueryreservationV1alpha2::ListReservationGrantsResponse::Representation
command.response_class = Google::Apis::BigqueryreservationV1alpha2::ListReservationGrantsResponse
command.params['parent'] = parent unless parent.nil?
command.query['pageSize'] = page_size unless page_size.nil?
command.query['pageToken'] = page_token unless page_token.nil?
command.query['fields'] = fields unless fields.nil?
command.query['quotaUser'] = quota_user unless quota_user.nil?
execute_or_queue_command(command, &block)
end
# Creates a new reservation resource. Multiple reservations are created if
# the ancestor reservations do not exist.
# @param [String] parent
# Project, location, and (optionally) reservation name. E.g.,
# projects/myproject/locations/us-central1/reservations/parent
# @param [Google::Apis::BigqueryreservationV1alpha2::Reservation] reservation_object
# @param [String] reservation_id
# The reservation ID relative to the parent, e.g., "dev". This field must
# only contain alphanumeric characters.
# @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::BigqueryreservationV1alpha2::Reservation] parsed result object
# @yieldparam err [StandardError] error object if request failed
#
# @return [Google::Apis::BigqueryreservationV1alpha2::Reservation]
#
# @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 create_project_location_reservation(parent, reservation_object = nil, reservation_id: nil, fields: nil, quota_user: nil, options: nil, &block)
command = make_simple_command(:post, 'v1alpha2/{+parent}/reservations', options)
command.request_representation = Google::Apis::BigqueryreservationV1alpha2::Reservation::Representation
command.request_object = reservation_object
command.response_representation = Google::Apis::BigqueryreservationV1alpha2::Reservation::Representation
command.response_class = Google::Apis::BigqueryreservationV1alpha2::Reservation
command.params['parent'] = parent unless parent.nil?
command.query['reservationId'] = reservation_id unless reservation_id.nil?
command.query['fields'] = fields unless fields.nil?
command.query['quotaUser'] = quota_user unless quota_user.nil?
execute_or_queue_command(command, &block)
end
# Creates a new reservation resource. Multiple reservations are created if
# the ancestor reservations do not exist.
# @param [String] parent
# Project, location, and (optionally) reservation name. E.g.,
# projects/myproject/locations/us-central1/reservations/parent
# @param [Google::Apis::BigqueryreservationV1alpha2::Reservation] reservation_object
# @param [String] reservation_id
# The reservation ID relative to the parent, e.g., "dev". This field must
# only contain alphanumeric characters.
# @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::BigqueryreservationV1alpha2::Reservation] parsed result object
# @yieldparam err [StandardError] error object if request failed
#
# @return [Google::Apis::BigqueryreservationV1alpha2::Reservation]
#
# @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 create_project_location_reservation_reservation(parent, reservation_object = nil, reservation_id: nil, fields: nil, quota_user: nil, options: nil, &block)
command = make_simple_command(:post, 'v1alpha2/{+parent}', options)
command.request_representation = Google::Apis::BigqueryreservationV1alpha2::Reservation::Representation
command.request_object = reservation_object
command.response_representation = Google::Apis::BigqueryreservationV1alpha2::Reservation::Representation
command.response_class = Google::Apis::BigqueryreservationV1alpha2::Reservation
command.params['parent'] = parent unless parent.nil?
command.query['reservationId'] = reservation_id unless reservation_id.nil?
command.query['fields'] = fields unless fields.nil?
command.query['quotaUser'] = quota_user unless quota_user.nil?
execute_or_queue_command(command, &block)
end
# Deletes a reservation.
# Returns `google.rpc.Code.FAILED_PRECONDITION` in the following cases:
# 1. When reservation has child reservations. This check can be bypassed by
# setting DeleteReservationRequest.force flag to true.
# 2. When top-level reservation with slot pools is being deleted.
# @param [String] name
# Resource name of the reservation to retrieve. E.g.,
# projects/myproject/locations/us-central1/reservations/my_reservation
# @param [Boolean] force
# If true, deletes all the child reservations of the given reservation.
# Otherwise, attempting to delete a reservation that has child
# reservations will fail with error code
# `google.rpc.Code.FAILED_PRECONDITION`.
# @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::BigqueryreservationV1alpha2::Empty] parsed result object
# @yieldparam err [StandardError] error object if request failed
#
# @return [Google::Apis::BigqueryreservationV1alpha2::Empty]
#
# @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 delete_project_location_reservation(name, force: nil, fields: nil, quota_user: nil, options: nil, &block)
command = make_simple_command(:delete, 'v1alpha2/{+name}', options)
command.response_representation = Google::Apis::BigqueryreservationV1alpha2::Empty::Representation
command.response_class = Google::Apis::BigqueryreservationV1alpha2::Empty
command.params['name'] = name unless name.nil?
command.query['force'] = force unless force.nil?
command.query['fields'] = fields unless fields.nil?
command.query['quotaUser'] = quota_user unless quota_user.nil?
execute_or_queue_command(command, &block)
end
# Returns information about the reservation.
# @param [String] name
# Resource name of the reservation to retrieve. E.g.,
# projects/myproject/locations/us-central1/reservations/path/to/reserv
# @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::BigqueryreservationV1alpha2::Reservation] parsed result object
# @yieldparam err [StandardError] error object if request failed
#
# @return [Google::Apis::BigqueryreservationV1alpha2::Reservation]
#
# @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 get_project_location_reservation(name, fields: nil, quota_user: nil, options: nil, &block)
command = make_simple_command(:get, 'v1alpha2/{+name}', options)
command.response_representation = Google::Apis::BigqueryreservationV1alpha2::Reservation::Representation
command.response_class = Google::Apis::BigqueryreservationV1alpha2::Reservation
command.params['name'] = name unless name.nil?
command.query['fields'] = fields unless fields.nil?
command.query['quotaUser'] = quota_user unless quota_user.nil?
execute_or_queue_command(command, &block)
end
# Lists all the reservations for the project in the specified location.
# @param [String] parent
# The parent resource name containing project and location, e.g.:
# "projects/myproject/locations/us-central1"
# @param [String] filter
# Can be used to filter out reservations based on names, capacity, etc, e.g.:
# filter="reservation.slot_capacity > 200"
# filter="reservation.name = \"*dev/*\""
# Advanced filtering syntax can be
# [here](https://cloud.google.com/logging/docs/view/advanced-filters).
# @param [Fixnum] page_size
# The maximum number of items to return.
# @param [String] page_token
# The next_page_token value returned from a previous List request, if any.
# @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::BigqueryreservationV1alpha2::ListReservationsResponse] parsed result object
# @yieldparam err [StandardError] error object if request failed
#
# @return [Google::Apis::BigqueryreservationV1alpha2::ListReservationsResponse]
#
# @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 list_project_location_reservations(parent, filter: nil, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil, &block)
command = make_simple_command(:get, 'v1alpha2/{+parent}/reservations', options)
command.response_representation = Google::Apis::BigqueryreservationV1alpha2::ListReservationsResponse::Representation
command.response_class = Google::Apis::BigqueryreservationV1alpha2::ListReservationsResponse
command.params['parent'] = parent unless parent.nil?
command.query['filter'] = filter unless filter.nil?
command.query['pageSize'] = page_size unless page_size.nil?
command.query['pageToken'] = page_token unless page_token.nil?
command.query['fields'] = fields unless fields.nil?
command.query['quotaUser'] = quota_user unless quota_user.nil?
execute_or_queue_command(command, &block)
end
# Updates an existing reservation resource. Applicable only for child
# reservations.
# @param [String] name
# The resource name of the reservation, e.g.,
# "projects/*/locations/*/reservations/dev/team/product". Reservation names
# (e.g., "dev/team/product") exceeding a depth of six will fail with
# `google.rpc.Code.INVALID_ARGUMENT`.
# @param [Google::Apis::BigqueryreservationV1alpha2::Reservation] reservation_object
# @param [String] update_mask
# Standard field mask for the set of fields to be updated.
# @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::BigqueryreservationV1alpha2::Reservation] parsed result object
# @yieldparam err [StandardError] error object if request failed
#
# @return [Google::Apis::BigqueryreservationV1alpha2::Reservation]
#
# @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 patch_project_location_reservation(name, reservation_object = nil, update_mask: nil, fields: nil, quota_user: nil, options: nil, &block)
command = make_simple_command(:patch, 'v1alpha2/{+name}', options)
command.request_representation = Google::Apis::BigqueryreservationV1alpha2::Reservation::Representation
command.request_object = reservation_object
command.response_representation = Google::Apis::BigqueryreservationV1alpha2::Reservation::Representation
command.response_class = Google::Apis::BigqueryreservationV1alpha2::Reservation
command.params['name'] = name unless name.nil?
command.query['updateMask'] = update_mask unless update_mask.nil?
command.query['fields'] = fields unless fields.nil?
command.query['quotaUser'] = quota_user unless quota_user.nil?
execute_or_queue_command(command, &block)
end
# Deletes a slot pool. Attempting to delete slot pool before its
# commitment_end_time will fail with the error code
# `google.rpc.Code.FAILED_PRECONDITION`.
# @param [String] name
# Resource name of the slot pool to delete. E.g.,
# projects/myproject/locations/us-central1/reservations/my_reservation/
# slotPools/123
# @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::BigqueryreservationV1alpha2::Empty] parsed result object
# @yieldparam err [StandardError] error object if request failed
#
# @return [Google::Apis::BigqueryreservationV1alpha2::Empty]
#
# @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 delete_project_location_reservation_slot_pool(name, fields: nil, quota_user: nil, options: nil, &block)
command = make_simple_command(:delete, 'v1alpha2/{+name}', options)
command.response_representation = Google::Apis::BigqueryreservationV1alpha2::Empty::Representation
command.response_class = Google::Apis::BigqueryreservationV1alpha2::Empty
command.params['name'] = name unless name.nil?
command.query['fields'] = fields unless fields.nil?
command.query['quotaUser'] = quota_user unless quota_user.nil?
execute_or_queue_command(command, &block)
end
# Returns information about the slot pool.
# @param [String] name
# Resource name of the slot pool to retrieve. E.g.,
# projects/myproject/locations/us-central1/reservations/my_reservation/
# slotPools/123
# @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::BigqueryreservationV1alpha2::SlotPool] parsed result object
# @yieldparam err [StandardError] error object if request failed
#
# @return [Google::Apis::BigqueryreservationV1alpha2::SlotPool]
#
# @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 get_project_location_reservation_slot_pool(name, fields: nil, quota_user: nil, options: nil, &block)
command = make_simple_command(:get, 'v1alpha2/{+name}', options)
command.response_representation = Google::Apis::BigqueryreservationV1alpha2::SlotPool::Representation
command.response_class = Google::Apis::BigqueryreservationV1alpha2::SlotPool
command.params['name'] = name unless name.nil?
command.query['fields'] = fields unless fields.nil?
command.query['quotaUser'] = quota_user unless quota_user.nil?
execute_or_queue_command(command, &block)
end
# Lists all the slot pools for the reservation.
# @param [String] parent
# Resource name of the parent reservation. Only top-level reservations can
# have slot pools. E.g.,
# projects/myproject/locations/us-central1/reservations/my_reservation
# @param [Fixnum] page_size
# The maximum number of items to return.
# @param [String] page_token
# The next_page_token value returned from a previous List request, if any.
# @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::BigqueryreservationV1alpha2::ListSlotPoolsResponse] parsed result object
# @yieldparam err [StandardError] error object if request failed
#
# @return [Google::Apis::BigqueryreservationV1alpha2::ListSlotPoolsResponse]
#
# @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 list_project_location_reservation_slot_pools(parent, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil, &block)
command = make_simple_command(:get, 'v1alpha2/{+parent}/slotPools', options)
command.response_representation = Google::Apis::BigqueryreservationV1alpha2::ListSlotPoolsResponse::Representation
command.response_class = Google::Apis::BigqueryreservationV1alpha2::ListSlotPoolsResponse
command.params['parent'] = parent unless parent.nil?
command.query['pageSize'] = page_size unless page_size.nil?
command.query['pageToken'] = page_token unless page_token.nil?
command.query['fields'] = fields unless fields.nil?
command.query['quotaUser'] = quota_user unless quota_user.nil?
execute_or_queue_command(command, &block)
end
protected
def apply_command_defaults(command)
command.query['key'] = key unless key.nil?
command.query['quotaUser'] = quota_user unless quota_user.nil?
end
end
end
end
end

View File

@ -25,7 +25,7 @@ module Google
# @see https://cloud.google.com/tasks/ # @see https://cloud.google.com/tasks/
module CloudtasksV2 module CloudtasksV2
VERSION = 'V2' VERSION = 'V2'
REVISION = '20190531' REVISION = '20190813'
# View and manage your data across Google Cloud Platform services # View and manage your data across Google Cloud Platform services
AUTH_CLOUD_PLATFORM = 'https://www.googleapis.com/auth/cloud-platform' AUTH_CLOUD_PLATFORM = 'https://www.googleapis.com/auth/cloud-platform'

View File

@ -46,11 +46,10 @@ module Google
# protocol. # protocol.
# The AppEngineRouting used to construct the URL that the task is # The AppEngineRouting used to construct the URL that the task is
# delivered to can be set at the queue-level or task-level: # delivered to can be set at the queue-level or task-level:
# * If set, # * If app_engine_routing_override is set on the
# app_engine_routing_override # queue, this value is used for all
# is used for all tasks in the queue, no matter what the setting # tasks in the queue, no matter what the setting is for the task-level
# is for the # app_engine_routing.
# task-level app_engine_routing.
# The `url` that the task will be sent to is: # The `url` that the task will be sent to is:
# * `url =` host `+` # * `url =` host `+`
# relative_uri # relative_uri
@ -94,6 +93,12 @@ module Google
# and [App Engine Flex request # and [App Engine Flex request
# routing](https://cloud.google.com/appengine/docs/flexible/python/how-requests- # routing](https://cloud.google.com/appengine/docs/flexible/python/how-requests-
# are-routed). # are-routed).
# Using AppEngineRouting requires
# [`appengine.applications.get`](https://cloud.google.com/appengine/docs/admin-
# api/access-control)
# Google IAM permission for the project
# and the following scope:
# `https://www.googleapis.com/auth/cloud-platform`
# Corresponds to the JSON property `appEngineRouting` # Corresponds to the JSON property `appEngineRouting`
# @return [Google::Apis::CloudtasksV2::AppEngineRouting] # @return [Google::Apis::CloudtasksV2::AppEngineRouting]
attr_accessor :app_engine_routing attr_accessor :app_engine_routing
@ -199,6 +204,12 @@ module Google
# and [App Engine Flex request # and [App Engine Flex request
# routing](https://cloud.google.com/appengine/docs/flexible/python/how-requests- # routing](https://cloud.google.com/appengine/docs/flexible/python/how-requests-
# are-routed). # are-routed).
# Using AppEngineRouting requires
# [`appengine.applications.get`](https://cloud.google.com/appengine/docs/admin-
# api/access-control)
# Google IAM permission for the project
# and the following scope:
# `https://www.googleapis.com/auth/cloud-platform`
class AppEngineRouting class AppEngineRouting
include Google::Apis::Core::Hashable include Google::Apis::Core::Hashable
@ -347,7 +358,7 @@ module Google
# * `allAuthenticatedUsers`: A special identifier that represents anyone # * `allAuthenticatedUsers`: A special identifier that represents anyone
# who is authenticated with a Google account or a service account. # who is authenticated with a Google account or a service account.
# * `user:`emailid``: An email address that represents a specific Google # * `user:`emailid``: An email address that represents a specific Google
# account. For example, `alice@gmail.com` . # account. For example, `alice@example.com` .
# * `serviceAccount:`emailid``: An email address that represents a service # * `serviceAccount:`emailid``: An email address that represents a service
# account. For example, `my-other-app@appspot.gserviceaccount.com`. # account. For example, `my-other-app@appspot.gserviceaccount.com`.
# * `group:`emailid``: An email address that represents a Google group. # * `group:`emailid``: An email address that represents a Google group.
@ -480,12 +491,40 @@ module Google
class GetIamPolicyRequest class GetIamPolicyRequest
include Google::Apis::Core::Hashable include Google::Apis::Core::Hashable
# Encapsulates settings provided to GetIamPolicy.
# Corresponds to the JSON property `options`
# @return [Google::Apis::CloudtasksV2::GetPolicyOptions]
attr_accessor :options
def initialize(**args) def initialize(**args)
update!(**args) update!(**args)
end end
# Update properties of this object # Update properties of this object
def update!(**args) def update!(**args)
@options = args[:options] if args.key?(:options)
end
end
# Encapsulates settings provided to GetIamPolicy.
class GetPolicyOptions
include Google::Apis::Core::Hashable
# Optional. The policy format version to be returned.
# Acceptable values are 0, 1, and 3.
# If the value is 0, or the field is omitted, policy format version 1 will be
# returned.
# Corresponds to the JSON property `requestedPolicyVersion`
# @return [Fixnum]
attr_accessor :requested_policy_version
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@requested_policy_version = args[:requested_policy_version] if args.key?(:requested_policy_version)
end end
end end
@ -687,7 +726,7 @@ module Google
# systems are expected to put that etag in the request to `setIamPolicy` to # systems are expected to put that etag in the request to `setIamPolicy` to
# ensure that their change will be applied to the same version of the policy. # ensure that their change will be applied to the same version of the policy.
# If no `etag` is provided in the call to `setIamPolicy`, then the existing # If no `etag` is provided in the call to `setIamPolicy`, then the existing
# policy is overwritten blindly. # policy is overwritten.
# Corresponds to the JSON property `etag` # Corresponds to the JSON property `etag`
# NOTE: Values are automatically base64 encoded/decoded in the client library. # NOTE: Values are automatically base64 encoded/decoded in the client library.
# @return [String] # @return [String]
@ -745,6 +784,12 @@ module Google
# and [App Engine Flex request # and [App Engine Flex request
# routing](https://cloud.google.com/appengine/docs/flexible/python/how-requests- # routing](https://cloud.google.com/appengine/docs/flexible/python/how-requests-
# are-routed). # are-routed).
# Using AppEngineRouting requires
# [`appengine.applications.get`](https://cloud.google.com/appengine/docs/admin-
# api/access-control)
# Google IAM permission for the project
# and the following scope:
# `https://www.googleapis.com/auth/cloud-platform`
# Corresponds to the JSON property `appEngineRoutingOverride` # Corresponds to the JSON property `appEngineRoutingOverride`
# @return [Google::Apis::CloudtasksV2::AppEngineRouting] # @return [Google::Apis::CloudtasksV2::AppEngineRouting]
attr_accessor :app_engine_routing_override attr_accessor :app_engine_routing_override
@ -849,7 +894,7 @@ module Google
# Cloud Tasks will pick the value of `max_burst_size` based on the # Cloud Tasks will pick the value of `max_burst_size` based on the
# value of # value of
# max_dispatches_per_second. # max_dispatches_per_second.
# For App Engine queues that were created or updated using # For queues that were created or updated using
# `queue.yaml/xml`, `max_burst_size` is equal to # `queue.yaml/xml`, `max_burst_size` is equal to
# [bucket_size](https://cloud.google.com/appengine/docs/standard/python/config/ # [bucket_size](https://cloud.google.com/appengine/docs/standard/python/config/
# queueref#bucket_size). # queueref#bucket_size).
@ -883,8 +928,7 @@ module Google
# The maximum rate at which tasks are dispatched from this queue. # The maximum rate at which tasks are dispatched from this queue.
# If unspecified when the queue is created, Cloud Tasks will pick the # If unspecified when the queue is created, Cloud Tasks will pick the
# default. # default.
# * For App Engine queues, the maximum allowed value # * The maximum allowed value is 500.
# is 500.
# This field has the same meaning as # This field has the same meaning as
# [rate in # [rate in
# queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/ # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/
@ -1179,11 +1223,10 @@ module Google
# protocol. # protocol.
# The AppEngineRouting used to construct the URL that the task is # The AppEngineRouting used to construct the URL that the task is
# delivered to can be set at the queue-level or task-level: # delivered to can be set at the queue-level or task-level:
# * If set, # * If app_engine_routing_override is set on the
# app_engine_routing_override # queue, this value is used for all
# is used for all tasks in the queue, no matter what the setting # tasks in the queue, no matter what the setting is for the task-level
# is for the # app_engine_routing.
# task-level app_engine_routing.
# The `url` that the task will be sent to is: # The `url` that the task will be sent to is:
# * `url =` host `+` # * `url =` host `+`
# relative_uri # relative_uri
@ -1292,8 +1335,7 @@ module Google
# @return [Fixnum] # @return [Fixnum]
attr_accessor :response_count attr_accessor :response_count
# The time when the task is scheduled to be attempted. # The time when the task is scheduled to be attempted or retried.
# For App Engine queues, this is when the task will be attempted or retried.
# `schedule_time` will be truncated to the nearest microsecond. # `schedule_time` will be truncated to the nearest microsecond.
# Corresponds to the JSON property `scheduleTime` # Corresponds to the JSON property `scheduleTime`
# @return [String] # @return [String]

View File

@ -70,6 +70,12 @@ module Google
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
end end
class GetPolicyOptions
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class ListLocationsResponse class ListLocationsResponse
class Representation < Google::Apis::Core::JsonRepresentation; end class Representation < Google::Apis::Core::JsonRepresentation; end
@ -243,6 +249,15 @@ module Google
class GetIamPolicyRequest class GetIamPolicyRequest
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
property :options, as: 'options', class: Google::Apis::CloudtasksV2::GetPolicyOptions, decorator: Google::Apis::CloudtasksV2::GetPolicyOptions::Representation
end
end
class GetPolicyOptions
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :requested_policy_version, as: 'requestedPolicyVersion'
end end
end end

View File

@ -128,8 +128,7 @@ module Google
# queue.yaml](https://cloud.google.com/tasks/docs/queue-yaml) before using # queue.yaml](https://cloud.google.com/tasks/docs/queue-yaml) before using
# this method. # this method.
# @param [String] parent # @param [String] parent
# Required. # Required. The location name in which the queue will be created.
# The location name in which the queue will be created.
# For example: `projects/PROJECT_ID/locations/LOCATION_ID` # For example: `projects/PROJECT_ID/locations/LOCATION_ID`
# The list of allowed locations can be obtained by calling Cloud # The list of allowed locations can be obtained by calling Cloud
# Tasks' implementation of # Tasks' implementation of
@ -175,8 +174,7 @@ module Google
# queue.yaml](https://cloud.google.com/tasks/docs/queue-yaml) before using # queue.yaml](https://cloud.google.com/tasks/docs/queue-yaml) before using
# this method. # this method.
# @param [String] name # @param [String] name
# Required. # Required. The queue name. For example:
# The queue name. For example:
# `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID` # `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID`
# @param [String] fields # @param [String] fields
# Selector specifying which fields to include in a partial response. # Selector specifying which fields to include in a partial response.
@ -207,8 +205,7 @@ module Google
# Gets a queue. # Gets a queue.
# @param [String] name # @param [String] name
# Required. # Required. The resource name of the queue. For example:
# The resource name of the queue. For example:
# `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID` # `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID`
# @param [String] fields # @param [String] fields
# Selector specifying which fields to include in a partial response. # Selector specifying which fields to include in a partial response.
@ -280,8 +277,7 @@ module Google
# Lists queues. # Lists queues.
# Queues are returned in lexicographical order. # Queues are returned in lexicographical order.
# @param [String] parent # @param [String] parent
# Required. # Required. The location name.
# The location name.
# For example: `projects/PROJECT_ID/locations/LOCATION_ID` # For example: `projects/PROJECT_ID/locations/LOCATION_ID`
# @param [String] filter # @param [String] filter
# `filter` can be used to specify a subset of queues. Any Queue # `filter` can be used to specify a subset of queues. Any Queue
@ -410,8 +406,7 @@ module Google
# when the queue is paused. A queue is paused if its # when the queue is paused. A queue is paused if its
# state is PAUSED. # state is PAUSED.
# @param [String] name # @param [String] name
# Required. # Required. The queue name. For example:
# The queue name. For example:
# `projects/PROJECT_ID/location/LOCATION_ID/queues/QUEUE_ID` # `projects/PROJECT_ID/location/LOCATION_ID/queues/QUEUE_ID`
# @param [Google::Apis::CloudtasksV2::PauseQueueRequest] pause_queue_request_object # @param [Google::Apis::CloudtasksV2::PauseQueueRequest] pause_queue_request_object
# @param [String] fields # @param [String] fields
@ -448,8 +443,7 @@ module Google
# Purge operations can take up to one minute to take effect. Tasks # Purge operations can take up to one minute to take effect. Tasks
# might be dispatched before the purge takes effect. A purge is irreversible. # might be dispatched before the purge takes effect. A purge is irreversible.
# @param [String] name # @param [String] name
# Required. # Required. The queue name. For example:
# The queue name. For example:
# `projects/PROJECT_ID/location/LOCATION_ID/queues/QUEUE_ID` # `projects/PROJECT_ID/location/LOCATION_ID/queues/QUEUE_ID`
# @param [Google::Apis::CloudtasksV2::PurgeQueueRequest] purge_queue_request_object # @param [Google::Apis::CloudtasksV2::PurgeQueueRequest] purge_queue_request_object
# @param [String] fields # @param [String] fields
@ -493,8 +487,7 @@ module Google
# [Managing Cloud Tasks Scaling # [Managing Cloud Tasks Scaling
# Risks](https://cloud.google.com/tasks/docs/manage-cloud-task-scaling). # Risks](https://cloud.google.com/tasks/docs/manage-cloud-task-scaling).
# @param [String] name # @param [String] name
# Required. # Required. The queue name. For example:
# The queue name. For example:
# `projects/PROJECT_ID/location/LOCATION_ID/queues/QUEUE_ID` # `projects/PROJECT_ID/location/LOCATION_ID/queues/QUEUE_ID`
# @param [Google::Apis::CloudtasksV2::ResumeQueueRequest] resume_queue_request_object # @param [Google::Apis::CloudtasksV2::ResumeQueueRequest] resume_queue_request_object
# @param [String] fields # @param [String] fields
@ -610,8 +603,7 @@ module Google
# Tasks cannot be updated after creation; there is no UpdateTask command. # Tasks cannot be updated after creation; there is no UpdateTask command.
# * The maximum task size is 100KB. # * The maximum task size is 100KB.
# @param [String] parent # @param [String] parent
# Required. # Required. The queue name. For example:
# The queue name. For example:
# `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID` # `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID`
# The queue must already exist. # The queue must already exist.
# @param [Google::Apis::CloudtasksV2::CreateTaskRequest] create_task_request_object # @param [Google::Apis::CloudtasksV2::CreateTaskRequest] create_task_request_object
@ -649,8 +641,7 @@ module Google
# cannot be deleted if it has executed successfully or permanently # cannot be deleted if it has executed successfully or permanently
# failed. # failed.
# @param [String] name # @param [String] name
# Required. # Required. The task name. For example:
# The task name. For example:
# `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID/tasks/TASK_ID` # `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID/tasks/TASK_ID`
# @param [String] fields # @param [String] fields
# Selector specifying which fields to include in a partial response. # Selector specifying which fields to include in a partial response.
@ -681,8 +672,7 @@ module Google
# Gets a task. # Gets a task.
# @param [String] name # @param [String] name
# Required. # Required. The task name. For example:
# The task name. For example:
# `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID/tasks/TASK_ID` # `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID/tasks/TASK_ID`
# @param [String] response_view # @param [String] response_view
# The response_view specifies which subset of the Task will be # The response_view specifies which subset of the Task will be
@ -731,8 +721,7 @@ module Google
# The tasks may be returned in any order. The ordering may change at any # The tasks may be returned in any order. The ordering may change at any
# time. # time.
# @param [String] parent # @param [String] parent
# Required. # Required. The queue name. For example:
# The queue name. For example:
# `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID` # `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID`
# @param [Fixnum] page_size # @param [Fixnum] page_size
# Maximum page size. # Maximum page size.
@ -810,8 +799,7 @@ module Google
# NOT_FOUND when it is called on a # NOT_FOUND when it is called on a
# task that has already succeeded or permanently failed. # task that has already succeeded or permanently failed.
# @param [String] name # @param [String] name
# Required. # Required. The task name. For example:
# The task name. For example:
# `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID/tasks/TASK_ID` # `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID/tasks/TASK_ID`
# @param [Google::Apis::CloudtasksV2::RunTaskRequest] run_task_request_object # @param [Google::Apis::CloudtasksV2::RunTaskRequest] run_task_request_object
# @param [String] fields # @param [String] fields

View File

@ -25,7 +25,7 @@ module Google
# @see https://cloud.google.com/genomics # @see https://cloud.google.com/genomics
module GenomicsV2alpha1 module GenomicsV2alpha1
VERSION = 'V2alpha1' VERSION = 'V2alpha1'
REVISION = '20190813' REVISION = '20190822'
# View and manage your data across Google Cloud Platform services # View and manage your data across Google Cloud Platform services
AUTH_CLOUD_PLATFORM = 'https://www.googleapis.com/auth/cloud-platform' AUTH_CLOUD_PLATFORM = 'https://www.googleapis.com/auth/cloud-platform'

View File

@ -77,8 +77,8 @@ module Google
attr_accessor :entrypoint attr_accessor :entrypoint
# The environment to pass into the container. This environment is merged # The environment to pass into the container. This environment is merged
# with any values specified in the `Pipeline` message. These values # with values specified in the google.genomics.v2alpha1.Pipeline
# overwrite any in the `Pipeline` message. # message, overwriting any duplicate values.
# In addition to the values passed here, a few other values are # In addition to the values passed here, a few other values are
# automatically injected into the environment. These cannot be hidden or # automatically injected into the environment. These cannot be hidden or
# overwritten. # overwritten.
@ -98,10 +98,19 @@ module Google
# @return [Array<String>] # @return [Array<String>]
attr_accessor :flags attr_accessor :flags
# The URI to pull the container image from. Note that all images referenced # Required. The URI to pull the container image from. Note that all images
# referenced
# by actions in the pipeline are pulled before the first action runs. If # by actions in the pipeline are pulled before the first action runs. If
# multiple actions reference the same image, it is only pulled once, # multiple actions reference the same image, it is only pulled once,
# ensuring that the same image is used for all actions in a single pipeline. # ensuring that the same image is used for all actions in a single pipeline.
# The image URI can be either a complete host and image specification (e.g.,
# quay.io/biocontainers/samtools), a library and image name (e.g.,
# google/cloud-sdk) or a bare image name ('bash') to pull from the default
# library. No schema is required in any of these cases.
# If the specified image is not public, the service account specified for
# the Virtual Machine must have access to pull the images from GCR, or
# appropriate credentials must be specified in the
# google.genomics.v2alpha1.Action.credentials field.
# Corresponds to the JSON property `imageUri` # Corresponds to the JSON property `imageUri`
# @return [String] # @return [String]
attr_accessor :image_uri attr_accessor :image_uri
@ -1265,8 +1274,9 @@ module Google
alias_method :enable_stackdriver_monitoring?, :enable_stackdriver_monitoring alias_method :enable_stackdriver_monitoring?, :enable_stackdriver_monitoring
# Optional set of labels to apply to the VM and any attached disk resources. # Optional set of labels to apply to the VM and any attached disk resources.
# These labels must adhere to the name and value restrictions on VM labels # These labels must adhere to the [name and value
# imposed by Compute Engine. # restrictions](https://cloud.google.com/compute/docs/labeling-resources) on
# VM labels imposed by Compute Engine.
# Labels keys with the prefix 'google-' are reserved for use by Google. # Labels keys with the prefix 'google-' are reserved for use by Google.
# Labels applied at creation time to the VM. Applied on a best-effort basis # Labels applied at creation time to the VM. Applied on a best-effort basis
# to attached disk resources shortly after VM creation. # to attached disk resources shortly after VM creation.
@ -1274,7 +1284,8 @@ module Google
# @return [Hash<String,String>] # @return [Hash<String,String>]
attr_accessor :labels attr_accessor :labels
# The machine type of the virtual machine to create. Must be the short name # Required. The machine type of the virtual machine to create. Must be the short
# name
# of a standard machine type (such as "n1-standard-1") or a custom machine # of a standard machine type (such as "n1-standard-1") or a custom machine
# type (such as "custom-1-4096", where "1" indicates the number of vCPUs and # type (such as "custom-1-4096", where "1" indicates the number of vCPUs and
# "4096" indicates the memory in MB). See # "4096" indicates the memory in MB). See

View File

@ -47,7 +47,11 @@ module Google
@batch_path = 'batch' @batch_path = 'batch'
end end
# Runs a pipeline. # Runs a pipeline. The returned Operation's metadata field will contain a
# google.genomics.v2alpha1.Metadata object describing the status of the
# pipeline execution. The [response] field will contain a
# google.genomics.v2alpha1.RunPipelineResponse object if the pipeline
# completes successfully.
# **Note:** Before you can use this method, the Genomics Service Agent # **Note:** Before you can use this method, the Genomics Service Agent
# must have access to your project. This is done automatically when the # must have access to your project. This is done automatically when the
# Cloud Genomics API is first enabled, but if you delete this permission, # Cloud Genomics API is first enabled, but if you delete this permission,

View File

@ -30,7 +30,7 @@ module Google
# @see https://cloud.google.com/monitoring/api/ # @see https://cloud.google.com/monitoring/api/
module MonitoringV3 module MonitoringV3
VERSION = 'V3' VERSION = 'V3'
REVISION = '20190805' REVISION = '20190816'
# View and manage your data across Google Cloud Platform services # View and manage your data across Google Cloud Platform services
AUTH_CLOUD_PLATFORM = 'https://www.googleapis.com/auth/cloud-platform' AUTH_CLOUD_PLATFORM = 'https://www.googleapis.com/auth/cloud-platform'

View File

@ -2321,7 +2321,7 @@ module Google
# is specified, the start time defaults to the value of the end time, and the # is specified, the start time defaults to the value of the end time, and the
# interval represents a single point in time. Such an interval is valid only # interval represents a single point in time. Such an interval is valid only
# for GAUGE metrics, which are point-in-time measurements. # for GAUGE metrics, which are point-in-time measurements.
# For DELTA and CUMULATIVE metrics, the start time must be later than the end # For DELTA and CUMULATIVE metrics, the start time must be earlier than the end
# time. # time.
# In all cases, the start time of the next interval must be at least a # In all cases, the start time of the next interval must be at least a
# microsecond after the end time of the previous interval. Because the interval # microsecond after the end time of the previous interval. Because the interval
@ -2527,7 +2527,7 @@ module Google
# is specified, the start time defaults to the value of the end time, and the # is specified, the start time defaults to the value of the end time, and the
# interval represents a single point in time. Such an interval is valid only # interval represents a single point in time. Such an interval is valid only
# for GAUGE metrics, which are point-in-time measurements. # for GAUGE metrics, which are point-in-time measurements.
# For DELTA and CUMULATIVE metrics, the start time must be later than the end # For DELTA and CUMULATIVE metrics, the start time must be earlier than the end
# time. # time.
# In all cases, the start time of the next interval must be at least a # In all cases, the start time of the next interval must be at least a
# microsecond after the end time of the previous interval. Because the interval # microsecond after the end time of the previous interval. Because the interval

View File

@ -26,7 +26,7 @@ module Google
# @see https://developers.google.com/speed/docs/insights/v5/get-started # @see https://developers.google.com/speed/docs/insights/v5/get-started
module PagespeedonlineV5 module PagespeedonlineV5
VERSION = 'V5' VERSION = 'V5'
REVISION = '20190725' REVISION = '20190821'
end end
end end
end end

View File

@ -25,7 +25,7 @@ module Google
# @see https://cloud.google.com/pubsub/docs # @see https://cloud.google.com/pubsub/docs
module PubsubV1 module PubsubV1
VERSION = 'V1' VERSION = 'V1'
REVISION = '20190808' REVISION = '20190812'
# View and manage your data across Google Cloud Platform services # View and manage your data across Google Cloud Platform services
AUTH_CLOUD_PLATFORM = 'https://www.googleapis.com/auth/cloud-platform' AUTH_CLOUD_PLATFORM = 'https://www.googleapis.com/auth/cloud-platform'

View File

@ -630,8 +630,9 @@ module Google
class PullRequest class PullRequest
include Google::Apis::Core::Hashable include Google::Apis::Core::Hashable
# The maximum number of messages returned for this request. The Pub/Sub # The maximum number of messages to return for this request. Must be a
# system may return fewer than the number specified. # positive integer. The Pub/Sub system may return fewer than the number
# specified.
# Corresponds to the JSON property `maxMessages` # Corresponds to the JSON property `maxMessages`
# @return [Fixnum] # @return [Fixnum]
attr_accessor :max_messages attr_accessor :max_messages

View File

@ -26,7 +26,7 @@ module Google
# @see https://cloud.google.com/run/ # @see https://cloud.google.com/run/
module RunV1alpha1 module RunV1alpha1
VERSION = 'V1alpha1' VERSION = 'V1alpha1'
REVISION = '20190809' REVISION = '20190816'
# View and manage your data across Google Cloud Platform services # View and manage your data across Google Cloud Platform services
AUTH_CLOUD_PLATFORM = 'https://www.googleapis.com/auth/cloud-platform' AUTH_CLOUD_PLATFORM = 'https://www.googleapis.com/auth/cloud-platform'

View File

@ -1392,6 +1392,45 @@ module Google
end end
end end
# The `Status` type defines a logical error model that is suitable for
# different programming environments, including REST APIs and RPC APIs. It is
# used by [gRPC](https://github.com/grpc). Each `Status` message contains
# three pieces of data: error code, error message, and error details.
# You can find out more about this error model and how to work with it in the
# [API Design Guide](https://cloud.google.com/apis/design/errors).
class GoogleRpcStatus
include Google::Apis::Core::Hashable
# The status code, which should be an enum value of google.rpc.Code.
# Corresponds to the JSON property `code`
# @return [Fixnum]
attr_accessor :code
# A list of messages that carry the error details. There is a common set of
# message types for APIs to use.
# Corresponds to the JSON property `details`
# @return [Array<Hash<String,Object>>]
attr_accessor :details
# A developer-facing error message, which should be in English. Any
# user-facing error message should be localized and sent in the
# google.rpc.Status.details field, or localized by the client.
# Corresponds to the JSON property `message`
# @return [String]
attr_accessor :message
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@code = args[:code] if args.key?(:code)
@details = args[:details] if args.key?(:details)
@message = args[:message] if args.key?(:message)
end
end
# HTTPGetAction describes an action based on HTTP Get requests. # HTTPGetAction describes an action based on HTTP Get requests.
class HttpGetAction class HttpGetAction
include Google::Apis::Core::Hashable include Google::Apis::Core::Hashable
@ -1694,6 +1733,12 @@ module Google
# @return [Google::Apis::RunV1alpha1::ListMeta] # @return [Google::Apis::RunV1alpha1::ListMeta]
attr_accessor :metadata attr_accessor :metadata
# Details for the regions used during a global call including any failures.
# This is not populated when targeting a specific region.
# Corresponds to the JSON property `regionDetails`
# @return [Hash<String,Google::Apis::RunV1alpha1::RegionDetails>]
attr_accessor :region_details
# Locations that could not be reached. # Locations that could not be reached.
# Corresponds to the JSON property `unreachable` # Corresponds to the JSON property `unreachable`
# @return [Array<String>] # @return [Array<String>]
@ -1709,6 +1754,7 @@ module Google
@items = args[:items] if args.key?(:items) @items = args[:items] if args.key?(:items)
@kind = args[:kind] if args.key?(:kind) @kind = args[:kind] if args.key?(:kind)
@metadata = args[:metadata] if args.key?(:metadata) @metadata = args[:metadata] if args.key?(:metadata)
@region_details = args[:region_details] if args.key?(:region_details)
@unreachable = args[:unreachable] if args.key?(:unreachable) @unreachable = args[:unreachable] if args.key?(:unreachable)
end end
end end
@ -1739,6 +1785,12 @@ module Google
# @return [Google::Apis::RunV1alpha1::ListMeta] # @return [Google::Apis::RunV1alpha1::ListMeta]
attr_accessor :metadata attr_accessor :metadata
# Details for the regions used during a global call including any failures.
# This is not populated when targeting a specific region.
# Corresponds to the JSON property `regionDetails`
# @return [Hash<String,Google::Apis::RunV1alpha1::RegionDetails>]
attr_accessor :region_details
def initialize(**args) def initialize(**args)
update!(**args) update!(**args)
end end
@ -1749,6 +1801,7 @@ module Google
@items = args[:items] if args.key?(:items) @items = args[:items] if args.key?(:items)
@kind = args[:kind] if args.key?(:kind) @kind = args[:kind] if args.key?(:kind)
@metadata = args[:metadata] if args.key?(:metadata) @metadata = args[:metadata] if args.key?(:metadata)
@region_details = args[:region_details] if args.key?(:region_details)
end end
end end
@ -1778,6 +1831,12 @@ module Google
# @return [Google::Apis::RunV1alpha1::ListMeta] # @return [Google::Apis::RunV1alpha1::ListMeta]
attr_accessor :metadata attr_accessor :metadata
# Details for the regions used during a global call including any failures.
# This is not populated when targeting a specific region.
# Corresponds to the JSON property `regionDetails`
# @return [Hash<String,Google::Apis::RunV1alpha1::RegionDetails>]
attr_accessor :region_details
# Locations that could not be reached. # Locations that could not be reached.
# Corresponds to the JSON property `unreachable` # Corresponds to the JSON property `unreachable`
# @return [Array<String>] # @return [Array<String>]
@ -1793,6 +1852,7 @@ module Google
@items = args[:items] if args.key?(:items) @items = args[:items] if args.key?(:items)
@kind = args[:kind] if args.key?(:kind) @kind = args[:kind] if args.key?(:kind)
@metadata = args[:metadata] if args.key?(:metadata) @metadata = args[:metadata] if args.key?(:metadata)
@region_details = args[:region_details] if args.key?(:region_details)
@unreachable = args[:unreachable] if args.key?(:unreachable) @unreachable = args[:unreachable] if args.key?(:unreachable)
end end
end end
@ -1899,6 +1959,12 @@ module Google
# @return [Google::Apis::RunV1alpha1::ListMeta] # @return [Google::Apis::RunV1alpha1::ListMeta]
attr_accessor :metadata attr_accessor :metadata
# Details for the regions used during a global call including any failures.
# This is not populated when targeting a specific region.
# Corresponds to the JSON property `regionDetails`
# @return [Hash<String,Google::Apis::RunV1alpha1::RegionDetails>]
attr_accessor :region_details
# Locations that could not be reached. # Locations that could not be reached.
# Corresponds to the JSON property `unreachable` # Corresponds to the JSON property `unreachable`
# @return [Array<String>] # @return [Array<String>]
@ -1914,6 +1980,7 @@ module Google
@items = args[:items] if args.key?(:items) @items = args[:items] if args.key?(:items)
@kind = args[:kind] if args.key?(:kind) @kind = args[:kind] if args.key?(:kind)
@metadata = args[:metadata] if args.key?(:metadata) @metadata = args[:metadata] if args.key?(:metadata)
@region_details = args[:region_details] if args.key?(:region_details)
@unreachable = args[:unreachable] if args.key?(:unreachable) @unreachable = args[:unreachable] if args.key?(:unreachable)
end end
end end
@ -1944,6 +2011,12 @@ module Google
# @return [Google::Apis::RunV1alpha1::ListMeta] # @return [Google::Apis::RunV1alpha1::ListMeta]
attr_accessor :metadata attr_accessor :metadata
# Details for the regions used during a global call including any failures.
# This is not populated when targeting a specific region.
# Corresponds to the JSON property `regionDetails`
# @return [Hash<String,Google::Apis::RunV1alpha1::RegionDetails>]
attr_accessor :region_details
# Locations that could not be reached. # Locations that could not be reached.
# Corresponds to the JSON property `unreachable` # Corresponds to the JSON property `unreachable`
# @return [Array<String>] # @return [Array<String>]
@ -1959,6 +2032,7 @@ module Google
@items = args[:items] if args.key?(:items) @items = args[:items] if args.key?(:items)
@kind = args[:kind] if args.key?(:kind) @kind = args[:kind] if args.key?(:kind)
@metadata = args[:metadata] if args.key?(:metadata) @metadata = args[:metadata] if args.key?(:metadata)
@region_details = args[:region_details] if args.key?(:region_details)
@unreachable = args[:unreachable] if args.key?(:unreachable) @unreachable = args[:unreachable] if args.key?(:unreachable)
end end
end end
@ -1989,6 +2063,12 @@ module Google
# @return [Google::Apis::RunV1alpha1::ListMeta] # @return [Google::Apis::RunV1alpha1::ListMeta]
attr_accessor :metadata attr_accessor :metadata
# Details for the regions used during a global call including any failures.
# This is not populated when targeting a specific region.
# Corresponds to the JSON property `regionDetails`
# @return [Hash<String,Google::Apis::RunV1alpha1::RegionDetails>]
attr_accessor :region_details
# Locations that could not be reached. # Locations that could not be reached.
# Corresponds to the JSON property `unreachable` # Corresponds to the JSON property `unreachable`
# @return [Array<String>] # @return [Array<String>]
@ -2004,6 +2084,7 @@ module Google
@items = args[:items] if args.key?(:items) @items = args[:items] if args.key?(:items)
@kind = args[:kind] if args.key?(:kind) @kind = args[:kind] if args.key?(:kind)
@metadata = args[:metadata] if args.key?(:metadata) @metadata = args[:metadata] if args.key?(:metadata)
@region_details = args[:region_details] if args.key?(:region_details)
@unreachable = args[:unreachable] if args.key?(:unreachable) @unreachable = args[:unreachable] if args.key?(:unreachable)
end end
end end
@ -2034,6 +2115,12 @@ module Google
# @return [Google::Apis::RunV1alpha1::ListMeta] # @return [Google::Apis::RunV1alpha1::ListMeta]
attr_accessor :metadata attr_accessor :metadata
# Details for the regions used during a global call including any failures.
# This is not populated when targeting a specific region.
# Corresponds to the JSON property `regionDetails`
# @return [Hash<String,Google::Apis::RunV1alpha1::RegionDetails>]
attr_accessor :region_details
# Locations that could not be reached. # Locations that could not be reached.
# Corresponds to the JSON property `unreachable` # Corresponds to the JSON property `unreachable`
# @return [Array<String>] # @return [Array<String>]
@ -2049,6 +2136,7 @@ module Google
@items = args[:items] if args.key?(:items) @items = args[:items] if args.key?(:items)
@kind = args[:kind] if args.key?(:kind) @kind = args[:kind] if args.key?(:kind)
@metadata = args[:metadata] if args.key?(:metadata) @metadata = args[:metadata] if args.key?(:metadata)
@region_details = args[:region_details] if args.key?(:region_details)
@unreachable = args[:unreachable] if args.key?(:unreachable) @unreachable = args[:unreachable] if args.key?(:unreachable)
end end
end end
@ -2646,6 +2734,30 @@ module Google
end end
end end
# Information for a regional call used for a global API.
class RegionDetails
include Google::Apis::Core::Hashable
# The `Status` type defines a logical error model that is suitable for
# different programming environments, including REST APIs and RPC APIs. It is
# used by [gRPC](https://github.com/grpc). Each `Status` message contains
# three pieces of data: error code, error message, and error details.
# You can find out more about this error model and how to work with it in the
# [API Design Guide](https://cloud.google.com/apis/design/errors).
# Corresponds to the JSON property `error`
# @return [Google::Apis::RunV1alpha1::GoogleRpcStatus]
attr_accessor :error
def initialize(**args)
update!(**args)
end
# Update properties of this object
def update!(**args)
@error = args[:error] if args.key?(:error)
end
end
# A DNS resource record. # A DNS resource record.
class ResourceRecord class ResourceRecord
include Google::Apis::Core::Hashable include Google::Apis::Core::Hashable

View File

@ -196,6 +196,12 @@ module Google
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
end end
class GoogleRpcStatus
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class HttpGetAction class HttpGetAction
class Representation < Google::Apis::Core::JsonRepresentation; end class Representation < Google::Apis::Core::JsonRepresentation; end
@ -352,6 +358,12 @@ module Google
include Google::Apis::Core::JsonObjectSupport include Google::Apis::Core::JsonObjectSupport
end end
class RegionDetails
class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end
class ResourceRecord class ResourceRecord
class Representation < Google::Apis::Core::JsonRepresentation; end class Representation < Google::Apis::Core::JsonRepresentation; end
@ -913,6 +925,15 @@ module Google
end end
end end
class GoogleRpcStatus
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :code, as: 'code'
collection :details, as: 'details'
property :message, as: 'message'
end
end
class HttpGetAction class HttpGetAction
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation
@ -1007,6 +1028,8 @@ module Google
property :kind, as: 'kind' property :kind, as: 'kind'
property :metadata, as: 'metadata', class: Google::Apis::RunV1alpha1::ListMeta, decorator: Google::Apis::RunV1alpha1::ListMeta::Representation property :metadata, as: 'metadata', class: Google::Apis::RunV1alpha1::ListMeta, decorator: Google::Apis::RunV1alpha1::ListMeta::Representation
hash :region_details, as: 'regionDetails', class: Google::Apis::RunV1alpha1::RegionDetails, decorator: Google::Apis::RunV1alpha1::RegionDetails::Representation
collection :unreachable, as: 'unreachable' collection :unreachable, as: 'unreachable'
end end
end end
@ -1020,6 +1043,8 @@ module Google
property :kind, as: 'kind' property :kind, as: 'kind'
property :metadata, as: 'metadata', class: Google::Apis::RunV1alpha1::ListMeta, decorator: Google::Apis::RunV1alpha1::ListMeta::Representation property :metadata, as: 'metadata', class: Google::Apis::RunV1alpha1::ListMeta, decorator: Google::Apis::RunV1alpha1::ListMeta::Representation
hash :region_details, as: 'regionDetails', class: Google::Apis::RunV1alpha1::RegionDetails, decorator: Google::Apis::RunV1alpha1::RegionDetails::Representation
end end
end end
@ -1032,6 +1057,8 @@ module Google
property :kind, as: 'kind' property :kind, as: 'kind'
property :metadata, as: 'metadata', class: Google::Apis::RunV1alpha1::ListMeta, decorator: Google::Apis::RunV1alpha1::ListMeta::Representation property :metadata, as: 'metadata', class: Google::Apis::RunV1alpha1::ListMeta, decorator: Google::Apis::RunV1alpha1::ListMeta::Representation
hash :region_details, as: 'regionDetails', class: Google::Apis::RunV1alpha1::RegionDetails, decorator: Google::Apis::RunV1alpha1::RegionDetails::Representation
collection :unreachable, as: 'unreachable' collection :unreachable, as: 'unreachable'
end end
end end
@ -1063,6 +1090,8 @@ module Google
property :kind, as: 'kind' property :kind, as: 'kind'
property :metadata, as: 'metadata', class: Google::Apis::RunV1alpha1::ListMeta, decorator: Google::Apis::RunV1alpha1::ListMeta::Representation property :metadata, as: 'metadata', class: Google::Apis::RunV1alpha1::ListMeta, decorator: Google::Apis::RunV1alpha1::ListMeta::Representation
hash :region_details, as: 'regionDetails', class: Google::Apis::RunV1alpha1::RegionDetails, decorator: Google::Apis::RunV1alpha1::RegionDetails::Representation
collection :unreachable, as: 'unreachable' collection :unreachable, as: 'unreachable'
end end
end end
@ -1076,6 +1105,8 @@ module Google
property :kind, as: 'kind' property :kind, as: 'kind'
property :metadata, as: 'metadata', class: Google::Apis::RunV1alpha1::ListMeta, decorator: Google::Apis::RunV1alpha1::ListMeta::Representation property :metadata, as: 'metadata', class: Google::Apis::RunV1alpha1::ListMeta, decorator: Google::Apis::RunV1alpha1::ListMeta::Representation
hash :region_details, as: 'regionDetails', class: Google::Apis::RunV1alpha1::RegionDetails, decorator: Google::Apis::RunV1alpha1::RegionDetails::Representation
collection :unreachable, as: 'unreachable' collection :unreachable, as: 'unreachable'
end end
end end
@ -1089,6 +1120,8 @@ module Google
property :kind, as: 'kind' property :kind, as: 'kind'
property :metadata, as: 'metadata', class: Google::Apis::RunV1alpha1::ListMeta, decorator: Google::Apis::RunV1alpha1::ListMeta::Representation property :metadata, as: 'metadata', class: Google::Apis::RunV1alpha1::ListMeta, decorator: Google::Apis::RunV1alpha1::ListMeta::Representation
hash :region_details, as: 'regionDetails', class: Google::Apis::RunV1alpha1::RegionDetails, decorator: Google::Apis::RunV1alpha1::RegionDetails::Representation
collection :unreachable, as: 'unreachable' collection :unreachable, as: 'unreachable'
end end
end end
@ -1102,6 +1135,8 @@ module Google
property :kind, as: 'kind' property :kind, as: 'kind'
property :metadata, as: 'metadata', class: Google::Apis::RunV1alpha1::ListMeta, decorator: Google::Apis::RunV1alpha1::ListMeta::Representation property :metadata, as: 'metadata', class: Google::Apis::RunV1alpha1::ListMeta, decorator: Google::Apis::RunV1alpha1::ListMeta::Representation
hash :region_details, as: 'regionDetails', class: Google::Apis::RunV1alpha1::RegionDetails, decorator: Google::Apis::RunV1alpha1::RegionDetails::Representation
collection :unreachable, as: 'unreachable' collection :unreachable, as: 'unreachable'
end end
end end
@ -1205,6 +1240,14 @@ module Google
end end
end end
class RegionDetails
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :error, as: 'error', class: Google::Apis::RunV1alpha1::GoogleRpcStatus, decorator: Google::Apis::RunV1alpha1::GoogleRpcStatus::Representation
end
end
class ResourceRecord class ResourceRecord
# @private # @private
class Representation < Google::Apis::Core::JsonRepresentation class Representation < Google::Apis::Core::JsonRepresentation