re-updated PR to add callbacks to publisher connections; right now the publisher callbacks
are the same as the subscriber callbacks.
Thus, kamailio nats module can make use of nats lib reconnection(e.g.
natsOptions_SetRetryOnFailedConnect() function) and not implement a reconnect mechanism by
itself.
I will later make a new PR to make the parameters that control nats lib reconnect
mechanism, configurable:
```
natsOptions_SetMaxReconnect(opts, 10000); // how many times nats lib tries to
reconnect before giving up; -1 is forever if i'm not wrong
natsOptions_SetReconnectWait(opts, 2 * 1000); // the interval between reconnect
retries
```
Thanks,
Stefan
--
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/pull/2915#issuecomment-961885703