From 80633075119c3d34343fb3ddc637d096a8a79293 Mon Sep 17 00:00:00 2001 From: awstools Date: Tue, 24 Sep 2024 18:58:40 +0000 Subject: [PATCH] feat(client-budgets): Releasing minor partitional endpoint updates --- .../client-budgets/src/endpoint/ruleset.ts | 2 +- codegen/sdk-codegen/aws-models/budgets.json | 150 +++++++++++++++++- 2 files changed, 149 insertions(+), 3 deletions(-) diff --git a/clients/client-budgets/src/endpoint/ruleset.ts b/clients/client-budgets/src/endpoint/ruleset.ts index 5a65f1086096..70d9ac2a2996 100644 --- a/clients/client-budgets/src/endpoint/ruleset.ts +++ b/clients/client-budgets/src/endpoint/ruleset.ts @@ -34,5 +34,5 @@ u={[z]:c,[A]:[true,{[z]:"getAttr",[A]:[{[B]:g},"supportsDualStack"]}]}, v=[n], w=[o], x=[{[B]:"Region"}]; -const _data={version:"1.0",parameters:{Region:k,UseDualStack:l,UseFIPS:l,Endpoint:k},rules:[{conditions:[{[z]:b,[A]:[m]}],rules:[{conditions:v,error:"Invalid Configuration: FIPS and custom endpoint are not supported",type:d},{conditions:w,error:"Invalid Configuration: Dualstack and custom endpoint are not supported",type:d},{endpoint:{url:m,properties:p,headers:p},type:e}],type:f},{conditions:[{[z]:b,[A]:x}],rules:[{conditions:[{[z]:"aws.partition",[A]:x,assign:g}],rules:[{conditions:[{[z]:h,[A]:[q,"aws"]},r,s],endpoint:{url:"https://budgets.amazonaws.com",properties:{authSchemes:[{name:i,signingName:j,signingRegion:"us-east-1"}]},headers:p},type:e},{conditions:[{[z]:h,[A]:[q,"aws-cn"]},r,s],endpoint:{url:"https://budgets.amazonaws.com.cn",properties:{authSchemes:[{name:i,signingName:j,signingRegion:"cn-northwest-1"}]},headers:p},type:e},{conditions:[n,o],rules:[{conditions:[{[z]:c,[A]:[a,t]},u],rules:[{endpoint:{url:"https://budgets-fips.{Region}.{PartitionResult#dualStackDnsSuffix}",properties:p,headers:p},type:e}],type:f},{error:"FIPS and DualStack are enabled, but this partition does not support one or both",type:d}],type:f},{conditions:v,rules:[{conditions:[{[z]:c,[A]:[t,a]}],rules:[{endpoint:{url:"https://budgets-fips.{Region}.{PartitionResult#dnsSuffix}",properties:p,headers:p},type:e}],type:f},{error:"FIPS is enabled but this partition does not support FIPS",type:d}],type:f},{conditions:w,rules:[{conditions:[u],rules:[{endpoint:{url:"https://budgets.{Region}.{PartitionResult#dualStackDnsSuffix}",properties:p,headers:p},type:e}],type:f},{error:"DualStack is enabled but this partition does not support DualStack",type:d}],type:f},{endpoint:{url:"https://budgets.{Region}.{PartitionResult#dnsSuffix}",properties:p,headers:p},type:e}],type:f}],type:f},{error:"Invalid Configuration: Missing Region",type:d}]}; +const _data={version:"1.0",parameters:{Region:k,UseDualStack:l,UseFIPS:l,Endpoint:k},rules:[{conditions:[{[z]:b,[A]:[m]}],rules:[{conditions:v,error:"Invalid Configuration: FIPS and custom endpoint are not supported",type:d},{conditions:w,error:"Invalid Configuration: Dualstack and custom endpoint are not supported",type:d},{endpoint:{url:m,properties:p,headers:p},type:e}],type:f},{conditions:[{[z]:b,[A]:x}],rules:[{conditions:[{[z]:"aws.partition",[A]:x,assign:g}],rules:[{conditions:[{[z]:h,[A]:[q,"aws"]},r,s],endpoint:{url:"https://budgets.amazonaws.com",properties:{authSchemes:[{name:i,signingName:j,signingRegion:"us-east-1"}]},headers:p},type:e},{conditions:[{[z]:h,[A]:[q,"aws-cn"]},r,s],endpoint:{url:"https://budgets.amazonaws.com.cn",properties:{authSchemes:[{name:i,signingName:j,signingRegion:"cn-northwest-1"}]},headers:p},type:e},{conditions:[{[z]:h,[A]:[q,"aws-iso-e"]},r,s],endpoint:{url:"https://budgets.global.cloud.adc-e.uk",properties:{authSchemes:[{name:i,signingName:j,signingRegion:"eu-isoe-west-1"}]},headers:p},type:e},{conditions:[{[z]:h,[A]:[q,"aws-iso-f"]},r,s],endpoint:{url:"https://budgets.global.csp.hci.ic.gov",properties:{authSchemes:[{name:i,signingName:j,signingRegion:"us-isof-south-1"}]},headers:p},type:e},{conditions:[n,o],rules:[{conditions:[{[z]:c,[A]:[a,t]},u],rules:[{endpoint:{url:"https://budgets-fips.{Region}.{PartitionResult#dualStackDnsSuffix}",properties:p,headers:p},type:e}],type:f},{error:"FIPS and DualStack are enabled, but this partition does not support one or both",type:d}],type:f},{conditions:v,rules:[{conditions:[{[z]:c,[A]:[t,a]}],rules:[{endpoint:{url:"https://budgets-fips.{Region}.{PartitionResult#dnsSuffix}",properties:p,headers:p},type:e}],type:f},{error:"FIPS is enabled but this partition does not support FIPS",type:d}],type:f},{conditions:w,rules:[{conditions:[u],rules:[{endpoint:{url:"https://budgets.{Region}.{PartitionResult#dualStackDnsSuffix}",properties:p,headers:p},type:e}],type:f},{error:"DualStack is enabled but this partition does not support DualStack",type:d}],type:f},{endpoint:{url:"https://budgets.{Region}.{PartitionResult#dnsSuffix}",properties:p,headers:p},type:e}],type:f}],type:f},{error:"Invalid Configuration: Missing Region",type:d}]}; export const ruleSet: RuleSetObject = _data; diff --git a/codegen/sdk-codegen/aws-models/budgets.json b/codegen/sdk-codegen/aws-models/budgets.json index 6932de648e8d..cdaff177ff7c 100644 --- a/codegen/sdk-codegen/aws-models/budgets.json +++ b/codegen/sdk-codegen/aws-models/budgets.json @@ -340,6 +340,108 @@ }, "type": "endpoint" }, + { + "conditions": [ + { + "fn": "stringEquals", + "argv": [ + { + "fn": "getAttr", + "argv": [ + { + "ref": "PartitionResult" + }, + "name" + ] + }, + "aws-iso-e" + ] + }, + { + "fn": "booleanEquals", + "argv": [ + { + "ref": "UseFIPS" + }, + false + ] + }, + { + "fn": "booleanEquals", + "argv": [ + { + "ref": "UseDualStack" + }, + false + ] + } + ], + "endpoint": { + "url": "https://budgets.global.cloud.adc-e.uk", + "properties": { + "authSchemes": [ + { + "name": "sigv4", + "signingName": "budgets", + "signingRegion": "eu-isoe-west-1" + } + ] + }, + "headers": {} + }, + "type": "endpoint" + }, + { + "conditions": [ + { + "fn": "stringEquals", + "argv": [ + { + "fn": "getAttr", + "argv": [ + { + "ref": "PartitionResult" + }, + "name" + ] + }, + "aws-iso-f" + ] + }, + { + "fn": "booleanEquals", + "argv": [ + { + "ref": "UseFIPS" + }, + false + ] + }, + { + "fn": "booleanEquals", + "argv": [ + { + "ref": "UseDualStack" + }, + false + ] + } + ], + "endpoint": { + "url": "https://budgets.global.csp.hci.ic.gov", + "properties": { + "authSchemes": [ + { + "name": "sigv4", + "signingName": "budgets", + "signingRegion": "us-isof-south-1" + } + ] + }, + "headers": {} + }, + "type": "endpoint" + }, { "conditions": [ { @@ -858,6 +960,50 @@ "UseDualStack": false } }, + { + "documentation": "For region eu-isoe-west-1 with FIPS disabled and DualStack disabled", + "expect": { + "endpoint": { + "properties": { + "authSchemes": [ + { + "name": "sigv4", + "signingName": "budgets", + "signingRegion": "eu-isoe-west-1" + } + ] + }, + "url": "https://budgets.global.cloud.adc-e.uk" + } + }, + "params": { + "Region": "eu-isoe-west-1", + "UseFIPS": false, + "UseDualStack": false + } + }, + { + "documentation": "For region us-isof-south-1 with FIPS disabled and DualStack disabled", + "expect": { + "endpoint": { + "properties": { + "authSchemes": [ + { + "name": "sigv4", + "signingName": "budgets", + "signingRegion": "us-isof-south-1" + } + ] + }, + "url": "https://budgets.global.csp.hci.ic.gov" + } + }, + "params": { + "Region": "us-isof-south-1", + "UseFIPS": false, + "UseDualStack": false + } + }, { "documentation": "For custom endpoint with region set and fips disabled and dualstack disabled", "expect": { @@ -3861,7 +4007,7 @@ "min": 25, "max": 684 }, - "smithy.api#pattern": "^arn:(aws|aws-cn|aws-us-gov|us-iso-east-1|us-isob-east-1):iam::(\\d{12}|aws):policy(\\u002F[\\u0021-\\u007F]+\\u002F|\\u002F)[\\w+=,.@-]+$" + "smithy.api#pattern": "^arn:aws(-cn|-us-gov|-iso|-iso-[a-z]{1})?:iam::(\\d{12}|aws):policy(\\u002F[\\u0021-\\u007F]+\\u002F|\\u002F)[\\w+=,.@-]+$" } }, "com.amazonaws.budgets#PolicyId": { @@ -3978,7 +4124,7 @@ "min": 32, "max": 618 }, - "smithy.api#pattern": "^arn:(aws|aws-cn|aws-us-gov|us-iso-east-1|us-isob-east-1):iam::\\d{12}:role(\\u002F[\\u0021-\\u007F]+\\u002F|\\u002F)[\\w+=,.@-]+$" + "smithy.api#pattern": "^arn:aws(-cn|-us-gov|-iso|-iso-[a-z]{1})?:iam::\\d{12}:role(\\u002F[\\u0021-\\u007F]+\\u002F|\\u002F)[\\w+=,.@-]+$" } }, "com.amazonaws.budgets#Roles": {