[Click] Question about socket

Beyers Cronje bcronje at gmail.com
Wed Dec 16 14:27:40 EST 2009


Hi Roberto,

Socket is opened on Click initialization and closed on cleanup, so yes
elements in "my elements" will use the already open socket.

I run Socket in server mode and can confirm the connection from the remote
client stays open and is used by elements in my configuration.

Beyers

On Wed, Dec 16, 2009 at 6:24 PM, Roberto Riggio <
roberto.riggio at create-net.org> wrote:

> Hi,
>
> I have some questions about the Socket element.
>
> Let's say that I want to implement a persistent TCP connection between
> a click process and another application. The click configurations should be
> something like this:
>
> s::Socket (TCP, 0.0.0.0, 9999)->... My elements -> s;
>
> So i can process the packet coming from the client and send an answer.
>
> However it is not clear to me if the socket is kept open so if in "my
> elements"
> there is an element that periodically generates a packet, this packet is
> sent
> over the previously open socket.
>
> R.
> _______________________________________________
> click mailing list
> click at amsterdam.lcs.mit.edu
> https://amsterdam.lcs.mit.edu/mailman/listinfo/click
>


More information about the click mailing list