Skip to content

Commit

Permalink
feat: Automated regeneration of WorkloadManager client (#12722)
Browse files Browse the repository at this point in the history
Auto-created at 2024-12-14 13:14:51 +0000 using the toys pull request generator.
  • Loading branch information
yoshi-code-bot authored Dec 14, 2024
1 parent b0aad8d commit e16b009
Show file tree
Hide file tree
Showing 9 changed files with 125 additions and 5 deletions.
2 changes: 1 addition & 1 deletion clients/workload_manager/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ Install this package from [Hex](https://hex.pm) by adding

```elixir
def deps do
[{:google_api_workload_manager, "~> 0.10"}]
[{:google_api_workload_manager, "~> 0.11"}]
end
```

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -992,7 +992,7 @@ defmodule GoogleApi.WorkloadManager.V1.Api.Projects do
end

@doc """
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`.
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`.
## Parameters
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ defmodule GoogleApi.WorkloadManager.V1 do
API client metadata for GoogleApi.WorkloadManager.V1.
"""

@discovery_revision "20241016"
@discovery_revision "20241209"

def discovery_revision(), do: @discovery_revision
end
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@ defmodule GoogleApi.WorkloadManager.V1.Model.Evaluation do
* `createTime` (*type:* `DateTime.t`, *default:* `nil`) - Output only. [Output only] Create time stamp
* `customRulesBucket` (*type:* `String.t`, *default:* `nil`) - The Cloud Storage bucket name for custom rules.
* `description` (*type:* `String.t`, *default:* `nil`) - Description of the Evaluation
* `evaluationType` (*type:* `String.t`, *default:* `nil`) - Evaluation type
* `labels` (*type:* `map()`, *default:* `nil`) - Labels as key value pairs
* `name` (*type:* `String.t`, *default:* `nil`) - name of resource names have the form 'projects/{project_id}/locations/{location_id}/evaluations/{evaluation_id}'
* `resourceFilter` (*type:* `GoogleApi.WorkloadManager.V1.Model.ResourceFilter.t`, *default:* `nil`) - annotations as key value pairs
Expand All @@ -43,6 +44,7 @@ defmodule GoogleApi.WorkloadManager.V1.Model.Evaluation do
:createTime => DateTime.t() | nil,
:customRulesBucket => String.t() | nil,
:description => String.t() | nil,
:evaluationType => String.t() | nil,
:labels => map() | nil,
:name => String.t() | nil,
:resourceFilter => GoogleApi.WorkloadManager.V1.Model.ResourceFilter.t() | nil,
Expand All @@ -57,6 +59,7 @@ defmodule GoogleApi.WorkloadManager.V1.Model.Evaluation do
field(:createTime, as: DateTime)
field(:customRulesBucket)
field(:description)
field(:evaluationType)
field(:labels, type: :map)
field(:name)
field(:resourceFilter, as: GoogleApi.WorkloadManager.V1.Model.ResourceFilter)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@ defmodule GoogleApi.WorkloadManager.V1.Model.Execution do
* `labels` (*type:* `map()`, *default:* `nil`) - Labels as key value pairs
* `name` (*type:* `String.t`, *default:* `nil`) - The name of execution resource. The format is projects/{project}/locations/{location}/evaluations/{evaluation}/executions/{execution}
* `notices` (*type:* `list(GoogleApi.WorkloadManager.V1.Model.Notice.t)`, *default:* `nil`) - Output only. Additional information generated by the execution
* `resultSummary` (*type:* `GoogleApi.WorkloadManager.V1.Model.Summary.t`, *default:* `nil`) - Output only. [Output only] Result summary
* `ruleResults` (*type:* `list(GoogleApi.WorkloadManager.V1.Model.RuleExecutionResult.t)`, *default:* `nil`) - Output only. execution result summary per rule
* `runType` (*type:* `String.t`, *default:* `nil`) - type represent whether the execution executed directly by user or scheduled according evaluation.schedule field.
* `startTime` (*type:* `DateTime.t`, *default:* `nil`) - Output only. [Output only] Start time stamp
Expand All @@ -45,6 +46,7 @@ defmodule GoogleApi.WorkloadManager.V1.Model.Execution do
:labels => map() | nil,
:name => String.t() | nil,
:notices => list(GoogleApi.WorkloadManager.V1.Model.Notice.t()) | nil,
:resultSummary => GoogleApi.WorkloadManager.V1.Model.Summary.t() | nil,
:ruleResults => list(GoogleApi.WorkloadManager.V1.Model.RuleExecutionResult.t()) | nil,
:runType => String.t() | nil,
:startTime => DateTime.t() | nil,
Expand All @@ -63,6 +65,7 @@ defmodule GoogleApi.WorkloadManager.V1.Model.Execution do
field(:labels, type: :map)
field(:name)
field(:notices, as: GoogleApi.WorkloadManager.V1.Model.Notice, type: :list)
field(:resultSummary, as: GoogleApi.WorkloadManager.V1.Model.Summary)
field(:ruleResults, as: GoogleApi.WorkloadManager.V1.Model.RuleExecutionResult, type: :list)
field(:runType)
field(:startTime, as: DateTime)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@ defmodule GoogleApi.WorkloadManager.V1.Model.Insight do
* `sapValidation` (*type:* `GoogleApi.WorkloadManager.V1.Model.SapValidation.t`, *default:* `nil`) - The insights data for the SAP workload validation.
* `sentTime` (*type:* `DateTime.t`, *default:* `nil`) - Output only. [Output only] Create time stamp
* `sqlserverValidation` (*type:* `GoogleApi.WorkloadManager.V1.Model.SqlserverValidation.t`, *default:* `nil`) - The insights data for the sqlserver workload validation.
* `torsoValidation` (*type:* `GoogleApi.WorkloadManager.V1.Model.TorsoValidation.t`, *default:* `nil`) - The insights data for workload validation of torso workloads.
"""

use GoogleApi.Gax.ModelBase
Expand All @@ -35,14 +36,17 @@ defmodule GoogleApi.WorkloadManager.V1.Model.Insight do
:sapDiscovery => GoogleApi.WorkloadManager.V1.Model.SapDiscovery.t() | nil,
:sapValidation => GoogleApi.WorkloadManager.V1.Model.SapValidation.t() | nil,
:sentTime => DateTime.t() | nil,
:sqlserverValidation => GoogleApi.WorkloadManager.V1.Model.SqlserverValidation.t() | nil
:sqlserverValidation =>
GoogleApi.WorkloadManager.V1.Model.SqlserverValidation.t() | nil,
:torsoValidation => GoogleApi.WorkloadManager.V1.Model.TorsoValidation.t() | nil
}

field(:instanceId)
field(:sapDiscovery, as: GoogleApi.WorkloadManager.V1.Model.SapDiscovery)
field(:sapValidation, as: GoogleApi.WorkloadManager.V1.Model.SapValidation)
field(:sentTime, as: DateTime)
field(:sqlserverValidation, as: GoogleApi.WorkloadManager.V1.Model.SqlserverValidation)
field(:torsoValidation, as: GoogleApi.WorkloadManager.V1.Model.TorsoValidation)
end

defimpl Poison.Decoder, for: GoogleApi.WorkloadManager.V1.Model.Insight do
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,52 @@
# Copyright 2019 Google LLC
#
# 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.

# NOTE: This file is auto generated by the elixir code generator program.
# Do not edit this file manually.

defmodule GoogleApi.WorkloadManager.V1.Model.Summary do
@moduledoc """
Message for execution summary
## Attributes
* `failures` (*type:* `String.t`, *default:* `nil`) - Output only. Number of failures
* `newFailures` (*type:* `String.t`, *default:* `nil`) - Output only. Number of new failures compared to the previous execution
* `newFixes` (*type:* `String.t`, *default:* `nil`) - Output only. Number of new fixes compared to the previous execution
"""

use GoogleApi.Gax.ModelBase

@type t :: %__MODULE__{
:failures => String.t() | nil,
:newFailures => String.t() | nil,
:newFixes => String.t() | nil
}

field(:failures)
field(:newFailures)
field(:newFixes)
end

defimpl Poison.Decoder, for: GoogleApi.WorkloadManager.V1.Model.Summary do
def decode(value, options) do
GoogleApi.WorkloadManager.V1.Model.Summary.decode(value, options)
end
end

defimpl Poison.Encoder, for: GoogleApi.WorkloadManager.V1.Model.Summary do
def encode(value, options) do
GoogleApi.Gax.ModelBase.encode(value, options)
end
end
Original file line number Diff line number Diff line change
@@ -0,0 +1,58 @@
# Copyright 2019 Google LLC
#
# 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.

# NOTE: This file is auto generated by the elixir code generator program.
# Do not edit this file manually.

defmodule GoogleApi.WorkloadManager.V1.Model.TorsoValidation do
@moduledoc """
The schema of torso workload validation data.
## Attributes
* `agentVersion` (*type:* `String.t`, *default:* `nil`) - Required. agent_version lists the version of the agent that collected this data.
* `instanceName` (*type:* `String.t`, *default:* `nil`) - Required. instance_name lists the human readable name of the instance that the data comes from.
* `projectId` (*type:* `String.t`, *default:* `nil`) - Required. project_id lists the human readable cloud project that the data comes from.
* `validationDetails` (*type:* `map()`, *default:* `nil`) - Required. validation_details contains the pairs of validation data: field name & field value.
* `workloadType` (*type:* `String.t`, *default:* `nil`) - Required. workload_type specifies the type of torso workload.
"""

use GoogleApi.Gax.ModelBase

@type t :: %__MODULE__{
:agentVersion => String.t() | nil,
:instanceName => String.t() | nil,
:projectId => String.t() | nil,
:validationDetails => map() | nil,
:workloadType => String.t() | nil
}

field(:agentVersion)
field(:instanceName)
field(:projectId)
field(:validationDetails, type: :map)
field(:workloadType)
end

defimpl Poison.Decoder, for: GoogleApi.WorkloadManager.V1.Model.TorsoValidation do
def decode(value, options) do
GoogleApi.WorkloadManager.V1.Model.TorsoValidation.decode(value, options)
end
end

defimpl Poison.Encoder, for: GoogleApi.WorkloadManager.V1.Model.TorsoValidation do
def encode(value, options) do
GoogleApi.Gax.ModelBase.encode(value, options)
end
end
2 changes: 1 addition & 1 deletion clients/workload_manager/mix.exs
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
defmodule GoogleApi.WorkloadManager.Mixfile do
use Mix.Project

@version "0.10.0"
@version "0.11.0"

def project() do
[
Expand Down

0 comments on commit e16b009

Please sign in to comment.