[hybi] Ping/Pong body (was Re: TSV-Directorate review of draft-ietf-hybi-thewebsocketprotocol-07)
Takeshi Yoshino <tyoshino@google.com> Fri, 13 May 2011 06:01 UTC
Return-Path: <tyoshino@google.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 6D72BE0658 for <hybi@ietfa.amsl.com>; Thu, 12 May 2011 23:01:19 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -105.976
X-Spam-Level:
X-Spam-Status: No, score=-105.976 tagged_above=-999 required=5 tests=[BAYES_00=-2.599, FM_FORGED_GMAIL=0.622, HTML_MESSAGE=0.001, RCVD_IN_DNSWL_MED=-4, USER_IN_WHITELIST=-100]
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 QzBkNEQyw8tw for <hybi@ietfa.amsl.com>; Thu, 12 May 2011 23:01:18 -0700 (PDT)
Received: from smtp-out.google.com (smtp-out.google.com [216.239.44.51]) by ietfa.amsl.com (Postfix) with ESMTP id 229B8E0657 for <hybi@ietf.org>; Thu, 12 May 2011 23:01:18 -0700 (PDT)
Received: from hpaq1.eem.corp.google.com (hpaq1.eem.corp.google.com [172.25.149.1]) by smtp-out.google.com with ESMTP id p4D61G73006897 for <hybi@ietf.org>; Thu, 12 May 2011 23:01:17 -0700
DKIM-Signature: v=1; a=rsa-sha1; c=relaxed/relaxed; d=google.com; s=beta; t=1305266477; bh=d+aFwIIsynuI9th/CH/1Fx47LQs=; h=MIME-Version:From:Date:Message-ID:Subject:To:Cc:Content-Type; b=LHnSAJ/M2lms9v94YUYYD4jwAGLaEfbmjq8vdeBMBVkHBRQhXAPmtCmrLtZrUWK2/ J0KiU8TkXkOM34PAVNzzg==
Received: from gye5 (gye5.prod.google.com [10.243.50.5]) by hpaq1.eem.corp.google.com with ESMTP id p4D6006U022882 (version=TLSv1/SSLv3 cipher=RC4-SHA bits=128 verify=NOT) for <hybi@ietf.org>; Thu, 12 May 2011 23:01:15 -0700
Received: by gye5 with SMTP id 5so879251gye.30 for <hybi@ietf.org>; Thu, 12 May 2011 23:01:15 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=beta; h=domainkey-signature:mime-version:from:date:message-id:subject:to:cc :content-type; bh=+5Wb8Ne2IY0eoEjlgDc9c49uE+uALQB8SS58baMTC2Y=; b=g6xhofOw14d47n2wW+94dXEBiTovJA/KCRtV0N851Lvj8nCT9oMTEcOTCDlc+8EyLR IN8onryE6kVUSSOKkzUQ==
DomainKey-Signature: a=rsa-sha1; c=nofws; d=google.com; s=beta; h=mime-version:from:date:message-id:subject:to:cc:content-type; b=TkWRKBVm5H4t6Yi2Yby7YZRJBwh1lypk2XMbQ5AQdeKfN2qktyYP0hVBgAAS+YgInV cPF6lBOi7sA1ewlLyUig==
Received: by 10.150.69.27 with SMTP id r27mr1079668yba.114.1305266475175; Thu, 12 May 2011 23:01:15 -0700 (PDT)
MIME-Version: 1.0
Received: by 10.150.50.13 with HTTP; Thu, 12 May 2011 23:00:55 -0700 (PDT)
From: Takeshi Yoshino <tyoshino@google.com>
Date: Fri, 13 May 2011 15:00:55 +0900
Message-ID: <BANLkTi=-ZD024mJ99P8acwZZOQqFkv+O0w@mail.gmail.com>
To: Greg Wilkins <gregw@intalio.com>
Content-Type: multipart/alternative; boundary="000e0cd5905a970f8504a3220849"
X-System-Of-Record: true
Cc: "hybi@ietf.org" <hybi@ietf.org>
Subject: [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: Fri, 13 May 2011 06:01:19 -0000
(Detaching from TSV review thread) Greg, I see. Sounds ok to use assignment like that. As you said "it's over reliable transport" in reply to my message, we don't need to use sequence number as ping/ICMP does since there's no loss or reorder. Maybe just \x00 (reply to ping) or \x01 (unsolicited) would be fine. Basically, I don't think it's good idea to make it duty of implementor or service designer to choose body for Ping and unsolicited Pong properly. That should be covered by the spec to reduce what to be cared by user if possible. What do you think about specifying some rule for the body strings to be used for Ping and unsolicited Pong in the spec? - application data of Ping must start with \x00 - application data of in-reply-to Pong MUST have the same body as the received Ping - application data of unsolicited Pong must start with \x01 I think the following is clearer. - when received Normal-Ping (Ping with its application data starting with \x00), reply with Pong with the same body - when received NOP-Ping (Ping with its application data starting with \x01), just ignore it On Fri, May 13, 2011 at 07:29, Greg Wilkins <gregw@intalio.com> wrote: > Takeshi, > > what I have seen before is the use of sequence numbers where the > client side uses even and the server side uses odd, so can tell by the > seq number in a pong where it was generated and thus tell if it is a > response or unsolicited. > > cheers > > > On 13 May 2011 04:36, Takeshi Yoshino <tyoshino@google.com> wrote: > >> Obviously there is a chance that a unsolicited pong matches a ping, > >> but some careful design of payloads can easily fix that. > > > > I see. Coordinating body value assignment so that unsolicited one and > reply > > one don't conflict each other (e.g. "ABC" and "XYZ" as you said) is one > > possible solution. > > This should be discussed well when we add some keep alive feature to > browser > > that sends Ping to the server. If we prepare some API for JavaScript to > tell > > the browser what string to use for Ping, service designers may coordinate > > assignment by themselves. If we don't, we should reserve some string to > be > > used for Ping/unsolicited Pong by browsers to avoid collision. > > ---- > > Isn't it simpler to reserve some string, say "NOOP" (or "\x00" to save > > bytes), for Ping body and require endpoints to ignore such Ping rather > than > > diverting Pong for heartbeat? > > Thanks, > > Takeshi >
- [hybi] Ping/Pong body (was Re: TSV-Directorate re… Takeshi Yoshino
- Re: [hybi] Ping/Pong body (was Re: TSV-Directorat… Salvatore Loreto
- Re: [hybi] Ping/Pong body (was Re: TSV-Directorat… Bruce Atherton
- Re: [hybi] Ping/Pong body (was Re: TSV-Directorat… Takeshi Yoshino
- Re: [hybi] Ping/Pong body (was Re: TSV-Directorat… Gabriel Montenegro
- Re: [hybi] Ping/Pong body (was Re: TSV-Directorat… Piotr Kulaga
- Re: [hybi] Ping/Pong body (was Re: TSV-Directorat… Brian McKelvey
- Re: [hybi] Ping/Pong body (was Re: TSV-Directorat… Piotr Kulaga
- Re: [hybi] Ping/Pong body (was Re: TSV-Directorat… Greg Wilkins
- Re: [hybi] Ping/Pong body (was Re: TSV-Directorat… Brian McKelvey
- Re: [hybi] Ping/Pong body (was Re: TSV-Directorat… Patrick McManus
- Re: [hybi] Ping/Pong body (was Re: TSV-Directorat… Jamie Lokier
- Re: [hybi] Ping/Pong body (was Re: TSV-Directorat… Gabriel Montenegro
- Re: [hybi] Ping/Pong body (was Re: TSV-Directorat… Salvatore Loreto
- Re: [hybi] Ping/Pong body (was Re: TSV-Directorat… Bruce Atherton
- Re: [hybi] Ping/Pong body (was Re: TSV-Directorat… Pieter Hintjens
- Re: [hybi] Ping/Pong body (was Re: TSV-Directorat… Jamie Lokier
- Re: [hybi] Ping/Pong body (was Re: TSV-Directorat… Jamie Lokier
- Re: [hybi] Ping/Pong body (was Re: TSV-Directorat… Pieter Hintjens
- Re: [hybi] Ping/Pong body (was Re: TSV-Directorat… Bruce Atherton
- Re: [hybi] Ping/Pong body (was Re: TSV-Directorat… Takeshi Yoshino
- Re: [hybi] Ping/Pong body (was Re: TSV-Directorat… Patrick McManus
- Re: [hybi] Ping/Pong body (was Re: TSV-Directorat… Takeshi Yoshino
- Re: [hybi] Ping/Pong body (was Re: TSV-Directorat… Takeshi Yoshino
- Re: [hybi] Ping/Pong body (was Re: TSV-Directorat… Patrick McManus
- Re: [hybi] Ping/Pong body (was Re: TSV-Directorat… Willy Tarreau
- Re: [hybi] Ping/Pong body (was Re: TSV-Directorat… Takeshi Yoshino
- Re: [hybi] Ping/Pong body (was Re: TSV-Directorat… Patrick McManus
- Re: [hybi] Ping/Pong body (was Re: TSV-Directorat… Brian McKelvey
- Re: [hybi] Ping/Pong body (was Re: TSV-Directorat… Greg Wilkins
- Re: [hybi] Ping/Pong body (was Re: TSV-Directorat… Takeshi Yoshino
- Re: [hybi] Ping/Pong body (was Re: TSV-Directorat… Gabriel Montenegro