couchdb-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Henri van den Bulk <hvandenb...@gmail.com>
Subject Re: Custom log format
Date Fri, 01 Mar 2013 00:21:14 GMT
Would be nice to keep this consistent with apache http. You can make it put out in multiple
formats. 

http://httpd.apache.org/docs/2.2/mod/mod_log_config.html

Thanks,

Henri van den Bulk

On Feb 28, 2013, at 4:09 PM, Lance Carlson <lancecarlson@gmail.com> wrote:

> I wonder if this could be turned into a config setting or something.
> I'd just worry about the overhead of having the load the format.
> Though the log format could be cached on boot.
> 
> Sent from my iPhone
> 
> On Feb 28, 2013, at 6:06 PM, Anthony Ananich <anton.ananich@inpun.com> wrote:
> 
>> Found answer in couch_log.erl
>> 
>> get_log_messages(Pid, Level, Format, Args) ->
>>   ConsoleMsg = unicode:characters_to_binary(io_lib:format(
>>       "[~s] [~p] " ++ Format ++ "~n", [Level, Pid | Args])),
>>   FileMsg = ["[", couch_util:rfc1123_date(), "] ", ConsoleMsg],
>>   {ConsoleMsg, iolist_to_binary(FileMsg)}.
>> 
>> So FileMsg is hardcoded.
>> 
>> On Fri, Mar 1, 2013 at 1:16 AM, Anthony Ananich <anton.ananich@inpun.com> wrote:
>>> Hi!
>>> 
>>> I wonder if it is possible to change couch.log file format to Apache's
>>> log file format?
>>> 
>>> I need this to be able to use log file analyzer tools like AWStats.
>>> 
>>> I found that handle_log_req could be customized, but I guess that it
>>> just reads log file and send it's part over HTTP.
>>> 
>>> Thanks,
>>> Anthony

Mime
  • Unnamed multipart/alternative (inline, 7-Bit, 0 bytes)
View raw message