Scaling PhantomJs

131 views
Skip to first unread message

Saleem Shah

unread,
Aug 8, 2016, 2:34:10 PM8/8/16
to phantomjs
Hello all, 

The question has been asked several times but I didn't landed on a single one to clearly give me direction for the problem. We have a big client base and they have websites with thousands of pages. We want to automate the system so that we will just add the main url of the website of our client and our app will be able to run tests against all the pages. The only problem we have is that how to scale phantomjs so that it can run multiple tests in parallel. I want to create servers with one or two instances of phantomjs running with multiple tabs. I can fine tune the work load according to server resources but I can't get it that how to install phantomjs on multiple servers communicating with our main app through api over a private network through a load balancer. I am thinking of using nodejs for server. If anyone can just simplify the steps afterward, I will be grateful.

Thanks )

Sean McNamara

unread,
Aug 8, 2016, 2:41:22 PM8/8/16
to phan...@googlegroups.com
Use Selenium Grid. It's designed for exactly this kind of scenario.

You can access PhantomJS through Selenium, then you'll just have to
re-write whatever you've written using PhantomJS directly to use
Selenium.

It's much more flexible and featureful to use a proper programming
environment, anyway...
> --
> You received this message because you are subscribed to the Google Groups
> "phantomjs" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to phantomjs+...@googlegroups.com.
> Visit this group at https://groups.google.com/group/phantomjs.
> For more options, visit https://groups.google.com/d/optout.

Saleem Shah

unread,
Aug 8, 2016, 4:06:12 PM8/8/16
to phantomjs
thank you for your reply. I checked selenium and I think it can pretty much do what I want. But I have limited toolsets in form of number of languages I know. Is there any php library or nodejs to control it programmatically?

Also I found an npm package named ghost-town which claims to provide highly scalable phantomjs environment, But I was not able to find any details on it. Do you or anyone else has any experience in that?  

Sean McNamara

unread,
Aug 8, 2016, 4:42:58 PM8/8/16
to phan...@googlegroups.com
http://webdriver.io
To unsubscribe from this group and stop receiving emails from it, send an email to phantomjs+unsubscribe@googlegroups.com.

Alessandro Tagliapietra

unread,
Aug 11, 2016, 8:19:57 PM8/11/16
to phantomjs
Use something like AWS lambda, you can have hundreds of phantomjs instances running concurrently
Reply all
Reply to author
Forward
0 new messages