Skip to main content

⭐ Repository β†’ πŸ“ Compliance Engine β†’ πŸ“ CloudAware β†’ πŸ“ Azure β†’ πŸ“ SQL Database β†’ πŸ›‘οΈ Database is located in a less cost-effective region🟒

🧠 Azure SQL Database is located in a less cost-effective region - prod.logic.yaml🟒

Uses​

Test Results πŸŸ’β€‹

Generated at: 2025-10-01T12:47:02.443375738Z Open

ResultIdCondition IndexCondition TextRuntime Error
🟒001βœ”οΈ 99βœ”οΈ isDisappeared(CA10__disappearanceTime__c)βœ”οΈ null
🟒002βœ”οΈ 899βœ”οΈ extract('CA10__locationName__c') == 'uksouth'βœ”οΈ null
🟒003βœ”οΈ 1199βœ”οΈ extract('CA10__locationName__c') == 'westeurope'βœ”οΈ null
🟒004βœ”οΈ 2499βœ”οΈ extract('CA10__locationName__c') == 'japaneast'βœ”οΈ null
🟒005βœ”οΈ 2700βœ”οΈ otherwiseβœ”οΈ null

Generation Bundle​

FileMD5
Open/ce/ca/azure/sql-database/database-cost-effective-region/policy.yaml4E9F0AC1D3F876A06B4AAD1A48D11EBF
Open/ce/ca/azure/sql-database/database-cost-effective-region/prod.logic.yamlEB028CD19A048E8C5A2FFAE19C012126
Open/ce/ca/azure/sql-database/database-cost-effective-region/test-data.json475FD25A6E0B499882D1D44B239355B1
Open/types/CA10__CaAzureSqlDatabase__c/object.extracts.yamlB4BDC0B62AEF4B03FB276D037CE05688

Available Commands​

repo-manager policies generate FULL /ce/ca/azure/sql-database/database-cost-effective-region/prod.logic.yaml
repo-manager policies generate DEBUG /ce/ca/azure/sql-database/database-cost-effective-region/prod.logic.yaml
repo-manager policies generate CAPTURE_TEST_DATA /ce/ca/azure/sql-database/database-cost-effective-region/prod.logic.yaml
repo-manager policies generate TESTS /ce/ca/azure/sql-database/database-cost-effective-region/prod.logic.yaml
# Execute tests
repo-manager policies test /ce/ca/azure/sql-database/database-cost-effective-region/prod.logic.yaml

Content​

Open File

---
inputType: "CA10__CaAzureSqlDatabase__c"
importExtracts:
- file: "/types/CA10__CaAzureSqlDatabase__c/object.extracts.yaml"
testData:
- file: 'test-data.json'
conditions:
- status: "INCOMPLIANT"
currentStateMessage: "The Database is running in westus which is more expensive than westus3 or westus2."
remediationMessage: "Consider migrating the Database to westus3 or westus2."
check:
IS_EQUAL:
left:
EXTRACT: CA10__locationName__c
right:
TEXT: "westus"
- status: "INCOMPLIANT"
currentStateMessage: "The Database is running in westcentralus which is more expensive than westus3 or westus2."
remediationMessage: "Consider migrating the Database to westus3 or westus2."
check:
IS_EQUAL:
left:
EXTRACT: CA10__locationName__c
right:
TEXT: "westcentralus"
- status: "INCOMPLIANT"
currentStateMessage: "The Database is running in southcentralus which is more expensive than northcentralus, westus3 or westus2."
remediationMessage: "Consider migrating the Database to northcentralus, westus3 or westus2."
check:
IS_EQUAL:
left:
EXTRACT: CA10__locationName__c
right:
TEXT: "southcentralus"
- status: "INCOMPLIANT"
currentStateMessage: "The Database is running in centralus which is more expensive than northcentralus, westus3 or westus2."
remediationMessage: "Consider migrating the Database to northcentralus, westus3 or westus2."
check:
IS_EQUAL:
left:
EXTRACT: CA10__locationName__c
right:
TEXT: "centralus"
- status: "INCOMPLIANT"
currentStateMessage: "The Database is running in canadaeast which is more expensive than eastus or eastus2."
remediationMessage: "Consider migrating the Database to eastus or eastus2."
check:
IS_EQUAL:
left:
EXTRACT: CA10__locationName__c
right:
TEXT: "canadaeast"
- status: "INCOMPLIANT"
currentStateMessage: "The Database is running in canadacentral which is more expensive than eastus or eastus2."
remediationMessage: "Consider migrating the Database to eastus or eastus2."
check:
IS_EQUAL:
left:
EXTRACT: CA10__locationName__c
right:
TEXT: "canadacentral"
- status: "INCOMPLIANT"
currentStateMessage: "The Database is running in ukwest which is more expensive than eu-west-1, eu-north-1, or eu-south-2."
remediationMessage: "Consider migrating the Database to eu-west-1, eu-north-1, or eu-south-2."
check:
IS_EQUAL:
left:
EXTRACT: CA10__locationName__c
right:
TEXT: "ukwest"
- status: "INCOMPLIANT"
currentStateMessage: "The Database is running in uksouth which is more expensive than eu-west-1, eu-north-1, or eu-south-2."
remediationMessage: "Consider migrating the Database to eu-west-1, eu-north-1, or eu-south-2."
check:
IS_EQUAL:
left:
EXTRACT: CA10__locationName__c
right:
TEXT: "uksouth"
- status: "INCOMPLIANT"
currentStateMessage: "The Database is running in francecentral which is more expensive than eu-west-1, eu-north-1, or eu-south-2."
remediationMessage: "Consider migrating the Database to eu-west-1, eu-north-1, or eu-south-2."
check:
IS_EQUAL:
left:
EXTRACT: CA10__locationName__c
right:
TEXT: "francecentral"
- status: "INCOMPLIANT"
currentStateMessage: "The Database is running in francesouth which is more expensive than eu-west-1, eu-north-1, or eu-south-2."
remediationMessage: "Consider migrating the Database to eu-west-1, eu-north-1, or eu-south-2."
check:
IS_EQUAL:
left:
EXTRACT: CA10__locationName__c
right:
TEXT: "francesouth"
- status: "INCOMPLIANT"
currentStateMessage: "The Database is running in westeurope which is more expensive than swedencentral or northeurope."
remediationMessage: "Consider migrating the Database to swedencentral or northeurope."
check:
IS_EQUAL:
left:
EXTRACT: CA10__locationName__c
right:
TEXT: "westeurope"
- status: "INCOMPLIANT"
currentStateMessage: "The Database is running in germanywestcentral which is more expensive than swedencentral or northeurope."
remediationMessage: "Consider migrating the Database to swedencentral or northeurope."
check:
IS_EQUAL:
left:
EXTRACT: CA10__locationName__c
right:
TEXT: "germanywestcentral"
- status: "INCOMPLIANT"
currentStateMessage: "The Database is running in germanynorth which is more expensive than swedencentral or northeurope."
remediationMessage: "Consider migrating the Database to swedencentral or northeurope."
check:
IS_EQUAL:
left:
EXTRACT: CA10__locationName__c
right:
TEXT: "germanynorth"
- status: "INCOMPLIANT"
currentStateMessage: "The Database is running in switzerlandnorth which is more expensive than swedencentral or northeurope."
remediationMessage: "Consider migrating the Database to swedencentral or northeurope."
check:
IS_EQUAL:
left:
EXTRACT: CA10__locationName__c
right:
TEXT: "switzerlandnorth"
- status: "INCOMPLIANT"
currentStateMessage: "The Database is running in switzerlandwest which is more expensive than swedencentral or northeurope."
remediationMessage: "Consider migrating the Database to swedencentral or northeurope."
check:
IS_EQUAL:
left:
EXTRACT: CA10__locationName__c
right:
TEXT: "switzerlandwest"
- status: "INCOMPLIANT"
currentStateMessage: "The Database is running in italynorth which is more expensive than swedencentral or northeurope."
remediationMessage: "Consider migrating the Database to swedencentral or northeurope."
check:
IS_EQUAL:
left:
EXTRACT: CA10__locationName__c
right:
TEXT: "italynorth"
- status: "INCOMPLIANT"
currentStateMessage: "The Database is running in polandcentral which is more expensive than swedencentral or northeurope."
remediationMessage: "Consider migrating the Database to swedencentral or northeurope."
check:
IS_EQUAL:
left:
EXTRACT: CA10__locationName__c
right:
TEXT: "polandcentral"
- status: "INCOMPLIANT"
currentStateMessage: "The Database is running in norwayeast which is more expensive than swedencentral or northeurope."
remediationMessage: "Consider migrating the Database to swedencentral or northeurope."
check:
IS_EQUAL:
left:
EXTRACT: CA10__locationName__c
right:
TEXT: "norwayeast"
- status: "INCOMPLIANT"
currentStateMessage: "The Database is running in norwaywest which is more expensive than swedencentral or northeurope."
remediationMessage: "Consider migrating the Database to swedencentral or northeurope."
check:
IS_EQUAL:
left:
EXTRACT: CA10__locationName__c
right:
TEXT: "norwaywest"
- status: "INCOMPLIANT"
currentStateMessage: "The Database is running in swedensouth which is more expensive than swedencentral or northeurope."
remediationMessage: "Consider migrating the Database to swedencentral or northeurope."
check:
IS_EQUAL:
left:
EXTRACT: CA10__locationName__c
right:
TEXT: "swedensouth"
- status: "INCOMPLIANT"
currentStateMessage: "The Database is running in spaincentral which is more expensive than swedencentral or northeurope."
remediationMessage: "Consider migrating the Database to swedencentral or northeurope."
check:
IS_EQUAL:
left:
EXTRACT: CA10__locationName__c
right:
TEXT: "spaincentral"
- status: "INCOMPLIANT"
currentStateMessage: "The Database is running in australiaeast which is more expensive than australiacentral or australiacentral2."
remediationMessage: "Consider migrating the Database to australiacentral or australiacentral2."
check:
IS_EQUAL:
left:
EXTRACT: CA10__locationName__c
right:
TEXT: "australiaeast"
- status: "INCOMPLIANT"
currentStateMessage: "The Database is running in australiasoutheast which is more expensive than australiacentral or australiacentral2."
remediationMessage: "Consider migrating the Database to australiacentral or australiacentral2."
check:
IS_EQUAL:
left:
EXTRACT: CA10__locationName__c
right:
TEXT: "australiasoutheast"
- status: "INCOMPLIANT"
currentStateMessage: "The Database is running in japaneast which is more expensive than koreasouth."
remediationMessage: "Consider migrating the Database to koreasouth."
check:
IS_EQUAL:
left:
EXTRACT: CA10__locationName__c
right:
TEXT: "japaneast"
- status: "INCOMPLIANT"
currentStateMessage: "The Database is running in japanwest which is more expensive than koreasouth."
remediationMessage: "Consider migrating the Database to koreasouth."
check:
IS_EQUAL:
left:
EXTRACT: CA10__locationName__c
right:
TEXT: "japanwest"
- status: "INCOMPLIANT"
currentStateMessage: "The Database is running in koreacentral which is more expensive than koreasouth."
remediationMessage: "Consider migrating the Database to koreasouth."
check:
IS_EQUAL:
left:
EXTRACT: CA10__locationName__c
right:
TEXT: "koreacentral"
otherwise:
status: "COMPLIANT"
currentStateMessage: "The VM is located in a cost-effective region."