You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomcat.apache.org by Riccardo Cohen <ri...@5flow.com> on 2018/04/02 14:02:35 UTC

Re: java 10 with jpa eclipselink and tomcat 9

Hello
Is there anybody that tried to use Java 9 or 10 ?
Thanks

On 29/03/2018 11:42, Riccardo Cohen wrote:
> Hello
> I'm using Tomcat 9.0.6 with java 1.8 and EclipseLink 
> org.eclipse.persistence:org.eclipse.persistence.jpa:2.7.1
>
> This works fine !
>
> I try to migrate to java 10:
> JAVA_VERSION="10"
> JAVA_VERSION_DATE="2018-03-20"
> downloaded into my mac today from 
> https://download.java.net/java/GA/jdk10/10/binaries/openjdk-10_osx-x64_bin.tar.gz
>
> I had to add 2 libraries :
>     javax.activation:activation:1.1.1
>     javax.xml.bind:jaxb-api:2.3.0
>
> The server succeded to launch. But at launch time I have the info :
>
> /[EL Warning]: metamodel: 2018-03-28 13:55:44.159--The collection of 
> metamodel types is empty. Model classes may not have been found during 
> entity search for Java SE and some Java EE container managed 
> persistence units.  Please verify that your entity classes are 
> referenced in persistence.xml using either <class> elements or a 
> global <exclude-unlisted-classes>false</exclude-unlisted-classes> element/
>
> With java 10, the persistence.xml seems to be ignored. This is the 
> content of the file :
>
> <persistence xmlns="http://java.sun.com/xml/ns/persistence"
>     xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
>     xsi:schemaLocation="http://java.sun.com/xml/ns/persistence 
> http://java.sun.com/xml/ns/persistence/persistence_2_0.xsd"
>     version="2.0">
>     <persistence-unit name="maindb" transaction-type="RESOURCE_LOCAL">
> <provider>org.eclipse.persistence.jpa.PersistenceProvider</provider>
>         <class>Data.E5User</class>
>         <class>Data.E5Witem</class>
>         <properties>
>             <property name="javax.persistence.nonJtaDataSource" 
> value="java:comp/env/jdbc/wfdb"/>
> <!--http://www.eclipse.org/eclipselink/documentation/2.5/jpa/extensions/p_logging_level.htm-->
>             <property name="eclipselink.logging.level" value="INFO"/>
>         </properties>
>     </persistence-unit>
> </persistence>
>
> I tried googling but found very few information about java 9 or 10 for 
> eclipselink.
> Adding javax.persistence library did not help.
> Maybe this is related to new "module" organization of java 9 ? But I 
> wouldn't know how to fix this.
>
> Thanks for your help
>
> -- 
> Riccardo Cohen
> +33 6 09 83 64 49
> http://www.5flow.com

-- 
Riccardo Cohen
+33 6 09 83 64 49
http://www.5flow.com

Re: java 10 with jpa eclipselink and tomcat 9

Posted by Riccardo Cohen <ri...@5flow.com>.
For your information, the problem with java 10 have been solved with 
org.eclipse.persistence:org.eclipse.persistence.jpa:2.7.2-SNAPSHOT

I can now run my server application with Java 10
Thanks

On 02/04/2018 16:02, Riccardo Cohen wrote:
> Hello
> Is there anybody that tried to use Java 9 or 10 ?
> Thanks
> 
> On 29/03/2018 11:42, Riccardo Cohen wrote:
>> Hello
>> I'm using Tomcat 9.0.6 with java 1.8 and EclipseLink 
>> org.eclipse.persistence:org.eclipse.persistence.jpa:2.7.1
>>
>> This works fine !
>>
>> I try to migrate to java 10:
>> JAVA_VERSION="10"
>> JAVA_VERSION_DATE="2018-03-20"
>> downloaded into my mac today from 
>> https://download.java.net/java/GA/jdk10/10/binaries/openjdk-10_osx-x64_bin.tar.gz
>>
>> I had to add 2 libraries :
>>     javax.activation:activation:1.1.1
>>     javax.xml.bind:jaxb-api:2.3.0
>>
>> The server succeded to launch. But at launch time I have the info :
>>
>> /[EL Warning]: metamodel: 2018-03-28 13:55:44.159--The collection of 
>> metamodel types is empty. Model classes may not have been found during 
>> entity search for Java SE and some Java EE container managed 
>> persistence units.  Please verify that your entity classes are 
>> referenced in persistence.xml using either <class> elements or a 
>> global <exclude-unlisted-classes>false</exclude-unlisted-classes> element/
>>
>> With java 10, the persistence.xml seems to be ignored. This is the 
>> content of the file :
>>
>> <persistence xmlns="http://java.sun.com/xml/ns/persistence"
>>     xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
>>     xsi:schemaLocation="http://java.sun.com/xml/ns/persistence 
>> http://java.sun.com/xml/ns/persistence/persistence_2_0.xsd"
>>     version="2.0">
>>     <persistence-unit name="maindb" transaction-type="RESOURCE_LOCAL">
>> <provider>org.eclipse.persistence.jpa.PersistenceProvider</provider>
>>         <class>Data.E5User</class>
>>         <class>Data.E5Witem</class>
>>         <properties>
>>             <property name="javax.persistence.nonJtaDataSource" 
>> value="java:comp/env/jdbc/wfdb"/>
>> <!--http://www.eclipse.org/eclipselink/documentation/2.5/jpa/extensions/p_logging_level.htm-->
>>             <property name="eclipselink.logging.level" value="INFO"/>
>>         </properties>
>>     </persistence-unit>
>> </persistence>
>>
>> I tried googling but found very few information about java 9 or 10 for 
>> eclipselink.
>> Adding javax.persistence library did not help.
>> Maybe this is related to new "module" organization of java 9 ? But I 
>> wouldn't know how to fix this.
>>
>> Thanks for your help
>>
>> -- 
>> Riccardo Cohen
>> +33 6 09 83 64 49
>> http://www.5flow.com
> 
> -- 
> Riccardo Cohen
> +33 6 09 83 64 49
> http://www.5flow.com

-- 
Riccardo Cohen
+33 6 09 83 64 49
http://www.5flow.com

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org