Method: Instana::Backend::ServerlessAgent#source

Defined in:
lib/instana/backend/serverless_agent.rb

#sourceHash, NilClass

Returns the backend friendly description of the current in process collector.

Returns:

  • (Hash, NilClass)

    the backend friendly description of the current in process collector

Since:

  • 1.197.0



44
45
46
47
48
49
50
51
52
53
# File 'lib/instana/backend/serverless_agent.rb', line 44

def source
  snapshot = @snapshots.detect { |s| s.respond_to?(:source) }

  if snapshot
    snapshot.source
  else
    @logger.warn('Unable to find a snapshot which provides a source.')
    {}
  end
end