Method: NewRelic::Agent::Attributes#add_agent_attribute_with_key_check

Defined in:
lib/new_relic/agent/attributes.rb

#add_agent_attribute_with_key_check(key, value, default_destinations) ⇒ Object

[View source]

36
37
38
39
40
41
42
43
# File 'lib/new_relic/agent/attributes.rb', line 36

def add_agent_attribute_with_key_check(key, value, default_destinations)
  if exceeds_bytesize_limit?(key, KEY_LIMIT)
    NewRelic::Agent.logger.debug("Agent attribute #{key} was dropped for exceeding key length limit #{KEY_LIMIT}")
    return
  end

  add_agent_attribute(key, value, default_destinations)
end