techarch-newrelic_rpm 2.10.2.1 → 2.10.2.2

Sign up to get free protection for your applications and to get access to all the features.
@@ -0,0 +1,27 @@
1
+ module NewRelic::Agent::Samplers
2
+ class DelayedJobLockSampler < NewRelic::Agent::Sampler
3
+ def initialize
4
+ super :delayed_job_lock
5
+ end
6
+
7
+ def stats
8
+ stats_engine.get_stats("DJ/Locked Jobs", false)
9
+ end
10
+
11
+ def local_env
12
+ NewRelic::Control.instance.local_env
13
+ end
14
+
15
+ def worker_name
16
+ local_env.dispatcher_instance_id
17
+ end
18
+
19
+ def locked_jobs
20
+ Delayed::Job.count(:conditions => {:locked_by => worker_name})
21
+ end
22
+
23
+ def poll
24
+ stats.record_data_point locked_jobs
25
+ end
26
+ end
27
+ end
@@ -0,0 +1,24 @@
1
+ module NewRelic
2
+ module Agent
3
+ module Samplers
4
+ class ObjectSampler < NewRelic::Agent::Sampler
5
+
6
+ def initialize
7
+ super :objects
8
+ end
9
+
10
+ def stats
11
+ stats_engine.get_stats_no_scope("GC/objects")
12
+ end
13
+
14
+ def self.supported_on_this_platform?
15
+ defined?(ObjectSpace) && ObjectSpace.respond_to?(:live_objects)
16
+ end
17
+
18
+ def poll
19
+ stats.record_data_point(ObjectSpace.live_objects)
20
+ end
21
+ end
22
+ end
23
+ end
24
+ end
@@ -2,7 +2,7 @@
2
2
 
3
3
  Gem::Specification.new do |s|
4
4
  s.name = %q{techarch-newrelic_rpm}
5
- s.version = "2.10.2.1"
5
+ s.version = "2.10.2.2"
6
6
 
7
7
  s.required_rubygems_version = Gem::Requirement.new(">= 1.2") if s.respond_to? :required_rubygems_version=
8
8
  s.authors = ["Bill Kayser" , "Philippe F. Monnet"]
@@ -10,7 +10,7 @@ Gem::Specification.new do |s|
10
10
  s.date = %q{2009-11-04}
11
11
  s.description = %q{New Relic Ruby Performance Monitoring Agent}
12
12
  s.executables = ["mongrel_rpm", "newrelic_cmd"]
