stopAIBenchmarkJob method

Future<StopAIBenchmarkJobResponse> stopAIBenchmarkJob({
  1. required String aIBenchmarkJobName,
})

Stops a running AI benchmark job.

May throw ResourceNotFound.

Parameter aIBenchmarkJobName : The name of the AI benchmark job to stop.

Implementation

Future<StopAIBenchmarkJobResponse> stopAIBenchmarkJob({
  required String aIBenchmarkJobName,
}) async {
  final headers = <String, String>{
    'Content-Type': 'application/x-amz-json-1.1',
    'X-Amz-Target': 'SageMaker.StopAIBenchmarkJob'
  };
  final jsonResponse = await _protocol.send(
    method: 'POST',
    requestUri: '/',
    exceptionFnMap: _exceptionFns,
    // TODO queryParams
    headers: headers,
    payload: {
      'AIBenchmarkJobName': aIBenchmarkJobName,
    },
  );

  return StopAIBenchmarkJobResponse.fromJson(jsonResponse.body);
}