J2V8 as an OSGi Bundle

J2V8 is a set of Java Bindings for V8. I’m happy to announce that with the 3.1 release, we now ship J2V8 as an OSGi bundle. This means that you can easily use J2V8 on your favourite OSGi runtime, or as an Eclipse plugin. To make it even easier to consume, we’ve also made J2V8 available in a p2 repository. Because J2V8 contains native code (and a copy of V8), there are several bundles available — one for each available platform.

To use J2V8 as an Eclipse Plugin, add our p2 repository to your target definition.

Screen Shot 2015-12-09 at 10.31.55 PM

Select “Include All Environments” to provision J2V8 for all available platforms. Currently J2V8 is available as a bundle on Linux 64, Mac 64, and Windows 32 & 64.

To ensure you can run J2V8 on any available platform, reference J2V8 using “Imported Packages”. This will allow you to use the correct platform at runtime.

Screen Shot 2015-12-09 at 10.36.38 PM

Now you can program against J2V8 in your Eclipse plugin.

Screen Shot 2015-12-09 at 10.40.13 PM

Screen Shot 2015-12-09 at 10.41.44 PM

To try this out, use our p2 repository at https://github.eclipsesource.com/j2v8-osgi/.

For more information on J2V8, follow me on Twitter.