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

PubSub #1597

Closed
13 of 14 tasks
matt2e opened this issue May 29, 2024 · 8 comments
Closed
13 of 14 tasks

PubSub #1597

matt2e opened this issue May 29, 2024 · 8 comments
Labels
epic An umbrella topic

Comments

@matt2e matt2e added the epic An umbrella topic label May 29, 2024
@github-actions github-actions bot added the triage Issue needs triaging label May 29, 2024
@ftl-robot ftl-robot mentioned this issue May 29, 2024
@matt2e matt2e removed the triage Issue needs triaging label May 29, 2024
@matt2e
Copy link
Collaborator Author

matt2e commented May 30, 2024

Case to handle:

  • Deployment registers a topic with event A
  • Updated deployment happens, now with the topic defined with event B
  • ... what should happen?

@matt2e
Copy link
Collaborator Author

matt2e commented May 30, 2024

Case to handle:

  • Deployment registers a subscription
    • Some events are consumed by the subscription. Curser points to event row A
  • Replace deployment, now without the subscription
    • Quick thoughts: Does that subscription row just sit there untouched? Should we be deleting it? Will this work ok when there are multiple versions of a module? Don't worry about that for now?
  • ... Wait a week
  • Replace deployment again, now with a subscription with the same name as the old subscription
  • ... is the cursor still pointing to a week ago?

@matt2e
Copy link
Collaborator Author

matt2e commented May 30, 2024

Thing to think about:
When a module is updated and removes a topic, should the topic just sit there?

  • The module won't be able to publish any new events anyway...
  • It allows time for subscribers to catch up to the remaining unhandled events, which is good

@matt2e
Copy link
Collaborator Author

matt2e commented May 31, 2024

Case to handle:

  • Can not publish to external module's topic

@matt2e
Copy link
Collaborator Author

matt2e commented May 31, 2024

Queries are doing a lot of joins. Should we denormalize module name into topics?

@alecthomas
Copy link
Collaborator

For now we won't worry about catching any of these cases, we want a holistic approach to managing schema changes across FTL.

@alecthomas
Copy link
Collaborator

Queries are doing a lot of joins. Should we denormalize module name into topics?

Yeah, we do it in other places, so if you think it's necessary go for it.

@alecthomas
Copy link
Collaborator

I'm going to close this out. We can revisit later if we decide to do batching. Nice work Matt.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
epic An umbrella topic
Projects
None yet
Development

No branches or pull requests

2 participants