Hello,

 thank you for the answer!

 These links focus on the DataSource approach, which I've failed to make work 
as well. What I did get to work was through the persistence.xml, completely 
bypassing TOMEE's datasources (as described in the stackoverflow link I gave), 
but then I'm not sure whether UserTransactions and container-managed 
transactions are supported (at first sight things seem to work, but the devil 
is in the details).

 I hope maybe someone can answer on that?

 Thank you again,

Emmanuel

----- Original Message -----
From: "Zowalla, Richard" <richard.zowa...@hs-heilbronn.de>
To: users@tomee.apache.org
Sent: Tuesday, 23 March, 2021 20:28:01
Subject: Re: setting up the hikari connection pool with tomee

Hi,

there were some discussions related to HikariCP on the lists a few days
ago [1], [2], and [3]. I would try with [1] and [2]. Hope it helps.

Gruss
Richard


[1] 
http://tomee-openejb.979440.n4.nabble.com/HikariCP-configuration-in-TomEE-td4678838.html
[2] 
http://tomee-openejb.979440.n4.nabble.com/Configuring-HikariCP-with-OpenEjb-need-inputs-td4691576.html
[3] 
http://tomee-openejb.979440.n4.nabble.com/HikariCp-to-set-JtaManaged-td4689571.html

Am Dienstag, den 23.03.2021, 17:01 +0100 schrieb Emmanuel Touzery:
> Hello,
> 
>      I'm trying to configure hibernate+hikarip connection pool for
> TOMEE.
> 
>      I made it work without issues (at first sight), by configuring 
> everything in the persistence.xml, basically as described in the
> answer 
> to this stackoverflow question:
> 
> https://stackoverflow.com/questions/49366198/how-to-configure-hikaricp-via-tomee-xml
> 
>      I would rather configure it through TOMEE data sources, as I'm
> used 
> to, in the conf/tomee.xml or conf/context.xml
> 
>      I've attempted to do so, also helping myself with 
> https://github.com/brettwooldridge/HikariCP/wiki/JNDI-DataSource-Factory-(Tomcat,-etc.)
> 
>      But I didn't manage to. I got errors like described in the 
> stackoverflow question, but also some others.
> 
>      I have two questions:
> 
>  1. is it supported to specify the connection purely through the
>     persistence.xml without any datasource in the tomee.xml? Will
>     UserTransactions, container-managed transactions work as
> expected?
>  2. could I configure tomee+hibernate+hikaricp through a tomee
>     datasource? If so, how? (One reason I'd rather have a datasource
> is
>     also so that it's possible to edit the  JDBC configuration (eg
> IP,
>     password, connection pool size..) without redeploying the
>     application (because the persistence.xml is in the war)
> 
>      Thank you!
> 
> Emmanuel
> 
>

Reply via email to