Closed HeavyHorst closed 7 years ago
I've added support for nats-streaming to the nats queue implementation. https://nats.io/documentation/streaming/nats-streaming-intro/
a new nats-streaming transport can easily be created with: New(WithStreaming("clusterID", "clientID"))
1 package main 2 3 import ( 4 "fmt" 5 6 vn "github.com/matryer/vice/queues/nats" 7 ) 8 9 func main() { 10 nt := vn.New(vn.WithStreaming("test-cluster", "test-id")) 11 defer nt.Stop() 12 13 rc := nt.Receive("test123") 14 15 for { 16 select { 17 case v := <-rc: 18 fmt.Println(string(v)) 19 case err := <-nt.ErrChan(): 20 panic(err) 21 } 22 } 23 }
@matryer @piotrrojek what do you think?
Awesome.
I've added support for nats-streaming to the nats queue implementation. https://nats.io/documentation/streaming/nats-streaming-intro/
a new nats-streaming transport can easily be created with: New(WithStreaming("clusterID", "clientID"))
@matryer @piotrrojek what do you think?