Module: RedCross
- Defined in:
- lib/red_cross/trackers/application_tracker.rb,
lib/red_cross.rb,
lib/red_cross/logging.rb,
lib/red_cross/version.rb,
lib/red_cross/configuration.rb,
lib/red_cross/trackers/base.rb,
lib/red_cross/trackers/http_tracker.rb,
lib/red_cross/trackers/monitor_tracker.rb,
lib/red_cross/trackers/segment_tracker.rb
Overview
Application tracker send your metrics to influxdb using udp protocol Usage: RedCross.application_track(event: ‘user.registration’, properties: { referrer: ‘facebook’ } )
Defined Under Namespace
Modules: Configuration, Logging, Trackers
Constant Summary
collapse
- VERSION =
'0.4.1'
Class Method Summary
collapse
Class Method Details
.group(attrs, topic = '') ⇒ Object
28
29
30
|
# File 'lib/red_cross.rb', line 28
def group(attrs, topic = '')
Configuration.tracker.group(attrs)
end
|
.identify(attrs, topic = '') ⇒ Object
20
21
22
|
# File 'lib/red_cross.rb', line 20
def identify(attrs, topic = '')
Configuration.tracker.identify(attrs)
end
|
.method_missing(m, *args, &block) ⇒ Object
32
33
34
35
36
37
|
# File 'lib/red_cross.rb', line 32
def method_missing(m, *args, &block)
match = /(.*?)_track/.match(m.to_s)
tracker = match.captures.first.to_sym unless match.nil?
super unless Configuration.trackers.keys.include? tracker
Configuration.trackers[tracker].send(:track, *args)
end
|
.track(attrs, topic = '') ⇒ Object
16
17
18
|
# File 'lib/red_cross.rb', line 16
def track(attrs, topic = '')
Configuration.tracker.track(attrs)
end
|