13
- s.extra_rdoc_files = ["CHANGELOG", "LICENSE", "README.md", "bin/mongrel_rpm", "bin/newrelic_cmd", "lib/new_relic/agent.rb", "lib/new_relic/agent/agent.rb", "lib/new_relic/agent/chained_call.rb", "lib/new_relic/agent/collection_helper.rb", "lib/new_relic/agent/error_collector.rb", "lib/new_relic/agent/instrumentation/active_merchant.rb", "lib/new_relic/agent/instrumentation/active_record_instrumentation.rb", "lib/new_relic/agent/instrumentation/authlogic.rb", "lib/new_relic/agent/instrumentation/controller_instrumentation.rb", "lib/new_relic/agent/instrumentation/data_mapper.rb", "lib/new_relic/agent/instrumentation/dispatcher_instrumentation.rb", "lib/new_relic/agent/instrumentation/memcache.rb", "lib/new_relic/agent/instrumentation/merb/controller.rb", "lib/new_relic/agent/instrumentation/merb/dispatcher.rb", "lib/new_relic/agent/instrumentation/merb/errors.rb", "lib/new_relic/agent/instrumentation/net.rb", "lib/new_relic/agent/instrumentation/passenger_instrumentation.rb", "lib/new_relic/agent/instrumentation/rack.rb", "lib/new_relic/agent/instrumentation/rails/action_controller.rb", "lib/new_relic/agent/instrumentation/rails/action_web_service.rb", "lib/new_relic/agent/instrumentation/rails/dispatcher.rb", "lib/new_relic/agent/instrumentation/rails/errors.rb", "lib/new_relic/agent/instrumentation/sinatra.rb", "lib/new_relic/agent/method_tracer.rb", "lib/new_relic/agent/patch_const_missing.rb", "lib/new_relic/agent/sampler.rb", "lib/new_relic/agent/samplers/cpu_sampler.rb", "lib/new_relic/agent/samplers/memory_sampler.rb", "lib/new_relic/agent/samplers/mongrel_sampler.rb", "lib/new_relic/agent/shim_agent.rb", "lib/new_relic/agent/stats_engine.rb", "lib/new_relic/agent/stats_engine/metric_stats.rb", "lib/new_relic/agent/stats_engine/samplers.rb", "lib/new_relic/agent/stats_engine/transactions.rb", "lib/new_relic/agent/transaction_sampler.rb", "lib/new_relic/agent/worker_loop.rb", "lib/new_relic/commands/deployments.rb", "lib/new_relic/commands/new_relic_commands.rb", "lib/new_relic/control.rb", "lib/new_relic/control/external.rb", "lib/new_relic/control/merb.rb", "lib/new_relic/control/rails.rb", "lib/new_relic/control/ruby.rb", "lib/new_relic/control/sinatra.rb", "lib/new_relic/histogram.rb", "lib/new_relic/local_environment.rb", "lib/new_relic/merbtasks.rb", "lib/new_relic/metric_data.rb", "lib/new_relic/metric_parser.rb", "lib/new_relic/metric_parser/action_mailer.rb", "lib/new_relic/metric_parser/active_merchant.rb", "lib/new_relic/metric_parser/active_record.rb", "lib/new_relic/metric_parser/controller.rb", "lib/new_relic/metric_parser/controller_cpu.rb", "lib/new_relic/metric_parser/errors.rb", "lib/new_relic/metric_parser/external.rb", "lib/new_relic/metric_parser/mem_cache.rb", "lib/new_relic/metric_parser/view.rb", "lib/new_relic/metric_parser/web_frontend.rb", "lib/new_relic/metric_parser/web_service.rb", "lib/new_relic/metric_spec.rb", "lib/new_relic/metrics.rb", "lib/new_relic/noticed_error.rb", "lib/new_relic/rack/metric_app.rb", "lib/new_relic/rack/newrelic.ru", "lib/new_relic/rack/newrelic.yml", "lib/new_relic/rack_app.rb", "lib/new_relic/recipes.rb", "lib/new_relic/stats.rb", "lib/new_relic/transaction_analysis.rb", "lib/new_relic/transaction_sample.rb", "lib/new_relic/version.rb", "lib/new_relic_api.rb", "lib/newrelic_rpm.rb", "lib/tasks/all.rb", "lib/tasks/install.rake", "lib/tasks/tests.rake"]
13
+ s.extra_rdoc_files = ["CHANGELOG", "LICENSE", "README.md", "bin/mongrel_rpm", "bin/newrelic_cmd", "lib/new_relic/agent.rb", "lib/new_relic/agent/agent.rb", "lib/new_relic/agent/chained_call.rb", "lib/new_relic/agent/collection_helper.rb", "lib/new_relic/agent/error_collector.rb", "lib/new_relic/agent/instrumentation/active_merchant.rb", "lib/new_relic/agent/instrumentation/active_record_instrumentation.rb", "lib/new_relic/agent/instrumentation/authlogic.rb", "lib/new_relic/agent/instrumentation/controller_instrumentation.rb", "lib/new_relic/agent/instrumentation/data_mapper.rb", "lib/new_relic/agent/instrumentation/dispatcher_instrumentation.rb", "lib/new_relic/agent/instrumentation/memcache.rb", "lib/new_relic/agent/instrumentation/merb/controller.rb", "lib/new_relic/agent/instrumentation/merb/dispatcher.rb", "lib/new_relic/agent/instrumentation/merb/errors.rb", "lib/new_relic/agent/instrumentation/net.rb", "lib/new_relic/agent/instrumentation/passenger_instrumentation.rb", "lib/new_relic/agent/instrumentation/rack.rb", "lib/new_relic/agent/instrumentation/rails/action_controller.rb", "lib/new_relic/agent/instrumentation/rails/action_web_service.rb", "lib/new_relic/agent/instrumentation/rails/dispatcher.rb", "lib/new_relic/agent/instrumentation/rails/errors.rb", "lib/new_relic/agent/instrumentation/sinatra.rb", "lib/new_relic/agent/method_tracer.rb", "lib/new_relic/agent/patch_const_missing.rb", "lib/new_relic/agent/sampler.rb", "lib/new_relic/agent/samplers/cpu_sampler.rb", "lib/new_relic/agent/samplers/delayed_job_lock_sampler.rb", "lib/new_relic/agent/samplers/memory_sampler.rb", "lib/new_relic/agent/samplers/mongrel_sampler.rb", "lib/new_relic/agent/samplers/object_sampler.rb", "lib/new_relic/agent/shim_agent.rb", "lib/new_relic/agent/stats_engine.rb", "lib/new_relic/agent/stats_engine/metric_stats.rb", "lib/new_relic/agent/stats_engine/samplers.rb", "lib/new_relic/agent/stats_engine/transactions.rb", "lib/new_relic/agent/transaction_sampler.rb", "lib/new_relic/agent/worker_loop.rb", "lib/new_relic/commands/deployments.rb", "lib/new_relic/commands/new_relic_commands.rb", "lib/new_relic/control.rb", "lib/new_relic/control/external.rb", "lib/new_relic/control/merb.rb", "lib/new_relic/control/rails.rb", "lib/new_relic/control/ruby.rb", "lib/new_relic/control/sinatra.rb", "lib/new_relic/histogram.rb", "lib/new_relic/local_environment.rb", "lib/new_relic/merbtasks.rb", "lib/new_relic/metric_data.rb", "lib/new_relic/metric_parser.rb", "lib/new_relic/metric_parser/action_mailer.rb", "lib/new_relic/metric_parser/active_merchant.rb", "lib/new_relic/metric_parser/active_record.rb", "lib/new_relic/metric_parser/controller.rb", "lib/new_relic/metric_parser/controller_cpu.rb", "lib/new_relic/metric_parser/errors.rb", "lib/new_relic/metric_parser/external.rb", "lib/new_relic/metric_parser/mem_cache.rb", "lib/new_relic/metric_parser/view.rb", "lib/new_relic/metric_parser/web_frontend.rb", "lib/new_relic/metric_parser/web_service.rb", "lib/new_relic/metric_spec.rb", "lib/new_relic/metrics.rb", "lib/new_relic/noticed_error.rb", "lib/new_relic/rack/metric_app.rb", "lib/new_relic/rack/newrelic.ru", "lib/new_relic/rack/newrelic.yml", "lib/new_relic/rack_app.rb", "lib/new_relic/recipes.rb", "lib/new_relic/stats.rb", "lib/new_relic/transaction_analysis.rb", "lib/new_relic/transaction_sample.rb", "lib/new_relic/version.rb", "lib/new_relic_api.rb", "lib/newrelic_rpm.rb", "lib/tasks/all.rb", "lib/tasks/install.rake", "lib/tasks/tests.rake"]
14
14
  s.files = ["CHANGELOG", "LICENSE", "README.md", "Rakefile", "bin/mongrel_rpm", "bin/newrelic_cmd", "cert/cacert.pem", "init.rb", "install.rb", "lib/new_relic/agent.rb", "lib/new_relic/agent/agent.rb", "lib/new_relic/agent/chained_call.rb", "lib/new_relic/agent/collection_helper.rb", "lib/new_relic/agent/error_collector.rb", "lib/new_relic/agent/instrumentation/active_merchant.rb", "lib/new_relic/agent/instrumentation/active_record_instrumentation.rb", "lib/new_relic/agent/instrumentation/authlogic.rb", "lib/new_relic/agent/instrumentation/controller_instrumentation.rb", "lib/new_relic/agent/instrumentation/data_mapper.rb", "lib/new_relic/agent/instrumentation/dispatcher_instrumentation.rb", "lib/new_relic/agent/instrumentation/memcache.rb", "lib/new_relic/agent/instrumentation/merb/controller.rb", "lib/new_relic/agent/instrumentation/merb/dispatcher.rb", "lib/new_relic/agent/instrumentation/merb/errors.rb", "lib/new_relic/agent/instrumentation/net.rb", "lib/new_relic/agent/instrumentation/passenger_instrumentation.rb", "lib/new_relic/agent/instrumentation/rack.rb", "lib/new_relic/agent/instrumentation/rails/action_controller.rb", "lib/new_relic/agent/instrumentation/rails/action_web_service.rb", "lib/new_relic/agent/instrumentation/rails/dispatcher.rb", "lib/new_relic/agent/instrumentation/rails/errors.rb", "lib/new_relic/agent/instrumentation/sinatra.rb", "lib/new_relic/agent/method_tracer.rb", "lib/new_relic/agent/patch_const_missing.rb", "lib/new_relic/agent/sampler.rb", "lib/new_relic/agent/samplers/cpu_sampler.rb", "lib/new_relic/agent/samplers/memory_sampler.rb", "lib/new_relic/agent/samplers/mongrel_sampler.rb", "lib/new_relic/agent/shim_agent.rb", "lib/new_relic/agent/stats_engine.rb", "lib/new_relic/agent/stats_engine/metric_stats.rb", "lib/new_relic/agent/stats_engine/samplers.rb", "lib/new_relic/agent/stats_engine/transactions.rb", "lib/new_relic/agent/transaction_sampler.rb", "lib/new_relic/agent/worker_loop.rb", "lib/new_relic/commands/deployments.rb", "lib/new_relic/commands/new_relic_commands.rb", "lib/new_relic/control.rb", "lib/new_relic/control/external.rb", "lib/new_relic/control/merb.rb", "lib/new_relic/control/rails.rb", "lib/new_relic/control/ruby.rb", "lib/new_relic/control/sinatra.rb", "lib/new_relic/histogram.rb", "lib/new_relic/local_environment.rb", "lib/new_relic/merbtasks.rb", "lib/new_relic/metric_data.rb", "lib/new_relic/metric_parser.rb", "lib/new_relic/metric_parser/action_mailer.rb", "lib/new_relic/metric_parser/active_merchant.rb", "lib/new_relic/metric_parser/active_record.rb", "lib/new_relic/metric_parser/controller.rb", "lib/new_relic/metric_parser/controller_cpu.rb", "lib/new_relic/metric_parser/errors.rb", "lib/new_relic/metric_parser/external.rb", "lib/new_relic/metric_parser/mem_cache.rb", "lib/new_relic/metric_parser/view.rb", "lib/new_relic/metric_parser/web_frontend.rb", "lib/new_relic/metric_parser/web_service.rb", "lib/new_relic/metric_spec.rb", "lib/new_relic/metrics.rb", "lib/new_relic/noticed_error.rb", "lib/new_relic/rack/metric_app.rb", "lib/new_relic/rack/newrelic.ru", "lib/new_relic/rack/newrelic.yml", "lib/new_relic/rack_app.rb", "lib/new_relic/recipes.rb", "lib/new_relic/stats.rb", "lib/new_relic/transaction_analysis.rb", "lib/new_relic/transaction_sample.rb", "lib/new_relic/version.rb", "lib/new_relic_api.rb", "lib/newrelic_rpm.rb", "lib/tasks/all.rb", "lib/tasks/install.rake", "lib/tasks/tests.rake", "newrelic.yml", "recipes/newrelic.rb", "test/active_record_fixtures.rb", "test/config/newrelic.yml", "test/config/test_control.rb", "test/new_relic/agent/active_record_instrumentation_test.rb", "test/new_relic/agent/agent_controller_test.rb", "test/new_relic/agent/agent_test.rb", "test/new_relic/agent/agent_test_controller.rb", "test/new_relic/agent/classloader_patch_test.rb", "test/new_relic/agent/collection_helper_test.rb", "test/new_relic/agent/dispatcher_instrumentation_test.rb", "test/new_relic/agent/error_collector_test.rb", "test/new_relic/agent/method_tracer_test.rb", "test/new_relic/agent/metric_data_test.rb", "test/new_relic/agent/mock_ar_connection.rb", "test/new_relic/agent/mock_scope_listener.rb", "test/new_relic/agent/net_instrumentation_test.rb", "test/new_relic/agent/stats_engine/metric_stats_test.rb", "test/new_relic/agent/stats_engine/samplers_test.rb", "test/new_relic/agent/stats_engine/stats_engine_test.rb", "test/new_relic/agent/task_instrumentation_test.rb", "test/new_relic/agent/testable_agent.rb", "test/new_relic/agent/transaction_sample_builder_test.rb", "test/new_relic/agent/transaction_sample_test.rb", "test/new_relic/agent/transaction_sampler_test.rb", "test/new_relic/agent/worker_loop_test.rb", "test/new_relic/control_test.rb", "test/new_relic/deployments_api_test.rb", "test/new_relic/environment_test.rb", "test/new_relic/metric_parser_test.rb", "test/new_relic/metric_spec_test.rb", "test/new_relic/shim_agent_test.rb", "test/new_relic/stats_test.rb", "test/new_relic/version_number_test.rb", "test/test_helper.rb", "test/ui/newrelic_controller_test.rb", "test/ui/newrelic_helper_test.rb", "ui/controllers/newrelic_controller.rb", "ui/helpers/google_pie_chart.rb", "ui/helpers/newrelic_helper.rb", "ui/views/layouts/newrelic_default.rhtml", "ui/views/newrelic/_explain_plans.rhtml", "ui/views/newrelic/_sample.rhtml", "ui/views/newrelic/_segment.rhtml", "ui/views/newrelic/_segment_limit_message.rhtml", "ui/views/newrelic/_segment_row.rhtml", "ui/views/newrelic/_show_sample_detail.rhtml", "ui/views/newrelic/_show_sample_sql.rhtml", "ui/views/newrelic/_show_sample_summary.rhtml", "ui/views/newrelic/_sql_row.rhtml", "ui/views/newrelic/_stack_trace.rhtml", "ui/views/newrelic/_table.rhtml", "ui/views/newrelic/explain_sql.rhtml", "ui/views/newrelic/images/arrow-close.png", "ui/views/newrelic/images/arrow-open.png", "ui/views/newrelic/images/blue_bar.gif", "ui/views/newrelic/images/file_icon.png", "ui/views/newrelic/images/gray_bar.gif", "ui/views/newrelic/images/new_relic_rpm_desktop.gif", "ui/views/newrelic/images/textmate.png", "ui/views/newrelic/index.rhtml", "ui/views/newrelic/javascript/prototype-scriptaculous.js", "ui/views/newrelic/javascript/transaction_sample.js", "ui/views/newrelic/sample_not_found.rhtml", "ui/views/newrelic/show_sample.rhtml", "ui/views/newrelic/show_source.rhtml", "ui/views/newrelic/stylesheets/style.css", "ui/views/newrelic/threads.rhtml", "Manifest", "techarch-newrelic_rpm.gemspec"]
