/* * Copyright 2018-2023 Amazon.com, Inc. or its affiliates. All Rights Reserved. * * Licensed under the Apache License, Version 2.0 (the "License"). You may not use this file except in compliance with * the License. A copy of the License is located at * * http://aws.amazon.com/apache2.0 * * or in the "license" file accompanying this file. This file 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. */ package com.amazonaws.services.opensearch.model; import java.io.Serializable; import javax.annotation.Generated; import com.amazonaws.protocol.StructuredPojo; import com.amazonaws.protocol.ProtocolMarshaller; /** *
* Auto-Tune settings when updating a domain. For more information, see Auto-Tune for Amazon * OpenSearch Service. *
*/ @Generated("com.amazonaws:aws-java-sdk-code-generator") public class AutoTuneOptions implements Serializable, Cloneable, StructuredPojo { /** ** Whether Auto-Tune is enabled or disabled. *
*/ private String desiredState; /** *
* When disabling Auto-Tune, specify NO_ROLLBACK
to retain all prior Auto-Tune settings or
* DEFAULT_ROLLBACK
to revert to the OpenSearch Service defaults. If you specify
* DEFAULT_ROLLBACK
, you must include a MaintenanceSchedule
in the request. Otherwise,
* OpenSearch Service is unable to perform the rollback.
*
* DEPRECATED. Use off-peak window * instead. *
** A list of maintenance schedules during which Auto-Tune can deploy changes. *
*/ private java.util.List* Whether to use the domain's off-peak * window to deploy configuration changes on the domain rather than a maintenance schedule. *
*/ private Boolean useOffPeakWindow; /** ** Whether Auto-Tune is enabled or disabled. *
* * @param desiredState * Whether Auto-Tune is enabled or disabled. * @see AutoTuneDesiredState */ public void setDesiredState(String desiredState) { this.desiredState = desiredState; } /** ** Whether Auto-Tune is enabled or disabled. *
* * @return Whether Auto-Tune is enabled or disabled. * @see AutoTuneDesiredState */ public String getDesiredState() { return this.desiredState; } /** ** Whether Auto-Tune is enabled or disabled. *
* * @param desiredState * Whether Auto-Tune is enabled or disabled. * @return Returns a reference to this object so that method calls can be chained together. * @see AutoTuneDesiredState */ public AutoTuneOptions withDesiredState(String desiredState) { setDesiredState(desiredState); return this; } /** ** Whether Auto-Tune is enabled or disabled. *
* * @param desiredState * Whether Auto-Tune is enabled or disabled. * @return Returns a reference to this object so that method calls can be chained together. * @see AutoTuneDesiredState */ public AutoTuneOptions withDesiredState(AutoTuneDesiredState desiredState) { this.desiredState = desiredState.toString(); return this; } /** *
* When disabling Auto-Tune, specify NO_ROLLBACK
to retain all prior Auto-Tune settings or
* DEFAULT_ROLLBACK
to revert to the OpenSearch Service defaults. If you specify
* DEFAULT_ROLLBACK
, you must include a MaintenanceSchedule
in the request. Otherwise,
* OpenSearch Service is unable to perform the rollback.
*
NO_ROLLBACK
to retain all prior Auto-Tune settings or
* DEFAULT_ROLLBACK
to revert to the OpenSearch Service defaults. If you specify
* DEFAULT_ROLLBACK
, you must include a MaintenanceSchedule
in the request.
* Otherwise, OpenSearch Service is unable to perform the rollback.
* @see RollbackOnDisable
*/
public void setRollbackOnDisable(String rollbackOnDisable) {
this.rollbackOnDisable = rollbackOnDisable;
}
/**
*
* When disabling Auto-Tune, specify NO_ROLLBACK
to retain all prior Auto-Tune settings or
* DEFAULT_ROLLBACK
to revert to the OpenSearch Service defaults. If you specify
* DEFAULT_ROLLBACK
, you must include a MaintenanceSchedule
in the request. Otherwise,
* OpenSearch Service is unable to perform the rollback.
*
NO_ROLLBACK
to retain all prior Auto-Tune settings or
* DEFAULT_ROLLBACK
to revert to the OpenSearch Service defaults. If you specify
* DEFAULT_ROLLBACK
, you must include a MaintenanceSchedule
in the request.
* Otherwise, OpenSearch Service is unable to perform the rollback.
* @see RollbackOnDisable
*/
public String getRollbackOnDisable() {
return this.rollbackOnDisable;
}
/**
*
* When disabling Auto-Tune, specify NO_ROLLBACK
to retain all prior Auto-Tune settings or
* DEFAULT_ROLLBACK
to revert to the OpenSearch Service defaults. If you specify
* DEFAULT_ROLLBACK
, you must include a MaintenanceSchedule
in the request. Otherwise,
* OpenSearch Service is unable to perform the rollback.
*
NO_ROLLBACK
to retain all prior Auto-Tune settings or
* DEFAULT_ROLLBACK
to revert to the OpenSearch Service defaults. If you specify
* DEFAULT_ROLLBACK
, you must include a MaintenanceSchedule
in the request.
* Otherwise, OpenSearch Service is unable to perform the rollback.
* @return Returns a reference to this object so that method calls can be chained together.
* @see RollbackOnDisable
*/
public AutoTuneOptions withRollbackOnDisable(String rollbackOnDisable) {
setRollbackOnDisable(rollbackOnDisable);
return this;
}
/**
*
* When disabling Auto-Tune, specify NO_ROLLBACK
to retain all prior Auto-Tune settings or
* DEFAULT_ROLLBACK
to revert to the OpenSearch Service defaults. If you specify
* DEFAULT_ROLLBACK
, you must include a MaintenanceSchedule
in the request. Otherwise,
* OpenSearch Service is unable to perform the rollback.
*
NO_ROLLBACK
to retain all prior Auto-Tune settings or
* DEFAULT_ROLLBACK
to revert to the OpenSearch Service defaults. If you specify
* DEFAULT_ROLLBACK
, you must include a MaintenanceSchedule
in the request.
* Otherwise, OpenSearch Service is unable to perform the rollback.
* @return Returns a reference to this object so that method calls can be chained together.
* @see RollbackOnDisable
*/
public AutoTuneOptions withRollbackOnDisable(RollbackOnDisable rollbackOnDisable) {
this.rollbackOnDisable = rollbackOnDisable.toString();
return this;
}
/**
* * DEPRECATED. Use off-peak window * instead. *
** A list of maintenance schedules during which Auto-Tune can deploy changes. *
* * @return DEPRECATED. Use off-peak * window instead. *
* A list of maintenance schedules during which Auto-Tune can deploy changes.
*/
public java.util.List
* DEPRECATED. Use off-peak window
* instead.
*
* A list of maintenance schedules during which Auto-Tune can deploy changes.
*
* A list of maintenance schedules during which Auto-Tune can deploy changes.
*/
public void setMaintenanceSchedules(java.util.Collection
* DEPRECATED. Use off-peak window
* instead.
*
* A list of maintenance schedules during which Auto-Tune can deploy changes.
*
* NOTE: This method appends the values to the existing list (if any). Use
* {@link #setMaintenanceSchedules(java.util.Collection)} or {@link #withMaintenanceSchedules(java.util.Collection)}
* if you want to override the existing values.
*
* A list of maintenance schedules during which Auto-Tune can deploy changes.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public AutoTuneOptions withMaintenanceSchedules(AutoTuneMaintenanceSchedule... maintenanceSchedules) {
if (this.maintenanceSchedules == null) {
setMaintenanceSchedules(new java.util.ArrayList
* DEPRECATED. Use off-peak window
* instead.
*
* A list of maintenance schedules during which Auto-Tune can deploy changes.
*
* A list of maintenance schedules during which Auto-Tune can deploy changes.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public AutoTuneOptions withMaintenanceSchedules(java.util.Collection
* Whether to use the domain's off-peak
* window to deploy configuration changes on the domain rather than a maintenance schedule.
*
* Whether to use the domain's off-peak
* window to deploy configuration changes on the domain rather than a maintenance schedule.
*
* Whether to use the domain's off-peak
* window to deploy configuration changes on the domain rather than a maintenance schedule.
*
* Whether to use the domain's off-peak
* window to deploy configuration changes on the domain rather than a maintenance schedule.
*