Re: [hybi] Ping/Pong body (was Re: TSV-Directorate review of draft-ietf-hybi-thewebsocketprotocol-07)

Brian McKelvey <theturtle32@gmail.com> Wed, 18 May 2011 20:06 UTC

Return-Path: <theturtle32@gmail.com>
X-Original-To: hybi@ietfa.amsl.com
Delivered-To: hybi@ietfa.amsl.com
Received: from localhost (localhost [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id 8D28DE0778 for <hybi@ietfa.amsl.com>; Wed, 18 May 2011 13:06:04 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -2.202
X-Spam-Level:
X-Spam-Status: No, score=-2.202 tagged_above=-999 required=5 tests=[BAYES_00=-2.599, HTML_MESSAGE=0.001, MIME_QP_LONG_LINE=1.396, RCVD_IN_DNSWL_LOW=-1]
Received: from mail.ietf.org ([64.170.98.30]) by localhost (ietfa.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id hyBQzdXXo1Z3 for <hybi@ietfa.amsl.com>; Wed, 18 May 2011 13:06:03 -0700 (PDT)
Received: from mail-pw0-f44.google.com (mail-pw0-f44.google.com [209.85.160.44]) by ietfa.amsl.com (Postfix) with ESMTP id A4AA9E0771 for <hybi@ietf.org>; Wed, 18 May 2011 13:06:03 -0700 (PDT)
Received: by pwi5 with SMTP id 5so1232248pwi.31 for <hybi@ietf.org>; Wed, 18 May 2011 13:06:03 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:references:in-reply-to:mime-version :content-transfer-encoding:content-type:message-id:cc:x-mailer:from :subject:date:to; bh=F/OGf5f9mRpdXz/oEk5/tS43cA+jOifiWZHfth+3XFs=; b=YCHpWUtVEIExfs+r3TD/ROZKaXYlaV4HeMBVIaTTqxH2n/TGbQdbsxQ3u9xQzIZTvN ygvfKEuMc3LH+MTiAjVDAMPFKbTznJIy2vWT9vT8IGpIprGG0YB52TCrOnMJ0KiDaaY6 CJ6Aia0hps2Xzg5c6eOJ5WPv/FXNjQidxrqjk=
DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=references:in-reply-to:mime-version:content-transfer-encoding :content-type:message-id:cc:x-mailer:from:subject:date:to; b=s6udV+o1Sf0MFaKlwnqevUis/Z9emXa6gVh82wlBDNbGYKK+JZvZpJU4TbHiRxWcFB cfvxbXDSAXllfymsQvWDKPYp102LyqeBYOJtQf0QGzbhal0ngOlkNAxZf5OHB3k1Sdgq di5ELr1nAjU4uahwJWMqJGm4hX7R+Jbr6lf9c=
Received: by 10.68.20.38 with SMTP id k6mr3409400pbe.410.1305749163238; Wed, 18 May 2011 13:06:03 -0700 (PDT)
Received: from [10.0.109.211] (mobile-198-228-208-002.mycingular.net [198.228.208.2]) by mx.google.com with ESMTPS id k10sm1248661pbl.76.2011.05.18.13.05.59 (version=TLSv1/SSLv3 cipher=OTHER); Wed, 18 May 2011 13:06:01 -0700 (PDT)
References: <ED13A76FCE9E96498B049688227AEA292C6A81E4@TK5EX14MBXC206.redmond.corp.microsoft.com>
In-Reply-To: <ED13A76FCE9E96498B049688227AEA292C6A81E4@TK5EX14MBXC206.redmond.corp.microsoft.com>
Mime-Version: 1.0 (iPhone Mail 8F190)
Content-Transfer-Encoding: 7bit
Content-Type: multipart/alternative; boundary="Apple-Mail-5-1024443533"
Message-Id: <F390D8D1-335B-4595-93A2-0741DD693559@gmail.com>
X-Mailer: iPhone Mail (8F190)
From: Brian McKelvey <theturtle32@gmail.com>
Date: Wed, 18 May 2011 13:05:52 -0700
To: Piotr Kulaga <piotrku@microsoft.com>
Cc: "hybi@ietf.org" <hybi@ietf.org>, Gabriel Montenegro <Gabriel.Montenegro@microsoft.com>
Subject: Re: [hybi] Ping/Pong body (was Re: TSV-Directorate review of draft-ietf-hybi-thewebsocketprotocol-07)
X-BeenThere: hybi@ietf.org
X-Mailman-Version: 2.1.12
Precedence: list
List-Id: Server-Initiated HTTP <hybi.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/options/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: Wed, 18 May 2011 20:06:04 -0000

+1
I also see no purpose for correlating ping/pong data.  Or restricting the number of outstanding pings.  If you send 5 pings, you should expect 5 pongs, end of story.  The only real purpose for them is to see if the other end is still responsive, so send a ping and if you haven't gotten a pong after a certain user-decided timeout, close the connection.  It needs no further complication.

Brian


Sent from my iPhone

On May 18, 2011, at 12:07 PM, Piotr Kulaga <piotrku@microsoft.com> wrote:

> In my opinion, ping/pong frames should not carry application payload (foo and bar strings). If the payload is not well defined (i.e. reason, timestamp, etc.) there is no way the peer would understand how it should interpret the data. I would leave this problem the a protocol well-defined extensibility mechanism. If application wants to add payload to a ping/pong frame it should negotiate extension with the server and set a reserved bit on the frame. This way the basic protocol is simple and application can send/receive additional data if necessary (and negotiated).
> 
>  
> 
> I am ok with the 0x00 and 0x01 proposal.
> 
>  
> 
> From: hybi-bounces@ietf.org [mailto:hybi-bounces@ietf.org] On Behalf Of Gabriel Montenegro
> Sent: Tuesday, May 17, 2011 12:25 PM
> To: Takeshi Yoshino; hybi@ietf.org
> Subject: Re: [hybi] Ping/Pong body (was Re: TSV-Directorate review of draft-ietf-hybi-thewebsocketprotocol-07)
> 
>  
> 
> [As an individual]
> 
>  
> 
> I don’t think setting Ping/Pong as a platform for further applications is a good idea, for the same reasons that using ICMP as a platform for more intelligent applications is a good idea. Since ICMP does not follow the usual codepaths, any valid network characteristic measurements better not use, and they better use traffic that looks more closely like what an actual app would use (UDP, TCP). Similarly, I would expect Ping/Pong to not be treated as application traffic after network elements start being cognizant of Websockets. So the idea of using Ping/Pong for further apps doesn’t appear very convincing to me.
> 
>  
> 
> I’d much rather we kept Ping/Pong intentionally limited to its original purpose of just being a bare bones mechanism, and leave any other uses as proper extensions. 
> 
>  
> 
> The current text to say that only the last Ping need to be responded to discourages the peers from sending more than one, but it would be better to make it explicit that having more than one outstanding Ping (without its corresponding Pong) MUST NOT be done.
> 
>  
> 
> I think the 0x00 and 0x01 to distinguish unsolicited Pong is fine.
> 
>  
> 
> From: hybi-bounces@ietf.org [mailto:hybi-bounces@ietf.org] On Behalf Of Takeshi Yoshino
> Sent: Tuesday, May 17, 2011 04:03
> To: hybi@ietf.org
> Subject: Re: [hybi] Ping/Pong body (was Re: TSV-Directorate review of draft-ietf-hybi-thewebsocketprotocol-07)
> 
>  
> 
> Full body matching requirement has been introduced by http://tools.ietf.org/html/draft-ietf-hybi-thewebsocketprotocol-03 for both close and ping/pong. What was the original goal of this requirement for ping/pong? Is it still valid? Full body matching requirement for close frames has been thrown away after long discussion.
> 
>  
> 
> Now it looks like it's sufficient to have single boolean to indicate it's nop or reply in application data.
> 
>  
> 
> Here's relaxed version.
> 
>  
> 
> foo and bar mean "any string"
> 
>  
> 
> a) implement heartbeat by diverting Pong
> 
> - Ping would be "Ping foo"
> 
> - to reply to "Ping foo", send "Pong \x00 bar" (bar is foo by default)
> 
> - to send unsolicited Pong, send "Pong \x01 bar"
> 
>  
> 
> b) implement heartbeat by diverting Ping
> 
> - to send Normal-Ping, send "Ping \x00 foo"
> 
> - to send NOP-Ping, send "Ping \x01 foo"
> 
> - to reply "Ping \x00 foo", send "Pong bar" (bar is foo by default)
> 
> - just ignore "Ping \x01 foo" when received
> 
>  
> 
> to adopt Bruce's idea, change "(bar is foo by default)" to "(bar is foo + buz)". it implements echo and allows the receiver to send additional info.
> 
>  
> 
> I've removed unnecessary \x00 and \x01, but it's fine for me to keep them to keep framing symmetric.
> 
>  
> 
> Takeshi
> 
>  
> 
> _______________________________________________
> hybi mailing list
> hybi@ietf.org
> https://www.ietf.org/mailman/listinfo/hybi