| 613 | } |
| 614 | |
| 615 | inline void Schedule(const TMessage& msg, const TNotifyHandleRef& hndl) { |
| 616 | TParsedLocation loc(msg.Addr); |
| 617 | const TNetworkAddress* addr = &CachedThrResolve(TResolveInfo(loc.Host, loc.GetPort()))->Addr; |
| 618 | |
| 619 | for (TNetworkAddress::TIterator ai = addr->Begin(); ai != addr->End(); ++ai) { |
| 620 | TProto* proto = Find(ai->ai_family); |
| 621 | |
| 622 | if (proto) { |
| 623 | TRequestPacket rp(ToString(loc.Service), msg.Data); |
| 624 | TRequestDescrRef rd(new TRequestDescr(rp.Guid, hndl, msg)); |
| 625 | IRemoteAddrPtr raddr(new TAddrInfo(&*ai)); |
| 626 | TPacketRef p(new TPacket(rp, std::move(raddr))); |
| 627 | |
| 628 | proto->Schedule(rd, p); |
| 629 | |
| 630 | return; |
| 631 | } |
| 632 | } |
| 633 | |
| 634 | ythrow yexception() << "unsupported protocol family"; |
| 635 | } |
| 636 | |
| 637 | private: |
| 638 | inline void Init(IOnRequest* cb, TSockets& s) { |
nothing calls this directly
no test coverage detected