In Rails2, what’s the best way to customize the format of logger output
In Rails1, due to Rails weird monkey-patching of Logger, you couldn’t
just subclass Logger and then set it as the logger to be used. Has this
been improved in Rails2, is there a cleaner way to do this now?
In Rails1, the only good way I found to customize the logger output was
to myself monkey-patch Logger at the end of environment.rb, over-riding
def format_message(severity, timestamp, progname, msg)
# stuff to output messages just the way I want.
However, oddly, in Rails2 this seems to have stopped having any effect
at all. The logger output is still uncustomized, Rails default.
Any advice? Thanks in advance to Frederick if he pays attention to this,
because so far he’s the only one who both understands what I’m talking
about and pays attention to me I already owe you many beverages of
your choice, Frederick.