Retrieves the replication configuration for a specific file system. If a file system is not specified, all of the replication configurations for the Amazon Web Services account in an Amazon Web Services Region are retrieved.
Parameters:
-
file_system_id
(Optional[FileSystemId], default:
None
)
–
You can retrieve the replication configuration for a specific file system by providing its file system ID. For cross-account,cross-region replication, an account can only describe the replication configuration for a file system in its own Region.
-
next_token
(Optional[Token], default:
None
)
–
NextToken is present if the response is paginated. You can use NextToken in a subsequent request to fetch the next page of output.
-
max_results
(Optional[MaxResults], default:
None
)
–
(Optional) To limit the number of objects returned in a response, you can specify the MaxItems parameter. The default value is 100.
Raises:
-
BadRequest
–
Returned if the request is malformed or contains an error such as an invalid parameter value or a missing required parameter.
-
FileSystemNotFound
–
Returned if the specified FileSystemId value doesn't exist in the requester's Amazon Web Services account.
-
InternalServerError
–
Returned if an error occurred on the server side.
-
ReplicationNotFound
–
Returned if the specified file system does not have a replication configuration.
-
ValidationException
–
Returned if the Backup service is not available in the Amazon Web Services Region in which the request was made.
-
UnknownServiceError
–
The service returned an error code this client does not model.
Source code in docs_src/capo_efs/_services/async_efs.py
| async def describe_replication_configurations(
self,
*,
config_overrides: Optional[AsyncEFSClientConfig] = None,
file_system_id: Optional["capo_efs.types.file_system_id.FileSystemId"] = None,
next_token: Optional["capo_efs.types.token.Token"] = None,
max_results: Optional["capo_efs.types.max_results.MaxResults"] = None,
) -> "capo_efs.types.describe_replication_configurations_response.DescribeReplicationConfigurationsResponse":
"""<p>Retrieves the replication configuration for a specific file system. If a file system is not specified, all of the replication configurations for the Amazon Web Services account in an Amazon Web Services Region are retrieved.</p>
Args:
file_system_id: <p>You can retrieve the replication configuration for a specific file system by providing its file system ID. For cross-account,cross-region replication, an account can only describe the replication configuration for a file system in its own Region.</p>
next_token: <p> <code>NextToken</code> is present if the response is paginated. You can use <code>NextToken</code> in a subsequent request to fetch the next page of output.</p>
max_results: <p>(Optional) To limit the number of objects returned in a response, you can specify the <code>MaxItems</code> parameter. The default value is 100. </p>
Raises:
capo_efs.errors.bad_request.BadRequest: <p>Returned if the request is malformed or contains an error such as an invalid parameter value or a missing required parameter.</p>
capo_efs.errors.file_system_not_found.FileSystemNotFound: <p>Returned if the specified <code>FileSystemId</code> value doesn't exist in the requester's Amazon Web Services account.</p>
capo_efs.errors.internal_server_error.InternalServerError: <p>Returned if an error occurred on the server side.</p>
capo_efs.errors.replication_not_found.ReplicationNotFound: <p>Returned if the specified file system does not have a replication configuration.</p>
capo_efs.errors.validation_exception.ValidationException: <p>Returned if the Backup service is not available in the Amazon Web Services Region in which the request was made.</p>
capo_efs.errors.UnknownServiceError: The service returned an error code this client does not model.
"""
async def _handler(
req: "AsyncOperationRequest[capo_efs.types.describe_replication_configurations_request.DescribeReplicationConfigurationsRequest]",
) -> AsyncOperationResponse[
"capo_efs.types.describe_replication_configurations_response.DescribeReplicationConfigurationsResponse"
]:
import capo_efs._operations.magnolio_api_service_v20150201.describe_replication_configurations
(
output,
http_response,
) = await capo_efs._operations.magnolio_api_service_v20150201.describe_replication_configurations.async_describe_replication_configurations(
req.options, req.input
)
return AsyncOperationResponse(output=output, response=http_response)
interceptors_, options_ = self.operation_options(
config_overrides, OperationLogging("DescribeReplicationConfigurations")
)
input_: capo_efs.types.describe_replication_configurations_request.DescribeReplicationConfigurationsRequest = {}
if file_system_id is not None:
input_["file_system_id"] = file_system_id
if next_token is not None:
input_["next_token"] = next_token
if max_results is not None:
input_["max_results"] = max_results
response = await aexecute_pipeline(
AsyncOperationRequest(input=input_, options=options_),
handler=_handler,
interceptors=list(interceptors_),
)
await response.response.aclose()
return response.output
|