Cost-Optimized Architecture Design

Which CloudWatch Logs setting automatically expires older log events to reduce ongoing storage costs?

Show the answer

Correct answerC. Retention period

AWhy not this: A data protection policy detects and masks sensitive data rather than setting log retention.

BWhy not this: A subscription filter forwards matching log events; it does not set their expiration.

CWhy this is right: A retention period controls how long log events are kept before automatic expiration.

DWhy not this: A metric filter extracts metric observations from matching log events rather than expiring them.

A retention period makes older log events eligible for automatic deletion, limiting ongoing storage. A subscription filter forwards log events to another destination rather than controlling their expiration.