Skip to main content

Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Virgo » Virgo 3.7.0 and Java 8 support(Why does Virgo 3.7.0 not yet have java 1.8 support)
Virgo 3.7.0 and Java 8 support [message #1755792] Wed, 08 March 2017 08:58 Go to next message
Patrick Braakman is currently offline Patrick BraakmanFriend
Messages: 1
Registered: March 2017
Junior Member
First of all I Know this topic looks like: .

But i could not find the answer I was looking for.

We are trying to upgrade our systems from Virgo 3.0.26 to Virgo 3.7.0 and also our Hibernate version to 5.2.8.

First error that I get isfrom the Hibernate bundle(it requires java 1.8):
A bundle could not be resolved because the required generic capability could not be resolved. Resolver error data <Require-Capability:; filter="(&(">. Caused by missing constraint in bundle <org.hibernate.core_5.2.8.Final>
constraint: <Require-Capability:; filter="(&(">

I solved this by editing the "java-server.profile" and added the java 1.8 in the;"JavaSE"; version:List<Version>="1.0, 1.1, 1.2, 1.3, 1.4, 1.5, 1.6, 1.7, 1.8" property.

So I got it working but my questions:
1) "How come Virgo 3.7.0 still has not java 1.8 support" while java 1.9 is on it's way.
In the other Thread it says because of the springframework was not compatible Virgo 3.6.3 (it was using sping 3.1.0)

When i look at the springframwork bundles wich comes with the Virgo 3.7.0 release it states 4.2.9.RELEASE so that should not be the issue anymore.
2) Can anyone name a date when the official support comes?

I have to sell this to our managers because with the upgrade is a lot of money involved and I would expect at least java 1.8 support from the latest Virgo. We can work around it now but I want to be able to argument why.

Many thnx in advance
Re: Virgo 3.7.0 and Java 8 support [message #1755851 is a reply to message #1755792] Wed, 08 March 2017 15:29 Go to previous message
GianMaria Romanato is currently offline GianMaria RomanatoFriend
Messages: 56
Registered: November 2015
Virgo is an OSGi container, but it is also a Java Enteprise Edition container. Additionally, the OSGi enterprise specification depends somehow on the Java Enterprise specification.

The current version of Java EE is 7. Version 8 of Java Entprise Edition is not yet released, and even when released, Application Server vendors will need some time to adapt their products.
Historically Java EE was released 1 to 2 years after Java SE, but in the context of Java 8 this delay is higher, mostly due to Oracle not evolving Java EE for long time [1].

Now if you read the Java EE 7 spec [2] in section Container Requirements you will find "This specification requires that containers provide a Java Compatibleā„¢ runtime environment, as defined by the Java Platform, Standard Edition, v7 specification (Java SE). "

In other words, Java EE 7 containers must provide Java SE 7 API to deployed applications. And this is what Virgo does.

In Java Enterprise Edition containers you can somehow workaround this constraint by writing Java 8 code, compiling it with Java 8, and running the Application Server with JDK 8. However, you will not be able to use Java 8 API from packages other than java.*, because the javax.* packages will be provided by the Application Server that will ship with the Java SE/EE 7 version of such packages.

In OSGi containers there is a more formal check represented by the Execution Environment. OSGi build tools typically determine the value of the Execution Environment at compile time. If your code uses Java 8 features, the build tool will add Java 8 as the execution environment in the MANIFEST.MF and your bundle will be unresolvable on a Java 7 compliant container, even if it is executed using a Java 8 runtime.
You can work around this contraint by either removing the Execution Environment header from your manifests, or by tweaking the Java profile file of the server. In both cases, you will be subject to the same limitations related to javax.* packages, and your application will not be compliant with the specification.



Previous Topic:Virgo Nano shutdown.bat throws error
Next Topic:Virgo nano p2 shell command
Goto Forum:

Current Time: Thu May 13 17:42:18 GMT 2021

Powered by FUDForum. Page generated in 0.02106 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top