# Locking issues in sidekiq jobs?

**URL:** <https://meta.discourse.org/t/locking-issues-in-sidekiq-jobs/69287>\
**Category:** Product Support\
**Created:** [2017 年9 月 3 日 13:49 UTC](https://meta.discourse.org/t/locking-issues-in-sidekiq-jobs/69287 "2017-09-03T13:49:34Z")\
**Posts on this page:** 1\
**Showing post:** 7

<div class="post-metadata">

作者： ![RGJ](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/rgj/32/523185_2.png) [@RGJ](https://meta.discourse.org/u/RGJ)\
发布日期： [2019 年1 月 3 日 16:12 UTC](https://meta.discourse.org/t/locking-issues-in-sidekiq-jobs/69287/7 "2019-01-03T16:12:30Z")

</div>

Ok, this is what I got. I was hoping to spot the culprit more easily but maybe @sam does know better how to interpret these results…

```
==================================
  Mode: cpu(1000)
  Samples: 7994 (0.32% miss rate)
  GC: 10 (0.13%)
==================================
     TOTAL (pct) SAMPLES (pct) FRAME
      3301 (41.3%) 3300 (41.3%) ActiveModel::LazyAttributeHash#[]
      2123 (26.6%) 2123 (26.6%) ActiveRecord::ConnectionAdapters::TransactionState#finalized?
       897 (11.2%) 897 (11.2%) ActiveRecord::AttributeMethods::PrimaryKey::ClassMethods#primary_key
       787 (9.8%) 786 (9.8%) ActiveModel::Attribute#value
      7647 (95.7%) 118 (1.5%) ActiveRecord::AttributeMethods::PrimaryKey#id
      3414 (42.7%) 113 (1.4%) ActiveModel::AttributeSet#[]
      4400 (55.0%) 104 (1.3%) ActiveRecord::AttributeMethods::Read#_read_attribute
      4296 (53.7%) 96 (1.2%) ActiveModel::AttributeSet#fetch_value
      2210 (27.6%) 87 (1.1%) ActiveRecord::Transactions#update_attributes_from_transaction_state
        55 (0.7%) 55 (0.7%) Nokogiri::XML::Document#decorate
      7697 (96.3%) 51 (0.6%) ActiveRecord::Core#==
      2234 (27.9%) 24 (0.3%) ActiveRecord::Transactions#sync_with_transaction_state
        13 (0.2%) 13 (0.2%) ActionView::PathResolver#find_template_paths
        12 (0.2%) 12 (0.2%) PG::Connection#async_exec
        11 (0.1%) 11 (0.1%) Nokogiri::XML::XPathContext#register_namespaces
        10 (0.1%) 10 (0.1%) (garbage collection)
         8 (0.1%) 8 (0.1%) OpenSSL::Buffering#do_write
         5 (0.1%) 5 (0.1%) Concurrent::Collection::NonConcurrentMapBackend#get_or_default
         5 (0.1%) 5 (0.1%) Concurrent::Collection::NonConcurrentMapBackend#[]
         4 (0.1%) 4 (0.1%) Arel::Collectors::PlainString#<<
         4 (0.1%) 4 (0.1%) ActiveRecord::Relation#initialize_copy
         4 (0.1%) 4 (0.1%) ActiveSupport::PerThreadRegistry#instance
         3 (0.0%) 3 (0.0%) #<Module:0x0000000004808f78>.parse
         3 (0.0%) 3 (0.0%) OpenSSL::SSL::SSLContext#initialize
         3 (0.0%) 3 (0.0%) #<Module:0x0000000007cbb540>.blank?
         3 (0.0%) 3 (0.0%) Net::Protocol#ssl_socket_connect
         4 (0.1%) 3 (0.0%) ActiveModel::Type::Helpers::Numeric#cast
         4 (0.1%) 3 (0.0%) Nokogiri::XML::Node#write_to
         4 (0.1%) 3 (0.0%) #<Module:0x00000000063c6648>.reap_connections
         4 (0.1%) 3 (0.0%) MiniRacer::Context#timeout

```

---

_[View the full topic](https://meta.discourse.org/t/locking-issues-in-sidekiq-jobs/69287)._
