Skip to content

Commit 224b678

Browse files
committed
newrelic: Also send component name in MsgfloJobCompleted
1 parent cae0989 commit 224b678

2 files changed

Lines changed: 4 additions & 3 deletions

File tree

src/newrelic.coffee

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ catch e
77
debug 'New Relic not enabled', e.toString()
88

99
class Transactions
10-
constructor: (@name) ->
10+
constructor: (@definition) ->
1111
@transactions = {}
1212

1313
open: (id, port) ->
@@ -23,7 +23,8 @@ class Transactions
2323
if transaction
2424
duration = Date.now()-transaction.start
2525
event =
26-
role: @name
26+
role: @definition.role
27+
component: @definition.component
2728
inport: transaction.inport
2829
outport: port
2930
duration: duration

src/participant.coffee

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,7 @@ class Participant extends EventEmitter
5858
@definition = instantiateDefinition def, role
5959
@running = false
6060
newrelic = require './newrelic'
61-
@_transactions = new newrelic.Transactions role
61+
@_transactions = new newrelic.Transactions @definition
6262

6363
start: (callback) ->
6464
@messaging.connect (err) =>

0 commit comments

Comments
 (0)