// This file was autogenerated by go-to-protobuf. Do not edit it manually!

// @generated by protoc-gen-es v1.8.0 with parameter "target=ts"
// @generated from file rollouts/api/v1alpha1/generated.proto (package github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1, syntax proto2)
/* eslint-disable */
// @ts-nocheck

import type { BinaryReadOptions, FieldList, JsonReadOptions, JsonValue, PartialMessage, PlainMessage } from "@bufbuild/protobuf";
import { Message, proto2 } from "@bufbuild/protobuf";
import { ListMeta, ObjectMeta, Time } from "../../../k8s.io/apimachinery/pkg/apis/meta/v1/generated_pb.js";
import { IntOrString } from "../../../k8s.io/apimachinery/pkg/util/intstr/generated_pb.js";
import { JobSpec } from "../../../k8s.io/api/batch/v1/generated_pb.js";

/**
 * @generated from message github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.AnalysisRun
 */
export class AnalysisRun extends Message<AnalysisRun> {
  /**
   * @generated from field: optional k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta metadata = 1;
   */
  metadata?: ObjectMeta;

  /**
   * @generated from field: optional github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.AnalysisRunSpec spec = 2;
   */
  spec?: AnalysisRunSpec;

  /**
   * @generated from field: optional github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.AnalysisRunStatus status = 3;
   */
  status?: AnalysisRunStatus;

  constructor(data?: PartialMessage<AnalysisRun>) {
    super();
    proto2.util.initPartial(data, this);
  }

  static readonly runtime: typeof proto2 = proto2;
  static readonly typeName = "github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.AnalysisRun";
  static readonly fields: FieldList = proto2.util.newFieldList(() => [
    { no: 1, name: "metadata", kind: "message", T: ObjectMeta, opt: true },
    { no: 2, name: "spec", kind: "message", T: AnalysisRunSpec, opt: true },
    { no: 3, name: "status", kind: "message", T: AnalysisRunStatus, opt: true },
  ]);

  static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): AnalysisRun {
    return new AnalysisRun().fromBinary(bytes, options);
  }

  static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): AnalysisRun {
    return new AnalysisRun().fromJson(jsonValue, options);
  }

  static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): AnalysisRun {
    return new AnalysisRun().fromJsonString(jsonString, options);
  }

  static equals(a: AnalysisRun | PlainMessage<AnalysisRun> | undefined, b: AnalysisRun | PlainMessage<AnalysisRun> | undefined): boolean {
    return proto2.util.equals(AnalysisRun, a, b);
  }
}

/**
 * @generated from message github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.AnalysisRunList
 */
export class AnalysisRunList extends Message<AnalysisRunList> {
  /**
   * @generated from field: optional k8s.io.apimachinery.pkg.apis.meta.v1.ListMeta metadata = 1;
   */
  metadata?: ListMeta;

  /**
   * @generated from field: repeated github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.AnalysisRun items = 2;
   */
  items: AnalysisRun[] = [];

  constructor(data?: PartialMessage<AnalysisRunList>) {
    super();
    proto2.util.initPartial(data, this);
  }

  static readonly runtime: typeof proto2 = proto2;
  static readonly typeName = "github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.AnalysisRunList";
  static readonly fields: FieldList = proto2.util.newFieldList(() => [
    { no: 1, name: "metadata", kind: "message", T: ListMeta, opt: true },
    { no: 2, name: "items", kind: "message", T: AnalysisRun, repeated: true },
  ]);

  static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): AnalysisRunList {
    return new AnalysisRunList().fromBinary(bytes, options);
  }

  static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): AnalysisRunList {
    return new AnalysisRunList().fromJson(jsonValue, options);
  }

  static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): AnalysisRunList {
    return new AnalysisRunList().fromJsonString(jsonString, options);
  }

  static equals(a: AnalysisRunList | PlainMessage<AnalysisRunList> | undefined, b: AnalysisRunList | PlainMessage<AnalysisRunList> | undefined): boolean {
    return proto2.util.equals(AnalysisRunList, a, b);
  }
}

/**
 * @generated from message github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.AnalysisRunSpec
 */
export class AnalysisRunSpec extends Message<AnalysisRunSpec> {
  /**
   * @generated from field: repeated github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.Metric metrics = 1;
   */
  metrics: Metric[] = [];

  /**
   * @generated from field: repeated github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.Argument args = 2;
   */
  args: Argument[] = [];

  /**
   * @generated from field: optional bool terminate = 3;
   */
  terminate?: boolean;

  /**
   * @generated from field: repeated github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.DryRun dryRun = 4;
   */
  dryRun: DryRun[] = [];

  /**
   * @generated from field: repeated github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.MeasurementRetention measurementRetention = 5;
   */
  measurementRetention: MeasurementRetention[] = [];

  constructor(data?: PartialMessage<AnalysisRunSpec>) {
    super();
    proto2.util.initPartial(data, this);
  }

  static readonly runtime: typeof proto2 = proto2;
  static readonly typeName = "github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.AnalysisRunSpec";
  static readonly fields: FieldList = proto2.util.newFieldList(() => [
    { no: 1, name: "metrics", kind: "message", T: Metric, repeated: true },
    { no: 2, name: "args", kind: "message", T: Argument, repeated: true },
    { no: 3, name: "terminate", kind: "scalar", T: 8 /* ScalarType.BOOL */, opt: true },
    { no: 4, name: "dryRun", kind: "message", T: DryRun, repeated: true },
    { no: 5, name: "measurementRetention", kind: "message", T: MeasurementRetention, repeated: true },
  ]);

  static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): AnalysisRunSpec {
    return new AnalysisRunSpec().fromBinary(bytes, options);
  }

  static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): AnalysisRunSpec {
    return new AnalysisRunSpec().fromJson(jsonValue, options);
  }

  static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): AnalysisRunSpec {
    return new AnalysisRunSpec().fromJsonString(jsonString, options);
  }

  static equals(a: AnalysisRunSpec | PlainMessage<AnalysisRunSpec> | undefined, b: AnalysisRunSpec | PlainMessage<AnalysisRunSpec> | undefined): boolean {
    return proto2.util.equals(AnalysisRunSpec, a, b);
  }
}

/**
 * @generated from message github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.AnalysisRunStatus
 */
export class AnalysisRunStatus extends Message<AnalysisRunStatus> {
  /**
   * @generated from field: optional string phase = 1;
   */
  phase?: string;

  /**
   * @generated from field: optional string message = 2;
   */
  message?: string;

  /**
   * @generated from field: repeated github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.MetricResult metricResults = 3;
   */
  metricResults: MetricResult[] = [];

  /**
   * @generated from field: optional k8s.io.apimachinery.pkg.apis.meta.v1.Time startedAt = 4;
   */
  startedAt?: Time;

  /**
   * @generated from field: optional github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.RunSummary runSummary = 5;
   */
  runSummary?: RunSummary;

  /**
   * @generated from field: optional github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.RunSummary dryRunSummary = 6;
   */
  dryRunSummary?: RunSummary;

  constructor(data?: PartialMessage<AnalysisRunStatus>) {
    super();
    proto2.util.initPartial(data, this);
  }

  static readonly runtime: typeof proto2 = proto2;
  static readonly typeName = "github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.AnalysisRunStatus";
  static readonly fields: FieldList = proto2.util.newFieldList(() => [
    { no: 1, name: "phase", kind: "scalar", T: 9 /* ScalarType.STRING */, opt: true },
    { no: 2, name: "message", kind: "scalar", T: 9 /* ScalarType.STRING */, opt: true },
    { no: 3, name: "metricResults", kind: "message", T: MetricResult, repeated: true },
    { no: 4, name: "startedAt", kind: "message", T: Time, opt: true },
    { no: 5, name: "runSummary", kind: "message", T: RunSummary, opt: true },
    { no: 6, name: "dryRunSummary", kind: "message", T: RunSummary, opt: true },
  ]);

  static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): AnalysisRunStatus {
    return new AnalysisRunStatus().fromBinary(bytes, options);
  }

  static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): AnalysisRunStatus {
    return new AnalysisRunStatus().fromJson(jsonValue, options);
  }

  static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): AnalysisRunStatus {
    return new AnalysisRunStatus().fromJsonString(jsonString, options);
  }

  static equals(a: AnalysisRunStatus | PlainMessage<AnalysisRunStatus> | undefined, b: AnalysisRunStatus | PlainMessage<AnalysisRunStatus> | undefined): boolean {
    return proto2.util.equals(AnalysisRunStatus, a, b);
  }
}

/**
 * @generated from message github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.AnalysisTemplate
 */
export class AnalysisTemplate extends Message<AnalysisTemplate> {
  /**
   * @generated from field: optional k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta metadata = 1;
   */
  metadata?: ObjectMeta;

  /**
   * @generated from field: optional github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.AnalysisTemplateSpec spec = 2;
   */
  spec?: AnalysisTemplateSpec;

  constructor(data?: PartialMessage<AnalysisTemplate>) {
    super();
    proto2.util.initPartial(data, this);
  }

  static readonly runtime: typeof proto2 = proto2;
  static readonly typeName = "github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.AnalysisTemplate";
  static readonly fields: FieldList = proto2.util.newFieldList(() => [
    { no: 1, name: "metadata", kind: "message", T: ObjectMeta, opt: true },
    { no: 2, name: "spec", kind: "message", T: AnalysisTemplateSpec, opt: true },
  ]);

  static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): AnalysisTemplate {
    return new AnalysisTemplate().fromBinary(bytes, options);
  }

  static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): AnalysisTemplate {
    return new AnalysisTemplate().fromJson(jsonValue, options);
  }

  static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): AnalysisTemplate {
    return new AnalysisTemplate().fromJsonString(jsonString, options);
  }

  static equals(a: AnalysisTemplate | PlainMessage<AnalysisTemplate> | undefined, b: AnalysisTemplate | PlainMessage<AnalysisTemplate> | undefined): boolean {
    return proto2.util.equals(AnalysisTemplate, a, b);
  }
}

/**
 * @generated from message github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.AnalysisTemplateList
 */
export class AnalysisTemplateList extends Message<AnalysisTemplateList> {
  /**
   * @generated from field: optional k8s.io.apimachinery.pkg.apis.meta.v1.ListMeta metadata = 1;
   */
  metadata?: ListMeta;

  /**
   * @generated from field: repeated github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.AnalysisTemplate items = 2;
   */
  items: AnalysisTemplate[] = [];

  constructor(data?: PartialMessage<AnalysisTemplateList>) {
    super();
    proto2.util.initPartial(data, this);
  }

  static readonly runtime: typeof proto2 = proto2;
  static readonly typeName = "github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.AnalysisTemplateList";
  static readonly fields: FieldList = proto2.util.newFieldList(() => [
    { no: 1, name: "metadata", kind: "message", T: ListMeta, opt: true },
    { no: 2, name: "items", kind: "message", T: AnalysisTemplate, repeated: true },
  ]);

  static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): AnalysisTemplateList {
    return new AnalysisTemplateList().fromBinary(bytes, options);
  }

  static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): AnalysisTemplateList {
    return new AnalysisTemplateList().fromJson(jsonValue, options);
  }

  static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): AnalysisTemplateList {
    return new AnalysisTemplateList().fromJsonString(jsonString, options);
  }

  static equals(a: AnalysisTemplateList | PlainMessage<AnalysisTemplateList> | undefined, b: AnalysisTemplateList | PlainMessage<AnalysisTemplateList> | undefined): boolean {
    return proto2.util.equals(AnalysisTemplateList, a, b);
  }
}

/**
 * @generated from message github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.AnalysisTemplateSpec
 */
export class AnalysisTemplateSpec extends Message<AnalysisTemplateSpec> {
  /**
   * @generated from field: repeated github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.Metric metrics = 1;
   */
  metrics: Metric[] = [];

  /**
   * @generated from field: repeated github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.Argument args = 2;
   */
  args: Argument[] = [];

  /**
   * @generated from field: repeated github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.DryRun dryRun = 3;
   */
  dryRun: DryRun[] = [];

  /**
   * @generated from field: repeated github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.MeasurementRetention measurementRetention = 4;
   */
  measurementRetention: MeasurementRetention[] = [];

  constructor(data?: PartialMessage<AnalysisTemplateSpec>) {
    super();
    proto2.util.initPartial(data, this);
  }

  static readonly runtime: typeof proto2 = proto2;
  static readonly typeName = "github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.AnalysisTemplateSpec";
  static readonly fields: FieldList = proto2.util.newFieldList(() => [
    { no: 1, name: "metrics", kind: "message", T: Metric, repeated: true },
    { no: 2, name: "args", kind: "message", T: Argument, repeated: true },
    { no: 3, name: "dryRun", kind: "message", T: DryRun, repeated: true },
    { no: 4, name: "measurementRetention", kind: "message", T: MeasurementRetention, repeated: true },
  ]);

  static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): AnalysisTemplateSpec {
    return new AnalysisTemplateSpec().fromBinary(bytes, options);
  }

  static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): AnalysisTemplateSpec {
    return new AnalysisTemplateSpec().fromJson(jsonValue, options);
  }

  static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): AnalysisTemplateSpec {
    return new AnalysisTemplateSpec().fromJsonString(jsonString, options);
  }

  static equals(a: AnalysisTemplateSpec | PlainMessage<AnalysisTemplateSpec> | undefined, b: AnalysisTemplateSpec | PlainMessage<AnalysisTemplateSpec> | undefined): boolean {
    return proto2.util.equals(AnalysisTemplateSpec, a, b);
  }
}

/**
 * @generated from message github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.Argument
 */
export class Argument extends Message<Argument> {
  /**
   * @generated from field: optional string name = 1;
   */
  name?: string;

  /**
   * @generated from field: optional string value = 2;
   */
  value?: string;

  /**
   * @generated from field: optional github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.ValueFrom valueFrom = 3;
   */
  valueFrom?: ValueFrom;

  constructor(data?: PartialMessage<Argument>) {
    super();
    proto2.util.initPartial(data, this);
  }

  static readonly runtime: typeof proto2 = proto2;
  static readonly typeName = "github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.Argument";
  static readonly fields: FieldList = proto2.util.newFieldList(() => [
    { no: 1, name: "name", kind: "scalar", T: 9 /* ScalarType.STRING */, opt: true },
    { no: 2, name: "value", kind: "scalar", T: 9 /* ScalarType.STRING */, opt: true },
    { no: 3, name: "valueFrom", kind: "message", T: ValueFrom, opt: true },
  ]);

  static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): Argument {
    return new Argument().fromBinary(bytes, options);
  }

  static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): Argument {
    return new Argument().fromJson(jsonValue, options);
  }

  static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): Argument {
    return new Argument().fromJsonString(jsonString, options);
  }

  static equals(a: Argument | PlainMessage<Argument> | undefined, b: Argument | PlainMessage<Argument> | undefined): boolean {
    return proto2.util.equals(Argument, a, b);
  }
}

/**
 * @generated from message github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.Authentication
 */
export class Authentication extends Message<Authentication> {
  /**
   * @generated from field: optional github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.Sigv4Config sigv4 = 1;
   */
  sigv4?: Sigv4Config;

  /**
   * @generated from field: optional github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.OAuth2Config oauth2 = 2;
   */
  oauth2?: OAuth2Config;

  constructor(data?: PartialMessage<Authentication>) {
    super();
    proto2.util.initPartial(data, this);
  }

  static readonly runtime: typeof proto2 = proto2;
  static readonly typeName = "github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.Authentication";
  static readonly fields: FieldList = proto2.util.newFieldList(() => [
    { no: 1, name: "sigv4", kind: "message", T: Sigv4Config, opt: true },
    { no: 2, name: "oauth2", kind: "message", T: OAuth2Config, opt: true },
  ]);

  static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): Authentication {
    return new Authentication().fromBinary(bytes, options);
  }

  static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): Authentication {
    return new Authentication().fromJson(jsonValue, options);
  }

  static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): Authentication {
    return new Authentication().fromJsonString(jsonString, options);
  }

  static equals(a: Authentication | PlainMessage<Authentication> | undefined, b: Authentication | PlainMessage<Authentication> | undefined): boolean {
    return proto2.util.equals(Authentication, a, b);
  }
}

/**
 * @generated from message github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.CloudWatchMetric
 */
export class CloudWatchMetric extends Message<CloudWatchMetric> {
  /**
   * @generated from field: optional string interval = 1;
   */
  interval?: string;

  /**
   * @generated from field: repeated github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.CloudWatchMetricDataQuery metricDataQueries = 2;
   */
  metricDataQueries: CloudWatchMetricDataQuery[] = [];

  constructor(data?: PartialMessage<CloudWatchMetric>) {
    super();
    proto2.util.initPartial(data, this);
  }

  static readonly runtime: typeof proto2 = proto2;
  static readonly typeName = "github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.CloudWatchMetric";
  static readonly fields: FieldList = proto2.util.newFieldList(() => [
    { no: 1, name: "interval", kind: "scalar", T: 9 /* ScalarType.STRING */, opt: true },
    { no: 2, name: "metricDataQueries", kind: "message", T: CloudWatchMetricDataQuery, repeated: true },
  ]);

  static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): CloudWatchMetric {
    return new CloudWatchMetric().fromBinary(bytes, options);
  }

  static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): CloudWatchMetric {
    return new CloudWatchMetric().fromJson(jsonValue, options);
  }

  static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): CloudWatchMetric {
    return new CloudWatchMetric().fromJsonString(jsonString, options);
  }

  static equals(a: CloudWatchMetric | PlainMessage<CloudWatchMetric> | undefined, b: CloudWatchMetric | PlainMessage<CloudWatchMetric> | undefined): boolean {
    return proto2.util.equals(CloudWatchMetric, a, b);
  }
}

/**
 * @generated from message github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.CloudWatchMetricDataQuery
 */
export class CloudWatchMetricDataQuery extends Message<CloudWatchMetricDataQuery> {
  /**
   * @generated from field: optional string id = 1;
   */
  id?: string;

  /**
   * @generated from field: optional string expression = 2;
   */
  expression?: string;

  /**
   * @generated from field: optional string label = 3;
   */
  label?: string;

  /**
   * @generated from field: optional github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.CloudWatchMetricStat metricStat = 4;
   */
  metricStat?: CloudWatchMetricStat;

  /**
   * @generated from field: optional k8s.io.apimachinery.pkg.util.intstr.IntOrString period = 5;
   */
  period?: IntOrString;

  /**
   * @generated from field: optional bool returnData = 6;
   */
  returnData?: boolean;

  constructor(data?: PartialMessage<CloudWatchMetricDataQuery>) {
    super();
    proto2.util.initPartial(data, this);
  }

  static readonly runtime: typeof proto2 = proto2;
  static readonly typeName = "github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.CloudWatchMetricDataQuery";
  static readonly fields: FieldList = proto2.util.newFieldList(() => [
    { no: 1, name: "id", kind: "scalar", T: 9 /* ScalarType.STRING */, opt: true },
    { no: 2, name: "expression", kind: "scalar", T: 9 /* ScalarType.STRING */, opt: true },
    { no: 3, name: "label", kind: "scalar", T: 9 /* ScalarType.STRING */, opt: true },
    { no: 4, name: "metricStat", kind: "message", T: CloudWatchMetricStat, opt: true },
    { no: 5, name: "period", kind: "message", T: IntOrString, opt: true },
    { no: 6, name: "returnData", kind: "scalar", T: 8 /* ScalarType.BOOL */, opt: true },
  ]);

  static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): CloudWatchMetricDataQuery {
    return new CloudWatchMetricDataQuery().fromBinary(bytes, options);
  }

  static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): CloudWatchMetricDataQuery {
    return new CloudWatchMetricDataQuery().fromJson(jsonValue, options);
  }

  static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): CloudWatchMetricDataQuery {
    return new CloudWatchMetricDataQuery().fromJsonString(jsonString, options);
  }

  static equals(a: CloudWatchMetricDataQuery | PlainMessage<CloudWatchMetricDataQuery> | undefined, b: CloudWatchMetricDataQuery | PlainMessage<CloudWatchMetricDataQuery> | undefined): boolean {
    return proto2.util.equals(CloudWatchMetricDataQuery, a, b);
  }
}

/**
 * @generated from message github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.CloudWatchMetricStat
 */
export class CloudWatchMetricStat extends Message<CloudWatchMetricStat> {
  /**
   * @generated from field: optional github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.CloudWatchMetricStatMetric metric = 1;
   */
  metric?: CloudWatchMetricStatMetric;

  /**
   * @generated from field: optional k8s.io.apimachinery.pkg.util.intstr.IntOrString period = 2;
   */
  period?: IntOrString;

  /**
   * @generated from field: optional string stat = 3;
   */
  stat?: string;

  /**
   * @generated from field: optional string unit = 4;
   */
  unit?: string;

  constructor(data?: PartialMessage<CloudWatchMetricStat>) {
    super();
    proto2.util.initPartial(data, this);
  }

  static readonly runtime: typeof proto2 = proto2;
  static readonly typeName = "github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.CloudWatchMetricStat";
  static readonly fields: FieldList = proto2.util.newFieldList(() => [
    { no: 1, name: "metric", kind: "message", T: CloudWatchMetricStatMetric, opt: true },
    { no: 2, name: "period", kind: "message", T: IntOrString, opt: true },
    { no: 3, name: "stat", kind: "scalar", T: 9 /* ScalarType.STRING */, opt: true },
    { no: 4, name: "unit", kind: "scalar", T: 9 /* ScalarType.STRING */, opt: true },
  ]);

  static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): CloudWatchMetricStat {
    return new CloudWatchMetricStat().fromBinary(bytes, options);
  }

  static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): CloudWatchMetricStat {
    return new CloudWatchMetricStat().fromJson(jsonValue, options);
  }

  static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): CloudWatchMetricStat {
    return new CloudWatchMetricStat().fromJsonString(jsonString, options);
  }

  static equals(a: CloudWatchMetricStat | PlainMessage<CloudWatchMetricStat> | undefined, b: CloudWatchMetricStat | PlainMessage<CloudWatchMetricStat> | undefined): boolean {
    return proto2.util.equals(CloudWatchMetricStat, a, b);
  }
}

/**
 * @generated from message github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.CloudWatchMetricStatMetric
 */
export class CloudWatchMetricStatMetric extends Message<CloudWatchMetricStatMetric> {
  /**
   * @generated from field: repeated github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.CloudWatchMetricStatMetricDimension dimensions = 1;
   */
  dimensions: CloudWatchMetricStatMetricDimension[] = [];

  /**
   * @generated from field: optional string metricName = 2;
   */
  metricName?: string;

  /**
   * @generated from field: optional string namespace = 3;
   */
  namespace?: string;

  constructor(data?: PartialMessage<CloudWatchMetricStatMetric>) {
    super();
    proto2.util.initPartial(data, this);
  }

  static readonly runtime: typeof proto2 = proto2;
  static readonly typeName = "github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.CloudWatchMetricStatMetric";
  static readonly fields: FieldList = proto2.util.newFieldList(() => [
    { no: 1, name: "dimensions", kind: "message", T: CloudWatchMetricStatMetricDimension, repeated: true },
    { no: 2, name: "metricName", kind: "scalar", T: 9 /* ScalarType.STRING */, opt: true },
    { no: 3, name: "namespace", kind: "scalar", T: 9 /* ScalarType.STRING */, opt: true },
  ]);

  static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): CloudWatchMetricStatMetric {
    return new CloudWatchMetricStatMetric().fromBinary(bytes, options);
  }

  static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): CloudWatchMetricStatMetric {
    return new CloudWatchMetricStatMetric().fromJson(jsonValue, options);
  }

  static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): CloudWatchMetricStatMetric {
    return new CloudWatchMetricStatMetric().fromJsonString(jsonString, options);
  }

  static equals(a: CloudWatchMetricStatMetric | PlainMessage<CloudWatchMetricStatMetric> | undefined, b: CloudWatchMetricStatMetric | PlainMessage<CloudWatchMetricStatMetric> | undefined): boolean {
    return proto2.util.equals(CloudWatchMetricStatMetric, a, b);
  }
}

/**
 * @generated from message github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.CloudWatchMetricStatMetricDimension
 */
export class CloudWatchMetricStatMetricDimension extends Message<CloudWatchMetricStatMetricDimension> {
  /**
   * @generated from field: optional string name = 1;
   */
  name?: string;

  /**
   * @generated from field: optional string value = 2;
   */
  value?: string;

  constructor(data?: PartialMessage<CloudWatchMetricStatMetricDimension>) {
    super();
    proto2.util.initPartial(data, this);
  }

  static readonly runtime: typeof proto2 = proto2;
  static readonly typeName = "github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.CloudWatchMetricStatMetricDimension";
  static readonly fields: FieldList = proto2.util.newFieldList(() => [
    { no: 1, name: "name", kind: "scalar", T: 9 /* ScalarType.STRING */, opt: true },
    { no: 2, name: "value", kind: "scalar", T: 9 /* ScalarType.STRING */, opt: true },
  ]);

  static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): CloudWatchMetricStatMetricDimension {
    return new CloudWatchMetricStatMetricDimension().fromBinary(bytes, options);
  }

  static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): CloudWatchMetricStatMetricDimension {
    return new CloudWatchMetricStatMetricDimension().fromJson(jsonValue, options);
  }

  static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): CloudWatchMetricStatMetricDimension {
    return new CloudWatchMetricStatMetricDimension().fromJsonString(jsonString, options);
  }

  static equals(a: CloudWatchMetricStatMetricDimension | PlainMessage<CloudWatchMetricStatMetricDimension> | undefined, b: CloudWatchMetricStatMetricDimension | PlainMessage<CloudWatchMetricStatMetricDimension> | undefined): boolean {
    return proto2.util.equals(CloudWatchMetricStatMetricDimension, a, b);
  }
}

/**
 * @generated from message github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.DatadogMetric
 */
export class DatadogMetric extends Message<DatadogMetric> {
  /**
   * @generated from field: optional string interval = 1;
   */
  interval?: string;

  /**
   * @generated from field: optional string query = 2;
   */
  query?: string;

  /**
   * @generated from field: map<string, string> queries = 3;
   */
  queries: { [key: string]: string } = {};

  /**
   * @generated from field: optional string formula = 4;
   */
  formula?: string;

  /**
   * @generated from field: optional string apiVersion = 5;
   */
  apiVersion?: string;

  constructor(data?: PartialMessage<DatadogMetric>) {
    super();
    proto2.util.initPartial(data, this);
  }

  static readonly runtime: typeof proto2 = proto2;
  static readonly typeName = "github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.DatadogMetric";
  static readonly fields: FieldList = proto2.util.newFieldList(() => [
    { no: 1, name: "interval", kind: "scalar", T: 9 /* ScalarType.STRING */, opt: true },
    { no: 2, name: "query", kind: "scalar", T: 9 /* ScalarType.STRING */, opt: true },
    { no: 3, name: "queries", kind: "map", K: 9 /* ScalarType.STRING */, V: {kind: "scalar", T: 9 /* ScalarType.STRING */} },
    { no: 4, name: "formula", kind: "scalar", T: 9 /* ScalarType.STRING */, opt: true },
    { no: 5, name: "apiVersion", kind: "scalar", T: 9 /* ScalarType.STRING */, opt: true },
  ]);

  static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): DatadogMetric {
    return new DatadogMetric().fromBinary(bytes, options);
  }

  static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): DatadogMetric {
    return new DatadogMetric().fromJson(jsonValue, options);
  }

  static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): DatadogMetric {
    return new DatadogMetric().fromJsonString(jsonString, options);
  }

  static equals(a: DatadogMetric | PlainMessage<DatadogMetric> | undefined, b: DatadogMetric | PlainMessage<DatadogMetric> | undefined): boolean {
    return proto2.util.equals(DatadogMetric, a, b);
  }
}

/**
 * @generated from message github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.DryRun
 */
export class DryRun extends Message<DryRun> {
  /**
   * @generated from field: optional string metricName = 1;
   */
  metricName?: string;

  constructor(data?: PartialMessage<DryRun>) {
    super();
    proto2.util.initPartial(data, this);
  }

  static readonly runtime: typeof proto2 = proto2;
  static readonly typeName = "github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.DryRun";
  static readonly fields: FieldList = proto2.util.newFieldList(() => [
    { no: 1, name: "metricName", kind: "scalar", T: 9 /* ScalarType.STRING */, opt: true },
  ]);

  static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): DryRun {
    return new DryRun().fromBinary(bytes, options);
  }

  static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): DryRun {
    return new DryRun().fromJson(jsonValue, options);
  }

  static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): DryRun {
    return new DryRun().fromJsonString(jsonString, options);
  }

  static equals(a: DryRun | PlainMessage<DryRun> | undefined, b: DryRun | PlainMessage<DryRun> | undefined): boolean {
    return proto2.util.equals(DryRun, a, b);
  }
}

/**
 * @generated from message github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.FieldRef
 */
export class FieldRef extends Message<FieldRef> {
  /**
   * Required: Path of the field to select in the specified API version
   *
   * @generated from field: optional string fieldPath = 1;
   */
  fieldPath?: string;

  constructor(data?: PartialMessage<FieldRef>) {
    super();
    proto2.util.initPartial(data, this);
  }

  static readonly runtime: typeof proto2 = proto2;
  static readonly typeName = "github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.FieldRef";
  static readonly fields: FieldList = proto2.util.newFieldList(() => [
    { no: 1, name: "fieldPath", kind: "scalar", T: 9 /* ScalarType.STRING */, opt: true },
  ]);

  static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): FieldRef {
    return new FieldRef().fromBinary(bytes, options);
  }

  static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): FieldRef {
    return new FieldRef().fromJson(jsonValue, options);
  }

  static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): FieldRef {
    return new FieldRef().fromJsonString(jsonString, options);
  }

  static equals(a: FieldRef | PlainMessage<FieldRef> | undefined, b: FieldRef | PlainMessage<FieldRef> | undefined): boolean {
    return proto2.util.equals(FieldRef, a, b);
  }
}

/**
 * @generated from message github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.GraphiteMetric
 */
export class GraphiteMetric extends Message<GraphiteMetric> {
  /**
   * @generated from field: optional string address = 1;
   */
  address?: string;

  /**
   * @generated from field: optional string query = 2;
   */
  query?: string;

  constructor(data?: PartialMessage<GraphiteMetric>) {
    super();
    proto2.util.initPartial(data, this);
  }

  static readonly runtime: typeof proto2 = proto2;
  static readonly typeName = "github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.GraphiteMetric";
  static readonly fields: FieldList = proto2.util.newFieldList(() => [
    { no: 1, name: "address", kind: "scalar", T: 9 /* ScalarType.STRING */, opt: true },
    { no: 2, name: "query", kind: "scalar", T: 9 /* ScalarType.STRING */, opt: true },
  ]);

  static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): GraphiteMetric {
    return new GraphiteMetric().fromBinary(bytes, options);
  }

  static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): GraphiteMetric {
    return new GraphiteMetric().fromJson(jsonValue, options);
  }

  static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): GraphiteMetric {
    return new GraphiteMetric().fromJsonString(jsonString, options);
  }

  static equals(a: GraphiteMetric | PlainMessage<GraphiteMetric> | undefined, b: GraphiteMetric | PlainMessage<GraphiteMetric> | undefined): boolean {
    return proto2.util.equals(GraphiteMetric, a, b);
  }
}

/**
 * @generated from message github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.InfluxdbMetric
 */
export class InfluxdbMetric extends Message<InfluxdbMetric> {
  /**
   * @generated from field: optional string profile = 1;
   */
  profile?: string;

  /**
   * @generated from field: optional string query = 2;
   */
  query?: string;

  constructor(data?: PartialMessage<InfluxdbMetric>) {
    super();
    proto2.util.initPartial(data, this);
  }

  static readonly runtime: typeof proto2 = proto2;
  static readonly typeName = "github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.InfluxdbMetric";
  static readonly fields: FieldList = proto2.util.newFieldList(() => [
    { no: 1, name: "profile", kind: "scalar", T: 9 /* ScalarType.STRING */, opt: true },
    { no: 2, name: "query", kind: "scalar", T: 9 /* ScalarType.STRING */, opt: true },
  ]);

  static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): InfluxdbMetric {
    return new InfluxdbMetric().fromBinary(bytes, options);
  }

  static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): InfluxdbMetric {
    return new InfluxdbMetric().fromJson(jsonValue, options);
  }

  static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): InfluxdbMetric {
    return new InfluxdbMetric().fromJsonString(jsonString, options);
  }

  static equals(a: InfluxdbMetric | PlainMessage<InfluxdbMetric> | undefined, b: InfluxdbMetric | PlainMessage<InfluxdbMetric> | undefined): boolean {
    return proto2.util.equals(InfluxdbMetric, a, b);
  }
}

/**
 * @generated from message github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.JobMetric
 */
export class JobMetric extends Message<JobMetric> {
  /**
   * @generated from field: optional k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta metadata = 1;
   */
  metadata?: ObjectMeta;

  /**
   * @generated from field: optional k8s.io.api.batch.v1.JobSpec spec = 2;
   */
  spec?: JobSpec;

  constructor(data?: PartialMessage<JobMetric>) {
    super();
    proto2.util.initPartial(data, this);
  }

  static readonly runtime: typeof proto2 = proto2;
  static readonly typeName = "github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.JobMetric";
  static readonly fields: FieldList = proto2.util.newFieldList(() => [
    { no: 1, name: "metadata", kind: "message", T: ObjectMeta, opt: true },
    { no: 2, name: "spec", kind: "message", T: JobSpec, opt: true },
  ]);

  static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): JobMetric {
    return new JobMetric().fromBinary(bytes, options);
  }

  static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): JobMetric {
    return new JobMetric().fromJson(jsonValue, options);
  }

  static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): JobMetric {
    return new JobMetric().fromJsonString(jsonString, options);
  }

  static equals(a: JobMetric | PlainMessage<JobMetric> | undefined, b: JobMetric | PlainMessage<JobMetric> | undefined): boolean {
    return proto2.util.equals(JobMetric, a, b);
  }
}

/**
 * @generated from message github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.KayentaMetric
 */
export class KayentaMetric extends Message<KayentaMetric> {
  /**
   * @generated from field: optional string address = 1;
   */
  address?: string;

  /**
   * @generated from field: optional string application = 2;
   */
  application?: string;

  /**
   * @generated from field: optional string canaryConfigName = 3;
   */
  canaryConfigName?: string;

  /**
   * @generated from field: optional string metricsAccountName = 4;
   */
  metricsAccountName?: string;

  /**
   * @generated from field: optional string configurationAccountName = 5;
   */
  configurationAccountName?: string;

  /**
   * @generated from field: optional string storageAccountName = 6;
   */
  storageAccountName?: string;

  /**
   * @generated from field: optional github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.KayentaThreshold threshold = 7;
   */
  threshold?: KayentaThreshold;

  /**
   * @generated from field: repeated github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.KayentaScope scopes = 8;
   */
  scopes: KayentaScope[] = [];

  constructor(data?: PartialMessage<KayentaMetric>) {
    super();
    proto2.util.initPartial(data, this);
  }

  static readonly runtime: typeof proto2 = proto2;
  static readonly typeName = "github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.KayentaMetric";
  static readonly fields: FieldList = proto2.util.newFieldList(() => [
    { no: 1, name: "address", kind: "scalar", T: 9 /* ScalarType.STRING */, opt: true },
    { no: 2, name: "application", kind: "scalar", T: 9 /* ScalarType.STRING */, opt: true },
    { no: 3, name: "canaryConfigName", kind: "scalar", T: 9 /* ScalarType.STRING */, opt: true },
    { no: 4, name: "metricsAccountName", kind: "scalar", T: 9 /* ScalarType.STRING */, opt: true },
    { no: 5, name: "configurationAccountName", kind: "scalar", T: 9 /* ScalarType.STRING */, opt: true },
    { no: 6, name: "storageAccountName", kind: "scalar", T: 9 /* ScalarType.STRING */, opt: true },
    { no: 7, name: "threshold", kind: "message", T: KayentaThreshold, opt: true },
    { no: 8, name: "scopes", kind: "message", T: KayentaScope, repeated: true },
  ]);

  static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): KayentaMetric {
    return new KayentaMetric().fromBinary(bytes, options);
  }

  static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): KayentaMetric {
    return new KayentaMetric().fromJson(jsonValue, options);
  }

  static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): KayentaMetric {
    return new KayentaMetric().fromJsonString(jsonString, options);
  }

  static equals(a: KayentaMetric | PlainMessage<KayentaMetric> | undefined, b: KayentaMetric | PlainMessage<KayentaMetric> | undefined): boolean {
    return proto2.util.equals(KayentaMetric, a, b);
  }
}

/**
 * @generated from message github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.KayentaScope
 */
export class KayentaScope extends Message<KayentaScope> {
  /**
   * @generated from field: optional string name = 1;
   */
  name?: string;

  /**
   * @generated from field: optional github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.ScopeDetail controlScope = 2;
   */
  controlScope?: ScopeDetail;

  /**
   * @generated from field: optional github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.ScopeDetail experimentScope = 3;
   */
  experimentScope?: ScopeDetail;

  constructor(data?: PartialMessage<KayentaScope>) {
    super();
    proto2.util.initPartial(data, this);
  }

  static readonly runtime: typeof proto2 = proto2;
  static readonly typeName = "github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.KayentaScope";
  static readonly fields: FieldList = proto2.util.newFieldList(() => [
    { no: 1, name: "name", kind: "scalar", T: 9 /* ScalarType.STRING */, opt: true },
    { no: 2, name: "controlScope", kind: "message", T: ScopeDetail, opt: true },
    { no: 3, name: "experimentScope", kind: "message", T: ScopeDetail, opt: true },
  ]);

  static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): KayentaScope {
    return new KayentaScope().fromBinary(bytes, options);
  }

  static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): KayentaScope {
    return new KayentaScope().fromJson(jsonValue, options);
  }

  static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): KayentaScope {
    return new KayentaScope().fromJsonString(jsonString, options);
  }

  static equals(a: KayentaScope | PlainMessage<KayentaScope> | undefined, b: KayentaScope | PlainMessage<KayentaScope> | undefined): boolean {
    return proto2.util.equals(KayentaScope, a, b);
  }
}

/**
 * @generated from message github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.KayentaThreshold
 */
export class KayentaThreshold extends Message<KayentaThreshold> {
  /**
   * @generated from field: optional int64 pass = 1;
   */
  pass?: bigint;

  /**
   * @generated from field: optional int64 marginal = 2;
   */
  marginal?: bigint;

  constructor(data?: PartialMessage<KayentaThreshold>) {
    super();
    proto2.util.initPartial(data, this);
  }

  static readonly runtime: typeof proto2 = proto2;
  static readonly typeName = "github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.KayentaThreshold";
  static readonly fields: FieldList = proto2.util.newFieldList(() => [
    { no: 1, name: "pass", kind: "scalar", T: 3 /* ScalarType.INT64 */, opt: true },
    { no: 2, name: "marginal", kind: "scalar", T: 3 /* ScalarType.INT64 */, opt: true },
  ]);

  static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): KayentaThreshold {
    return new KayentaThreshold().fromBinary(bytes, options);
  }

  static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): KayentaThreshold {
    return new KayentaThreshold().fromJson(jsonValue, options);
  }

  static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): KayentaThreshold {
    return new KayentaThreshold().fromJsonString(jsonString, options);
  }

  static equals(a: KayentaThreshold | PlainMessage<KayentaThreshold> | undefined, b: KayentaThreshold | PlainMessage<KayentaThreshold> | undefined): boolean {
    return proto2.util.equals(KayentaThreshold, a, b);
  }
}

/**
 * @generated from message github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.Measurement
 */
export class Measurement extends Message<Measurement> {
  /**
   * @generated from field: optional string phase = 1;
   */
  phase?: string;

  /**
   * @generated from field: optional string message = 2;
   */
  message?: string;

  /**
   * @generated from field: optional k8s.io.apimachinery.pkg.apis.meta.v1.Time startedAt = 3;
   */
  startedAt?: Time;

  /**
   * @generated from field: optional k8s.io.apimachinery.pkg.apis.meta.v1.Time finishedAt = 4;
   */
  finishedAt?: Time;

  /**
   * @generated from field: optional string value = 5;
   */
  value?: string;

  /**
   * @generated from field: map<string, string> metadata = 6;
   */
  metadata: { [key: string]: string } = {};

  /**
   * @generated from field: optional k8s.io.apimachinery.pkg.apis.meta.v1.Time resumeAt = 7;
   */
  resumeAt?: Time;

  constructor(data?: PartialMessage<Measurement>) {
    super();
    proto2.util.initPartial(data, this);
  }

  static readonly runtime: typeof proto2 = proto2;
  static readonly typeName = "github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.Measurement";
  static readonly fields: FieldList = proto2.util.newFieldList(() => [
    { no: 1, name: "phase", kind: "scalar", T: 9 /* ScalarType.STRING */, opt: true },
    { no: 2, name: "message", kind: "scalar", T: 9 /* ScalarType.STRING */, opt: true },
    { no: 3, name: "startedAt", kind: "message", T: Time, opt: true },
    { no: 4, name: "finishedAt", kind: "message", T: Time, opt: true },
    { no: 5, name: "value", kind: "scalar", T: 9 /* ScalarType.STRING */, opt: true },
    { no: 6, name: "metadata", kind: "map", K: 9 /* ScalarType.STRING */, V: {kind: "scalar", T: 9 /* ScalarType.STRING */} },
    { no: 7, name: "resumeAt", kind: "message", T: Time, opt: true },
  ]);

  static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): Measurement {
    return new Measurement().fromBinary(bytes, options);
  }

  static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): Measurement {
    return new Measurement().fromJson(jsonValue, options);
  }

  static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): Measurement {
    return new Measurement().fromJsonString(jsonString, options);
  }

  static equals(a: Measurement | PlainMessage<Measurement> | undefined, b: Measurement | PlainMessage<Measurement> | undefined): boolean {
    return proto2.util.equals(Measurement, a, b);
  }
}

/**
 * @generated from message github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.MeasurementRetention
 */
export class MeasurementRetention extends Message<MeasurementRetention> {
  /**
   * @generated from field: optional string metricName = 1;
   */
  metricName?: string;

  /**
   * @generated from field: optional int32 limit = 2;
   */
  limit?: number;

  constructor(data?: PartialMessage<MeasurementRetention>) {
    super();
    proto2.util.initPartial(data, this);
  }

  static readonly runtime: typeof proto2 = proto2;
  static readonly typeName = "github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.MeasurementRetention";
  static readonly fields: FieldList = proto2.util.newFieldList(() => [
    { no: 1, name: "metricName", kind: "scalar", T: 9 /* ScalarType.STRING */, opt: true },
    { no: 2, name: "limit", kind: "scalar", T: 5 /* ScalarType.INT32 */, opt: true },
  ]);

  static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): MeasurementRetention {
    return new MeasurementRetention().fromBinary(bytes, options);
  }

  static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): MeasurementRetention {
    return new MeasurementRetention().fromJson(jsonValue, options);
  }

  static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): MeasurementRetention {
    return new MeasurementRetention().fromJsonString(jsonString, options);
  }

  static equals(a: MeasurementRetention | PlainMessage<MeasurementRetention> | undefined, b: MeasurementRetention | PlainMessage<MeasurementRetention> | undefined): boolean {
    return proto2.util.equals(MeasurementRetention, a, b);
  }
}

/**
 * @generated from message github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.Metric
 */
export class Metric extends Message<Metric> {
  /**
   * @generated from field: optional string name = 1;
   */
  name?: string;

  /**
   * @generated from field: optional string interval = 2;
   */
  interval?: string;

  /**
   * @generated from field: optional string initialDelay = 3;
   */
  initialDelay?: string;

  /**
   * @generated from field: optional k8s.io.apimachinery.pkg.util.intstr.IntOrString count = 4;
   */
  count?: IntOrString;

  /**
   * @generated from field: optional string successCondition = 5;
   */
  successCondition?: string;

  /**
   * @generated from field: optional string failureCondition = 6;
   */
  failureCondition?: string;

  /**
   * @generated from field: optional k8s.io.apimachinery.pkg.util.intstr.IntOrString failureLimit = 7;
   */
  failureLimit?: IntOrString;

  /**
   * @generated from field: optional k8s.io.apimachinery.pkg.util.intstr.IntOrString inconclusiveLimit = 8;
   */
  inconclusiveLimit?: IntOrString;

  /**
   * @generated from field: optional k8s.io.apimachinery.pkg.util.intstr.IntOrString consecutiveErrorLimit = 9;
   */
  consecutiveErrorLimit?: IntOrString;

  /**
   * @generated from field: optional github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.MetricProvider provider = 10;
   */
  provider?: MetricProvider;

  constructor(data?: PartialMessage<Metric>) {
    super();
    proto2.util.initPartial(data, this);
  }

  static readonly runtime: typeof proto2 = proto2;
  static readonly typeName = "github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.Metric";
  static readonly fields: FieldList = proto2.util.newFieldList(() => [
    { no: 1, name: "name", kind: "scalar", T: 9 /* ScalarType.STRING */, opt: true },
    { no: 2, name: "interval", kind: "scalar", T: 9 /* ScalarType.STRING */, opt: true },
    { no: 3, name: "initialDelay", kind: "scalar", T: 9 /* ScalarType.STRING */, opt: true },
    { no: 4, name: "count", kind: "message", T: IntOrString, opt: true },
    { no: 5, name: "successCondition", kind: "scalar", T: 9 /* ScalarType.STRING */, opt: true },
    { no: 6, name: "failureCondition", kind: "scalar", T: 9 /* ScalarType.STRING */, opt: true },
    { no: 7, name: "failureLimit", kind: "message", T: IntOrString, opt: true },
    { no: 8, name: "inconclusiveLimit", kind: "message", T: IntOrString, opt: true },
    { no: 9, name: "consecutiveErrorLimit", kind: "message", T: IntOrString, opt: true },
    { no: 10, name: "provider", kind: "message", T: MetricProvider, opt: true },
  ]);

  static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): Metric {
    return new Metric().fromBinary(bytes, options);
  }

  static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): Metric {
    return new Metric().fromJson(jsonValue, options);
  }

  static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): Metric {
    return new Metric().fromJsonString(jsonString, options);
  }

  static equals(a: Metric | PlainMessage<Metric> | undefined, b: Metric | PlainMessage<Metric> | undefined): boolean {
    return proto2.util.equals(Metric, a, b);
  }
}

/**
 * @generated from message github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.MetricProvider
 */
export class MetricProvider extends Message<MetricProvider> {
  /**
   * @generated from field: optional github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.PrometheusMetric prometheus = 1;
   */
  prometheus?: PrometheusMetric;

  /**
   * @generated from field: optional github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.KayentaMetric kayenta = 2;
   */
  kayenta?: KayentaMetric;

  /**
   * @generated from field: optional github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.WebMetric web = 3;
   */
  web?: WebMetric;

  /**
   * @generated from field: optional github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.DatadogMetric datadog = 4;
   */
  datadog?: DatadogMetric;

  /**
   * @generated from field: optional github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.WavefrontMetric wavefront = 5;
   */
  wavefront?: WavefrontMetric;

  /**
   * @generated from field: optional github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.NewRelicMetric newRelic = 6;
   */
  newRelic?: NewRelicMetric;

  /**
   * @generated from field: optional github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.JobMetric job = 7;
   */
  job?: JobMetric;

  /**
   * @generated from field: optional github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.CloudWatchMetric cloudWatch = 8;
   */
  cloudWatch?: CloudWatchMetric;

  /**
   * @generated from field: optional github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.GraphiteMetric graphite = 9;
   */
  graphite?: GraphiteMetric;

  /**
   * @generated from field: optional github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.InfluxdbMetric influxdb = 10;
   */
  influxdb?: InfluxdbMetric;

  /**
   * @generated from field: optional github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.SkyWalkingMetric skywalking = 11;
   */
  skywalking?: SkyWalkingMetric;

  /**
   * @generated from field: map<string, bytes> plugin = 12;
   */
  plugin: { [key: string]: Uint8Array } = {};

  constructor(data?: PartialMessage<MetricProvider>) {
    super();
    proto2.util.initPartial(data, this);
  }

  static readonly runtime: typeof proto2 = proto2;
  static readonly typeName = "github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.MetricProvider";
  static readonly fields: FieldList = proto2.util.newFieldList(() => [
    { no: 1, name: "prometheus", kind: "message", T: PrometheusMetric, opt: true },
    { no: 2, name: "kayenta", kind: "message", T: KayentaMetric, opt: true },
    { no: 3, name: "web", kind: "message", T: WebMetric, opt: true },
    { no: 4, name: "datadog", kind: "message", T: DatadogMetric, opt: true },
    { no: 5, name: "wavefront", kind: "message", T: WavefrontMetric, opt: true },
    { no: 6, name: "newRelic", kind: "message", T: NewRelicMetric, opt: true },
    { no: 7, name: "job", kind: "message", T: JobMetric, opt: true },
    { no: 8, name: "cloudWatch", kind: "message", T: CloudWatchMetric, opt: true },
    { no: 9, name: "graphite", kind: "message", T: GraphiteMetric, opt: true },
    { no: 10, name: "influxdb", kind: "message", T: InfluxdbMetric, opt: true },
    { no: 11, name: "skywalking", kind: "message", T: SkyWalkingMetric, opt: true },
    { no: 12, name: "plugin", kind: "map", K: 9 /* ScalarType.STRING */, V: {kind: "scalar", T: 12 /* ScalarType.BYTES */} },
  ]);

  static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): MetricProvider {
    return new MetricProvider().fromBinary(bytes, options);
  }

  static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): MetricProvider {
    return new MetricProvider().fromJson(jsonValue, options);
  }

  static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): MetricProvider {
    return new MetricProvider().fromJsonString(jsonString, options);
  }

  static equals(a: MetricProvider | PlainMessage<MetricProvider> | undefined, b: MetricProvider | PlainMessage<MetricProvider> | undefined): boolean {
    return proto2.util.equals(MetricProvider, a, b);
  }
}

/**
 * @generated from message github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.MetricResult
 */
export class MetricResult extends Message<MetricResult> {
  /**
   * @generated from field: optional string name = 1;
   */
  name?: string;

  /**
   * @generated from field: optional string phase = 2;
   */
  phase?: string;

  /**
   * @generated from field: repeated github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.Measurement measurements = 3;
   */
  measurements: Measurement[] = [];

  /**
   * @generated from field: optional string message = 4;
   */
  message?: string;

  /**
   * @generated from field: optional int32 count = 5;
   */
  count?: number;

  /**
   * @generated from field: optional int32 successful = 6;
   */
  successful?: number;

  /**
   * @generated from field: optional int32 failed = 7;
   */
  failed?: number;

  /**
   * @generated from field: optional int32 inconclusive = 8;
   */
  inconclusive?: number;

  /**
   * @generated from field: optional int32 error = 9;
   */
  error?: number;

  /**
   * @generated from field: optional int32 consecutiveError = 10;
   */
  consecutiveError?: number;

  /**
   * @generated from field: optional bool dryRun = 11;
   */
  dryRun?: boolean;

  /**
   * @generated from field: map<string, string> metadata = 12;
   */
  metadata: { [key: string]: string } = {};

  constructor(data?: PartialMessage<MetricResult>) {
    super();
    proto2.util.initPartial(data, this);
  }

  static readonly runtime: typeof proto2 = proto2;
  static readonly typeName = "github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.MetricResult";
  static readonly fields: FieldList = proto2.util.newFieldList(() => [
    { no: 1, name: "name", kind: "scalar", T: 9 /* ScalarType.STRING */, opt: true },
    { no: 2, name: "phase", kind: "scalar", T: 9 /* ScalarType.STRING */, opt: true },
    { no: 3, name: "measurements", kind: "message", T: Measurement, repeated: true },
    { no: 4, name: "message", kind: "scalar", T: 9 /* ScalarType.STRING */, opt: true },
    { no: 5, name: "count", kind: "scalar", T: 5 /* ScalarType.INT32 */, opt: true },
    { no: 6, name: "successful", kind: "scalar", T: 5 /* ScalarType.INT32 */, opt: true },
    { no: 7, name: "failed", kind: "scalar", T: 5 /* ScalarType.INT32 */, opt: true },
    { no: 8, name: "inconclusive", kind: "scalar", T: 5 /* ScalarType.INT32 */, opt: true },
    { no: 9, name: "error", kind: "scalar", T: 5 /* ScalarType.INT32 */, opt: true },
    { no: 10, name: "consecutiveError", kind: "scalar", T: 5 /* ScalarType.INT32 */, opt: true },
    { no: 11, name: "dryRun", kind: "scalar", T: 8 /* ScalarType.BOOL */, opt: true },
    { no: 12, name: "metadata", kind: "map", K: 9 /* ScalarType.STRING */, V: {kind: "scalar", T: 9 /* ScalarType.STRING */} },
  ]);

  static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): MetricResult {
    return new MetricResult().fromBinary(bytes, options);
  }

  static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): MetricResult {
    return new MetricResult().fromJson(jsonValue, options);
  }

  static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): MetricResult {
    return new MetricResult().fromJsonString(jsonString, options);
  }

  static equals(a: MetricResult | PlainMessage<MetricResult> | undefined, b: MetricResult | PlainMessage<MetricResult> | undefined): boolean {
    return proto2.util.equals(MetricResult, a, b);
  }
}

/**
 * @generated from message github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.NewRelicMetric
 */
export class NewRelicMetric extends Message<NewRelicMetric> {
  /**
   * @generated from field: optional string profile = 1;
   */
  profile?: string;

  /**
   * @generated from field: optional string query = 2;
   */
  query?: string;

  constructor(data?: PartialMessage<NewRelicMetric>) {
    super();
    proto2.util.initPartial(data, this);
  }

  static readonly runtime: typeof proto2 = proto2;
  static readonly typeName = "github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.NewRelicMetric";
  static readonly fields: FieldList = proto2.util.newFieldList(() => [
    { no: 1, name: "profile", kind: "scalar", T: 9 /* ScalarType.STRING */, opt: true },
    { no: 2, name: "query", kind: "scalar", T: 9 /* ScalarType.STRING */, opt: true },
  ]);

  static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): NewRelicMetric {
    return new NewRelicMetric().fromBinary(bytes, options);
  }

  static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): NewRelicMetric {
    return new NewRelicMetric().fromJson(jsonValue, options);
  }

  static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): NewRelicMetric {
    return new NewRelicMetric().fromJsonString(jsonString, options);
  }

  static equals(a: NewRelicMetric | PlainMessage<NewRelicMetric> | undefined, b: NewRelicMetric | PlainMessage<NewRelicMetric> | undefined): boolean {
    return proto2.util.equals(NewRelicMetric, a, b);
  }
}

/**
 * @generated from message github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.OAuth2Config
 */
export class OAuth2Config extends Message<OAuth2Config> {
  /**
   * @generated from field: optional string tokenUrl = 1;
   */
  tokenUrl?: string;

  /**
   * @generated from field: optional string clientId = 2;
   */
  clientId?: string;

  /**
   * @generated from field: optional string clientSecret = 3;
   */
  clientSecret?: string;

  /**
   * @generated from field: repeated string scopes = 4;
   */
  scopes: string[] = [];

  constructor(data?: PartialMessage<OAuth2Config>) {
    super();
    proto2.util.initPartial(data, this);
  }

  static readonly runtime: typeof proto2 = proto2;
  static readonly typeName = "github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.OAuth2Config";
  static readonly fields: FieldList = proto2.util.newFieldList(() => [
    { no: 1, name: "tokenUrl", kind: "scalar", T: 9 /* ScalarType.STRING */, opt: true },
    { no: 2, name: "clientId", kind: "scalar", T: 9 /* ScalarType.STRING */, opt: true },
    { no: 3, name: "clientSecret", kind: "scalar", T: 9 /* ScalarType.STRING */, opt: true },
    { no: 4, name: "scopes", kind: "scalar", T: 9 /* ScalarType.STRING */, repeated: true },
  ]);

  static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): OAuth2Config {
    return new OAuth2Config().fromBinary(bytes, options);
  }

  static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): OAuth2Config {
    return new OAuth2Config().fromJson(jsonValue, options);
  }

  static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): OAuth2Config {
    return new OAuth2Config().fromJsonString(jsonString, options);
  }

  static equals(a: OAuth2Config | PlainMessage<OAuth2Config> | undefined, b: OAuth2Config | PlainMessage<OAuth2Config> | undefined): boolean {
    return proto2.util.equals(OAuth2Config, a, b);
  }
}

/**
 * @generated from message github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.PrometheusMetric
 */
export class PrometheusMetric extends Message<PrometheusMetric> {
  /**
   * @generated from field: optional string address = 1;
   */
  address?: string;

  /**
   * @generated from field: optional string query = 2;
   */
  query?: string;

  /**
   * @generated from field: optional github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.Authentication authentication = 3;
   */
  authentication?: Authentication;

  /**
   * @generated from field: optional int64 timeout = 4;
   */
  timeout?: bigint;

  /**
   * @generated from field: optional bool insecure = 5;
   */
  insecure?: boolean;

  /**
   * @generated from field: repeated github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.WebMetricHeader headers = 6;
   */
  headers: WebMetricHeader[] = [];

  constructor(data?: PartialMessage<PrometheusMetric>) {
    super();
    proto2.util.initPartial(data, this);
  }

  static readonly runtime: typeof proto2 = proto2;
  static readonly typeName = "github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.PrometheusMetric";
  static readonly fields: FieldList = proto2.util.newFieldList(() => [
    { no: 1, name: "address", kind: "scalar", T: 9 /* ScalarType.STRING */, opt: true },
    { no: 2, name: "query", kind: "scalar", T: 9 /* ScalarType.STRING */, opt: true },
    { no: 3, name: "authentication", kind: "message", T: Authentication, opt: true },
    { no: 4, name: "timeout", kind: "scalar", T: 3 /* ScalarType.INT64 */, opt: true },
    { no: 5, name: "insecure", kind: "scalar", T: 8 /* ScalarType.BOOL */, opt: true },
    { no: 6, name: "headers", kind: "message", T: WebMetricHeader, repeated: true },
  ]);

  static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): PrometheusMetric {
    return new PrometheusMetric().fromBinary(bytes, options);
  }

  static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): PrometheusMetric {
    return new PrometheusMetric().fromJson(jsonValue, options);
  }

  static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): PrometheusMetric {
    return new PrometheusMetric().fromJsonString(jsonString, options);
  }

  static equals(a: PrometheusMetric | PlainMessage<PrometheusMetric> | undefined, b: PrometheusMetric | PlainMessage<PrometheusMetric> | undefined): boolean {
    return proto2.util.equals(PrometheusMetric, a, b);
  }
}

/**
 * @generated from message github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.RunSummary
 */
export class RunSummary extends Message<RunSummary> {
  /**
   * @generated from field: optional int32 count = 1;
   */
  count?: number;

  /**
   * @generated from field: optional int32 successful = 2;
   */
  successful?: number;

  /**
   * @generated from field: optional int32 failed = 3;
   */
  failed?: number;

  /**
   * @generated from field: optional int32 inconclusive = 4;
   */
  inconclusive?: number;

  /**
   * @generated from field: optional int32 error = 5;
   */
  error?: number;

  constructor(data?: PartialMessage<RunSummary>) {
    super();
    proto2.util.initPartial(data, this);
  }

  static readonly runtime: typeof proto2 = proto2;
  static readonly typeName = "github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.RunSummary";
  static readonly fields: FieldList = proto2.util.newFieldList(() => [
    { no: 1, name: "count", kind: "scalar", T: 5 /* ScalarType.INT32 */, opt: true },
    { no: 2, name: "successful", kind: "scalar", T: 5 /* ScalarType.INT32 */, opt: true },
    { no: 3, name: "failed", kind: "scalar", T: 5 /* ScalarType.INT32 */, opt: true },
    { no: 4, name: "inconclusive", kind: "scalar", T: 5 /* ScalarType.INT32 */, opt: true },
    { no: 5, name: "error", kind: "scalar", T: 5 /* ScalarType.INT32 */, opt: true },
  ]);

  static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): RunSummary {
    return new RunSummary().fromBinary(bytes, options);
  }

  static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): RunSummary {
    return new RunSummary().fromJson(jsonValue, options);
  }

  static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): RunSummary {
    return new RunSummary().fromJsonString(jsonString, options);
  }

  static equals(a: RunSummary | PlainMessage<RunSummary> | undefined, b: RunSummary | PlainMessage<RunSummary> | undefined): boolean {
    return proto2.util.equals(RunSummary, a, b);
  }
}

/**
 * @generated from message github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.ScopeDetail
 */
export class ScopeDetail extends Message<ScopeDetail> {
  /**
   * @generated from field: optional string scope = 1;
   */
  scope?: string;

  /**
   * @generated from field: optional string region = 2;
   */
  region?: string;

  /**
   * @generated from field: optional int64 step = 3;
   */
  step?: bigint;

  /**
   * @generated from field: optional string start = 4;
   */
  start?: string;

  /**
   * @generated from field: optional string end = 5;
   */
  end?: string;

  constructor(data?: PartialMessage<ScopeDetail>) {
    super();
    proto2.util.initPartial(data, this);
  }

  static readonly runtime: typeof proto2 = proto2;
  static readonly typeName = "github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.ScopeDetail";
  static readonly fields: FieldList = proto2.util.newFieldList(() => [
    { no: 1, name: "scope", kind: "scalar", T: 9 /* ScalarType.STRING */, opt: true },
    { no: 2, name: "region", kind: "scalar", T: 9 /* ScalarType.STRING */, opt: true },
    { no: 3, name: "step", kind: "scalar", T: 3 /* ScalarType.INT64 */, opt: true },
    { no: 4, name: "start", kind: "scalar", T: 9 /* ScalarType.STRING */, opt: true },
    { no: 5, name: "end", kind: "scalar", T: 9 /* ScalarType.STRING */, opt: true },
  ]);

  static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): ScopeDetail {
    return new ScopeDetail().fromBinary(bytes, options);
  }

  static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): ScopeDetail {
    return new ScopeDetail().fromJson(jsonValue, options);
  }

  static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): ScopeDetail {
    return new ScopeDetail().fromJsonString(jsonString, options);
  }

  static equals(a: ScopeDetail | PlainMessage<ScopeDetail> | undefined, b: ScopeDetail | PlainMessage<ScopeDetail> | undefined): boolean {
    return proto2.util.equals(ScopeDetail, a, b);
  }
}

/**
 * @generated from message github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.SecretKeyRef
 */
export class SecretKeyRef extends Message<SecretKeyRef> {
  /**
   * @generated from field: optional string name = 1;
   */
  name?: string;

  /**
   * @generated from field: optional string key = 2;
   */
  key?: string;

  constructor(data?: PartialMessage<SecretKeyRef>) {
    super();
    proto2.util.initPartial(data, this);
  }

  static readonly runtime: typeof proto2 = proto2;
  static readonly typeName = "github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.SecretKeyRef";
  static readonly fields: FieldList = proto2.util.newFieldList(() => [
    { no: 1, name: "name", kind: "scalar", T: 9 /* ScalarType.STRING */, opt: true },
    { no: 2, name: "key", kind: "scalar", T: 9 /* ScalarType.STRING */, opt: true },
  ]);

  static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): SecretKeyRef {
    return new SecretKeyRef().fromBinary(bytes, options);
  }

  static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): SecretKeyRef {
    return new SecretKeyRef().fromJson(jsonValue, options);
  }

  static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): SecretKeyRef {
    return new SecretKeyRef().fromJsonString(jsonString, options);
  }

  static equals(a: SecretKeyRef | PlainMessage<SecretKeyRef> | undefined, b: SecretKeyRef | PlainMessage<SecretKeyRef> | undefined): boolean {
    return proto2.util.equals(SecretKeyRef, a, b);
  }
}

/**
 * @generated from message github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.Sigv4Config
 */
export class Sigv4Config extends Message<Sigv4Config> {
  /**
   * @generated from field: optional string region = 1;
   */
  region?: string;

  /**
   * @generated from field: optional string profile = 2;
   */
  profile?: string;

  /**
   * @generated from field: optional string roleArn = 3;
   */
  roleArn?: string;

  constructor(data?: PartialMessage<Sigv4Config>) {
    super();
    proto2.util.initPartial(data, this);
  }

  static readonly runtime: typeof proto2 = proto2;
  static readonly typeName = "github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.Sigv4Config";
  static readonly fields: FieldList = proto2.util.newFieldList(() => [
    { no: 1, name: "region", kind: "scalar", T: 9 /* ScalarType.STRING */, opt: true },
    { no: 2, name: "profile", kind: "scalar", T: 9 /* ScalarType.STRING */, opt: true },
    { no: 3, name: "roleArn", kind: "scalar", T: 9 /* ScalarType.STRING */, opt: true },
  ]);

  static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): Sigv4Config {
    return new Sigv4Config().fromBinary(bytes, options);
  }

  static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): Sigv4Config {
    return new Sigv4Config().fromJson(jsonValue, options);
  }

  static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): Sigv4Config {
    return new Sigv4Config().fromJsonString(jsonString, options);
  }

  static equals(a: Sigv4Config | PlainMessage<Sigv4Config> | undefined, b: Sigv4Config | PlainMessage<Sigv4Config> | undefined): boolean {
    return proto2.util.equals(Sigv4Config, a, b);
  }
}

/**
 * @generated from message github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.SkyWalkingMetric
 */
export class SkyWalkingMetric extends Message<SkyWalkingMetric> {
  /**
   * @generated from field: optional string address = 1;
   */
  address?: string;

  /**
   * @generated from field: optional string query = 2;
   */
  query?: string;

  /**
   * @generated from field: optional string interval = 3;
   */
  interval?: string;

  constructor(data?: PartialMessage<SkyWalkingMetric>) {
    super();
    proto2.util.initPartial(data, this);
  }

  static readonly runtime: typeof proto2 = proto2;
  static readonly typeName = "github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.SkyWalkingMetric";
  static readonly fields: FieldList = proto2.util.newFieldList(() => [
    { no: 1, name: "address", kind: "scalar", T: 9 /* ScalarType.STRING */, opt: true },
    { no: 2, name: "query", kind: "scalar", T: 9 /* ScalarType.STRING */, opt: true },
    { no: 3, name: "interval", kind: "scalar", T: 9 /* ScalarType.STRING */, opt: true },
  ]);

  static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): SkyWalkingMetric {
    return new SkyWalkingMetric().fromBinary(bytes, options);
  }

  static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): SkyWalkingMetric {
    return new SkyWalkingMetric().fromJson(jsonValue, options);
  }

  static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): SkyWalkingMetric {
    return new SkyWalkingMetric().fromJsonString(jsonString, options);
  }

  static equals(a: SkyWalkingMetric | PlainMessage<SkyWalkingMetric> | undefined, b: SkyWalkingMetric | PlainMessage<SkyWalkingMetric> | undefined): boolean {
    return proto2.util.equals(SkyWalkingMetric, a, b);
  }
}

/**
 * @generated from message github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.ValueFrom
 */
export class ValueFrom extends Message<ValueFrom> {
  /**
   * @generated from field: optional github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.SecretKeyRef secretKeyRef = 1;
   */
  secretKeyRef?: SecretKeyRef;

  /**
   * @generated from field: optional github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.FieldRef fieldRef = 2;
   */
  fieldRef?: FieldRef;

  constructor(data?: PartialMessage<ValueFrom>) {
    super();
    proto2.util.initPartial(data, this);
  }

  static readonly runtime: typeof proto2 = proto2;
  static readonly typeName = "github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.ValueFrom";
  static readonly fields: FieldList = proto2.util.newFieldList(() => [
    { no: 1, name: "secretKeyRef", kind: "message", T: SecretKeyRef, opt: true },
    { no: 2, name: "fieldRef", kind: "message", T: FieldRef, opt: true },
  ]);

  static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): ValueFrom {
    return new ValueFrom().fromBinary(bytes, options);
  }

  static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): ValueFrom {
    return new ValueFrom().fromJson(jsonValue, options);
  }

  static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): ValueFrom {
    return new ValueFrom().fromJsonString(jsonString, options);
  }

  static equals(a: ValueFrom | PlainMessage<ValueFrom> | undefined, b: ValueFrom | PlainMessage<ValueFrom> | undefined): boolean {
    return proto2.util.equals(ValueFrom, a, b);
  }
}

/**
 * @generated from message github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.WavefrontMetric
 */
export class WavefrontMetric extends Message<WavefrontMetric> {
  /**
   * @generated from field: optional string address = 1;
   */
  address?: string;

  /**
   * @generated from field: optional string query = 2;
   */
  query?: string;

  constructor(data?: PartialMessage<WavefrontMetric>) {
    super();
    proto2.util.initPartial(data, this);
  }

  static readonly runtime: typeof proto2 = proto2;
  static readonly typeName = "github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.WavefrontMetric";
  static readonly fields: FieldList = proto2.util.newFieldList(() => [
    { no: 1, name: "address", kind: "scalar", T: 9 /* ScalarType.STRING */, opt: true },
    { no: 2, name: "query", kind: "scalar", T: 9 /* ScalarType.STRING */, opt: true },
  ]);

  static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): WavefrontMetric {
    return new WavefrontMetric().fromBinary(bytes, options);
  }

  static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): WavefrontMetric {
    return new WavefrontMetric().fromJson(jsonValue, options);
  }

  static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): WavefrontMetric {
    return new WavefrontMetric().fromJsonString(jsonString, options);
  }

  static equals(a: WavefrontMetric | PlainMessage<WavefrontMetric> | undefined, b: WavefrontMetric | PlainMessage<WavefrontMetric> | undefined): boolean {
    return proto2.util.equals(WavefrontMetric, a, b);
  }
}

/**
 * @generated from message github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.WebMetric
 */
export class WebMetric extends Message<WebMetric> {
  /**
   * @generated from field: optional string method = 1;
   */
  method?: string;

  /**
   * URL is the address of the web metric
   *
   * @generated from field: optional string url = 2;
   */
  url?: string;

  /**
   * @generated from field: repeated github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.WebMetricHeader headers = 3;
   */
  headers: WebMetricHeader[] = [];

  /**
   * @generated from field: optional string body = 4;
   */
  body?: string;

  /**
   * @generated from field: optional int64 timeoutSeconds = 5;
   */
  timeoutSeconds?: bigint;

  /**
   * @generated from field: optional string jsonPath = 6;
   */
  jsonPath?: string;

  /**
   * @generated from field: optional bool insecure = 7;
   */
  insecure?: boolean;

  /**
   * @generated from field: optional bytes jsonBody = 8;
   */
  jsonBody?: Uint8Array;

  /**
   * @generated from field: optional github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.Authentication authentication = 9;
   */
  authentication?: Authentication;

  constructor(data?: PartialMessage<WebMetric>) {
    super();
    proto2.util.initPartial(data, this);
  }

  static readonly runtime: typeof proto2 = proto2;
  static readonly typeName = "github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.WebMetric";
  static readonly fields: FieldList = proto2.util.newFieldList(() => [
    { no: 1, name: "method", kind: "scalar", T: 9 /* ScalarType.STRING */, opt: true },
    { no: 2, name: "url", kind: "scalar", T: 9 /* ScalarType.STRING */, opt: true },
    { no: 3, name: "headers", kind: "message", T: WebMetricHeader, repeated: true },
    { no: 4, name: "body", kind: "scalar", T: 9 /* ScalarType.STRING */, opt: true },
    { no: 5, name: "timeoutSeconds", kind: "scalar", T: 3 /* ScalarType.INT64 */, opt: true },
    { no: 6, name: "jsonPath", kind: "scalar", T: 9 /* ScalarType.STRING */, opt: true },
    { no: 7, name: "insecure", kind: "scalar", T: 8 /* ScalarType.BOOL */, opt: true },
    { no: 8, name: "jsonBody", kind: "scalar", T: 12 /* ScalarType.BYTES */, opt: true },
    { no: 9, name: "authentication", kind: "message", T: Authentication, opt: true },
  ]);

  static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): WebMetric {
    return new WebMetric().fromBinary(bytes, options);
  }

  static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): WebMetric {
    return new WebMetric().fromJson(jsonValue, options);
  }

  static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): WebMetric {
    return new WebMetric().fromJsonString(jsonString, options);
  }

  static equals(a: WebMetric | PlainMessage<WebMetric> | undefined, b: WebMetric | PlainMessage<WebMetric> | undefined): boolean {
    return proto2.util.equals(WebMetric, a, b);
  }
}

/**
 * @generated from message github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.WebMetricHeader
 */
export class WebMetricHeader extends Message<WebMetricHeader> {
  /**
   * @generated from field: optional string key = 1;
   */
  key?: string;

  /**
   * @generated from field: optional string value = 2;
   */
  value?: string;

  constructor(data?: PartialMessage<WebMetricHeader>) {
    super();
    proto2.util.initPartial(data, this);
  }

  static readonly runtime: typeof proto2 = proto2;
  static readonly typeName = "github.com.akuity.kargo.internal.controller.rollouts.api.v1alpha1.WebMetricHeader";
  static readonly fields: FieldList = proto2.util.newFieldList(() => [
    { no: 1, name: "key", kind: "scalar", T: 9 /* ScalarType.STRING */, opt: true },
    { no: 2, name: "value", kind: "scalar", T: 9 /* ScalarType.STRING */, opt: true },
  ]);

  static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): WebMetricHeader {
    return new WebMetricHeader().fromBinary(bytes, options);
  }

  static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): WebMetricHeader {
    return new WebMetricHeader().fromJson(jsonValue, options);
  }

  static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): WebMetricHeader {
    return new WebMetricHeader().fromJsonString(jsonString, options);
  }

  static equals(a: WebMetricHeader | PlainMessage<WebMetricHeader> | undefined, b: WebMetricHeader | PlainMessage<WebMetricHeader> | undefined): boolean {
    return proto2.util.equals(WebMetricHeader, a, b);
  }
}

