newrelic_rpm 6.3.0.355 → 9.2.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (468) hide show
  1. checksums.yaml +4 -4
  2. data/.gitignore +15 -1
  3. data/.rubocop.yml +1845 -0
  4. data/.rubocop_todo.yml +61 -0
  5. data/.simplecov +16 -0
  6. data/.snyk +11 -0
  7. data/.yardopts +1 -0
  8. data/Brewfile +13 -0
  9. data/CHANGELOG.md +4102 -2416
  10. data/CONTRIBUTING.md +132 -19
  11. data/DOCKER.md +167 -0
  12. data/Dockerfile +10 -0
  13. data/Gemfile +5 -2
  14. data/Guardfile +25 -6
  15. data/LICENSE +202 -38
  16. data/README.md +86 -87
  17. data/Rakefile +32 -32
  18. data/THIRD_PARTY_NOTICES.md +28 -0
  19. data/Thorfile +5 -0
  20. data/bin/newrelic +4 -2
  21. data/bin/newrelic_cmd +2 -0
  22. data/bin/nrdebug +86 -63
  23. data/config.dot +5 -5
  24. data/docker-compose.yml +107 -0
  25. data/init.rb +5 -7
  26. data/install.rb +3 -3
  27. data/lefthook.yml +9 -0
  28. data/lib/new_relic/agent/adaptive_sampler.rb +14 -10
  29. data/lib/new_relic/agent/agent.rb +115 -882
  30. data/lib/new_relic/agent/agent_helpers/connect.rb +222 -0
  31. data/lib/new_relic/agent/agent_helpers/harvest.rb +153 -0
  32. data/lib/new_relic/agent/agent_helpers/shutdown.rb +72 -0
  33. data/lib/new_relic/agent/agent_helpers/special_startup.rb +74 -0
  34. data/lib/new_relic/agent/agent_helpers/start_worker_thread.rb +175 -0
  35. data/lib/new_relic/agent/agent_helpers/startup.rb +202 -0
  36. data/lib/new_relic/agent/agent_helpers/transmit.rb +76 -0
  37. data/lib/new_relic/agent/agent_logger.rb +30 -22
  38. data/lib/new_relic/agent/attribute_filter.rb +70 -53
  39. data/lib/new_relic/agent/attribute_processing.rb +10 -10
  40. data/lib/new_relic/agent/attributes.rb +153 -0
  41. data/lib/new_relic/agent/audit_logger.rb +22 -7
  42. data/lib/new_relic/agent/autostart.rb +34 -28
  43. data/lib/new_relic/agent/chained_call.rb +2 -2
  44. data/lib/new_relic/agent/commands/agent_command.rb +5 -5
  45. data/lib/new_relic/agent/commands/agent_command_router.rb +18 -35
  46. data/lib/new_relic/agent/commands/thread_profiler_session.rb +17 -15
  47. data/lib/new_relic/agent/configuration/default_source.rb +1456 -1100
  48. data/lib/new_relic/agent/configuration/dotted_hash.rb +7 -6
  49. data/lib/new_relic/agent/configuration/environment_source.rb +17 -13
  50. data/lib/new_relic/agent/configuration/event_harvest_config.rb +68 -0
  51. data/lib/new_relic/agent/configuration/high_security_source.rb +12 -12
  52. data/lib/new_relic/agent/configuration/manager.rb +97 -80
  53. data/lib/new_relic/agent/configuration/manual_source.rb +2 -2
  54. data/lib/new_relic/agent/configuration/mask_defaults.rb +4 -4
  55. data/lib/new_relic/agent/configuration/security_policy_source.rb +93 -96
  56. data/lib/new_relic/agent/configuration/server_source.rb +66 -40
  57. data/lib/new_relic/agent/configuration/yaml_source.rb +44 -15
  58. data/lib/new_relic/agent/configuration.rb +2 -2
  59. data/lib/new_relic/agent/connect/request_builder.rb +25 -27
  60. data/lib/new_relic/agent/connect/response_handler.rb +7 -10
  61. data/lib/new_relic/agent/custom_event_aggregator.rb +16 -16
  62. data/lib/new_relic/agent/database/explain_plan_helpers.rb +6 -7
  63. data/lib/new_relic/agent/database/obfuscation_helpers.rb +18 -17
  64. data/lib/new_relic/agent/database/obfuscator.rb +5 -5
  65. data/lib/new_relic/agent/database/postgres_explain_obfuscator.rb +4 -4
  66. data/lib/new_relic/agent/database.rb +47 -56
  67. data/lib/new_relic/agent/database_adapter.rb +35 -0
  68. data/lib/new_relic/agent/datastores/metric_helper.rb +22 -23
  69. data/lib/new_relic/agent/datastores/mongo/event_formatter.rb +9 -8
  70. data/lib/new_relic/agent/datastores/mongo/metric_translator.rb +18 -22
  71. data/lib/new_relic/agent/datastores/mongo.rb +7 -12
  72. data/lib/new_relic/agent/datastores/nosql_obfuscator.rb +41 -0
  73. data/lib/new_relic/agent/datastores/redis.rb +10 -16
  74. data/lib/new_relic/agent/datastores.rb +14 -16
  75. data/lib/new_relic/agent/deprecator.rb +2 -2
  76. data/lib/new_relic/agent/{cross_app_payload.rb → distributed_tracing/cross_app_payload.rb} +13 -12
  77. data/lib/new_relic/agent/{cross_app_tracing.rb → distributed_tracing/cross_app_tracing.rb} +90 -70
  78. data/lib/new_relic/agent/distributed_tracing/distributed_trace_attributes.rb +84 -0
  79. data/lib/new_relic/agent/distributed_tracing/distributed_trace_metrics.rb +75 -0
  80. data/lib/new_relic/agent/distributed_tracing/distributed_trace_payload.rb +163 -0
  81. data/lib/new_relic/agent/distributed_tracing/distributed_trace_transport_type.rb +38 -0
  82. data/lib/new_relic/agent/distributed_tracing/trace_context.rb +245 -0
  83. data/lib/new_relic/agent/distributed_tracing/trace_context_payload.rb +127 -0
  84. data/lib/new_relic/agent/distributed_tracing.rb +113 -32
  85. data/lib/new_relic/agent/encoding_normalizer.rb +5 -3
  86. data/lib/new_relic/agent/error_collector.rb +129 -65
  87. data/lib/new_relic/agent/error_event_aggregator.rb +10 -8
  88. data/lib/new_relic/agent/error_filter.rb +174 -0
  89. data/lib/new_relic/agent/error_trace_aggregator.rb +11 -8
  90. data/lib/new_relic/agent/event_aggregator.rb +43 -48
  91. data/lib/new_relic/agent/event_buffer.rb +8 -9
  92. data/lib/new_relic/agent/event_listener.rb +2 -3
  93. data/lib/new_relic/agent/event_loop.rb +28 -26
  94. data/lib/new_relic/agent/external.rb +19 -52
  95. data/lib/new_relic/agent/guid_generator.rb +30 -0
  96. data/lib/new_relic/agent/harvester.rb +6 -9
  97. data/lib/new_relic/agent/heap.rb +9 -10
  98. data/lib/new_relic/agent/hostname.rb +22 -9
  99. data/lib/new_relic/agent/http_clients/abstract.rb +69 -0
  100. data/lib/new_relic/agent/http_clients/curb_wrappers.rb +30 -26
  101. data/lib/new_relic/agent/http_clients/excon_wrappers.rb +37 -21
  102. data/lib/new_relic/agent/http_clients/http_rb_wrappers.rb +22 -23
  103. data/lib/new_relic/agent/http_clients/httpclient_wrappers.rb +18 -17
  104. data/lib/new_relic/agent/http_clients/net_http_wrappers.rb +28 -8
  105. data/lib/new_relic/agent/http_clients/typhoeus_wrappers.rb +17 -17
  106. data/lib/new_relic/agent/http_clients/uri_util.rb +13 -14
  107. data/lib/new_relic/agent/instrumentation/action_cable_subscriber.rb +22 -55
  108. data/lib/new_relic/agent/instrumentation/action_controller_other_subscriber.rb +42 -0
  109. data/lib/new_relic/agent/instrumentation/action_controller_subscriber.rb +60 -72
  110. data/lib/new_relic/agent/instrumentation/action_dispatch.rb +31 -0
  111. data/lib/new_relic/agent/instrumentation/action_dispatch_subscriber.rb +64 -0
  112. data/lib/new_relic/agent/instrumentation/action_mailbox.rb +30 -0
  113. data/lib/new_relic/agent/instrumentation/action_mailbox_subscriber.rb +33 -0
  114. data/lib/new_relic/agent/instrumentation/action_mailer.rb +30 -0
  115. data/lib/new_relic/agent/instrumentation/action_mailer_subscriber.rb +85 -0
  116. data/lib/new_relic/agent/instrumentation/action_view_subscriber.rb +86 -62
  117. data/lib/new_relic/agent/instrumentation/active_job.rb +34 -14
  118. data/lib/new_relic/agent/instrumentation/active_job_subscriber.rb +41 -0
  119. data/lib/new_relic/agent/instrumentation/active_merchant.rb +21 -7
  120. data/lib/new_relic/agent/instrumentation/active_record.rb +97 -47
  121. data/lib/new_relic/agent/instrumentation/active_record_helper.rb +97 -73
  122. data/lib/new_relic/agent/instrumentation/active_record_notifications.rb +70 -76
  123. data/lib/new_relic/agent/instrumentation/active_record_prepend.rb +36 -12
  124. data/lib/new_relic/agent/instrumentation/active_record_subscriber.rb +65 -66
  125. data/lib/new_relic/agent/instrumentation/active_storage.rb +8 -4
  126. data/lib/new_relic/agent/instrumentation/active_storage_subscriber.rb +11 -32
  127. data/lib/new_relic/agent/instrumentation/active_support.rb +27 -0
  128. data/lib/new_relic/agent/instrumentation/active_support_logger/chain.rb +23 -0
  129. data/lib/new_relic/agent/instrumentation/active_support_logger/instrumentation.rb +20 -0
  130. data/lib/new_relic/agent/instrumentation/active_support_logger/prepend.rb +12 -0
  131. data/lib/new_relic/agent/instrumentation/active_support_logger.rb +24 -0
  132. data/lib/new_relic/agent/instrumentation/active_support_subscriber.rb +41 -0
  133. data/lib/new_relic/agent/instrumentation/bunny/chain.rb +45 -0
  134. data/lib/new_relic/agent/instrumentation/bunny/instrumentation.rb +150 -0
  135. data/lib/new_relic/agent/instrumentation/bunny/prepend.rb +35 -0
  136. data/lib/new_relic/agent/instrumentation/bunny.rb +14 -138
  137. data/lib/new_relic/agent/instrumentation/concurrent_ruby/chain.rb +36 -0
  138. data/lib/new_relic/agent/instrumentation/concurrent_ruby/instrumentation.rb +21 -0
  139. data/lib/new_relic/agent/instrumentation/concurrent_ruby/prepend.rb +27 -0
  140. data/lib/new_relic/agent/instrumentation/concurrent_ruby.rb +31 -0
  141. data/lib/new_relic/agent/instrumentation/controller_instrumentation.rb +75 -63
  142. data/lib/new_relic/agent/instrumentation/curb/chain.rb +91 -0
  143. data/lib/new_relic/agent/instrumentation/curb/instrumentation.rb +221 -0
  144. data/lib/new_relic/agent/instrumentation/curb/prepend.rb +61 -0
  145. data/lib/new_relic/agent/instrumentation/curb.rb +16 -201
  146. data/lib/new_relic/agent/instrumentation/custom_events.rb +12 -0
  147. data/lib/new_relic/agent/instrumentation/custom_events_subscriber.rb +38 -0
  148. data/lib/new_relic/agent/instrumentation/delayed_job/chain.rb +36 -0
  149. data/lib/new_relic/agent/instrumentation/delayed_job/instrumentation.rb +48 -0
  150. data/lib/new_relic/agent/instrumentation/delayed_job/prepend.rb +33 -0
  151. data/lib/new_relic/agent/instrumentation/delayed_job_instrumentation.rb +31 -52
  152. data/lib/new_relic/agent/instrumentation/elasticsearch/chain.rb +29 -0
  153. data/lib/new_relic/agent/instrumentation/elasticsearch/instrumentation.rb +67 -0
  154. data/lib/new_relic/agent/instrumentation/elasticsearch/prepend.rb +13 -0
  155. data/lib/new_relic/agent/instrumentation/elasticsearch.rb +31 -0
  156. data/lib/new_relic/agent/instrumentation/excon/middleware.rb +10 -8
  157. data/lib/new_relic/agent/instrumentation/excon.rb +29 -31
  158. data/lib/new_relic/agent/instrumentation/fiber/chain.rb +20 -0
  159. data/lib/new_relic/agent/instrumentation/fiber/instrumentation.rb +24 -0
  160. data/lib/new_relic/agent/instrumentation/fiber/prepend.rb +18 -0
  161. data/lib/new_relic/agent/instrumentation/fiber.rb +25 -0
  162. data/lib/new_relic/agent/instrumentation/grape/chain.rb +24 -0
  163. data/lib/new_relic/agent/instrumentation/grape/instrumentation.rb +100 -0
  164. data/lib/new_relic/agent/instrumentation/grape/prepend.rb +17 -0
  165. data/lib/new_relic/agent/instrumentation/grape.rb +17 -124
  166. data/lib/new_relic/agent/instrumentation/grpc/client/chain.rb +97 -0
  167. data/lib/new_relic/agent/instrumentation/grpc/client/instrumentation.rb +90 -0
  168. data/lib/new_relic/agent/instrumentation/grpc/client/prepend.rb +111 -0
  169. data/lib/new_relic/agent/instrumentation/grpc/client/request_wrapper.rb +30 -0
  170. data/lib/new_relic/agent/instrumentation/grpc/helper.rb +32 -0
  171. data/lib/new_relic/agent/instrumentation/grpc/server/chain.rb +69 -0
  172. data/lib/new_relic/agent/instrumentation/grpc/server/instrumentation.rb +134 -0
  173. data/lib/new_relic/agent/instrumentation/grpc/server/rpc_desc_prepend.rb +35 -0
  174. data/lib/new_relic/agent/instrumentation/grpc/server/rpc_server_prepend.rb +26 -0
  175. data/lib/new_relic/agent/instrumentation/grpc_client.rb +23 -0
  176. data/lib/new_relic/agent/instrumentation/grpc_server.rb +25 -0
  177. data/lib/new_relic/agent/instrumentation/httpclient/chain.rb +24 -0
  178. data/lib/new_relic/agent/instrumentation/httpclient/instrumentation.rb +37 -0
  179. data/lib/new_relic/agent/instrumentation/httpclient/prepend.rb +15 -0
  180. data/lib/new_relic/agent/instrumentation/httpclient.rb +12 -32
  181. data/lib/new_relic/agent/instrumentation/httprb/chain.rb +22 -0
  182. data/lib/new_relic/agent/instrumentation/httprb/instrumentation.rb +30 -0
  183. data/lib/new_relic/agent/instrumentation/httprb/prepend.rb +15 -0
  184. data/lib/new_relic/agent/instrumentation/httprb.rb +29 -0
  185. data/lib/new_relic/agent/instrumentation/ignore_actions.rb +6 -7
  186. data/lib/new_relic/agent/instrumentation/logger/chain.rb +21 -0
  187. data/lib/new_relic/agent/instrumentation/logger/instrumentation.rb +66 -0
  188. data/lib/new_relic/agent/instrumentation/logger/prepend.rb +13 -0
  189. data/lib/new_relic/agent/instrumentation/logger.rb +26 -0
  190. data/lib/new_relic/agent/instrumentation/memcache/chain.rb +15 -0
  191. data/lib/new_relic/agent/instrumentation/memcache/dalli.rb +60 -125
  192. data/lib/new_relic/agent/instrumentation/memcache/helper.rb +59 -0
  193. data/lib/new_relic/agent/instrumentation/memcache/instrumentation.rb +90 -0
  194. data/lib/new_relic/agent/instrumentation/memcache/prepend.rb +103 -0
  195. data/lib/new_relic/agent/instrumentation/memcache.rb +57 -71
  196. data/lib/new_relic/agent/instrumentation/middleware_proxy.rb +16 -15
  197. data/lib/new_relic/agent/instrumentation/middleware_tracing.rb +11 -11
  198. data/lib/new_relic/agent/instrumentation/mongo.rb +7 -132
  199. data/lib/new_relic/agent/instrumentation/mongodb_command_subscriber.rb +53 -17
  200. data/lib/new_relic/agent/instrumentation/net_http/chain.rb +24 -0
  201. data/lib/new_relic/agent/instrumentation/net_http/instrumentation.rb +40 -0
  202. data/lib/new_relic/agent/instrumentation/net_http/prepend.rb +21 -0
  203. data/lib/new_relic/agent/instrumentation/net_http.rb +44 -0
  204. data/lib/new_relic/agent/instrumentation/notifications_subscriber.rb +142 -0
  205. data/lib/new_relic/agent/instrumentation/padrino/chain.rb +38 -0
  206. data/lib/new_relic/agent/instrumentation/padrino/instrumentation.rb +28 -0
  207. data/lib/new_relic/agent/instrumentation/padrino/prepend.rb +20 -0
  208. data/lib/new_relic/agent/instrumentation/padrino.rb +22 -58
  209. data/lib/new_relic/agent/instrumentation/passenger_instrumentation.rb +7 -7
  210. data/lib/new_relic/agent/instrumentation/queue_time.rb +9 -10
  211. data/lib/new_relic/agent/instrumentation/rack/chain.rb +66 -0
  212. data/lib/new_relic/agent/instrumentation/rack/helpers.rb +33 -0
  213. data/lib/new_relic/agent/instrumentation/rack/instrumentation.rb +75 -0
  214. data/lib/new_relic/agent/instrumentation/rack/prepend.rb +43 -0
  215. data/lib/new_relic/agent/instrumentation/rack.rb +33 -141
  216. data/lib/new_relic/agent/instrumentation/rails3/action_controller.rb +22 -57
  217. data/lib/new_relic/agent/instrumentation/rails_middleware.rb +5 -5
  218. data/lib/new_relic/agent/instrumentation/rails_notifications/action_cable.rb +10 -10
  219. data/lib/new_relic/agent/instrumentation/rails_notifications/action_controller.rb +18 -6
  220. data/lib/new_relic/agent/instrumentation/rails_notifications/action_view.rb +9 -6
  221. data/lib/new_relic/agent/instrumentation/rails_notifications/custom_events.rb +30 -0
  222. data/lib/new_relic/agent/instrumentation/rake/chain.rb +20 -0
  223. data/lib/new_relic/agent/instrumentation/rake/instrumentation.rb +142 -0
  224. data/lib/new_relic/agent/instrumentation/rake/prepend.rb +14 -0
  225. data/lib/new_relic/agent/instrumentation/rake.rb +18 -158
  226. data/lib/new_relic/agent/instrumentation/redis/chain.rb +45 -0
  227. data/lib/new_relic/agent/instrumentation/redis/constants.rb +17 -0
  228. data/lib/new_relic/agent/instrumentation/redis/instrumentation.rb +94 -0
  229. data/lib/new_relic/agent/instrumentation/redis/middleware.rb +16 -0
  230. data/lib/new_relic/agent/instrumentation/redis/prepend.rb +29 -0
  231. data/lib/new_relic/agent/instrumentation/redis.rb +20 -103
  232. data/lib/new_relic/agent/instrumentation/resque/chain.rb +21 -0
  233. data/lib/new_relic/agent/instrumentation/resque/helper.rb +19 -0
  234. data/lib/new_relic/agent/instrumentation/resque/instrumentation.rb +34 -0
  235. data/lib/new_relic/agent/instrumentation/resque/prepend.rb +15 -0
  236. data/lib/new_relic/agent/instrumentation/resque.rb +33 -41
  237. data/lib/new_relic/agent/instrumentation/sequel.rb +17 -20
  238. data/lib/new_relic/agent/instrumentation/sequel_helper.rb +13 -13
  239. data/lib/new_relic/agent/instrumentation/sidekiq/client.rb +20 -0
  240. data/lib/new_relic/agent/instrumentation/sidekiq/extensions/delayed_class.rb +30 -0
  241. data/lib/new_relic/agent/instrumentation/sidekiq/server.rb +37 -0
  242. data/lib/new_relic/agent/instrumentation/sidekiq.rb +30 -46
  243. data/lib/new_relic/agent/instrumentation/sinatra/chain.rb +55 -0
  244. data/lib/new_relic/agent/instrumentation/sinatra/ignorer.rb +31 -37
  245. data/lib/new_relic/agent/instrumentation/sinatra/instrumentation.rb +126 -0
  246. data/lib/new_relic/agent/instrumentation/sinatra/prepend.rb +33 -0
  247. data/lib/new_relic/agent/instrumentation/sinatra/transaction_namer.rb +4 -4
  248. data/lib/new_relic/agent/instrumentation/sinatra.rb +35 -165
  249. data/lib/new_relic/agent/instrumentation/thread/chain.rb +24 -0
  250. data/lib/new_relic/agent/instrumentation/thread/instrumentation.rb +28 -0
  251. data/lib/new_relic/agent/instrumentation/thread/prepend.rb +22 -0
  252. data/lib/new_relic/agent/instrumentation/thread.rb +20 -0
  253. data/lib/new_relic/agent/instrumentation/tilt/chain.rb +24 -0
  254. data/lib/new_relic/agent/instrumentation/tilt/instrumentation.rb +42 -0
  255. data/lib/new_relic/agent/instrumentation/tilt/prepend.rb +13 -0
  256. data/lib/new_relic/agent/instrumentation/tilt.rb +25 -0
  257. data/lib/new_relic/agent/instrumentation/typhoeus/chain.rb +22 -0
  258. data/lib/new_relic/agent/instrumentation/typhoeus/instrumentation.rb +80 -0
  259. data/lib/new_relic/agent/instrumentation/typhoeus/prepend.rb +14 -0
  260. data/lib/new_relic/agent/instrumentation/typhoeus.rb +14 -76
  261. data/lib/new_relic/agent/instrumentation.rb +2 -2
  262. data/lib/new_relic/agent/internal_agent_error.rb +3 -3
  263. data/lib/new_relic/agent/javascript_instrumentor.rb +60 -49
  264. data/lib/new_relic/agent/linking_metadata.rb +44 -0
  265. data/lib/new_relic/agent/local_log_decorator.rb +37 -0
  266. data/lib/new_relic/agent/log_event_aggregator.rb +235 -0
  267. data/lib/new_relic/agent/log_once.rb +2 -2
  268. data/lib/new_relic/agent/log_priority.rb +20 -0
  269. data/lib/new_relic/agent/logging.rb +182 -0
  270. data/lib/new_relic/agent/memory_logger.rb +3 -3
  271. data/lib/new_relic/agent/messaging.rb +74 -156
  272. data/lib/new_relic/agent/method_tracer.rb +157 -150
  273. data/lib/new_relic/agent/method_tracer_helpers.rb +89 -12
  274. data/lib/new_relic/agent/monitors/cross_app_monitor.rb +117 -0
  275. data/lib/new_relic/agent/monitors/distributed_tracing_monitor.rb +28 -0
  276. data/lib/new_relic/agent/{inbound_request_monitor.rb → monitors/inbound_request_monitor.rb} +5 -6
  277. data/lib/new_relic/agent/{synthetics_monitor.rb → monitors/synthetics_monitor.rb} +8 -13
  278. data/lib/new_relic/agent/monitors.rb +26 -0
  279. data/lib/new_relic/agent/new_relic_service/encoders.rb +8 -8
  280. data/lib/new_relic/agent/new_relic_service/json_marshaller.rb +7 -7
  281. data/lib/new_relic/agent/new_relic_service/marshaller.rb +3 -3
  282. data/lib/new_relic/agent/new_relic_service/security_policy_settings.rb +5 -5
  283. data/lib/new_relic/agent/new_relic_service.rb +273 -202
  284. data/lib/new_relic/agent/noticeable_error.rb +19 -0
  285. data/lib/new_relic/agent/null_logger.rb +8 -4
  286. data/lib/new_relic/agent/obfuscator.rb +9 -11
  287. data/lib/new_relic/agent/parameter_filtering.rb +30 -16
  288. data/lib/new_relic/agent/payload_metric_mapping.rb +10 -11
  289. data/lib/new_relic/agent/pipe_channel_manager.rb +34 -23
  290. data/lib/new_relic/agent/pipe_service.rb +14 -9
  291. data/lib/new_relic/agent/prepend_supportability.rb +3 -3
  292. data/lib/new_relic/agent/priority_sampled_buffer.rb +17 -15
  293. data/lib/new_relic/agent/rules_engine/replacement_rule.rb +12 -12
  294. data/lib/new_relic/agent/rules_engine/segment_terms_rule.rb +13 -14
  295. data/lib/new_relic/agent/rules_engine.rb +6 -5
  296. data/lib/new_relic/agent/sampler.rb +6 -6
  297. data/lib/new_relic/agent/sampler_collection.rb +5 -6
  298. data/lib/new_relic/agent/samplers/cpu_sampler.rb +9 -8
  299. data/lib/new_relic/agent/samplers/delayed_job_sampler.rb +21 -18
  300. data/lib/new_relic/agent/samplers/memory_sampler.rb +33 -22
  301. data/lib/new_relic/agent/samplers/object_sampler.rb +3 -3
  302. data/lib/new_relic/agent/samplers/vm_sampler.rb +22 -20
  303. data/lib/new_relic/agent/span_event_aggregator.rb +17 -19
  304. data/lib/new_relic/agent/span_event_primitive.rb +118 -58
  305. data/lib/new_relic/agent/sql_sampler.rb +23 -23
  306. data/lib/new_relic/agent/stats.rb +80 -43
  307. data/lib/new_relic/agent/stats_engine/gc_profiler.rb +11 -13
  308. data/lib/new_relic/agent/stats_engine/stats_hash.rb +13 -14
  309. data/lib/new_relic/agent/stats_engine.rb +9 -9
  310. data/lib/new_relic/agent/synthetics_event_aggregator.rb +9 -10
  311. data/lib/new_relic/agent/system_info.rb +97 -68
  312. data/lib/new_relic/agent/threading/agent_thread.rb +19 -15
  313. data/lib/new_relic/agent/threading/backtrace_node.rb +13 -14
  314. data/lib/new_relic/agent/threading/backtrace_service.rb +21 -25
  315. data/lib/new_relic/agent/threading/thread_profile.rb +32 -46
  316. data/lib/new_relic/agent/timestamp_sampled_buffer.rb +3 -3
  317. data/lib/new_relic/agent/tracer.rb +159 -107
  318. data/lib/new_relic/agent/transaction/abstract_segment.rb +147 -51
  319. data/lib/new_relic/agent/transaction/datastore_segment.rb +23 -19
  320. data/lib/new_relic/agent/transaction/distributed_tracer.rb +185 -0
  321. data/lib/new_relic/agent/transaction/distributed_tracing.rb +73 -164
  322. data/lib/new_relic/agent/transaction/external_request_segment.rb +67 -64
  323. data/lib/new_relic/agent/transaction/message_broker_segment.rb +34 -46
  324. data/lib/new_relic/agent/transaction/request_attributes.rb +40 -40
  325. data/lib/new_relic/agent/transaction/segment.rb +46 -10
  326. data/lib/new_relic/agent/transaction/slowest_sample_buffer.rb +2 -4
  327. data/lib/new_relic/agent/transaction/synthetics_sample_buffer.rb +3 -3
  328. data/lib/new_relic/agent/transaction/trace.rb +22 -25
  329. data/lib/new_relic/agent/transaction/trace_builder.rb +11 -12
  330. data/lib/new_relic/agent/transaction/trace_context.rb +168 -0
  331. data/lib/new_relic/agent/transaction/trace_node.rb +36 -32
  332. data/lib/new_relic/agent/transaction/tracing.rb +16 -13
  333. data/lib/new_relic/agent/transaction/transaction_sample_buffer.rb +7 -7
  334. data/lib/new_relic/agent/transaction.rb +248 -205
  335. data/lib/new_relic/agent/transaction_error_primitive.rb +34 -37
  336. data/lib/new_relic/agent/transaction_event_aggregator.rb +17 -17
  337. data/lib/new_relic/agent/transaction_event_primitive.rb +44 -56
  338. data/lib/new_relic/agent/transaction_event_recorder.rb +17 -16
  339. data/lib/new_relic/agent/transaction_metrics.rb +11 -10
  340. data/lib/new_relic/agent/transaction_sampler.rb +9 -14
  341. data/lib/new_relic/agent/transaction_time_aggregator.rb +33 -28
  342. data/lib/new_relic/agent/utilization/aws.rb +35 -5
  343. data/lib/new_relic/agent/utilization/azure.rb +7 -7
  344. data/lib/new_relic/agent/utilization/gcp.rb +11 -11
  345. data/lib/new_relic/agent/utilization/pcf.rb +7 -6
  346. data/lib/new_relic/agent/utilization/vendor.rb +45 -30
  347. data/lib/new_relic/agent/utilization_data.rb +8 -6
  348. data/lib/new_relic/agent/vm/jruby_vm.rb +2 -2
  349. data/lib/new_relic/agent/vm/monotonic_gc_profiler.rb +4 -4
  350. data/lib/new_relic/agent/vm/mri_vm.rb +54 -26
  351. data/lib/new_relic/agent/vm/snapshot.rb +6 -6
  352. data/lib/new_relic/agent/vm.rb +2 -2
  353. data/lib/new_relic/agent/worker_loop.rb +11 -13
  354. data/lib/new_relic/agent.rb +219 -89
  355. data/lib/new_relic/cli/command.rb +22 -24
  356. data/lib/new_relic/cli/commands/deployments.rb +102 -52
  357. data/lib/new_relic/cli/commands/install.rb +33 -35
  358. data/lib/new_relic/coerce.rb +42 -15
  359. data/lib/new_relic/collection_helper.rb +51 -49
  360. data/lib/new_relic/constants.rb +38 -0
  361. data/lib/new_relic/control/class_methods.rb +6 -6
  362. data/lib/new_relic/control/frameworks/external.rb +3 -3
  363. data/lib/new_relic/control/frameworks/rails.rb +50 -32
  364. data/lib/new_relic/control/frameworks/rails3.rb +4 -5
  365. data/lib/new_relic/control/frameworks/rails4.rb +2 -2
  366. data/lib/new_relic/control/frameworks/rails_notifications.rb +2 -2
  367. data/lib/new_relic/control/frameworks/ruby.rb +4 -4
  368. data/lib/new_relic/control/frameworks/sinatra.rb +8 -2
  369. data/lib/new_relic/control/frameworks.rb +2 -2
  370. data/lib/new_relic/control/instance_methods.rb +33 -42
  371. data/lib/new_relic/control/instrumentation.rb +40 -12
  372. data/lib/new_relic/control/private_instance_methods.rb +48 -0
  373. data/lib/new_relic/control/server_methods.rb +4 -5
  374. data/lib/new_relic/control.rb +2 -3
  375. data/lib/new_relic/delayed_job_injection.rb +2 -2
  376. data/lib/new_relic/dependency_detection.rb +129 -31
  377. data/lib/new_relic/environment_report.rb +42 -36
  378. data/lib/new_relic/helper.rb +50 -8
  379. data/lib/new_relic/language_support.rb +31 -7
  380. data/lib/new_relic/latest_changes.rb +11 -10
  381. data/lib/new_relic/local_environment.rb +23 -27
  382. data/lib/new_relic/metric_data.rb +32 -27
  383. data/lib/new_relic/metric_spec.rb +9 -7
  384. data/lib/new_relic/noticed_error.rb +60 -45
  385. data/lib/new_relic/rack/agent_hooks.rb +2 -2
  386. data/lib/new_relic/rack/agent_middleware.rb +6 -4
  387. data/lib/new_relic/rack/browser_monitoring.rb +136 -115
  388. data/lib/new_relic/rack.rb +2 -2
  389. data/lib/new_relic/recipes/capistrano3.rb +5 -63
  390. data/lib/new_relic/recipes/capistrano_legacy.rb +25 -28
  391. data/lib/new_relic/recipes/helpers/send_deployment.rb +70 -0
  392. data/lib/new_relic/recipes.rb +2 -2
  393. data/lib/new_relic/supportability_helper.rb +23 -7
  394. data/lib/new_relic/traced_thread.rb +39 -0
  395. data/lib/new_relic/version.rb +7 -18
  396. data/lib/newrelic_rpm.rb +21 -34
  397. data/lib/sequel/extensions/{newrelic_instrumentation.rb → new_relic_instrumentation.rb} +18 -21
  398. data/lib/sequel/plugins/{newrelic_instrumentation.rb → new_relic_instrumentation.rb} +10 -16
  399. data/lib/tasks/all.rb +4 -4
  400. data/lib/tasks/config.rake +24 -120
  401. data/lib/tasks/coverage_report.rake +28 -0
  402. data/lib/tasks/helpers/config.html.erb +21 -0
  403. data/lib/tasks/helpers/format.rb +123 -0
  404. data/lib/tasks/helpers/matches.rb +12 -0
  405. data/lib/tasks/helpers/prompt.rb +24 -0
  406. data/lib/tasks/helpers/removers.rb +33 -0
  407. data/lib/tasks/install.rake +8 -4
  408. data/lib/tasks/instrumentation_generator/README.md +63 -0
  409. data/lib/tasks/instrumentation_generator/TODO.md +33 -0
  410. data/lib/tasks/instrumentation_generator/instrumentation.thor +121 -0
  411. data/lib/tasks/instrumentation_generator/templates/Envfile.tt +9 -0
  412. data/lib/tasks/instrumentation_generator/templates/chain.tt +22 -0
  413. data/lib/tasks/instrumentation_generator/templates/chain_method.tt +8 -0
  414. data/lib/tasks/instrumentation_generator/templates/dependency_detection.tt +29 -0
  415. data/lib/tasks/instrumentation_generator/templates/instrumentation.tt +13 -0
  416. data/lib/tasks/instrumentation_generator/templates/instrumentation_method.tt +3 -0
  417. data/lib/tasks/instrumentation_generator/templates/newrelic.yml.tt +19 -0
  418. data/lib/tasks/instrumentation_generator/templates/prepend.tt +13 -0
  419. data/lib/tasks/instrumentation_generator/templates/prepend_method.tt +3 -0
  420. data/lib/tasks/instrumentation_generator/templates/test.tt +15 -0
  421. data/lib/tasks/multiverse.rake +4 -0
  422. data/lib/tasks/multiverse.rb +23 -9
  423. data/lib/tasks/newrelic.rb +3 -2
  424. data/lib/tasks/tests.rake +17 -17
  425. data/newrelic.yml +672 -3
  426. data/newrelic_rpm.gemspec +50 -34
  427. data/recipes/newrelic.rb +3 -3
  428. data/test/agent_helper.rb +414 -98
  429. metadata +302 -93
  430. data/.travis.yml +0 -170
  431. data/bin/mongrel_rpm +0 -33
  432. data/cert/cacert.pem +0 -1177
  433. data/lib/new_relic/agent/commands/xray_session.rb +0 -55
  434. data/lib/new_relic/agent/commands/xray_session_collection.rb +0 -161
  435. data/lib/new_relic/agent/configuration/event_data.rb +0 -39
  436. data/lib/new_relic/agent/cross_app_monitor.rb +0 -110
  437. data/lib/new_relic/agent/datastores/mongo/obfuscator.rb +0 -44
  438. data/lib/new_relic/agent/datastores/mongo/statement_formatter.rb +0 -53
  439. data/lib/new_relic/agent/distributed_trace_monitor.rb +0 -40
  440. data/lib/new_relic/agent/distributed_trace_payload.rb +0 -242
  441. data/lib/new_relic/agent/http_clients/abstract_request.rb +0 -31
  442. data/lib/new_relic/agent/instrumentation/acts_as_solr.rb +0 -74
  443. data/lib/new_relic/agent/instrumentation/authlogic.rb +0 -25
  444. data/lib/new_relic/agent/instrumentation/data_mapper.rb +0 -202
  445. data/lib/new_relic/agent/instrumentation/evented_subscriber.rb +0 -135
  446. data/lib/new_relic/agent/instrumentation/excon/connection.rb +0 -46
  447. data/lib/new_relic/agent/instrumentation/http.rb +0 -46
  448. data/lib/new_relic/agent/instrumentation/merb/controller.rb +0 -44
  449. data/lib/new_relic/agent/instrumentation/merb/errors.rb +0 -33
  450. data/lib/new_relic/agent/instrumentation/net.rb +0 -50
  451. data/lib/new_relic/agent/instrumentation/rails/action_controller.rb +0 -125
  452. data/lib/new_relic/agent/instrumentation/rails/action_web_service.rb +0 -46
  453. data/lib/new_relic/agent/instrumentation/rainbows_instrumentation.rb +0 -26
  454. data/lib/new_relic/agent/instrumentation/sunspot.rb +0 -33
  455. data/lib/new_relic/agent/range_extensions.rb +0 -47
  456. data/lib/new_relic/agent/supported_versions.rb +0 -275
  457. data/lib/new_relic/agent/transaction/attributes.rb +0 -154
  458. data/lib/new_relic/agent/transaction/xray_sample_buffer.rb +0 -64
  459. data/lib/new_relic/build.rb +0 -2
  460. data/lib/new_relic/control/frameworks/merb.rb +0 -29
  461. data/lib/new_relic/metrics.rb +0 -13
  462. data/lib/tasks/config.html.erb +0 -32
  463. data/lib/tasks/versions.html.erb +0 -28
  464. data/lib/tasks/versions.postface.html +0 -8
  465. data/lib/tasks/versions.preface.html +0 -9
  466. data/lib/tasks/versions.rake +0 -65
  467. data/lib/tasks/versions.txt.erb +0 -14
  468. /data/lib/tasks/{config.text.erb → helpers/config.text.erb} +0 -0
