Thank you Very much.

I have see your changes into your PR.

I would get Now tomee8.0.8 plus but with hibernate.
Please do you can still chance my pom ?

What version of libs for hibernate do you Think are ok with tomee8.0.8?

Please let me know what version are ok for hibernate .
The hibernate 5.2.12 is too old?

I have to update the libs for get last version of  hibernate ?

Please control this pom.xml below for get tomee8.0.8 plus with last
hibernate available working with jee8


-----------------
<project xmlns="http://maven.apache.org/POM/4.0.0"; xmlns:xsi="
http://www.w3.org/2001/XMLSchema-instance";
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0
http://maven.apache.org/xsd/maven-4.0.0.xsd";>
<modelVersion>4.0.0</modelVersion>
<groupId>mauro.tomee7hibernate</groupId>
<artifactId>prova2</artifactId>
<version>1.0-SNAPSHOT</version>
<packaging>war</packaging>
<properties>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
<project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding>
<maven.compiler.source>1.8</maven.compiler.source>
<maven.compiler.target>1.8</maven.compiler.target>
<failOnMissingWebXml>false</failOnMissingWebXml>
<!-- versions for TomEE maven plugin and Hibernate -->
<tomee-maven-plugin.version>7.0.4</tomee-maven-plugin.version>
<hibernate-core.version>5.2.12.Final</hibernate-core.version>
<hibernate-commons-annotations.version>5.0.1.Final</hibernate-commons-annotations.version>
<jandex.version>2.0.3.Final</jandex.version>
<jboss-logging.version>3.3.0.Final</jboss-logging.version>
<javassist.version>3.20.0-GA</javassist.version>
<classmate.version>1.3.0</classmate.version>
<antlr.version>2.7.7</antlr.version>
<dom4j.version>1.6.1</dom4j.version>
<!-- versions for HSQLDB setup -->
<exec-maven-plugin.version>1.6.0</exec-maven-plugin.version>
<hsqldb.version>2.3.2</hsqldb.version> <!-- 7.0.4 ships with 2.3.2, 2.3.4
requires a newer driver version, so it can't be accessed via the lib
version shipped with TomEE-->
</properties>
<dependencies>
<dependency>
<groupId>javax</groupId>
<artifactId>javaee-api</artifactId>
<version>7.0</version>
<scope>provided</scope>
</dependency>
</dependencies>
<build>
<finalName>${project.artifactId}</finalName>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-war-plugin</artifactId>
<version>3.2.3</version>
<configuration>
<webResources>
<resource>
<directory>${basedir}/src/main/webapp/WEB-INF</directory>
<filtering>true</filtering>
<targetPath>WEB-INF</targetPath>
</resource>
</webResources>
<failOnMissingWebXml>false</failOnMissingWebXml>
</configuration>
</plugin>
<plugin>
<groupId>org.apache.tomee.maven</groupId>
<artifactId>tomee-maven-plugin</artifactId>
<version>${tomee-maven-plugin.version}</version>
<configuration>
<tomeeClassifier>plus</tomeeClassifier>
<config>${project.basedir}/src/test/tomee/conf</config>
<libs>
<lib>remove:openjpa-</lib>
<lib>org.hibernate:hibernate-core:${hibernate-core.version}</lib>
<lib>
org.hibernate.common:hibernate-commons-annotations:${hibernate-commons-annotations.version}
</lib>
<lib>org.jboss:jandex:${jandex.version}</lib>
<lib>org.jboss.logging:jboss-logging:${jboss-logging.version}</lib>
<lib>org.javassist:javassist:${javassist.version}</lib>
<lib>com.fasterxml:classmate:${classmate.version}</lib>
<lib>antlr:antlr:${antlr.version}</lib>
<lib>dom4j:dom4j:${dom4j.version}</lib>
<!-- add JDBC driver for RDBMS you use, driver for HSQLDB is bundled with
TomEE -->
</libs>
<systemVariables>
<openejb.system.apps>true</openejb.system.apps>
<tomee.remote.support>true</tomee.remote.support>
<tomee.serialization.class.blacklist>-</tomee.serialization.class.blacklist>
<!--
<log4j.category.OpenEJB>info</log4j.category.OpenEJB>
<log4j.category.OpenEJB.options>warn</log4j.category.OpenEJB.options>
<log4j.category.OpenEJB.server>info</log4j.category.OpenEJB.server>
<log4j.category.OpenEJB.startup>info</log4j.category.OpenEJB.startup>
<log4j.category.OpenEJB.startup.service>warn</log4j.category.OpenEJB.startup.service>
<log4j.category.OpenEJB.startup.config>warn</log4j.category.OpenEJB.startup.config>
<openejb.logger.external>true</openejb.logger.external>
<openejb.log.factory>log4j</openejb.log.factory>
-->
<openejb.nobanner>false</openejb.nobanner>
</systemVariables>
<webapps>
<webapp>
mauro.tomee7hibernate:prova2:${project.version}?name=ROOT
</webapp>
</webapps>
</configuration>
</plugin>
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>exec-maven-plugin</artifactId>
<version>${exec-maven-plugin.version}</version>
<dependencies>
<dependency>
<groupId>org.hsqldb</groupId>
<artifactId>hsqldb</artifactId>
<version>${hsqldb.version}</version>
</dependency>
</dependencies>
<configuration>
<includePluginDependencies>true</includePluginDependencies>
<mainClass>org.hsqldb.server.Server</mainClass>
<arguments>
<argument>--database.0</argument>
<argument>file:${project.build.directory}/hsqldb/xdb</argument>
<argument>--dbname.0</argument>
<argument>xdb</argument>
</arguments>
</configuration>
</plugin>
</plugins>
</build>
</project>


