ChangeLog from http://bogomips.org/clogger.git commit a1c4506c011b071a9aef0145827b51ffe4d5cd60 Author: Eric Wong Date: Mon Dec 5 18:52:21 2011 -0800 clogger 1.1.0 - more escaping! This release fixes potential vulnerabilities when escape sequences are viewed in certain terminals. The 0x7F-0xFF byte range is escaped to match behavior of nginx 1.0.9+, as some character sets may have escape characters in that range. $cookie_* values are now escaped to be consistent with the behavior of the $http_cookie value. All users of $cookie_* in their log format must upgrade (of course there may be no Clogger users other than myself, and I don't use $cookie_*) commit 3a47f23e74a681339f74b21b94241dcfe9542472 Author: Eric Wong Date: Mon Dec 5 17:59:40 2011 -0800 escape individual cookie values from $cookie_* These values are untrusted, so if any client sends them to us we must escape them. commit ba72b12030864a05fc88bc94a3b699971cc70b0a Author: Eric Wong Date: Mon Dec 5 17:53:43 2011 -0800 escape bytes in the 0x7F-0xFF range, too This matches the behavior of nginx 1.0.9 commit 9f6aece724a79d5a19723a781766fdb1725ddcf3 Author: Eric Wong Date: Fri Jul 22 09:49:22 2011 -0700 use librelist.org for mailing list address It's clearer that we have zero commercial intent when using a non-profit .org domain for the mailing list. commit 99d9141f5d57e286c8205b13c41dde34b4bca16d Author: Eric Wong Date: Wed Jul 20 14:01:56 2011 -0700 ext: note we rely on GVL for reentrancy detection Nothing wrong with the GVL in Ruby 1.9.3; but we'll need to modify our code if it's removed for C extensions. commit d6328a6f31f97bded75a4e2aba73f85366215924 Author: Eric Wong Date: Wed Jun 22 14:43:16 2011 -0700 clogger 1.0.1 - portability fixes Minor portability fixes noticed on some systems. There is a minor license change, it is now explicitly LGPLv2.1 and LGPLv3 and later versions at the project leader's discretion. It is no longer LGPLv2.1+, so it doesn't give a blank check to the FSF to change the license on us. commit 7e3694c6de13fc3d635473d3150412cbda287e75 Author: Eric Wong Date: Wed Jun 22 13:55:25 2011 -0700 ext: fix portability defines for some installs Some Ruby installs muck up headers/#defines and cause weirdness. We now explicitly define _BSD_SOURCE and include #stdio.h commit 5979a9b113815721140058d021ecfffc5c529de4 Author: Eric Wong Date: Wed May 11 18:54:47 2011 -0700 tests: add full URL example Could be useful for some folks. commit bcb9fb819a8753863952302d71215152cc715935 Author: Eric Wong Date: Tue Apr 26 16:24:18 2011 -0700 change from LGPLv2.1+ to LGPLv2.1 + LGPLv3 LGPLv4 could be completely different, so we won't give the FSF a blank check to force it upon us. commit edd2bd2b3baa9cca40dcd8717b338076f09d0807 Author: Eric Wong Date: Thu Apr 21 04:02:57 2011 +0000 clogger 1.0.0 - \o/ * $time_iso8601 added for nginx compatibility * $time_local (without strftime-options) is now locale-independent There's also a minor usability tweak that allows Symbols to be specified as the :format argument, so config.ru can be shortened: before (continues to work with 1.0.0): use Clogger, :format => Clogger::Format::Rack_1_0 after: use Clogger, :format => :Rack_1_0 commit b7459a293c1b3efe3f5be4201620af885bb8122e Author: Eric Wong Date: Tue Apr 19 00:33:48 2011 +0000 README: stop promoting strftime()-compatible formats strftime() isn't locale-independent, so it can lead to inconsistencies in logs. commit 0a2cb5093f7fbba370fd9b6caaf308139220b47b Author: Eric Wong Date: Tue Apr 19 00:28:08 2011 +0000 $time_local and $time_utc are locale-independent This doesn't apply to people that use strftime()-formats, but that's a minority. commit 8303d477a13a63e6b28666e04b0c62886feae48e Author: Eric Wong Date: Sat Apr 16 02:03:34 2011 +0000 add support for $time_iso8601 format This appeared in nginx 0.9.6 commit a84b132f51bd011f3c3441c28d23ff9c1029a9f8 Author: Eric Wong Date: Mon Mar 21 14:10:07 2011 -0700 extconf: unnecessary dir_config statement Braindamage from back in the day when I didn't understand mkmf commit b086541910c5797732886c7f0d276871f2775d08 Author: Eric Wong Date: Wed Mar 16 16:35:40 2011 -0700 :format may be a Symbol for less typing This allows using: use Clogger, :format => :Rack_1_0 Instead of: use Clogger, :format => Clogger::Format::Rack_1_0 commit 9102cb13084980f1899b488627b354fc16bc38eb Author: Eric Wong Date: Wed Mar 16 14:56:19 2011 -0700 fix documentation of Clogger.new for :path Oops commit 21be17fd1307e1e194a3089f0e3317a5948088e7 Author: Eric Wong Date: Tue Mar 15 19:21:02 2011 +0000 README: misspelled "discusssion" commit af8a20dedc47ab001fbe5072d40967c4cf8545ea Author: Eric Wong Date: Tue Mar 15 11:51:28 2011 +0000 clogger 0.9.0 - configurable logging for Rack Under 1.9, we always release the GVL for filesystem operations now to avoid worst case scenarios. This may hurt performance for some folks with bad locking implementations and extremely fast filesystems. A couple of minor cleanups, too. commit 60cde0ff6147211ae09178bb62a82374241514e0 Author: Eric Wong Date: Tue Mar 15 11:49:54 2011 +0000 clogger: remove VERSION constant People shouldn't care, there have been no backwards-incompatible changes in the UI and we're not a library people write code against. commit 00864a06a860c31f0b139a543f07d94dd37c8a59 Author: Eric Wong Date: Sun Mar 13 09:54:37 2011 +0000 avoid potential RString -> C-string conversions Unlikely, but it may make a difference somewhere... commit bd8334f5f3e901a3d54d3421dffb0db8efa024a9 Author: Eric Wong Date: Sun Mar 13 09:48:18 2011 +0000 release GVL for filesystem operations While local filesystems are usually very fast, we are pessimistic and should prepare for worst-case scenarios. This can use rb_thread_io_blocking_region() under Ruby 1.9.3dev. commit c55831a01dab548fdf9eccb7529396f6582c6637 Author: Eric Wong Date: Sun Mar 13 09:43:50 2011 +0000 ext: ensure path is a valid C string Unlikely, but some app could pass '\0' into us commit ecd7877787a156e476e31b7108e7b9f15f7523d8 Author: Eric Wong Date: Sun Mar 13 06:03:57 2011 +0000 update pkg.mk commit 3f1832a9bb149cb189371357d06000917b6098eb Author: Eric Wong Date: Fri Mar 4 09:20:38 2011 +0000 doc: bogomips.org URL diet Old git URLs still work, but new ones are shorter commit 3c94498e18ca0f62bf62e5f3d844383b7417cc1c Author: Eric Wong Date: Fri Mar 4 09:12:49 2011 +0000 ext: avoid potentially unsafe casts with C API Rubinius may be pickier about what a VALUE is, so we can't safely cast any C address into VALUEs. commit c2e6c1635c55bfd23470bd30878596245a5d25b0 Author: Eric Wong Date: Thu Jan 27 06:18:35 2011 +0000 pkg.mk: update in case we get rid of C ext commit 1281d0b3cb5758d524af7e9f67094bcf936570b7 Author: Eric Wong Date: Fri Jan 21 09:07:52 2011 +0000 clogger 0.8.0 - delegating away! Clogger now delegates all unknown methods to the response body in cases where it needs to wrap the response body. This allows apps that use non-standard Rack extensions to continue working. Eric Wong (4): pass along "to_io" calls to the body delegate method_missing calls to the response body pure: simpler autoload trigger switch to pkg.mk for maintenance tasks commit abb753d65398e96c29ce6a66069b0f8f1cc2a384 Author: Eric Wong Date: Fri Jan 21 09:05:25 2011 +0000 switch to pkg.mk for maintenance tasks I like make :D commit fae26b8e56f6b6e4c6d75f8faa8570ee209ef757 Author: Eric Wong Date: Fri Jan 21 09:04:39 2011 +0000 pure: simpler autoload trigger No need to actually create the hash, just load the constant commit 2c43727f8e689ef5998d773feb4cbb2f58009391 Author: Eric Wong Date: Fri Jan 21 08:53:56 2011 +0000 delegate method_missing calls to the response body Since we delegated response_to?, we also need to delegate method_missing to the response body in case there are non-standard methods defined outside of Rack. commit d3a182dd0238c964ff5191642d53fce3d2e64be9 Author: Eric Wong Date: Fri Jan 21 08:53:55 2011 +0000 pass along "to_io" calls to the body This optimization is used by Rainbows! to pass IO objects to the response body. commit 0abc76611fe3438dd5b152257f9ba9028c536ed3 Author: Eric Wong Date: Fri Jan 14 14:43:17 2011 -0800 clogger 0.7.0 - portability improvements, cleanups Broken/crazy systems without CLOCK_MONOTONIC (in varying degrees) and/or clock_gettime() should be supported by using gettimeofday(). Thanks to Lawrence Pit for reporting and helping us test. The Clogger::ToPath proxy class is gone, Clogger itself can proxy to_path/close calls correctly to the response body. $time_utc with a default strftime-format is now supported, and time formats can now be arbitrarily long in the C extension. commit 5580514d1b291217ccfd62f2f1b06f64aa3906ef Author: Eric Wong Date: Fri Jan 14 16:30:38 2011 -0800 properly support $time_utc as documented nginx doesn't have this, only time_local, but we do commit 916e7f09c56ff0ab6722c4cce5e78d71ec336d48 Author: Eric Wong Date: Fri Jan 14 16:20:40 2011 -0800 handle abitrarily long time formats in C extension In case some folks need to use insanely long time formats, we'll support them. commit fd00bf25c8da9a04952b14bceb7e64420caf9bdb Author: Eric Wong Date: Fri Jan 14 14:21:41 2011 -0800 RDoc fixups call-seq is needed to make C functions look good commit f61187d870c580b6411d025ac1850cc3e5f2eb6a Author: Eric Wong Date: Fri Jan 14 14:13:38 2011 -0800 remove dead RSTRUCT* compatibility macros The Clogger::ToPath proxy struct class is gone and so is our need to access it. commit e4f738709482d95e49552f7ddfda800e1b4a6baf Author: Eric Wong Date: Fri Jan 14 13:59:15 2011 -0800 remove Clogger::ToPath proxy class We can just make Clogger#respond_to? smarter and forward everything except :close to the body we're proxying. commit 63521b4c70a1aff89049abf2ba224114e97f62ac Author: Eric Wong Date: Fri Jan 14 13:24:58 2011 -0800 test_clogger_to_path: do not assume implementation details We'll be getting rid of an unnecessary wrapper class commit b48017f818e13f8c7ddb555f8fe5fa895521af7a Author: Eric Wong Date: Fri Jan 14 17:26:59 2011 +0000 another try to fix systems without CLOCK_MONOTONIC Fix a reversed typedef and also deal with the case where CLOCK_MONOTONIC is a function call and not a constant macro. commit cc43cfbb418ab7b4b2786123d33ede23b3cb5ea3 Author: Eric Wong Date: Fri Jan 14 09:07:57 2011 +0000 another workaround for systems with broken CLOCK_MONOTONIC This should also detect cases where CLOCK_MONOTONIC is available at build but not at runtime. commit 6cc7e96f972d9a648bef9d49ca245282250a5502 Author: Eric Wong Date: Wed Jan 12 16:24:23 2011 -0800 attempt to support broken/crazy systems clock_gettime() is not available on some systems and/or CLOCK_MONOTONIC. This is totally broken considering the POSIX standard was 10 years ago, now. Nothing in gnulib, either, wtf?! http://www.gnu.org/software/gnulib/manual/html_node/clock_005fgettime.html commit eeae500effcddece4e9186d7b647253c48b8a3a7 Author: Eric Wong Date: Wed Jan 12 16:04:34 2011 -0800 remove unused function (obj_fileno) commit f132c6baa33496515743de1a31854d169479518d Author: Eric Wong Date: Sun Dec 26 01:21:33 2010 +0000 release: publish_news runs by default It's interactive and sucks less, now. commit a4b13f3e1376b539a1b7b7cbfeb9e38f6de2b289 Author: Eric Wong Date: Sat Dec 25 09:34:01 2010 +0000 README: updates Remove unnecessary "DESCRIPTION" header, also added note about Rubinius support. commit 04ac0bbb1a7eb6d36d80a33e5798c7bbd62455ef Author: Eric Wong Date: Sat Dec 25 00:59:58 2010 -0800 clogger 0.6.0 - :path shortcut, minor bugfixes Clogger may now be initialized with a :path instead of :logger to avoid typing "::File" in config.ru files to avoid conflicting with the completely-unrelated Rack::File. $request_time is now uses the monotonic clock, making it immune to system clock changes. $usec and $msec statements were completely broken in the pure-Ruby code and now fixed. Rubinius is supported by the optional C extension as well, the pure-Ruby code always worked. commit 8492f6bbc56d42e3068f25ca233faa78884d5a77 Author: Eric Wong Date: Sat Dec 25 01:27:33 2010 -0800 fix $msec and $usec in pure Ruby variant It was totally broken but nobody uses uses it, so it went unnoticed since the beginning of time. commit 66a5374e724612cd16f270f43102a6ed347208d7 Author: Eric Wong Date: Sat Dec 25 00:58:03 2010 -0800 add support for Rubinius RSTRUCT_PTR access is unlikely to ever happen for Rubinius, so we'll just make a method dispatch and leave the faster code for Ruby 1.8 and 1.9. commit cd91b34636caabb3a1a7cee38f5b84e91eaf62b8 Author: Eric Wong Date: Sat Dec 25 00:47:17 2010 -0800 GNUmakefile: better external RUBYLIB support Duh! commit 6720cdda4b890ac42806a8fe290f96449a150c6a Author: Eric Wong Date: Fri Dec 24 16:48:50 2010 -0800 eliminate unnecessary freeze and dup They're not needed and a waste of code. commit 54cf500266b35beecb9c30b8252e72af9fafbc3e Author: Eric Wong Date: Fri Dec 24 16:32:28 2010 -0800 doc: switch to wrongdoc for documentation wrongdoc eliminates JavaScript from our website and also enables us to cut down on our management scripts/code for supporting the project. commit c77066dd3c93d88ab91653244d36e51dc53e60d2 Author: Eric Wong Date: Fri Dec 24 16:16:27 2010 -0800 GNUmakefile: preserve RUBYLIB env for tests commit fb001a2a1e1037597804db458a28316599fc6e83 Author: Eric Wong Date: Fri Dec 24 16:14:58 2010 -0800 fix #include ordering under FreeBSD 7.2 ruby.h doesn't seem to like being included after time.h commit 2816f3ceaa31452f6bb67a7a7297e6795221cb35 Author: Eric Wong Date: Fri Dec 24 15:41:53 2010 -0800 use clock_gettime for time resolution This lets us use CLOCK_MONOTONIC so we are not affected by system clock changes. We still convert to microseconds instead of nanoseconds for (pure)-Ruby 1.8 code compatibility. There is also little need for nanosecond timer resolution in log files (microsecond is not needed, even). commit 9b46379f75f384c86e42046ab03ce55231197c92 Author: Eric Wong Date: Fri Dec 24 13:23:32 2010 -0800 accept a new :path argument in initialize This lessens confusion for people configuring Clogger in config.ru, since "File" could be mistaken for Rack::File and "::File" needs to be specified. commit 8d58b42d0255880d732ba0700597b312a8219f8f Author: Eric Wong Date: Fri Dec 24 13:17:37 2010 -0800 GNUmakefile: fix running of extension test Oops commit fc58e747835f05a64cf3c4625d6a51baa4bc8369 Author: Eric Wong Date: Tue Oct 5 14:24:11 2010 -0700 GNUmakefile: use portable tar invocation We've been spoiled by GNU tar. commit 0a13fccf2e9c285baf6d7ebfedb004e496dd976d Author: Eric Wong Date: Sun Jun 6 08:15:14 2010 +0000 README: Rack 1.1 is out (and has been for a while) commit f60c24e1fd49b6f3876f90a43a886c18d7fe743d Author: Eric Wong Date: Sun Jun 6 07:50:51 2010 +0000 clogger 0.5.0 - body.to_path forwarding This release allows middleware like Rack::Contrib::Sendfile to work properly higher up the stack from Clogger. Certain configurations of the Rainbows! and Zbatery web servers are able to use the return value of body.to_path to serve static files efficiently (via IO.copy_stream under 1.9 or stream_file_data with EventMachine). There are some small cleanups and documentation improvements as well. I've relicensed to LGPLv2.1+ (from LGPLv3-only) to allow bundling with GPLv2-only applications (I'm currently the sole copyright holder). Signed-off-by: Eric Wong commit 86699fa42105c48e7d4c3cf6e16cca4417bf0a06 Author: Eric Wong Date: Sun Jun 6 07:46:25 2010 +0000 README: document CLOGGER_PURE environment variable There may also be some MRI users uncomfortable running C extensions. commit fac515bf384d1cb8fe30a310bb38904b1dc74f58 Author: Eric Wong Date: Sun Jun 6 07:42:56 2010 +0000 CLOGGER_PURE=0 disables the C ext It's unintuitive that merely setting the environment variable to an empty string or zero would be a boolean true. commit 009760bdb7ba08246b98f4befe856cbda2ce769a Author: Eric Wong Date: Sun Jun 6 07:37:13 2010 +0000 ext: comment why we do what we do in to_path commit 41debb52b9d719dbb6f3ee7963de8913eff0c13d Author: Eric Wong Date: Sun Jun 6 07:34:09 2010 +0000 ext: the N in /dev/fd/N must be unsigned There's no way in hell a valid file descriptor can have a negative number attached to it. commit cd76457a8eec40a0de8cb2bc779c5bfb08b9d7b3 Author: Eric Wong Date: Sun Jun 6 07:19:55 2010 +0000 ext: handle weird regular files with O_NONBLOCK set Sometimes programmers can blindly set O_NONBLOCK on everything in sight. However, O_NONBLOCK has no effect on regular files, so ignore it and allow the raw file descriptor to be used. commit 8794037db3e88fc03d8bc33d603a0b39a69ddf97 Author: Eric Wong Date: Sun Jun 6 07:17:09 2010 +0000 ext: cleanup -Wshadow warning commit 0de4a3d46d15ee5097f4a9cfd46363b5f720ae39 Author: Eric Wong Date: Sun Jun 6 07:02:00 2010 +0000 no point in using autoload for Rack Rack is always used, and Rack itself uses autoload to save memory. commit f4dd93733793baadd859ba1197814c3a19f232b4 Author: Eric Wong Date: Sun Jun 6 07:01:23 2010 +0000 gemspec: update test files commit 52180f527a3711f590b369499c1bd83a19b88187 Author: Eric Wong Date: Sun Jun 6 06:58:12 2010 +0000 relicense as LGPLv2.1 or later (from LGPLv3) This allows GPLv2-only programs to bundle us. Signed-off-by: Eric Wong commit e3dfea56ec8f189711f7904a9a05dbbfc0bd6acc Author: Eric Wong Date: Sun Jun 6 06:47:02 2010 +0000 doc: RDoc cleanups, split out LICENSE file commit b895d3d0393a647d3602783bc53bf68e223e51c9 Author: Eric Wong Date: Sun Jun 6 05:17:14 2010 +0000 pass-through body.to_path when wrapping the body Certain configurations of Rainbows! (and Zbatery) are able to use the return value of body.to_path to serve static files more efficiently. This also allows middleware like Rack::Contrib::Sendfile to work properly higher up the stack, too. commit bc1d1df38d7803ce9fdae05fc5129051eeed89e0 Author: Eric Wong Date: Sun Jun 6 00:43:34 2010 +0000 when wrapping the body, body.close writes the log We no longer write the log out at the end of the body.each call. This is a behavioral change, but fortunately all Rack servers I've seen call body.close inside an ensure. This allows us to later pass along the "to_path" method and not rely on "each" to write the log. commit e4c3548e8ff4c95c697b4a30699e6f655d60f188 Author: Eric Wong Date: Sat Jun 5 20:57:17 2010 +0000 GNUmakefile: allow multiple tests to run in parallel commit 111e5ac0bf12021a2b8cf9145df59312f1f96992 Author: Eric Wong Date: Wed Apr 21 16:53:43 2010 -0700 clogger 0.4.0 Small cleanups and minor enhancements (mainly for the optional C extension) for this release: Eric Wong (10): ext: use FIX macros instead of generic NUM macros if possible ext: preserve subclasses of Rack::Utils::HeaderHash test: fix Linux memory usage test avoid direct require of "rack" to quiet warnings ext: GC safety fix when throwing an exception ext: eliminate unused variable ext: fix signedness and shadow warnings ext: sparse cleanups ext: avoid void pointer arithmetic clogger 0.4.0 commit 380e547ba406c00130304ce0cab4fa289e3f2957 Author: Eric Wong Date: Wed Apr 21 16:52:27 2010 -0700 ext: avoid void pointer arithmetic default CFLAGS for 1.9.2dev complains commit 23628403c9dc58925e5db2abb9ed9425a4208325 Author: Eric Wong Date: Wed Apr 21 16:48:48 2010 -0700 ext: sparse cleanups commit c353b5bf62ea500fda8cc7799d1645f9b0c28697 Author: Eric Wong Date: Wed Apr 21 16:35:36 2010 -0700 ext: fix signedness and shadow warnings These were (fortunately) harmless, but better safe than sorry. commit c16263dc9ff6230bd148e39431e9c5e059a674a7 Author: Eric Wong Date: Wed Apr 21 16:31:33 2010 -0700 ext: eliminate unused variable commit e142f2c5db4427be70d10d7e1316e139d08a7c3e Author: Eric Wong Date: Wed Apr 21 16:29:56 2010 -0700 ext: GC safety fix when throwing an exception The return value of rb_inspect() may not be visible on the stack without assigning it to a local variable first. commit a0ee3ba2d08acb423a1cbc4a5ae862bd40c4b914 Author: Eric Wong Date: Wed Apr 21 15:31:58 2010 -0700 avoid direct require of "rack" to quiet warnings This quiets down warnings when used with RubyGems loaders such as Isolate and Bundler where the HTTP server already loaded Rack. commit 9c6fd3814b6bed2772fc540e7824febe85e9b046 Author: Eric Wong Date: Wed Apr 21 15:29:10 2010 -0700 test: fix Linux memory usage test commit 0313f0651caf9ef35d320c6049d4f32ace711457 Author: Eric Wong Date: Thu Apr 8 15:12:07 2010 -0700 ext: preserve subclasses of Rack::Utils::HeaderHash some people subclass HeaderHash and want them preserved through the middleware stack. commit 31925d90c3d292d0b5f20524082b7d3dc2e08fcb Author: Eric Wong Date: Thu Apr 8 14:36:36 2010 -0700 ext: use FIX macros instead of generic NUM macros if possible They're slightly faster when we know a number is small enough to be a FIXNUM. commit 724c1f6a3b42a020199554c809a46ddc4b404659 Author: Eric Wong Date: Sat Feb 13 01:47:12 2010 -0800 clogger 0.3.2 This release fixes a memory leak in the optional C extension due to misuse of the Ruby C API. Users of the pure Ruby version are unaffected. We also misreleased 0.3.1 with this fix, but without bumping the Clogger::VERSION constant. commit 4247fafd0f361d2373df7213a1a0028554e93d93 Author: Eric Wong Date: Sat Feb 13 01:35:55 2010 -0800 ext: fix memory leak when reentrant/multithreaded The optional C extension leaked memory due to improper use of the Ruby API, causing duplicated objects to never be garbage collected. I misread the Data_Make_Struct/Data_Wrap_Struct documentation and ended up passing NULL as the "free" argument instead of -1, causing the memory to never be freed. From README.EXT in the MRI source which I misread: > The free argument is the function to free the pointer > allocation. If this is -1, the pointer will be just freed. > The functions mark and free will be called from garbage > collector. commit 883368f745af13a57b3784b834001a82823eee05 Author: Eric Wong Date: Tue Feb 9 13:57:17 2010 -0800 clogger 0.3.0 You may now force the :reentrant flag to +true+ or +false+ in your Rack configuration file: use Clogger, :format => Clogger::Format::Combined, :logger => ::File.open("/path/to/log", "ab"), :reentrant => true This is to be compatible with Rack servers that do not use use events or Fibers for concurrency instead of threads. By default, reentrancy is enabled if env["rack.multithread"] is true, but "rack.multithread" cannot indicative of a reentrancy requirement in a web server. commit 616314a2bbc13095b1da9306916c0d414634e555 Author: Eric Wong Date: Mon Feb 8 17:20:30 2010 -0800 README: update examples for :reentrant commit 2dd3e22782090dc347429e306569f687fa794d06 Author: Eric Wong Date: Mon Feb 8 17:14:41 2010 -0800 Allow :reentrant flag to be forced true/false Clogger may set this value independently of "rack.multithread" since Actor/Fiber-based servers may have multiple instances of Clogger wrapping different response bodies and yet be incompatible with "rack.multithread" commit 74ab49d2f02d65fb4d2915563d8b4c4f026e4657 Author: Eric Wong Date: Wed Jan 6 18:09:27 2010 -0800 Fix minor build system bugs commit 1df164e28824cf139b38e35d6eb6dbfb088c54a8 Author: Eric Wong Date: Wed Jan 6 17:44:27 2010 -0800 clogger 0.2.0 The optional C extension no longer tries to preserve the original response array as it could become subtly broken by people using non-frozen but constant responses. For the pure Ruby version, there is a 1.9-encoding bugfix for response size calculation. commit 87c742bd385593bfe001dc3247c4a4ae7fc92463 Author: Eric Wong Date: Wed Jan 6 17:41:41 2010 -0800 pure: use Rack::Utils.bytesize instead of String#size hacking the C extension with RSTRING_LEN() is so much easier :P commit 5d4fd9f41ab57f7297569910c08f7330dd3ec39e Author: Eric Wong Date: Wed Jan 6 17:37:25 2010 -0800 pure: avoid unnecessary method dispatches instance variable lookups are expensive as-is commit 30ce68ad7ba0c7467b0369e0a5d6252baa52aae4 Author: Eric Wong Date: Wed Jan 6 17:34:58 2010 -0800 GNUmakefile: avoid deleting when uploading docs commit f8f05dc199a0553bbcd03deb990f220d57278cc9 Author: Eric Wong Date: Wed Jan 6 17:32:07 2010 -0800 Rakefile: raa_update task commit 684a9d6083a7f95a3010e7a1291df7ab6de0f394 Author: Eric Wong Date: Wed Jan 6 17:27:04 2010 -0800 README: use ::File in usage examples A bare "File" constant may conflict with Rack::File when run inside Rack::Builder commit ab37f2d65b01370ae975346110471f33b10bd178 Author: Eric Wong Date: Wed Jan 6 17:23:13 2010 -0800 ext: unpack response arrays unconditionally It's too crazy to have to special case for frozen response constants. 3-element arrays are cheap under Ruby 1.9 anyways. commit b082327b0363f5236a267abd8a412e18ce9918e0 Author: Eric Wong Date: Wed Jan 6 16:07:38 2010 -0800 GNUmakefile: NEWS depends on .manifest commit 6e3977583a4b2932617e5c81bcf1aeb7a2605ddc Author: Eric Wong Date: Wed Jan 6 16:06:49 2010 -0800 GNUmakefile: modernize for Gemcutter Also uppercase rake/ruby variables commit 0420598d0007d9d816d55c698ed1f9ac4e206433 Author: Eric Wong Date: Tue Oct 6 13:46:20 2009 -0700 clogger 0.1.0 This release should help ensure compatibility with a to-be-released version of Rack::Lint that allows subclasses of the core String and Hash objects for users of the optional C extension. Eric Wong (6): ext: convert non-Hashes #to_hash if possible ext: ensure all objects we byte_xs are Strings tests for subclassing gemspec: disable the license= field for older RubyGems GNUmakefile: fix grammar FAIL in comment cleanup packaging and website/rdoc commit cf543e57efa4b8d81121e712280bb6413719be35 Author: Eric Wong Date: Tue Oct 6 13:24:05 2009 -0700 cleanup packaging and website/rdoc commit 1e4b7c3d2fe12e4732ed816ebd75bb7dc81d6151 Author: Eric Wong Date: Tue Oct 6 11:16:43 2009 -0700 GNUmakefile: fix grammar FAIL in comment commit cf3be5aca27a82a1f6939cd6383f6b1c0ac0c602 Author: Eric Wong Date: Tue Oct 6 11:12:07 2009 -0700 gemspec: disable the license= field for older RubyGems commit 485fe222d304c9a795141532596b0575c3d2e6ea Author: Eric Wong Date: Tue Oct 6 12:03:11 2009 -0700 tests for subclassing Rack::Lint will be relaxed in the next version to allow subclasses of String and Hash objects, so ensure we're good to go when the next version of Rack hits. commit 2ca88db578a4b9143a5dfaa66ce38b9463e7e166 Author: Eric Wong Date: Tue Oct 6 12:03:10 2009 -0700 ext: ensure all objects we byte_xs are Strings Rack will be relaxing the spec to allow subclasses of String objects. Just in case they're not compatible, we'll convert them to strings. commit c4eca8765e9aaf0d2736e764770d72f407affc16 Author: Eric Wong Date: Tue Oct 6 12:03:09 2009 -0700 ext: convert non-Hashes #to_hash if possible This is to remain compatible with Rack if it relaxes Rack::Lint to allow subclasses. commit 162110a29c6b3f4e3698151d83d998f24ed3768a Author: Eric Wong Date: Wed Sep 9 10:11:29 2009 -0700 clogger 0.0.7 We now properly handle bodies that do not respond to the :close method. Additionally there small documentation/formatting fixes. commit 7eb0c4e29e567f02affc202b51eb277cbae43688 Author: Eric Wong Date: Wed Sep 9 10:02:49 2009 -0700 handle bodies that do not respond to :close Since the wrapped Clogger object always responds to close, we cannot blindly delegate the close method to the body without ensuring it can be closed. So ensure that it can be closed before attempting to close it, all return values and errors are trapped and returned. Reported-by: Iñaki Baz Castillo commit 72dfd64ed0ab31ced0f27e8a8a941c555221bb96 Author: Eric Wong Date: Mon Sep 7 19:32:17 2009 -0700 README: fix some grammar peculiarities commit 1c19cf0066ac83d2da02f331be65dffacd560c36 Author: Eric Wong Date: Mon Sep 7 19:28:17 2009 -0700 README: document $status Hopefully it was obvious before, if not it is now. commit 5d77f491c59f79a7727d8699be2aaf12db9d81c6 Author: Eric Wong Date: Mon Sep 7 17:27:18 2009 -0700 Rakefile: preformatted text for history rdoc escaping issues are too painful to deal with commit 898d31b2ffa0383d62bf28c4fa49bc74aa92fde5 Author: Eric Wong Date: Mon Sep 7 17:25:09 2009 -0700 Rakefile: Fix history with multi-paragraph tag messages commit 25faf9f74637db03f0e5e1bcd1785d74d7ff6309 Author: Eric Wong Date: Mon Sep 7 17:24:35 2009 -0700 gemspec: license is LGPLv3 Odd, RubyGems doesn't warn about a lack of it and I didn't notice this field until now... commit 4d0226b77b2d053ee677d3101b19fb662b1f10b6 Author: Eric Wong Date: Mon Sep 7 17:19:05 2009 -0700 GNUmakefile: cleanup release notes generation commit 6769f9b6615ebe172b3a75f1d11554ada26c592d Author: Eric Wong Date: Mon Sep 7 16:49:22 2009 -0700 clogger 0.0.6 "clogger_ext" is no longer a separate gem, but merged into the "clogger" gem itself. The installation should automatically detect compatible versions of Ruby and only build the C extension for MRI 1.8/1.9. Rack::Utils::HeaderHash is now used for $sent_http_* variable lookups instead of a hand-rolled solution. HeaderHash objects should be reusable in Rack soon to avoid the penalty of recreating them repeatedly in middlewares and hopefully more-widely used as a result. Underlying logger objects are sync=true for safety reasons. This has always been the case for the C extension version when writing to regular files. Other small changes include more CGI variables and the :ORS (output record separator) option added (default: "\n"). commit 1475c6ce69dab9a6679dc3237be7761afd29e998 Author: Eric Wong Date: Mon Sep 7 16:47:38 2009 -0700 ext: fix compiler warnings in the cpp "comment" commit 3547efe6386bb4ad224be49b723d16cde2067f9c Author: Eric Wong Date: Sat Sep 5 19:33:33 2009 -0700 Don't bother creating HeaderHash unless we need it It's expensive to create if not needed, and no current released version of Rack has my proposed optimizations for it yet... commit 9335d300dbf62e7b8bd140f6388358fe71a62bc0 Author: Eric Wong Date: Sun Sep 6 16:30:39 2009 -0700 README: note that it's multi-instance-safe commit 9b1012102ad16fcb27188b6a3ffd299c70ef63e1 Author: Eric Wong Date: Mon Sep 7 16:43:45 2009 -0700 README: fix links commit 732325a67ba68060fe18dc66c21134c35f8006ea Author: Eric Wong Date: Mon Sep 7 16:24:41 2009 -0700 enable MRI C extension by default It was too much confusion to have multiple gems in the mix and I mainly use the C extension anyways. If we're not on a compatible version of Ruby, the extension will just be disabled by generating a dummy no-op Makefile to work around it. commit cee939b527e82237f89eb8eece62610854ac888a Author: Eric Wong Date: Mon Sep 7 15:49:55 2009 -0700 Switch to hand-rolled packaging/distro scripts Several bikeshed reasons brought me to this point: * I like the README.html layout more than any default index.html even if it's using README content. Having links on the side helps navigation IMHO. * publish_docs preserves timestamps to improve cache hit rate * git is used to maintain the manifest at packaging/release-time so my changesets have less noise in them * git is used to generate history files (from tag messages), this is a more DRY approach to me. * I don't like the ".txt" suffix being translated to "_txt.html" in URLs. I don't like the ".txt" suffix in general. * I don't like Manifest.txt showing up in my RDoc commit 00814d46e9e82fa24d38bd77172143df3757f020 Author: Eric Wong Date: Mon Sep 7 15:23:01 2009 -0700 ext: hack to prevent rdoc from finding Rack* namespace TODO: find a better way to do this... commit 1d764d806b65d392fdb3f3dd8055ed18d42a5c2b Author: Eric Wong Date: Fri Sep 4 19:26:42 2009 -0700 ext: only duplicate frozen response arrays Otherwise modify the response array in place since most frameworks give you a modifiable array for you to play with anyways. commit 09cae70d5509530ed3abff9046b1dc0fe448b3b3 Author: Eric Wong Date: Fri Sep 4 19:19:28 2009 -0700 use Rack::Utils::HeaderHash for $sent_http_* lookups No point in having extra code to do case-insensitive lookups, especially since the HeaderHash implementation is already in wide use and will only get faster as time goes by. commit 38e617b5a044ed91c799718d2188052c5646bc95 Author: Eric Wong Date: Fri Sep 4 18:49:44 2009 -0700 ext: store each response element explicitly Avoid calling RARRAY_PTR all over the place and make the code easier to read/audit as a result. commit 3ebed5dbd35440cb1e892a1361c71dc0516c64e8 Author: Eric Wong Date: Fri Sep 4 17:43:59 2009 -0700 ext: more consistent function naming s/init_bad_response/init_bad_app_response/ The new name matches the variable it initializes more closely. commit f704fba80a8522975b6c167a751f2b68298f1d66 Author: Eric Wong Date: Thu Sep 3 23:43:38 2009 -0700 add support for several more CGI variables $auth_type, $gateway_interface, $server_software, $path_translated are all supported now. commit b32d1da1d760f2e193b293af6dde9da272a85e8d Author: Eric Wong Date: Thu Sep 3 19:25:39 2009 -0700 add output record separator option (:ORS) This allows overriding the default of "\n". Behavior remains similar to IO#puts, the :ORS (output record separator) is appended iff the format doesn't already end with that string. commit af12d387069d017494daa23534fa7f87aea9ff3b Author: Eric Wong Date: Thu Sep 3 19:23:43 2009 -0700 CLOGGER_PURE forces the pure version to be loaded This is useful for testing the pure Ruby version in case clogger_ext is already installed on your system. commit b7c6846e317b0f2bfe4807aab34524c2a633947c Author: Eric Wong Date: Thu Sep 3 09:20:42 2009 -0700 Ensure underlying logger objects are sync=true Userspace buffering defaults are dangerous as the Ruby default IO objects do not do line-aware buffering. This makes the README examples with File.open much safer to use out-of-the-box for users of the pure-Ruby version. For users on the MRI C extension logging to regular files, this should not have any effect as we've optimized those to do unbuffered write(2) syscalls anyways. commit afaa8efb31094a831a68b383523f9bac46a244ac Author: Eric Wong Date: Wed Sep 2 18:44:55 2009 -0700 clogger 0.0.5 commit 5fd5bb6aa884ec8f2c62a5edaae6b93ec8275f2e Author: Eric Wong Date: Wed Sep 2 18:40:02 2009 -0700 README: minor updates and clarifications * link to Clogger::Format when talking about predefined formats * use upper-case for escape chars since that's what we use * clarify $request_time{PRECISION} range commit 3bc7000a34c8e1788a5951381c7007f617233da2 Author: Eric Wong Date: Wed Sep 2 18:29:58 2009 -0700 alias $http_content_{length,type} to $content_{length,type} Since Rack doesn't allow the HTTP_CONTENT_{LENGTH,TYPE} headers, alias attempts to use those to the non-"HTTP_"-prefixed equivalents to avoid confusion on the user side (nginx also does this). commit 41e3dcf47d8ee855747681b80dab1c3b9d6bc457 Author: Eric Wong Date: Wed Sep 2 18:21:09 2009 -0700 expose the $content_length/$content_type variables Since the HTTP_CONTENT_LENGTH and HTTP_CONTENT_TYPE variables are not allowed by Rack, we need to allow access to the CGI variables instead. commit 34bda71752bc7401c552a7a4d5b77cf7e1bfe431 Author: Eric Wong Date: Wed Sep 2 18:15:27 2009 -0700 expose $request_method as documented in the README Accessing "REQUEST_METHOD" in the Rack env should be doable as a CGI-ish variable. Thanks to Iñaki Baz Castillo for spotting the issue and reporting it to me. commit d60d0b4656718a63137f89baa15b6589740ad454 Author: Eric Wong Date: Wed Sep 2 01:04:19 2009 -0700 clogger 0.0.4 commit 144e9909ea0f875b3dd58c6c850e25ed9f70c3cb Author: Eric Wong Date: Tue Sep 1 19:04:52 2009 -0700 correctly rebuild simple HTTP/0.9 GET requests Back in HTTP/0.9 days (before it was called HTTP/0.9), "GET /uri/goes/here\r\n" was a valid HTTP request. See rfc 1945, section 4.1 for details on this ancient "Simple-Request" scheme used by HTTP/0.9 clients. commit 98d72e530ae0e7899aee88bcb0a607e046b32965 Author: Eric Wong Date: Tue Sep 1 15:40:07 2009 -0700 README: point to repo.or.cz git mirror setup The rubyforge one is out-of-date right now, so lets stop referencing it until the issues around it can be fixed. commit 12d45b13dc28be86ada0bf304153155cb1975ba9 Author: Eric Wong Date: Tue Sep 1 15:17:06 2009 -0700 README: new git repository I seem to have problems pushing to Rubyforge at the moment, so I'll put the repository on a host I have more control over. Tracking the issue here: http://rubyforge.org/tracker/index.php?func=detail&aid=26185&group_id=5&atid=102 commit c9f68fc6294a59c31728bab9e01350c4b271fe30 Author: Eric Wong Date: Sun Aug 30 22:27:26 2009 -0700 Ensure hex escaping is done in uppercase The pure variant was using lower-case output instead of upper case, the ext variant was actually fine in this case. This is for nginx output format compatibility. commit a6e410b7f85f22e6adbc55eb9dd3a494ca7200b2 Author: Eric Wong Date: Sun Aug 30 22:27:25 2009 -0700 ext: ensure headers#each in response is valid We're not Rack::Lint, but we still need to take steps to avoid segfaulting if we host non-Rack::Lint-compliant applications. This also updates the pure variant to fail on bad applications, too. commit a6978053b9e9f4eff3e54bda6b4aa0c06f707075 Author: Eric Wong Date: Sun Aug 30 22:27:24 2009 -0700 ext: compiler compatibility fix Remove trailing "," for enum commit 465625fa4763177553846653c2b1198c543d2496 Author: Eric Wong Date: Tue Sep 1 11:26:59 2009 -0700 GNUmakefile: post_news after release commit 5fb4355a370632391654a9aa19338fc48a30d143 Author: Eric Wong Date: Sat Aug 29 16:20:19 2009 -0700 clogger 0.0.3 commit cb1772c91444c0c4eb3e4cf17cac5e265cb2a551 Merge: de46287 ed276bd Author: Eric Wong Date: Sat Aug 29 16:15:18 2009 -0700 Merge dcvr:clogger * dcvr:clogger: ext: several cleanups and robustness improvements ext: explicitly gc_mark each struct element commit ed276bd6ba03b89201bfdfd1730b428b224372f0 Author: Eric Wong Date: Sat Aug 29 16:11:52 2009 -0700 ext: several cleanups and robustness improvements Add a little more tolerance for bad applications that may not give us string objects. This should only have a minor performance penalty for proper applications but at least ensures we don't segfault on misbehaving apps. commit e4bdbdcfcbf51ee91e4192ef361ba73e80e14dcc Author: Eric Wong Date: Sat Aug 29 16:08:55 2009 -0700 ext: explicitly gc_mark each struct element rb_gc_mark_locations doesn't seem in common use for structs and there was a fencepost error so the response element didn't seem to be marked at times. This should fix random errors I've been seeing on big/longer response bodies. commit de46287e9ea70e63e77d17c862ee6bf5ab105e96 Author: Eric Wong Date: Sat Aug 29 13:58:26 2009 -0700 GNUmakefile: fix "release" now that I've used it.. * pass correct arguments for changes * correctly generate change log from git * add blank line after description in release notes commit d7cbdb6d59434145ed7293f97578feea83a47bc2 Author: Eric Wong Date: Sat Aug 29 13:52:37 2009 -0700 clogger 0.0.2 commit 4cae518fd0b2ba81114ed4cc26eb1704a1f71e28 Author: Eric Wong Date: Sat Aug 29 13:39:58 2009 -0700 Log bad/invalid app responses as 500 errors Some misbehaved apps can do this to us, and we don't want the C extension to segfault when this happens. commit c03045ecde0f3270d7458ba7ac0d76a25afc6fb2 Author: Eric Wong Date: Sat Aug 29 13:35:22 2009 -0700 support "$request_uri" as a log variable This was documented in the README but never implemented. Some popular web servers set REQUEST_URI even though it's not required by Rack, so allow this variable to be used if possible. As a side effect, it is also less likely to be modified by certain handlers (*cough*Rails::Rack::Static*cough*). commit 46a176a741ad4d19d81946b4232c0c26fb8bdbc8 Author: Eric Wong Date: Sat Aug 29 12:45:45 2009 -0700 GNUmakefile: "release" steps commit 0a582a3a0f18d359792a523d3ca3ae25eba0b279 Author: Eric Wong Date: Fri Aug 28 21:47:18 2009 -0700 Remove benchmarks from Manifest.txt We don't care commit d3fcf416c616327ca8aacd6f0a1cd8fd74baca01 Author: Eric Wong Date: Fri Aug 28 21:45:29 2009 -0700 README: updates and clarifications commit a70468036d9b780bc7ec921f7feb6e1275778169 Author: Eric Wong Date: Fri Aug 28 20:47:43 2009 -0700 initial import