createDBClusterParameterGroup method

Future<CreateDBClusterParameterGroupResult> createDBClusterParameterGroup({
  1. required String dBClusterParameterGroupName,
  2. required String dBParameterGroupFamily,
  3. required String description,
  4. List<Tag>? tags,
})

Creates a new cluster parameter group.

Parameters in a cluster parameter group apply to all of the instances in a cluster.

A cluster parameter group is initially created with the default parameters for the database engine used by instances in the cluster. In Amazon DocumentDB, you cannot make modifications directly to the default.docdb3.6 cluster parameter group. If your Amazon DocumentDB cluster is using the default cluster parameter group and you want to modify a value in it, you must first create a new parameter group or copy an existing parameter group, modify it, and then apply the modified parameter group to your cluster. For the new cluster parameter group and associated settings to take effect, you must then reboot the instances in the cluster without failover. For more information, see Modifying Amazon DocumentDB Cluster Parameter Groups.

May throw DBParameterGroupQuotaExceededFault. May throw DBParameterGroupAlreadyExistsFault.

Parameter dBClusterParameterGroupName : The name of the cluster parameter group.

Constraints:

  • Must not match the name of an existing DBClusterParameterGroup.

Parameter dBParameterGroupFamily : The cluster parameter group family name.

Parameter description : The description for the cluster parameter group.

Parameter tags : The tags to be assigned to the cluster parameter group.

Implementation

Future<CreateDBClusterParameterGroupResult> createDBClusterParameterGroup({
  required String dBClusterParameterGroupName,
  required String dBParameterGroupFamily,
  required String description,
  List<Tag>? tags,
}) async {
  ArgumentError.checkNotNull(
      dBClusterParameterGroupName, 'dBClusterParameterGroupName');
  ArgumentError.checkNotNull(
      dBParameterGroupFamily, 'dBParameterGroupFamily');
  ArgumentError.checkNotNull(description, 'description');
  final $request = <String, dynamic>{};
  $request['DBClusterParameterGroupName'] = dBClusterParameterGroupName;
  $request['DBParameterGroupFamily'] = dBParameterGroupFamily;
  $request['Description'] = description;
  tags?.also((arg) => $request['Tags'] = arg);
  final $result = await _protocol.send(
    $request,
    action: 'CreateDBClusterParameterGroup',
    version: '2014-10-31',
    method: 'POST',
    requestUri: '/',
    exceptionFnMap: _exceptionFns,
    shape: shapes['CreateDBClusterParameterGroupMessage'],
    shapes: shapes,
    resultWrapper: 'CreateDBClusterParameterGroupResult',
  );
  return CreateDBClusterParameterGroupResult.fromXml($result);
}