# 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.Apigee.V1.Model.GoogleCloudApigeeV1CanaryEvaluation do
@moduledoc """
CanaryEvaluation represents the canary analysis between two versions of the runtime that is serving requests.
## Attributes
* `control` (*type:* `String.t`, *default:* `nil`) - Required. The stable version that is serving requests.
* `createTime` (*type:* `DateTime.t`, *default:* `nil`) - Output only. Create time of the canary evaluation.
* `endTime` (*type:* `DateTime.t`, *default:* `nil`) - Required. End time for the evaluation's analysis.
* `metricLabels` (*type:* `GoogleApi.Apigee.V1.Model.GoogleCloudApigeeV1CanaryEvaluationMetricLabels.t`, *default:* `nil`) - Required. Labels used to filter the metrics used for a canary evaluation.
* `name` (*type:* `String.t`, *default:* `nil`) - Output only. Name of the canary evalution.
* `startTime` (*type:* `DateTime.t`, *default:* `nil`) - Required. Start time for the canary evaluation's analysis.
* `state` (*type:* `String.t`, *default:* `nil`) - Output only. The current state of the canary evaluation.
* `treatment` (*type:* `String.t`, *default:* `nil`) - Required. The newer version that is serving requests.
* `verdict` (*type:* `String.t`, *default:* `nil`) - Output only. The resulting verdict of the canary evaluations: NONE, PASS, or FAIL.
"""
use GoogleApi.Gax.ModelBase
@type t :: %__MODULE__{
:control => String.t() | nil,
:createTime => DateTime.t() | nil,
:endTime => DateTime.t() | nil,
:metricLabels =>
GoogleApi.Apigee.V1.Model.GoogleCloudApigeeV1CanaryEvaluationMetricLabels.t() | nil,
:name => String.t() | nil,
:startTime => DateTime.t() | nil,
:state => String.t() | nil,
:treatment => String.t() | nil,
:verdict => String.t() | nil
}
field(:control)
field(:createTime, as: DateTime)
field(:endTime, as: DateTime)
field(:metricLabels,
as: GoogleApi.Apigee.V1.Model.GoogleCloudApigeeV1CanaryEvaluationMetricLabels
)
field(:name)
field(:startTime, as: DateTime)
field(:state)
field(:treatment)
field(:verdict)
end
defimpl Poison.Decoder, for: GoogleApi.Apigee.V1.Model.GoogleCloudApigeeV1CanaryEvaluation do
def decode(value, options) do
GoogleApi.Apigee.V1.Model.GoogleCloudApigeeV1CanaryEvaluation.decode(value, options)
end
end
defimpl Poison.Encoder, for: GoogleApi.Apigee.V1.Model.GoogleCloudApigeeV1CanaryEvaluation do
def encode(value, options) do
GoogleApi.Gax.ModelBase.encode(value, options)
end
end