frontpage.
newsnewestaskshowjobs

Made with ♥ by @iamnishanth

Open Source @Github

fp.

Open in hackernews

Modern messaging: Running your own XMPP server

https://www.codedge.de/posts/modern-messaging-running-your-own-xmpp-server
60•codedge•2h ago

Comments

mindcrime•1h ago
Good stuff. I run my own ejabberd server and it's been great. Installation is relatively straightforward, configuration isn't terribly convoluted, and it "just works" once up and running. Now my server doesn't have a ton of load on it, as it's used mainly for development / experimental purposes at the moment, so I can't say much about it's scalability or anything. But generally speaking, I installed it, did the initial setup, and other than adding/modifying users, I've rarely had to think about it since.
codedge•1h ago
Thanks! Same for me, it just works. Even regular updates run smoothly with ejabberd. I also do audio calls with it, and it is just a pleasant experience.
endre•1h ago
the only problem, as usual, is the network effect
tcfhgj•53m ago
what about

- single point of failure of rooms (server creating the chat room)

- media access via 3rd party servers

- gossiping encrypted message access across multiple devices

- encrypted audio-visual (group) communication

- good clients for iOS

- reliable server-side storage of messages (of all(!) chats)

AJ007•36m ago
Not my project, but I was hoping to see more stuff like https://prose.org/

As others have pointed out, for iOS Monal is good.

netsharc•48m ago
Maybe for friends and family? But then, if their phone might be compromised by the state...

And telling friends and family they need to setup a Jabber connection to talk you will make you "That guy/girl who...". And if the idea spreads, then talking to n people requires n accounts on n servers. At least Pidgin (last time I used it, which was last decade) supports such a configuration. I wonder if the mobile apps can do the same.

tcfhgj•33m ago
> And if the idea spreads, then talking to n people requires n accounts on n servers.

No, it doesn't.

XMPP is like E-Mail and Matrix a protocol which supports federation, i.e. a protocol which specifies how many service providers can cooperate, specifically forward messages to other service providers to reach their users.

sroerick•1h ago
I couldn't get iOS notifications to work properly when I tried to set up ejabberd.

Ended up using Hey, and it works pretty well, I guess, but a rails PWA is a little heavy duty for my taste, I would prefer XMPP

codedge•55m ago
I cannot say, that I have problems with it. I use monal on iOS and whenever someone mentions me, I get a notification.
Semaphor•57m ago
I’ve been running Prosody [0] for many years now. Don’t ask me why I chose it over another server. I used to have a jabber.org account that I used before that, already back when I could use jabber to communicate with gchat and facebook messenger users. Alas, nowadays, it’s just my wife I use it to communicate with :(

[0]: https://prosody.im/

netdur•48m ago
Any idea what kind of server we’d need to handle 40M users if it’s just text chat (no files or audio)?
reactordev•40m ago
If you’re running a single machine, you’ll be limited by the number of available ports. It’s a TCP limitation and nothing to do with XMPP. You’d need a cluster of XMPP servers to handle 40M users. Even for just text. Port limits are port limits.
VladVladikoff•26m ago
40M users don’t all simultaneously send messages, or does XMPP need to sustain an open connection to each user?
zajio1am•17m ago
Yes, you need to have open connection to receive messages.
wild_egg•25m ago
You're thinking of outbound port limits. Inbound connections all come in on the same port and there's no port-related limits there.

The real limits are going to be on hardware. If we want 40M concurrent connections, the server will need a few hundred to a few thousand gigabytes of memory.

aaronax•15m ago
You can put multiple IPs on a computer. (Or VMs, LXCs, etc. which would each get an IP)

Now what size of machine?

(I don't really care, and the original question does have a whiff of malicious intent, but scaling discussions are sometimes interesting...)

jerf•24m ago
Here's a blog post on scalability from the front page (well, sort of, see last paragraph): https://www.process-one.net/blog/ejabberd-massive-scalabilit... This includes not just textual claims about scalability but a lot of hooks you can use to followup on, like a reference to the Tsung benchmarking tool you can use. If you're asking about this for serious reasons, at this scale you're obviously running your own tests anyhow. You may also want to speak directly to Process One about this because it sounds like you're at a scale where you should probably be looking at paid support anyhow.

I'm not necessarily endorsing this, just giving it to you as some first stabs at answers and some ways to follow up.

If there's anyone reading this from the ejabberd project, note that the link to this on your front page under "Massively Scalable" is completely broken; that links to "blog.process-one.net" but that domain is completely dead, so it doesn't redirect to the link I gave above. (It's also part of why I posted this; my post here is not a "just read these docs" because I had to do non-trivial work to find them.) I had to pull that out of archive.org. Should probably check for any other links to that domain too.

pkulak•29m ago
Last time I tried this I couldn’t even find an iOS client that supported reactions. Hate on the complexity of Matrix all you like, but at least when you ask your family to use it, they get a modern experience and don’t feel like they’re giving up everything vs every other messenger they are used to.
bogwog•19m ago
I recently tried to move people over, and the iOS situation is bleak. It seems like notifications don't work at all in any app, which is a big problem for chat. Also, one of them (I think Siskin?) doesn't display sender name/avatar in group chats, so you can't tell who sent what.

There's also some weird behavior with how E2EE works, which is causing me problems in group chats. Initially it worked, but now people are unable to read some messages with errors like "this message was not encrypted for this device"

FWIW, everything works great on Android with the Conversations app, and also I admit I haven't really RTFM'd too much so it may be my fault as a lazy admin.

Edit: this is with ejabberd btw

zenmac•24m ago
One potential issue with XMPP is the default port is commonly blocked on public wifi.

There is an nginx-xmpp to proxy it, but it is archived. https://github.com/robn/nginx-xmpp

For that reason http based protocol just seems much easier on the network or something that can be easily reverse proxied without extensions will be easier to self-host and have wilder internet connection accessibility.