eventual
eventual copied to clipboard
Feat: Pub/Sub at the service layer
Using #272
Move the service to service subscribe and publish behaviors to the service layer.
const serviceB: Service = service.from(...);
// put service B events into service A bus
serviceB.subscribe({ events: [] });
// subscribe directly to another service
subscription("forwardEvents", {
service: serviceB,
events: []
}, async () => {});
Not sure what you mean by service layer? Do you mean out of the cdk?