[{"data":1,"prerenderedAt":66},["ShallowReactive",2],{"pattern-eventbridge-lambda-rust":3},{"id":4,"title":5,"architectureURL":6,"cleanup":7,"contributors":12,"deploy":14,"description":17,"extension":18,"framework":19,"gitHub":20,"highlight":6,"introBox":26,"language":32,"level":33,"meta":34,"patternArch":35,"resources":48,"s3URL":6,"services":57,"stem":58,"testing":59,"videoId":31,"__hash__":65},"patterns\u002Fpatterns\u002Feventbridge-lambda-rust.json","Amazon EventBridge to AWS Lambda",null,{"headline":8,"text":9},"Cleanup",[10,11],"1. Delete the stack: \u003Ccode>sam delete --stack-name STACK_NAME\u003C\u002Fcode>.","2. Confirm the stack has been deleted: \u003Ccode>aws cloudformation list-stacks --query \"StackSummaries[?contains(StackName,'STACK_NAME')].StackStatus\"\u003C\u002Fcode>",[13],"content\u002Fcontributors\u002Fdaniele-frasca.json",{"text":15},[16],"sam deploy --guided","Create an EventBridge rule that invokes a Lambda function","json","AWS SAM",{"template":21},{"projectFolder":22,"repoURL":23,"templateURL":24,"templateFile":25},"eventbridge-lambda-rust","https:\u002F\u002Fgithub.com\u002Faws-samples\u002Fserverless-patterns\u002Ftree\u002Fmain\u002Feventbridge-lambda-rust","serverless-patterns\u002Feventbridge-lambda-rust","template.yml",{"headline":27,"text":28,"test":31},"How it works",[29,30],"This template deploys a Lambda function that is triggered by an EventBridge rule. In this example, the rule filters for specific attributes in the event before invoking the function.","The Events section of the AWS::Serverless::Function type also sets up the required permissions for EventBridge to invoke this specific function.","","Rust","100",{},{"icon1":36,"icon2":41,"line1":45},{"x":37,"y":38,"service":39,"label":40},20,50,"eventbridge","EventBridge",{"x":42,"y":38,"service":43,"label":44},80,"lambda","AWS Lambda",{"from":46,"to":47,"label":31},"icon1","icon2",{"headline":49,"bullets":50},"Additional resources",[51,54],{"text":52,"link":53},"Reducing custom code by using advanced rules in Amazon EventBridge","https:\u002F\u002Faws.amazon.com\u002Fblogs\u002Fcompute\u002Freducing-custom-code-by-using-advanced-rules-in-amazon-eventbridge\u002F",{"text":55,"link":56},"Use Amazon EventBridge to Build Decoupled, Event-Driven Architectures","https:\u002F\u002Fserverlessland.com\u002Flearn\u002Feventbridge",{"from":39,"to":43},"patterns\u002Feventbridge-lambda-rust",{"headline":60,"text":61},"Testing",[62,63,64],"Use the AWS CLI to send a test event to EventBridge and observe the event delivered to the Lambda function:","1. Send an event to EventBridge: \u003Ccode>aws events put-events --entries file:\u002F\u002Fevent.json\u003C\u002Fcode>.","2. Retrieve the logs from the Lambda function: \u003Ccode>sam logs -n ENTER_YOUR_CONSUMER_FUNCTION_NAME\u003C\u002Fcode>.","sSZSyOU8XF7Pk7cBnEuNOVC4SqnHK8_NJxv1D0oI0TM",1779273335343]