Re: [hybi] Are keep-alives necessary? Was: Re: NAT reset recovery? Was: Extensibility mechanisms?

Hugh Winkler <hugh.winkler@wellstorm.com> Tue, 20 April 2010 21:04 UTC

Return-Path: <hugh.winkler@wellstorm.com>
X-Original-To: hybi@core3.amsl.com
Delivered-To: hybi@core3.amsl.com
Received: from localhost (localhost [127.0.0.1]) by core3.amsl.com (Postfix) with ESMTP id F061E3A6BC9 for <hybi@core3.amsl.com>; Tue, 20 Apr 2010 14:04:50 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -0.488
X-Spam-Level:
X-Spam-Status: No, score=-0.488 tagged_above=-999 required=5 tests=[BAYES_05=-1.11, FM_FORGED_GMAIL=0.622]
Received: from mail.ietf.org ([64.170.98.32]) by localhost (core3.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id fdkPrX77-75z for <hybi@core3.amsl.com>; Tue, 20 Apr 2010 14:04:50 -0700 (PDT)
Received: from mxout-07.mxes.net (mxout-07.mxes.net [216.86.168.182]) by core3.amsl.com (Postfix) with ESMTP id 1B2EF3A6AE3 for <hybi@ietf.org>; Tue, 20 Apr 2010 14:04:49 -0700 (PDT)
Received: from mail-gw0-f44.google.com (unknown [74.125.83.44]) (using TLSv1 with cipher RC4-MD5 (128/128 bits)) (No client certificate requested) by smtp.mxes.net (Postfix) with ESMTPSA id 0EBB922E254 for <hybi@ietf.org>; Tue, 20 Apr 2010 17:04:34 -0400 (EDT)
Received: by gwj20 with SMTP id 20so1174794gwj.31 for <hybi@ietf.org>; Tue, 20 Apr 2010 14:04:33 -0700 (PDT)
MIME-Version: 1.0
Received: by 10.151.49.20 with HTTP; Tue, 20 Apr 2010 14:04:32 -0700 (PDT)
In-Reply-To: <1707962B-4054-4062-854A-6E9E676E90A9@d2dx.com>
References: <s2t927441b31004200917x1d05b3f1jbbe5bb9e270f1c38@mail.gmail.com> <1707962B-4054-4062-854A-6E9E676E90A9@d2dx.com>
Date: Tue, 20 Apr 2010 16:04:32 -0500
Received: by 10.150.253.11 with SMTP id a11mr7981936ybi.245.1271797472752; Tue, 20 Apr 2010 14:04:32 -0700 (PDT)
Message-ID: <p2w927441b31004201404hb2de698dyf54948e6d37414e2@mail.gmail.com>
From: Hugh Winkler <hugh.winkler@wellstorm.com>
To: Vladimir Katardjiev <vladimir@d2dx.com>
Content-Type: text/plain; charset="ISO-8859-1"
Content-Transfer-Encoding: quoted-printable
Cc: Hybi <hybi@ietf.org>
Subject: Re: [hybi] Are keep-alives necessary? Was: Re: NAT reset recovery? Was: Extensibility mechanisms?
X-BeenThere: hybi@ietf.org
X-Mailman-Version: 2.1.9
Precedence: list
List-Id: Server-Initiated HTTP <hybi.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/listinfo/hybi>, <mailto:hybi-request@ietf.org?subject=unsubscribe>
List-Archive: <http://www.ietf.org/mail-archive/web/hybi>
List-Post: <mailto:hybi@ietf.org>
List-Help: <mailto:hybi-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/hybi>, <mailto:hybi-request@ietf.org?subject=subscribe>
X-List-Received-Date: Tue, 20 Apr 2010 21:04:51 -0000

On Tue, Apr 20, 2010 at 11:39 AM, Vladimir Katardjiev <vladimir@d2dx.com> wrote:

> All technically correct, and completely accurate if we assume the only reason the WebSocket API would be used would be to send() data to a remote endpoint. But websocket is a bidirectional API, meaning it should both send and receive messages. Going back to the tic tac toe example, my side (client) is waiting for the other side (server) to make their turn, there will never come a point in time at which my side should send a message (it's not my turn). There's also no reasonable expectation of when the other side is going to make their move (=send me a message). And even if the remote side discovers the connection is dropped, it can't do anything because I'm behind a NAT.
> So either the WS realisation would need to open a new TCP connection every 5 minutes of no traffic (just in case the old one died, because there's no way to recognise that), or it would need some form of message that would trigger traffic on the channel thus making it clear it's still open. Otherwise the WSAPI won't be able to receive messages from the remote endpoint at arbitrary time points.


Yes, duh. I don't know what I was thinking. That's the most important
case: replacing hanging GET. Of course it's necessary to keep that TCP
connection alive so I can receive the message from the server, my
mistake.


Hugh