On 21/02/17 20:23, Alan Conway wrote:
On Tue, 2017-02-21 at 17:24 +0000, Jeremy Gooch wrote:
Hi,
Last week, I asked a question about implementing durable consumers in
Python, via Proton.  That's working perfectly now but I also need to
support consumers written in Go, for which we're trying to use
Electron.  This time, it's not a missing container ID that's causing
me a headache but a missing subscription name.
I thought that the subscription name should be passed into the
Receiver via a LinkName, but the following code doesn't set the
subscription name (the Receiver gets messages fine but any messages
sent when off-line are lost).

 if r, err := c.Receiver(electron.Source("topic://"+TopicName),
electron.LinkName(SubscriptionName)); err == nil {

Should I be setting the subscription name somewhere else?
For info, I'm setting the container ID at instantiation time, via the
NewContainer function. I'm running a fresh build of Electron, inside
Docker, and using Go 1.7.
A working example for durable Go subscribers would be marvellous.
Thanks,
J.
Jeremy Gooch http://goochgooch.co.uk

I want to get you going with this - can you raise a proton JIRA for the
go-binding component at https://issues.apache.org/jira/ and include the
following:

- some info on the broker you are trying to subscribe to
- your python example code

I'm not very familiar with durable subscriptions (yet) but if I can
look at what your python client is doing it should be easy to figure
out what the equivalent thing would be in Go.

The source should have durability set to 2 (unsettled-state from terminus-durability) and expiry-policy to 'never'.


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to