Active record logs
Reported by Thomas | May 5th, 2009 @ 05:12 AM | in 0.8.5
It would be great to enable active record logs.
This can be done like that:
module Adhearsion class Initializer
class DatabaseInitializer
class << self
def start
require_dependencies
require_models
@@config = Adhearsion::AHN_CONFIG.database
# You may need to uncomment the following line for older versions of ActiveRecord
# ActiveRecord::Base.allow_concurrency = true
establish_connection
ActiveRecord::Base.logger = Logger.new(File.join(AHN_ROOT, 'log', 'database.log'))
create_call_hook_for_connection_cleanup
end
...
Note: You may want to enable/disable this by configuration
Comments and changes to this ticket
-
Jay Phillips June 4th, 2009 @ 04:08 PM
- State changed from new to open
You're right, this should definitely be in master.
-
Ben Klang June 26th, 2010 @ 02:18 AM
- Milestone cleared.
- State changed from open to resolved
- Assigned user changed from Jay Phillips to Ben Klang
- Milestone order changed from 0 to 0
This has been added to Git:
http://github.com/adhearsion/adhearsion/commit/e6880ea6b6a607c1883d... -
Ben Klang June 26th, 2010 @ 02:20 AM
- Milestone set to 0.8.5
- Milestone order changed from 1 to 0
Please Sign in or create a free account to add a new ticket.
With your very own profile, you can contribute to projects, track your activity, watch tickets, receive and update tickets through your email and much more.
Create your profile
Help contribute to this project by taking a few moments to create your personal profile. Create your profile ยป