Copyright | (c) 2013-2023 Brendan Hay |
---|---|
License | Mozilla Public License, v. 2.0. |
Maintainer | Brendan Hay |
Stability | auto-generated |
Portability | non-portable (GHC extensions) |
Safe Haskell | Safe-Inferred |
Language | Haskell2010 |
Sets the retention of the specified log group. With a retention policy, you can configure the number of days for which to retain log events in the specified log group.
CloudWatch Logs doesn’t immediately delete log events when they reach their retention setting. It typically takes up to 72 hours after that before log events are deleted, but in rare situations might take longer.
To illustrate, imagine that you change a log group to have a longer retention setting when it contains log events that are past the expiration date, but haven’t been deleted. Those log events will take up to 72 hours to be deleted after the new retention date is reached. To make sure that log data is deleted permanently, keep a log group at its lower retention setting until 72 hours after the previous retention period ends. Alternatively, wait to change the retention setting until you confirm that the earlier log events are deleted.
Synopsis
- data PutRetentionPolicy = PutRetentionPolicy' {}
- newPutRetentionPolicy :: Text -> Int -> PutRetentionPolicy
- putRetentionPolicy_logGroupName :: Lens' PutRetentionPolicy Text
- putRetentionPolicy_retentionInDays :: Lens' PutRetentionPolicy Int
- data PutRetentionPolicyResponse = PutRetentionPolicyResponse' {
- newPutRetentionPolicyResponse :: PutRetentionPolicyResponse
Creating a Request
data PutRetentionPolicy Source #
See: newPutRetentionPolicy
smart constructor.
PutRetentionPolicy' | |
|
Instances
newPutRetentionPolicy Source #
Create a value of PutRetentionPolicy
with all optional fields omitted.
Use generic-lens or optics to modify other optional fields.
The following record fields are available, with the corresponding lenses provided for backwards compatibility:
PutRetentionPolicy
, putRetentionPolicy_logGroupName
- The name of the log group.
PutRetentionPolicy
, putRetentionPolicy_retentionInDays
- Undocumented member.
Request Lenses
putRetentionPolicy_logGroupName :: Lens' PutRetentionPolicy Text Source #
The name of the log group.
putRetentionPolicy_retentionInDays :: Lens' PutRetentionPolicy Int Source #
Undocumented member.
Destructuring the Response
data PutRetentionPolicyResponse Source #
See: newPutRetentionPolicyResponse
smart constructor.
Instances
newPutRetentionPolicyResponse :: PutRetentionPolicyResponse Source #
Create a value of PutRetentionPolicyResponse
with all optional fields omitted.
Use generic-lens or optics to modify other optional fields.