You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Is it (somewhat easily) possible to have different callbacks registered on different ports (e.g.because the implement different protocols) without threads?
And for this, one needs to (also) hook some buffer transfer logic as the daemon mustn't block.
So the basic idea is:
register various callbacks to various (different) ports
the callbacks are called if data is available. the callback functions buffer the data and handle it, if enough data is here (e.a. a complete request).
the response is constructed (non-blocking) and stored in some buffer (and is gradually transmitted).
Using threads just adds the complexity for internal explicit synchronization ....
The text was updated successfully, but these errors were encountered:
As you probably know already, libasyncd listens on single port per server. So for now, it probably needs multiple servers to listen on multiple ports. So my answer to the question is no.
I guess you'd like to run different type of requests on different ports but handles them all from single thread. If the type of requests on various ports can be determined from the input data rather than tcp port number, I guess you could consider port forwarding technique.
Is it (somewhat easily) possible to have different callbacks registered on different ports (e.g.because the implement different protocols) without threads?
And for this, one needs to (also) hook some buffer transfer logic as the daemon mustn't block.
So the basic idea is:
Using threads just adds the complexity for internal explicit synchronization ....
The text was updated successfully, but these errors were encountered: