createMonitor method
Creates an Amazon Web Services Deadline Cloud monitor that you can use to view your farms, queues, and fleets. After you submit a job, you can track the progress of the tasks and steps that make up the job, and then download the job's results.
May throw AccessDeniedException.
May throw InternalServerErrorException.
May throw ServiceQuotaExceededException.
May throw ThrottlingException.
May throw ValidationException.
Parameter displayName :
The name that you give the monitor that is displayed in the Deadline Cloud
console.
Parameter identityCenterInstanceArn :
The Amazon Resource Name of the IAM Identity Center instance that
authenticates monitor users.
Parameter roleArn :
The Amazon Resource Name of the IAM role that the monitor uses to connect
to Deadline Cloud. Every user that signs in to the monitor using IAM
Identity Center uses this role to access Deadline Cloud resources.
Parameter subdomain :
The subdomain to use when creating the monitor URL. The full URL of the
monitor is subdomain.Region.deadlinecloud.amazonaws.com.
Parameter clientToken :
The unique token which the server uses to recognize retries of the same
request.
Parameter identityCenterRegion :
The Region where IAM Identity Center is enabled. Required when IAM
Identity Center is in a different Region than the monitor.
Parameter tags :
The tags to add to your monitor. Each tag consists of a tag key and a tag
value. Tag keys and values are both required, but tag values can be empty
strings.
Implementation
Future<CreateMonitorResponse> createMonitor({
required String displayName,
required String identityCenterInstanceArn,
required String roleArn,
required String subdomain,
String? clientToken,
String? identityCenterRegion,
Map<String, String>? tags,
}) async {
final headers = <String, String>{
if (clientToken != null) 'X-Amz-Client-Token': clientToken.toString(),
};
final $payload = <String, dynamic>{
'displayName': displayName,
'identityCenterInstanceArn': identityCenterInstanceArn,
'roleArn': roleArn,
'subdomain': subdomain,
if (identityCenterRegion != null)
'identityCenterRegion': identityCenterRegion,
if (tags != null) 'tags': tags,
};
final response = await _protocol.send(
payload: $payload,
method: 'POST',
requestUri: '/2023-10-12/monitors',
headers: headers,
exceptionFnMap: _exceptionFns,
);
return CreateMonitorResponse.fromJson(response);
}