Skip to content

Commit

Permalink
feat: Automated regeneration of tpu v2alpha1 client (googleapis#16628)
Browse files Browse the repository at this point in the history
Auto-created at 2023-11-05 10:50:01 +0000 using the toys pull request generator.
  • Loading branch information
yoshi-code-bot authored Nov 5, 2023
1 parent 738b57a commit 201f818
Show file tree
Hide file tree
Showing 6 changed files with 250 additions and 2 deletions.
20 changes: 20 additions & 0 deletions api_names_out.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -295088,6 +295088,10 @@
"/tpu:v2alpha1/ListQueuedResourcesResponse/queuedResources/queued_resource": queued_resource
"/tpu:v2alpha1/ListQueuedResourcesResponse/unreachable": unreachable
"/tpu:v2alpha1/ListQueuedResourcesResponse/unreachable/unreachable": unreachable
"/tpu:v2alpha1/ListReservationsResponse": list_reservations_response
"/tpu:v2alpha1/ListReservationsResponse/nextPageToken": next_page_token
"/tpu:v2alpha1/ListReservationsResponse/reservations": reservations
"/tpu:v2alpha1/ListReservationsResponse/reservations/reservation": reservation
"/tpu:v2alpha1/ListRuntimeVersionsResponse": list_runtime_versions_response
"/tpu:v2alpha1/ListRuntimeVersionsResponse/nextPageToken": next_page_token
"/tpu:v2alpha1/ListRuntimeVersionsResponse/runtimeVersions": runtime_versions
Expand Down Expand Up @@ -295170,6 +295174,7 @@
"/tpu:v2alpha1/ProvisioningData": provisioning_data
"/tpu:v2alpha1/QueuedResource": queued_resource
"/tpu:v2alpha1/QueuedResource/bestEffort": best_effort
"/tpu:v2alpha1/QueuedResource/createTime": create_time
"/tpu:v2alpha1/QueuedResource/guaranteed": guaranteed
"/tpu:v2alpha1/QueuedResource/name": name
"/tpu:v2alpha1/QueuedResource/queueingPolicy": queueing_policy
Expand All @@ -295194,6 +295199,9 @@
"/tpu:v2alpha1/QueueingPolicy/validInterval": valid_interval
"/tpu:v2alpha1/QueueingPolicy/validUntilDuration": valid_until_duration
"/tpu:v2alpha1/QueueingPolicy/validUntilTime": valid_until_time
"/tpu:v2alpha1/Reservation": reservation
"/tpu:v2alpha1/Reservation/name": name
"/tpu:v2alpha1/Reservation/standard": standard
"/tpu:v2alpha1/ResetQueuedResourceRequest": reset_queued_resource_request
"/tpu:v2alpha1/RuntimeVersion": runtime_version
"/tpu:v2alpha1/RuntimeVersion/name": name
Expand All @@ -295213,6 +295221,12 @@
"/tpu:v2alpha1/SimulateMaintenanceEventRequest/workerIds": worker_ids
"/tpu:v2alpha1/SimulateMaintenanceEventRequest/workerIds/worker_id": worker_id
"/tpu:v2alpha1/Spot": spot
"/tpu:v2alpha1/Standard": standard
"/tpu:v2alpha1/Standard/capacityUnits": capacity_units
"/tpu:v2alpha1/Standard/interval": interval
"/tpu:v2alpha1/Standard/resourceType": resource_type
"/tpu:v2alpha1/Standard/size": size
"/tpu:v2alpha1/Standard/usage": usage
"/tpu:v2alpha1/StartNodeRequest": start_node_request
"/tpu:v2alpha1/Status": status
"/tpu:v2alpha1/Status/code": code
Expand All @@ -295231,6 +295245,8 @@
"/tpu:v2alpha1/Tpu": tpu
"/tpu:v2alpha1/Tpu/nodeSpec": node_spec
"/tpu:v2alpha1/Tpu/nodeSpec/node_spec": node_spec
"/tpu:v2alpha1/Usage": usage
"/tpu:v2alpha1/Usage/total": total
"/tpu:v2alpha1/fields": fields
"/tpu:v2alpha1/key": key
"/tpu:v2alpha1/quotaUser": quota_user
Expand Down Expand Up @@ -295302,6 +295318,10 @@
"/tpu:v2alpha1/tpu.projects.locations.queuedResources.list/parent": parent
"/tpu:v2alpha1/tpu.projects.locations.queuedResources.reset": reset_queued_resource
"/tpu:v2alpha1/tpu.projects.locations.queuedResources.reset/name": name
"/tpu:v2alpha1/tpu.projects.locations.reservations.list": list_project_location_reservations
"/tpu:v2alpha1/tpu.projects.locations.reservations.list/pageSize": page_size
"/tpu:v2alpha1/tpu.projects.locations.reservations.list/pageToken": page_token
"/tpu:v2alpha1/tpu.projects.locations.reservations.list/parent": parent
"/tpu:v2alpha1/tpu.projects.locations.runtimeVersions.get": get_project_location_runtime_version
"/tpu:v2alpha1/tpu.projects.locations.runtimeVersions.get/name": name
"/tpu:v2alpha1/tpu.projects.locations.runtimeVersions.list": list_project_location_runtime_versions
Expand Down
4 changes: 4 additions & 0 deletions generated/google-apis-tpu_v2alpha1/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
# Release history for google-apis-tpu_v2alpha1

### v0.25.0 (2023-11-05)

* Regenerated from discovery document revision 20231026

### v0.24.0 (2023-08-27)

* Regenerated from discovery document revision 20230814
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -632,6 +632,31 @@ def update!(**args)
end
end

# Response for ListReservations.
class ListReservationsResponse
include Google::Apis::Core::Hashable

# The next page token or empty if none.
# Corresponds to the JSON property `nextPageToken`
# @return [String]
attr_accessor :next_page_token

# The listed reservations.
# Corresponds to the JSON property `reservations`
# @return [Array<Google::Apis::TpuV2alpha1::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

# Response for ListRuntimeVersions.
class ListRuntimeVersionsResponse
include Google::Apis::Core::Hashable
Expand Down Expand Up @@ -1178,6 +1203,11 @@ class QueuedResource
# @return [Google::Apis::TpuV2alpha1::BestEffort]
attr_accessor :best_effort

# Output only. The time when the QueuedResource was created.
# Corresponds to the JSON property `createTime`
# @return [String]
attr_accessor :create_time

# Guaranteed tier definition.
# Corresponds to the JSON property `guaranteed`
# @return [Google::Apis::TpuV2alpha1::Guaranteed]
Expand Down Expand Up @@ -1221,6 +1251,7 @@ def initialize(**args)
# Update properties of this object
def update!(**args)
@best_effort = args[:best_effort] if args.key?(:best_effort)
@create_time = args[:create_time] if args.key?(:create_time)
@guaranteed = args[:guaranteed] if args.key?(:guaranteed)
@name = args[:name] if args.key?(:name)
@queueing_policy = args[:queueing_policy] if args.key?(:queueing_policy)
Expand Down Expand Up @@ -1352,6 +1383,33 @@ def update!(**args)
end
end

# A reservation describes the amount of a resource 'allotted' for a defined
# period of time.
class Reservation
include Google::Apis::Core::Hashable

# The reservation name with the format: projects/`projectID`/locations/`location`
# /reservations/`reservationID`
# Corresponds to the JSON property `name`
# @return [String]
attr_accessor :name

#
# Corresponds to the JSON property `standard`
# @return [Google::Apis::TpuV2alpha1::Standard]
attr_accessor :standard

def initialize(**args)
update!(**args)
end

# Update properties of this object
def update!(**args)
@name = args[:name] if args.key?(:name)
@standard = args[:standard] if args.key?(:standard)
end
end

# Request for ResetQueuedResource.
class ResetQueuedResourceRequest
include Google::Apis::Core::Hashable
Expand Down Expand Up @@ -1518,6 +1576,53 @@ def update!(**args)
end
end

#
class Standard
include Google::Apis::Core::Hashable

#
# Corresponds to the JSON property `capacityUnits`
# @return [String]
attr_accessor :capacity_units

# Represents a time interval, encoded as a Timestamp start (inclusive) and a
# Timestamp end (exclusive). The start must be less than or equal to the end.
# When the start equals the end, the interval is empty (matches no time). When
# both start and end are unspecified, the interval matches any time.
# Corresponds to the JSON property `interval`
# @return [Google::Apis::TpuV2alpha1::Interval]
attr_accessor :interval

# The resource type of the reservation.
# Corresponds to the JSON property `resourceType`
# @return [String]
attr_accessor :resource_type

# The size of the reservation, in the units specified in the 'capacity_units'
# field.
# Corresponds to the JSON property `size`
# @return [Fixnum]
attr_accessor :size

#
# Corresponds to the JSON property `usage`
# @return [Google::Apis::TpuV2alpha1::Usage]
attr_accessor :usage

def initialize(**args)
update!(**args)
end

# Update properties of this object
def update!(**args)
@capacity_units = args[:capacity_units] if args.key?(:capacity_units)
@interval = args[:interval] if args.key?(:interval)
@resource_type = args[:resource_type] if args.key?(:resource_type)
@size = args[:size] if args.key?(:size)
@usage = args[:usage] if args.key?(:usage)
end
end

# Request for StartNode.
class StartNodeRequest
include Google::Apis::Core::Hashable
Expand Down Expand Up @@ -1664,6 +1769,26 @@ def update!(**args)
@node_spec = args[:node_spec] if args.key?(:node_spec)
end
end

#
class Usage
include Google::Apis::Core::Hashable

# The real-time value of usage within the reservation, with the unit specified
# in field capacity_units.
# Corresponds to the JSON property `total`
# @return [Fixnum]
attr_accessor :total

def initialize(**args)
update!(**args)
end

# Update properties of this object
def update!(**args)
@total = args[:total] if args.key?(:total)
end
end
end
end
end
Original file line number Diff line number Diff line change
Expand Up @@ -16,13 +16,13 @@ module Google
module Apis
module TpuV2alpha1
# Version of the google-apis-tpu_v2alpha1 gem
GEM_VERSION = "0.24.0"
GEM_VERSION = "0.25.0"

# Version of the code generator used to generate this client
GENERATOR_VERSION = "0.12.0"

# Revision of the discovery document this client was generated from
REVISION = "20230814"
REVISION = "20231026"
end
end
end
Original file line number Diff line number Diff line change
Expand Up @@ -184,6 +184,12 @@ 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 ListRuntimeVersionsResponse
class Representation < Google::Apis::Core::JsonRepresentation; end

Expand Down Expand Up @@ -262,6 +268,12 @@ 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 ResetQueuedResourceRequest
class Representation < Google::Apis::Core::JsonRepresentation; end

Expand Down Expand Up @@ -310,6 +322,12 @@ class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end

class Standard
class Representation < Google::Apis::Core::JsonRepresentation; end

include Google::Apis::Core::JsonObjectSupport
end

class StartNodeRequest
class Representation < Google::Apis::Core::JsonRepresentation; end

Expand Down Expand Up @@ -352,6 +370,12 @@ class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end

class Usage
class Representation < Google::Apis::Core::JsonRepresentation; end

include Google::Apis::Core::JsonObjectSupport
end

class AcceleratorConfig
# @private
class Representation < Google::Apis::Core::JsonRepresentation
Expand Down Expand Up @@ -565,6 +589,15 @@ class Representation < Google::Apis::Core::JsonRepresentation
end
end

class ListReservationsResponse
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :next_page_token, as: 'nextPageToken'
collection :reservations, as: 'reservations', class: Google::Apis::TpuV2alpha1::Reservation, decorator: Google::Apis::TpuV2alpha1::Reservation::Representation

end
end

class ListRuntimeVersionsResponse
# @private
class Representation < Google::Apis::Core::JsonRepresentation
Expand Down Expand Up @@ -702,6 +735,7 @@ class QueuedResource
class Representation < Google::Apis::Core::JsonRepresentation
property :best_effort, as: 'bestEffort', class: Google::Apis::TpuV2alpha1::BestEffort, decorator: Google::Apis::TpuV2alpha1::BestEffort::Representation

property :create_time, as: 'createTime'
property :guaranteed, as: 'guaranteed', class: Google::Apis::TpuV2alpha1::Guaranteed, decorator: Google::Apis::TpuV2alpha1::Guaranteed::Representation

property :name, as: 'name'
Expand Down Expand Up @@ -753,6 +787,15 @@ class Representation < Google::Apis::Core::JsonRepresentation
end
end

class Reservation
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :name, as: 'name'
property :standard, as: 'standard', class: Google::Apis::TpuV2alpha1::Standard, decorator: Google::Apis::TpuV2alpha1::Standard::Representation

end
end

class ResetQueuedResourceRequest
# @private
class Representation < Google::Apis::Core::JsonRepresentation
Expand Down Expand Up @@ -810,6 +853,19 @@ class Representation < Google::Apis::Core::JsonRepresentation
end
end

class Standard
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :capacity_units, as: 'capacityUnits'
property :interval, as: 'interval', class: Google::Apis::TpuV2alpha1::Interval, decorator: Google::Apis::TpuV2alpha1::Interval::Representation

property :resource_type, as: 'resourceType'
property :size, as: 'size'
property :usage, as: 'usage', class: Google::Apis::TpuV2alpha1::Usage, decorator: Google::Apis::TpuV2alpha1::Usage::Representation

end
end

class StartNodeRequest
# @private
class Representation < Google::Apis::Core::JsonRepresentation
Expand Down Expand Up @@ -860,6 +916,13 @@ class Representation < Google::Apis::Core::JsonRepresentation

end
end

class Usage
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :total, :numeric_string => true, as: 'total'
end
end
end
end
end
Loading

0 comments on commit 201f818

Please sign in to comment.