@@ -1,20 +1,32 @@
1
- # encoding: utf-8
2
1
  # This file is distributed under New Relic's license terms.
3
- # See https://github.com/newrelic/rpm/blob/master/LICENSE for complete details.
2
+ # See https://github.com/newrelic/newrelic-ruby-agent/blob/main/LICENSE for complete details.
3
+ # frozen_string_literal: true
4
4
 
5
5
  require 'forwardable'
6
6
 
7
7
  module NewRelic
8
8
  module Agent
9
9
  module Configuration
10
-
11
10
  # Helper since default Procs are evaluated in the context of this module
12
11
  def self.value_of(key)
13
- Proc.new do
12
+ proc do
14
13
  NewRelic::Agent.config[key]
15
14
  end
16
15
  end
17
16
 
17
+ def self.instrumentation_value_from_boolean(key)
18
+ proc do
19
+ NewRelic::Agent.config[key] ? 'auto' : 'disabled'
20
+ end
21
+ end
22
+
23
+ # Marks the config option as deprecated in the documentation once generated.
24
+ # Does not appear in logs.
25
+ def self.deprecated_description(new_setting, description)
26
+ link_ref = new_setting.to_s.tr('.', '-')
27
+ %{Please see: [#{new_setting}](docs/agents/ruby-agent/configuration/ruby-agent-configuration##{link_ref}). \n\n#{description}}
28
+ end
29
+
18
30
  class Boolean
19
31
  def self.===(o)
20
32
  TrueClass === o or FalseClass === o
@@ -44,27 +56,35 @@ module NewRelic
44
56
  default_settings[:transform] if default_settings
45
57
  end
46
58
 
47
- def self.config_search_paths
48
- Proc.new {
49
- paths = [
50
- File.join("config","newrelic.yml"),
51
- File.join("newrelic.yml")
52
- ]
59
+ def self.config_search_paths # rubocop:disable Metrics/AbcSize
60
+ proc {
61
+ yaml = 'newrelic.yml'
62
+ config_yaml = File.join('config', yaml)
63
+ erb = 'newrelic.yml.erb'
64
+ config_erb = File.join('config', erb)
65
+
66
+ paths = [config_yaml, yaml, config_erb, erb]
53
67
 
54
68
  if NewRelic::Control.instance.root
55
- paths << File.join(NewRelic::Control.instance.root, "config", "newrelic.yml")
56
- paths << File.join(NewRelic::Control.instance.root, "newrelic.yml")
69
+ paths << File.join(NewRelic::Control.instance.root, config_yaml)
70
+ paths << File.join(NewRelic::Control.instance.root, yaml)
71
+ paths << File.join(NewRelic::Control.instance.root, config_erb)
72
+ paths << File.join(NewRelic::Control.instance.root, erb)
57
73
  end
58
74
 
59
- if ENV["HOME"]
60
- paths << File.join(ENV["HOME"], ".newrelic", "newrelic.yml")
61
- paths << File.join(ENV["HOME"], "newrelic.yml")
75
+ if ENV['HOME']
76
+ paths << File.join(ENV['HOME'], '.newrelic', yaml)
77
+ paths << File.join(ENV['HOME'], yaml)
78
+ paths << File.join(ENV['HOME'], '.newrelic', erb)
79
+ paths << File.join(ENV['HOME'], erb)
62
80
  end
63
81
 
64
82
  # If we're packaged for warbler, we can tell from GEM_HOME
65
- if ENV["GEM_HOME"] && ENV["GEM_HOME"].end_with?(".jar!")
66
- app_name = File.basename(ENV["GEM_HOME"], ".jar!")
67
- paths << File.join(ENV["GEM_HOME"], app_name, "config", "newrelic.yml")
83
+ # the following line needs else branch coverage
84
+ if ENV['GEM_HOME'] && ENV['GEM_HOME'].end_with?('.jar!') # rubocop:disable Style/SafeNavigation
85
+ app_name = File.basename(ENV['GEM_HOME'], '.jar!')
86
+ paths << File.join(ENV['GEM_HOME'], app_name, config_yaml)
87
+ paths << File.join(ENV['GEM_HOME'], app_name, config_erb)
68
88
  end
69
89
 
70
90
  paths
@@ -72,29 +92,27 @@ module NewRelic
72
92
  end
73
93
 
74
94
  def self.config_path
75
- Proc.new {
95
+ proc {
76
96
  found_path = NewRelic::Agent.config[:config_search_paths].detect do |file|
77
- File.expand_path(file) if File.exist? file
97
+ File.expand_path(file) if File.exist?(file)
78
98
  end
79
- found_path || ""
99
+ found_path || NewRelic::EMPTY_STR
80
100
  }
81
101
  end
82
102
 
83
103
  def self.framework
84
- Proc.new {
104
+ proc {
85
105
  case
86
106
  when defined?(::NewRelic::TEST) then :test
87
- when defined?(::Merb) && defined?(::Merb::Plugins) then :merb
88
107
  when defined?(::Rails::VERSION)
89
108
  case Rails::VERSION::MAJOR
90
- when 0..2
91
- :rails
92
109
  when 3
93
110
  :rails3
94
- when 4..6
111
+ when 4..7
95
112
  :rails_notifications
96
113
  else
97
- ::NewRelic::Agent.logger.error "Detected unsupported Rails version #{Rails::VERSION::STRING}"
114
+ ::NewRelic::Agent.logger.warn("Detected untested Rails version #{Rails::VERSION::STRING}")
115
+ :rails_notifications
98
116
  end
99
117
  when defined?(::Sinatra) && defined?(::Sinatra::Base) then :sinatra
100
118
  when defined?(::NewRelic::IA) then :external
@@ -104,19 +122,19 @@ module NewRelic
104
122
  end
105
123
 
106
124
  def self.agent_enabled
107
- Proc.new {
125
+ proc {
108
126
  NewRelic::Agent.config[:enabled] &&
109
- (NewRelic::Agent.config[:test_mode] || NewRelic::Agent.config[:monitor_mode]) &&
110
- NewRelic::Agent::Autostart.agent_should_start?
127
+ (NewRelic::Agent.config[:test_mode] || NewRelic::Agent.config[:monitor_mode]) &&
128
+ NewRelic::Agent::Autostart.agent_should_start?
111
129
  }
112
130
  end
113
131
 
114
132
  DEFAULT_LOG_DIR = 'log/'.freeze
115
133
 
116
134
  def self.audit_log_path
117
- Proc.new {
135
+ proc {
118
136
  log_file_path = NewRelic::Agent.config[:log_file_path]
119
- wants_stdout = (log_file_path.upcase == 'STDOUT')
137
+ wants_stdout = (log_file_path.casecmp(NewRelic::STANDARD_OUT) == 0)
120
138
  audit_log_dir = wants_stdout ? DEFAULT_LOG_DIR : log_file_path
121
139
 
122
140
  File.join(audit_log_dir, 'newrelic_audit.log')
@@ -124,30 +142,23 @@ module NewRelic
124
142
  end
125
143
 
126
144
  def self.app_name
127
- Proc.new { NewRelic::Control.instance.env }
145
+ proc { NewRelic::Control.instance.env }
128
146
  end
129
147
 
130
148
  def self.dispatcher
131
- Proc.new { NewRelic::Control.instance.local_env.discovered_dispatcher }
149
+ proc { NewRelic::Control.instance.local_env.discovered_dispatcher }
132
150
  end
133
151
 
134
152
  def self.thread_profiler_enabled
135
- Proc.new { NewRelic::Agent::Threading::BacktraceService.is_supported? }
136
- end
137
-
138
- # This check supports the js_errors_beta key we've asked clients to
139
- # set. Once JS errors are GA, browser_monitoring.loader can stop
140
- # being dynamic.
141
- def self.browser_monitoring_loader
142
- Proc.new { NewRelic::Agent.config[:js_errors_beta] ? "full" : "rum"}
153
+ proc { NewRelic::Agent::Threading::BacktraceService.is_supported? }
143
154
  end
144
155
 
145
156
  def self.transaction_tracer_transaction_threshold
146
- Proc.new { NewRelic::Agent.config[:apdex_t] * 4 }
157
+ proc { NewRelic::Agent.config[:apdex_t] * 4 }
147
158
  end
148
159
 
149
160
  def self.profiling_available
150
- Proc.new {
161
+ proc {
151
162
  begin
152
163
  require 'ruby-prof'
153
164
  true
@@ -158,7 +169,7 @@ module NewRelic
158
169
  end
159
170
 
160
171
  def self.host
161
- Proc.new do
172
+ proc do
162
173
  regex = /\A(?<identifier>.+?)x/
163
174
  if matches = regex.match(String(NewRelic::Agent.config[:license_key]))
164
175
  "collector.#{matches['identifier']}.nr-data.net"
@@ -169,12 +180,16 @@ module NewRelic
169
180
  end
170
181
 
171
182
  def self.api_host
172
- Proc.new do
173
- if String(NewRelic::Agent.config[:license_key]).start_with? 'eu'
174
- 'rpm.eu.newrelic.com'
183
+ # only used for deployment task
184
+ proc do
185
+ api_version = if NewRelic::Agent.config[:api_key].nil? || NewRelic::Agent.config[:api_key].empty?
186
+ 'rpm'
175
187
  else
176
- 'rpm.newrelic.com'
188
+ 'api'
177
189
  end
190
+ api_region = 'eu.' if String(NewRelic::Agent.config[:license_key]).start_with?('eu')
191
+
192
+ "#{api_version}.#{api_region}newrelic.com"
178
193
  end
179
194
  end
180
195
 
@@ -196,22 +211,39 @@ module NewRelic
196
211
  end
197
212
  end
198
213
 
214
+ SEMICOLON = ';'.freeze
215
+ def self.convert_to_list_on_semicolon(value)
216
+ case value
217
+ when Array then value
218
+ when String then value.split(SEMICOLON)
219
+ else NewRelic::EMPTY_ARRAY
220
+ end
221
+ end
222
+
199
223
  def self.convert_to_constant_list(raw_value)
200
- const_names = convert_to_list(raw_value)
201
- const_names.map! do |class_name|
224
+ return NewRelic::EMPTY_ARRAY if raw_value.nil? || raw_value.empty?
225
+
226
+ constants = convert_to_list(raw_value).map! do |class_name|
202
227
  const = ::NewRelic::LanguageSupport.constantize(class_name)
228
+ NewRelic::Agent.logger.warn("Ignoring invalid constant '#{class_name}' in #{raw_value}") unless const
229
+ const
230
+ end
231
+ constants.compact!
232
+ constants
233
+ end
203
234
 
204
- unless const
205
- NewRelic::Agent.logger.warn("Ignoring unrecognized constant '#{class_name}' in #{raw_value}")
235
+ def self.enforce_fallback(allowed_values: nil, fallback: nil)
236
+ proc do |configured_value|
237
+ if allowed_values.any? { |v| v =~ /#{configured_value}/i }
238
+ configured_value
239
+ else
240
+ fallback
206
241
  end
207
-
208
- const
209
242
  end
210
- const_names.compact
211
243
  end
212
244
  end
213
245
 
214
- AUTOSTART_BLACKLISTED_RAKE_TASKS = [
246
+ AUTOSTART_DENYLISTED_RAKE_TASKS = [
215
247
  'about',
216
248
  'assets:clean',
217
249
  'assets:clobber',
@@ -264,110 +296,106 @@ module NewRelic
264
296
  ].join(',').freeze
265
297
 
266
298
  DEFAULTS = {
267
- :license_key => {
268
- :default => '',
269
- :public => true,
270
- :type => String,
271
- :allowed_from_server => false,
272
- :description => 'Your New Relic <a href="https://docs.newrelic.com/docs/accounts-partnerships/accounts/account-setup/license-key">license key</a>.'
273
- },
299
+ # Critical
274
300
  :agent_enabled => {
275
301
  :default => DefaultSource.agent_enabled,
302
+ :documentation_default => true,
276
303
  :public => true,
277
304
  :type => Boolean,
278
305
  :allowed_from_server => false,
279
- :description => 'If <code>true</code>, allows the Ruby agent to run.'
280
- },
281
- :enabled => {
282
- :default => true,
283
- :public => false,
284
- :type => Boolean,
285
- :aliases => [:enable],
286
- :allowed_from_server => false,
287
- :description => 'Enable or disable the agent.'
306
+ :description => 'If `true`, allows the Ruby agent to run.'
288
307
  },
289
308
  :app_name => {
290
309
  :default => DefaultSource.app_name,
291
310
  :public => true,
292
311
  :type => String,
293
312
  :allowed_from_server => false,
294
- :description => 'Specify the <a href="https://docs.newrelic.com/docs/apm/new-relic-apm/installation-configuration/name-your-application">application name</a> used to aggregate data in the New Relic UI. To report data to <a href="https://docs.newrelic.com/docs/apm/new-relic-apm/installation-configuration/using-multiple-names-app">multiple apps at the same time</a>, specify a list of names separated by a semicolon <code>;</code>. For example, <code>MyApp</code> or <code>MyStagingApp;Instance1</code>.'
313
+ :transform => DefaultSource.method(:convert_to_list_on_semicolon),
314
+ :description => 'Specify the [application name](/docs/apm/new-relic-apm/installation-configuration/name-your-application) used to aggregate data in the New Relic UI. To report data to [multiple apps at the same time](/docs/apm/new-relic-apm/installation-configuration/using-multiple-names-app), specify a list of names separated by a semicolon `;`. For example, `MyApp` or `MyStagingApp;Instance1`.'
295
315
  },
296
- :monitor_mode => {
297
- :default => value_of(:enabled),
316
+ :license_key => {
317
+ :default => '',
298
318
  :public => true,
299
- :type => Boolean,
300
- :allowed_from_server => false,
301
- :description => 'When <code>true</code>, the agent transmits data about your app to the New Relic <a href="https://docs.newrelic.com/docs/apm/new-relic-apm/getting-started/glossary#collector">collector</a>.'
302
- },
303
- :test_mode => {
304
- :default => false,
305
- :public => false,
306
- :type => Boolean,
319
+ :type => String,
307
320
  :allowed_from_server => false,
308
- :description => 'Used in tests for agent to start up but not connect to collector. Formerly used <code>developer_mode</code> in test config for this purpose.'
321
+ :description => 'Your New Relic <LicenseKey />.'
309
322
  },
310
323
  :log_level => {
311
324
  :default => 'info',
312
325
  :public => true,
313
326
  :type => String,
314
327
  :allowed_from_server => false,
315
- :description => 'Sets the level of detail of log messages. Possible log levels, in increasing verbosity, are: <code>error</code>, <code>warn</code>, <code>info</code> or <code>debug</code>.'
328
+ :description => 'Sets the level of detail of log messages. Possible log levels, in increasing verbosity, are: `error`, `warn`, `info` or `debug`.'
316
329
  },
317
- :high_security => {
318
- :default => false,
330
+ # General
331
+ :active_support_custom_events_names => {
332
+ :default => [],
319
333
  :public => true,
320
- :type => Boolean,
334
+ :type => Array,
321
335
  :allowed_from_server => false,
322
- :description => 'If <code>true</code>, enables <a href="https://docs.newrelic.com/docs/accounts-partnerships/accounts/security/high-security">high security mode</a>. Ensure you understand the implications of high security mode before enabling this setting.'
336
+ :description => <<~DESCRIPTION
337
+ An array of ActiveSupport custom event names to subscribe to and instrument. For example,
338
+ - one.custom.event
339
+ - another.event
340
+ - a.third.event
341
+ DESCRIPTION
323
342
  },
324
- :security_policies_token => {
325
- :default => '',
326
- :public => true,
327
- :type => String,
328
- :allowed_from_server => false,
329
- :description => 'Applies Language Agent Security Policy settings.'
343
+ # this is only set via server side config
344
+ :apdex_t => {
345
+ :default => 0.5,
346
+ :public => false,
347
+ :type => Float,
348
+ :allowed_from_server => true,
349
+ :description => 'For agent versions 3.5.0 or higher, [set your Apdex T via the New Relic UI](/docs/apm/new-relic-apm/apdex/changing-your-apdex-settings).'
330
350
  },
331
- :proxy_host => {
332
- :default => nil,
333
- :allow_nil => true,
351
+ :api_key => {
352
+ :default => '',
334
353
  :public => true,
335
354
  :type => String,
336
355
  :allowed_from_server => false,
337
- :description => 'Defines a host for communicating with the New Relic <a href="https://docs.newrelic.com/docs/apm/new-relic-apm/getting-started/glossary#collector">collector</a> via a proxy server.'
356
+ :description => 'Your New Relic [user key](/docs/apis/intro-apis/new-relic-api-keys/#overview-keys). Required when using the New Relic REST API v2 to record deployments using the `newrelic deployments` command.'
338
357
  },
339
- :proxy_port => {
340
- :default => 8080,
341
- :allow_nil => true,
358
+ :backport_fast_active_record_connection_lookup => {
359
+ :default => false,
342
360
  :public => true,
343
- :type => Integer,
361
+ :type => Boolean,
344
362
  :allowed_from_server => false,
345
- :description => 'Defines a port for communicating with the New Relic <a href="https://docs.newrelic.com/docs/apm/new-relic-apm/getting-started/glossary#collector">collector</a> via a proxy server.'
363
+ :description => 'Backports the faster ActiveRecord connection lookup introduced in Rails 6, which improves agent performance when instrumenting ActiveRecord. Note that this setting may not be compatible with other gems that patch ActiveRecord.'
346
364
  },
347
- :proxy_user => {
365
+ :ca_bundle_path => {
348
366
  :default => nil,
349
367
  :allow_nil => true,
350
368
  :public => true,
351
369
  :type => String,
352
370
  :allowed_from_server => false,
353
- :exclude_from_reported_settings => true,
354
- :description => 'Defines a user for communicating with the New Relic <a href="https://docs.newrelic.com/docs/apm/new-relic-apm/getting-started/glossary#collector">collector</a> via a proxy server.'
371
+ :description => "Manual override for the path to your local CA bundle. This CA bundle will be used to validate the SSL certificate presented by New Relic's data collection service."
355
372
  },
356
- :proxy_pass => {
357
- :default => nil,
358
- :allow_nil => true,
373
+ :capture_memcache_keys => {
374
+ :default => false,
359
375
  :public => true,
360
- :type => String,
361
- :allowed_from_server => false,
362
- :exclude_from_reported_settings => true,
363
- :description => 'Defines a password for communicating with the New Relic <a href="https://docs.newrelic.com/docs/apm/new-relic-apm/getting-started/glossary#collector">collector</a> via a proxy server.'
376
+ :type => Boolean,
377
+ :allowed_from_server => true,
378
+ :description => 'Enable or disable the capture of memcache keys from transaction traces.'
364
379
  },
365
380
  :capture_params => {
366
381
  :default => false,
367
382
  :public => true,
368
383
  :type => Boolean,
369
384
  :allowed_from_server => false,
370
- :description => 'When <code>true</code>, the agent captures HTTP request parameters and attaches them to transaction traces, traced errors, and <a href="https://docs.newrelic.com/docs/insights/new-relic-insights/decorating-events/error-event-default-attributes-insights">TransactionError events</a>.'
385
+ :description => <<~DESCRIPTION
386
+ When `true`, the agent captures HTTP request parameters and attaches them to transaction traces, traced errors, and [`TransactionError` events](/attribute-dictionary?attribute_name=&events_tids%5B%5D=8241).
387
+
388
+ <Callout variant="caution">
389
+ When using the `capture_params` setting, the Ruby agent will not attempt to filter secret information. <b>Recommendation:</b> To filter secret information from request parameters, use the [`attributes.include` setting](/docs/agents/ruby-agent/attributes/enable-disable-attributes-ruby) instead. For more information, see the <a href="/docs/agents/ruby-agent/attributes/ruby-attribute-examples#ex_req_params">Ruby attribute examples</a>.
390
+ </Callout>
391
+ DESCRIPTION
392
+ },
393
+ :'clear_transaction_state_after_fork' => {
394
+ :default => false,
395
+ :public => true,
396
+ :type => Boolean,
397
+ :allowed_from_server => false,
398
+ :description => 'If `true`, the agent will clear `Tracer::State` in `Agent.drop_buffered_data`.'
371
399
  },
372
400
  :config_path => {
373
401
  :default => DefaultSource.config_path,
@@ -376,1422 +404,1656 @@ module NewRelic
376
404
  :allowed_from_server => false,
377
405
  :description => 'Path to <b>newrelic.yml</b>. If undefined, the agent checks the following directories (in order): <b>config/newrelic.yml</b>, <b>newrelic.yml</b>, <b>$HOME/.newrelic/newrelic.yml</b> and <b>$HOME/newrelic.yml</b>.'
378
406
  },
379
- :config_search_paths => {
380
- :default => DefaultSource.config_search_paths,
381
- :public => false,
382
- :type => Array,
407
+ :'exclude_newrelic_header' => {
408
+ :default => false,
409
+ :public => true,
410
+ :type => Boolean,
411
+ :allowed_from_server => true,
412
+ :description => 'Allows newrelic distributed tracing headers to be suppressed on outbound requests.'
413
+ },
414
+ :force_install_exit_handler => {
415
+ :default => false,
416
+ :public => true,
417
+ :type => Boolean,
383
418
  :allowed_from_server => false,
384
- :description => "An array of candidate locations for the agent\'s configuration file."
419
+ :description => 'Forces the exit handler that sends all cached data to collector ' \
420
+ 'before shutting down to be installed regardless of detecting scenarios where it generally should not be. ' \
421
+ 'Known use-case for this option is where Sinatra is running as an embedded service within another framework ' \
422
+ 'and the agent is detecting the Sinatra app and skipping the `at_exit` handler as a result. Sinatra classically ' \
423
+ 'runs the entire application in an `at_exit` block and would otherwise misbehave if the Agent\'s `at_exit` handler ' \
424
+ 'was also installed in those circumstances. Note: `send_data_on_exit` should also be set to `true` in tandem with this setting.'
385
425
  },
386
- :dispatcher => {
387
- :default => DefaultSource.dispatcher,
388
- :public => false,
389
- :type => Symbol,
426
+ :high_security => {
427
+ :default => false,
428
+ :public => true,
429
+ :type => Boolean,
390
430
  :allowed_from_server => false,
391
- :description => 'Autodetected application component that reports metrics to New Relic.'
431
+ :description => 'If `true`, enables [high security mode](/docs/accounts-partnerships/accounts/security/high-security). Ensure you understand the implications of high security mode before enabling this setting.'
392
432
  },
393
- :framework => {
394
- :default => DefaultSource.framework,
395
- :public => false,
396
- :type => Symbol,
433
+ :labels => {
434
+ :default => '',
435
+ :public => true,
436
+ :type => String,
397
437
  :allowed_from_server => false,
398
- :description => 'Autodetected application framework used to enable framework-specific functionality.'
438
+ :description => 'A dictionary of [label names](/docs/data-analysis/user-interface-functions/labels-categories-organize-your-apps-servers) and values that will be applied to the data sent from this agent. May also be expressed as a semicolon-delimited `;` string of colon-separated `:` pairs. For example, `Server:One;Data Center:Primary`.'
399
439
  },
400
- :'autostart.blacklisted_constants' => {
401
- :default => 'Rails::Console',
440
+ :log_file_name => {
441
+ :default => 'newrelic_agent.log',
402
442
  :public => true,
403
443
  :type => String,
404
444
  :allowed_from_server => false,
405
- :description => 'Specify a list of constants that should prevent the agent from starting automatically. Separate individual constants with a comma <code>,</code>. For example, <code>Rails::Console,UninstrumentedBackgroundJob</code>.'
445
+ :description => 'Defines a name for the log file.'
406
446
  },
407
- :'autostart.blacklisted_executables' => {
408
- :default => 'irb,rspec',
447
+ :log_file_path => {
448
+ :default => DefaultSource::DEFAULT_LOG_DIR,
409
449
  :public => true,
410
450
  :type => String,
411
451
  :allowed_from_server => false,
412
- :description => 'Defines a comma-delimited list of executables that the agent should not instrument. For example, <code>rake,my_ruby_script.rb</code>.'
452
+ :description => 'Defines a path to the agent log file, excluding the filename.'
413
453
  },
414
- :'autostart.blacklisted_rake_tasks' => {
415
- :default => AUTOSTART_BLACKLISTED_RAKE_TASKS,
454
+ :marshaller => {
455
+ :default => 'json',
416
456
  :public => true,
417
457
  :type => String,
418
458
  :allowed_from_server => false,
419
- :description => 'Defines a comma-delimited list of Rake tasks that the agent should not instrument. For example, <code>assets:precompile,db:migrate</code>.'
459
+ :description => 'Specifies a marshaller for transmitting data to the New Relic [collector](/docs/apm/new-relic-apm/getting-started/glossary#collector). Currently `json` is the only valid value for this setting.'
420
460
  },
421
- :disable_rake => {
422
- :default => false,
461
+ :monitor_mode => {
462
+ :default => value_of(:enabled),
463
+ :documentation_default => true,
423
464
  :public => true,
424
465
  :type => Boolean,
425
466
  :allowed_from_server => false,
426
- :description => 'If <code>true</code>, disables Rake instrumentation.'
467
+ :description => 'When `true`, the agent transmits data about your app to the New Relic [collector](/docs/using-new-relic/welcome-new-relic/get-started/glossary/#collector).'
427
468
  },
428
- :disable_rake_instrumentation => {
469
+ :prepend_active_record_instrumentation => {
429
470
  :default => false,
430
- :public => false,
471
+ :public => true,
431
472
  :type => Boolean,
432
473
  :allowed_from_server => false,
433
- :description => 'Enable or disable Rake instrumentation. Preferred key is `disable_rake`'
474
+ :description => 'If `true`, uses `Module#prepend` rather than `alias_method` for ActiveRecord instrumentation.'
434
475
  },
435
- :'rake.tasks' => {
436
- :default => [],
476
+ :proxy_host => {
477
+ :default => nil,
478
+ :allow_nil => true,
437
479
  :public => true,
438
- :type => Array,
480
+ :type => String,
439
481
  :allowed_from_server => false,
440
- :transform => DefaultSource.method(:convert_to_regexp_list),
441
- :description => 'Specify an array of Rake tasks to automatically instrument.'
482
+ :description => 'Defines a host for communicating with the New Relic [collector](/docs/using-new-relic/welcome-new-relic/get-started/glossary/#collector) via a proxy server.'
442
483
  },
443
- :'rake.connect_timeout' => {
444
- :default => 10,
484
+ :proxy_pass => {
485
+ :default => nil,
486
+ :allow_nil => true,
445
487
  :public => true,
446
- :type => Integer,
488
+ :type => String,
447
489
  :allowed_from_server => false,
448
- :description => 'Timeout for waiting on connect to complete before a rake task'
449
- },
450
- :apdex_t => {
451
- :default => 0.5,
452
- :public => true,
453
- :type => Float,
454
- :allowed_from_server => true,
455
- :deprecated => true,
456
- :description => 'Deprecated. For agent versions 3.5.0 or higher, <a href="https://docs.newrelic.com/docs/apm/new-relic-apm/apdex/changing-your-apdex-settings">set your Apdex T via the New Relic UI</a>.'
490
+ :exclude_from_reported_settings => true,
491
+ :description => 'Defines a password for communicating with the New Relic [collector](/docs/using-new-relic/welcome-new-relic/get-started/glossary/#collector) via a proxy server.'
457
492
  },
458
- :'strip_exception_messages.enabled' => {
459
- :default => value_of(:high_security),
493
+ :proxy_port => {
494
+ :default => 8080,
495
+ :allow_nil => true,
460
496
  :public => true,
461
- :type => Boolean,
497
+ :type => Integer,
462
498
  :allowed_from_server => false,
463
- :description => 'If true, the agent strips messages from all exceptions except those in the <a href="#strip_exception_messages-whitelist">whitelist</a>. Enabled automatically in <a href="https://docs.newrelic.com/docs/accounts-partnerships/accounts/security/high-security">high security mode</a>.'
499
+ :description => 'Defines a port for communicating with the New Relic [collector](/docs/using-new-relic/welcome-new-relic/get-started/glossary/#collector) via a proxy server.'
464
500
  },
465
- :'strip_exception_messages.whitelist' => {
466
- :default => '',
501
+ :proxy_user => {
502
+ :default => nil,
503
+ :allow_nil => true,
467
504
  :public => true,
468
505
  :type => String,
469
506
  :allowed_from_server => false,
470
- :transform => DefaultSource.method(:convert_to_constant_list),
471
- :description => 'Specify a whitelist of exceptions you do not want the agent to strip when <a href="#strip_exception_messages-enabled">strip_exception_messages</a> is <code>true</code>. Separate exceptions with a comma. For example, <code>"ImportantException,PreserveMessageException"</code>.'
507
+ :exclude_from_reported_settings => true,
508
+ :description => 'Defines a user for communicating with the New Relic [collector](/docs/using-new-relic/welcome-new-relic/get-started/glossary/#collector) via a proxy server.'
472
509
  },
473
- :host => {
474
- :default => DefaultSource.host,
475
- :public => false,
510
+ :security_policies_token => {
511
+ :default => '',
512
+ :public => true,
476
513
  :type => String,
477
514
  :allowed_from_server => false,
478
- :description => "URI for the New Relic data collection service."
515
+ :description => 'Applies Language Agent Security Policy settings.'
479
516
  },
480
- :api_host => {
481
- :default => DefaultSource.api_host,
482
- :public => false,
483
- :type => String,
517
+ :send_data_on_exit => {
518
+ :default => true,
519
+ :public => true,
520
+ :type => Boolean,
484
521
  :allowed_from_server => false,
485
- :description => 'API host for New Relic.'
522
+ :description => 'If `true`, enables the exit handler that sends data to the New Relic [collector](/docs/using-new-relic/welcome-new-relic/get-started/glossary/#collector) before shutting down.'
486
523
  },
487
- :port => {
488
- :default => 443,
489
- :public => false,
490
- :type => Integer,
524
+ :sync_startup => {
525
+ :default => false,
526
+ :public => true,
527
+ :type => Boolean,
491
528
  :allowed_from_server => false,
492
- :description => 'Port for the New Relic data collection service.'
529
+ :description => 'When set to `true`, forces a synchronous connection to the New Relic [collector](/docs/using-new-relic/welcome-new-relic/get-started/glossary/#collector) during application startup. For very short-lived processes, this helps ensure the New Relic agent has time to report.'
493
530
  },
494
- :api_port => {
495
- :default => value_of(:port),
496
- :public => false,
531
+ :timeout => {
532
+ :default => 2 * 60, # 2 minutes
533
+ :public => true,
497
534
  :type => Integer,
498
535
  :allowed_from_server => false,
499
- :description => 'Port for the New Relic API host.'
536
+ :description => 'Defines the maximum number of seconds the agent should spend attempting to connect to the collector.'
500
537
  },
501
- :sync_startup => {
502
- :default => false,
538
+ # Transaction tracer
539
+ :'transaction_tracer.enabled' => {
540
+ :default => true,
503
541
  :public => true,
504
542
  :type => Boolean,
505
- :allowed_from_server => false,
506
- :description => 'When set to <code>true</code>, forces a synchronous connection to the New Relic <a href="https://docs.newrelic.com/docs/apm/new-relic-apm/getting-started/glossary#collector">collector</a> during application startup. For very short-lived processes, this helps ensure the New Relic agent has time to report.'
543
+ :allowed_from_server => true,
544
+ :description => 'If `true`, enables collection of [transaction traces](/docs/apm/traces/transaction-traces/transaction-traces).'
507
545
  },
508
- :send_data_on_exit => {
546
+ :'transaction_tracer.explain_enabled' => {
509
547
  :default => true,
510
548
  :public => true,
511
549
  :type => Boolean,
512
- :allowed_from_server => false,
513
- :description => 'If <code>true</code>, enables the exit handler that sends data to the New Relic <a href="https://docs.newrelic.com/docs/apm/new-relic-apm/getting-started/glossary#collector">collector</a> before shutting down.'
550
+ :allowed_from_server => true,
551
+ :description => 'If `true`, enables the collection of explain plans in transaction traces. This setting will also apply to explain plans in slow SQL traces if [`slow_sql.explain_enabled`](#slow_sql-explain_enabled) is not set separately.'
514
552
  },
515
- :max_payload_size_in_bytes => {
516
- :default => 1000000,
517
- :public => false,
553
+ :'transaction_tracer.explain_threshold' => {
554
+ :default => 0.5,
555
+ :public => true,
556
+ :type => Float,
557
+ :allowed_from_server => true,
558
+ :description => 'Threshold (in seconds) above which the agent will collect explain plans. Relevant only when [`explain_enabled`](#transaction_tracer.explain_enabled) is true.'
559
+ },
560
+ :'transaction_tracer.limit_segments' => {
561
+ :default => 4000,
562
+ :public => true,
518
563
  :type => Integer,
519
564
  :allowed_from_server => true,
520
- :description => 'Maximum number of bytes to send to the New Relic data collection service.'
565
+ :description => 'Maximum number of transaction trace nodes to record in a single transaction trace.'
521
566
  },
522
- :put_for_data_send => {
567
+ :'transaction_tracer.record_redis_arguments' => {
523
568
  :default => false,
524
- :public => false,
569
+ :public => true,
525
570
  :type => Boolean,
526
571
  :allowed_from_server => false,
527
- :description => 'Use HTTP PUT requests instead of POST.'
572
+ :description => 'If `true`, the agent records Redis command arguments in transaction traces.'
528
573
  },
529
- :compressed_content_encoding => {
530
- :default => 'deflate',
531
- :public => false,
574
+ :'transaction_tracer.record_sql' => {
575
+ :default => 'obfuscated',
576
+ :public => true,
532
577
  :type => String,
533
- :allowed_from_server => false,
534
- :description => 'Encoding to use if data needs to be compressed. The options are deflate and gzip.'
578
+ :allowed_from_server => true,
579
+ :description => 'Obfuscation level for SQL queries reported in transaction trace nodes.
580
+
581
+ By default, this is set to `obfuscated`, which strips out the numeric and string literals.
582
+
583
+ - If you do not want the agent to capture query information, set this to `none`.
584
+ - If you want the agent to capture all query information in its original form, set this to `raw`.
585
+ - When you enable [high security mode](/docs/agents/manage-apm-agents/configuration/high-security-mode), this is automatically set to `obfuscated`.
586
+ '
535
587
  },
536
- :simple_compression => {
537
- :default => false,
538
- :public => false,
539
- :type => Boolean,
540
- :allowed_from_server => false,
541
- :description => 'When enabled the agent will compress payloads destined for the collector, but will not pre-compress parts of the payload.'
588
+
589
+ :'transaction_tracer.stack_trace_threshold' => {
590
+ :default => 0.5,
591
+ :public => true,
592
+ :type => Float,
593
+ :allowed_from_server => true,
594
+ :description => 'Specify a threshold in seconds. The agent includes stack traces in transaction trace nodes when the stack trace duration exceeds this threshold.'
542
595
  },
543
- :timeout => {
544
- :default => 2 * 60, # 2 minutes
596
+ :'transaction_tracer.transaction_threshold' => {
597
+ :default => DefaultSource.transaction_tracer_transaction_threshold,
545
598
  :public => true,
546
- :type => Integer,
547
- :allowed_from_server => false,
548
- :description => 'Defines the maximum number of seconds the agent should spend attempting to connect to the collector.'
599
+ :type => Float,
600
+ :allowed_from_server => true,
601
+ :description => 'Specify a threshold in seconds. Transactions with a duration longer than this threshold are eligible for transaction traces. Specify a float value or the string `apdex_f`.'
549
602
  },
550
- :send_environment_info => {
603
+ # Error collector
604
+ :'error_collector.ignore_classes' => {
605
+ :default => ['ActionController::RoutingError', 'Sinatra::NotFound'],
606
+ :public => true,
607
+ :type => Array,
608
+ :allowed_from_server => true,
609
+ :dynamic_name => true,
610
+ :description => <<~DESCRIPTION
611
+ A list of error classes that the agent should ignore.
612
+
613
+ <Callout variant="caution">
614
+ This option can't be set via environment variable.
615
+ </Callout>
616
+ DESCRIPTION
617
+ },
618
+ :'error_collector.capture_events' => {
619
+ :default => value_of(:'error_collector.enabled'),
620
+ :documentation_default => true,
621
+ :public => true,
622
+ :type => Boolean,
623
+ :allowed_from_server => true,
624
+ :dynamic_name => true,
625
+ :description => 'If `true`, the agent collects [TransactionError events](/docs/insights/new-relic-insights/decorating-events/error-event-default-attributes-insights).'
626
+ },
627
+ :'error_collector.enabled' => {
551
628
  :default => true,
552
- :public => false,
629
+ :public => true,
553
630
  :type => Boolean,
554
- :allowed_from_server => false,
555
- :description => 'Enable or disable transmission of application environment information to the New Relic data collection service.'
631
+ :allowed_from_server => true,
632
+ :description => 'If `true`, the agent captures traced errors and error count metrics.'
556
633
  },
557
- :data_report_period => {
558
- :default => 60,
559
- :public => false,
560
- :type => Integer,
634
+ :'error_collector.expected_classes' => {
635
+ :default => [],
636
+ :public => true,
637
+ :type => Array,
561
638
  :allowed_from_server => true,
562
- :description => 'Number of seconds betwixt connections to the New Relic data collection service.'
639
+ :dynamic_name => true,
640
+ :description => <<~DESCRIPTION
641
+ A list of error classes that the agent should treat as expected.
642
+
643
+ <Callout variant="caution">
644
+ This option can't be set via environment variable.
645
+ </Callout>
646
+ DESCRIPTION
563
647
  },
564
- :event_report_period => {
565
- :default => 60,
566
- :public => false,
567
- :type => Integer,
648
+ :'error_collector.expected_messages' => {
649
+ :default => {},
650
+ :public => true,
651
+ :type => Hash,
568
652
  :allowed_from_server => true,
569
- :description => 'Number of seconds betwixt connections to the New Relic event collection services.'
653
+ :dynamic_name => true,
654
+ :description => <<~DESCRIPTION
655
+ A map of error classes to a list of messages. When an error of one of the classes specified here occurs, if its error message contains one of the strings corresponding to it here, that error will be treated as expected.
656
+
657
+ <Callout variant="caution">
658
+ This option can't be set via environment variable.
659
+ </Callout>
660
+ DESCRIPTION
570
661
  },
571
- :'data_report_periods.analytic_event_data' => {
572
- :default => 60,
573
- :public => false,
574
- :type => Integer,
575
- :deprecated => true,
662
+ :'error_collector.expected_status_codes' => {
663
+ :default => '',
664
+ :public => true,
665
+ :type => String,
666
+ :allowed_from_server => true,
667
+ :dynamic_name => true,
668
+ :description => 'A comma separated list of status codes, possibly including ranges. Errors associated with these status codes, where applicable, will be treated as expected.'
669
+ },
670
+
671
+ :'error_collector.ignore_messages' => {
672
+ :default => {},
673
+ :public => true,
674
+ :type => Hash,
675
+ :allowed_from_server => true,
576
676
  :dynamic_name => true,
677
+ :description => <<~DESCRIPTION
678
+ A map of error classes to a list of messages. When an error of one of the classes specified here occurs, if its error message contains one of the strings corresponding to it here, that error will be ignored.
679
+
680
+ <Callout variant="caution">
681
+ This option can't be set via environment variable.
682
+ </Callout>
683
+ DESCRIPTION
684
+ },
685
+ :'error_collector.ignore_status_codes' => {
686
+ :default => '',
687
+ :public => true,
688
+ :type => String,
577
689
  :allowed_from_server => true,
578
- :description => 'Number of seconds between connections to the New Relic data collection service for sending transaction event data.'
690
+ :dynamic_name => true,
691
+ :description => 'A comma separated list of status codes, possibly including ranges. Errors associated with these status codes, where applicable, will be ignored.'
579
692
  },
580
- :keep_retrying => {
581
- :default => true,
582
- :public => false,
583
- :type => Boolean,
584
- :deprecated => true,
693
+ :'error_collector.max_backtrace_frames' => {
694
+ :default => 50,
695
+ :public => true,
696
+ :type => Integer,
585
697
  :allowed_from_server => false,
586
- :description => 'Enable or disable retrying failed connections to the New Relic data collection service.'
698
+ :description => 'Defines the maximum number of frames in an error backtrace. Backtraces over this amount are truncated at the beginning and end.'
587
699
  },
588
- :force_reconnect => {
589
- :default => false,
590
- :public => false,
700
+ :'error_collector.max_event_samples_stored' => {
701
+ :default => 100,
702
+ :public => true,
703
+ :type => Integer,
704
+ :allowed_from_server => true,
705
+ :description => 'Defines the maximum number of [TransactionError events](/docs/insights/new-relic-insights/decorating-events/error-event-default-attributes-insights) reported per harvest cycle.'
706
+ },
707
+ # Browser monitoring
708
+ :'browser_monitoring.auto_instrument' => {
709
+ :default => value_of(:'rum.enabled'),
710
+ :documentation_default => true,
711
+ :public => true,
591
712
  :type => Boolean,
592
- :allowed_from_server => false,
593
- :description => 'Force a new connection to the server before running the worker loop. Creates a separate agent run and is recorded as a separate instance by the New Relic data collection service.'
713
+ :allowed_from_server => true,
714
+ :description => 'If `true`, enables [auto-injection](/docs/browser/new-relic-browser/installation-configuration/adding-apps-new-relic-browser#select-apm-app) of the JavaScript header for page load timing (sometimes referred to as real user monitoring or RUM).'
594
715
  },
595
- :report_instance_busy => {
716
+ # Transaction events
717
+ :'transaction_events.enabled' => {
596
718
  :default => true,
597
- :public => false,
719
+ :public => true,
598
720
  :type => Boolean,
599
- :allowed_from_server => false,
600
- :description => 'Enable or disable transmission of metrics recording the percentage of time application instances spend servicing requests (duty cycle metrics).'
721
+ :allowed_from_server => true,
722
+ :description => 'If `true`, enables transaction event sampling.'
601
723
  },
602
- :log_file_name => {
603
- :default => 'newrelic_agent.log',
724
+ :'transaction_events.max_samples_stored' => {
725
+ :default => 1200,
604
726
  :public => true,
605
- :type => String,
606
- :allowed_from_server => false,
607
- :description => 'Defines a name for the log file.'
727
+ :type => Integer,
728
+ :allowed_from_server => true,
729
+ :description => 'Defines the maximum number of transaction events reported from a single harvest.'
608
730
  },
609
- :log_file_path => {
610
- :default => DefaultSource::DEFAULT_LOG_DIR,
731
+ # Application logging
732
+ :'application_logging.enabled' => {
733
+ :default => true,
611
734
  :public => true,
612
- :type => String,
735
+ :type => Boolean,
613
736
  :allowed_from_server => false,
614
- :description => 'Defines a path to the agent log file, excluding the filename.'
737
+ :description => 'If `true`, enables log decoration and the collection of log events and metrics.'
615
738
  },
616
- :'audit_log.enabled' => {
617
- :default => false,
739
+ :'application_logging.forwarding.enabled' => {
740
+ :default => true,
618
741
  :public => true,
619
742
  :type => Boolean,
620
743
  :allowed_from_server => false,
621
- :description => 'If <code>true</code>, enables an audit log which logs communications with the New Relic <a href="https://docs.newrelic.com/docs/apm/new-relic-apm/getting-started/glossary#collector">collector</a>.'
744
+ :description => 'If `true`, the agent captures log records emitted by your application.'
622
745
  },
623
- :'audit_log.path' => {
624
- :default => DefaultSource.audit_log_path,
746
+ :'application_logging.forwarding.max_samples_stored' => {
747
+ :default => 10000,
625
748
  :public => true,
626
- :type => String,
627
- :allowed_from_server => false,
628
- :description => 'Specifies a path to the audit log file (including the filename).'
749
+ :type => Integer,
750
+ :allowed_from_server => true,
751
+ :description => 'Defines the maximum number of log records to buffer in memory at a time.',
752
+ :dynamic_name => true
629
753
  },
630
- :'audit_log.endpoints' => {
631
- :default => [".*"],
754
+ :'application_logging.local_decorating.enabled' => {
755
+ :default => false,
632
756
  :public => true,
633
- :type => Array,
757
+ :type => Boolean,
634
758
  :allowed_from_server => false,
635
- :transform => DefaultSource.method(:convert_to_regexp_list),
636
- :description => 'List of allowed endpoints to include in audit log'
759
+ :description => 'If `true`, the agent decorates logs with metadata to link to entities, hosts, traces, and spans.'
637
760
  },
638
- :disable_samplers => {
639
- :default => false,
761
+ :'application_logging.metrics.enabled' => {
762
+ :default => true,
640
763
  :public => true,
641
764
  :type => Boolean,
642
- :allowed_from_server => false,
643
- :description => 'If <code>true</code>, disables the collection of sampler metrics. Sampler metrics are metrics that are not event-based (such as CPU time or memory usage).'
765
+ :allowed_from_server => true,
766
+ :description => 'If `true`, the agent captures metrics related to logging for your application.'
644
767
  },
645
- :disable_resque => {
646
- :default => false,
768
+ # Attributes
769
+ :'attributes.enabled' => {
770
+ :default => true,
647
771
  :public => true,
648
772
  :type => Boolean,
649
773
  :allowed_from_server => false,
650
- :description => 'If <code>true</code>, disables <a href="https://docs.newrelic.com/docs/agents/ruby-agent/background-jobs/resque-instrumentation">Resque instrumentation</a>.'
774
+ :description => 'If `true`, enables capture of attributes for all destinations.'
651
775
  },
652
- :disable_sidekiq => {
653
- :default => false,
776
+ :'attributes.exclude' => {
777
+ :default => [],
654
778
  :public => true,
655
- :type => Boolean,
779
+ :type => Array,
656
780
  :allowed_from_server => false,
657
- :description => 'If <code>true</code>, disables <a href="https://docs.newrelic.com/docs/agents/ruby-agent/background-jobs/sidekiq-instrumentation">Sidekiq instrumentation</a>.'
781
+ :transform => DefaultSource.method(:convert_to_list),
782
+ :description => 'Prefix of attributes to exclude from all destinations. Allows `*` as wildcard at end.'
658
783
  },
659
- :disable_dj => {
660
- :default => false,
784
+ :'attributes.include' => {
785
+ :default => [],
661
786
  :public => true,
662
- :type => Boolean,
787
+ :type => Array,
663
788
  :allowed_from_server => false,
664
- :description => 'If <code>true</code>, disables <a href="https://docs.newrelic.com/docs/agents/ruby-agent/background-jobs/delayedjob">Delayed::Job instrumentation</a>.'
789
+ :transform => DefaultSource.method(:convert_to_list),
790
+ :description => 'Prefix of attributes to include in all destinations. Allows `*` as wildcard at end.'
665
791
  },
666
- :disable_sinatra => {
792
+ :'browser_monitoring.attributes.enabled' => {
667
793
  :default => false,
668
794
  :public => true,
669
795
  :type => Boolean,
670
796
  :allowed_from_server => false,
671
- :description => 'If <code>true</code> , disables <a href="https://docs.newrelic.com/docs/agents/ruby-agent/frameworks/sinatra-support">Sinatra instrumentation</a>.'
797
+ :description => 'If `true`, the agent captures attributes from browser monitoring.'
672
798
  },
673
- :disable_sinatra_auto_middleware => {
674
- :default => false,
799
+ :'browser_monitoring.attributes.exclude' => {
800
+ :default => [],
675
801
  :public => true,
676
- :type => Boolean,
802
+ :type => Array,
677
803
  :allowed_from_server => false,
678
- :description => 'If <code>true</code>, disables agent middleware for Sinatra. This middleware is responsible for advanced feature support such as <a href="https://docs.newrelic.com/docs/apm/transactions/cross-application-traces/cross-application-tracing">cross application tracing</a>, <a href="https://docs.newrelic.com/docs/browser/new-relic-browser/getting-started/new-relic-browser">page load timing</a>, and <a href="https://docs.newrelic.com/docs/apm/applications-menu/events/view-apm-error-analytics">error collection</a>.'
804
+ :transform => DefaultSource.method(:convert_to_list),
805
+ :description => 'Prefix of attributes to exclude from browser monitoring. Allows `*` as wildcard at end.'
679
806
  },
680
- :disable_view_instrumentation => {
681
- :default => false,
807
+ :'browser_monitoring.attributes.include' => {
808
+ :default => [],
682
809
  :public => true,
683
- :type => Boolean,
810
+ :type => Array,
684
811
  :allowed_from_server => false,
685
- :description => 'If <code>true</code>, disables view instrumentation.'
812
+ :transform => DefaultSource.method(:convert_to_list),
813
+ :description => 'Prefix of attributes to include in browser monitoring. Allows `*` as wildcard at end.'
686
814
  },
687
- :disable_harvest_thread => {
688
- :default => false,
689
- :public => false,
815
+ :'error_collector.attributes.enabled' => {
816
+ :default => true,
817
+ :public => true,
690
818
  :type => Boolean,
691
819
  :allowed_from_server => false,
692
- :description => 'Enable or disable the harvest thread.'
820
+ :description => 'If `true`, the agent captures attributes from error collection.'
693
821
  },
694
- :skip_ar_instrumentation => {
695
- :default => false,
696
- :public => false,
697
- :type => Boolean,
822
+ :'error_collector.attributes.exclude' => {
823
+ :default => [],
824
+ :public => true,
825
+ :type => Array,
698
826
  :allowed_from_server => false,
699
- :description => 'Enable or disable active record instrumentation.'
827
+ :transform => DefaultSource.method(:convert_to_list),
828
+ :description => 'Prefix of attributes to exclude from error collection. Allows `*` as wildcard at end.'
700
829
  },
701
- :disable_activerecord_instrumentation => {
702
- :default => value_of(:skip_ar_instrumentation),
830
+ :'error_collector.attributes.include' => {
831
+ :default => [],
703
832
  :public => true,
704
- :type => Boolean,
833
+ :type => Array,
705
834
  :allowed_from_server => false,
706
- :description => 'If <code>true</code>, disables active record instrumentation.'
835
+ :transform => DefaultSource.method(:convert_to_list),
836
+ :description => 'Prefix of attributes to include in error collection. Allows `*` as wildcard at end.'
707
837
  },
708
- :prepend_active_record_instrumentation => {
709
- :default => false,
838
+ :'span_events.attributes.enabled' => {
839
+ :default => true,
710
840
  :public => true,
711
841
  :type => Boolean,
712
842
  :allowed_from_server => false,
713
- :description => 'If <code>true</code>, uses Module.prepend rather than alias_method for ActiveRecord instrumentation.'
843
+ :description => 'If `true`, the agent captures attributes on span events.'
714
844
  },
715
- :disable_data_mapper => {
716
- :default => false,
845
+ :'span_events.attributes.exclude' => {
846
+ :default => [],
717
847
  :public => true,
718
- :type => Boolean,
848
+ :type => Array,
719
849
  :allowed_from_server => false,
720
- :description => 'If <code>true</code>, disables DataMapper instrumentation.'
850
+ :transform => DefaultSource.method(:convert_to_list),
851
+ :description => 'Prefix of attributes to exclude from span events. Allows `*` as wildcard at end.'
721
852
  },
722
- :disable_activejob => {
723
- :default => false,
853
+ :'span_events.attributes.include' => {
854
+ :default => [],
724
855
  :public => true,
725
- :type => Boolean,
726
- :dynamic_name => true,
856
+ :type => Array,
727
857
  :allowed_from_server => false,
728
- :description => 'If <code>true</code>, disables ActiveJob instrumentation.'
858
+ :transform => DefaultSource.method(:convert_to_list),
859
+ :description => 'Prefix of attributes to include on span events. Allows `*` as wildcard at end.'
729
860
  },
730
- :disable_action_cable_instrumentation => {
731
- :default => false,
861
+ :'transaction_events.attributes.enabled' => {
862
+ :default => true,
732
863
  :public => true,
733
864
  :type => Boolean,
734
- :dynamic_name => true,
735
865
  :allowed_from_server => false,
736
- :description => 'If <code>true</code>, disables Action Cable instrumentation.'
866
+ :description => 'If `true`, the agent captures attributes from transaction events.'
737
867
  },
738
- :disable_active_storage => {
739
- :default => false,
868
+ :'transaction_events.attributes.exclude' => {
869
+ :default => [],
740
870
  :public => true,
741
- :type => Boolean,
742
- :dynamic_name => true,
871
+ :type => Array,
743
872
  :allowed_from_server => false,
744
- :description => 'If <code>true</code>, disables ActiveStorage instrumentation.'
873
+ :transform => DefaultSource.method(:convert_to_list),
874
+ :description => 'Prefix of attributes to exclude from transaction events. Allows `*` as wildcard at end.'
745
875
  },
746
- :disable_memcached => {
747
- :default => value_of(:disable_memcache_instrumentation),
876
+ :'transaction_events.attributes.include' => {
877
+ :default => [],
748
878
  :public => true,
749
- :type => Boolean,
879
+ :type => Array,
750
880
  :allowed_from_server => false,
751
- :description => 'If <code>true</code>, disables instrumentation for the memcached gem.'
881
+ :transform => DefaultSource.method(:convert_to_list),
882
+ :description => 'Prefix of attributes to include in transaction events. Allows `*` as wildcard at end.'
752
883
  },
753
- :disable_memcache_client => {
754
- :default => value_of(:disable_memcache_instrumentation),
884
+ :'transaction_segments.attributes.enabled' => {
885
+ :default => true,
755
886
  :public => true,
756
887
  :type => Boolean,
757
888
  :allowed_from_server => false,
758
- :description => 'If <code>true</code>, disables instrumentation for the memcache-client gem.'
889
+ :description => 'If `true`, the agent captures attributes on transaction segments.'
759
890
  },
760
- :disable_dalli => {
761
- :default => value_of(:disable_memcache_instrumentation),
891
+ :'transaction_segments.attributes.exclude' => {
892
+ :default => [],
762
893
  :public => true,
763
- :type => Boolean,
894
+ :type => Array,
764
895
  :allowed_from_server => false,
765
- :description => 'If <code>true</code>, disables instrumentation for the dalli gem.'
896
+ :transform => DefaultSource.method(:convert_to_list),
897
+ :description => 'Prefix of attributes to exclude from transaction segments. Allows `*` as wildcard at end.'
766
898
  },
767
- :disable_dalli_cas_client => {
768
- :default => value_of(:disable_memcache_instrumentation),
899
+ :'transaction_segments.attributes.include' => {
900
+ :default => [],
769
901
  :public => true,
770
- :type => Boolean,
902
+ :type => Array,
771
903
  :allowed_from_server => false,
772
- :description => "If <code>true</code>, disables instrumentation for the dalli gem\'s additional CAS client support."
904
+ :transform => DefaultSource.method(:convert_to_list),
905
+ :description => 'Prefix of attributes to include on transaction segments. Allows `*` as wildcard at end.'
773
906
  },
774
- :disable_memcache_instrumentation => {
775
- :default => false,
907
+ :'transaction_tracer.attributes.enabled' => {
908
+ :default => true,
776
909
  :public => true,
777
910
  :type => Boolean,
778
911
  :allowed_from_server => false,
779
- :description => 'If <code>true</code>, disables memcache instrumentation.'
912
+ :description => 'If `true`, the agent captures attributes from transaction traces.'
780
913
  },
781
- :disable_gc_profiler => {
782
- :default => false,
914
+ :'transaction_tracer.attributes.exclude' => {
915
+ :default => [],
783
916
  :public => true,
784
- :type => Boolean,
917
+ :type => Array,
785
918
  :allowed_from_server => false,
786
- :description => 'If <code>true</code>, disables the use of GC::Profiler to measure time spent in garbage collection'
919
+ :transform => DefaultSource.method(:convert_to_list),
920
+ :description => 'Prefix of attributes to exclude from transaction traces. Allows `*` as wildcard at end.'
787
921
  },
788
- :'sidekiq.capture_params' => {
789
- :default => false,
922
+ :'transaction_tracer.attributes.include' => {
923
+ :default => [],
790
924
  :public => true,
791
- :type => Boolean,
925
+ :type => Array,
792
926
  :allowed_from_server => false,
793
- :dynamic_name => true,
794
- :deprecated => true,
795
- :description => 'If <code>true</code>, enables the capture of job arguments for transaction traces and traced errors in Sidekiq.'
927
+ :transform => DefaultSource.method(:convert_to_list),
928
+ :description => 'Prefix of attributes to include in transaction traces. Allows `*` as wildcard at end.'
796
929
  },
797
- :'resque.capture_params' => {
930
+ # Audit log
931
+ :'audit_log.enabled' => {
798
932
  :default => false,
799
933
  :public => true,
800
934
  :type => Boolean,
801
935
  :allowed_from_server => false,
802
- :dynamic_name => true,
803
- :deprecated => true,
804
- :description => 'If <code>true</code>, enables the capture of job arguments for transaction traces and traced errors in Resque.'
936
+ :description => 'If `true`, enables an audit log which logs communications with the New Relic [collector](/docs/using-new-relic/welcome-new-relic/get-started/glossary/#collector).'
805
937
  },
806
- :'resque.use_ruby_dns' => {
807
- :default => true,
808
- :public => false,
809
- :type => Boolean,
810
- :allowed_from_server => false,
811
- :description => 'Replace the libc DNS resolver with the all Ruby resolver Resolv'
938
+ :'audit_log.endpoints' => {
939
+ :default => ['.*'],
940
+ :public => true,
941
+ :type => Array,
942
+ :allowed_from_server => false,
943
+ :transform => DefaultSource.method(:convert_to_regexp_list),
944
+ :description => 'List of allowed endpoints to include in audit log'
812
945
  },
813
- :capture_memcache_keys => {
946
+ :'audit_log.path' => {
947
+ :default => DefaultSource.audit_log_path,
948
+ :documentation_default => 'config/newrelic_audit.log',
949
+ :public => true,
950
+ :type => String,
951
+ :allowed_from_server => false,
952
+ :description => 'Specifies a path to the audit log file (including the filename).'
953
+ },
954
+ # Autostart
955
+ :'autostart.denylisted_constants' => {
956
+ :default => 'Rails::Console',
957
+ :public => true,
958
+ :type => String,
959
+ :allowed_from_server => false,
960
+ :description => 'Specify a list of constants that should prevent the agent from starting automatically. Separate individual constants with a comma `,`. For example, `Rails::Console,UninstrumentedBackgroundJob`.'
961
+ },
962
+ :'autostart.denylisted_executables' => {
963
+ :default => 'irb,rspec',
964
+ :public => true,
965
+ :type => String,
966
+ :allowed_from_server => false,
967
+ :description => 'Defines a comma-delimited list of executables that the agent should not instrument. For example, `rake,my_ruby_script.rb`.'
968
+ },
969
+ :'autostart.denylisted_rake_tasks' => {
970
+ :default => AUTOSTART_DENYLISTED_RAKE_TASKS,
971
+ :public => true,
972
+ :type => String,
973
+ :allowed_from_server => false,
974
+ :description => 'Defines a comma-delimited list of Rake tasks that the agent should not instrument. For example, `assets:precompile,db:migrate`.'
975
+ },
976
+ # Code level metrics
977
+ :'code_level_metrics.enabled' => {
978
+ :default => true,
979
+ :public => true,
980
+ :type => Boolean,
981
+ :allowed_from_server => true,
982
+ :description => "If `true`, the agent will report source code level metrics for traced methods.\nsee: " \
983
+ 'https://docs.newrelic.com/docs/apm/agents/ruby-agent/features/ruby-codestream-integration/'
984
+ },
985
+ # Cross application tracer
986
+ :"cross_application_tracer.enabled" => {
814
987
  :default => false,
815
988
  :public => true,
816
989
  :type => Boolean,
817
990
  :allowed_from_server => true,
818
- :description => 'Enable or disable the capture of memcache keys from transaction traces.'
991
+ :deprecated => true,
992
+ :description => deprecated_description(
993
+ :'distributed_tracing-enabled',
994
+ 'If `true`, enables [cross-application tracing](/docs/agents/ruby-agent/features/cross-application-tracing-ruby/) when `distributed_tracing.enabled` is set to `false`.'
995
+ )
819
996
  },
820
- :'transaction_tracer.enabled' => {
997
+ # Custom attributes
998
+ :'custom_attributes.enabled' => {
821
999
  :default => true,
822
1000
  :public => true,
823
1001
  :type => Boolean,
824
- :allowed_from_server => true,
825
- :description => 'If <code>true</code>, enables collection of <a href="https://docs.newrelic.com/docs/apm/traces/transaction-traces/transaction-traces">transaction traces</a>.'
1002
+ :allowed_from_server => false,
1003
+ :description => 'If `false`, custom attributes will not be sent on events.'
826
1004
  },
827
- :'transaction_tracer.transaction_threshold' => {
828
- :default => DefaultSource.transaction_tracer_transaction_threshold,
1005
+ # Custom events
1006
+ :'custom_insights_events.enabled' => {
1007
+ :default => true,
829
1008
  :public => true,
830
- :type => Float,
1009
+ :type => Boolean,
831
1010
  :allowed_from_server => true,
832
- :description => 'Specify a threshold in seconds. Transactions with a duration longer than this threshold are eligible for transaction traces. Specify a float value or the string <code><a href="https://docs.newrelic.com/docs/apm/new-relic-apm/getting-started/glossary#apdex_f">apdex_f</a></code>.'
1011
+ :description => 'If `true`, the agent captures [custom events](/docs/insights/new-relic-insights/adding-querying-data/inserting-custom-events-new-relic-apm-agents).'
833
1012
  },
834
- :'transaction_tracer.record_sql' => {
835
- :default => 'obfuscated',
1013
+ :'custom_insights_events.max_samples_stored' => {
1014
+ :default => 3000,
836
1015
  :public => true,
837
- :type => String,
1016
+ :type => Integer,
838
1017
  :allowed_from_server => true,
839
- :description => 'Obfuscation level for SQL queries reported in transaction trace nodes.</p>
840
-
841
- <p>By default, this is set to <code>obfuscated</code>, which strips out the numeric and string literals.</p>
842
-
843
- <ul>
844
- <li>If you do not want the agent to capture query information, set this to <code>none</code>.</li>
845
- <li>If you want the agent to capture all query information in its original form, set this to <code>raw</code>.</li>
846
- <li>When you enable <a href="/docs/agents/manage-apm-agents/configuration/high-security-mode">high security mode</a>, this is automatically set to <code>obfuscated</code>.</li>
847
- </ul>
848
- <p>' # Doc generator will wrap this in <p>...</p>
1018
+ :description => 'Specify a maximum number of custom events to buffer in memory at a time.',
1019
+ :dynamic_name => true
849
1020
  },
850
- :'transaction_tracer.record_redis_arguments' => {
851
- :default => false,
1021
+ # Datastore tracer
1022
+ :'datastore_tracer.database_name_reporting.enabled' => {
1023
+ :default => true,
852
1024
  :public => true,
853
1025
  :type => Boolean,
854
1026
  :allowed_from_server => false,
855
- :description => 'If <code>true</code>, the agent records Redis command arguments in transaction traces.'
1027
+ :description => 'If `false`, the agent will not add `database_name` parameter to transaction or slow sql traces.'
856
1028
  },
857
- :'transaction_tracer.capture_attributes' => {
1029
+ :'datastore_tracer.instance_reporting.enabled' => {
858
1030
  :default => true,
859
1031
  :public => true,
860
1032
  :type => Boolean,
861
- :deprecated => true,
862
1033
  :allowed_from_server => false,
863
- :description => 'Deprecated; use <a href="#transaction_tracer-attributes-enabled"><code>transaction_tracer.attributes.enabled</code></a> instead.'
1034
+ :description => 'If `false`, the agent will not report datastore instance metrics, nor add `host` or `port_path_or_id` parameters to transaction or slow SQL traces.'
864
1035
  },
865
- :'transaction_tracer.explain_threshold' => {
866
- :default => 0.5,
1036
+ # Disabling
1037
+ :disable_action_cable_instrumentation => {
1038
+ :default => false,
867
1039
  :public => true,
868
- :type => Float,
869
- :allowed_from_server => true,
870
- :description => 'Threshold (in seconds) above which the agent will collect explain plans. Relevant only when <code><a href="#transaction_tracer.explain_enabled">explain_enabled</a></code> is true.'
1040
+ :type => Boolean,
1041
+ :allowed_from_server => false,
1042
+ :description => 'If `true`, disables Action Cable instrumentation.'
871
1043
  },
872
- :'transaction_tracer.explain_enabled' => {
1044
+ # TODO: by subscribing to process_middleware.action_dispatch events,
1045
+ # we duplicate the efforts already performed by non-notifications
1046
+ # based instrumentation. In future, we ought to determine the
1047
+ # extent of the overlap and duplication and end up with only this
1048
+ # notifications based approach existing and the monkey patching
1049
+ # approach removed entirely. NOTE that we will likely not want to
1050
+ # do so until we are okay with dropping support for Rails < v6,
1051
+ # given that these events are available only for v6+.
1052
+ :disable_action_dispatch => {
873
1053
  :default => true,
874
- :public => true,
1054
+ :public => false,
875
1055
  :type => Boolean,
876
- :allowed_from_server => true,
877
- :description => 'If <code>true</code>, enables the collection of explain plans in transaction traces. This setting will also apply to explain plans in slow SQL traces if <a href="#slow_sql-explain_enabled"><code>slow_sql.explain_enabled</code></a> is not set separately.'
1056
+ :allowed_from_server => false,
1057
+ :description => 'If `true`, disables Action Dispatch instrumentation.'
878
1058
  },
879
- :'transaction_tracer.stack_trace_threshold' => {
880
- :default => 0.5,
1059
+ :disable_action_controller => {
1060
+ :default => false,
881
1061
  :public => true,
882
- :type => Float,
883
- :allowed_from_server => true,
884
- :description => 'Specify a threshold in seconds. The agent includes stack traces in transaction trace nodes when the stack trace duration exceeds this threshold.'
1062
+ :type => Boolean,
1063
+ :allowed_from_server => false,
1064
+ :description => 'If `true`, disables Action Controller instrumentation.'
885
1065
  },
886
- :'transaction_tracer.limit_segments' => {
887
- :default => 4000,
1066
+ :disable_action_mailbox => {
1067
+ :default => false,
888
1068
  :public => true,
889
- :type => Integer,
890
- :allowed_from_server => true,
891
- :description => 'Maximum number of transaction trace nodes to record in a single transaction trace.'
1069
+ :type => Boolean,
1070
+ :allowed_from_server => false,
1071
+ :description => 'If `true`, disables Action Mailbox instrumentation.'
892
1072
  },
893
- :disable_sequel_instrumentation => {
1073
+ :disable_action_mailer => {
894
1074
  :default => false,
895
1075
  :public => true,
896
1076
  :type => Boolean,
897
1077
  :allowed_from_server => false,
898
- :description => 'If <code>true</code>, disables <a href="https://docs.newrelic.com/docs/agents/ruby-agent/frameworks/sequel-instrumentation">Sequel instrumentation</a>.'
1078
+ :description => 'If `true`, disables Action Mailer instrumentation.'
899
1079
  },
900
- :disable_database_instrumentation => {
1080
+ :disable_activejob => {
901
1081
  :default => false,
902
1082
  :public => true,
903
1083
  :type => Boolean,
904
1084
  :allowed_from_server => false,
905
- :deprecated => true,
906
- :description => 'Deprecated; use <a href="#disable_sequel_instrumentation"><code>disable_sequel_instrumentation</code></a> instead.'
1085
+ :description => 'If `true`, disables Active Job instrumentation.'
907
1086
  },
908
- :disable_mongo => {
909
- :default => false,
910
- :public => true,
911
- :type => Boolean,
1087
+ :disable_active_storage => {
1088
+ :default => false,
1089
+ :public => true,
1090
+ :type => Boolean,
912
1091
  :allowed_from_server => false,
913
- :dynamic_name => true,
914
- :description => 'If <code>true</code>, the agent won\'t install <a href="https://docs.newrelic.com/docs/agents/ruby-agent/frameworks/mongo-instrumentation">instrumentation for the Mongo gem</a>.'
1092
+ :description => 'If `true`, disables Active Storage instrumentation.'
915
1093
  },
916
- :disable_redis => {
917
- :default => false,
918
- :public => true,
919
- :type => Boolean,
1094
+ :disable_active_support => {
1095
+ :default => false,
1096
+ :public => true,
1097
+ :type => Boolean,
920
1098
  :allowed_from_server => false,
921
- :description => 'If <code>true</code>, the agent won\'t install <a href="https://docs.newrelic.com/docs/agents/ruby-agent/frameworks/redis-instrumentation">instrumentation for Redis</a>.'
1099
+ :description => 'If `true`, disables Active Support instrumentation.'
922
1100
  },
923
- :disable_redis_instrumentation => {
924
- :default => false,
925
- :public => false,
926
- :type => Boolean,
1101
+ :disable_activerecord_instrumentation => {
1102
+ :default => value_of(:skip_ar_instrumentation),
1103
+ :documentation_default => false,
1104
+ :public => true,
1105
+ :type => Boolean,
927
1106
  :allowed_from_server => false,
928
- :description => 'Disables installation of Redis instrumentation. Standard key to use is disable_redis.'
1107
+ :description => 'If `true`, disables Active Record instrumentation.'
929
1108
  },
930
- :'message_tracer.segment_parameters.enabled' => {
931
- :default => true,
932
- :public => true,
933
- :type => Boolean,
934
- :allowed_from_server => true,
935
- :description => 'If <code>true</code>, the agent will collect metadata about messages and attach them as segment parameters.'
1109
+ :disable_active_record_notifications => {
1110
+ :default => false,
1111
+ :public => true,
1112
+ :type => Boolean,
1113
+ :dynamic_name => true,
1114
+ :allowed_from_server => false,
1115
+ :description => 'If `true`, disables instrumentation for Active Record 4+'
936
1116
  },
937
- :'slow_sql.enabled' => {
938
- :default => value_of(:'transaction_tracer.enabled'),
1117
+ :disable_cpu_sampler => {
1118
+ :default => false,
939
1119
  :public => true,
940
1120
  :type => Boolean,
941
- :allowed_from_server => true,
942
- :description => 'If <code>true</code>, the agent collects <a href="https://docs.newrelic.com/docs/apm/applications-menu/monitoring/viewing-slow-query-details">slow SQL queries</a>.'
1121
+ :dynamic_name => true,
1122
+ :allowed_from_server => false,
1123
+ :description => 'If `true`, the agent won\'t sample the CPU usage of the host process.'
943
1124
  },
944
- :'slow_sql.explain_threshold' => {
945
- :default => value_of(:'transaction_tracer.explain_threshold'),
1125
+ :disable_delayed_job_sampler => {
1126
+ :default => false,
946
1127
  :public => true,
947
- :type => Float,
948
- :allowed_from_server => true,
949
- :description => 'Specify a threshold in seconds. The agent collects <a href="https://docs.newrelic.com/docs/apm/applications-menu/monitoring/viewing-slow-query-details">slow SQL queries</a> and explain plans that exceed this threshold.'
1128
+ :type => Boolean,
1129
+ :dynamic_name => true,
1130
+ :allowed_from_server => false,
1131
+ :description => 'If `true`, the agent won\'t measure the depth of Delayed Job queues.'
950
1132
  },
951
- :'slow_sql.explain_enabled' => {
952
- :default => value_of(:'transaction_tracer.explain_enabled'),
1133
+ :disable_gc_profiler => {
1134
+ :default => false,
953
1135
  :public => true,
954
1136
  :type => Boolean,
955
- :allowed_from_server => true,
956
- :description => 'If <code>true</code>, the agent collects explain plans in slow SQL queries. If this setting is omitted, the <a href="#transaction_tracer-explain_enabled"><code>transaction_tracer.explain_enabled</code></a> setting will be applied as the default setting for explain plans in slow SQL as well.'
1137
+ :allowed_from_server => false,
1138
+ :description => 'If `true`, disables the use of GC::Profiler to measure time spent in garbage collection'
957
1139
  },
958
- :'slow_sql.record_sql' => {
959
- :default => value_of(:'transaction_tracer.record_sql'),
1140
+ :disable_memory_sampler => {
1141
+ :default => false,
960
1142
  :public => true,
961
- :type => String,
962
- :allowed_from_server => true,
963
- :description => 'Defines an obfuscation level for slow SQL queries. Valid options are <code>obfuscated</code>, <code>raw</code>, or <code>none</code>).'
1143
+ :type => Boolean,
1144
+ :dynamic_name => true,
1145
+ :allowed_from_server => false,
1146
+ :description => 'If `true`, the agent won\'t sample the memory usage of the host process.'
964
1147
  },
965
- :'slow_sql.use_longer_sql_id' => {
1148
+ :disable_middleware_instrumentation => {
966
1149
  :default => false,
967
1150
  :public => true,
968
1151
  :type => Boolean,
969
- :allowed_from_server => true,
970
- :description => 'Generate a longer sql_id for slow SQL traces. sql_id is used for aggregation of similar queries.'
1152
+ :allowed_from_server => false,
1153
+ :description => 'If `true`, the agent won\'t wrap third-party middlewares in instrumentation (regardless of whether they are installed via Rack::Builder or Rails).'
971
1154
  },
972
- :'mongo.capture_queries' => {
973
- :default => true,
1155
+ :disable_samplers => {
1156
+ :default => false,
974
1157
  :public => true,
975
1158
  :type => Boolean,
976
- :allowed_from_server => true,
977
- :description => 'If <code>true</code>, the agent captures Mongo queries in transaction traces.'
1159
+ :allowed_from_server => false,
1160
+ :description => 'If `true`, disables the collection of sampler metrics. Sampler metrics are metrics that are not event-based (such as CPU time or memory usage).'
978
1161
  },
979
- :'mongo.obfuscate_queries' => {
980
- :default => true,
1162
+ :disable_sequel_instrumentation => {
1163
+ :default => false,
981
1164
  :public => true,
982
1165
  :type => Boolean,
983
- :allowed_from_server => true,
984
- :description => 'If <code>true</code>, the agent obfuscates Mongo queries in transaction traces.'
1166
+ :allowed_from_server => false,
1167
+ :description => 'If `true`, disables [Sequel instrumentation](/docs/agents/ruby-agent/frameworks/sequel-instrumentation).'
985
1168
  },
986
- :'error_collector.enabled' => {
987
- :default => true,
1169
+ :disable_sidekiq => {
1170
+ :default => false,
988
1171
  :public => true,
989
1172
  :type => Boolean,
990
- :allowed_from_server => true,
991
- :description => 'If <code>true</code>, the agent captures traced errors and error count metrics.'
1173
+ :allowed_from_server => false,
1174
+ :description => 'If `true`, disables [Sidekiq instrumentation](/docs/agents/ruby-agent/background-jobs/sidekiq-instrumentation).'
992
1175
  },
993
- :'error_collector.capture_attributes' => {
994
- :default => true,
1176
+ :disable_sinatra_auto_middleware => {
1177
+ :default => false,
995
1178
  :public => true,
996
1179
  :type => Boolean,
997
- :deprecated => true,
998
1180
  :allowed_from_server => false,
999
- :description => 'Deprecated; use <a href="#error_collector-attributes-enabled"><code>error_collector.attributes.enabled</code></a> instead.'
1181
+ :description => <<~DESCRIPTION
1182
+ If `true`, disables agent middleware for Sinatra. This middleware is responsible for advanced feature support such as [cross application tracing](/docs/apm/transactions/cross-application-traces/cross-application-tracing), [page load timing](/docs/browser/new-relic-browser/getting-started/new-relic-browser), and [error collection](/docs/apm/applications-menu/events/view-apm-error-analytics).
1183
+
1184
+ <Callout variant="important">
1185
+ Cross application tracing is deprecated in favor of [distributed tracing](/docs/apm/distributed-tracing/getting-started/introduction-distributed-tracing). Distributed tracing is on by default for Ruby agent versions 8.0.0 and above. Middlewares are not required to support distributed tracing.
1186
+
1187
+ To continue using cross application tracing, update the following options in your `newrelic.yml` configuration file:
1188
+
1189
+ ```
1190
+ # newrelic.yml
1191
+
1192
+ cross_application_tracer:
1193
+ enabled: true
1194
+ distributed_tracing:
1195
+ enabled: false
1196
+ ```
1197
+ </Callout>
1198
+ DESCRIPTION
1000
1199
  },
1001
- :'error_collector.ignore_errors' => {
1002
- :default => 'ActionController::RoutingError,Sinatra::NotFound',
1200
+ :disable_view_instrumentation => {
1201
+ :default => false,
1003
1202
  :public => true,
1004
- :type => String,
1005
- :allowed_from_server => true,
1006
- :description => 'Specify a comma-delimited list of error classes that the agent should ignore.'
1203
+ :type => Boolean,
1204
+ :allowed_from_server => false,
1205
+ :description => 'If `true`, disables view instrumentation.'
1007
1206
  },
1008
- :'error_collector.max_backtrace_frames' => {
1009
- :default => 50,
1207
+ :disable_vm_sampler => {
1208
+ :default => false,
1010
1209
  :public => true,
1011
- :type => Integer,
1210
+ :type => Boolean,
1211
+ :dynamic_name => true,
1012
1212
  :allowed_from_server => false,
1013
- :description => 'Defines the maximum number of frames in an error backtrace. Backtraces over this amount are truncated at the beginning and end.'
1213
+ :description => 'If `true`, the agent won\'t [sample performance measurements from the Ruby VM](/docs/agents/ruby-agent/features/ruby-vm-measurements).'
1014
1214
  },
1015
- :'error_collector.capture_events' => {
1016
- :default => value_of(:'error_collector.enabled'),
1215
+ # Distributed tracing
1216
+ :'distributed_tracing.enabled' => {
1217
+ :default => true,
1017
1218
  :public => true,
1018
1219
  :type => Boolean,
1019
1220
  :allowed_from_server => true,
1020
- :description => 'If <code>true</code>, the agent collects <a href="https://docs.newrelic.com/docs/insights/new-relic-insights/decorating-events/error-event-default-attributes-insights">TransactionError events</a>.'
1221
+ :description => 'Distributed tracing lets you see the path that a request takes through your distributed system. Enabling distributed tracing changes the behavior of some New Relic features, so carefully consult the [transition guide](/docs/transition-guide-distributed-tracing) before you enable this feature.'
1021
1222
  },
1022
- :'error_collector.max_event_samples_stored' => {
1023
- :default => 100,
1223
+ # Elasticsearch
1224
+ :'elasticsearch.capture_queries' => {
1225
+ :default => true,
1024
1226
  :public => true,
1025
- :type => Integer,
1227
+ :type => Boolean,
1026
1228
  :allowed_from_server => true,
1027
- :description => 'Defines the maximum number of <a href="https://docs.newrelic.com/docs/insights/new-relic-insights/decorating-events/error-event-default-attributes-insights">TransactionError events</a> sent to Insights per harvest cycle.'
1229
+ :description => 'If `true`, the agent captures Elasticsearch queries in transaction traces.'
1028
1230
  },
1029
- :'rum.enabled' => {
1231
+ :'elasticsearch.obfuscate_queries' => {
1030
1232
  :default => true,
1031
- :public => false,
1233
+ :public => true,
1032
1234
  :type => Boolean,
1033
1235
  :allowed_from_server => true,
1034
- :description => 'Enable or disable page load timing (sometimes referred to as real user monitoring or RUM).'
1236
+ :description => 'If `true`, the agent obfuscates Elasticsearch queries in transaction traces.'
1035
1237
  },
1036
- :browser_key => {
1037
- :default => '',
1038
- :public => false,
1039
- :type => String,
1040
- :allowed_from_server => true,
1041
- :description => 'Real user monitoring license key for the browser timing header.'
1238
+ # Heroku
1239
+ :'heroku.use_dyno_names' => {
1240
+ :default => true,
1241
+ :public => true,
1242
+ :type => Boolean,
1243
+ :allowed_from_server => false,
1244
+ :description => 'If `true`, the agent uses Heroku dyno names as the hostname.'
1042
1245
  },
1043
- :beacon => {
1044
- :default => '',
1045
- :public => false,
1046
- :type => String,
1047
- :allowed_from_server => true,
1048
- :description => 'Beacon for real user monitoring.'
1246
+ :'heroku.dyno_name_prefixes_to_shorten' => {
1247
+ :default => %w[scheduler run],
1248
+ :public => true,
1249
+ :type => Array,
1250
+ :allowed_from_server => false,
1251
+ :transform => DefaultSource.method(:convert_to_list),
1252
+ :description => 'Ordinarily the agent reports dyno names with a trailing dot and process ID (for example, <b>worker.3</b>). You can remove this trailing data by specifying the prefixes you want to report without trailing data (for example, <b>worker</b>).'
1049
1253
  },
1050
- :error_beacon => {
1254
+ # Infinite tracing
1255
+ :'infinite_tracing.trace_observer.host' => {
1051
1256
  :default => '',
1052
- :public => false,
1257
+ :public => true,
1053
1258
  :type => String,
1054
- :allowed_from_server => true,
1055
- :description => 'Error beacon for real user monitoring.'
1259
+ :allowed_from_server => false,
1260
+ :external => :infinite_tracing,
1261
+ :description => 'Configures the hostname for the trace observer Host. ' \
1262
+ 'When configured, enables tail-based sampling by sending all recorded spans ' \
1263
+ 'to a trace observer for further sampling decisions, irrespective of any usual ' \
1264
+ 'agent sampling decision.'
1056
1265
  },
1057
- :application_id => {
1058
- :default => '',
1059
- :public => false,
1266
+ :'infinite_tracing.trace_observer.port' => {
1267
+ :default => 443,
1268
+ :public => true,
1269
+ :type => Integer,
1270
+ :allowed_from_server => false,
1271
+ :external => :infinite_tracing,
1272
+ :description => 'Configures the TCP/IP port for the trace observer Host'
1273
+ },
1274
+ # Instrumentation
1275
+ :'instrumentation.active_support_logger' => {
1276
+ :default => instrumentation_value_from_boolean(:'application_logging.enabled'),
1277
+ :documentation_default => 'auto',
1278
+ :dynamic_name => true,
1279
+ :public => true,
1060
1280
  :type => String,
1061
- :allowed_from_server => true,
1062
- :description => 'Application ID for real user monitoring.'
1281
+ :allowed_from_server => false,
1282
+ :description => 'Controls auto-instrumentation of ActiveSupport::Logger at start up. May be one of [auto|prepend|chain|disabled].'
1063
1283
  },
1064
- :js_agent_file => {
1065
- :default => '',
1066
- :public => false,
1284
+ :'instrumentation.bunny' => {
1285
+ :default => 'auto',
1286
+ :public => true,
1067
1287
  :type => String,
1068
- :allowed_from_server => true,
1069
- :description => 'Javascript agent file for real user monitoring.'
1288
+ :dynamic_name => true,
1289
+ :allowed_from_server => false,
1290
+ :description => 'Controls auto-instrumentation of bunny at start up. May be one of [auto|prepend|chain|disabled].'
1070
1291
  },
1071
- :'browser_monitoring.auto_instrument' => {
1072
- :default => value_of(:'rum.enabled'),
1292
+ :'instrumentation.fiber' => {
1293
+ :default => 'auto',
1073
1294
  :public => true,
1074
- :type => Boolean,
1075
- :allowed_from_server => true,
1076
- :description => 'If <code>true</code>, enables <a href="https://docs.newrelic.com/docs/browser/new-relic-browser/installation-configuration/adding-apps-new-relic-browser#select-apm-app">auto-injection</a> of the JavaScript header for page load timing (sometimes referred to as real user monitoring or RUM).'
1295
+ :type => String,
1296
+ :dynamic_name => true,
1297
+ :allowed_from_server => false,
1298
+ :description => 'Controls auto-instrumentation of the Fiber class at start up. May be one of [auto|prepend|chain|disabled].'
1077
1299
  },
1078
- :'browser_monitoring.capture_attributes' => {
1079
- :default => false,
1300
+ :'instrumentation.concurrent_ruby' => {
1301
+ :default => 'auto',
1080
1302
  :public => true,
1081
- :type => Boolean,
1082
- :deprecated => true,
1083
- :allowed_from_server => false,
1084
- :description => 'Deprecated; use <a href="#browser_monitoring-attributes-enabled"><code>browser_monitoring.attributes.enabled</code></a> instead.'
1085
- },
1086
- :'browser_monitoring.loader' => {
1087
- :default => DefaultSource.browser_monitoring_loader,
1088
- :public => false,
1089
- :type => String,
1090
- :allowed_from_server => true,
1091
- :description => 'Type of JavaScript agent loader to use for browser monitoring instrumentation.'
1092
- },
1093
- :'browser_monitoring.loader_version' => {
1094
- :default => '',
1095
- :public => false,
1096
- :type => String,
1097
- :allowed_from_server => true,
1098
- :description => 'Version of JavaScript agent loader (returned from the New Relic <a href="https://docs.newrelic.com/docs/apm/new-relic-apm/getting-started/glossary#collector">collector</a>.)'
1099
- },
1100
- :'browser_monitoring.debug' => {
1101
- :default => false,
1102
- :public => false,
1103
- :type => Boolean,
1104
- :allowed_from_server => true,
1105
- :description => 'Enable or disable debugging version of JavaScript agent loader for browser monitoring instrumentation.'
1106
- },
1107
- :'browser_monitoring.ssl_for_http' => {
1108
- :default => nil,
1109
- :allow_nil => true,
1110
- :public => false,
1111
- :type => Boolean,
1112
- :allowed_from_server => true,
1113
- :description => 'Enable or disable HTTPS instrumentation by JavaScript agent on HTTP pages.'
1114
- },
1115
- :js_agent_loader => {
1116
- :default => '',
1117
- :public => false,
1118
1303
  :type => String,
1119
- :allowed_from_server => true,
1120
- :description => 'JavaScript agent loader content.'
1121
- },
1122
- :js_errors_beta => {
1123
- :default => false,
1124
- :public => false,
1125
- :type => Boolean,
1304
+ :dynamic_name => true,
1126
1305
  :allowed_from_server => false,
1127
- :deprecated => true,
1128
- :description => 'Enable or disable beta JavaScript error reporting.'
1129
- },
1130
- :trusted_account_ids => {
1131
- :default => [],
1132
- :public => false,
1133
- :type => Array,
1134
- :allowed_from_server => true,
1135
- :description => 'List of trusted New Relic account IDs for the purposes of cross-application tracing. Inbound requests from applications including cross-application headers that do not come from an account in this list will be ignored.'
1306
+ :description => 'Controls auto-instrumentation of the concurrent-ruby library at start up. May be one of [auto|prepend|chain|disabled].'
1136
1307
  },
1137
- :"cross_application_tracer.enabled" => {
1138
- :default => Proc.new { !NewRelic::Agent.config[:'distributed_tracing.enabled'] },
1308
+ :'instrumentation.curb' => {
1309
+ :default => 'auto',
1310
+ :documentation_default => 'auto',
1139
1311
  :public => true,
1140
- :type => Boolean,
1141
- :allowed_from_server => true,
1142
- :description => 'If <code>true</code>, enables <a href="https://docs.newrelic.com/docs/apm/transactions/cross-application-traces/cross-application-tracing">cross-application tracing</a>.'
1143
- },
1144
- :cross_application_tracing => {
1145
- :default => nil,
1146
- :allow_nil => true,
1147
- :public => false,
1148
- :type => Boolean,
1149
- :allowed_from_server => false,
1150
- :deprecated => true,
1151
- :description => 'Deprecated in favor of cross_application_tracer.enabled'
1152
- },
1153
- :encoding_key => {
1154
- :default => '',
1155
- :public => false,
1156
- :type => String,
1157
- :allowed_from_server => true,
1158
- :description => 'Encoding key for cross-application tracing.'
1159
- },
1160
- :cross_process_id => {
1161
- :default => '',
1162
- :public => false,
1163
1312
  :type => String,
1164
- :allowed_from_server => true,
1165
- :description => 'Cross process ID for cross-application tracing.'
1313
+ :dynamic_name => true,
1314
+ :allowed_from_server => false,
1315
+ :description => 'Controls auto-instrumentation of Curb at start up. May be one of [auto|prepend|chain|disabled].'
1166
1316
  },
1167
- :'thread_profiler.enabled' => {
1168
- :default => DefaultSource.thread_profiler_enabled,
1317
+ :'instrumentation.delayed_job' => {
1318
+ :default => 'auto',
1319
+ :documentation_default => 'auto',
1169
1320
  :public => true,
1170
- :type => Boolean,
1171
- :allowed_from_server => true,
1172
- :description => 'If <code>true</code>, enables use of the <a href="https://docs.newrelic.com/docs/apm/applications-menu/events/thread-profiler-tool">thread profiler</a>.'
1321
+ :type => String,
1322
+ :dynamic_name => true,
1323
+ :allowed_from_server => false,
1324
+ :description => 'Controls auto-instrumentation of Delayed Job at start up. May be one of [auto|prepend|chain|disabled].'
1173
1325
  },
1174
- :'xray_session.enabled' => {
1175
- :default => true,
1326
+ :'instrumentation.elasticsearch' => {
1327
+ :default => 'auto',
1176
1328
  :public => true,
1177
- :type => Boolean,
1178
- :allowed_from_server => true,
1179
- :description => 'If <code>true</code>, enables <a href="https://docs.newrelic.com/docs/apm/transactions-menu/x-ray-sessions/x-ray-sessions">X-Ray sessions</a>.'
1180
- },
1181
- :'xray_session.allow_traces' => {
1182
- :default => true,
1183
- :public => false,
1184
- :type => Boolean,
1185
- :allowed_from_server => true,
1186
- :description => 'Enable or disable X-Ray sessions recording transaction traces.'
1187
- },
1188
- :'xray_session.allow_profiles' => {
1189
- :default => true,
1190
- :public => false,
1191
- :type => Boolean,
1192
- :allowed_from_server => true,
1193
- :description => 'Enable or disable X-Ray sessions taking thread profiles.'
1194
- },
1195
- :'xray_session.max_samples' => {
1196
- :default => 10,
1197
- :public => false,
1198
- :type => Integer,
1199
- :allowed_from_server => true,
1200
- :description => 'Maximum number of transaction traces to buffer for active X-Ray sessions'
1201
- },
1202
- :'xray_session.max_profile_overhead' => {
1203
- :default => 0.05,
1204
- :public => false,
1205
- :type => Float,
1206
- :allowed_from_server => true,
1207
- :description => 'Maximum overhead percentage for thread profiling before agent reduces polling frequency'
1329
+ :type => String,
1330
+ :dynamic_name => true,
1331
+ :allowed_from_server => false,
1332
+ :description => 'Controls auto-instrumentation of the elasticsearch library at start up. May be one of [auto|prepend|chain|disabled].'
1208
1333
  },
1209
- :marshaller => {
1210
- :default => 'json',
1334
+ :'instrumentation.excon' => {
1335
+ :default => 'enabled',
1336
+ :documentation_default => 'enabled',
1211
1337
  :public => true,
1212
1338
  :type => String,
1339
+ :dynamic_name => true,
1213
1340
  :allowed_from_server => false,
1214
- :description => 'Specifies a marshaller for transmitting data to the New Relic <a href="https://docs.newrelic.com/docs/apm/new-relic-apm/getting-started/glossary#collector">collector</a>. Currently <code>json</code> is the only valid value for this setting.'
1341
+ :description => 'Controls auto-instrumentation of Excon at start up. May be one of [enabled|disabled].'
1215
1342
  },
1216
- :'analytics_events.enabled' => {
1217
- :default => true,
1343
+ :'instrumentation.grape' => {
1344
+ :default => 'auto',
1218
1345
  :public => true,
1219
- :type => Boolean,
1220
- :allowed_from_server => true,
1221
- :description => 'If <code>true</code>, enables analytics event sampling.'
1346
+ :type => String,
1347
+ :dynamic_name => true,
1348
+ :allowed_from_server => false,
1349
+ :description => 'Controls auto-instrumentation of Grape at start up. May be one of [auto|prepend|chain|disabled].'
1222
1350
  },
1223
- :'analytics_events.max_samples_stored' => {
1224
- :default => 1200,
1351
+ :'instrumentation.grpc_client' => {
1352
+ :default => 'auto',
1353
+ :documentation_default => 'auto',
1225
1354
  :public => true,
1226
- :type => Integer,
1227
- :allowed_from_server => true,
1228
- :description => 'Defines the maximum number of request events reported from a single harvest.'
1355
+ :type => String,
1356
+ :dynamic_name => true,
1357
+ :allowed_from_server => false,
1358
+ :description => 'Controls auto-instrumentation of gRPC clients at start up. May be one of [auto|prepend|chain|disabled].'
1229
1359
  },
1230
- :'analytics_events.capture_attributes' => {
1231
- :default => true,
1360
+ :'instrumentation.grpc.host_denylist' => {
1361
+ :default => [],
1232
1362
  :public => true,
1233
- :type => Boolean,
1234
- :deprecated => true,
1363
+ :type => Array,
1235
1364
  :allowed_from_server => false,
1236
- :description => 'Deprecated; use <a href="#transaction_events-attributes-enabled"><code>transaction_events.attributes.enabled</code></a> instead.'
1365
+ :transform => DefaultSource.method(:convert_to_regexp_list),
1366
+ :description => %Q(Specifies a list of hostname patterns separated by commas that will match gRPC hostnames that traffic is to be ignored by New Relic for. New Relic's gRPC client instrumentation will ignore traffic streamed to a host matching any of these patterns, and New Relic's gRPC server instrumentation will ignore traffic for a server running on a host whose hostname matches any of these patterns. By default, no traffic is ignored when gRPC instrumentation is itself enabled. For example, "private.com$,exception.*")
1237
1367
  },
1238
- :restart_thread_in_children => {
1239
- :default => true,
1240
- :public => false,
1241
- :type => Boolean,
1368
+ :'instrumentation.grpc_server' => {
1369
+ :default => 'auto',
1370
+ :documentation_default => 'auto',
1371
+ :public => true,
1372
+ :type => String,
1373
+ :dynamic_name => true,
1242
1374
  :allowed_from_server => false,
1243
- :description => 'Controls whether to check on running a transaction whether to respawn the harvest thread.'
1375
+ :description => 'Controls auto-instrumentation of gRPC servers at start up. May be one of [auto|prepend|chain|disabled].'
1244
1376
  },
1245
- :normalize_json_string_encodings => {
1246
- :default => true,
1247
- :public => false,
1248
- :type => Boolean,
1377
+ :'instrumentation.httpclient' => {
1378
+ :default => 'auto',
1379
+ :documentation_default => 'auto',
1380
+ :public => true,
1381
+ :type => String,
1382
+ :dynamic_name => true,
1249
1383
  :allowed_from_server => false,
1250
- :description => 'Controls whether to normalize string encodings prior to serializing data for the collector to JSON.'
1384
+ :description => 'Controls auto-instrumentation of HTTPClient at start up. May be one of [auto|prepend|chain|disabled].'
1251
1385
  },
1252
- :backport_fast_active_record_connection_lookup => {
1253
- :default => true,
1254
- :public => false,
1255
- :type => Boolean,
1386
+ :'instrumentation.httprb' => {
1387
+ :default => 'auto',
1388
+ :documentation_default => 'auto',
1389
+ :public => true,
1390
+ :type => String,
1391
+ :dynamic_name => true,
1256
1392
  :allowed_from_server => false,
1257
- :description => 'Enables patching of "sql.active_record" AS Notification to include :connection in payload.'
1393
+ :description => 'Controls auto-instrumentation of http.rb gem at start up. May be one of [auto|prepend|chain|disabled].'
1258
1394
  },
1259
- :disable_vm_sampler => {
1260
- :default => false,
1261
- :public => true,
1262
- :type => Boolean,
1395
+ :'instrumentation.logger' => {
1396
+ :default => instrumentation_value_from_boolean(:'application_logging.enabled'),
1397
+ :documentation_default => 'auto',
1398
+ :public => true,
1399
+ :type => String,
1263
1400
  :dynamic_name => true,
1264
1401
  :allowed_from_server => false,
1265
- :description => 'If <code>true</code>, the agent won\'t <a href="https://docs.newrelic.com/docs/agents/ruby-agent/features/ruby-vm-measurements">sample performance measurements from the Ruby VM</a>.'
1402
+ :description => 'Controls auto-instrumentation of Ruby standard library Logger at start up. May be one of [auto|prepend|chain|disabled].'
1266
1403
  },
1267
- :disable_memory_sampler => {
1268
- :default => false,
1269
- :public => true,
1270
- :type => Boolean,
1404
+ :'instrumentation.memcache' => {
1405
+ :default => 'auto',
1406
+ :public => true,
1407
+ :type => String,
1271
1408
  :dynamic_name => true,
1272
1409
  :allowed_from_server => false,
1273
- :description => 'If <code>true</code>, the agent won\'t sample the memory usage of the host process.'
1410
+ :description => 'Controls auto-instrumentation of dalli gem for Memcache at start up. May be one of [auto|prepend|chain|disabled].'
1274
1411
  },
1275
- :disable_cpu_sampler => {
1276
- :default => false,
1277
- :public => true,
1278
- :type => Boolean,
1412
+ :'instrumentation.memcached' => {
1413
+ :default => 'auto',
1414
+ :documentation_default => 'auto',
1415
+ :public => true,
1416
+ :type => String,
1279
1417
  :dynamic_name => true,
1280
1418
  :allowed_from_server => false,
1281
- :description => 'If <code>true</code>, the agent won\'t sample the CPU usage of the host process.'
1419
+ :description => 'Controls auto-instrumentation of memcached gem for Memcache at start up. May be one of [auto|prepend|chain|disabled].'
1282
1420
  },
1283
- :disable_delayed_job_sampler => {
1284
- :default => false,
1285
- :public => true,
1286
- :type => Boolean,
1421
+ :'instrumentation.memcache_client' => {
1422
+ :default => 'auto',
1423
+ :documentation_default => 'auto',
1424
+ :public => true,
1425
+ :type => String,
1287
1426
  :dynamic_name => true,
1288
1427
  :allowed_from_server => false,
1289
- :description => 'If <code>true</code>, the agent won\'t measure the depth of Delayed Job queues.'
1428
+ :description => 'Controls auto-instrumentation of memcache-client gem for Memcache at start up. May be one of [auto|prepend|chain|disabled].'
1290
1429
  },
1291
- :disable_active_record_4 => {
1292
- :default => false,
1293
- :public => true,
1294
- :type => Boolean,
1430
+ :'instrumentation.mongo' => {
1431
+ :default => 'enabled',
1432
+ :documentation_default => 'enabled',
1433
+ :public => true,
1434
+ :type => String,
1295
1435
  :dynamic_name => true,
1296
1436
  :allowed_from_server => false,
1297
- :deprecated => true,
1298
- :description => 'Deprecated. ' \
1299
- 'For agent versions 6.3 or higher, ' \
1300
- 'use <a href="#disable_active_record_notifications"><code>' \
1301
- 'disable_active_record_notifications' \
1302
- '</code></a> instead.'
1303
- },
1304
- :disable_active_record_5 => {
1305
- :default => false,
1306
- :public => true,
1307
- :type => Boolean,
1437
+ :description => 'Controls auto-instrumentation of Mongo at start up. May be one of [enabled|disabled].'
1438
+ },
1439
+ :'instrumentation.net_http' => {
1440
+ :default => 'auto',
1441
+ :documentation_default => 'auto',
1442
+ :public => true,
1443
+ :type => String,
1308
1444
  :dynamic_name => true,
1309
1445
  :allowed_from_server => false,
1310
- :deprecated => true,
1311
- :description => 'Deprecated. ' \
1312
- 'For agent versions 6.3 or higher, ' \
1313
- 'use <a href="#disable_active_record_notifications"><code>' \
1314
- 'disable_active_record_notifications' \
1315
- '</code></a> instead.'
1446
+ :description => 'Controls auto-instrumentation of Net::HTTP at start up. May be one of [auto|prepend|chain|disabled].'
1316
1447
  },
1317
- :disable_active_record_notifications => {
1318
- :default => false,
1319
- :public => true,
1320
- :type => Boolean,
1448
+ :'instrumentation.puma_rack' => {
1449
+ :default => value_of(:'instrumentation.rack'),
1450
+ :documentation_default => 'auto',
1451
+ :public => true,
1452
+ :type => String,
1321
1453
  :dynamic_name => true,
1322
1454
  :allowed_from_server => false,
1323
- :description => 'If <code>true</code>, disables instrumentation for ActiveRecord 4, 5, and 6.'
1455
+ :description => 'Controls auto-instrumentation of Puma::Rack. When enabled, the agent hooks into the ' \
1456
+ '`to_app` method in Puma::Rack::Builder to find gems to instrument during ' \
1457
+ 'application startup. May be one of [auto|prepend|chain|disabled].'
1324
1458
  },
1325
- :disable_bunny => {
1326
- :default => false,
1327
- :public => true,
1328
- :type => Boolean,
1459
+ :'instrumentation.puma_rack_urlmap' => {
1460
+ :default => value_of(:'instrumentation.rack_urlmap'),
1461
+ :documentation_default => 'auto',
1462
+ :public => true,
1463
+ :type => String,
1329
1464
  :dynamic_name => true,
1330
1465
  :allowed_from_server => false,
1331
- :description => 'If <code>true</code>, disables instrumentation for the bunny gem.'
1466
+ :description => 'Controls auto-instrumentation of Puma::Rack::URLMap at start up. May be one of [auto|prepend|chain|disabled].'
1332
1467
  },
1333
- :disable_curb => {
1334
- :default => false,
1335
- :public => true,
1336
- :type => Boolean,
1468
+ :'instrumentation.rack' => {
1469
+ :default => 'auto',
1470
+ :documentation_default => 'auto',
1471
+ :public => true,
1472
+ :type => String,
1337
1473
  :dynamic_name => true,
1338
1474
  :allowed_from_server => false,
1339
- :description => 'If <code>true</code>, disables instrumentation for the curb gem.'
1475
+ :description => 'Controls auto-instrumentation of Rack. When enabled, the agent hooks into the ' \
1476
+ '`to_app` method in Rack::Builder to find gems to instrument during ' \
1477
+ 'application startup. May be one of [auto|prepend|chain|disabled].'
1340
1478
  },
1341
- :disable_excon => {
1342
- :default => false,
1343
- :public => true,
1344
- :type => Boolean,
1479
+ :'instrumentation.rack_urlmap' => {
1480
+ :default => 'auto',
1481
+ :documentation_default => 'auto',
1482
+ :public => true,
1483
+ :type => String,
1345
1484
  :dynamic_name => true,
1346
1485
  :allowed_from_server => false,
1347
- :description => 'If <code>true</code>, disables instrumentation for the excon gem.'
1486
+ :description => 'Controls auto-instrumentation of Rack::URLMap at start up. May be one of [auto|prepend|chain|disabled].'
1348
1487
  },
1349
- :disable_httpclient => {
1350
- :default => false,
1351
- :public => true,
1352
- :type => Boolean,
1488
+ :'instrumentation.rake' => {
1489
+ :default => 'auto',
1490
+ :public => true,
1491
+ :type => String,
1353
1492
  :dynamic_name => true,
1354
1493
  :allowed_from_server => false,
1355
- :description => 'If <code>true</code>, disables instrumentation for the httpclient gem.'
1494
+ :description => 'Controls auto-instrumentation of rake at start up. May be one of [auto|prepend|chain|disabled].'
1356
1495
  },
1357
- :disable_net_http => {
1358
- :default => false,
1359
- :public => true,
1360
- :type => Boolean,
1496
+ :'instrumentation.redis' => {
1497
+ :default => 'auto',
1498
+ :public => true,
1499
+ :type => String,
1361
1500
  :dynamic_name => true,
1362
1501
  :allowed_from_server => false,
1363
- :description => 'If <code>true</code>, disables instrumentation for Net::HTTP.'
1502
+ :description => 'Controls auto-instrumentation of Redis at start up. May be one of [auto|prepend|chain|disabled].'
1364
1503
  },
1365
- :disable_rack => {
1366
- :default => false,
1367
- :public => true,
1368
- :type => Boolean,
1504
+ :'instrumentation.resque' => {
1505
+ :default => 'auto',
1506
+ :documentation_default => 'auto',
1507
+ :public => true,
1508
+ :type => String,
1369
1509
  :dynamic_name => true,
1370
1510
  :allowed_from_server => false,
1371
- :description => 'If <code>true</code>, prevents the agent from hooking into the <code>to_app</code> method in Rack::Builder to find gems to instrument during application startup.'
1511
+ :description => 'Controls auto-instrumentation of resque at start up. May be one of [auto|prepend|chain|disabled].'
1372
1512
  },
1373
- :disable_rack_urlmap => {
1374
- :default => false,
1375
- :public => true,
1376
- :type => Boolean,
1513
+ :'instrumentation.sinatra' => {
1514
+ :default => 'auto',
1515
+ :public => true,
1516
+ :type => String,
1377
1517
  :dynamic_name => true,
1378
1518
  :allowed_from_server => false,
1379
- :description => 'If <code>true</code>, prevents the agent from hooking into Rack::URLMap to install middleware tracing.'
1519
+ :description => 'Controls auto-instrumentation of Sinatra at start up. May be one of [auto|prepend|chain|disabled].'
1380
1520
  },
1381
- :disable_puma_rack => {
1382
- :default => value_of(:disable_rack),
1383
- :public => true,
1384
- :type => Boolean,
1521
+ :'instrumentation.thread' => {
1522
+ :default => 'auto',
1523
+ :public => true,
1524
+ :type => String,
1385
1525
  :dynamic_name => true,
1386
1526
  :allowed_from_server => false,
1387
- :description => 'If <code>true</code>, prevents the agent from hooking into the <code>to_app</code> method in Puma::Rack::Builder to find gems to instrument during application startup.'
1527
+ :description => 'Controls auto-instrumentation of the Thread class at start up to allow the agent to correctly nest spans inside of an asynchronous transaction. This does not enable the agent to automatically trace all threads created (see `instrumentation.thread.tracing`). May be one of [auto|prepend|chain|disabled].'
1388
1528
  },
1389
- :disable_puma_rack_urlmap => {
1390
- :default => value_of(:disable_rack_urlmap),
1391
- :public => true,
1392
- :type => Boolean,
1393
- :dynamic_name => true,
1529
+ :'instrumentation.thread.tracing' => {
1530
+ :default => true,
1531
+ :public => true,
1532
+ :type => Boolean,
1394
1533
  :allowed_from_server => false,
1395
- :description => 'If <code>true</code>, prevents the agent from hooking into Puma::Rack::URLMap to install middleware tracing.'
1534
+ :description => 'Controls auto-instrumentation of the Thread class at start up to automatically add tracing to all Threads created in the application.'
1396
1535
  },
1397
- :disable_typhoeus => {
1398
- :default => false,
1399
- :public => true,
1400
- :type => Boolean,
1401
- :dynamic_name => true,
1536
+ :'thread_ids_enabled' => {
1537
+ :default => false,
1538
+ :public => false,
1539
+ :type => Boolean,
1402
1540
  :allowed_from_server => false,
1403
- :description => 'If <code>true</code>, the agent won\'t install instrumentation for the typhoeus gem.'
1541
+ :description => 'If enabled, will append the current Thread and Fiber object ids onto the segment names of segments created in Threads and concurrent-ruby'
1404
1542
  },
1405
- :disable_httprb => {
1406
- :default => false,
1407
- :public => true,
1408
- :type => Boolean,
1543
+ :'instrumentation.tilt' => {
1544
+ :default => 'auto',
1545
+ :public => true,
1546
+ :type => String,
1409
1547
  :dynamic_name => true,
1410
1548
  :allowed_from_server => false,
1411
- :description => 'If <code>true</code>, the agent won\'t install instrumentation for the http.rb gem.'
1549
+ :description => 'Controls auto-instrumentation of the Tilt template rendering library at start up. May be one of [auto|prepend|chain|disabled].'
1412
1550
  },
1413
- :disable_middleware_instrumentation => {
1414
- :default => false,
1415
- :public => true,
1416
- :type => Boolean,
1551
+ :'instrumentation.typhoeus' => {
1552
+ :default => 'auto',
1553
+ :documentation_default => 'auto',
1554
+ :public => true,
1555
+ :type => String,
1556
+ :dynamic_name => true,
1417
1557
  :allowed_from_server => false,
1418
- :description => 'If <code>true</code>, the agent won\'t wrap third-party middlewares in instrumentation (regardless of whether they are installed via Rack::Builder or Rails).'
1558
+ :description => 'Controls auto-instrumentation of Typhoeus at start up. May be one of [auto|prepend|chain|disabled].'
1419
1559
  },
1420
- :disable_rails_middleware => {
1421
- :default => false,
1422
- :public => false,
1423
- :type => Boolean,
1424
- :allowed_from_server => false,
1425
- :description => 'Internal name for controlling Rails 3+ middleware instrumentation'
1560
+ # Message tracer
1561
+ :'message_tracer.segment_parameters.enabled' => {
1562
+ :default => true,
1563
+ :public => true,
1564
+ :type => Boolean,
1565
+ :allowed_from_server => true,
1566
+ :description => 'If `true`, the agent will collect metadata about messages and attach them as segment parameters.'
1426
1567
  },
1427
- :'heroku.use_dyno_names' => {
1428
- :default => true,
1429
- :public => true,
1430
- :type => Boolean,
1431
- :allowed_from_server => false,
1432
- :description => 'If <code>true</code>, the agent uses Heroku dyno names as the hostname.'
1568
+ # Mongo
1569
+ :'mongo.capture_queries' => {
1570
+ :default => true,
1571
+ :public => true,
1572
+ :type => Boolean,
1573
+ :allowed_from_server => true,
1574
+ :description => 'If `true`, the agent captures Mongo queries in transaction traces.'
1433
1575
  },
1434
- :'heroku.dyno_name_prefixes_to_shorten' => {
1435
- :default => ['scheduler', 'run'],
1436
- :public => true,
1437
- :type => Array,
1438
- :allowed_from_server => false,
1439
- :transform => DefaultSource.method(:convert_to_list),
1440
- :description => 'Ordinarily the agent reports dyno names with a trailing dot and process ID (for example, <b>worker.3</b>). You can remove this trailing data by specifying the prefixes you want to report without trailing data (for example, <b>worker</b>).'
1576
+ :'mongo.obfuscate_queries' => {
1577
+ :default => true,
1578
+ :public => true,
1579
+ :type => Boolean,
1580
+ :allowed_from_server => true,
1581
+ :description => 'If `true`, the agent obfuscates Mongo queries in transaction traces.'
1441
1582
  },
1583
+ # Process host
1442
1584
  :'process_host.display_name' => {
1443
- :default => Proc.new{ NewRelic::Agent::Hostname.get },
1444
- :public => true,
1445
- :type => String,
1585
+ :default => proc { NewRelic::Agent::Hostname.get },
1586
+ :public => true,
1587
+ :type => String,
1446
1588
  :allowed_from_server => false,
1447
- :description => 'Specify a custom host name for <a href="https://docs.newrelic.com/docs/apm/new-relic-apm/maintenance/add-rename-remove-hosts#display_name">display in the New Relic UI</a>.'
1589
+ :description => 'Specify a custom host name for [display in the New Relic UI](/docs/apm/new-relic-apm/maintenance/add-rename-remove-hosts#display_name).'
1448
1590
  },
1449
- :labels => {
1450
- :default => '',
1451
- :public => true,
1452
- :type => String,
1591
+ # Rails
1592
+ :'defer_rails_initialization' => {
1593
+ :default => false,
1594
+ :public => true,
1595
+ :type => Boolean,
1596
+ :external => true, # this config is used directly from the ENV variables
1453
1597
  :allowed_from_server => false,
1454
- :description => 'A dictionary of <a href="/docs/data-analysis/user-interface-functions/labels-categories-organize-your-apps-servers">label names</a> and values that will be applied to the data sent from this agent. May also be expressed as a semicolon-delimited <code>;</code> string of colon-separated <code>:</code> pairs. For example, <code><var>Server</var>:<var>One</var>;<var>Data Center</var>:<var>Primary</var></code>.'
1455
- },
1456
- :aggressive_keepalive => {
1457
- :default => true,
1458
- :public => false,
1459
- :type => Boolean,
1460
- :allowed_from_server => true,
1461
- :description => 'If true, attempt to keep the TCP connection to the collector alive between harvests.'
1598
+ :description => <<-DESCRIPTION
1599
+ If `true`, when the agent is in an application using Ruby on Rails, it will start after `config/initializers` run.
1600
+
1601
+ <Callout variant="caution">
1602
+ This option may only be set by environment variable.
1603
+ </Callout>
1604
+ DESCRIPTION
1462
1605
  },
1463
- :keep_alive_timeout => {
1464
- :default => 60,
1465
- :public => false,
1466
- :type => Integer,
1467
- :allowed_from_server => true,
1468
- :description => 'Timeout for keep alive on TCP connection to collector if supported by Ruby version. Only used in conjunction when aggressive_keepalive is enabled.'
1606
+ # Rake
1607
+ :'rake.tasks' => {
1608
+ :default => [],
1609
+ :public => true,
1610
+ :type => Array,
1611
+ :allowed_from_server => false,
1612
+ :transform => DefaultSource.method(:convert_to_regexp_list),
1613
+ :description => 'Specify an Array of Rake tasks to automatically instrument. ' \
1614
+ 'This configuration option converts the Array to a RegEx list. If you\'d like ' \
1615
+ 'to allow all tasks by default, use `rake.tasks: [.+]`. No rake tasks will be ' \
1616
+ 'instrumented unless they\'re added to this list. For more information, ' \
1617
+ 'visit the (New Relic Rake Instrumentation docs)[/docs/apm/agents/ruby-agent/background-jobs/rake-instrumentation].'
1469
1618
  },
1470
- :ca_bundle_path => {
1471
- :default => nil,
1472
- :allow_nil => true,
1473
- :public => true,
1474
- :type => String,
1619
+ :'rake.connect_timeout' => {
1620
+ :default => 10,
1621
+ :public => true,
1622
+ :type => Integer,
1475
1623
  :allowed_from_server => false,
1476
- :description => "Manual override for the path to your local CA bundle. This CA bundle will be used to validate the SSL certificate presented by New Relic\'s data collection service."
1624
+ :description => 'Timeout for waiting on connect to complete before a rake task'
1477
1625
  },
1626
+ # Rules
1478
1627
  :'rules.ignore_url_regexes' => {
1479
- :default => [],
1480
- :public => true,
1481
- :type => Array,
1628
+ :default => [],
1629
+ :public => true,
1630
+ :type => Array,
1482
1631
  :allowed_from_server => true,
1483
- :transform => DefaultSource.method(:convert_to_regexp_list),
1484
- :description => 'Define transactions you want the agent to ignore, by specifying a list of patterns matching the URI you want to ignore.'
1632
+ :transform => DefaultSource.method(:convert_to_regexp_list),
1633
+ :description => 'Define transactions you want the agent to ignore, by specifying a list of patterns matching the URI you want to ignore. For more detail, see [the docs on ignoring specific transactions](/docs/agents/ruby-agent/api-guides/ignoring-specific-transactions/#config-ignoring).'
1485
1634
  },
1486
- :'synthetics.traces_limit' => {
1487
- :default => 20,
1488
- :public => false,
1489
- :type => Integer,
1635
+ # Slow SQL
1636
+ :'slow_sql.enabled' => {
1637
+ :default => value_of(:'transaction_tracer.enabled'),
1638
+ :documentation_default => true,
1639
+ :public => true,
1640
+ :type => Boolean,
1490
1641
  :allowed_from_server => true,
1491
- :description => 'Maximum number of synthetics transaction traces to hold for a given harvest'
1642
+ :description => 'If `true`, the agent collects [slow SQL queries](/docs/apm/applications-menu/monitoring/viewing-slow-query-details).'
1492
1643
  },
1493
- :'synthetics.events_limit' => {
1494
- :default => 200,
1495
- :public => false,
1496
- :type => Integer,
1644
+ :'slow_sql.explain_threshold' => {
1645
+ :default => value_of(:'transaction_tracer.explain_threshold'),
1646
+ :documentation_default => 0.5,
1647
+ :public => true,
1648
+ :type => Float,
1497
1649
  :allowed_from_server => true,
1498
- :description => 'Maximum number of synthetics transaction events to hold for a given harvest'
1650
+ :description => 'Specify a threshold in seconds. The agent collects [slow SQL queries](/docs/apm/applications-menu/monitoring/viewing-slow-query-details) and explain plans that exceed this threshold.'
1499
1651
  },
1500
- :'custom_insights_events.enabled' => {
1501
- :default => true,
1502
- :public => true,
1503
- :type => Boolean,
1652
+ :'slow_sql.explain_enabled' => {
1653
+ :default => value_of(:'transaction_tracer.explain_enabled'),
1654
+ :documentation_default => true,
1655
+ :public => true,
1656
+ :type => Boolean,
1504
1657
  :allowed_from_server => true,
1505
- :description => 'If <code>true</code>, the agent captures <a href="/docs/insights/new-relic-insights/adding-querying-data/inserting-custom-events-new-relic-apm-agents">New Relic Insights custom events</a>.'
1658
+ :description => 'If `true`, the agent collects explain plans in slow SQL queries. If this setting is omitted, the [`transaction_tracer.explain_enabled`](#transaction_tracer-explain_enabled) setting will be applied as the default setting for explain plans in slow SQL as well.'
1506
1659
  },
1507
- :'custom_insights_events.max_samples_stored' => {
1508
- :default => 1000,
1509
- :public => true,
1510
- :type => Integer,
1660
+ :'slow_sql.record_sql' => {
1661
+ :default => value_of(:'transaction_tracer.record_sql'),
1662
+ :documentation_default => 'obfuscated',
1663
+ :public => true,
1664
+ :type => String,
1511
1665
  :allowed_from_server => true,
1512
- :description => 'Specify a maximum number of custom Insights events to buffer in memory at a time.',
1513
- :dynamic_name => true
1666
+ :description => 'Defines an obfuscation level for slow SQL queries. Valid options are `obfuscated`, `raw`, or `none`).'
1514
1667
  },
1515
- :disable_grape_instrumentation => {
1516
- :default => false,
1517
- :public => false,
1518
- :type => Boolean,
1519
- :allowed_from_server => false,
1520
- :description => 'If <code>true</code>, the agent won\'t install Grape instrumentation.'
1668
+ :'slow_sql.use_longer_sql_id' => {
1669
+ :default => false,
1670
+ :public => true,
1671
+ :type => Boolean,
1672
+ :allowed_from_server => true,
1673
+ :description => 'Generate a longer sql_id for slow SQL traces. sql_id is used for aggregation of similar queries.'
1521
1674
  },
1522
- :disable_grape => {
1523
- :default => false,
1524
- :public => true,
1525
- :type => Boolean,
1526
- :allowed_from_server => false,
1527
- :description => 'If <code>true</code>, the agent won\'t install Grape instrumentation.'
1675
+ # Span events
1676
+ :'span_events.enabled' => {
1677
+ :default => true,
1678
+ :public => true,
1679
+ :type => Boolean,
1680
+ :allowed_from_server => true,
1681
+ :description => 'If `true`, enables span event sampling.'
1528
1682
  },
1529
- :'attributes.enabled' => {
1530
- :default => true,
1531
- :public => true,
1532
- :type => Boolean,
1683
+ :'span_events.queue_size' => {
1684
+ :default => 10_000,
1685
+ :public => true,
1686
+ :type => Integer,
1533
1687
  :allowed_from_server => false,
1534
- :description => 'If <code>true</code>, enables capture of attributes for all destinations.'
1688
+ :external => :infinite_tracing,
1689
+ :description => 'Sets the maximum number of span events to buffer when streaming to the trace observer.'
1535
1690
  },
1536
- :'transaction_tracer.attributes.enabled' => {
1537
- :default => value_of(:'transaction_tracer.capture_attributes'),
1538
- :public => true,
1539
- :type => Boolean,
1540
- :allowed_from_server => false,
1541
- :description => 'If <code>true</code>, the agent captures attributes from transaction traces.'
1691
+ :'span_events.max_samples_stored' => {
1692
+ :default => 2000,
1693
+ :public => true,
1694
+ :type => Integer,
1695
+ :allowed_from_server => true,
1696
+ :description => 'Defines the maximum number of span events reported from a single harvest. Any Integer between 1 and 10000 is valid.'
1542
1697
  },
1543
- :'transaction_events.attributes.enabled' => {
1544
- :default => value_of(:'analytics_events.capture_attributes'),
1545
- :public => true,
1546
- :type => Boolean,
1698
+ # Strip exception messages
1699
+ :'strip_exception_messages.enabled' => {
1700
+ :default => value_of(:high_security),
1701
+ :documentation_default => false,
1702
+ :public => true,
1703
+ :type => Boolean,
1547
1704
  :allowed_from_server => false,
1548
- :description => 'If <code>true</code>, the agent captures attributes from transaction events.'
1705
+ :description => 'If true, the agent strips messages from all exceptions except those in the [allowlist](#strip_exception_messages-allowlist). Enabled automatically in [high security mode](/docs/accounts-partnerships/accounts/security/high-security).'
1549
1706
  },
1550
- :'error_collector.attributes.enabled' => {
1551
- :default => value_of(:'error_collector.capture_attributes'),
1552
- :public => true,
1553
- :type => Boolean,
1707
+ :'strip_exception_messages.allowed_classes' => {
1708
+ :default => '',
1709
+ :public => true,
1710
+ :type => String,
1554
1711
  :allowed_from_server => false,
1555
- :description => 'If <code>true</code>, the agent captures attributes from error collection.'
1712
+ :transform => DefaultSource.method(:convert_to_constant_list),
1713
+ :description => 'Specify a list of exceptions you do not want the agent to strip when [strip_exception_messages](#strip_exception_messages-enabled) is `true`. Separate exceptions with a comma. For example, `"ImportantException,PreserveMessageException"`.'
1556
1714
  },
1557
- :'browser_monitoring.attributes.enabled' => {
1558
- :default => value_of(:'browser_monitoring.capture_attributes'),
1559
- :public => true,
1560
- :type => Boolean,
1561
- :allowed_from_server => false,
1562
- :description => 'If <code>true</code>, the agent captures attributes from browser monitoring.'
1715
+ # Thread profiler
1716
+ :'thread_profiler.enabled' => {
1717
+ :default => DefaultSource.thread_profiler_enabled,
1718
+ :documentation_default => false,
1719
+ :public => true,
1720
+ :type => Boolean,
1721
+ :allowed_from_server => true,
1722
+ :description => 'If `true`, enables use of the [thread profiler](/docs/apm/applications-menu/events/thread-profiler-tool).'
1563
1723
  },
1564
- :'span_events.attributes.enabled' => {
1565
- :default => true,
1566
- :public => true,
1567
- :type => Boolean,
1724
+ # Utilization
1725
+ :'utilization.detect_aws' => {
1726
+ :default => true,
1727
+ :public => true,
1728
+ :type => Boolean,
1568
1729
  :allowed_from_server => false,
1569
- :description => 'If <code>true</code>, the agent captures attributes on span events.'
1730
+ :dynamic_name => true,
1731
+ :description => 'If `true`, the agent automatically detects that it is running in an AWS environment.'
1570
1732
  },
1571
- :'transaction_segments.attributes.enabled' => {
1572
- :default => true,
1573
- :public => true,
1574
- :type => Boolean,
1733
+ :'utilization.detect_azure' => {
1734
+ :default => true,
1735
+ :public => true,
1736
+ :type => Boolean,
1575
1737
  :allowed_from_server => false,
1576
- :description => 'If <code>true</code>, the agent captures attributes on transaction segments.'
1738
+ :dynamic_name => true,
1739
+ :description => 'If `true`, the agent automatically detects that it is running in an Azure environment.'
1577
1740
  },
1578
- :'attributes.exclude' => {
1579
- :default => [],
1580
- :public => true,
1581
- :type => Array,
1741
+ :'utilization.detect_docker' => {
1742
+ :default => true,
1743
+ :public => true,
1744
+ :type => Boolean,
1582
1745
  :allowed_from_server => false,
1583
- :transform => DefaultSource.method(:convert_to_list),
1584
- :description => 'Prefix of attributes to exclude from all destinations. Allows <code>*</code> as wildcard at end.'
1746
+ :description => 'If `true`, the agent automatically detects that it is running in Docker.'
1585
1747
  },
1586
- :'transaction_tracer.attributes.exclude' => {
1587
- :default => [],
1588
- :public => true,
1589
- :type => Array,
1748
+ :'utilization.detect_gcp' => {
1749
+ :default => true,
1750
+ :public => true,
1751
+ :type => Boolean,
1590
1752
  :allowed_from_server => false,
1591
- :transform => DefaultSource.method(:convert_to_list),
1592
- :description => 'Prefix of attributes to exclude from transaction traces. Allows <code>*</code> as wildcard at end.'
1753
+ :dynamic_name => true,
1754
+ :description => 'If `true`, the agent automatically detects that it is running in an Google Cloud Platform environment.'
1593
1755
  },
1594
- :'transaction_events.attributes.exclude' => {
1595
- :default => [],
1596
- :public => true,
1597
- :type => Array,
1756
+ :'utilization.detect_kubernetes' => {
1757
+ :default => true,
1758
+ :public => true,
1759
+ :type => Boolean,
1598
1760
  :allowed_from_server => false,
1599
- :transform => DefaultSource.method(:convert_to_list),
1600
- :description => 'Prefix of attributes to exclude from transaction events. Allows <code>*</code> as wildcard at end.'
1761
+ :description => 'If `true`, the agent automatically detects that it is running in Kubernetes.'
1601
1762
  },
1602
- :'error_collector.attributes.exclude' => {
1603
- :default => [],
1604
- :public => true,
1605
- :type => Array,
1763
+ :'utilization.detect_pcf' => {
1764
+ :default => true,
1765
+ :public => true,
1766
+ :type => Boolean,
1606
1767
  :allowed_from_server => false,
1607
- :transform => DefaultSource.method(:convert_to_list),
1608
- :description => 'Prefix of attributes to exclude from error collection. Allows <code>*</code> as wildcard at end.'
1768
+ :dynamic_name => true,
1769
+ :description => 'If `true`, the agent automatically detects that it is running in a Pivotal Cloud Foundry environment.'
1609
1770
  },
1610
- :'browser_monitoring.attributes.exclude' => {
1611
- :default => [],
1612
- :public => true,
1613
- :type => Array,
1614
- :allowed_from_server => false,
1615
- :transform => DefaultSource.method(:convert_to_list),
1616
- :description => 'Prefix of attributes to exclude from browser monitoring. Allows <code>*</code> as wildcard at end.'
1771
+ # Private
1772
+ :account_id => {
1773
+ :default => nil,
1774
+ :allow_nil => true,
1775
+ :public => false,
1776
+ :type => String,
1777
+ :allowed_from_server => true,
1778
+ :description => 'The account id associated with your application.'
1617
1779
  },
1618
- :'span_events.attributes.exclude' => {
1619
- :default => [],
1620
- :public => true,
1621
- :type => Array,
1622
- :allowed_from_server => false,
1623
- :transform => DefaultSource.method(:convert_to_list),
1624
- :description => 'Prefix of attributes to exclude from span events. Allows <code>*</code> as wildcard at end.'
1780
+ :aggressive_keepalive => {
1781
+ :default => true,
1782
+ :public => false,
1783
+ :type => Boolean,
1784
+ :allowed_from_server => true,
1785
+ :description => 'If true, attempt to keep the TCP connection to the collector alive between harvests.'
1625
1786
  },
1626
- :'transaction_segments.attributes.exclude' => {
1627
- :default => [],
1628
- :public => true,
1629
- :type => Array,
1787
+ :api_host => {
1788
+ :default => DefaultSource.api_host,
1789
+ :public => false,
1790
+ :type => String,
1630
1791
  :allowed_from_server => false,
1631
- :transform => DefaultSource.method(:convert_to_list),
1632
- :description => 'Prefix of attributes to exclude from transaction segments. Allows <code>*</code> as wildcard at end.'
1792
+ :description => 'API host for New Relic.'
1633
1793
  },
1634
- :'attributes.include' => {
1635
- :default => [],
1636
- :public => true,
1637
- :type => Array,
1794
+ :api_port => {
1795
+ :default => value_of(:port),
1796
+ :public => false,
1797
+ :type => Integer,
1638
1798
  :allowed_from_server => false,
1639
- :transform => DefaultSource.method(:convert_to_list),
1640
- :description => 'Prefix of attributes to include in all destinations. Allows <code>*</code> as wildcard at end.'
1799
+ :description => 'Port for the New Relic API host.'
1641
1800
  },
1642
- :'transaction_tracer.attributes.include' => {
1643
- :default => [],
1644
- :public => true,
1645
- :type => Array,
1646
- :allowed_from_server => false,
1647
- :transform => DefaultSource.method(:convert_to_list),
1648
- :description => 'Prefix of attributes to include in transaction traces. Allows <code>*</code> as wildcard at end.'
1801
+ :application_id => {
1802
+ :default => '',
1803
+ :public => false,
1804
+ :type => String,
1805
+ :allowed_from_server => true,
1806
+ :description => 'Application ID for real user monitoring.'
1649
1807
  },
1650
- :'transaction_events.attributes.include' => {
1651
- :default => [],
1652
- :public => true,
1653
- :type => Array,
1654
- :allowed_from_server => false,
1655
- :transform => DefaultSource.method(:convert_to_list),
1656
- :description => 'Prefix of attributes to include in transaction events. Allows <code>*</code> as wildcard at end.'
1808
+ :beacon => {
1809
+ :default => '',
1810
+ :public => false,
1811
+ :type => String,
1812
+ :allowed_from_server => true,
1813
+ :description => 'Beacon for real user monitoring.'
1657
1814
  },
1658
- :'error_collector.attributes.include' => {
1659
- :default => [],
1660
- :public => true,
1661
- :type => Array,
1662
- :allowed_from_server => false,
1663
- :transform => DefaultSource.method(:convert_to_list),
1664
- :description => 'Prefix of attributes to include in error collection. Allows <code>*</code> as wildcard at end.'
1815
+ :browser_key => {
1816
+ :default => '',
1817
+ :public => false,
1818
+ :type => String,
1819
+ :allowed_from_server => true,
1820
+ :description => 'Real user monitoring license key for the browser timing header.'
1665
1821
  },
1666
- :'browser_monitoring.attributes.include' => {
1667
- :default => [],
1668
- :public => true,
1669
- :type => Array,
1822
+ :'browser_monitoring.loader' => {
1823
+ :default => 'rum',
1824
+ :public => false,
1825
+ :type => String,
1826
+ :allowed_from_server => true,
1827
+ :description => 'Type of JavaScript agent loader to use for browser monitoring instrumentation.'
1828
+ },
1829
+ :'browser_monitoring.loader_version' => {
1830
+ :default => '',
1831
+ :public => false,
1832
+ :type => String,
1833
+ :allowed_from_server => true,
1834
+ :description => 'Version of JavaScript agent loader (returned from the New Relic [collector](/docs/apm/new-relic-apm/getting-started/glossary#collector).)'
1835
+ },
1836
+ :'browser_monitoring.debug' => {
1837
+ :default => false,
1838
+ :public => false,
1839
+ :type => Boolean,
1840
+ :allowed_from_server => true,
1841
+ :description => 'Enable or disable debugging version of JavaScript agent loader for browser monitoring instrumentation.'
1842
+ },
1843
+ :'browser_monitoring.ssl_for_http' => {
1844
+ :default => nil,
1845
+ :allow_nil => true,
1846
+ :public => false,
1847
+ :type => Boolean,
1848
+ :allowed_from_server => true,
1849
+ :description => 'Enable or disable HTTPS instrumentation by JavaScript agent on HTTP pages.'
1850
+ },
1851
+ :compressed_content_encoding => {
1852
+ :default => 'gzip',
1853
+ :public => false,
1854
+ :type => String,
1670
1855
  :allowed_from_server => false,
1671
- :transform => DefaultSource.method(:convert_to_list),
1672
- :description => 'Prefix of attributes to include in browser monitoring. Allows <code>*</code> as wildcard at end.'
1856
+ :description => 'Encoding to use if data needs to be compressed. The options are deflate and gzip.'
1673
1857
  },
1674
- :'span_events.attributes.include' => {
1675
- :default => [],
1676
- :public => true,
1677
- :type => Array,
1858
+ :config_search_paths => {
1859
+ :default => DefaultSource.config_search_paths,
1860
+ :public => false,
1861
+ :type => Array,
1678
1862
  :allowed_from_server => false,
1679
- :transform => DefaultSource.method(:convert_to_list),
1680
- :description => 'Prefix of attributes to include on span events. Allows <code>*</code> as wildcard at end.'
1863
+ :description => "An array of candidate locations for the agent's configuration file."
1681
1864
  },
1682
- :'transaction_segments.attributes.include' => {
1683
- :default => [],
1684
- :public => true,
1685
- :type => Array,
1865
+ :cross_process_id => {
1866
+ :default => '',
1867
+ :public => false,
1868
+ :type => String,
1869
+ :allowed_from_server => true,
1870
+ :description => 'Cross process ID for cross-application tracing.'
1871
+ },
1872
+ :data_report_period => {
1873
+ :default => 60,
1874
+ :public => false,
1875
+ :type => Integer,
1876
+ :allowed_from_server => true,
1877
+ :description => 'Number of seconds betwixt connections to the New Relic data collection service.'
1878
+ },
1879
+ :dispatcher => {
1880
+ :default => DefaultSource.dispatcher,
1881
+ :public => false,
1882
+ :type => Symbol,
1686
1883
  :allowed_from_server => false,
1687
- :transform => DefaultSource.method(:convert_to_list),
1688
- :description => 'Prefix of attributes to include on transaction segments. Allows <code>*</code> as wildcard at end.'
1884
+ :description => 'Autodetected application component that reports metrics to New Relic.'
1689
1885
  },
1690
- :'custom_attributes.enabled' => {
1691
- :default => true,
1692
- :public => true,
1693
- :type => Boolean,
1886
+ :disable_harvest_thread => {
1887
+ :default => false,
1888
+ :public => false,
1889
+ :type => Boolean,
1694
1890
  :allowed_from_server => false,
1695
- :description => 'If <code>false</code>, custom attributes will not be sent on Insights events.'
1891
+ :description => 'Enable or disable the harvest thread.'
1696
1892
  },
1697
- :'utilization.detect_aws' => {
1698
- :default => true,
1699
- :public => true,
1700
- :type => Boolean,
1893
+ :disable_rails_middleware => {
1894
+ :default => false,
1895
+ :public => false,
1896
+ :type => Boolean,
1701
1897
  :allowed_from_server => false,
1702
- :dynamic_name => true,
1703
- :description => 'If <code>true</code>, the agent automatically detects that it is running in an AWS environment.'
1898
+ :description => 'Internal name for controlling Rails 3+ middleware instrumentation'
1704
1899
  },
1705
- :'utilization.detect_azure' => {
1706
- :default => true,
1707
- :public => true,
1708
- :type => Boolean,
1900
+ :enabled => {
1901
+ :default => true,
1902
+ :public => false,
1903
+ :type => Boolean,
1904
+ :aliases => [:enable],
1709
1905
  :allowed_from_server => false,
1906
+ :description => 'Enable or disable the agent.'
1907
+ },
1908
+ :encoding_key => {
1909
+ :default => '',
1910
+ :public => false,
1911
+ :type => String,
1912
+ :allowed_from_server => true,
1913
+ :description => 'Encoding key for cross-application tracing.'
1914
+ },
1915
+ :entity_guid => {
1916
+ :default => nil,
1917
+ :allow_nil => true,
1918
+ :public => false,
1919
+ :type => String,
1920
+ :allowed_from_server => true,
1921
+ :description => 'The [Entity GUID](/attribute-dictionary/span/entityguid) for the entity running your agent.'
1922
+ },
1923
+ :error_beacon => {
1924
+ :default => '',
1925
+ :public => false,
1926
+ :type => String,
1927
+ :allowed_from_server => true,
1928
+ :description => 'Error beacon for real user monitoring.'
1929
+ },
1930
+ :event_report_period => {
1931
+ :default => 60,
1932
+ :public => false,
1933
+ :type => Integer,
1934
+ :allowed_from_server => true,
1935
+ :description => 'Number of seconds betwixt connections to the New Relic event collection services.'
1936
+ },
1937
+ :'event_report_period.transaction_event_data' => {
1938
+ :default => 60,
1939
+ :public => false,
1940
+ :type => Integer,
1710
1941
  :dynamic_name => true,
1711
- :description => 'If <code>true</code>, the agent automatically detects that it is running in an Azure environment.'
1942
+ :allowed_from_server => true,
1943
+ :description => 'Number of seconds betwixt connections to the New Relic transaction event collection services.'
1712
1944
  },
1713
- :'utilization.detect_gcp' => {
1714
- :default => true,
1715
- :public => true,
1716
- :type => Boolean,
1717
- :allowed_from_server => false,
1945
+ :'event_report_period.custom_event_data' => {
1946
+ :default => 60,
1947
+ :public => false,
1948
+ :type => Integer,
1718
1949
  :dynamic_name => true,
1719
- :description => 'If <code>true</code>, the agent automatically detects that it is running in an Google Cloud Platform environment.'
1950
+ :allowed_from_server => true,
1951
+ :description => 'Number of seconds betwixt connections to the New Relic custom event collection services.'
1720
1952
  },
1721
- :'utilization.detect_pcf' => {
1722
- :default => true,
1723
- :public => true,
1724
- :type => Boolean,
1725
- :allowed_from_server => false,
1953
+ :'event_report_period.error_event_data' => {
1954
+ :default => 60,
1955
+ :public => false,
1956
+ :type => Integer,
1726
1957
  :dynamic_name => true,
1727
- :description => 'If <code>true</code>, the agent automatically detects that it is running in a Pivotal Cloud Foundry environment.'
1958
+ :allowed_from_server => true,
1959
+ :description => 'Number of seconds betwixt connections to the New Relic error event collection services.'
1728
1960
  },
1729
- :'utilization.detect_docker' => {
1730
- :default => true,
1731
- :public => true,
1732
- :type => Boolean,
1733
- :allowed_from_server => false,
1734
- :description => 'If <code>true</code>, the agent automatically detects that it is running in Docker.'
1961
+ :'event_report_period.log_event_data' => {
1962
+ :default => 60,
1963
+ :public => false,
1964
+ :type => Integer,
1965
+ :dynamic_name => true,
1966
+ :allowed_from_server => true,
1967
+ :description => 'Number of seconds betwixt connections to the New Relic log event collection services.'
1735
1968
  },
1736
- :'utilization.detect_kubernetes' => {
1737
- :default => true,
1738
- :public => true,
1739
- :type => Boolean,
1740
- :allowed_from_server => false,
1741
- :description => 'If <code>true</code>, the agent automatically detects that it is running in Kubernetes.'
1969
+ :'event_report_period.span_event_data' => {
1970
+ :default => 60,
1971
+ :public => false,
1972
+ :type => Integer,
1973
+ :dynamic_name => true,
1974
+ :allowed_from_server => true,
1975
+ :description => 'Number of seconds betwixt connections to the New Relic span event collection services.'
1742
1976
  },
1743
- :'utilization.billing_hostname' => {
1744
- :default => nil,
1745
- :allow_nil => true,
1746
- :public => false,
1747
- :type => String,
1977
+ :force_reconnect => {
1978
+ :default => false,
1979
+ :public => false,
1980
+ :type => Boolean,
1748
1981
  :allowed_from_server => false,
1749
- :description => 'The configured server name by a customer.'
1982
+ :description => 'Force a new connection to the server before running the worker loop. Creates a separate agent run and is recorded as a separate instance by the New Relic data collection service.'
1750
1983
  },
1751
- :'utilization.logical_processors' => {
1752
- :default => nil,
1753
- :allow_nil => true,
1754
- :public => false,
1755
- :type => Integer,
1984
+ :framework => {
1985
+ :default => DefaultSource.framework,
1986
+ :public => false,
1987
+ :type => Symbol,
1756
1988
  :allowed_from_server => false,
1757
- :description => 'The total number of hyper-threaded execution contexts available.'
1989
+ :description => 'Autodetected application framework used to enable framework-specific functionality.'
1758
1990
  },
1759
- :'utilization.total_ram_mib' => {
1760
- :default => nil,
1761
- :allow_nil => true,
1762
- :public => false,
1763
- :type => Integer,
1991
+ :host => {
1992
+ :default => DefaultSource.host,
1993
+ :public => false,
1994
+ :type => String,
1764
1995
  :allowed_from_server => false,
1765
- :description => 'This value represents the total amount of memory available to the host (not the process), in mebibytes (1024 squared or 1,048,576 bytes).'
1996
+ :description => 'URI for the New Relic data collection service.'
1766
1997
  },
1767
- :'datastore_tracer.instance_reporting.enabled' => {
1768
- :default => true,
1769
- :public => true,
1770
- :type => Boolean,
1998
+ :'infinite_tracing.batching' => {
1999
+ :default => true,
2000
+ :public => true,
2001
+ :type => Boolean,
1771
2002
  :allowed_from_server => false,
1772
- :description => 'If <code>false</code>, the agent will not report datastore instance metrics, nor add <code>host</code> or <code>port_path_or_id</code> parameters to transaction or slow sql traces.'
2003
+ :external => :infinite_tracing,
2004
+ :description => "If `true` (the default), data sent to the trace observer is batched\ninstead of sending " \
2005
+ 'each span individually.'
1773
2006
  },
1774
- :'datastore_tracer.database_name_reporting.enabled' => {
1775
- :default => true,
1776
- :public => true,
1777
- :type => Boolean,
2007
+ :'infinite_tracing.compression_level' => {
2008
+ :default => :high,
2009
+ :public => true,
2010
+ :type => Symbol,
1778
2011
  :allowed_from_server => false,
1779
- :description => 'If <code>false</code>, the agent will not add <code>database_name</code> parameter to transaction or slow sql traces.'
2012
+ :external => :infinite_tracing,
2013
+ :description => "Configure the compression level for data sent to the trace observer\nMay be one of " \
2014
+ "[none|low|medium|high]\n'high' is the default. Set the level to 'none' to disable compression"
1780
2015
  },
1781
- :'clear_transaction_state_after_fork' => {
1782
- :default => false,
1783
- :public => true,
1784
- :type => Boolean,
1785
- :allowed_from_server => false,
1786
- :description => 'If <code>true</code>, the agent will clear <code>Tracer::State</code> in <code>Agent.drop_buffered_data</code>.'
2016
+ :js_agent_file => {
2017
+ :default => '',
2018
+ :public => false,
2019
+ :type => String,
2020
+ :allowed_from_server => true,
2021
+ :description => 'JavaScript agent file for real user monitoring.'
1787
2022
  },
1788
- :account_id => {
1789
- :default => nil,
1790
- :allow_nil => true,
2023
+ :js_agent_loader => {
2024
+ :default => '',
1791
2025
  :public => false,
1792
2026
  :type => String,
1793
2027
  :allowed_from_server => true,
1794
- :description => 'The account id associated with this application.'
2028
+ :description => 'JavaScript agent loader content.'
2029
+ },
2030
+ :keep_alive_timeout => {
2031
+ :default => 60,
2032
+ :public => false,
2033
+ :type => Integer,
2034
+ :allowed_from_server => true,
2035
+ :description => 'Timeout for keep alive on TCP connection to collector if supported by Ruby version. Only used in conjunction when aggressive_keepalive is enabled.'
2036
+ },
2037
+ :max_payload_size_in_bytes => {
2038
+ :default => 1000000,
2039
+ :public => false,
2040
+ :type => Integer,
2041
+ :allowed_from_server => true,
2042
+ :description => 'Maximum number of bytes to send to the New Relic data collection service.'
2043
+ },
2044
+ :normalize_json_string_encodings => {
2045
+ :default => true,
2046
+ :public => false,
2047
+ :type => Boolean,
2048
+ :allowed_from_server => false,
2049
+ :description => 'Controls whether to normalize string encodings prior to serializing data for the collector to JSON.'
2050
+ },
2051
+ :port => {
2052
+ :default => 443,
2053
+ :public => false,
2054
+ :type => Integer,
2055
+ :allowed_from_server => false,
2056
+ :description => 'Port for the New Relic data collection service.'
1795
2057
  },
1796
2058
  :primary_application_id => {
1797
2059
  :default => nil,
@@ -1799,22 +2061,42 @@ module NewRelic
1799
2061
  :public => false,
1800
2062
  :type => String,
1801
2063
  :allowed_from_server => true,
1802
- :description => 'The primary id associated with this application.'
2064
+ :description => 'The primary id associated with your application.'
1803
2065
  },
1804
- :'distributed_tracing.enabled' => {
1805
- :default => false,
1806
- :public => true,
1807
- :type => Boolean,
2066
+ :put_for_data_send => {
2067
+ :default => false,
2068
+ :public => false,
2069
+ :type => Boolean,
1808
2070
  :allowed_from_server => false,
1809
- :description => 'Distributed tracing lets you see the path that a request takes through your distributed system. Enabling distributed tracing changes the behavior of some New Relic features, so carefully consult the <a href="https://docs.newrelic.com/docs/transition-guide-distributed-tracing">transition guide</a> before you enable this feature.'
2071
+ :description => 'Use HTTP PUT requests instead of POST.'
1810
2072
  },
1811
- :trusted_account_key => {
1812
- :default => nil,
1813
- :allow_nil => true,
2073
+ :report_instance_busy => {
2074
+ :default => true,
1814
2075
  :public => false,
1815
- :type => String,
2076
+ :type => Boolean,
2077
+ :allowed_from_server => false,
2078
+ :description => 'Enable or disable transmission of metrics recording the percentage of time application instances spend servicing requests (duty cycle metrics).'
2079
+ },
2080
+ :restart_thread_in_children => {
2081
+ :default => true,
2082
+ :public => false,
2083
+ :type => Boolean,
2084
+ :allowed_from_server => false,
2085
+ :description => 'Controls whether to check on running a transaction whether to respawn the harvest thread.'
2086
+ },
2087
+ :'resque.use_ruby_dns' => {
2088
+ :default => true,
2089
+ :public => false,
2090
+ :type => Boolean,
2091
+ :allowed_from_server => false,
2092
+ :description => 'Replace the libc DNS resolver with the all Ruby resolver Resolv'
2093
+ },
2094
+ :'rum.enabled' => {
2095
+ :default => true,
2096
+ :public => false,
2097
+ :type => Boolean,
1816
2098
  :allowed_from_server => true,
1817
- :description => 'A shared key to validate that a distributed trace payload came from a trusted account.'
2099
+ :description => 'Enable or disable page load timing (sometimes referred to as real user monitoring or RUM).'
1818
2100
  },
1819
2101
  :sampling_target => {
1820
2102
  :default => 10,
@@ -1830,19 +2112,93 @@ module NewRelic
1830
2112
  :allowed_from_server => true,
1831
2113
  :description => 'The period during which a target number of transactions should be marked as sampled.'
1832
2114
  },
1833
- :'span_events.enabled' => {
2115
+ :send_environment_info => {
1834
2116
  :default => true,
1835
2117
  :public => false,
1836
2118
  :type => Boolean,
2119
+ :allowed_from_server => false,
2120
+ :description => 'Enable or disable transmission of application environment information to the New Relic data collection service.'
2121
+ },
2122
+ :simple_compression => {
2123
+ :default => false,
2124
+ :public => false,
2125
+ :type => Boolean,
2126
+ :allowed_from_server => false,
2127
+ :description => 'When enabled the agent will compress payloads destined for the collector, but will not pre-compress parts of the payload.'
2128
+ },
2129
+ :skip_ar_instrumentation => {
2130
+ :default => false,
2131
+ :public => false,
2132
+ :type => Boolean,
2133
+ :allowed_from_server => false,
2134
+ :description => 'Enable or disable active record instrumentation.'
2135
+ },
2136
+ :'synthetics.traces_limit' => {
2137
+ :default => 20,
2138
+ :public => false,
2139
+ :type => Integer,
1837
2140
  :allowed_from_server => true,
1838
- :description => 'If <code>true</code>, enables span event sampling.'
2141
+ :description => 'Maximum number of synthetics transaction traces to hold for a given harvest'
1839
2142
  },
1840
- :'span_events.max_samples_stored' => {
1841
- :default => 1000,
2143
+ :'synthetics.events_limit' => {
2144
+ :default => 200,
1842
2145
  :public => false,
1843
2146
  :type => Integer,
1844
2147
  :allowed_from_server => true,
1845
- :description => 'Defines the maximum number of span events reported from a single harvest.'
2148
+ :description => 'Maximum number of synthetics transaction events to hold for a given harvest'
2149
+ },
2150
+ :test_mode => {
2151
+ :default => false,
2152
+ :public => false,
2153
+ :type => Boolean,
2154
+ :allowed_from_server => false,
2155
+ :description => 'Used in tests for the agent to start up, but not connect to the collector. Formerly used `developer_mode` in test config for this purpose.'
2156
+ },
2157
+ :'thread_profiler.max_profile_overhead' => {
2158
+ :default => 0.05,
2159
+ :public => false,
2160
+ :type => Float,
2161
+ :allowed_from_server => true,
2162
+ :description => 'Maximum overhead percentage for thread profiling before agent reduces polling frequency'
2163
+ },
2164
+ :trusted_account_ids => {
2165
+ :default => [],
2166
+ :public => false,
2167
+ :type => Array,
2168
+ :allowed_from_server => true,
2169
+ :description => 'List of trusted New Relic account IDs for the purposes of cross-application tracing. Inbound requests from applications including cross-application headers that do not come from an account in this list will be ignored.'
2170
+ },
2171
+ :trusted_account_key => {
2172
+ :default => nil,
2173
+ :allow_nil => true,
2174
+ :public => false,
2175
+ :type => String,
2176
+ :allowed_from_server => true,
2177
+ :description => 'A shared key to validate that a distributed trace payload came from a trusted account.'
2178
+ },
2179
+ :'utilization.billing_hostname' => {
2180
+ :default => nil,
2181
+ :allow_nil => true,
2182
+ :public => false,
2183
+ :type => String,
2184
+ :allowed_from_server => false,
2185
+ :description => 'The configured server name by a customer.'
2186
+ },
2187
+ :'utilization.logical_processors' => {
2188
+ :default => nil,
2189
+ :allow_nil => true,
2190
+ :public => false,
2191
+ :type => Integer,
2192
+ :allowed_from_server => false,
2193
+ :description => 'The total number of hyper-threaded execution contexts available.'
2194
+ },
2195
+ :'utilization.total_ram_mib' => {
2196
+ :default => nil,
2197
+ :allow_nil => true,
2198
+ :public => false,
2199
+ :type => Integer,
2200
+ :allowed_from_server => false,
2201
+ :description => 'This value represents the total amount of memory available to the host (not the process), in mebibytes (1024 squared or 1,048,576 bytes).'
1846
2202
  }
1847
2203
  }.freeze
1848
2204
  end