Uploaded image for project: 'Node.js Driver'
  1. Node.js Driver
  2. NODE-1571

Removal of APM metadata broke instrumentations.

    XMLWordPrintable

Details

    • Bug
    • Status: Closed
    • Major - P3
    • Resolution: Done
    • 3.0.6
    • None
    • None

    Description

      This is a continuation of this conversation.

       

      The instrument API does not work as before. Previously the 2nd argument to the callback was an array of endpoints describing how to instrument those methods. Now it is an instance of the Instrumentation class which has no information about the shape of the classes in the library.

      If this method of instrumenting Mongo is truly deprecated, the documentation which still lists the old way of instrumenting should be updated.

       

      That all said, there is a serious limitation of the command monitoring API when it comes to Node instrumentation, and that's a lack of mechanism for proper context propagation. Since only begin and end events are emitted, there is no way for us to properly restore and remove context without leaking it. This is uniquely a problem for Node due to its evented nature, which is probably why only the Node driver implemented the metadata array.

      Attachments

        Issue Links

          Activity

            People

              matt.broadstone@mongodb.com Matt Broadstone
              nwolfe Natalie Wolfe
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: