Skip to content

Any plans/thoughts about monitoring event loop performance #131

Closed

Description

@zimbabao

Event loop performance metrics like

  1. time for iteration
  2. size of the queue during each phases.
  3. statistics on these numbers (percentiles, SD etc)

Can be helpful just like GC numbers dumped by V8 VM.

Any thoughts for or against this?.

Activity

  1. hybrist commented on Dec 12, 2017

    @hybrist
    Contributor
  2. zimbabao commented on Dec 13, 2017

    @zimbabao
    Author

    Thanks @jkrems, I'm interested in monitoring event loop.

    1. To keep tab on event loop stalls
    2. Attribute latency to event loop stalls
  3. danielkhan commented on Dec 14, 2017

    @danielkhan
    Contributor

    Have a look at my blog post: https://medium.com/the-node-js-collection/what-you-should-know-to-really-understand-the-node-js-event-loop-and-its-metrics-c4907b19da4c

    I am covering some metrics that can be easily gathered there.

  4. naugtur commented on Dec 14, 2017

    @naugtur
    Contributor

    This might be useful:
    https://github.com/naugtur/blocked-at

    Disclaimer: I'm the author and blocked-at is still considered experimental (but seems to work)

  5. mcollina commented on Dec 15, 2017

    @mcollina
    SponsorMember

    I know that @jasnell looked extensively in it, and it seemed it could not be possible without a breaking change in libuv, which I don't think the team was willing to do.

  6. jasnell commented on Dec 15, 2017

    @jasnell
    Member

    Still intending to work on this, but it definitely will be libuv2

  7. bnb commented on Dec 18, 2017

    @bnb
    Member

    We currently do this with N|Solid and from my understanding it's... not easy. I've looked into the existing ecosystem tooling and it kinda reflects that, unfortunately. 😞

    @Fishrock123 and @cxreg did a ton of work on it and may be able to share their experience with it.

  8. bnoordhuis commented on Dec 18, 2017

    @bnoordhuis
    Member

    time for iteration

    Can already be done with a uv_check_t + uv_prepare_t.

    size of the queue during each phase

    Can you specify "queue" and "phase" a bit more?

  9. Fishrock123 commented on Dec 18, 2017

    @Fishrock123
    Contributor

    Yeah we pretty much do this stuff in N|Solid already, and also event loop "stall" notifications.


    size of the queue during each phase

    Can you specify "queue" and "phase" a bit more?

    Probably one of the things we do: essentially the number of MakeCallbacks per loop.

  10. zimbabao commented on Dec 22, 2017

    @zimbabao
    Author

    @bnoordhuis : By phases I'm referring to phases to https://nodejs.org/en/docs/guides/event-loop-timers-and-nexttick/. By queues I meant macro task queues in that phase and micro task queue in process.tick().

    @Fishrock123 : That's what I meant.

  11. gireeshpunathil commented on Oct 25, 2019

    @gireeshpunathil
    Member

    should this remain open? [ I am trying to chase dormant issues to closure ]

  12. jasnell commented on Oct 25, 2019

    @jasnell
    Member

    I've abandoned the effort to get something into libuv as I just could not get feedback or any positive momentum from the maintainers. I've added loop delay sampling to node.js itself so I think we can close this

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions