comp.lang.ada
 help / color / mirror / Atom feed
From: "Dmitry A. Kazakov" <mailbox@dmitry-kazakov.de>
Subject: Re: ANN: Simple components v.4.3 released
Date: Sun, 23 Nov 2014 17:33:08 +0100
Date: 2014-11-23T17:33:08+01:00	[thread overview]
Message-ID: <11qdtipniibky$.153zsecim7qpq.dlg@40tude.net> (raw)
In-Reply-To: d5a2d07a-0e9a-4764-a755-9ed6e6109563@googlegroups.com

On Sun, 23 Nov 2014 07:39:38 -0800 (PST), David Botton wrote:

>> - WebSockets integrated into the HTTP server. Both half-duplex and
>> full-duplex operating modes are supported.
> 
> Is half duplex mode part of the Websocket standard or just an
> implementation method in your code?

WebSocket is full-duplex in the sense that it allows full-duplex exchange.
AFAIK that was one of the reasons to introduce it, because HTTP is
half-duplex. But it is up to the server and the client to decide if they
actually do.

> What would be the advantages or
> reasons for choosing one mode over the other?

The advantage of a half-duplex exchange is that the server need not to
start an extra task or tasks. Therefore the server need not to protect its
state from concurrent access, since only one task can access it at the
time.

Being half-duplex is a property of the higher-level protocol and ultimately
of the application.

If the application is an echo server, the server only responds to the
client. This can be handled in the half-duplex mode.

If the application is a game when the server sends messages to the client
on real-time events then it must be full-duplex. E.g. a Tetris-game
implementation will use a full-duplex exchange.

-- 
Regards,
Dmitry A. Kazakov
http://www.dmitry-kazakov.de

  reply	other threads:[~2014-11-23 16:33 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-11-23 10:20 ANN: Simple components v.4.3 released Dmitry A. Kazakov
2014-11-23 15:39 ` David Botton
2014-11-23 16:33   ` Dmitry A. Kazakov [this message]
2014-11-27 15:25     ` David Botton
replies disabled

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox