rack-devel archive mirror (unofficial) https://groups.google.com/group/rack-devel
 help / color / mirror / Atom feed
From: Eric Wong <normalperson@yhbt.net>
To: rack-devel@googlegroups.com
Subject: Re: CommonLogger (and Clogger) generates strange symbols in the response body
Date: Fri, 4 Sep 2009 12:42:22 -0700	[thread overview]
Message-ID: <20090904194222.GB29915@dcvr.yhbt.net> (raw)
In-Reply-To: <200909042120.47501.ibc@aliax.net>


Iñaki Baz Castillo <ibc@aliax.net> wrote:
> El Viernes, 4 de Septiembre de 2009, Eric Wong escribió:
> 
> > > > For performance reasons, the next version of Rack will instead log the
> > > > existing "Content-Length" header if one exists, and '-' if it doesn't;
> > > > skipping the wrapping of the body[1].
> > >
> > > Does it mean that with the next version I would get a non chunked
> > > transfer encoded body even if I use CommonLogger?
> > >
> > Yes, however you might want to load the Rack::ContentLength middleware
> > in front of CommonLogger to ensure the length can get logged correctly
> > as a result.
> 
> But if I use Clogger then I don't need to add Rack::ContentLength, right?

With $body_bytes_sent or $response_length, then no, you don't need to
load Rack::ContentLength in front of Clogger.  But you can avoid a
chunked body if you do load Rack::ContentLength.

> Thanks again.

No problem!

-- 
Eric Wong

  reply	other threads:[~2009-09-04 19:42 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-09-03 23:02 CommonLogger (and Clogger) generates strange symbols in the response body Iñaki Baz Castillo
2009-09-03 23:28 ` Iñaki Baz Castillo
2009-09-04  1:35 ` Eric Wong
2009-09-04 13:47   ` Iñaki Baz Castillo
2009-09-04 19:13     ` Eric Wong
2009-09-04 19:20       ` Iñaki Baz Castillo
2009-09-04 19:42         ` Eric Wong [this message]
2009-09-04 19:44           ` Iñaki Baz Castillo

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-list from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://groups.google.com/group/rack-devel

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20090904194222.GB29915@dcvr.yhbt.net \
    --to=rack-devel@googlegroups.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).