0
votes

I need "normal" push notifications for my mobile chat users, as is expected of any chat today.

I read the guide on MUC/SUB an implemented my rooms that way, so my clients are subscribed to room messages. mod_muc rooms are configured as peristent and allow_subscriptions... and working as expected, clients receive messages when online without needing to join room.

  • I enabled mod_push to catch messages intended for offline users

  • I am using my own XMPP component "AppServer" to handle offline messages (a fork of: https://git.happy-dev.fr/startinblox/prosody/xmpp-notification-component)

  • Clients subscibe to push notifications on my AppServer (using IQ-set-enable stanza as described in XEP-0357)

  • My AppServer correctly receives messages that are sent directly to the full JID of a subscribed and offline user, as expected. So i guess i have in general understood implemented and configured the appServer component correctly. (however i dont know why a full JID is required)

  • My AppServer however does not receive messages that are sent to MUC rooms for users that are subscribed to both muc and push and offline.

What am i missing? Am i correct in understanding that MUC/SUB should support mod_push out of the box? Why are my MUC messages not being pushed to subscribed users? Why do i need full JID with resource for push notifications to work?

(Using ejabberd 20.4.0)

1

1 Answers

0
votes

My AppServer correctly receives messages that are sent directly to the full JID of a subscribed and offline user, as expected. So i guess i have in general understood implemented and configured the appServer component correctly. (however i dont know why a full JID is required)

I have a doubt about the concepts here.

When an account is registered, it has as bare JID: user1@localhost

When a client starts a XMPP session with resource "tka" in that account, the full JID is: user1@localhost/tka

If an account (user1@localhost) doesn't have any online session (no client is connected with no resource), then the concept of "full jid" doesn't make sense:

When no client is connected, what resource do you send the message to?

My AppServer however does not receive messages that are sent to MUC rooms for users that are subscribed to both muc and push and offline.

When an account is subscribed using MUCSUB to messages in a room, and that account has no sessions, and a message is sent to the room... then MUCSUB sends an offline message to that user, and I imagine that should trigger a Push.

Can you check if the offline message is really stored for that account in the "offline" table in your database?