Skip to content
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

Merged
merged 4 commits into from
Jun 4, 2024
Merged

feat: publish pubsub events #1613

merged 4 commits into from
Jun 4, 2024

Conversation

matt2e
Copy link
Collaborator

@matt2e 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

@matt2e matt2e requested a review from alecthomas as a code owner May 31, 2024 04:27
@matt2e matt2e requested review from a team and worstell and removed request for a team May 31, 2024 04:27
@ftl-robot ftl-robot mentioned this pull request May 31, 2024
@matt2e matt2e mentioned this pull request May 31, 2024
14 tasks
@matt2e matt2e linked an issue May 31, 2024 that may be closed by this pull request
Copy link
Collaborator

@alecthomas alecthomas left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice

go-runtime/internal/impl.go Outdated Show resolved Hide resolved
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},
Copy link
Collaborator

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?

Copy link
Collaborator Author

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

@matt2e matt2e force-pushed the matt2e/pubsub-publish branch from e92d316 to 0032a47 Compare June 4, 2024 03:17
matt2e added 4 commits June 4, 2024 13:18
# Conflicts:
#	backend/protos/xyz/block/ftl/v1/ftl.pb.go
@matt2e matt2e force-pushed the matt2e/pubsub-publish branch from 0032a47 to 19d3672 Compare June 4, 2024 03:18
@matt2e matt2e merged commit 502cf46 into main Jun 4, 2024
31 checks passed
@matt2e matt2e deleted the matt2e/pubsub-publish branch June 4, 2024 03:24
jonathanj-square pushed a commit that referenced this pull request Jun 4, 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
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

PubSub grpc changes
2 participants