describeTapeRecoveryPoints method

Future<DescribeTapeRecoveryPointsOutput> describeTapeRecoveryPoints({
  1. required String gatewayARN,
  2. int? limit,
  3. String? marker,
})

Returns a list of virtual tape recovery points that are available for the specified tape gateway.

A recovery point is a point-in-time view of a virtual tape at which all the data on the virtual tape is consistent. If your gateway crashes, virtual tapes that have recovery points can be recovered to a new gateway. This operation is only supported in the tape gateway type.

May throw InvalidGatewayRequestException. May throw InternalServerError.

Parameter limit : Specifies that the number of virtual tape recovery points that are described be limited to the specified number.

Parameter marker : An opaque string that indicates the position at which to begin describing the virtual tape recovery points.

Implementation

Future<DescribeTapeRecoveryPointsOutput> describeTapeRecoveryPoints({
  required String gatewayARN,
  int? limit,
  String? marker,
}) async {
  ArgumentError.checkNotNull(gatewayARN, 'gatewayARN');
  _s.validateStringLength(
    'gatewayARN',
    gatewayARN,
    50,
    500,
    isRequired: true,
  );
  _s.validateNumRange(
    'limit',
    limit,
    1,
    1152921504606846976,
  );
  _s.validateStringLength(
    'marker',
    marker,
    1,
    1000,
  );
  final headers = <String, String>{
    'Content-Type': 'application/x-amz-json-1.1',
    'X-Amz-Target': 'StorageGateway_20130630.DescribeTapeRecoveryPoints'
  };
  final jsonResponse = await _protocol.send(
    method: 'POST',
    requestUri: '/',
    exceptionFnMap: _exceptionFns,
    // TODO queryParams
    headers: headers,
    payload: {
      'GatewayARN': gatewayARN,
      if (limit != null) 'Limit': limit,
      if (marker != null) 'Marker': marker,
    },
  );

  return DescribeTapeRecoveryPointsOutput.fromJson(jsonResponse.body);
}