From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on dcvr.yhbt.net X-Spam-Level: X-Spam-ASN: AS11260 24.222.16.0/20 X-Spam-Status: No, score=-4.3 required=3.0 tests=AWL,BAYES_00,RP_MATCHES_RCVD, SPF_PASS shortcircuit=no autolearn=ham autolearn_force=no version=3.4.0 Received: from webmail.dymaxion.ca (webmail.dymaxion.ca [24.222.19.53]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-SHA384 (256/256 bits)) (No client certificate requested) by dcvr.yhbt.net (Postfix) with ESMTPS id 434AD203E3 for ; Tue, 26 Jul 2016 15:24:53 +0000 (UTC) Received: from DYMAXMAIL.dymaxion.lan (24.222.19.53) by dymaxmail.dymaxion.lan (24.222.19.53) with Microsoft SMTP Server (TLS) id 15.0.1210.3; Tue, 26 Jul 2016 12:24:04 -0300 Received: from localhost (24.222.19.4) by DYMAXMAIL.dymaxion.lan (24.222.19.55) with Microsoft SMTP Server (TLS) id 15.0.1210.3 via Frontend Transport; Tue, 26 Jul 2016 12:24:04 -0300 Received: from [::1] by localhost with esmtp (Exim 4.87) (envelope-from ) id 1bS4Dz-0008Hy-2t; Tue, 26 Jul 2016 12:24:51 -0300 Subject: Re: gem fails to build on Win 7 32 bit, DevKit 3.7.2 (rubyinstaller.org) To: Eric Wong References: <230a2e9e-a0d3-2473-2cba-567eadc32c88@dymaxion.ca> <20160725210439.GA29810@starla> CC: From: Ben Armstrong Message-ID: <768eb146-93a3-e86b-f089-b548921744a6@dymaxion.ca> Date: Tue, 26 Jul 2016 12:24:50 -0300 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101 Icedove/45.2.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset="utf-8"; format=flowed Content-Transfer-Encoding: 7bit List-Id: On 26/07/16 06:35 AM, Ben Armstrong wrote: > However, after my successful build of the patched gem, when I re-enabled > clogger in my rails 3 app in config/application.rb like this, it > resulted in an empty log/access.log: > > config.middleware.use 'Clogger', > :format => Clogger::Format::Combined, > :logger => File.open("log/access.log", "ab") > > Odd, as this worked fine for me once upon a time when the application > ran on Ruby 1.8.7. (It was only when we made the switch to Ruby 1.8.7 -> > 2.2.4 that clogger broke and we temporarily disabled this feature.) This made me suspect that Rails was no longer passing this logger to WEBrick to use as an access log, and that had nothing at all to do with clogger. Sure enough, when I initialized the HTTPServer instance with :AccessLog => [[File.open('log/access.log','ab'),WEBrick::AccessLog::COMBINED_LOG_FORMAT]], I got exactly what I wanted, without having clogger involved at all. So, thanks for your time looking at my issue, but I think I'll go with this solution, as it reduces my application's dependencies by one. If I ever need a logger with more flexibility, I'll keep clogger in mind, but it appears I don't need it. Ben