startSimulationJobBatch method
Future<StartSimulationJobBatchResponse>
startSimulationJobBatch({
- required List<
SimulationJobRequest> createSimulationJobRequests, - BatchPolicy? batchPolicy,
- String? clientRequestToken,
- Map<
String, String> ? tags,
Starts a new simulation job batch. The batch is defined using one or more
SimulationJobRequest
objects.
May throw InvalidParameterException. May throw LimitExceededException. May throw ThrottlingException. May throw IdempotentParameterMismatchException. May throw InternalServerException.
Parameter createSimulationJobRequests
:
A list of simulation job requests to create in the batch.
Parameter batchPolicy
:
The batch policy.
Parameter clientRequestToken
:
Unique, case-sensitive identifier that you provide to ensure the
idempotency of the request.
Parameter tags
:
A map that contains tag keys and tag values that are attached to the
deployment job batch.
Implementation
Future<StartSimulationJobBatchResponse> startSimulationJobBatch({
required List<SimulationJobRequest> createSimulationJobRequests,
BatchPolicy? batchPolicy,
String? clientRequestToken,
Map<String, String>? tags,
}) async {
ArgumentError.checkNotNull(
createSimulationJobRequests, 'createSimulationJobRequests');
_s.validateStringLength(
'clientRequestToken',
clientRequestToken,
1,
64,
);
final $payload = <String, dynamic>{
'createSimulationJobRequests': createSimulationJobRequests,
if (batchPolicy != null) 'batchPolicy': batchPolicy,
'clientRequestToken': clientRequestToken ?? _s.generateIdempotencyToken(),
if (tags != null) 'tags': tags,
};
final response = await _protocol.send(
payload: $payload,
method: 'POST',
requestUri: '/startSimulationJobBatch',
exceptionFnMap: _exceptionFns,
);
return StartSimulationJobBatchResponse.fromJson(response);
}