From mboxrd@z Thu Jan 1 00:00:00 1970 Delivered-To: chneukirchen@gmail.com Received: by 10.229.201.42 with SMTP id ey42csp13600qcb; Mon, 16 Apr 2012 00:40:07 -0700 (PDT) Received: by 10.236.193.101 with SMTP id j65mr9810833yhn.47.1334562007830; Mon, 16 Apr 2012 00:40:07 -0700 (PDT) Return-Path: Received: from mail-gy0-f190.google.com (mail-gy0-f190.google.com [209.85.160.190]) by mx.google.com with ESMTPS id z65si16198948yhl.91.2012.04.16.00.40.07 (version=TLSv1/SSLv3 cipher=OTHER); Mon, 16 Apr 2012 00:40:07 -0700 (PDT) Received-SPF: pass (google.com: domain of rack-devel+bncCNq3rdOKCBDVma_8BBoEgxz_JA@googlegroups.com designates 209.85.160.190 as permitted sender) client-ip=209.85.160.190; Authentication-Results: mx.google.com; spf=pass (google.com: domain of rack-devel+bncCNq3rdOKCBDVma_8BBoEgxz_JA@googlegroups.com designates 209.85.160.190 as permitted sender) smtp.mail=rack-devel+bncCNq3rdOKCBDVma_8BBoEgxz_JA@googlegroups.com; dkim=pass header.i=@googlegroups.com Received: by ghbg22 with SMTP id g22sf4385784ghb.17 for ; Mon, 16 Apr 2012 00:40:07 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=googlegroups.com; s=beta; h=x-beenthere:date:from:to:message-id:in-reply-to:references:subject :mime-version:x-original-sender:x-original-authentication-results :reply-to:precedence:mailing-list:list-id:x-google-group-id :list-post:list-help:list-archive:sender:list-subscribe :list-unsubscribe:content-type; bh=7y8ImXfUFAOgRN7IPb6IUu15zmMjQvV2TEg5qqSb8lA=; b=GCICtKV9PXQFJlxbu0wbOqC/mGiLHUf7g4QNsxCj2TPIeOPfGg+Yh+yhQeyzdZjVFt juQ0xx1um2B4L6KoqDBFbbZBBArnvNaR90/sokEWc81rIdum9+ehrYAduorSAPi9oLTk k5MNSB9i7hbH4Fp2dnPwsHE31xotUuPjd4kzE= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=x-beenthere:date:from:to:message-id:in-reply-to:references:subject :mime-version:x-original-sender:x-original-authentication-results :reply-to:precedence:mailing-list:list-id:x-google-group-id :list-post:list-help:list-archive:sender:list-subscribe :list-unsubscribe:content-type:x-gm-message-state; bh=7y8ImXfUFAOgRN7IPb6IUu15zmMjQvV2TEg5qqSb8lA=; b=fj3XDgUykAZwKt+qUC0gnHA679M8IMQxlwDdEZ9aTRPjj3vSY0Bqb9UDV2xY0r04NZ hGM9/Mz/ffLHD8AmAF3RZAZaUU0LjlsxD2RuGqIwigSBtPaZJsX3DGTb/DRXTdTr0TCA fjHQBGTQrktuww905pP4xLJPGYV1UwVnKjboryKGoihDe1ma3UQcvRIrEKrGVKwbvaNz MDjtl+M0nJT2blIVuCPUiwHxKAHOIiN+ZkafiRJTv9vDtl5Dbg85JUfmYGP5iDqwTfOs tnvl5b8oQ0+eg65sEPWVyBpgNc/dFj9wyN3go2kodGgvWwcpOQg8TQ0/XabNKkFiSZ9Y Kf3Q== Received: by 10.52.19.227 with SMTP id i3mr652377vde.18.1334562005351; Mon, 16 Apr 2012 00:40:05 -0700 (PDT) X-BeenThere: rack-devel@googlegroups.com Received: by 10.220.240.138 with SMTP id la10ls2319147vcb.1.gmail; Mon, 16 Apr 2012 00:40:03 -0700 (PDT) Received: by 10.52.31.42 with SMTP id x10mr652032vdh.7.1334562003660; Mon, 16 Apr 2012 00:40:03 -0700 (PDT) Date: Mon, 16 Apr 2012 00:40:03 -0700 (PDT) From: Konstantin Haase To: rack-devel@googlegroups.com Message-ID: <10094941.3386.1334562003291.JavaMail.geo-discussion-forums@vbiz13> In-Reply-To: <11588923.816.1334536867088.JavaMail.geo-discussion-forums@vbhy13> References: <11588923.816.1334536867088.JavaMail.geo-discussion-forums@vbhy13> Subject: Re: Rack asynchronous responses with async.callback MIME-Version: 1.0 X-Original-Sender: k.haase@finn.de X-Original-Authentication-Results: ls.google.com; spf=pass (google.com: domain of k.haase@finn.de designates internal as permitted sender) smtp.mail=k.haase@finn.de; dkim=pass header.i=@finn.de Reply-To: rack-devel@googlegroups.com Precedence: list Mailing-list: list rack-devel@googlegroups.com; contact rack-devel+owners@googlegroups.com List-ID: X-Google-Group-Id: 486215384060 List-Post: , List-Help: , List-Archive: Sender: rack-devel@googlegroups.com List-Subscribe: , List-Unsubscribe: , Content-Type: multipart/alternative; boundary="----=_Part_3385_33165723.1334562003290" X-Gm-Message-State: ALoCoQml1KsEkqH2ek7/vNIqDeED31Kp7ukSqHdwDauREi5/RXE9BMzcnRgTD+VdlXCe9QnfO6al ------=_Part_3385_33165723.1334562003290 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit Hi there! async.callback will never be part of the spec, that's true. But there will be a completely different spec for a successor of Rack, which will include first class support for async responses. Howerver, work is going rather slow on that front at the moment. At status quo, both Thin and Rainbows support just returning a Defferrable (or really, anything that responds to both callback and errback) without the need to an async response, rendering both the async handshake and async.callback unnecessary. Main issue is other middleware (esp. Rack::Lint) wrapping the body object in something that does not proxy those methods. Konstantin On Monday, April 16, 2012 2:41:07 AM UTC+2, pmahoney wrote: > > I am doing some work with JRuby that may need asynchronous HTTP support. > There doesn't seem to be much documentation about this online, so I did > some digging to see how the existing Rack async servers do things, and > wrote up some documentation for myself. I thought maybe others would find > it useful: > http://polycrystal.org/2012/04/15/asynchronous_responses_in_rack.html > > I also found some posts from a couple years ago implying that > 'async.callback' will never be a part of the Rack specification: > > > https://groups.google.com/forum/?fromgroups#!searchin/rack-devel/async/rack-devel/fu58paleLJg/frwK57QHNn4J > > Is this still the case? I must say I'm a bit disappointed by this > discovery, but I don't fully understand all the issues (in particular, my > documentation above ignores interaction with middleware). > ------=_Part_3385_33165723.1334562003290 Content-Type: text/html; charset=utf-8 Content-Transfer-Encoding: quoted-printable

