-->
These old forums are deprecated now and set to read-only. We are waiting for you on our new forums!
More modern, Discourse-based and with GitHub/Google/Twitter authentication built-in.

All times are UTC - 5 hours [ DST ]



Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 3 posts ] 
Author Message
 Post subject: Deployment phase doesn't process each persistence unit
PostPosted: Thu Sep 01, 2016 2:39 pm 
Newbie

Joined: Fri Dec 04, 2009 4:17 pm
Posts: 18
I have an webapp in Payara 4.1.1.162 + JPA + Hibernate 4.3.
My webapp has more than 20 PUs, because it needs to look for data in many databases.
But these databases aren't neeeded at the same time, there are options in the menu that
use one or other database at this time. I would like to know if it is possible to configure
Payara/JPA/Hibernate to doesn't do the initial check of databases at deploy time, leaving
it for a time it will be needed at running time, on demand of first user interaction.
Informações: HHH000204: Processing PersistenceUnitInfo [
name: myPU1
...]
Informações: HHH000204: Processing PersistenceUnitInfo [
name: myPU2
...]
etc
This part of deployment is the main processing time, then the webapp is deployed
more than 4 minutes. If I disable the majority of the PUs, leaving just one, the deployment
is very fast.
I use JTA and not RESOURCE-LOCAL in persistence.xml for all databases.
PS: I sent this msg in Payara/Glassfish forum and they said me to send to Hibernate forum.


Top
 Profile  
 
 Post subject: Re: Deployment phase doesn't process each persistence unit
PostPosted: Fri Sep 02, 2016 12:41 am 
Hibernate Team
Hibernate Team

Joined: Thu Sep 11, 2014 2:50 am
Posts: 1628
Location: Romania
I'm not sure if you can delay the EMF creation. But you can break it into multiple services so, when you have to deploy one service, you don't have to wait that much. Breaking the monolith seems like a popular choice these days.


Top
 Profile  
 
 Post subject: Re: Deployment phase doesn't process each persistence unit
PostPosted: Fri Sep 02, 2016 5:32 pm 
Newbie

Joined: Fri Dec 04, 2009 4:17 pm
Posts: 18
But my webapp is just one traditional ERP where I have one deployment and many enterprises using the same app/server, just the user is different.
Then, it is not possible to break the app in mini-apps, like microservices or something like that.


Top
 Profile  
 
Display posts from previous:  Sort by  
Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 3 posts ] 

All times are UTC - 5 hours [ DST ]


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
© Copyright 2014, Red Hat Inc. All rights reserved. JBoss and Hibernate are registered trademarks and servicemarks of Red Hat, Inc.