From 96ad99b0d49b8b7b0bf16abcb2ed54dbc38e9ffc Mon Sep 17 00:00:00 2001 From: Iakov Gan Date: Sat, 9 Nov 2024 17:33:42 +0100 Subject: [PATCH 1/2] add time granularity --- cfn-templates/data-exports-aggregation.yaml | 14 +++++++++++--- 1 file changed, 11 insertions(+), 3 deletions(-) diff --git a/cfn-templates/data-exports-aggregation.yaml b/cfn-templates/data-exports-aggregation.yaml index 3631f08c..95599ae2 100644 --- a/cfn-templates/data-exports-aggregation.yaml +++ b/cfn-templates/data-exports-aggregation.yaml @@ -24,6 +24,7 @@ Metadata: Parameters: - EnableSCAD - RolePath + - TimeGranularity ParameterLabels: ManageCOH: @@ -40,6 +41,8 @@ Metadata: default: "Source Account Ids (Comma separated list)" EnableSCAD: default: "Enable Split Cost Allocation Data (SCAD) in CUR 2.0" + TimeGranularity: + default: "CUR 2.0 Granularity. Do not change." Parameters: @@ -92,8 +95,13 @@ Parameters: Default: "yes" RolePath: Type: String - Default: '/' Description: Path for roles where PermissionBoundaries can limit location + Default: '/' + TimeGranularity: + Type: String + Description: Changing of this parameter will require redeployment of this Stack, purging of data in Destination and then additional Backfill request. HOURLY is a recommended option unless your AWS invoice is more then $50M (in this case contact your TAM when installing). + Default: "HOURLY" + AllowedValues: ["HOURLY", "DAILY"] Conditions: EmptySourceAccountIds: !Equals [ !Ref SourceAccountIds, ''] @@ -427,7 +435,7 @@ Resources: QueryStatement: !If [EnableSCAD, !FindInMap [DataExports, CUR2, SCADQuery], !FindInMap [DataExports, CUR2, DefaultQuery]] TableConfigurations: COST_AND_USAGE_REPORT: - TIME_GRANULARITY: "HOURLY" + TIME_GRANULARITY: !Ref TimeGranularity INCLUDE_RESOURCES: "TRUE" INCLUDE_MANUAL_DISCOUNT_COMPATIBILITY: "FALSE" INCLUDE_SPLIT_COST_ALLOCATION_DATA: !If [EnableSCAD, "TRUE", "FALSE"] @@ -458,7 +466,7 @@ Resources: QueryStatement: !If [EnableSCAD, !FindInMap [DataExports, CUR2, SCADQuery], !FindInMap [DataExports, CUR2, DefaultQuery]] TableConfigurations: COST_AND_USAGE_REPORT: - TIME_GRANULARITY: "HOURLY" + TIME_GRANULARITY: !Ref TimeGranularity INCLUDE_RESOURCES: "TRUE" INCLUDE_MANUAL_DISCOUNT_COMPATIBILITY: "FALSE" INCLUDE_SPLIT_COST_ALLOCATION_DATA: !If [EnableSCAD, "TRUE", "FALSE"] From a2704293eee77e7f02599ddbad7e558d5248bd2e Mon Sep 17 00:00:00 2001 From: Iakov Gan Date: Sat, 9 Nov 2024 20:02:43 +0100 Subject: [PATCH 2/2] add month --- cfn-templates/data-exports-aggregation.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cfn-templates/data-exports-aggregation.yaml b/cfn-templates/data-exports-aggregation.yaml index 95599ae2..f2be77aa 100644 --- a/cfn-templates/data-exports-aggregation.yaml +++ b/cfn-templates/data-exports-aggregation.yaml @@ -101,7 +101,7 @@ Parameters: Type: String Description: Changing of this parameter will require redeployment of this Stack, purging of data in Destination and then additional Backfill request. HOURLY is a recommended option unless your AWS invoice is more then $50M (in this case contact your TAM when installing). Default: "HOURLY" - AllowedValues: ["HOURLY", "DAILY"] + AllowedValues: ["HOURLY", "DAILY", "MONTHLY"] Conditions: EmptySourceAccountIds: !Equals [ !Ref SourceAccountIds, '']