updateFlow method

Future<UpdateFlowResponse> updateFlow({
  1. required String flowArn,
  2. EncodingConfig? encodingConfig,
  3. FlowSize? flowSize,
  4. UpdateMaintenance? maintenance,
  5. NdiConfig? ndiConfig,
  6. UpdateFailoverConfig? sourceFailoverConfig,
  7. MonitoringConfig? sourceMonitoringConfig,
})

Updates an existing flow.

  • If you have a MEDIUM flow and you want to change the flow source to NDIĀ®:
    • First, use the UpdateFlow operation to upgrade the flow size to LARGE.
    • After that, you can then use the UpdateFlowSource operation to configure the NDI source.
  • If you're switching from an NDI source to a transport stream (TS) source and want to downgrade the flow size:
    • First, use the UpdateFlowSource operation to change the flow source type.
    • After that, you can then use the UpdateFlow operation to downgrade the flow size to MEDIUM.

May throw BadRequestException. May throw ForbiddenException. May throw InternalServerErrorException. May throw NotFoundException. May throw ServiceUnavailableException. May throw TooManyRequestsException.

Parameter flowArn : The Amazon Resource Name (ARN) of the flow that you want to update.

Parameter flowSize : Determines the processing capacity and feature set of the flow.

Parameter maintenance : The maintenance setting of the flow.

Parameter ndiConfig : Specifies the configuration settings for a flow's NDI source or output. Required when the flow includes an NDI source or output.

Parameter sourceFailoverConfig : The settings for source failover.

Parameter sourceMonitoringConfig : The settings for source monitoring.

Implementation

Future<UpdateFlowResponse> updateFlow({
  required String flowArn,
  EncodingConfig? encodingConfig,
  FlowSize? flowSize,
  UpdateMaintenance? maintenance,
  NdiConfig? ndiConfig,
  UpdateFailoverConfig? sourceFailoverConfig,
  MonitoringConfig? sourceMonitoringConfig,
}) async {
  final $payload = <String, dynamic>{
    if (encodingConfig != null) 'encodingConfig': encodingConfig,
    if (flowSize != null) 'flowSize': flowSize.value,
    if (maintenance != null) 'maintenance': maintenance,
    if (ndiConfig != null) 'ndiConfig': ndiConfig,
    if (sourceFailoverConfig != null)
      'sourceFailoverConfig': sourceFailoverConfig,
    if (sourceMonitoringConfig != null)
      'sourceMonitoringConfig': sourceMonitoringConfig,
  };
  final response = await _protocol.send(
    payload: $payload,
    method: 'PUT',
    requestUri: '/v1/flows/${Uri.encodeComponent(flowArn)}',
    exceptionFnMap: _exceptionFns,
  );
  return UpdateFlowResponse.fromJson(response);
}