Skip to content

Commit 5ebe519

Browse files
authored
Merge pull request #4 from rajavaid77/main
updated lambda concurrency, sync with workshop template
2 parents 5902b77 + 9e77991 commit 5ebe519

File tree

1 file changed

+28
-20
lines changed

1 file changed

+28
-20
lines changed

20-Industry-Use-Cases/22-Medical-Claims-Processing/assets/cfn-templates/bda-idp-workshop.yaml

Lines changed: 28 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -393,6 +393,11 @@ Resources:
393393
# Lambda function to load schema
394394
SchemaLoaderLambda:
395395
Type: AWS::Lambda::Function
396+
DependsOn:
397+
- CloudformationVpcEndoint
398+
- CloudWatchLogsVpcEndoint
399+
- RdsDataVpcEndoint
400+
- SecretsManagerVpcEndoint
396401
Properties:
397402
Description: Lambda function to setup initial data tables and sample data
398403
Handler: index.handler
@@ -406,7 +411,7 @@ Resources:
406411
- !Ref BDAWorkshopPrivateSubnet2
407412
SecurityGroupIds:
408413
- !Ref VPCLambdaSecurityGroup
409-
ReservedConcurrentExecutions: 5
414+
ReservedConcurrentExecutions: 1
410415
Layers:
411416
- !Ref ClaimsReviewLambdaLayer
412417
Code:
@@ -566,6 +571,10 @@ Resources:
566571

567572
VectorStoreIndexCreationLambdaFunction:
568573
Type: AWS::Lambda::Function
574+
DependsOn:
575+
- CloudformationVpcEndoint
576+
- CloudWatchLogsVpcEndoint
577+
- ClaimsVectorStoreVPCEndpoint
569578
Properties:
570579
Runtime: python3.11
571580
Handler: index.lambda_handler
@@ -578,7 +587,7 @@ Resources:
578587
- !Ref BDAWorkshopPrivateSubnet2
579588
SecurityGroupIds:
580589
- !Ref VPCLambdaSecurityGroup
581-
ReservedConcurrentExecutions: 5
590+
ReservedConcurrentExecutions: 1
582591
Layers:
583592
- !Ref ClaimsReviewLambdaLayer
584593
Code:
@@ -739,7 +748,9 @@ Resources:
739748
- bedrock:InvokeModel*
740749
- bedrock:CreateInferenceProfile
741750
Resource:
742-
- !Sub arn:aws:bedrock:${AWS::Region}::foundation-model/*
751+
- !Sub arn:aws:bedrock:us-east-1::foundation-model/anthropic.claude-3-5-haiku-20241022-v1:0
752+
- !Sub arn:aws:bedrock:us-east-2::foundation-model/anthropic.claude-3-5-haiku-20241022-v1:0
753+
- !Sub arn:aws:bedrock:us-west-2::foundation-model/anthropic.claude-3-5-haiku-20241022-v1:0
743754
- !Sub arn:aws:bedrock:${AWS::Region}:${AWS::AccountId}:inference-profile/*
744755
- !Sub arn:aws:bedrock:${AWS::Region}:${AWS::AccountId}:application-inference-profile/*
745756
Sid: InferenceCreateStatement
@@ -888,6 +899,11 @@ Resources:
888899

889900
ClaimsReviewAgentActionLambdaFunction:
890901
Type: AWS::Lambda::Function
902+
DependsOn:
903+
- CloudformationVpcEndoint
904+
- CloudWatchLogsVpcEndoint
905+
- RdsDataVpcEndoint
906+
- SecretsManagerVpcEndoint
891907
Properties:
892908
Runtime: python3.11
893909
Handler: index.lambda_handler
@@ -900,7 +916,6 @@ Resources:
900916
- !Ref BDAWorkshopPrivateSubnet2
901917
SecurityGroupIds:
902918
- !Ref VPCLambdaSecurityGroup
903-
ReservedConcurrentExecutions: 5
904919
Layers:
905920
- !Ref ClaimsReviewLambdaLayer
906921
Code:
@@ -1239,20 +1254,6 @@ Resources:
12391254
OwnershipSettings:
12401255
OwnerUserProfileName: !Ref UserProfileName
12411256

1242-
JupyterServerApp:
1243-
Type: AWS::SageMaker::App
1244-
DependsOn: UserProfile
1245-
Properties:
1246-
AppName: default
1247-
AppType: JupyterServer
1248-
DomainId: !Ref StudioDomain
1249-
UserProfileName: !Ref UserProfileName
1250-
ResourceSpec:
1251-
SageMakerImageArn: !FindInMap
1252-
- RegionMap
1253-
- !Ref AWS::Region
1254-
- jupyter
1255-
12561257
DeleteEFSVolumeLambdaRole:
12571258
Type: 'AWS::IAM::Role'
12581259
Properties:
@@ -1295,6 +1296,10 @@ Resources:
12951296

12961297
DeleteEFSVolumeLambda:
12971298
Type: AWS::Lambda::Function
1299+
DependsOn:
1300+
- CloudformationVpcEndoint
1301+
- CloudWatchLogsVpcEndoint
1302+
- SageMakerVpcEndoint
12981303
Properties:
12991304
Handler: index.lambda_handler
13001305
Description: "Delete all objects in S3 bucket"
@@ -1308,7 +1313,7 @@ Resources:
13081313
- !Ref BDAWorkshopPrivateSubnet2
13091314
SecurityGroupIds:
13101315
- !Ref VPCLambdaSecurityGroup
1311-
ReservedConcurrentExecutions: 5
1316+
ReservedConcurrentExecutions: 1
13121317
Layers:
13131318
- !Ref ClaimsReviewLambdaLayer
13141319
Code:
@@ -1367,6 +1372,9 @@ Resources:
13671372
Type: AWS::Lambda::Function
13681373
DependsOn:
13691374
- UserProfile
1375+
- SageMakerVpcEndoint
1376+
- CloudformationVpcEndoint
1377+
- CloudWatchLogsVpcEndoint
13701378
Properties:
13711379
Handler: index.lambda_handler
13721380
Description: Add LifeCycle Configuration to copy NB files to Studio
@@ -1380,7 +1388,7 @@ Resources:
13801388
- !Ref BDAWorkshopPrivateSubnet2
13811389
SecurityGroupIds:
13821390
- !Ref VPCLambdaSecurityGroup
1383-
ReservedConcurrentExecutions: 5
1391+
ReservedConcurrentExecutions: 1
13841392
Layers:
13851393
- !Ref ClaimsReviewLambdaLayer
13861394
Code:

0 commit comments

Comments
 (0)