Using PhantomJS.exe for mass memory usage with Webdriver

I wrote a simple cleaning program using PhantomJS and webdriver, which consists essentially of the following steps:

Go to the page Collect some links (30) from the page on xpath For each link, go to this URL and collect a bunch of text elements on the page

I do not call it in JavaScript, I use webdriver written in C #.

My problem is that the PhantomJS.exe process reaches a memory usage of more than 800 MB, that I cannot understand why this is happening. My .net exe memory usage (which calls PhantomJS.exe) is about 12 MB. I use only one instance and do all the processing in sequential order, so efficiently that I know a single window or tab.

Does anyone encounter similar problems using PhantomJS, for some reason should it have this behavior?

+4
source share

Source: https://habr.com/ru/post/1488262/


All Articles