/** * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. * SPDX-License-Identifier: Apache-2.0. */ #pragma once #include #include #include #include #include namespace Aws { namespace Utils { namespace Xml { class XmlNode; } // namespace Xml } // namespace Utils namespace RDS { namespace Model { /** *

Contains the state of scheduled or in-process failover operations on an * Aurora global database (GlobalCluster). This Data type is empty unless a * failover operation is scheduled or is currently underway on the Aurora global * database.

See Also:

AWS * API Reference

*/ class FailoverState { public: AWS_RDS_API FailoverState(); AWS_RDS_API FailoverState(const Aws::Utils::Xml::XmlNode& xmlNode); AWS_RDS_API FailoverState& operator=(const Aws::Utils::Xml::XmlNode& xmlNode); AWS_RDS_API void OutputToStream(Aws::OStream& ostream, const char* location, unsigned index, const char* locationValue) const; AWS_RDS_API void OutputToStream(Aws::OStream& oStream, const char* location) const; /** *

The current status of the Aurora global database (GlobalCluster). * Possible values are as follows:

  • pending – A request to * fail over the Aurora global database (GlobalCluster) has been received by * the service. The GlobalCluster's primary DB cluster and the * specified secondary DB cluster are being verified before the failover process * can start.

  • failing-over – This status covers the range of * Aurora internal operations that take place during the failover process, such as * demoting the primary Aurora DB cluster, promoting the secondary Aurora DB, and * synchronizing replicas.

  • cancelling – The request to fail * over the Aurora global database (GlobalCluster) was cancelled and the * primary Aurora DB cluster and the selected secondary Aurora DB cluster are * returning to their previous states.

*/ inline const FailoverStatus& GetStatus() const{ return m_status; } /** *

The current status of the Aurora global database (GlobalCluster). * Possible values are as follows:

  • pending – A request to * fail over the Aurora global database (GlobalCluster) has been received by * the service. The GlobalCluster's primary DB cluster and the * specified secondary DB cluster are being verified before the failover process * can start.

  • failing-over – This status covers the range of * Aurora internal operations that take place during the failover process, such as * demoting the primary Aurora DB cluster, promoting the secondary Aurora DB, and * synchronizing replicas.

  • cancelling – The request to fail * over the Aurora global database (GlobalCluster) was cancelled and the * primary Aurora DB cluster and the selected secondary Aurora DB cluster are * returning to their previous states.

*/ inline bool StatusHasBeenSet() const { return m_statusHasBeenSet; } /** *

The current status of the Aurora global database (GlobalCluster). * Possible values are as follows:

  • pending – A request to * fail over the Aurora global database (GlobalCluster) has been received by * the service. The GlobalCluster's primary DB cluster and the * specified secondary DB cluster are being verified before the failover process * can start.

  • failing-over – This status covers the range of * Aurora internal operations that take place during the failover process, such as * demoting the primary Aurora DB cluster, promoting the secondary Aurora DB, and * synchronizing replicas.

  • cancelling – The request to fail * over the Aurora global database (GlobalCluster) was cancelled and the * primary Aurora DB cluster and the selected secondary Aurora DB cluster are * returning to their previous states.

*/ inline void SetStatus(const FailoverStatus& value) { m_statusHasBeenSet = true; m_status = value; } /** *

The current status of the Aurora global database (GlobalCluster). * Possible values are as follows:

  • pending – A request to * fail over the Aurora global database (GlobalCluster) has been received by * the service. The GlobalCluster's primary DB cluster and the * specified secondary DB cluster are being verified before the failover process * can start.

  • failing-over – This status covers the range of * Aurora internal operations that take place during the failover process, such as * demoting the primary Aurora DB cluster, promoting the secondary Aurora DB, and * synchronizing replicas.

  • cancelling – The request to fail * over the Aurora global database (GlobalCluster) was cancelled and the * primary Aurora DB cluster and the selected secondary Aurora DB cluster are * returning to their previous states.

*/ inline void SetStatus(FailoverStatus&& value) { m_statusHasBeenSet = true; m_status = std::move(value); } /** *

The current status of the Aurora global database (GlobalCluster). * Possible values are as follows:

  • pending – A request to * fail over the Aurora global database (GlobalCluster) has been received by * the service. The GlobalCluster's primary DB cluster and the * specified secondary DB cluster are being verified before the failover process * can start.

  • failing-over – This status covers the range of * Aurora internal operations that take place during the failover process, such as * demoting the primary Aurora DB cluster, promoting the secondary Aurora DB, and * synchronizing replicas.

  • cancelling – The request to fail * over the Aurora global database (GlobalCluster) was cancelled and the * primary Aurora DB cluster and the selected secondary Aurora DB cluster are * returning to their previous states.

*/ inline FailoverState& WithStatus(const FailoverStatus& value) { SetStatus(value); return *this;} /** *

The current status of the Aurora global database (GlobalCluster). * Possible values are as follows:

  • pending – A request to * fail over the Aurora global database (GlobalCluster) has been received by * the service. The GlobalCluster's primary DB cluster and the * specified secondary DB cluster are being verified before the failover process * can start.

  • failing-over – This status covers the range of * Aurora internal operations that take place during the failover process, such as * demoting the primary Aurora DB cluster, promoting the secondary Aurora DB, and * synchronizing replicas.

  • cancelling – The request to fail * over the Aurora global database (GlobalCluster) was cancelled and the * primary Aurora DB cluster and the selected secondary Aurora DB cluster are * returning to their previous states.

*/ inline FailoverState& WithStatus(FailoverStatus&& value) { SetStatus(std::move(value)); return *this;} /** *

The Amazon Resource Name (ARN) of the Aurora DB cluster that is currently * being demoted, and which is associated with this state.

*/ inline const Aws::String& GetFromDbClusterArn() const{ return m_fromDbClusterArn; } /** *

The Amazon Resource Name (ARN) of the Aurora DB cluster that is currently * being demoted, and which is associated with this state.

*/ inline bool FromDbClusterArnHasBeenSet() const { return m_fromDbClusterArnHasBeenSet; } /** *

The Amazon Resource Name (ARN) of the Aurora DB cluster that is currently * being demoted, and which is associated with this state.

*/ inline void SetFromDbClusterArn(const Aws::String& value) { m_fromDbClusterArnHasBeenSet = true; m_fromDbClusterArn = value; } /** *

The Amazon Resource Name (ARN) of the Aurora DB cluster that is currently * being demoted, and which is associated with this state.

*/ inline void SetFromDbClusterArn(Aws::String&& value) { m_fromDbClusterArnHasBeenSet = true; m_fromDbClusterArn = std::move(value); } /** *

The Amazon Resource Name (ARN) of the Aurora DB cluster that is currently * being demoted, and which is associated with this state.

*/ inline void SetFromDbClusterArn(const char* value) { m_fromDbClusterArnHasBeenSet = true; m_fromDbClusterArn.assign(value); } /** *

The Amazon Resource Name (ARN) of the Aurora DB cluster that is currently * being demoted, and which is associated with this state.

*/ inline FailoverState& WithFromDbClusterArn(const Aws::String& value) { SetFromDbClusterArn(value); return *this;} /** *

The Amazon Resource Name (ARN) of the Aurora DB cluster that is currently * being demoted, and which is associated with this state.

*/ inline FailoverState& WithFromDbClusterArn(Aws::String&& value) { SetFromDbClusterArn(std::move(value)); return *this;} /** *

The Amazon Resource Name (ARN) of the Aurora DB cluster that is currently * being demoted, and which is associated with this state.

*/ inline FailoverState& WithFromDbClusterArn(const char* value) { SetFromDbClusterArn(value); return *this;} /** *

The Amazon Resource Name (ARN) of the Aurora DB cluster that is currently * being promoted, and which is associated with this state.

*/ inline const Aws::String& GetToDbClusterArn() const{ return m_toDbClusterArn; } /** *

The Amazon Resource Name (ARN) of the Aurora DB cluster that is currently * being promoted, and which is associated with this state.

*/ inline bool ToDbClusterArnHasBeenSet() const { return m_toDbClusterArnHasBeenSet; } /** *

The Amazon Resource Name (ARN) of the Aurora DB cluster that is currently * being promoted, and which is associated with this state.

*/ inline void SetToDbClusterArn(const Aws::String& value) { m_toDbClusterArnHasBeenSet = true; m_toDbClusterArn = value; } /** *

The Amazon Resource Name (ARN) of the Aurora DB cluster that is currently * being promoted, and which is associated with this state.

*/ inline void SetToDbClusterArn(Aws::String&& value) { m_toDbClusterArnHasBeenSet = true; m_toDbClusterArn = std::move(value); } /** *

The Amazon Resource Name (ARN) of the Aurora DB cluster that is currently * being promoted, and which is associated with this state.

*/ inline void SetToDbClusterArn(const char* value) { m_toDbClusterArnHasBeenSet = true; m_toDbClusterArn.assign(value); } /** *

The Amazon Resource Name (ARN) of the Aurora DB cluster that is currently * being promoted, and which is associated with this state.

*/ inline FailoverState& WithToDbClusterArn(const Aws::String& value) { SetToDbClusterArn(value); return *this;} /** *

The Amazon Resource Name (ARN) of the Aurora DB cluster that is currently * being promoted, and which is associated with this state.

*/ inline FailoverState& WithToDbClusterArn(Aws::String&& value) { SetToDbClusterArn(std::move(value)); return *this;} /** *

The Amazon Resource Name (ARN) of the Aurora DB cluster that is currently * being promoted, and which is associated with this state.

*/ inline FailoverState& WithToDbClusterArn(const char* value) { SetToDbClusterArn(value); return *this;} private: FailoverStatus m_status; bool m_statusHasBeenSet = false; Aws::String m_fromDbClusterArn; bool m_fromDbClusterArnHasBeenSet = false; Aws::String m_toDbClusterArn; bool m_toDbClusterArnHasBeenSet = false; }; } // namespace Model } // namespace RDS } // namespace Aws