content: /*
   * Copyright (c) 2020-2025 Airbyte, Inc., all rights reserved.
   */
  
  package io.airbyte.config;
  
  import com.fasterxml.jackson.annotation.JsonInclude;
  import com.fasterxml.jackson.annotation.JsonProperty;
  import com.fasterxml.jackson.annotation.JsonPropertyDescription;
  import com.fasterxml.jackson.annotation.JsonPropertyOrder;
  import jakarta.annotation.Generated;
  import java.io.Serializable;
  import java.util.Objects;
  
  /**
   * RolloutConfiguration
   * <p>
   * configuration for the rollout of a connector
   *
   */
  @JsonInclude(JsonInclude.Include.NON_NULL)
  @JsonPropertyOrder({
    "initialPercentage",
    "maxPercentage",
    "advanceDelayMinutes"
  })
  @Generated(value = "Generated by jsonSchema2Pojo")
  public class RolloutConfiguration implements Serializable {
  
    /**
     * The percentage of users that should receive the new version initially.
     *
     */
    @JsonProperty("initialPercentage")
    @JsonPropertyDescription("The percentage of users that should receive the new version initially.")
    private Long initialPercentage = 0L;
    /**
     * The percentage of users who should receive the release candidate during the test phase before
     * full rollout.
     *
     */
    @JsonProperty("maxPercentage")
    @JsonPropertyDescription("The percentage of users who should receive the release candidate during the test phase before full rollout.")
    private Long maxPercentage = 50L;
    /**
     * The number of minutes to wait before advancing the rollout percentage.
     *
     */
    @JsonProperty("advanceDelayMinutes")
    @JsonPropertyDescription("The number of minutes to wait before advancing the rollout percentage.")
    private Long advanceDelayMinutes = 10L;
    private final static long serialVersionUID = 67565051722744898L;
  
    /**
     * The percentage of users that should receive the new version initially.
     *
     */
    @JsonProperty("initialPercentage")
    public Long getInitialPercentage() {
      return initialPercentage;
    }
  
    /**
     * The percentage of users that should receive the new version initially.
     *
     */
    @JsonProperty("initialPercentage")
    public void setInitialPercentage(Long initialPercentage) {
      this.initialPercentage = initialPercentage;
    }
  
    public RolloutConfiguration withInitialPercentage(Long initialPercentage) {
      this.initialPercentage = initialPercentage;
      return this;
    }
  
    /**
     * The percentage of users who should receive the release candidate during the test phase before
     * full rollout.
     *
     */
    @JsonProperty("maxPercentage")
    public Long getMaxPercentage() {
      return maxPercentage;
    }
  
    /**
     * The percentage of users who should receive the release candidate during the test phase before
     * full rollout.
     *
     */
    @JsonProperty("maxPercentage")
    public void setMaxPercentage(Long maxPercentage) {
      this.maxPercentage = maxPercentage;
    }
  
    public RolloutConfiguration withMaxPercentage(Long maxPercentage) {
      this.maxPercentage = maxPercentage;
      return this;
    }
  
    /**
     * The number of minutes to wait before advancing the rollout percentage.
     *
     */
    @JsonProperty("advanceDelayMinutes")
    public Long getAdvanceDelayMinutes() {
      return advanceDelayMinutes;
    }
  
    /**
     * The number of minutes to wait before advancing the rollout percentage.
     *
     */
    @JsonProperty("advanceDelayMinutes")
    public void setAdvanceDelayMinutes(Long advanceDelayMinutes) {
      this.advanceDelayMinutes = advanceDelayMinutes;
    }
  
    public RolloutConfiguration withAdvanceDelayMinutes(Long advanceDelayMinutes) {
      this.advanceDelayMinutes = advanceDelayMinutes;
      return this;
    }
  
    @Override
    public String toString() {
      StringBuilder sb = new StringBuilder();
      sb.append(RolloutConfiguration.class.getName()).append('@').append(Integer.toHexString(System.identityHashCode(this))).append('[');
      sb.append("initialPercentage");
      sb.append('=');
      sb.append(((this.initialPercentage == null) ? "<null>" : this.initialPercentage));
      sb.append(',');
      sb.append("maxPercentage");
      sb.append('=');
      sb.append(((this.maxPercentage == null) ? "<null>" : this.maxPercentage));
      sb.append(',');
      sb.append("advanceDelayMinutes");
      sb.append('=');
      sb.append(((this.advanceDelayMinutes == null) ? "<null>" : this.advanceDelayMinutes));
      sb.append(',');
      if (sb.charAt((sb.length() - 1)) == ',') {
        sb.setCharAt((sb.length() - 1), ']');
      } else {
        sb.append(']');
      }
      return sb.toString();
    }
  
    @Override
    public int hashCode() {
      int result = 1;
      result = ((result * 31) + ((this.initialPercentage == null) ? 0 : this.initialPercentage.hashCode()));
      result = ((result * 31) + ((this.advanceDelayMinutes == null) ? 0 : this.advanceDelayMinutes.hashCode()));
      result = ((result * 31) + ((this.maxPercentage == null) ? 0 : this.maxPercentage.hashCode()));
      return result;
    }
  
    @Override
    public boolean equals(Object other) {
      if (other == this) {
        return true;
      }
      if ((other instanceof RolloutConfiguration) == false) {
        return false;
      }
      RolloutConfiguration rhs = ((RolloutConfiguration) other);
      return ((((Objects.equals(this.initialPercentage, rhs.initialPercentage))
          || ((this.initialPercentage != null) && this.initialPercentage.equals(rhs.initialPercentage)))
          && ((Objects.equals(this.advanceDelayMinutes, rhs.advanceDelayMinutes))
              || ((this.advanceDelayMinutes != null) && this.advanceDelayMinutes.equals(rhs.advanceDelayMinutes))))
          && ((Objects.equals(this.maxPercentage, rhs.maxPercentage))
              || ((this.maxPercentage != null) && this.maxPercentage.equals(rhs.maxPercentage))));
    }
  
  }
  