Il Mer 27 Ott 2021, 09:30 Zowalla, Richard <[email protected]>
ha scritto:

> Hi Mauro,
>
> I had a quick look at your project. Any reason for choosing TomEE 7 /
> EE7? If not absolutly necessary, I would look at TomEE 8 in 2021.
>
> I made some changes and the project is working fine (see my PR in your
> project).
>
> The following adjustments are necessary / were made:
>
> 1. "org.hibernate.ejb.HibernatePersistence" does not exist in the
> selected hibernate version (and the referenced library).
>
> 2. I would use a tomee.xml rather than using system.properties to
> configure the datasource.
>
> 3. The hsqldb version for the hsqldb server is too high compared to the
> version shipped with 7.0.4. You have to downgrade.
>
> 4. I updated your POM to use the maven war plugin and configured the
> plugin to automatically deploy your webapp.
>
> Gruss
> Richard
>
>
>
>
> Am Mittwoch, dem 27.10.2021 um 02:18 +0200 schrieb naciu:
> > please go at this web app created using the archetyoe for tomee7 and
> > hibernate 5.2.12.
> >
> > I setted the properties for create the tables from entity at
> > deployment
> > time ,but it not working.
> >
> > the table into hsqldb not are created.
> >
> > please the datasource is named ds .
> >
> > The jpa provider is hibernate 5.2.12 added with tomee maven plugin
> > and
> > removed openjpa .
> >
> > i setted into persistence.xml the properties:
> >
> >
> > <exclude-unlisted-classes>false</exclude-unlisted-classes>
> >          <properties>
> >              <property name="hibernate.dialect"
> > value="org.hibernate.dialect.HSQLDialect"/>
> >
> >              <!-- 'update' is a nonstandard action, but Hibernate
> > supports it -->
> >              <!--       <property
> > name="javax.persistence.schema-generation.database.action"
> > value="update"/>  -->
> >              <!--     <property name="hibernate.hbm2ddl.auto"
> > value="create-drop"/>  -->
> >              <property name="hibernate.show_sql" value="true"/>
> >              <property name="hibernate.format_sql" value="true"/>
> >              <property
> > name="javax.persistence.schema-generation.database.action"
> > value="drop-and-create"/>
> >          </properties>
> >
> > my project is at my github
> >
> > https://github.com/maurojava/prova2.git
> >
> >
> --
> Richard Zowalla, M.Sc.
> Research Associate, PhD Student | Medical Informatics
>
> Hochschule Heilbronn – University of Applied Sciences
> Max-Planck-Str. 39
> D-74081 Heilbronn
> phone: +49 7131 504 6791 (zur Zeit nicht via Telefon erreichbar)
> mail: [email protected]
> web: https://www.mi.hs-heilbronn.de/
>

Reply via email to