15
15
  s.homepage = %q{http://www.newrelic.com}
16
16
  s.rdoc_options = ["--line-numbers", "--inline-source", "--title", "techarch-newrelic_rpm", "--main", "README.md"]
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: techarch-newrelic_rpm
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.10.2.1
4
+ version: 2.10.2.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Bill Kayser
@@ -56,8 +56,10 @@ extra_rdoc_files:
56
56
  - lib/new_relic/agent/patch_const_missing.rb
57
57
  - lib/new_relic/agent/sampler.rb
58
58
  - lib/new_relic/agent/samplers/cpu_sampler.rb
59
+ - lib/new_relic/agent/samplers/delayed_job_lock_sampler.rb
59
60
  - lib/new_relic/agent/samplers/memory_sampler.rb
60
61
  - lib/new_relic/agent/samplers/mongrel_sampler.rb
62
+ - lib/new_relic/agent/samplers/object_sampler.rb
61
63
  - lib/new_relic/agent/shim_agent.rb
62
64
  - lib/new_relic/agent/stats_engine.rb
63
65
  - lib/new_relic/agent/stats_engine/metric_stats.rb
@@ -264,6 +266,8 @@ files:
264
266
  - ui/views/newrelic/threads.rhtml
265
267
  - Manifest
266
268
  - techarch-newrelic_rpm.gemspec
269
+ - lib/new_relic/agent/samplers/delayed_job_lock_sampler.rb
270
+ - lib/new_relic/agent/samplers/object_sampler.rb
267
271
  has_rdoc: true
268
272
  homepage: http://www.newrelic.com
269
273
  licenses: []