decrease_stream_retention_period¶
Operation¶
decrease_stream_retention_period
async
¶
decrease_stream_retention_period(input: DecreaseStreamRetentionPeriodInput, plugins: list[Plugin] | None = None) -> DecreaseStreamRetentionPeriodOutput
Decreases the Kinesis data stream's retention period, which is the length of time data records are accessible after they are added to the stream. The minimum value of a stream's retention period is 24 hours.
Note
When invoking this API, you must use either the StreamARN or the
StreamName parameter, or both. It is recommended that you use the
StreamARN input parameter when you invoke this API.
This operation may result in lost data. For example, if the stream's retention period is 48 hours and is decreased to 24 hours, any data already in the stream that is older than 24 hours is inaccessible.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
input
|
DecreaseStreamRetentionPeriodInput
|
An instance of |
required |
plugins
|
list[Plugin] | None
|
A list of callables that modify the configuration dynamically. Changes made by these plugins only apply for the duration of the operation execution and will not affect any other operation invocations. |
None
|
Returns:
| Type | Description |
|---|---|
DecreaseStreamRetentionPeriodOutput
|
An instance of |
Input¶
DecreaseStreamRetentionPeriodInput
dataclass
¶
Bases: _SerdeShape
Represents the input for DecreaseStreamRetentionPeriod.
Attributes¶
retention_period_hours
class-attribute
instance-attribute
¶
retention_period_hours: int | None = ...
The new retention period of the stream, in hours. Must be less than the current retention period.
Output¶
DecreaseStreamRetentionPeriodOutput
dataclass
¶
Bases: _SerdeShape
Dataclass for DecreaseStreamRetentionPeriodOutput structure.