Skip to content

crema/locksmith

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

13 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Locksmith

ActiveRecord transaction checker

  • check max duration
  • check max record lock count
  • check invalid s-lock, x-lock order

Usage

add config/inializers/locksmith.rb

class LocksmithConfig
  include Locksmith::Config

  check_transaction_duration_over 10.seconds do |transaction, duration|
    # blah blah    
  end

  check_transaction_record_count_over 100 do |transaction, locks_count|
     # blah blah    
  end

  check_invalid_order_lock do |transaction, locks, invalid_order_locks|
     # blah blah    
  end

end

About

mysql record lock base deadlock detector

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages