database - Java EclipseLink EntityManger: Way to Ensure Connection Can be Established? -


i'm using eclipselink 2.4 in jax-rs (jersey) application.

in base controller, connect database, since entity manager really connects when query executed, exception thrown.

is there way determine if can connect database after entitymanager object can handle exception myself (and fail on manually database).

edit: assume cannot change underlying dbms @ all.

you create servletcontextlistener , run query on startup application. if fails out of luck error handling guess.

you should clustered ha database.


Comments

Popular posts from this blog

css - Which browser returns the correct result for getBoundingClientRect of an SVG element? -

gcc - Calling fftR4() in c from assembly -

.htaccess - Matching full URL in RewriteCond -