Missing messages when user is offline

Skip to first unread message

Jordan Corbman

Jan 30, 2022, 10:55:40 AM1/30/22
to Faye users
Hi all,
I'm using the node.js client to create a connection to an existing faye client

import faye from 'faye';
const client = new faye.Client(config.FAYE_SERVER_URL);
faye.logger = window.console;
client.subscribe(`/user/${user?.id}/subscription`, (msg: string) => {
setLastMessageList([...lastMessageList, msg]);

Everything works great when the web browser is online, but I have been trying to test getting missed messages after coming back from offline
1. test to make sure a message is received while online
2. set my connection to "offline"
3. send 2 messages from the publisher
4. set myself back to "online"

At this point I expect to receive the missed messages but nothing happens, even if I send another message, I just get that new one but none of the missed ones.
Is there a piece I'm missing?

Jordan Corbman

Jan 31, 2022, 11:54:48 AM1/31/22
to Faye users
Alternatively, is there an event that fires on reconnect?

James Coglan

Jan 31, 2022, 8:19:45 PM1/31/22
to faye-...@googlegroups.com
Hi Jordan,

Would you be able to share the logs that the subscribing client emits
during this process?

Many thanks,
Reply all
Reply to author
0 new messages