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

Type system guards on message creation #4

Open
fjarri opened this issue Oct 12, 2024 · 0 comments
Open

Type system guards on message creation #4

fjarri opened this issue Oct 12, 2024 · 0 comments
Labels
API Involves backwards-incompatible changes of the public API enhancement New feature or request
Milestone

Comments

@fjarri
Copy link
Member

fjarri commented Oct 12, 2024

Currently Session code needs to remember to

  • get the list of message destinations from a new Round,
  • create an echo broadcast
  • create direct messages to the destinations from the above list.

This is error-prone. Can we make it stricter? For example, when finalize() returns the next round, it can instead return a structure with the echo broadcast (if any) and message destinations already present there. Also, instead of message destinations we may return "message factories", each of which can be consumed to generate a message.

@fjarri fjarri added the enhancement New feature or request label Oct 12, 2024
@fjarri fjarri added the API Involves backwards-incompatible changes of the public API label Oct 12, 2024
@fjarri fjarri added this to the v1.0.0 milestone Oct 14, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
API Involves backwards-incompatible changes of the public API enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant