Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Question: Loggly timeoute #16

Closed
ghost opened this issue Jun 14, 2011 · 3 comments
Closed

Question: Loggly timeoute #16

ghost opened this issue Jun 14, 2011 · 3 comments

Comments

@ghost
Copy link

ghost commented Jun 14, 2011

If you have a callback waiting on a log action and a transport such as Loggly, what is the default timeout? Can this be configured so if Loggly is in a bad state (such as accepting the socket but hanging etc..) we dont wait for maximum/default socket timeout or one of those scenarios where the timeout doesnt get invoked (drip feeding a packet a minute etc..) we arent vunerable. Lets say we have this:

function handleUncaughtException(err) {
log.error('CRAP. in an unreliable state, lets get out of here QUICK and let supervisord,upstart, monit, god etc.. restart us')
log.info('exiting', function() {
   process.exit(0)
})
}
@ghost
Copy link
Author

ghost commented Jun 14, 2011

Also, Internally are the write queued to preserve ordering?, so in the above, I have a callback on the second log statement (but not the first) I can be assured that the first has successfully completed due the queue?

@ghost
Copy link
Author

ghost commented Jun 16, 2011

any update to this? are we guaranteed order? and more importantly can a log action stall forever and a day? if not take a look at the internals of log4j or log4net, a lot of hacky but appreciated magic

@indexzero
Copy link
Member

@mattopenstack Ordering is perserved in all of the winston transports. You can still use HTTP in your uncaughtException handler, but I think it would be wise to listen to some of the newer log events that will be coming out in HEAD.

I'll create a test for this and let you know my findings

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants