Purge executions, logs, metrics, and storage files.
This task can be used to purge flow executions data for all flows, for a specific namespace, or for a specific flow.
type: "io.kestra.plugin.core.execution.PurgeExecutions"
Purge all flow execution data for flows that ended more than one month ago.
id: "purgeexecutions"
type: "io.kestra.plugin.core.execution.PurgeExecutions"
endDate: "{{ now() | dateAdd(-1, 'MONTHS') }}"
states:
- KILLED
- FAILED
- WARNING
- SUCCESS
YES
The maximum date to be purged.
All data of flows executed before this date will be purged.
YES
The flow ID to be purged.
You need to provide the namespace
properties if you want to purge a flow.
YES
Namespace whose flows need to be purged, or namespace of the flow that needs to be purged.
If flowId
isn't provided, this is a namespace prefix, else the namespace of the flow.
YES
true
YES
true
YES
true
YES
true
YES
The minimum date to be purged.
All data of flows executed after this date will be purged.
YES
CREATED
RUNNING
PAUSED
RESTARTED
KILLING
SUCCESS
WARNING
FAILED
KILLED
CANCELLED
QUEUED
RETRYING
RETRIED
SKIPPED
The state of the executions to be purged.
If not set, executions for any states will be purged.
0
The count of deleted executions.
0
The count of deleted logs.
0
The count of deleted metrics.
0
The count of deleted storage files.