13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
|
# File 'lib/ixtlan/audit_config.rb', line 13
def self.reconfigure(keep, file)
audit_appender =
RollingFile.new('audit',
{ :filename_base => file,
:keep => keep,
:safe => true,
:layout => Logging::Layouts::Pattern.new(:pattern => "%d %m\n") }
)
@@categories.each do |category|
logger = Logging::Logger[category]
logger.remove_appenders('audit')
logger.add_appenders(audit_appender)
@logger.debug("setup logger for #{category}")
end
@logger.info("initialized audit log . . .")
end
|