Frank
new EventBus(this, "MyBus", {
rules: {
myRule: {
eventPattern: { source: ["aws.codebuild"] },
targets: ["src/target1.main", "src/target2.main"],
},
},
});
sst.EventBus
currently supports Lambda and SQS as targets. If you need any other targets, drop me a line at anytime ✌️
More examples here - https://docs.serverless-stack.com/constructs/EventBusAdrián Mouly
08/04/2021, 8:10 AMimport { EventBus } from "@aws-cdk/aws-events";
, what’s the difference with this construct?thdxr
08/04/2021, 12:13 PMAshishkumar Pandey
08/04/2021, 1:04 PMFrank
defaultFunctionProps
for all Function targetsAdrián Mouly
08/04/2021, 5:26 PMFrank
EventBus
to get recreated, b/c the id for the EventBus in your CFN might change when you move things around.Adrián Mouly
08/04/2021, 5:30 PM