mirror of
https://github.com/christianselig/apollo-backend
synced 2024-11-21 19:37:41 +00:00
get a separate redis connection for the queue itself
This commit is contained in:
parent
a441d2723e
commit
61dc3b558f
1 changed files with 7 additions and 1 deletions
|
@ -56,13 +56,19 @@ func WorkerCmd(ctx context.Context) *cobra.Command {
|
|||
}
|
||||
defer db.Close()
|
||||
|
||||
qredis, err := cmdutil.NewRedisClient(ctx, 4)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
defer qredis.Close()
|
||||
|
||||
redis, err := cmdutil.NewRedisClient(ctx, consumers)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
defer redis.Close()
|
||||
|
||||
queue, err := cmdutil.NewQueueClient(logger, redis, "worker")
|
||||
queue, err := cmdutil.NewQueueClient(logger, qredis, "worker")
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue