Which actions should the developer take to increase the processing speed?
(Choose two.)
Increase the number of shards of the Kinesis data stream.
Decrease the timeout of the Lambda function.
Increase the memory that is allocated to the Lambda function.
Decrease the number of shards of the Kinesis data stream.
Increase the timeout of the Lambda function.
Explanations:
Increasing the number of shards in the Kinesis data stream allows for greater parallelism in processing. Each shard can support one concurrent Lambda function invocation, so more shards can lead to increased throughput and reduced iterator age.
Decreasing the timeout of the Lambda function would not help with processing speed. In fact, it could lead to more frequent timeouts if the function requires more time to process records, worsening the backlog of unprocessed records.
Increasing the memory allocated to the Lambda function can enhance its processing speed because it also increases the CPU allocated to the function. More memory allows for faster execution of the function, which can help reduce run duration and iterator age.
Decreasing the number of shards in the Kinesis data stream would reduce parallel processing capability, leading to slower record processing and increased iterator age. This is counterproductive when trying to improve processing speed.
Increasing the timeout of the Lambda function does not directly improve processing speed; it merely allows the function more time to complete its processing. If the function is slow due to resource limitations, simply increasing the timeout won’t solve the underlying issue.