wd_newrelic_rpm 3.3.4.1 → 3.5.5

Sign up to get free protection for your applications and to get access to all the features.
Files changed (290) hide show
  1. data/.gitignore +20 -0
  2. data/.project +23 -0
  3. data/.travis.yml +9 -0
  4. data/CHANGELOG +317 -39
  5. data/GUIDELINES_FOR_CONTRIBUTING.md +76 -0
  6. data/Gemfile +16 -0
  7. data/LICENSE +1 -1
  8. data/{README.rdoc → README.md} +71 -55
  9. data/Rakefile +62 -0
  10. data/bin/mongrel_rpm +1 -1
  11. data/config.dot +290 -0
  12. data/config/database.yml +5 -0
  13. data/init.rb +31 -0
  14. data/lib/new_relic/agent.rb +31 -60
  15. data/lib/new_relic/agent/agent.rb +277 -502
  16. data/lib/new_relic/agent/agent_logger.rb +165 -0
  17. data/lib/new_relic/agent/audit_logger.rb +72 -0
  18. data/lib/new_relic/agent/beacon_configuration.rb +36 -50
  19. data/lib/new_relic/agent/browser_monitoring.rb +114 -61
  20. data/lib/new_relic/agent/busy_calculator.rb +14 -6
  21. data/lib/new_relic/agent/configuration.rb +74 -0
  22. data/lib/new_relic/agent/configuration/defaults.rb +126 -0
  23. data/lib/new_relic/agent/configuration/environment_source.rb +49 -0
  24. data/lib/new_relic/agent/configuration/manager.rb +136 -0
  25. data/lib/new_relic/agent/configuration/mask_defaults.rb +10 -0
  26. data/lib/new_relic/agent/configuration/server_source.rb +27 -0
  27. data/lib/new_relic/agent/configuration/yaml_source.rb +63 -0
  28. data/lib/new_relic/agent/cross_process_monitoring.rb +43 -0
  29. data/lib/new_relic/agent/database.rb +39 -26
  30. data/lib/new_relic/agent/error_collector.rb +48 -49
  31. data/lib/new_relic/agent/instrumentation/active_merchant.rb +1 -1
  32. data/lib/new_relic/agent/instrumentation/active_record.rb +4 -7
  33. data/lib/new_relic/agent/instrumentation/acts_as_solr.rb +1 -1
  34. data/lib/new_relic/agent/instrumentation/authlogic.rb +1 -1
  35. data/lib/new_relic/agent/instrumentation/browser_monitoring_timings.rb +41 -0
  36. data/lib/new_relic/agent/instrumentation/controller_instrumentation.rb +35 -12
  37. data/lib/new_relic/agent/instrumentation/data_mapper.rb +4 -12
  38. data/lib/new_relic/agent/instrumentation/delayed_job_instrumentation.rb +2 -2
  39. data/lib/new_relic/agent/instrumentation/memcache.rb +6 -6
  40. data/lib/new_relic/agent/instrumentation/merb/controller.rb +1 -1
  41. data/lib/new_relic/agent/instrumentation/merb/errors.rb +1 -1
  42. data/lib/new_relic/agent/instrumentation/metric_frame.rb +4 -14
  43. data/lib/new_relic/agent/instrumentation/metric_frame/pop.rb +1 -1
  44. data/lib/new_relic/agent/instrumentation/net.rb +1 -1
  45. data/lib/new_relic/agent/instrumentation/passenger_instrumentation.rb +6 -20
  46. data/lib/new_relic/agent/instrumentation/queue_time.rb +2 -2
  47. data/lib/new_relic/agent/instrumentation/rack.rb +1 -1
  48. data/lib/new_relic/agent/instrumentation/rails/action_controller.rb +7 -7
  49. data/lib/new_relic/agent/instrumentation/rails/action_web_service.rb +1 -1
  50. data/lib/new_relic/agent/instrumentation/rails/errors.rb +1 -1
  51. data/lib/new_relic/agent/instrumentation/rails3/action_controller.rb +5 -5
  52. data/lib/new_relic/agent/instrumentation/rails3/errors.rb +6 -2
  53. data/lib/new_relic/agent/instrumentation/resque.rb +81 -0
  54. data/lib/new_relic/agent/instrumentation/sinatra.rb +21 -10
  55. data/lib/new_relic/agent/instrumentation/sunspot.rb +1 -1
  56. data/lib/new_relic/agent/instrumentation/unicorn_instrumentation.rb +5 -4
  57. data/lib/new_relic/agent/method_tracer.rb +11 -9
  58. data/lib/new_relic/agent/new_relic_service.rb +379 -0
  59. data/lib/new_relic/agent/pipe_channel_manager.rb +175 -0
  60. data/lib/new_relic/agent/pipe_service.rb +58 -0
  61. data/lib/new_relic/agent/samplers/delayed_job_sampler.rb +86 -0
  62. data/lib/new_relic/agent/samplers/memory_sampler.rb +6 -8
  63. data/lib/new_relic/agent/sql_sampler.rb +31 -74
  64. data/lib/new_relic/agent/stats_engine.rb +0 -5
  65. data/lib/new_relic/agent/stats_engine/gc_profiler.rb +40 -24
  66. data/lib/new_relic/agent/stats_engine/metric_stats.rb +89 -14
  67. data/lib/new_relic/agent/stats_engine/samplers.rb +9 -7
  68. data/lib/new_relic/agent/stats_engine/transactions.rb +20 -12
  69. data/lib/new_relic/agent/thread.rb +32 -0
  70. data/lib/new_relic/agent/thread_profiler.rb +306 -0
  71. data/lib/new_relic/agent/transaction_info.rb +24 -4
  72. data/lib/new_relic/agent/transaction_sample_builder.rb +12 -13
  73. data/lib/new_relic/agent/transaction_sampler.rb +49 -65
  74. data/lib/new_relic/agent/worker_loop.rb +31 -25
  75. data/lib/new_relic/collection_helper.rb +1 -1
  76. data/lib/new_relic/commands/deployments.rb +19 -10
  77. data/lib/new_relic/control.rb +1 -3
  78. data/lib/new_relic/control/class_methods.rb +10 -5
  79. data/lib/new_relic/control/frameworks/merb.rb +0 -6
  80. data/lib/new_relic/control/frameworks/rails.rb +30 -45
  81. data/lib/new_relic/control/frameworks/rails3.rb +23 -18
  82. data/lib/new_relic/control/frameworks/rails4.rb +23 -0
  83. data/lib/new_relic/control/frameworks/ruby.rb +2 -23
  84. data/lib/new_relic/control/instance_methods.rb +35 -73
  85. data/lib/new_relic/control/instrumentation.rb +7 -12
  86. data/lib/new_relic/control/server_methods.rb +17 -19
  87. data/lib/new_relic/delayed_job_injection.rb +2 -2
  88. data/lib/new_relic/helper.rb +34 -0
  89. data/lib/new_relic/language_support.rb +56 -37
  90. data/lib/new_relic/local_environment.rb +32 -67
  91. data/lib/new_relic/metric_data.rb +10 -2
  92. data/lib/new_relic/metric_spec.rb +7 -3
  93. data/lib/new_relic/noticed_error.rb +32 -9
  94. data/lib/new_relic/rack.rb +4 -0
  95. data/lib/new_relic/rack/browser_monitoring.rb +34 -25
  96. data/lib/new_relic/rack/developer_mode.rb +3 -0
  97. data/lib/new_relic/rack/error_collector.rb +56 -0
  98. data/lib/new_relic/stats.rb +9 -7
  99. data/lib/new_relic/transaction_sample.rb +19 -18
  100. data/lib/new_relic/transaction_sample/segment.rb +13 -15
  101. data/lib/new_relic/version.rb +19 -3
  102. data/lib/newrelic_rpm.rb +1 -1
  103. data/lib/tasks/tests.rake +6 -8
  104. data/newrelic.yml +15 -32
  105. data/newrelic_rpm.gemspec +224 -43
  106. data/newrelic_rpm.gemspec.erb +54 -0
  107. data/test/config/newrelic.yml +4 -3
  108. data/test/config/test_control.rb +18 -18
  109. data/test/fixtures/gemspec_no_build.rb +442 -0
  110. data/test/fixtures/gemspec_with_build.rb +442 -0
  111. data/test/fixtures/gemspec_with_build_and_stage.rb +442 -0
  112. data/test/intentional_fail.rb +10 -0
  113. data/test/multiverse/.gitignore +10 -0
  114. data/test/multiverse/README.md +85 -0
  115. data/test/multiverse/lib/multiverse/color.rb +13 -0
  116. data/test/multiverse/lib/multiverse/envfile.rb +66 -0
  117. data/test/multiverse/lib/multiverse/environment.rb +16 -0
  118. data/test/multiverse/lib/multiverse/output_collector.rb +29 -0
  119. data/test/multiverse/lib/multiverse/runner.rb +44 -0
  120. data/test/multiverse/lib/multiverse/suite.rb +162 -0
  121. data/test/multiverse/script/run_one +3 -0
  122. data/test/multiverse/script/runner +9 -0
  123. data/test/multiverse/suites/active_record/Envfile +13 -0
  124. data/test/multiverse/suites/active_record/ar_method_aliasing.rb +94 -0
  125. data/test/multiverse/suites/active_record/config/newrelic.yml +22 -0
  126. data/test/multiverse/suites/active_record/encoding_test.rb +26 -0
  127. data/test/multiverse/suites/agent_only/Envfile +4 -0
  128. data/test/multiverse/suites/agent_only/audit_log_test.rb +99 -0
  129. data/test/multiverse/suites/agent_only/config/newrelic.yml +22 -0
  130. data/test/multiverse/suites/agent_only/http_response_code_test.rb +53 -0
  131. data/test/multiverse/suites/agent_only/marshaling_test.rb +109 -0
  132. data/test/multiverse/suites/agent_only/method_visibility_test.rb +98 -0
  133. data/test/multiverse/suites/agent_only/pipe_manager_test.rb +33 -0
  134. data/test/multiverse/suites/agent_only/service_timeout_test.rb +29 -0
  135. data/test/multiverse/suites/agent_only/test_trace_method_with_punctuation.rb +30 -0
  136. data/test/multiverse/suites/agent_only/test_trace_transaction_with_punctuation.rb +32 -0
  137. data/test/multiverse/suites/agent_only/thread_profiling_test.rb +80 -0
  138. data/test/multiverse/suites/config_file_loading/Envfile +7 -0
  139. data/test/multiverse/suites/config_file_loading/config_file_loading_test.rb +106 -0
  140. data/test/multiverse/suites/datamapper/Envfile +8 -0
  141. data/test/multiverse/suites/datamapper/config/newrelic.yml +22 -0
  142. data/test/multiverse/suites/datamapper/encoding_test.rb +36 -0
  143. data/test/multiverse/suites/logging/Envfile +4 -0
  144. data/test/multiverse/suites/logging/config/newrelic.yml +22 -0
  145. data/test/multiverse/suites/logging/logging_test.rb +143 -0
  146. data/test/multiverse/suites/monitor_mode_false/Envfile +2 -0
  147. data/test/multiverse/suites/monitor_mode_false/config/newrelic.yml +25 -0
  148. data/test/multiverse/suites/monitor_mode_false/no_dns_resolv.rb +29 -0
  149. data/test/multiverse/suites/no_load/Envfile +2 -0
  150. data/test/multiverse/suites/no_load/config/newrelic.yml +22 -0
  151. data/test/multiverse/suites/no_load/start_up_test.rb +14 -0
  152. data/test/multiverse/suites/rails_3_error_tracing/Envfile +15 -0
  153. data/test/multiverse/suites/rails_3_error_tracing/config/newrelic.yml +165 -0
  154. data/test/multiverse/suites/rails_3_error_tracing/error_tracing_test.rb +236 -0
  155. data/test/multiverse/suites/rails_3_gc/Envfile +8 -0
  156. data/test/multiverse/suites/rails_3_gc/config/newrelic.yml +167 -0
  157. data/test/multiverse/suites/rails_3_gc/instrumentation_test.rb +92 -0
  158. data/test/multiverse/suites/rails_3_queue_time/Envfile +15 -0
  159. data/test/multiverse/suites/rails_3_queue_time/config/newrelic.yml +165 -0
  160. data/test/multiverse/suites/rails_3_queue_time/queue_time_test.rb +75 -0
  161. data/test/multiverse/suites/rails_3_views/.gitignore +3 -0
  162. data/test/multiverse/suites/rails_3_views/Envfile +16 -0
  163. data/test/multiverse/suites/rails_3_views/app/views/foos/_foo.html.haml +1 -0
  164. data/test/multiverse/suites/rails_3_views/app/views/test/_a_partial.html.erb +1 -0
  165. data/test/multiverse/suites/rails_3_views/app/views/test/_mid_partial.html.erb +1 -0
  166. data/test/multiverse/suites/rails_3_views/app/views/test/_top_partial.html.erb +3 -0
  167. data/test/multiverse/suites/rails_3_views/app/views/test/deep_partial.html.erb +3 -0
  168. data/test/multiverse/suites/rails_3_views/app/views/test/haml_view.html.haml +6 -0
  169. data/test/multiverse/suites/rails_3_views/app/views/test/index.html.erb +4 -0
  170. data/test/multiverse/suites/rails_3_views/config/newrelic.yml +164 -0
  171. data/test/multiverse/suites/rails_3_views/view_instrumentation_test.rb +245 -0
  172. data/test/multiverse/suites/resque/Envfile +21 -0
  173. data/test/multiverse/suites/resque/config/newrelic.yml +22 -0
  174. data/test/multiverse/suites/resque/dump.rdb +0 -0
  175. data/test/multiverse/suites/resque/instrumentation_test.rb +73 -0
  176. data/test/multiverse/suites/rum_auto_instrumentation/Envfile +4 -0
  177. data/test/multiverse/suites/rum_auto_instrumentation/config/newrelic.yml +24 -0
  178. data/test/multiverse/suites/rum_auto_instrumentation/responses/worst_case_small.html +5000 -0
  179. data/test/multiverse/suites/rum_auto_instrumentation/sanity_test.rb +102 -0
  180. data/test/multiverse/suites/sinatra/Envfile +13 -0
  181. data/test/multiverse/suites/sinatra/config/newrelic.yml +24 -0
  182. data/test/multiverse/suites/sinatra/sinatra_metric_explosion_test.rb +77 -0
  183. data/test/multiverse/suites/sinatra/sinatra_routes_test.rb +46 -0
  184. data/test/multiverse/suites/sinatra/sinatra_test.rb +55 -0
  185. data/test/multiverse/test/multiverse_test.rb +55 -0
  186. data/test/multiverse/test/suite_examples/one/a/Envfile +3 -0
  187. data/test/multiverse/test/suite_examples/one/a/a_test.rb +11 -0
  188. data/test/multiverse/test/suite_examples/one/a/config/newrelic.yml +24 -0
  189. data/test/multiverse/test/suite_examples/one/b/Envfile +3 -0
  190. data/test/multiverse/test/suite_examples/one/b/b_test.rb +11 -0
  191. data/test/multiverse/test/suite_examples/one/b/config/newrelic.yml +24 -0
  192. data/test/multiverse/test/suite_examples/three/a/Envfile +2 -0
  193. data/test/multiverse/test/suite_examples/three/a/fail_test.rb +6 -0
  194. data/test/multiverse/test/suite_examples/three/b/Envfile +2 -0
  195. data/test/multiverse/test/suite_examples/three/b/win_test.rb +6 -0
  196. data/test/multiverse/test/suite_examples/two/a/Envfile +1 -0
  197. data/test/multiverse/test/suite_examples/two/a/fail_test.rb +6 -0
  198. data/test/new_relic/agent/agent/connect_test.rb +151 -227
  199. data/test/new_relic/agent/agent/start_test.rb +68 -118
  200. data/test/new_relic/agent/agent/start_worker_thread_test.rb +12 -74
  201. data/test/new_relic/agent/agent_logger_test.rb +153 -0
  202. data/test/new_relic/agent/agent_test.rb +116 -30
  203. data/test/new_relic/agent/agent_test_controller.rb +1 -1
  204. data/test/new_relic/agent/agent_test_controller_test.rb +42 -10
  205. data/test/new_relic/agent/audit_logger_test.rb +105 -0
  206. data/test/new_relic/agent/beacon_configuration_test.rb +63 -67
  207. data/test/new_relic/agent/browser_monitoring_test.rb +151 -79
  208. data/test/new_relic/agent/busy_calculator_test.rb +7 -0
  209. data/test/new_relic/agent/configuration/environment_source_test.rb +79 -0
  210. data/test/new_relic/agent/configuration/manager_test.rb +204 -0
  211. data/test/new_relic/agent/configuration/server_source_test.rb +45 -0
  212. data/test/new_relic/agent/configuration/yaml_source_test.rb +75 -0
  213. data/test/new_relic/agent/cross_process_monitoring_test.rb +77 -0
  214. data/test/new_relic/agent/database_test.rb +12 -11
  215. data/test/new_relic/agent/error_collector/notice_error_test.rb +64 -53
  216. data/test/new_relic/agent/error_collector_test.rb +33 -19
  217. data/test/new_relic/agent/instrumentation/active_record_instrumentation_test.rb +60 -30
  218. data/test/new_relic/agent/instrumentation/browser_monitoring_timings_test.rb +39 -0
  219. data/test/new_relic/agent/instrumentation/metric_frame/pop_test.rb +1 -1
  220. data/test/new_relic/agent/instrumentation/metric_frame_test.rb +6 -0
  221. data/test/new_relic/agent/instrumentation/queue_time_test.rb +14 -0
  222. data/test/new_relic/agent/instrumentation/sinatra_test.rb +25 -0
  223. data/test/new_relic/agent/instrumentation/task_instrumentation_test.rb +2 -2
  224. data/test/new_relic/agent/method_tracer/class_methods/add_method_tracer_test.rb +4 -10
  225. data/test/new_relic/agent/method_tracer/instance_methods/trace_execution_scoped_test.rb +3 -15
  226. data/test/new_relic/agent/method_tracer_test.rb +7 -6
  227. data/test/new_relic/agent/mock_scope_listener.rb +3 -0
  228. data/test/new_relic/agent/new_relic_service_test.rb +376 -0
  229. data/test/new_relic/agent/pipe_channel_manager_test.rb +131 -0
  230. data/test/new_relic/agent/pipe_service_test.rb +113 -0
  231. data/test/new_relic/agent/rpm_agent_test.rb +27 -50
  232. data/test/new_relic/agent/sql_sampler_test.rb +81 -56
  233. data/test/new_relic/agent/stats_engine/metric_stats/harvest_test.rb +3 -20
  234. data/test/new_relic/agent/stats_engine/metric_stats_test.rb +12 -1
  235. data/test/new_relic/agent/stats_engine_test.rb +17 -8
  236. data/test/new_relic/agent/thread_profiler_test.rb +537 -0
  237. data/test/new_relic/agent/thread_test.rb +89 -0
  238. data/test/new_relic/agent/threaded_test.rb +65 -0
  239. data/test/new_relic/agent/transaction_info_test.rb +45 -4
  240. data/test/new_relic/agent/transaction_sample_builder_test.rb +8 -7
  241. data/test/new_relic/agent/transaction_sampler_test.rb +193 -204
  242. data/test/new_relic/agent/worker_loop_test.rb +26 -11
  243. data/test/new_relic/agent_test.rb +113 -33
  244. data/test/new_relic/collection_helper_test.rb +7 -8
  245. data/test/new_relic/command/deployments_test.rb +18 -2
  246. data/test/new_relic/control/class_methods_test.rb +0 -18
  247. data/test/new_relic/control/frameworks/rails_test.rb +26 -0
  248. data/test/new_relic/control_test.rb +96 -137
  249. data/test/new_relic/delayed_job_injection_test.rb +6 -1
  250. data/test/new_relic/dispatcher_test.rb +54 -0
  251. data/test/new_relic/fake_collector.rb +283 -0
  252. data/test/new_relic/fake_service.rb +53 -0
  253. data/test/new_relic/fakes_sending_data.rb +30 -0
  254. data/test/new_relic/framework_test.rb +53 -0
  255. data/test/new_relic/load_test.rb +13 -0
  256. data/test/new_relic/local_environment_test.rb +11 -11
  257. data/test/new_relic/metric_data_test.rb +45 -16
  258. data/test/new_relic/noticed_error_test.rb +24 -0
  259. data/test/new_relic/rack/browser_monitoring_test.rb +20 -10
  260. data/test/new_relic/rack/developer_mode_test.rb +13 -7
  261. data/test/new_relic/rack/error_collector_test.rb +74 -0
  262. data/test/new_relic/stats_test.rb +10 -0
  263. data/test/new_relic/transaction_sample/segment_test.rb +23 -4
  264. data/test/new_relic/transaction_sample_test.rb +47 -2
  265. data/test/new_relic/version_number_test.rb +32 -0
  266. data/test/script/build_test_gem.sh +9 -3
  267. data/test/script/ci.sh +108 -35
  268. data/test/script/ci_agent-tests_runner.sh +82 -0
  269. data/test/script/ci_multiverse_runner.sh +63 -0
  270. data/test/test_contexts.rb +1 -0
  271. data/test/test_helper.rb +68 -18
  272. data/ui/helpers/developer_mode_helper.rb +21 -11
  273. data/ui/views/layouts/newrelic_default.rhtml +1 -0
  274. data/ui/views/newrelic/file/images/arrow-close.png +0 -0
  275. data/ui/views/newrelic/file/images/arrow-open.png +0 -0
  276. data/ui/views/newrelic/file/images/blue_bar.gif +0 -0
  277. data/ui/views/newrelic/file/images/file_icon.png +0 -0
  278. data/ui/views/newrelic/file/images/gray_bar.gif +0 -0
  279. data/ui/views/newrelic/show_sample.rhtml +1 -1
  280. data/ui/views/newrelic/threads.rhtml +2 -10
  281. data/vendor/gems/metric_parser-0.1.0.pre1/.specification +116 -0
  282. data/vendor/gems/metric_parser-0.1.0.pre1/lib/new_relic/metric_parser/servlet_init.rb +7 -0
  283. metadata +191 -65
  284. data/lib/new_relic/agent/samplers/delayed_job_lock_sampler.rb +0 -40
  285. data/lib/new_relic/control/configuration.rb +0 -206
  286. data/lib/new_relic/control/logging_methods.rb +0 -143
  287. data/lib/new_relic/data_serialization.rb +0 -151
  288. data/test/new_relic/control/configuration_test.rb +0 -84
  289. data/test/new_relic/control/logging_methods_test.rb +0 -185
  290. data/test/new_relic/data_serialization_test.rb +0 -208
