Skip to content

update_pipeline async

update_pipeline(
    pipeline_name: PipelineName,
    *,
    config_overrides: Optional[AsyncOSISClientConfig] = None,
    min_units: Optional[PipelineUnits] = None,
    max_units: Optional[PipelineUnits] = None,
    pipeline_configuration_body: Optional[PipelineConfigurationBody] = None,
    log_publishing_options: Optional[LogPublishingOptions] = None,
    buffer_options: Optional[BufferOptions] = None,
    encryption_at_rest_options: Optional[EncryptionAtRestOptions] = None,
    pipeline_role_arn: Optional[PipelineRoleArn] = None,
) -> UpdatePipelineResponse

Updates an OpenSearch Ingestion pipeline. For more information, see Updating Amazon OpenSearch Ingestion pipelines.

Parameters:

  • pipeline_name (PipelineName) –

    The name of the pipeline to update.

  • min_units (Optional[PipelineUnits], default: None ) –

    The minimum pipeline capacity, in Ingestion Compute Units (ICUs).

  • max_units (Optional[PipelineUnits], default: None ) –

    The maximum pipeline capacity, in Ingestion Compute Units (ICUs)

  • pipeline_configuration_body (Optional[PipelineConfigurationBody], default: None ) –

    The pipeline configuration in YAML format. The command accepts the pipeline configuration as a string or within a .yaml file. If you provide the configuration as a string, each new line must be escaped with \n.

  • log_publishing_options (Optional[LogPublishingOptions], default: None ) –

    Key-value pairs to configure log publishing.

  • buffer_options (Optional[BufferOptions], default: None ) –

    Key-value pairs to configure persistent buffering for the pipeline.

  • encryption_at_rest_options (Optional[EncryptionAtRestOptions], default: None ) –

    Key-value pairs to configure encryption for data that is written to a persistent buffer.

  • pipeline_role_arn (Optional[PipelineRoleArn], default: None ) –

    The Amazon Resource Name (ARN) of the IAM role that grants the pipeline permission to access Amazon Web Services resources.

Raises:

Source code in docs_src/capo_osis/_services/async_osis.py
async def update_pipeline(
    self,
    pipeline_name: "capo_osis.types.pipeline_name.PipelineName",
    *,
    config_overrides: Optional[AsyncOSISClientConfig] = None,
    min_units: Optional["capo_osis.types.pipeline_units.PipelineUnits"] = None,
    max_units: Optional["capo_osis.types.pipeline_units.PipelineUnits"] = None,
    pipeline_configuration_body: Optional[
        "capo_osis.types.pipeline_configuration_body.PipelineConfigurationBody"
    ] = None,
    log_publishing_options: Optional[
        "capo_osis.types.log_publishing_options.LogPublishingOptions"
    ] = None,
    buffer_options: Optional["capo_osis.types.buffer_options.BufferOptions"] = None,
    encryption_at_rest_options: Optional[
        "capo_osis.types.encryption_at_rest_options.EncryptionAtRestOptions"
    ] = None,
    pipeline_role_arn: Optional[
        "capo_osis.types.pipeline_role_arn.PipelineRoleArn"
    ] = None,
) -> "capo_osis.types.update_pipeline_response.UpdatePipelineResponse":
    r"""<p>Updates an OpenSearch Ingestion pipeline. For more information, see <a href="https://docs.aws.amazon.com/opensearch-service/latest/developerguide/update-pipeline.html">Updating Amazon OpenSearch Ingestion pipelines</a>.</p>

    Args:
        pipeline_name: <p>The name of the pipeline to update.</p>
        min_units: <p>The minimum pipeline capacity, in Ingestion Compute Units (ICUs).</p>
        max_units: <p>The maximum pipeline capacity, in Ingestion Compute Units (ICUs)</p>
        pipeline_configuration_body: <p>The pipeline configuration in YAML format. The command accepts the pipeline configuration as a string or within a .yaml file. If you provide the configuration as a string, each new line must be escaped with <code>\n</code>.</p>
        log_publishing_options: <p>Key-value pairs to configure log publishing.</p>
        buffer_options: <p>Key-value pairs to configure persistent buffering for the pipeline.</p>
        encryption_at_rest_options: <p>Key-value pairs to configure encryption for data that is written to a persistent buffer.</p>
        pipeline_role_arn: <p>The Amazon Resource Name (ARN) of the IAM role that grants the pipeline permission to access Amazon Web Services resources.</p>

    Raises:
        capo_osis.errors.access_denied_exception.AccessDeniedException: <p>You don't have permissions to access the resource.</p>
        capo_osis.errors.conflict_exception.ConflictException: <p>The client attempted to remove a resource that is currently in use.</p>
        capo_osis.errors.disabled_operation_exception.DisabledOperationException: <p>Exception is thrown when an operation has been disabled.</p>
        capo_osis.errors.internal_exception.InternalException: <p>The request failed because of an unknown error, exception, or failure (the failure is internal to the service).</p>
        capo_osis.errors.resource_not_found_exception.ResourceNotFoundException: <p>You attempted to access or delete a resource that does not exist.</p>
        capo_osis.errors.validation_exception.ValidationException: <p>An exception for missing or invalid input fields.</p>
        capo_osis.errors.UnknownServiceError: The service returned an error code this client does not model.
    """

    async def _handler(
        req: "AsyncOperationRequest[capo_osis.types.update_pipeline_request.UpdatePipelineRequest]",
    ) -> AsyncOperationResponse[
        "capo_osis.types.update_pipeline_response.UpdatePipelineResponse"
    ]:
        import capo_osis._operations.amazon_open_search_ingestion_service.update_pipeline

        (
            output,
            http_response,
        ) = await capo_osis._operations.amazon_open_search_ingestion_service.update_pipeline.async_update_pipeline(
            req.options, req.input
        )
        return AsyncOperationResponse(output=output, response=http_response)

    interceptors_, options_ = self.operation_options(
        config_overrides, OperationLogging("UpdatePipeline")
    )
    input_: capo_osis.types.update_pipeline_request.UpdatePipelineRequest = {
        "pipeline_name": pipeline_name
    }
    if min_units is not None:
        input_["min_units"] = min_units
    if max_units is not None:
        input_["max_units"] = max_units
    if pipeline_configuration_body is not None:
        input_["pipeline_configuration_body"] = pipeline_configuration_body
    if log_publishing_options is not None:
        input_["log_publishing_options"] = log_publishing_options
    if buffer_options is not None:
        input_["buffer_options"] = buffer_options
    if encryption_at_rest_options is not None:
        input_["encryption_at_rest_options"] = encryption_at_rest_options
    if pipeline_role_arn is not None:
        input_["pipeline_role_arn"] = pipeline_role_arn

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