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

Memory leak caused by default initialisation of xlib #17

Open
tenxliviu opened this issue Oct 22, 2021 · 2 comments
Open

Memory leak caused by default initialisation of xlib #17

tenxliviu opened this issue Oct 22, 2021 · 2 comments

Comments

@tenxliviu
Copy link

Hello,

I managed to find a memory leak caused by "longjohn", a dependency loaded by default through xlib.

fixed memory leak phantomjscloud npm - production

fixed memory leak phantomjscloud npm

What fixed it was configuring xlib in production mode:

global.__xlibInitArgs = Object.assign({ envLevel: 'PROD', logLevel: 'ERROR' }, global.__xlibInitArgs);

I suggest to modify the phanthomjscloud initialisation of xlib to also contain the two parameters above.

@jasonswearingen
Copy link
Contributor

thank you for this. I will work on the required change. it is a little difficult because internally we are using a new version of xlib but that is not yet reflected in the public version of phantomjscloud-node. So it may be easier to just update to the newset xlib (and make sure the problem doesn't occur) than it is to fix this.

@jasonswearingen
Copy link
Contributor

This is scheduled to get fixed during the coming week.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants