Skip to content

reset_db_parameter_group async

reset_db_parameter_group(
    *,
    config_overrides: Optional[AsyncNeptuneClientConfig] = None,
    db_parameter_group_name: Optional[String] = None,
    reset_all_parameters: Optional[Boolean] = None,
    parameters: Optional[ParametersList] = None,
) -> DBParameterGroupNameMessage

Modifies the parameters of a DB parameter group to the engine/system default value. To reset specific parameters, provide a list of the following: ParameterName and ApplyMethod. To reset the entire DB parameter group, specify the DBParameterGroup name and ResetAllParameters parameters. When resetting the entire group, dynamic parameters are updated immediately and static parameters are set to pending-reboot to take effect on the next DB instance restart or RebootDBInstance request.

Parameters:

  • db_parameter_group_name (Optional[String], default: None ) –

    The name of the DB parameter group.

    Constraints:

    • Must match the name of an existing DBParameterGroup.

  • reset_all_parameters (Optional[Boolean], default: None ) –

    Specifies whether (true) or not (false) to reset all parameters in the DB parameter group to default values.

    Default: true

  • parameters (Optional[ParametersList], default: None ) –

    To reset the entire DB parameter group, specify the DBParameterGroup name and ResetAllParameters parameters. To reset specific parameters, provide a list of the following: ParameterName and ApplyMethod. A maximum of 20 parameters can be modified in a single request.

    Valid Values (for Apply method): pending-reboot

Raises:

  • DBParameterGroupNotFoundFault –

    DBParameterGroupName does not refer to an existing DB parameter group.

  • InvalidDBParameterGroupStateFault –

    The DB parameter group is in use or is in an invalid state. If you are attempting to delete the parameter group, you cannot delete it when the parameter group is in this state.

  • UnknownServiceError –

    The service returned an error code this client does not model.

Source code in docs_src/capo_neptune/_services/async_neptune.py
async def reset_db_parameter_group(
    self,
    *,
    config_overrides: Optional[AsyncNeptuneClientConfig] = None,
    db_parameter_group_name: Optional["capo_neptune.types.string.String"] = None,
    reset_all_parameters: Optional["capo_neptune.types.boolean.Boolean"] = None,
    parameters: Optional[
        "capo_neptune.types.parameters_list.ParametersList"
    ] = None,
) -> (
    "capo_neptune.types.db_parameter_group_name_message.DBParameterGroupNameMessage"
):
    """<p>Modifies the parameters of a DB parameter group to the engine/system default value. To reset specific parameters, provide a list of the following: <code>ParameterName</code> and <code>ApplyMethod</code>. To reset the entire DB parameter group, specify the <code>DBParameterGroup</code> name and <code>ResetAllParameters</code> parameters. When resetting the entire group, dynamic parameters are updated immediately and static parameters are set to <code>pending-reboot</code> to take effect on the next DB instance restart or <code>RebootDBInstance</code> request.</p>

    Args:
        db_parameter_group_name: <p>The name of the DB parameter group.</p> <p>Constraints:</p> <ul> <li> <p>Must match the name of an existing DBParameterGroup.</p> </li> </ul>
        reset_all_parameters: <p>Specifies whether (<code>true</code>) or not (<code>false</code>) to reset all parameters in the DB parameter group to default values.</p> <p>Default: <code>true</code> </p>
        parameters: <p>To reset the entire DB parameter group, specify the <code>DBParameterGroup</code> name and <code>ResetAllParameters</code> parameters. To reset specific parameters, provide a list of the following: <code>ParameterName</code> and <code>ApplyMethod</code>. A maximum of 20 parameters can be modified in a single request.</p> <p>Valid Values (for Apply method): <code>pending-reboot</code> </p>

    Raises:
        capo_neptune.errors.db_parameter_group_not_found_fault.DBParameterGroupNotFoundFault: <p> <i>DBParameterGroupName</i> does not refer to an existing DB parameter group.</p>
        capo_neptune.errors.invalid_db_parameter_group_state_fault.InvalidDBParameterGroupStateFault: <p>The DB parameter group is in use or is in an invalid state. If you are attempting to delete the parameter group, you cannot delete it when the parameter group is in this state.</p>
        capo_neptune.errors.UnknownServiceError: The service returned an error code this client does not model.
    """

    async def _handler(
        req: "AsyncOperationRequest[capo_neptune.types.reset_db_parameter_group_message.ResetDBParameterGroupMessage]",
    ) -> AsyncOperationResponse[
        "capo_neptune.types.db_parameter_group_name_message.DBParameterGroupNameMessage"
    ]:
        import capo_neptune._operations.amazon_rd_sv19.reset_db_parameter_group

        (
            output,
            http_response,
        ) = await capo_neptune._operations.amazon_rd_sv19.reset_db_parameter_group.async_reset_db_parameter_group(
            req.options, req.input
        )
        return AsyncOperationResponse(output=output, response=http_response)

    interceptors_, options_ = self.operation_options(
        config_overrides, OperationLogging("ResetDBParameterGroup")
    )
    input_: capo_neptune.types.reset_db_parameter_group_message.ResetDBParameterGroupMessage = {}
    if db_parameter_group_name is not None:
        input_["db_parameter_group_name"] = db_parameter_group_name
    if reset_all_parameters is not None:
        input_["reset_all_parameters"] = reset_all_parameters
    if parameters is not None:
        input_["parameters"] = parameters

    response = await aexecute_pipeline(
        AsyncOperationRequest(input=input_, options=options_),
        handler=_handler,
        interceptors=list(interceptors_),
    )
    await response.response.aclose()
    return response.output