clogger RubyGem user+dev discussion/patches/pulls/bugs/help
 help / color / mirror / code / Atom feed
From: Eric Wong <>
Subject: [PATCH] README: document $env support for reading Rack env
Date: Thu, 14 Aug 2014 19:46:21 +0000	[thread overview]
Message-ID: <> (raw)
In-Reply-To: <>

This is more portable across different servers than Thread.current
in case of non-blocking servers which may be serving multiple
clients at once.  This is also faster than relying on $e{...} since
$e{...} uses eval and that is slow.
 README | 1 +
 1 file changed, 1 insertion(+)

diff --git a/README b/README
index e125b6f..74c8185 100644
--- a/README
+++ b/README
@@ -88,6 +88,7 @@ that receives a "<<" method:
 * $pid - process ID of the current process
 * $e{Thread.current} - Thread processing the request
 * $e{Actor.current} - Actor processing the request (Revactor or Rubinius)
+* $env{variable_name} - any Rack environment variable (e.g. rack.url_scheme)

           reply	other threads:[~2014-08-14 19:46 UTC|newest]

Thread overview: expand[flat|nested]  mbox.gz  Atom feed
 [parent not found: <>]

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-all from there: mbox

  Avoid top-posting and favor interleaved quoting:

  List information:

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

  git send-email \ \ \ \

* 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.
Code repositories for project(s) associated with this public inbox

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).