pass additional context for broker subscribe (#1105)
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
This commit is contained in:
parent
74e52bdb3e
commit
08fe30da46
4
grpc.go
4
grpc.go
@ -645,6 +645,10 @@ func (g *grpcServer) Register() error {
|
|||||||
opts = append(opts, broker.Queue(queue))
|
opts = append(opts, broker.Queue(queue))
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if cx := sb.Options().Context; cx != nil {
|
||||||
|
opts = append(opts, broker.SubscribeContext(cx))
|
||||||
|
}
|
||||||
|
|
||||||
if !sb.Options().AutoAck {
|
if !sb.Options().AutoAck {
|
||||||
opts = append(opts, broker.DisableAutoAck())
|
opts = append(opts, broker.DisableAutoAck())
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user