vendredi 9 octobre 2015

JEE Container (Glassfish) and HikariCP - JNDI vs managing my own instance

Is it considered bad/acceptable/good/best practice to manage my own instance of a HikariCP connection pool, with the goal that I don't have to configure any JNDI resources within Glassfish?

Some background:

My deployment environment is AWS's elastic beanstalk, running glassfish within a docker container. I have a working solution for generating JNDI resources whe deploying in that environment, but it makes deployment quite fragile. See the following question for details: How to configure a GlassFish instance running on AWS/ElasticBeanstalk/Docker?.

I'm quite keen to get rid of the deployment hassles, but I don't really know much about connection pooling, and HikariCP in particular. Am I just cruising for a bruising in this direction? My super simple implementation might just be to create a static variable that contains the connection pool.




Aucun commentaire:

Enregistrer un commentaire