Created by: tebriel
Overrides the options.redis settings for clientName for creating a new client
When specifying createClient
as part of the Bull.QueueOptions
there is no way to know the Queue
's name (from queue.clientName
).
When calling queue.process
, this.setHandler
is invoked which calls setWorkerName
however this only does so on the client
, and not on the eclient
(subscriber
) nor on the bclient
.
I opted to hand the clientName
via connectionName
in the redis options (overriding the defaults passed in to the QueueOptions
to allow the createClient
function to determine what to do with these options.
Additionally I slightly tweaked the example to note that this value is present and to better showcase how to use the createClient
function.