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

xmpp.js / component #13

Open
sonnyp opened this issue Jan 30, 2020 · 6 comments
Open

xmpp.js / component #13

sonnyp opened this issue Jan 30, 2020 · 6 comments

Comments

@sonnyp
Copy link

sonnyp commented Jan 30, 2020

Hi,

maintainer / author of node-xmpp/xmpp.js here

Thanks for sharing RubDub, was pretty useful for me to understand how XMPP push worked.

node-xmpp is deprecated in favor of xmpp.js, I'm considering writing something very similar to RubDub using xmpp.js component

Would that be something you would be interested in? I'd be happy to share it if others are benefiting from or contributing to it.

Is there any specific reason why you used s2s instead of component connection?

If so, s2s is also on my roadmap for xmpp.js so that might be an option too.

@chrisballinger
Copy link
Member

chrisballinger commented Jan 30, 2020 via email

@sonnyp
Copy link
Author

sonnyp commented Jan 30, 2020

@chrisballinger ah of course, makes sense.

My use case is slightly different, we own and control the server of the app.

However, they are 2 options to make the component/service federation friendly:

  1. Use Metre

Pro: Works immediately
Con: Requires an additional service

  1. Add support for s2s on the component

Pro: Makes the service easier to use/deploy
Con: More work

Unfortunately xmpp.js does not support s2s yet but it should be fairly easy to do by taking inspiration from node-xmpp-server.

The current middleware API of xmpp.js allows clients, components and servers to share the same handlers so supporting both transports (component and s2s) is free of abstractions.

In any case I can give a small update here if/when we've made progress.

@sonnyp
Copy link
Author

sonnyp commented Jan 31, 2020

Actually for option 1. any XMPP server with component connections support can be used. If you don't need/want c2s you can just disable it.

@chrisballinger
Copy link
Member

If I feel motivated enough one of these days I might rewrite it in Rust, or switch to using this Prosody module: https://github.com/tmolitor-stud-tu/mod_push_appserver

@karimhm
Copy link

karimhm commented Jan 7, 2021

If I feel motivated enough one of these days I might rewrite it in Rust, or switch to using this Prosody module: https://github.com/tmolitor-stud-tu/mod_push_appserver

What about using Apache Vysper?

@karimhm
Copy link

karimhm commented Jan 7, 2021

Apache Vysper is a library that have a full featured XMPP server. Using it would simplify things because instead of having 2 servers, one that accept XMPP s2s connections and another one who forward the push events to the appropriate service (APNS, GCM, etc...) all this can be bundled inside a single server.

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

No branches or pull requests

3 participants