Class: OmgPullRequest::Plugin::Instrumenter
- Inherits:
-
Object
- Object
- OmgPullRequest::Plugin::Instrumenter
- Includes:
- Singleton
- Defined in:
- lib/omg_pull_request/plugin.rb
Instance Method Summary collapse
-
#initialize ⇒ Instrumenter
constructor
A new instance of Instrumenter.
- #instrument(event, args) ⇒ Object
Constructor Details
#initialize ⇒ Instrumenter
Returns a new instance of Instrumenter.
26 27 28 29 30 |
# File 'lib/omg_pull_request/plugin.rb', line 26 def initialize Plugin.initialize do |attributes| @attributes = attributes end end |
Instance Method Details
#instrument(event, args) ⇒ Object
32 33 34 |
# File 'lib/omg_pull_request/plugin.rb', line 32 def instrument(event, args) ActiveSupport::Notifications.instrument("omgpr:#{event}", (@attributes || {}).merge(args)) end |