grouper-users - [grouper-users] RE: Connection pooling to reduce first load time after Tomcat start
Subject: Grouper Users - Open Discussion List
List archive
[grouper-users] RE: Connection pooling to reduce first load time after Tomcat start
Chronological Thread
- From: "Wessel, Keith" <>
- To: "" <>
- Subject: [grouper-users] RE: Connection pooling to reduce first load time after Tomcat start
- Date: Tue, 4 Oct 2016 17:09:55 +0000
- Accept-language: en-US
- Ironport-phdr: 9a23:JSNNxxRz5UFbn9olBr/o4JCP39psv+yvbD5Q0YIujvd0So/mwa64ZBCN2/xhgRfzUJnB7Loc0qyN7PCmBDdLuMvJmUtBWaIPfidNsd8RkQ0kDZzNImzAB9muURYHGt9fXkRu5XCxPBsdMs//Y1rPvi/6tmZKSV2sfTZyc676AInPl8mtkv2p9ofISwROmDenZ75udlO7oRib/p0Zm4x/MqsrjwbSr2FTU+VQ2W5yI1+PxVDx6trmr7B59CEF8c0s7NVNVeGyXKk5UbwSRGAlLG0u/8DvnRjHSQqJ4XoHFGgaj0wbUED+8BjmU8Kp4WPBve1n1XzCMA==
Hi, Chris, If others have found a way around this, a patch for this isn’t necessary, though thanks for offering. I changed my hibernate.c3p0.min_size to 1 from 0, thinking that would have one connection at the ready. And if I wait a minute after Tomcat start-up before connecting, that does, in fact, seem to get rid of the
gateway timeout error from mod_proxy. If I adjust the mod_proxy timeout to 60 seconds as you suggest, that should take care of it. I do, however, notice three, not one, connection from my Grouper server to MySQL. Not sure where the three are coming from right
now, but I think I’ll tinker some more. Not that three is hurting anything. Just to make sure, I’m assuming that the min pool size of 1 rather than 0 won’t hurt anything. Am I missing something? And this should also negate the need to prime the pump by hitting the URL on Tomcat start-up? Thanks, Keith From: [mailto:]
On Behalf Of Hyzer, Chris I would bump that timeout up
J (whether or not startup takes a while… you don’t want a request failing because of timeout… make it 60 seconds at least). Also in your tomcat start script maybe you could
prime the pump by hitting the servlet? I think if I made a patch that implemented the init() method on the servlet and started grouper it would get grouper ready to go automatically, do you want that? Btw, I don’t think changing pooling would help, need
hibernate to init and classes to load, that’s the bottleneck I think Thanks Chris From: [mailto:]
On Behalf Of Wessel, Keith Hi, all, We’re running a fairly vanilla Grouper installation at this point, with few changes from what the Grouper Installer did. One change is that we’re talking to a remote MySQL database server instead of HSQL. I’ve noticed, the first time we connect to Grouper after a Tomcat restart or after a while of inactivity, things take a while to return – usually longer than the 15 second time-out we have configured in Apache mod_proxy. That means that
the first page load usualy results in a 503 from Apache. How would I go about configuring connection pooling and starting up some initial connections on Tomcat start as well as a validation check and occasional retirement/regeneration of db connections? Is there a way to interface something like
Tomcat CP or HikariCP with Grouper, or should I just use the options available in the MySQL Connector JAR? Thanks, Keith |
- [grouper-users] Connection pooling to reduce first load time after Tomcat start, Wessel, Keith, 10/03/2016
- [grouper-users] RE: Connection pooling to reduce first load time after Tomcat start, Hyzer, Chris, 10/04/2016
- [grouper-users] RE: Connection pooling to reduce first load time after Tomcat start, Wessel, Keith, 10/04/2016
- [grouper-users] RE: Connection pooling to reduce first load time after Tomcat start, Hyzer, Chris, 10/04/2016
- [grouper-users] RE: Connection pooling to reduce first load time after Tomcat start, Wessel, Keith, 10/04/2016
- [grouper-users] RE: Connection pooling to reduce first load time after Tomcat start, Hyzer, Chris, 10/04/2016
Archive powered by MHonArc 2.6.19.