Skip to content

Commit

Permalink
Update README.md
Browse files Browse the repository at this point in the history
  • Loading branch information
Peter Svetlichny authored and GitHub Enterprise committed Mar 27, 2018
1 parent 11cb29b commit 153535a
Showing 1 changed file with 9 additions and 7 deletions.
16 changes: 9 additions & 7 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -708,15 +708,17 @@ returned transaction is a custom one, started with either `startWebTransaction`
or `startBackgroundTransaction`, then `transaction.end()` must be called to
end the transaction.

#### newrelic.createTracer(name, handle)
#### newrelic.startSegment(name, record, handler, callback)

`name` is the name of the tracer. It will show up as a segment in your
transaction traces and create its own metric. `handle` is the function to be
bound to the tracer.
`name` is the name of the segment. `record` is a boolean value signalling
whether or not to record the segment as a metric. `handler` is the function
being recorded. `callback` is an optional function that is passed to the
handler and fired after all other work is complete.

Timing is from when `createTracer` is called until the `handle` done executing.
This should be called inside of a transaction to get data. If it is called
outside of a transaction it will just pass through.
Timing is from when `startSegment` is called until the `handler` is done
executing, or when the `callback` is fired, if it's supplied. This method
should be called inside of a transaction to get data. If it is called outside
of a transaction it will just pass through.

#### newrelic.recordMetric(name, value)

Expand Down

0 comments on commit 153535a

Please sign in to comment.