Skip to content

update_data_repository_association

update_data_repository_association(
    *,
    config_overrides: Optional[FSxClientConfig] = None,
    association_id: Optional[DataRepositoryAssociationId] = None,
    client_request_token: Optional[ClientRequestToken] = None,
    imported_file_chunk_size: Optional[Megabytes] = None,
    s3: Optional[S3DataRepositoryConfiguration] = None,
) -> UpdateDataRepositoryAssociationResponse

Updates the configuration of an existing data repository association on an Amazon FSx for Lustre file system. Data repository associations are supported on all FSx for Lustre 2.12 and 2.15 file systems, excluding scratch_1 deployment type.

Parameters:

  • association_id (Optional[DataRepositoryAssociationId], default: None ) –

    The ID of the data repository association that you are updating.

  • imported_file_chunk_size (Optional[Megabytes], default: None ) –

    For files imported from a data repository, this value determines the stripe count and maximum amount of data per file (in MiB) stored on a single physical disk. The maximum number of disks that a single file can be striped across is limited by the total number of disks that make up the file system.

    The default chunk size is 1,024 MiB (1 GiB) and can go as high as 512,000 MiB (500 GiB). Amazon S3 objects have a maximum size of 5 TB.

  • s3 (Optional[S3DataRepositoryConfiguration], default: None ) –

    The configuration for an Amazon S3 data repository linked to an Amazon FSx Lustre file system with a data repository association. The configuration defines which file events (new, changed, or deleted files or directories) are automatically imported from the linked data repository to the file system or automatically exported from the file system to the data repository.

Raises:

  • BadRequest –

    A generic error indicating a failure with a client request.

  • DataRepositoryAssociationNotFound –

    No data repository associations were found based upon the supplied parameters.

  • IncompatibleParameterError –

    The error returned when a second request is received with the same client request token but different parameters settings. A client request token should always uniquely identify a single request.

  • InternalServerError –

    A generic error indicating a server-side failure.

  • ServiceLimitExceeded –

    An error indicating that a particular service limit was exceeded. You can increase some service limits by contacting Amazon Web Services Support.

  • UnknownServiceError –

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

Source code in docs_src/capo_fsx/_services/f_sx.py
def update_data_repository_association(
    self,
    *,
    config_overrides: Optional[FSxClientConfig] = None,
    association_id: Optional[
        "capo_fsx.types.data_repository_association_id.DataRepositoryAssociationId"
    ] = None,
    client_request_token: Optional[
        "capo_fsx.types.client_request_token.ClientRequestToken"
    ] = None,
    imported_file_chunk_size: Optional["capo_fsx.types.megabytes.Megabytes"] = None,
    s3: Optional[
        "capo_fsx.types.s3_data_repository_configuration.S3DataRepositoryConfiguration"
    ] = None,
) -> "capo_fsx.types.update_data_repository_association_response.UpdateDataRepositoryAssociationResponse":
    """<p>Updates the configuration of an existing data repository association on an Amazon FSx for Lustre file system. Data repository associations are supported on all FSx for Lustre 2.12 and 2.15 file systems, excluding <code>scratch_1</code> deployment type.</p>

    Args:
        association_id: <p>The ID of the data repository association that you are updating.</p>
        imported_file_chunk_size: <p>For files imported from a data repository, this value determines the stripe count and maximum amount of data per file (in MiB) stored on a single physical disk. The maximum number of disks that a single file can be striped across is limited by the total number of disks that make up the file system.</p> <p>The default chunk size is 1,024 MiB (1 GiB) and can go as high as 512,000 MiB (500 GiB). Amazon S3 objects have a maximum size of 5 TB.</p>
        s3: <p>The configuration for an Amazon S3 data repository linked to an Amazon FSx Lustre file system with a data repository association. The configuration defines which file events (new, changed, or deleted files or directories) are automatically imported from the linked data repository to the file system or automatically exported from the file system to the data repository.</p>

    Raises:
        capo_fsx.errors.bad_request.BadRequest: <p>A generic error indicating a failure with a client request.</p>
        capo_fsx.errors.data_repository_association_not_found.DataRepositoryAssociationNotFound: <p>No data repository associations were found based upon the supplied parameters.</p>
        capo_fsx.errors.incompatible_parameter_error.IncompatibleParameterError: <p>The error returned when a second request is received with the same client request token but different parameters settings. A client request token should always uniquely identify a single request.</p>
        capo_fsx.errors.internal_server_error.InternalServerError: <p>A generic error indicating a server-side failure.</p>
        capo_fsx.errors.service_limit_exceeded.ServiceLimitExceeded: <p>An error indicating that a particular service limit was exceeded. You can increase some service limits by contacting Amazon Web Services Support.</p>
        capo_fsx.errors.UnknownServiceError: The service returned an error code this client does not model.
    """

    def _handler(
        req: "OperationRequest[capo_fsx.types.update_data_repository_association_request.UpdateDataRepositoryAssociationRequest]",
    ) -> OperationResponse[
        "capo_fsx.types.update_data_repository_association_response.UpdateDataRepositoryAssociationResponse"
    ]:
        import capo_fsx._operations.aws_simba_api_service_v20180301.update_data_repository_association

        output, http_response = (
            capo_fsx._operations.aws_simba_api_service_v20180301.update_data_repository_association.update_data_repository_association(
                req.options, req.input
            )
        )
        return OperationResponse(output=output, response=http_response)

    interceptors_, options_ = self.operation_options(
        config_overrides, OperationLogging("UpdateDataRepositoryAssociation")
    )
    input_: capo_fsx.types.update_data_repository_association_request.UpdateDataRepositoryAssociationRequest = {}
    if association_id is not None:
        input_["association_id"] = association_id
    if client_request_token is None:
        client_request_token = str(uuid.uuid4())
    input_["client_request_token"] = client_request_token
    if imported_file_chunk_size is not None:
        input_["imported_file_chunk_size"] = imported_file_chunk_size
    if s3 is not None:
        input_["s3"] = s3

    response = execute_pipeline(
        OperationRequest(input=input_, options=options_),
        handler=_handler,
        interceptors=list(interceptors_),
    )
    response.response.close()
    return response.output