feat: add support for before/after hooks to support tracing outbound requests #156
feat: add support for before/after hooks to support tracing outbound requests #156DonutEspresso wants to merge 5 commits intomasterfrom
Conversation
5c908a1 to
f57c997
Compare
|
Hey @joshwilsdon, let's continue the convo here. I rebased against master so this should be in a good place now. For context, we're looking at building a custom REST client for internal use and we need to do some pretty low level metrics and error logging. That's not currently possible without doing something intrusive like extending directly from JSONClient and overriding existing class methods. These life cycle hooks are a good alternative. The one thing I would want to add in this PR is the ability for Since |
| } | ||
| cb(); | ||
| }, before: function (opts, cb) { | ||
| beforeRan = true; |
There was a problem hiding this comment.
can we add more assertation around opts?
To be sure that this is the complete opts object, not just the subset of it.
|
Would be nice to create an |

Carries #95 over the finish line - would like to get input from the peanut gallery. This should dove tail nicely with our metrics needs as well.