You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Sep 19, 2024. It is now read-only.
I would try to implement the following exception policy in node-statsd:
exceptions "bubble up" into the app that uses this library
we don't log or print to console any errors ourself, it's the toplevel app that decides how to log/write to console.
we document which exceptions can be raised, and where.
I'm thinking of the following issues:
dns resolve (exception EADDRINFO)
host unreachable, connection refused (these don't give any exception, but that's ok: it's a udp socket anyway)
any other exception that might get raised?? I surely must be missing some, because at least require('dgram').createSocket('udp4') can raise errors, and socket.send() as well.
I'm new to node.js exception handling, so any input is welcome. For now I'm just tinkering and trying to find a workable solution, but I haven't figured it out yet. cc @msiebuhr