rebootDBInstance method
You might need to reboot your DB instance, usually for maintenance reasons. For example, if you make certain modifications, or if you change the DB parameter group associated with the DB instance, you must reboot the instance for the changes to take effect.
Rebooting a DB instance restarts the database engine service. Rebooting a DB instance results in a momentary outage, during which the DB instance status is set to rebooting.
For more information about rebooting, see Rebooting a DB Instance in the Amazon RDS User Guide.
This command doesn't apply to RDS Custom.
If your DB instance is part of a Multi-AZ DB cluster, you can reboot the
DB cluster with the RebootDBCluster operation.
May throw DBInstanceNotFoundFault.
May throw InvalidDBInstanceStateFault.
May throw KMSKeyNotAccessibleFault.
Parameter dBInstanceIdentifier :
The DB instance identifier. This parameter is stored as a lowercase
string.
Constraints:
- Must match the identifier of an existing DBInstance.
Parameter forceFailover :
Specifies whether the reboot is conducted through a Multi-AZ failover.
Constraint: You can't enable force failover if the instance isn't configured for Multi-AZ.
Implementation
Future<RebootDBInstanceResult> rebootDBInstance({
required String dBInstanceIdentifier,
bool? forceFailover,
}) async {
final $request = <String, String>{
'DBInstanceIdentifier': dBInstanceIdentifier,
if (forceFailover != null) 'ForceFailover': forceFailover.toString(),
};
final $result = await _protocol.send(
$request,
action: 'RebootDBInstance',
version: '2014-10-31',
method: 'POST',
requestUri: '/',
exceptionFnMap: _exceptionFns,
resultWrapper: 'RebootDBInstanceResult',
);
return RebootDBInstanceResult.fromXml($result);
}