Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add more events #58

Closed
KartoffelToby opened this issue Nov 15, 2018 · 8 comments
Closed

Add more events #58

KartoffelToby opened this issue Nov 15, 2018 · 8 comments
Labels
discussion Talk about features or implementation enhancement New feature or request

Comments

@KartoffelToby
Copy link

Something like:

    cluster.on('monitor', (data) => {
        console.log(data);
    });
@thomasdondorf
Copy link
Owner

I will probably go in the direction of offering a way to query the status. Then you can set up a setInterval function and call cluster.stats() yourself.

Sounds good?

@thomasdondorf thomasdondorf added the discussion Talk about features or implementation label Nov 18, 2018
@KartoffelToby
Copy link
Author

Yea, sounds sweet, but maybe an event would be more useful

@thomasdondorf
Copy link
Owner

And when would you want the 'monitor' event to be triggered?

@KartoffelToby
Copy link
Author

Every time a queue is done?

@thomasdondorf thomasdondorf changed the title Monitor Stats Object as Event Add more events Dec 21, 2018
@thomasdondorf
Copy link
Owner

I guess a 'queue' event would be better suited then. I could add more events for v1.0.

@thomasdondorf thomasdondorf added the enhancement New feature or request label Mar 6, 2019
@thomasdondorf
Copy link
Owner

The "queue" event is now fired when something is queued via queue or execute.

@kfrajtak
Copy link

Hi. Does the queue event payload contain all the information the monitor is displaying? My idea is to retrieve the monitor part information on the server and send it to client through socket.

@thomasdondorf
Copy link
Owner

No, there is only the queued data/function inside the event. There currently is no "statistics API".

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
discussion Talk about features or implementation enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

3 participants