MachinePublishers / jBrowserDriver

A programmable, embeddable web browser driver compatible with the Selenium WebDriver spec -- headless, WebKit-based, pure Java
Other
809 stars 143 forks source link

Seeking user feedback: jBrowserDriver vs headless ChromeDriver #273

Closed hollingsworthd closed 7 years ago

hollingsworthd commented 7 years ago

Chromium has added headless mode in Chrome 59

https://news.ycombinator.com/item?id=14101233

I think it would be possible to use Selenium ChromeDriver and pass the headless flag.

I am curious what users of jBrowserDriver see as the primary advantage of using this project vs headless ChromeDriver. For instance, only needing Java, performance, managing SSL certs in the JDK, greater programmatic configurability, logging of HTTP traffic, proxying, etc. Feedback here would help chart a direction for future enhancements and add some context for people deciding on what web driver to pick.

jackrusher commented 7 years ago

I really like having a single dep that allows me to deploy without having anything more than the JVM installed. Also, while there are many users whose main use for such a library is site testing, my main use is website spidering and remote site automation, so flexible programmability is a big deal for me.

vrosu commented 7 years ago

I would say that the one dependency +the VM it's something highly desired. Had many issues with running in Linux, because of things that are hard to diagnose, like a missing library from JRE or stuff like that. My usecase is saving a page screenshot in a PDF, kinda like a HTML-2-PDF saving tool for reports, so no testing as well.

sidneydemoraes commented 7 years ago

My choice for jBrowserDriver was the same as mentioned by folks above. I'd rather having a single dep with no need to setup XVFB or anything like that. I'm not performing functional tests but automating stuff so I don't need a real browser running.

hollingsworthd commented 7 years ago

Thanks for the feedback. I think along the lines of what's mentioned here it will eventually be nice to have the ability to run only a single instance of JBrowserDriver and run it in a single JVM process. The downside is if it crashes it takes down the main app. But people might prefer to handle that in their own architecture.

Within the Settings object generally it will be a good place to expose additional features that will be useful for use cases this project is particularly suited. That way we won't break Selenium compatibility. But the Selenium API is meant to mimic exactly the behaviors of a human user.

jackrusher commented 7 years ago

Single-process would be grand. I haven't seen nearly so many browser crashes in more recent versions.

ibrahimrajabli commented 3 years ago

what about speed? which browser opens, render something and closes faster?