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

Improve Peer Awareness's metadata to be updatable #153

Closed
hackerwins opened this issue Feb 27, 2021 · 3 comments · Fixed by #217 or yorkie-team/yorkie-js-sdk#236
Closed

Improve Peer Awareness's metadata to be updatable #153

hackerwins opened this issue Feb 27, 2021 · 3 comments · Fixed by #217 or yorkie-team/yorkie-js-sdk#236
Assignees
Labels
enhancement 🌟 New feature or request

Comments

@hackerwins
Copy link
Member

What would you like to be added:

Realtime collaborative editors usually need to propagate volatile data, such as cursor position to other peers. This type of data needs to be propagated, but not stored.

For now, we implemented Peer Awareness to propagate the metadata of the client, but updates are not possible. We can cover this scenario by improving the Peer Awareness's metadata so that it can be updated.

Why is this needed:

The cost of storing data is expensive, so it is economical to propagate this type of data but not store it.

@hackerwins hackerwins added the enhancement 🌟 New feature or request label Feb 27, 2021
@dc7303
Copy link
Member

dc7303 commented Apr 5, 2021

@hackerwins could I try this issue?

@hackerwins
Copy link
Member Author

@dc7303 Yes. of course. This issue is more complicated than other issues, so writing a design document together would be nice.

@hackerwins
Copy link
Member Author

hackerwins commented Jul 17, 2021

Metadata for the purpose of sharing the status of peers who are watching the document together is stored in the SubscriptionMap as non-persistent data.

Since the client receives Peer's changes using Watch stream, it would be good to implement updating metadata using this stream as well. However, grpc-web does not support bi-directional streams now.

Therefore, we plan to temporarily update the metadata using Unary and remove it when the bidirectional stream is supported in grpc-web in the future.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement 🌟 New feature or request
Projects
None yet
2 participants