powered by Jive Software

Multi-Device Message Sync

Smack version 4.1

I’m building a Chat Application with Ejabberd XMPP backend server.
Sending & receiving messages is working fine.

I’m stuck at Message Sync feature.

  • User-A is logged in on 2 devices
  • User-A sends a message from Device-A
  • Same message should appear on Device-B too

Is there a direct function or flag or feature to achieve this or should this be programmed?

Pls point me in the right direction.

Thanks,
Sanjay

In XMPP this is called Message Carbons and Smack supports it. Can’t tell more as I’m not a dev.

Thanks @wroot
I have it enabled in Ejabberd.

odules:
mod_adhoc: {}
mod_admin_extra: {}
mod_announce: # recommends mod_adhoc
access: announce
mod_blocking: {} # requires mod_privacy
mod_caps: {}
mod_carboncopy:
db_type: internal
mod_client_state: {}
mod_configure: {} # requires mod_adhoc
mod_disco: {}
mod_echo: {}
mod_http_bind:
max_inactivity: 60
## mod_http_fileserver:

When I send messages from Smack (Android) my logins on other device do not receive it.
I’m clueless where should I even begin my debugging.
Any help here?

Thanks

Not sure if that would help, but that’s the original commit adding its support to Smack. https://github.com/igniterealtime/Smack/commit/33e2094fe4c47a3f3aa030b501d888e9ea63942d

Thats from Jan 2014.
I’m sure the current version 4.1 already has it and its matured.

Have you enabled carbos via the CarbonManager?

I think not. Let me verify this and come back.