improvement: log errors to avoid ws throwing exceptions
improvement: log errors to avoid ws throwing exceptions

websocket npm module throws errors in its methods where callbacks are
optional but not passed as a param. To avoid this a logger helper method
is passed a callback so that if an error is raised, it gets logged.

scality/S3,scality/S3,scality/S3,scality/S3,scality/S3,scality/S3,scality/S3,scality/S3