New to Kestra?
Use blueprints to kickstart your first workflows.
Audits AWS EFS file systems for burst credit depletion and I/O throughput throttling, delivering proactive scaling alerts to platform teams via Slack.
Modern cloud architectures rely on Amazon Elastic File System (EFS) to provide shared, POSIX-compliant persistent storage across Kubernetes pods, Amazon ECS containers, and auto-scaled EC2 instances. Under the standard Bursting Throughput mode, an EFS file system accumulates burst credits during quiet periods and expends them when read and write throughput surges. However, when high-throughput batch ETL pipelines, distributed software builds, or unindexed database backups read and write to the shared volume continuously, burst credits deplete rapidly. Once the burst balance reaches zero, AWS clamps throughput down to baseline rates (as low as 50 KiB/s per GiB of storage). This causes disk I/O bottlenecks, application request timeouts, and cascading container pod evictions. This sentinel monitors the CloudWatch BurstCreditBalance and PermittedThroughput metrics hourly, identifies depleted file systems, and notifies platform teams on Slack with remediation commands to upgrade to Elastic Throughput before production services fail.
0 * * * *) or runs on-demand via manual execution.BurstCreditBalance and PermittedThroughput metrics.min_burst_credit_bytes_threshold.io.kestra.plugin.core.flow.If flowable checks if credits are depleted and dispatches an incident card to #cloud-storage-alerts.flowchart TD
A[hourly_efs_credit_audit Schedule Trigger] --> B[scan_efs_credits Python Script]
B --> C[check_burst_credit_depletion Flowable If]
C -- Credit Balance Depleted --> D[notify_slack_credit_exhaustion Webhook]
C -- Credits Nominal --> E[log_storage_health_state Log]
D --> E
E --> F[export_efs_manifest Return]
While AWS CloudWatch monitors metrics, translating credit dips into automated operational decisions across engineering teams requires workflow orchestration. Kestra connects directly to AWS APIs, parses real-time CloudWatch metrics, formats actionable incident alerts, and can trigger automated throughput mode transitions. With Kestra's containerized Python runner and native secret management, teams bridge the gap between cloud metrics and automated reliability workflows.
| Name | Type | Default | Description |
|---|---|---|---|
aws_region |
STRING |
us-east-1 |
Target AWS region where the EFS file systems and CloudWatch metrics reside. |
file_system_id |
STRING |
fs-0123456789abcdef0 |
Unique identifier of the target AWS EFS file system to monitor. |
min_burst_credit_bytes_threshold |
FLOAT |
107374182400.0 |
Minimum acceptable BurstCreditBalance in bytes (default 100 GiB) before triggering depletion alerts. |
alert_on_depletion |
BOOL |
true |
Whether to dispatch automated Slack incident notifications when burst credits are exhausted. |
{{ outputs.scan_efs_credits.vars.file_system_name }}: Name or tag of the evaluated EFS file system.{{ outputs.scan_efs_credits.vars.burst_credits_gib }}: Remaining burst credit balance expressed in gigabytes.{{ outputs.scan_efs_credits.vars.is_depleted }}: Boolean flag indicating whether the burst credit balance breached safety limits.{{ outputs.export_efs_manifest.value }}: Structured dictionary containing the consolidated EFS storage diagnostic manifest.elasticfilesystem:DescribeFileSystems and cloudwatch:GetMetricData permissions.AWS_ACCESS_KEY_ID: AWS IAM access key with permissions to read EFS metadata and CloudWatch metrics.AWS_SECRET_ACCESS_KEY: AWS IAM secret key corresponding to the access key.SLACK_WEBHOOK_URL: Slack Incoming Webhook URL used to dispatch storage alerts.AWS_ACCESS_KEY_ID, AWS_SECRET_ACCESS_KEY, and SLACK_WEBHOOK_URL in your Kestra secret storage.company.cloud namespace.file_system_id with your EFS volume ID (e.g., fs-0123456789abcdef0).BurstCreditBalance is not tracked and is reported as 0; the script detects this mode and avoids false alerts.cloudwatch:GetMetricData for the AWS/EFS namespace; missing permissions yield empty metric arrays.io.kestra.plugin.core.flow.ForEach loop to monitor all regional EFS volumes.