modifyDBClusterEndpoint method

Future<DBClusterEndpoint> modifyDBClusterEndpoint({
  1. required String dBClusterEndpointIdentifier,
  2. String? endpointType,
  3. List<String>? excludedMembers,
  4. List<String>? staticMembers,
})

Modifies the properties of an endpoint in an Amazon Aurora DB cluster.

May throw InvalidDBClusterStateFault. May throw InvalidDBClusterEndpointStateFault. May throw DBClusterEndpointNotFoundFault. May throw DBInstanceNotFoundFault. May throw InvalidDBInstanceStateFault.

Parameter dBClusterEndpointIdentifier : The identifier of the endpoint to modify. This parameter is stored as a lowercase string.

Parameter endpointType : The type of the endpoint. One of: READER, WRITER, ANY.

Parameter excludedMembers : List of DB instance identifiers that aren't part of the custom endpoint group. All other eligible instances are reachable through the custom endpoint. Only relevant if the list of static members is empty.

Parameter staticMembers : List of DB instance identifiers that are part of the custom endpoint group.

Implementation

Future<DBClusterEndpoint> modifyDBClusterEndpoint({
  required String dBClusterEndpointIdentifier,
  String? endpointType,
  List<String>? excludedMembers,
  List<String>? staticMembers,
}) async {
  ArgumentError.checkNotNull(
      dBClusterEndpointIdentifier, 'dBClusterEndpointIdentifier');
  final $request = <String, dynamic>{};
  $request['DBClusterEndpointIdentifier'] = dBClusterEndpointIdentifier;
  endpointType?.also((arg) => $request['EndpointType'] = arg);
  excludedMembers?.also((arg) => $request['ExcludedMembers'] = arg);
  staticMembers?.also((arg) => $request['StaticMembers'] = arg);
  final $result = await _protocol.send(
    $request,
    action: 'ModifyDBClusterEndpoint',
    version: '2014-10-31',
    method: 'POST',
    requestUri: '/',
    exceptionFnMap: _exceptionFns,
    shape: shapes['ModifyDBClusterEndpointMessage'],
    shapes: shapes,
    resultWrapper: 'ModifyDBClusterEndpointResult',
  );
  return DBClusterEndpoint.fromXml($result);
}