Hi there!


async.= callback will never be part of the spec, that's true. But there will be a c= ompletely different spec for a successor of Rack, which will include first = class support for async responses. Howerver, work is going rather slow on t= hat front at the moment.


At stat= us quo, both Thin and Rainbows support just returning a Defferrable (or rea= lly, anything that responds to both callback and errback) without the need = to an async response, rendering both the async handshake and async.callback= unnecessary. Main issue is other middleware (esp. Rack::Lint) wrapping the= body object in something that does not proxy those methods.


Konstantin


On Monday, April 16, 2012 2:= 41:07 AM UTC+2, pmahoney wrote:
I am doing some work with JRuby that may need asynchronous HTTP support.&n= bsp; There doesn't seem to be much documentation about this online, so I di= d some digging to see how the existing Rack async servers do things, and wr= ote up some documentation for myself.  I thought maybe others would fi= nd it useful: http://polycrystal.org/2012/04/= 15/asynchronous_responses_in_rack.html

I also found some po= sts from a couple years ago implying that 'async.callback' will never be a = part of the Rack specification:

https://groups.google.com/forum/?fromgrou= ps#!searchin/rack-devel/async/rack-devel/fu58paleLJg/frwK57QHNn4J=

Is this still the case?  I must say I'm a bit disappointed= by this discovery, but I don't fully understand all the issues (in particu= lar, my documentation above ignores interaction with middleware).
------=_Part_3385_33165723.1334562003290--