Hacker Newsnew | past | comments | ask | show | jobs | submitlogin
Show HN: A programmable embedded browser written in pure Java (github.com/machinepublishers)
52 points by logn on Jan 13, 2016 | hide | past | favorite | 11 comments


Interesting, but a bit misleading. I was expecting something more like HotJava, where the entire thing is java top to bottom. A webkit wrapper for Selenium tests is definitely useful, just not as neat as the idea of a pure java browser.


It uses only Java SE. It implements the Selenium API and wraps the renderer and JS engine that's built in to Java (WebKit). Granted, Java itself is built on native code and native WebKit renderer (whereas, the networking code, graphics, cookie management, headers, etc. are Java). Sorry to be misleading.


As for pure Java browsers, there is GNGR https://gngr.info/


Awesome!

Please add a sample maven pom import line into the readme - many more people will use it if it has it.


I just added it to Maven central repo. The dependency you can use is noted on the project page in the Download section.


If people are interested in WebKit source used by Java, you can get it here: http://hg.openjdk.java.net/openjfx/8/master/rt/file/tip/modu...


What's the use case for this? Thanks.


I was wondering also what the use case is for a headless browser. I'm guessing I'm just not thinking about this the correct way.


Glad I'm not alone. Obviously it can download pages like wget or curl. Presumably you could access the DOM of a page - for scraping, etc. Then there is a testing - perhaps this would be used for automated access of your website to make sure its working. But these are all guesses.


Yes, that's right, for (1) crawling and general index building, (2) scraping and data extraction, and (3) testing or web automation.

Some might be wondering, why this project vs other Selenium web drivers. Answer to that is: https://www.reddit.com/r/java/comments/40qa0q/a_purejava_sel...

The primary difference from wget and curl is the ability to fully render pages, sub-resources, CSS, and JS. Also allows interaction such as clicks and keyboard events.


I wonder if this works on aws lambda?




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: