lib/new_relic/agent/agent.rb in newrelic_rpm-9.8.0 vs lib/new_relic/agent/agent.rb in newrelic_rpm-9.9.0
- old
+ new
@@ -32,10 +32,11 @@
require 'new_relic/agent/vm/monotonic_gc_profiler'
require 'new_relic/agent/utilization_data'
require 'new_relic/environment_report'
require 'new_relic/agent/attribute_filter'
require 'new_relic/agent/adaptive_sampler'
+require 'new_relic/agent/serverless_handler'
require 'new_relic/agent/connect/request_builder'
require 'new_relic/agent/connect/response_handler'
require 'new_relic/agent/agent_helpers/connect'
require 'new_relic/agent/agent_helpers/harvest'
@@ -94,10 +95,11 @@
@sql_sampler = SqlSampler.new
@transaction_rules = RulesEngine.new
@monotonic_gc_profiler = VM::MonotonicGCProfiler.new
@adaptive_sampler = AdaptiveSampler.new(Agent.config[:sampling_target],
Agent.config[:sampling_target_period_in_seconds])
+ @serverless_handler = ServerlessHandler.new
end
def init_event_handlers
@agent_command_router = Commands::AgentCommandRouter.new(@events)
@monitors = Monitors.new(@events)
@@ -170,10 +172,11 @@
attr_reader :span_event_aggregator
attr_reader :log_event_aggregator
attr_reader :transaction_event_recorder
attr_reader :attribute_filter
attr_reader :adaptive_sampler
+ attr_reader :serverless_handler
def transaction_event_aggregator
@transaction_event_recorder.transaction_event_aggregator
end
@@ -305,10 +308,10 @@
# might be holding locks for background thread that aren't there anymore.
def reset_objects_with_locks
@stats_engine = StatsEngine.new
end
- def flush_pipe_data
+ def flush_pipe_data # used only by resque
if connected? && @service.is_a?(PipeService)
transmit_data_types
end
end