unsent message queue #31

Closed
silvioster opened this Issue May 28, 2012 · 2 comments

Comments

Projects
None yet
2 participants

Can you add some kind of an external file structure for unsent messages, so if the problem is in configuration,
those messages can be re-sent when server is restarted with new configuration?
Or maybe an external resend_old.js script, which would drain the unsent queue, using the new config.
Main point: avoid silently dropping messages when sending is a problem.

Owner

eleith commented May 28, 2012

i like the idea.

however, is this not supported by the callback that currently exists on send?

server.send(headers, function(err, message) 
{
   if(err)
   {
      save_err_to_file(err);
      save_message_to_file(message);
   }
});

then you can make a resend script that just runs through each message in the file and call send on them one by one

let me know if you had something else in mind or if i misunderstood the request.

indeed, a file makes for a well behaved persistent message store.
will try it and see if the callbacks work as advertised, thanks !

silvioster closed this May 31, 2012

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment