Hibernate session created twice in Weblogic

Description

We noticed that during application deployment, all relevant Hibernate persistence units are getting created 2 times, thus significantly increasing deployment time.

Attached is a relevant log from a deployment and a demo war to reproduce the issue

Tested with Hibernate > 5.2.11. Currently: 5.4.16

Reproduce Actions:

1. create new data source in weblogic with jndi name: jdbc/SSA Use oracle db.
2. deploy app
3. check logs

 

You will notice that the log entry:
Processing PersistenceUnitInfo [name: primary]

happens 2 times!!

Environment

Weblogic 12.2.1.3

Activity

Show:
Theodore Chaikalis
August 7, 2020, 12:40 PM

Form do not let me upload the example WAR because it is > 10 MB, so i uploaded it to Drobpox:

Assignee

Unassigned

Reporter

Theodore Chaikalis

Fix versions

None

Labels

None

backPortable

None

Suitable for new contributors

None

Requires Release Note

None

Pull Request

None

backportDecision

None

Components

Affects versions

Priority

Critical
Configure