@@ -7,6 +7,7 @@ module TestContexts
7
7
  setup do
8
8
  @log_data = StringIO.new
9
9
  @log = Logger.new(@log_data)
10
+ NewRelic::Agent::Agent.instance.service = NewRelic::FakeService.new
10
11
  NewRelic::Agent.manual_start :log => @log
11
12
  @agent = NewRelic::Agent.instance
12
13
  @agent.transaction_sampler.send :clear_builder
data/test/test_helper.rb CHANGED
@@ -3,46 +3,57 @@ ENV['RAILS_ENV'] = 'test'
3
3
  NEWRELIC_PLUGIN_DIR = File.expand_path(File.join(File.dirname(__FILE__),".."))
4
4
  $LOAD_PATH << '.'
5
5
  $LOAD_PATH << '../../..'
6
+ $LOAD_PATH << File.join(NEWRELIC_PLUGIN_DIR,"lib")
6
7
  $LOAD_PATH << File.join(NEWRELIC_PLUGIN_DIR,"test")
7
8
  $LOAD_PATH << File.join(NEWRELIC_PLUGIN_DIR,"ui/helpers")
8
9
  $LOAD_PATH.uniq!
9
10
 
10
11
  require 'rubygems'
12
+ require 'rake'
11
13
  # We can speed things up in tests that don't need to load rails.
12
14
  # You can also run the tests in a mode without rails. Many tests
13
15
  # will be skipped.
14
16
 
15
17
  begin
16
18
  require 'config/environment'
17
- # require File.join(File.dirname(__FILE__),'..','..','rpm_test_app','config','environment')
19
+ # require File.join(File.dirname(__FILE__),'..','..','rpm_test_app','config','environment')
18
20
  begin
19
21
  require 'test_help'
20
22
  rescue LoadError
21
23
  # ignore load problems on test help - it doesn't exist in rails 3
22
24
  end
23
-
24
- rescue LoadError
25
- # To run the tests against a standalone agent build, you need to
26
- # add a rails app to the load path. It can be 2.* to 3.*. It should
27
- # referenc newrelic_rpm in the Gemfile with a :path option pointing
28
- # to this work directory.
29
- guess = File.expand_path("../../../rpm", __FILE__)
30
- if $LOAD_PATH.include? guess
31
- puts "Unable to load Rails for New Relic tests. See note in test_helper.rb"
32
- raise
33
- else
34
- $LOAD_PATH << guess
35
- retry
25
+ require 'newrelic_rpm'
26
+ rescue LoadError => e
27
+ puts "Running tests in standalone mode."
28
+ require 'bundler'
29
+ Bundler.require
30
+ require 'rails/all'
31
+ require 'newrelic_rpm'
32
+
33
+ # Bootstrap a basic rails environment for the agent to run in.
34
+ class MyApp < Rails::Application
35
+ config.active_support.deprecation = :log
36
+ config.secret_token = "49837489qkuweoiuoqwehisuakshdjksadhaisdy78o34y138974xyqp9rmye8yrpiokeuioqwzyoiuxftoyqiuxrhm3iou1hrzmjk"
37
+ config.after_initialize do
38
+ NewRelic::Agent.manual_start
39
+ end
36
40
  end
41
+ MyApp.initialize!
42
+
37
43
  end
38
- require 'newrelic_rpm'
39
44
 
40
45
  require 'test/unit'
41
46
  require 'shoulda'
42
47
  require 'test_contexts'
43
48
  require 'mocha'
44
- require 'mocha/integration/test_unit'
45
- require 'mocha/integration/test_unit/assertion_counter'
49
+
50
+ begin # 1.8.6
51
+ require 'mocha/integration/test_unit'
52
+ require 'mocha/integration/test_unit/assertion_counter'
53
+ rescue LoadError
54
+ end
55
+
56
+ require 'new_relic/fake_service'
46
57
 
47
58
  class Test::Unit::TestCase
48
59
  include Mocha::API
@@ -116,7 +127,47 @@ def compare_metrics(expected, actual)
116
127
  assert_equal(expected.to_a.sort, actual.to_a.sort, "extra: #{(actual - expected).to_a.inspect}; missing: #{(expected - actual).to_a.inspect}")
117
128
  end
118
129
 
130
+ def with_config(config_hash, level=0)
131
+ config = NewRelic::Agent::Configuration::DottedHash.new(config_hash)
132
+ NewRelic::Agent.config.apply_config(config, level)
133
+ begin
134
+ yield
135
+ ensure
136
+ NewRelic::Agent.config.remove_config(config)
137
+ end
138
+ end
139
+
140
+ # Need to be a bit sloppy when testing against the logging--let everything
141
+ # through, but check we (at least) get our particular message we care about
142
+ def expects_logging(level, *with_params)
143
+ ::NewRelic::Agent.logger.stubs(level)
144
+ ::NewRelic::Agent.logger.expects(level).with(*with_params).once
145
+ end
146
+
147
+ # Similarly, have to be specific about the message we "never" expect...
148
+ def expects_no_logging(level, *with_params)
149
+ ::NewRelic::Agent.logger.stubs(level)
150
+ ::NewRelic::Agent.logger.expects(level).with(*with_params).never
151
+ end
152
+
153
+ # Sometimes need to test cases where we muddle with the global logger
154
+ # If so, use this method to ensure it gets restored after we're done
155
+ def without_logger
156
+ logger = ::NewRelic::Agent.logger
157
+ ::NewRelic::Agent.logger = nil
158
+ yield
159
+ ensure
160
+ ::NewRelic::Agent.logger = logger
161
+ end
162
+
163
+ module NewRelic
164
+ def self.fixture_path(name)
165
+ File.join(File.dirname(__FILE__), 'fixtures', name)
166
+ end
167
+ end
168
+
119
169
  module TransactionSampleTestHelper
170
+ module_function
120
171
  def make_sql_transaction(*sql)
121
172
  sampler = NewRelic::Agent::TransactionSampler.new
122
173
  sampler.notice_first_scope_push Time.now.to_f
@@ -151,5 +202,4 @@ module TransactionSampleTestHelper
151
202
  sampler.notice_scope_empty
152
203
  sampler.samples[0]
153
204
  end
154
-
155
205
  end
@@ -70,7 +70,7 @@ module NewRelic::DeveloperModeHelper
70
70
  rescue
71
71
  # catch all other exceptions. We're going to create an invalid link below, but that's okay.
72
72
  end
73
- if using_textmate?
73
+ if NewRelic::Agent.config[:textmate]
74
74
  "txmt://open?url=file://#{file}&line=#{line}"
75
75
  else
76
76
  "show_source?file=#{file}&amp;line=#{line}&amp;anchor=selected_line"
@@ -105,7 +105,7 @@ module NewRelic::DeveloperModeHelper
105
105
 
106
106
  # write a link to the source for a trace
107
107
  def link_to_source(trace)
108
- image_url = 'file/images/' + (using_textmate? ? "textmate.png" : "file_icon.png")
108
+ image_url = 'file/images/' + (NewRelic::Agent.config[:textmate] ? "textmate.png" : "file_icon.png")
109
109
 
110
110
  link_to "<img src=#{image_url} alt=\"View Source\" title=\"View Source\"/>", url_for_source(application_caller(trace))
111
111
  end
@@ -239,11 +239,6 @@ module NewRelic::DeveloperModeHelper
239
239
  end
240
240
  end
241
241
 
242
- def using_textmate?
243
- NewRelic::Control.instance.use_textmate?
244
- end
245
-
246
-
247
242
  def render_segment_details(segment, depth=0)
248
243
  @detail_segment_count ||= 0
249
244
  @detail_segment_count += 1
@@ -348,10 +343,25 @@ module NewRelic::DeveloperModeHelper
348
343
  parts.join '.'
349
344
  end
350
345
 
351
- def profile_table(profile)
346
+ SORT_REPLACEMENTS = {
347
+ "Total" => :total_time,
348
+ "Self" => :self_time,
349
+ "Child" => :children_time,
350
+ "Wait" => :wait_time
351
+ }
352
+
353
+ def profile_table(sample, options)
352
354
  out = StringIO.new
353
- printer = RubyProf::GraphHtmlPrinter.new(profile)
354
- printer.print(out, :min_percent=>0.5)
355
- out.string[/<body>(.*)<\/body>/im, 0].gsub('<table>', '<table class=profile>')
355
+ printer = RubyProf::GraphHtmlPrinter.new(sample.profile)
356
+ printer.print(out, options)
357
+ out = out.string[/<body>(.*)<\/body>/im, 0].gsub('<table>', '<table class=profile>')
358
+ SORT_REPLACEMENTS.each do |text, param|
359
+ replacement = (options[:sort_method] == param) ?
360
+ "<th> #{text}&nbsp;&darr;</th>" :
361
+ "<th>#{link_to text, "show_sample_summary?id=#{sample.sample_id}&sort=#{param}"}</th>"
362
+
363
+ out.gsub!(/<th> +#{text}<\/th>/, replacement)
364
+ end
365
+ out
356
366
  end
357
367
  end
@@ -2,6 +2,7 @@
2
2
  xml:lang="en" lang="en">
3
3
  <head>
4
4
  <script type="text/javascript" src="/newrelic/file/javascript/jquery-1.4.2.js"></script>
5
+ <meta charset="utf-8" />
5
6
  <title>New Relic Developer Mode</title>
6
7
  <link href="/newrelic/file/stylesheets/style.css"
7
8
  media="screen" rel="stylesheet" type="text/css" />
@@ -62,7 +62,7 @@
62
62
  <br/>
63
63
  <div id="view_sample">
64
64
  <% if @sample.profile %>
65
- <%= profile_table(@sample.profile) %>
65
+ <%= profile_table(@sample, @profile_options) %>
66
66
  <% else %>
67
67
  <div align=center width="100%">
68
68
  <%= show_view_link 'Summary', 'show_sample_summary' %>
@@ -8,22 +8,18 @@
8
8
  <th class="left">Status</th>
9
9
  <th class="left">Group</th>
10
10
  <th class="left">Priority</th>
11
- <th class="left">Locals</th>
12
11
  </thead>
13
12
  <%
14
13
  main = Thread.main
15
14
  threads = Thread.list - [ main ]
16
15
  nr_threads = []
17
- threads.delete_if { | thread | nr_threads << thread if thread.key? 'newrelic_label' }
16
+ threads.delete_if { | thread | nr_threads << thread if thread.key?(:newrelic_label) }
18
17
  ([ main ] + threads).each_with_index do | thread, i | %>
19
18
  <tr class="odd_row">
20
19
  <td valign="top"><%= h(thread == main ? 'main' : thread.to_s) %></td>
21
20
  <td valign="top"><%= h(thread.status || 'terminated with exception') %></td>
22
21
  <td valign="top"><%= h(thread.group || 'none') %></td>
23
22
  <td valign="top"><%= h thread.priority %></td>
24
- <td class="locals">
25
- <%= thread.keys.map{|k| h k}.join("</br>") %>
26
- </td>
27
23
  </tr>
28
24
  <% end %>
29
25
  <% if nr_threads.size > 0 %>
@@ -34,18 +30,14 @@
34
30
  <th class="left">Status</th>
35
31
  <th class="left">Group</th>
36
32
  <th class="left">Priority</th>
37
- <th class="left">Locals</th>
38
33
  </thead>
39
34
 
40
35
  <% nr_threads.each_with_index do | thread, i | %>
41
36
  <tr class="odd_row">
42
- <td valign="top"><%= h thread['newrelic_label'] %></td>
37
+ <td valign="top"><%= h thread[:newrelic_label] %></td>
43
38
  <td valign="top"><%= h(thread.status || 'terminated with exception') %></td>
44
39
  <td valign="top"><%= h(thread.group || 'none') %></td>
45
40
  <td valign="top"><%= h thread.priority %></td>
46
- <td class="locals">
47
- <%= (thread.keys - ['newrelic_label']).map{|k| h k}.join("</br>") %>
48
- </td>
49
41
  </tr>
50
42
  <% end %>
51
43
  <% end %>
@@ -0,0 +1,116 @@
1
+ --- !ruby/object:Gem::Specification
2
+ name: metric_parser
3
+ version: !ruby/object:Gem::Version
4
+ hash: 270495464
5
+ prerelease: true
6
+ segments:
7
+ - 0
8
+ - 1
9
+ - 0
10
+ - pre1
11
+ version: 0.1.0.pre1
12
+ platform: ruby
13
+ authors:
14
+ - Justin George
15
+ autorequire:
16
+ bindir: bin
17
+ cert_chain: []
18
+
19
+ date: 2010-08-12 00:00:00 +00:00
20
+ default_executable:
21
+ dependencies: []
22
+
23
+ description: A standard way to parse New Relic metric names
24
+ email:
25
+ - support@newrelic.com
26
+ executables: []
27
+
28
+ extensions: []
29
+
30
+ extra_rdoc_files: []
31
+
32
+ files:
33
+ - lib/metric_parser.rb
34
+ - lib/new_relic/metric_parser/action_mailer.rb
35
+ - lib/new_relic/metric_parser/active_merchant.rb
36
+ - lib/new_relic/metric_parser/active_record.rb
37
+ - lib/new_relic/metric_parser/apdex.rb
38
+ - lib/new_relic/metric_parser/background_transaction.rb
39
+ - lib/new_relic/metric_parser/client.rb
40
+ - lib/new_relic/metric_parser/controller.rb
41
+ - lib/new_relic/metric_parser/controller_cpu.rb
42
+ - lib/new_relic/metric_parser/controller_ext.rb
43
+ - lib/new_relic/metric_parser/database.rb
44
+ - lib/new_relic/metric_parser/database_pool.rb
45
+ - lib/new_relic/metric_parser/dot_net.rb
46
+ - lib/new_relic/metric_parser/dot_net_parser.rb
47
+ - lib/new_relic/metric_parser/errors.rb
48
+ - lib/new_relic/metric_parser/external.rb
49
+ - lib/new_relic/metric_parser/frontend.rb
50
+ - lib/new_relic/metric_parser/gc.rb
51
+ - lib/new_relic/metric_parser/hibernate_session.rb
52
+ - lib/new_relic/metric_parser/java.rb
53
+ - lib/new_relic/metric_parser/java_parser.rb
54
+ - lib/new_relic/metric_parser/jsp.rb
55
+ - lib/new_relic/metric_parser/jsp_tag.rb
56
+ - lib/new_relic/metric_parser/mem_cache.rb
57
+ - lib/new_relic/metric_parser/metric_parser.rb
58
+ - lib/new_relic/metric_parser/orm.rb
59
+ - lib/new_relic/metric_parser/other_transaction.rb
60
+ - lib/new_relic/metric_parser/servlet.rb
61
+ - lib/new_relic/metric_parser/servlet_context_listener.rb
62
+ - lib/new_relic/metric_parser/servlet_filter.rb
63
+ - lib/new_relic/metric_parser/servlet_init.rb
64
+ - lib/new_relic/metric_parser/solr.rb
65
+ - lib/new_relic/metric_parser/solr_request_handler.rb
66
+ - lib/new_relic/metric_parser/spring.rb
67
+ - lib/new_relic/metric_parser/spring_controller.rb
68
+ - lib/new_relic/metric_parser/spring_view.rb
69
+ - lib/new_relic/metric_parser/struts_action.rb
70
+ - lib/new_relic/metric_parser/struts_result.rb
71
+ - lib/new_relic/metric_parser/version.rb
72
+ - lib/new_relic/metric_parser/view.rb
73
+ - lib/new_relic/metric_parser/web_frontend.rb
74
+ - lib/new_relic/metric_parser/web_service.rb
75
+ - lib/new_relic/metric_parser/web_transaction.rb
76
+ - lib/new_relic/metric_parser.rb
77
+ - LICENSE
78
+ - README
79
+ has_rdoc: true
80
+ homepage: http://www.newrelic.com
81
+ licenses: []
82
+
83
+ post_install_message:
84
+ rdoc_options: []
85
+
86
+ require_paths:
87
+ - lib
88
+ required_ruby_version: !ruby/object:Gem::Requirement
89
+ none: false
90
+ requirements:
91
+ - - ">="
92
+ - !ruby/object:Gem::Version
93
+ hash: 3
94
+ segments:
95
+ - 0
96
+ version: "0"
97
+ required_rubygems_version: !ruby/object:Gem::Requirement
98
+ none: false
99
+ requirements:
100
+ - - ">="
101
+ - !ruby/object:Gem::Version
102
+ hash: 31
103
+ segments:
104
+ - 1
105
+ - 2
106
+ - 0
107
+ version: 1.2.0
108
+ requirements: []
109
+
110
+ rubyforge_project:
111
+ rubygems_version: 1.3.7
112
+ signing_key:
113
+ specification_version: 3
114
+ summary: A standard way to parse New Relic metric names
115
+ test_files: []
116
+
@@ -0,0 +1,7 @@
1
+ require 'new_relic/metric_parser/java'
2
+ class NewRelic::MetricParser::ServletInit < NewRelic::MetricParser::Java
3
+
4
+ def call_rate_suffix
5
+ 'cpm'
6
+ end
7
+ end
metadata CHANGED
@@ -1,54 +1,22 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: wd_newrelic_rpm
3
3
  version: !ruby/object:Gem::Version
4
- version: 3.3.4.1
4
+ version: 3.5.5
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors:
8
- - Bill Kayser
8
+ - Jason Clark
9
+ - Sam Goldstein
9
10
  - Jon Guymon
10
- - Justin George
11
- - Darin Swanson
11
+ - Ben Weintraub
12
12
  autorequire:
13
13
  bindir: bin
14
14
  cert_chain: []
15
- date: 2012-04-24 00:00:00.000000000 Z
16
- dependencies:
17
- - !ruby/object:Gem::Dependency
18
- name: jeweler
19
- requirement: &70237809766480 !ruby/object:Gem::Requirement
20
- none: false
21
- requirements:
22
- - - ! '>='
23
- - !ruby/object:Gem::Version
24
- version: '0'
25
- type: :development
26
- prerelease: false
27
- version_requirements: *70237809766480
28
- - !ruby/object:Gem::Dependency
29
- name: mocha
30
- requirement: &70237809765800 !ruby/object:Gem::Requirement
31
- none: false
32
- requirements:
33
- - - ! '>='
34
- - !ruby/object:Gem::Version
35
- version: '0'
36
- type: :development
37
- prerelease: false
38
- version_requirements: *70237809765800
39
- - !ruby/object:Gem::Dependency
40
- name: shoulda
41
- requirement: &70237809765040 !ruby/object:Gem::Requirement
42
- none: false
43
- requirements:
44
- - - ! '>='
45
- - !ruby/object:Gem::Version
46
- version: '0'
47
- type: :development
48
- prerelease: false
49
- version_requirements: *70237809765040
50
- description: ! 'Weasel Diesel compatible version of rpm. New Relic is a performance
51
- management system, developed by New Relic,
15
+ date: 2013-01-09 00:00:00.000000000 Z
16
+ dependencies: []
17
+ description: ! 'Weasel Diesel compatible version of rpm.
18
+
19
+ New Relic is a performance management system, developed by New Relic,
52
20
 
53
21
  Inc (http://www.newrelic.com). New Relic provides you with deep
54
22
 
@@ -63,34 +31,54 @@ description: ! 'Weasel Diesel compatible version of rpm. New Relic is a performa
63
31
  '
64
32
  email: support@newrelic.com
65
33
  executables:
66
- - newrelic_cmd
67
34
  - mongrel_rpm
35
+ - newrelic_cmd
68
36
  - newrelic
69
37
  extensions: []
70
38
  extra_rdoc_files:
71
39
  - CHANGELOG
72
40
  - LICENSE
73
- - README.rdoc
41
+ - README.md
42
+ - GUIDELINES_FOR_CONTRIBUTING.md
74
43
  - newrelic.yml
75
44
  files:
45
+ - .gitignore
46
+ - .project
47
+ - .travis.yml
76
48
  - CHANGELOG
49
+ - GUIDELINES_FOR_CONTRIBUTING.md
50
+ - Gemfile
77
51
  - LICENSE
78
- - README.rdoc
52
+ - README.md
53
+ - Rakefile
79
54
  - bin/mongrel_rpm
80
55
  - bin/newrelic
81
56
  - bin/newrelic_cmd
82
57
  - cert/cacert.pem
83
58
  - cert/oldsite.pem
84
59
  - cert/site.pem
60
+ - config.dot
61
+ - config/database.yml
62
+ - init.rb
85
63
  - install.rb
86
64
  - lib/conditional_vendored_dependency_detection.rb
87
65
  - lib/conditional_vendored_metric_parser.rb
88
66
  - lib/new_relic/agent.rb
89
67
  - lib/new_relic/agent/agent.rb
68
+ - lib/new_relic/agent/agent_logger.rb
69
+ - lib/new_relic/agent/audit_logger.rb
90
70
  - lib/new_relic/agent/beacon_configuration.rb
91
71
  - lib/new_relic/agent/browser_monitoring.rb
92
72
  - lib/new_relic/agent/busy_calculator.rb
93
73
  - lib/new_relic/agent/chained_call.rb
74
+ - lib/new_relic/agent/configuration.rb
75
+ - lib/new_relic/agent/configuration/defaults.rb
76
+ - lib/new_relic/agent/configuration/environment_source.rb
77
+ - lib/new_relic/agent/configuration/manager.rb
78
+ - lib/new_relic/agent/configuration/mask_defaults.rb
79
+ - lib/new_relic/agent/configuration/server_source.rb
80
+ - lib/new_relic/agent/configuration/yaml_source.rb
81
+ - lib/new_relic/agent/cross_process_monitoring.rb
94
82
  - lib/new_relic/agent/database.rb
95
83
  - lib/new_relic/agent/error_collector.rb
96
84
  - lib/new_relic/agent/instrumentation.rb
@@ -98,6 +86,7 @@ files:
98
86
  - lib/new_relic/agent/instrumentation/active_record.rb
99
87
  - lib/new_relic/agent/instrumentation/acts_as_solr.rb
100
88
  - lib/new_relic/agent/instrumentation/authlogic.rb
89
+ - lib/new_relic/agent/instrumentation/browser_monitoring_timings.rb
101
90
  - lib/new_relic/agent/instrumentation/controller_instrumentation.rb
102
91
  - lib/new_relic/agent/instrumentation/data_mapper.rb
103
92
  - lib/new_relic/agent/instrumentation/delayed_job_instrumentation.rb
@@ -115,13 +104,17 @@ files:
115
104
  - lib/new_relic/agent/instrumentation/rails/errors.rb
116
105
  - lib/new_relic/agent/instrumentation/rails3/action_controller.rb
117
106
  - lib/new_relic/agent/instrumentation/rails3/errors.rb
107
+ - lib/new_relic/agent/instrumentation/resque.rb
118
108
  - lib/new_relic/agent/instrumentation/sinatra.rb
119
109
  - lib/new_relic/agent/instrumentation/sunspot.rb
120
110
  - lib/new_relic/agent/instrumentation/unicorn_instrumentation.rb
121
111
  - lib/new_relic/agent/method_tracer.rb
112
+ - lib/new_relic/agent/new_relic_service.rb
113
+ - lib/new_relic/agent/pipe_channel_manager.rb
114
+ - lib/new_relic/agent/pipe_service.rb
122
115
  - lib/new_relic/agent/sampler.rb
123
116
  - lib/new_relic/agent/samplers/cpu_sampler.rb
124
- - lib/new_relic/agent/samplers/delayed_job_lock_sampler.rb
117
+ - lib/new_relic/agent/samplers/delayed_job_sampler.rb
125
118
  - lib/new_relic/agent/samplers/memory_sampler.rb
126
119
  - lib/new_relic/agent/samplers/object_sampler.rb
127
120
  - lib/new_relic/agent/shim_agent.rb
@@ -131,6 +124,8 @@ files:
131
124
  - lib/new_relic/agent/stats_engine/metric_stats.rb
132
125
  - lib/new_relic/agent/stats_engine/samplers.rb
133
126
  - lib/new_relic/agent/stats_engine/transactions.rb
127
+ - lib/new_relic/agent/thread.rb
128
+ - lib/new_relic/agent/thread_profiler.rb
134
129
  - lib/new_relic/agent/transaction_info.rb
135
130
  - lib/new_relic/agent/transaction_sample_builder.rb
136
131
  - lib/new_relic/agent/transaction_sampler.rb
@@ -141,21 +136,20 @@ files:
141
136
  - lib/new_relic/commands/install.rb
142
137
  - lib/new_relic/control.rb
143
138
  - lib/new_relic/control/class_methods.rb
144
- - lib/new_relic/control/configuration.rb
145
139
  - lib/new_relic/control/frameworks.rb
146
140
  - lib/new_relic/control/frameworks/external.rb
147
141
  - lib/new_relic/control/frameworks/merb.rb
148
142
  - lib/new_relic/control/frameworks/rails.rb
149
143
  - lib/new_relic/control/frameworks/rails3.rb
144
+ - lib/new_relic/control/frameworks/rails4.rb
150
145
  - lib/new_relic/control/frameworks/ruby.rb
151
146
  - lib/new_relic/control/frameworks/sinatra.rb
152
147
  - lib/new_relic/control/instance_methods.rb
153
148
  - lib/new_relic/control/instrumentation.rb
154
- - lib/new_relic/control/logging_methods.rb
155
149
  - lib/new_relic/control/profiling.rb
156
150
  - lib/new_relic/control/server_methods.rb
157
- - lib/new_relic/data_serialization.rb
158
151
  - lib/new_relic/delayed_job_injection.rb
152
+ - lib/new_relic/helper.rb
159
153
  - lib/new_relic/language_support.rb
160
154
  - lib/new_relic/local_environment.rb
161
155
  - lib/new_relic/merbtasks.rb
@@ -163,8 +157,10 @@ files:
163
157
  - lib/new_relic/metric_spec.rb
164
158
  - lib/new_relic/metrics.rb
165
159
  - lib/new_relic/noticed_error.rb
160
+ - lib/new_relic/rack.rb
166
161
  - lib/new_relic/rack/browser_monitoring.rb
167
162
  - lib/new_relic/rack/developer_mode.rb
163
+ - lib/new_relic/rack/error_collector.rb
168
164
  - lib/new_relic/recipes.rb
169
165
  - lib/new_relic/stats.rb
170
166
  - lib/new_relic/timer_lib.rb
@@ -182,26 +178,123 @@ files:
182
178
  - lib/tasks/install.rake
183
179
  - lib/tasks/tests.rake
184
180
  - newrelic.yml
185
- - newrelic_rpm.gemspec
181
+ - newrelic_rpm.gemspec.erb
186
182
  - recipes/newrelic.rb
187
183
  - test/active_record_fixtures.rb
188
184
  - test/config/newrelic.yml
189
185
  - test/config/test_control.rb
186
+ - test/fixtures/gemspec_no_build.rb
187
+ - test/fixtures/gemspec_with_build.rb
188
+ - test/fixtures/gemspec_with_build_and_stage.rb
190
189
  - test/fixtures/proc_cpuinfo.txt
190
+ - test/intentional_fail.rb
191
+ - test/multiverse/.gitignore
192
+ - test/multiverse/README.md
193
+ - test/multiverse/lib/multiverse/color.rb
194
+ - test/multiverse/lib/multiverse/envfile.rb
195
+ - test/multiverse/lib/multiverse/environment.rb
196
+ - test/multiverse/lib/multiverse/output_collector.rb
197
+ - test/multiverse/lib/multiverse/runner.rb
198
+ - test/multiverse/lib/multiverse/suite.rb
199
+ - test/multiverse/script/run_one
200
+ - test/multiverse/script/runner
201
+ - test/multiverse/suites/active_record/Envfile
202
+ - test/multiverse/suites/active_record/ar_method_aliasing.rb
203
+ - test/multiverse/suites/active_record/config/newrelic.yml
204
+ - test/multiverse/suites/active_record/encoding_test.rb
205
+ - test/multiverse/suites/agent_only/Envfile
206
+ - test/multiverse/suites/agent_only/audit_log_test.rb
207
+ - test/multiverse/suites/agent_only/config/newrelic.yml
208
+ - test/multiverse/suites/agent_only/http_response_code_test.rb
209
+ - test/multiverse/suites/agent_only/marshaling_test.rb
210
+ - test/multiverse/suites/agent_only/method_visibility_test.rb
211
+ - test/multiverse/suites/agent_only/pipe_manager_test.rb
212
+ - test/multiverse/suites/agent_only/service_timeout_test.rb
213
+ - test/multiverse/suites/agent_only/test_trace_method_with_punctuation.rb
214
+ - test/multiverse/suites/agent_only/test_trace_transaction_with_punctuation.rb
215
+ - test/multiverse/suites/agent_only/thread_profiling_test.rb
216
+ - test/multiverse/suites/config_file_loading/Envfile
217
+ - test/multiverse/suites/config_file_loading/config_file_loading_test.rb
218
+ - test/multiverse/suites/datamapper/Envfile
219
+ - test/multiverse/suites/datamapper/config/newrelic.yml
220
+ - test/multiverse/suites/datamapper/encoding_test.rb
221
+ - test/multiverse/suites/logging/Envfile
222
+ - test/multiverse/suites/logging/config/newrelic.yml
223
+ - test/multiverse/suites/logging/logging_test.rb
224
+ - test/multiverse/suites/monitor_mode_false/Envfile
225
+ - test/multiverse/suites/monitor_mode_false/config/newrelic.yml
226
+ - test/multiverse/suites/monitor_mode_false/no_dns_resolv.rb
227
+ - test/multiverse/suites/no_load/Envfile
228
+ - test/multiverse/suites/no_load/config/newrelic.yml
229
+ - test/multiverse/suites/no_load/start_up_test.rb
230
+ - test/multiverse/suites/rails_3_error_tracing/Envfile
231
+ - test/multiverse/suites/rails_3_error_tracing/config/newrelic.yml
232
+ - test/multiverse/suites/rails_3_error_tracing/error_tracing_test.rb
233
+ - test/multiverse/suites/rails_3_gc/Envfile
234
+ - test/multiverse/suites/rails_3_gc/config/newrelic.yml
235
+ - test/multiverse/suites/rails_3_gc/instrumentation_test.rb
236
+ - test/multiverse/suites/rails_3_queue_time/Envfile
237
+ - test/multiverse/suites/rails_3_queue_time/config/newrelic.yml
238
+ - test/multiverse/suites/rails_3_queue_time/queue_time_test.rb
239
+ - test/multiverse/suites/rails_3_views/.gitignore
240
+ - test/multiverse/suites/rails_3_views/Envfile
241
+ - test/multiverse/suites/rails_3_views/app/views/foos/_foo.html.haml
242
+ - test/multiverse/suites/rails_3_views/app/views/test/_a_partial.html.erb
243
+ - test/multiverse/suites/rails_3_views/app/views/test/_mid_partial.html.erb
244
+ - test/multiverse/suites/rails_3_views/app/views/test/_top_partial.html.erb
245
+ - test/multiverse/suites/rails_3_views/app/views/test/deep_partial.html.erb
246
+ - test/multiverse/suites/rails_3_views/app/views/test/haml_view.html.haml
247
+ - test/multiverse/suites/rails_3_views/app/views/test/index.html.erb
248
+ - test/multiverse/suites/rails_3_views/config/newrelic.yml
249
+ - test/multiverse/suites/rails_3_views/view_instrumentation_test.rb
250
+ - test/multiverse/suites/resque/Envfile
251
+ - test/multiverse/suites/resque/config/newrelic.yml
252
+ - test/multiverse/suites/resque/dump.rdb
253
+ - test/multiverse/suites/resque/instrumentation_test.rb
254
+ - test/multiverse/suites/rum_auto_instrumentation/Envfile
255
+ - test/multiverse/suites/rum_auto_instrumentation/config/newrelic.yml
256
+ - test/multiverse/suites/rum_auto_instrumentation/responses/worst_case_small.html
257
+ - test/multiverse/suites/rum_auto_instrumentation/sanity_test.rb
258
+ - test/multiverse/suites/sinatra/Envfile
259
+ - test/multiverse/suites/sinatra/config/newrelic.yml
260
+ - test/multiverse/suites/sinatra/sinatra_metric_explosion_test.rb
261
+ - test/multiverse/suites/sinatra/sinatra_routes_test.rb
262
+ - test/multiverse/suites/sinatra/sinatra_test.rb
263
+ - test/multiverse/test/multiverse_test.rb
264
+ - test/multiverse/test/suite_examples/one/a/Envfile
265
+ - test/multiverse/test/suite_examples/one/a/a_test.rb
266
+ - test/multiverse/test/suite_examples/one/a/config/newrelic.yml
267
+ - test/multiverse/test/suite_examples/one/b/Envfile
268
+ - test/multiverse/test/suite_examples/one/b/b_test.rb
269
+ - test/multiverse/test/suite_examples/one/b/config/newrelic.yml
270
+ - test/multiverse/test/suite_examples/three/a/Envfile
271
+ - test/multiverse/test/suite_examples/three/a/fail_test.rb
272
+ - test/multiverse/test/suite_examples/three/b/Envfile
273
+ - test/multiverse/test/suite_examples/three/b/win_test.rb
274
+ - test/multiverse/test/suite_examples/two/a/Envfile
275
+ - test/multiverse/test/suite_examples/two/a/fail_test.rb
191
276
  - test/new_relic/agent/agent/connect_test.rb
192
277
  - test/new_relic/agent/agent/start_test.rb
193
278
  - test/new_relic/agent/agent/start_worker_thread_test.rb
279
+ - test/new_relic/agent/agent_logger_test.rb
194
280
  - test/new_relic/agent/agent_test.rb
195
281
  - test/new_relic/agent/agent_test_controller.rb
196
282
  - test/new_relic/agent/agent_test_controller_test.rb
197
283
  - test/new_relic/agent/apdex_from_server_test.rb
284
+ - test/new_relic/agent/audit_logger_test.rb
198
285
  - test/new_relic/agent/beacon_configuration_test.rb
199
286
  - test/new_relic/agent/browser_monitoring_test.rb
200
287
  - test/new_relic/agent/busy_calculator_test.rb
288
+ - test/new_relic/agent/configuration/environment_source_test.rb
289
+ - test/new_relic/agent/configuration/manager_test.rb
290
+ - test/new_relic/agent/configuration/server_source_test.rb
291
+ - test/new_relic/agent/configuration/yaml_source_test.rb
292
+ - test/new_relic/agent/cross_process_monitoring_test.rb
201
293
  - test/new_relic/agent/database_test.rb
202
294
  - test/new_relic/agent/error_collector/notice_error_test.rb
203
295
  - test/new_relic/agent/error_collector_test.rb
204
296
  - test/new_relic/agent/instrumentation/active_record_instrumentation_test.rb
297
+ - test/new_relic/agent/instrumentation/browser_monitoring_timings_test.rb
205
298
  - test/new_relic/agent/instrumentation/controller_instrumentation_test.rb
206
299
  - test/new_relic/agent/instrumentation/instrumentation_test.rb
207
300
  - test/new_relic/agent/instrumentation/metric_frame/pop_test.rb
@@ -209,12 +302,16 @@ files:
209
302
  - test/new_relic/agent/instrumentation/net_instrumentation_test.rb
210
303
  - test/new_relic/agent/instrumentation/queue_time_test.rb
211
304
  - test/new_relic/agent/instrumentation/rack_test.rb
305
+ - test/new_relic/agent/instrumentation/sinatra_test.rb
212
306
  - test/new_relic/agent/instrumentation/task_instrumentation_test.rb
213
307
  - test/new_relic/agent/memcache_instrumentation_test.rb
214
308
  - test/new_relic/agent/method_tracer/class_methods/add_method_tracer_test.rb
215
309
  - test/new_relic/agent/method_tracer/instance_methods/trace_execution_scoped_test.rb
216
310
  - test/new_relic/agent/method_tracer_test.rb
217
311
  - test/new_relic/agent/mock_scope_listener.rb
312
+ - test/new_relic/agent/new_relic_service_test.rb
313
+ - test/new_relic/agent/pipe_channel_manager_test.rb
314
+ - test/new_relic/agent/pipe_service_test.rb
218
315
  - test/new_relic/agent/rpm_agent_test.rb
219
316
  - test/new_relic/agent/sampler_test.rb
220
317
  - test/new_relic/agent/shim_agent_test.rb
@@ -223,6 +320,9 @@ files:
223
320
  - test/new_relic/agent/stats_engine/metric_stats_test.rb
224
321
  - test/new_relic/agent/stats_engine/samplers_test.rb
225
322
  - test/new_relic/agent/stats_engine_test.rb
323
+ - test/new_relic/agent/thread_profiler_test.rb
324
+ - test/new_relic/agent/thread_test.rb
325
+ - test/new_relic/agent/threaded_test.rb
226
326
  - test/new_relic/agent/transaction_info_test.rb
227
327
  - test/new_relic/agent/transaction_sample_builder_test.rb
228
328
  - test/new_relic/agent/transaction_sampler_test.rb
@@ -231,19 +331,25 @@ files:
231
331
  - test/new_relic/collection_helper_test.rb
232
332
  - test/new_relic/command/deployments_test.rb
233
333
  - test/new_relic/control/class_methods_test.rb
234
- - test/new_relic/control/configuration_test.rb
235
- - test/new_relic/control/logging_methods_test.rb
334
+ - test/new_relic/control/frameworks/rails_test.rb
236
335
  - test/new_relic/control_test.rb
237
- - test/new_relic/data_serialization_test.rb
238
336
  - test/new_relic/delayed_job_injection_test.rb
337
+ - test/new_relic/dispatcher_test.rb
338
+ - test/new_relic/fake_collector.rb
339
+ - test/new_relic/fake_service.rb
340
+ - test/new_relic/fakes_sending_data.rb
341
+ - test/new_relic/framework_test.rb
342
+ - test/new_relic/load_test.rb
239
343
  - test/new_relic/local_environment_test.rb
240
344
  - test/new_relic/metric_data_test.rb
241
345
  - test/new_relic/metric_parser/metric_parser_test.rb
242
346
  - test/new_relic/metric_spec_test.rb
347
+ - test/new_relic/noticed_error_test.rb
243
348
  - test/new_relic/rack/all_test.rb
244
349
  - test/new_relic/rack/browser_monitoring_test.rb
245
350
  - test/new_relic/rack/developer_mode_helper_test.rb
246
351
  - test/new_relic/rack/developer_mode_test.rb
352
+ - test/new_relic/rack/error_collector_test.rb
247
353
  - test/new_relic/stats_test.rb
248
354
  - test/new_relic/transaction_analysis/segment_summary_test.rb
249
355
  - test/new_relic/transaction_analysis_test.rb
@@ -256,7 +362,9 @@ files:
256
362
  - test/new_relic/version_number_test.rb
257
363
  - test/script/build_test_gem.sh
258
364
  - test/script/ci.sh
365
+ - test/script/ci_agent-tests_runner.sh
259
366
  - test/script/ci_bench.sh
367
+ - test/script/ci_multiverse_runner.sh
260
368
  - test/test_contexts.rb
261
369
  - test/test_helper.rb
262
370
  - ui/helpers/developer_mode_helper.rb
@@ -293,6 +401,7 @@ files:
293
401
  - vendor/gems/dependency_detection-0.0.1.build/LICENSE
294
402
  - vendor/gems/dependency_detection-0.0.1.build/lib/dependency_detection.rb
295
403
  - vendor/gems/dependency_detection-0.0.1.build/lib/dependency_detection/version.rb
404
+ - vendor/gems/metric_parser-0.1.0.pre1/.specification
296
405
  - vendor/gems/metric_parser-0.1.0.pre1/lib/metric_parser.rb
297
406
  - vendor/gems/metric_parser-0.1.0.pre1/lib/new_relic/metric_parser.rb
298
407
  - vendor/gems/metric_parser-0.1.0.pre1/lib/new_relic/metric_parser/action_mailer.rb
@@ -324,6 +433,7 @@ files:
324
433
  - vendor/gems/metric_parser-0.1.0.pre1/lib/new_relic/metric_parser/servlet.rb
325
434
  - vendor/gems/metric_parser-0.1.0.pre1/lib/new_relic/metric_parser/servlet_context_listener.rb
326
435
  - vendor/gems/metric_parser-0.1.0.pre1/lib/new_relic/metric_parser/servlet_filter.rb
436
+ - vendor/gems/metric_parser-0.1.0.pre1/lib/new_relic/metric_parser/servlet_init.rb
327
437
  - vendor/gems/metric_parser-0.1.0.pre1/lib/new_relic/metric_parser/solr.rb
328
438
  - vendor/gems/metric_parser-0.1.0.pre1/lib/new_relic/metric_parser/solr_request_handler.rb
329
439
  - vendor/gems/metric_parser-0.1.0.pre1/lib/new_relic/metric_parser/spring.rb
@@ -336,17 +446,34 @@ files:
336
446
  - vendor/gems/metric_parser-0.1.0.pre1/lib/new_relic/metric_parser/web_frontend.rb
337
447
  - vendor/gems/metric_parser-0.1.0.pre1/lib/new_relic/metric_parser/web_service.rb
338
448
  - vendor/gems/metric_parser-0.1.0.pre1/lib/new_relic/metric_parser/web_transaction.rb
449
+ - newrelic_rpm.gemspec
339
450
  homepage: http://www.github.com/newrelic/rpm
340
451
  licenses: []
341
- post_install_message: ! "\nPLEASE NOTE:\n\nDeveloper Mode is now a Rack middleware.\n\nDeveloper
342
- Mode is no longer available in Rails 2.1 and earlier.\nHowever, starting in version
343
- 2.12 you can use Developer Mode in any\nRack based framework, in addition to Rails.
344
- \ To install developer mode\nin a non-Rails application, just add NewRelic::Rack::DeveloperMode
345
- to\nyour middleware stack.\n\nIf you are using JRuby, we recommend using at least
346
- version 1.4 or \nlater because of issues with the implementation of the timeout
347
- library.\n\nRefer to the README.md file for more information.\n\nPlease see http://github.com/newrelic/rpm/blob/master/CHANGELOG\nfor
348
- a complete description of the features and enhancements available\nin version 3.3
349
- of the Ruby Agent.\n \n"
452
+ post_install_message: ! "\n# New Relic Ruby Agent Release Notes #\n\n## v3.5.5 ##\n\n
453
+ \ * Add thread profiling support\n\n Thread profiling performs statistical sampling
454
+ of backtraces of all threads\n within your Ruby processes. This feature requires
455
+ MRI >= 1.9.2, and is\n controlled via the New Relic web UI. JRuby support (in
456
+ 1.9.x compat mode) is\n considered experimental, due to issues with JRuby's Thread#backtrace.\n\n
457
+ \ * Add audit logging capability\n\n The agent can now log all of the data it
458
+ sends to the New Relic servers to\n a special log file for human inspection.
459
+ This feature is off by default, and\n can be enabled by setting the audit_log.enabled
460
+ configuration key to true.\n You may also control the location of the audit log
461
+ with the audit_log.path key. \n\n * Use config system for dispatcher, framework,
462
+ and config file detection\n\n Several aspects of the agent's configuration were
463
+ not being handled by the\n configuration system. Detection/configuration of
464
+ the dispatcher (e.g. passenger,\n unicorn, resque), framework (e.g. rails3, sinatra),
465
+ and newrelic.yml\n location are now handled via the Agent environment, manual,
466
+ and default\n configuration sources.\n\n * Updates to logging across the agent\n\n
467
+ \ We've carefully reviewed the logging messages that the agent outputs, adding\n
468
+ \ details in some cases, and removing unnecessary clutter. We've also altered\n
469
+ \ the startup sequence to ensure that we don't spam STDOUT with messages\n during
470
+ initialization.\n\n * Fix passing environment to manual_start()\n\n Thanks to
471
+ Justin Hannus. The :env key, when passed to Agent.manual_start,\n can again
472
+ be used to specify which section of newrelic.yml is loaded.\n\n * Rails 4 support\n\n
473
+ \ This release includes preliminary support for Rails 4 as of 4.0.0.beta.\n Rails
474
+ 4 is still in development, but the agent should work as expected for\n people
475
+ who are experimenting with the beta.\n\n\nSee https://github.com/newrelic/rpm/blob/master/CHANGELOG
476
+ for a full list of\nchanges.\n"
350
477
  rdoc_options:
351
478
  - --line-numbers
352
479
  - --inline-source
@@ -363,14 +490,13 @@ required_ruby_version: !ruby/object:Gem::Requirement
363
490
  required_rubygems_version: !ruby/object:Gem::Requirement
364
491
  none: false
365
492
  requirements:
366
- - - ! '>='
493
+ - - ! '>'
367
494
  - !ruby/object:Gem::Version
368
- version: '0'
495
+ version: 1.3.1
369
496
  requirements: []
370
497
  rubyforge_project:
371
- rubygems_version: 1.8.16
498
+ rubygems_version: 1.8.24
372
499
  signing_key:
373
500
  specification_version: 3
374
501
  summary: New Relic Ruby Agent
375
502
  test_files: []
376
- has_rdoc: