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
[Feature request]: Collaboration support #401
Comments
We can use some public stun server: https://gist.github.com/mondain/b0ec1cf5f60ae726202e Google has some stun servers to use it:
I can use it on the web and if someone click on "Create session" we can show a warning to the user that they need to accept that a connection to the google servers will be created and they should accept to the privacy policy of them. What do you think? |
Added in 2.0.0-beta.16 |
How do I check it on https://preview.butterfly.linwood.dev/ ? |
Where is the blog post?
Where are connect and start buttons? I see Settings -> Experiments -> Collaboration switch, but don't see any effect of the switch on https://preview.butterfly.linwood.dev/. I also see empty "Connections" tab which states "Web not supported" (not sure why, sites typically can connect to arbitrary |
I post everything on my linwood homepage: https://www.linwood.dev/butterfly/2.0.0-beta.16 which you can find a link in Read more. |
Can Butterly use a dedicated backend (not another Butterfly app, just something permanently running on server) so that all Butterfly instances use client WebSocket conenctions, not acting as a WebSocket server? Will Web version of collaboration follow in some next version? Usage of WebSockets just naturally invites the feature to work in browsers. Is Butterfly protocol documented? Can it work e.g. over my WebSocket broadcaster? |
I will look at this. This looks like a good idea.
It already can be used as client. It only doesn't allow you to host the instance. This is a browser restriction that can't be fixed.
I will do this. But for now, it just sends json data around using websocket messages. It's just websockets, I didn't change anything at it. You can also use insomnia to see how these messages looks like. |
OK, now found it. First try (connecting to a silent WebSocket server that does not return any messages): it spins a loading indication for some time, then outputs "TimeoutException after 0:00:10.000000: Future not completed", seemingly without sending anything to the WebSocket. Is the difference between client and server solely in usage of WebSocket protocol (accept connection vs connect) and after the connection establishment they are symmetric? Or the distinction between server and client is deeper, e.g. only one of them acts as a source of truth and the other is just obeying commands? |
Indeed. But I think with some simple server-side helper (I can implement it) one of clients can effectively become a (logical) server. Physically it would still connect to |
TimeoutException means that it couldn't found the server. What did you use? ws://localhost should work fine if you are on the same computer and using two native butterfly apps (not web).
|
Using of helper server can be an optional feature, allowing additional connection method besides the truly decentralized one.
My own service, to discover the protocol. First time it failed to connect due to implicit port If you want, you can experiment with this URL (obfuscated):
F-Droid version of the android app is not yet up to date for this. I'll postpone further experiments until it is available. |
Sending binary WebSocket message Note that message content appears to be trimmed on the screenshot above (and it links to a 404 page, so no full version of the picture). |
The receiver is a generated connection id from the server and need to be send by the server. |
Is your feature request related to a problem? Please describe
To use the app with many people isn't very easy.
To support people that want to mock up ideas with the team, we need to support editing a document with multiple users.
Describe your feature request!
Add collaboration support including some connection types:
A global signaling server to allow collaboration support without extra server would be nice but I can't host it. Feel free to share ideas.
Additional context
This issue won't be implemented soon.
This is only to track the progress of it and to share some ideas.
Code of Conduct
The text was updated successfully, but these errors were encountered: