Skip to content

update_location_fsx_open_zfs async

update_location_fsx_open_zfs(
    location_arn: LocationArn,
    *,
    config_overrides: Optional[AsyncDataSyncClientConfig] = None,
    protocol: Optional[FsxProtocol] = None,
    subdirectory: Optional[SmbSubdirectory] = None,
) -> UpdateLocationFsxOpenZfsResponse

Modifies the following configuration parameters of the Amazon FSx for OpenZFS transfer location that you're using with DataSync.

For more information, see Configuring DataSync transfers with FSx for OpenZFS.

Request parameters related to SMB aren't supported with the UpdateLocationFsxOpenZfs operation.

Parameters:

  • location_arn (LocationArn) –

    Specifies the Amazon Resource Name (ARN) of the FSx for OpenZFS transfer location that you're updating.

  • subdirectory (Optional[SmbSubdirectory], default: None ) –

    Specifies a subdirectory in the location's path that must begin with /fsx. DataSync uses this subdirectory to read or write data (depending on whether the file system is a source or destination location).

Raises:

Source code in docs_src/capo_datasync/_services/async_data_sync.py
async def update_location_fsx_open_zfs(
    self,
    location_arn: "capo_datasync.types.location_arn.LocationArn",
    *,
    config_overrides: Optional[AsyncDataSyncClientConfig] = None,
    protocol: Optional["capo_datasync.types.fsx_protocol.FsxProtocol"] = None,
    subdirectory: Optional[
        "capo_datasync.types.smb_subdirectory.SmbSubdirectory"
    ] = None,
) -> "capo_datasync.types.update_location_fsx_open_zfs_response.UpdateLocationFsxOpenZfsResponse":
    """<p>Modifies the following configuration parameters of the Amazon FSx for OpenZFS transfer location that you're using with DataSync.</p> <p>For more information, see <a href="https://docs.aws.amazon.com/datasync/latest/userguide/create-openzfs-location.html">Configuring DataSync transfers with FSx for OpenZFS</a>.</p> <note> <p>Request parameters related to <code>SMB</code> aren't supported with the <code>UpdateLocationFsxOpenZfs</code> operation.</p> </note>

    Args:
        location_arn: <p>Specifies the Amazon Resource Name (ARN) of the FSx for OpenZFS transfer location that you're updating.</p>
        subdirectory: <p>Specifies a subdirectory in the location's path that must begin with <code>/fsx</code>. DataSync uses this subdirectory to read or write data (depending on whether the file system is a source or destination location).</p>

    Raises:
        capo_datasync.errors.internal_exception.InternalException: <p>This exception is thrown when an error occurs in the DataSync service.</p>
        capo_datasync.errors.invalid_request_exception.InvalidRequestException: <p>This exception is thrown when the client submits a malformed request.</p>
        capo_datasync.errors.UnknownServiceError: The service returned an error code this client does not model.
    """

    async def _handler(
        req: "AsyncOperationRequest[capo_datasync.types.update_location_fsx_open_zfs_request.UpdateLocationFsxOpenZfsRequest]",
    ) -> AsyncOperationResponse[
        "capo_datasync.types.update_location_fsx_open_zfs_response.UpdateLocationFsxOpenZfsResponse"
    ]:
        import capo_datasync._operations.fmrs_service.update_location_fsx_open_zfs

        (
            output,
            http_response,
        ) = await capo_datasync._operations.fmrs_service.update_location_fsx_open_zfs.async_update_location_fsx_open_zfs(
            req.options, req.input
        )
        return AsyncOperationResponse(output=output, response=http_response)

    def _redact_input(
        input_: "capo_datasync.types.update_location_fsx_open_zfs_request.UpdateLocationFsxOpenZfsRequest",
    ) -> dict[str, Any]:
        import capo_datasync.types.update_location_fsx_open_zfs_request

        return capo_datasync.types.update_location_fsx_open_zfs_request.redact_sensitive(
            input_
        )

    interceptors_, options_ = self.operation_options(
        config_overrides,
        OperationLogging("UpdateLocationFsxOpenZfs", redact_input=_redact_input),
    )
    input_: capo_datasync.types.update_location_fsx_open_zfs_request.UpdateLocationFsxOpenZfsRequest = {
        "location_arn": location_arn
    }
    if protocol is not None:
        input_["protocol"] = protocol
    if subdirectory is not None:
        input_["subdirectory"] = subdirectory

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