Skip to content

Node.js Collaboration Summit diagnostics discussion minutes #95

Closed
@watson

Description

@watson

These are my raw notes taken at the Node.js Collaboration Summit in Berlin. Sorry for the mess 😅. I'll update when new stuff comes up. Feel free to add stuff I missed 😃

Day 1: 2017-05-04

Problem: How do we make it easier for APM vendors to instrument node-core and userland modules without having to monkey-patch everything (even after AsyncHooks lands)?

Suggestion: We need to make it easier for module owners to know how to structure and build their modules so they are easier to instrument. We can make a guide on https://nodejs.org/en/docs/guides/ that specifies how module owners should make their modules easy to instrument.

Topic ideas:

  • How to use the AsyncHooks Embedder API
  • How to send detailed tracing events to APM vendors using some API

Other notes:

  • This should be a living document
  • Discussion on this could be had on a PR that’s opened to the nodejs.org website creating this guide

Problem: Can we standardise the way tracing information is sent from an instrumented module (called module-x below) to an APM agent?

Suggestions:

  • Maybe we can use the V8 trace events API
    • Pros: No need for module-x to know about the APM agents
    • Cons:
      • Currently no way to bind the trace event to the current context
      • Might be expensive to cross the barrier into C-land
      • Might not be detailed enough
      • Overhead of running in production?
  • Alternatively invent a new API in JavaScript land
    • This could either be in Node core or a userland module
    • If it’s a userland module, then module-x needs to detect if it’s present before it can send events to it. The APM agents need to do the same.
      • What if there’s multiple versions of this module installed?
    • Research if other languages have something similar

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions