-
Notifications
You must be signed in to change notification settings - Fork 8
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat: publish pubsub events #1613
Conversation
matt2e
commented
May 31, 2024
- pipes module calls for publishing events through to the controller to the db
- fake implementation for tests not included
- added TopicEventKey. It will be generally useful I think, but also required for how db events are set up needing a "key" column
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice
return fmt.Errorf("failed to marshal event: %w", err) | ||
} | ||
_, err = client.PublishEvent(ctx, connect.NewRequest(&ftlv1.PublishEventRequest{ | ||
Topic: &schemapb.Ref{Module: reflection.Module(), Name: topic}, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What if you're publishing to a module that's from another module?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Good point, I've made it an issue and part of the pubsub epic
#1640
e92d316
to
0032a47
Compare
# Conflicts: # backend/protos/xyz/block/ftl/v1/ftl.pb.go
0032a47
to
19d3672
Compare
- pipes module calls for publishing events through to the controller to the db - fake implementation for tests not included - added TopicEventKey. It will be generally useful I think, but also required for how db events are set up needing a "key" column