MLS-C01 Question 48
Select 3You are managing a streaming data analytics application using Amazon Managed Service for Apache Flink. Your application processes high-throughput streaming data from Amazon Kinesis Data Streams and writes the results to an Amazon S3 bucket. Recently, you noticed a significant increase in data processing latency. Upon investigation, you discover that the application is experiencing backpressure. How can you effectively address this issue?
- A
Increase the number of Kinesis Data Stream shards to provide more throughput to the application.
- B
Scale the parallelism of the Managed Service for Apache Flink application to increase the number of parallel processing tasks.
- C
Enable checkpointing in the application to handle state recovery and improve processing speed.
- D
Monitor and optimize the Flink application code to improve the efficiency of stream processing.
- E
Reduce the retention period of data in the Kinesis Data Stream to decrease the volume of incoming data.
Show answer and explanation
Correct answers: A, B, D
Explanation
Backpressure in Apache Flink applications typically occurs when the system cannot process incoming data at the rate it is being received. To resolve this, you can increase the throughput of the data source (e.g., by adding shards to Kinesis Data Streams), scale the application's parallelism to handle more tasks simultaneously, and optimize the application code to improve processing efficiency. These actions directly target the causes of backpressure and help maintain low-latency data processing.
- A. Correct.
Increasing the number of Kinesis Data Stream shards can help address throughput issues by providing more capacity to handle incoming data, which can alleviate backpressure.
- B. Correct.
Scaling the parallelism of the Flink application allows more tasks to process data simultaneously, reducing the likelihood of bottlenecks and backpressure.
- C. Incorrect.
While enabling checkpointing is essential for state recovery and fault tolerance, it does not directly address backpressure caused by processing inefficiencies.
- D. Correct.
Optimizing the Flink application code can improve processing efficiency, reducing latency and mitigating backpressure.
- E. Incorrect.
Reducing the retention period of data in the Kinesis Data Stream does not address the root cause of backpressure and can lead to data loss if the application falls behind.