updateProfilingGroup method

Future<UpdateProfilingGroupResponse> updateProfilingGroup({
  1. required AgentOrchestrationConfig agentOrchestrationConfig,
  2. required String profilingGroupName,
})

Updates a profiling group.

May throw InternalServerException. May throw ConflictException. May throw ValidationException. May throw ThrottlingException. May throw ResourceNotFoundException.

Parameter agentOrchestrationConfig : Specifies whether profiling is enabled or disabled for a profiling group.

Parameter profilingGroupName : The name of the profiling group to update.

Implementation

Future<UpdateProfilingGroupResponse> updateProfilingGroup({
  required AgentOrchestrationConfig agentOrchestrationConfig,
  required String profilingGroupName,
}) async {
  ArgumentError.checkNotNull(
      agentOrchestrationConfig, 'agentOrchestrationConfig');
  ArgumentError.checkNotNull(profilingGroupName, 'profilingGroupName');
  _s.validateStringLength(
    'profilingGroupName',
    profilingGroupName,
    1,
    255,
    isRequired: true,
  );
  final $payload = <String, dynamic>{
    'agentOrchestrationConfig': agentOrchestrationConfig,
  };
  final response = await _protocol.sendRaw(
    payload: $payload,
    method: 'PUT',
    requestUri: '/profilingGroups/${Uri.encodeComponent(profilingGroupName)}',
    exceptionFnMap: _exceptionFns,
  );
  final $json = await _s.jsonFromResponse(response);
  return UpdateProfilingGroupResponse(
    profilingGroup: ProfilingGroupDescription.fromJson($json),
  );
}