TELCU-25 Fallback to next address if current one fails - #818
TELCU-25 Fallback to next address if current one fails#818genseric-ghiro wants to merge 2 commits into
Conversation
There was a problem hiding this comment.
🔍 Devin Review: 2 flags
Not posted on this PR by your GitHub settings — view them in Devin Review. (Configure)
| WriteRequest(req *sip.Request, options ...sipgo.ClientRequestOption) error | ||
| // TransportLayer exposes sipgo's resolution and connection handling. It may | ||
| // be nil for clients that do not own one. | ||
| TransportLayer() *transport.Layer |
There was a problem hiding this comment.
I'm not sure yet if it's a good idea, but what if we expose a single method which is similar to the net.Resolver? Basically with a fake SIP client, regular resolver would do. And without one, sipgo will use it's logic for SRV, etc.
Or as an alternative, maybe the resolver in sipgo can be split, so that it doesn't rely on transport layer there. Just let it be a new interface and pass to sipgo. Or let sipgo create this special implementation internally in transport layer, and sip will create a second one here, if needed.
There was a problem hiding this comment.
Changed it to ResolveTargets() specifically
Summary