Skip to main content

🧠 AWS ELB Application Load Balancer is idle - prod.logic.yaml🟒

Uses​

Test Results πŸŸ’β€‹

Generated at: 2025-12-27T12:02:00.119740489Z Open

ResultIdCondition IndexCondition TextRuntime Error
🟒001βœ”οΈ 99βœ”οΈ isDisappeared(CA10__disappearanceTime__c)βœ”οΈ null
🟒002βœ”οΈ 399βœ”οΈ extract('CA10__createdTime__c').withinLastDays(30)βœ”οΈ null
🟒003βœ”οΈ 499βœ”οΈ extract('CA10__requestCountOneMonth__c').isEmpty() || extract('CA10__requestCountOneMonth__c') <= number(0.0)βœ”οΈ null
🟒004βœ”οΈ 499βœ”οΈ extract('CA10__requestCountOneMonth__c').isEmpty() || extract('CA10__requestCountOneMonth__c') <= number(0.0)βœ”οΈ null
🟒005βœ”οΈ 500βœ”οΈ otherwiseβœ”οΈ null
🟒006βœ”οΈ 499βœ”οΈ extract('CA10__requestCountOneMonth__c').isEmpty() || extract('CA10__requestCountOneMonth__c') <= number(0.0)βœ”οΈ null

Generation Bundle​

FileMD5
Open/ce/ca/aws/elb/load-balancer-idle/policy.yamlEB68D51FCC51CE71E691FF9366345FFD
Open/ce/ca/aws/elb/load-balancer-idle/prod.logic.yaml9714D5F3EAC2FF5CF07EB837FD562516
Open/ce/ca/aws/elb/load-balancer-idle/test-data.jsonA8054F8C017C9237707B5D9371EB59FB
Open/types/CA10__CaAwsLoadBalancer__c/object.extracts.yaml08ABDD2ADB04C6F391A6E9FE1F0ACBBE

Available Commands​

repo-manager policies generate FULL /ce/ca/aws/elb/load-balancer-idle/prod.logic.yaml
repo-manager policies generate DEBUG /ce/ca/aws/elb/load-balancer-idle/prod.logic.yaml
repo-manager policies generate CAPTURE_TEST_DATA /ce/ca/aws/elb/load-balancer-idle/prod.logic.yaml
repo-manager policies generate TESTS /ce/ca/aws/elb/load-balancer-idle/prod.logic.yaml
# Execute tests
repo-manager policies test /ce/ca/aws/elb/load-balancer-idle/prod.logic.yaml

Content​

Open File

---
inputType: "CA10__CaAwsLoadBalancer__c"
recordTypes:
- "caAwsLoadBalancerApplication"
- "caAwsLoadBalancerClassic"
importExtracts:
- file: "/types/CA10__CaAwsLoadBalancer__c/object.extracts.yaml"
testData:
- file: "test-data.json"
conditions:
- status: "INAPPLICABLE"
currentStateMessage: "This policy only applies to Application and Classic Load Balancers."
check:
AND:
args:
- NOT_EQUAL:
left:
EXTRACT: "CA10__type__c"
right:
TEXT: "application"
- NOT_EQUAL:
left:
EXTRACT: "CA10__type__c"
right:
TEXT: "classic"
- status: "INAPPLICABLE"
currentStateMessage: "The Load Balancer has been created less than 30 days ago."
check:
IS_WITHIN_LAST_DAYS:
offsetDays: 30
arg:
EXTRACT: "CA10__createdTime__c"
- status: "INCOMPLIANT"
currentStateMessage: "The Load Balancer has received zero requests in the last 30 days."
remediationMessage: "Review the idle Load Balancer and consider deleting it to save costs."
check:
OR:
args:
- IS_EMPTY:
arg:
EXTRACT: "CA10__requestCountOneMonth__c"
- LESS_THAN_EQUAL:
left:
EXTRACT: "CA10__requestCountOneMonth__c"
right:
NUMBER: 0.0
otherwise:
status: "COMPLIANT"
currentStateMessage: "The Application Load Balancer is actively processing requests."