Tomcat JDBC pool
I am a bit stuck in an attempt to set up a JDBC pool on my tcserver set up by the deploy.
There are 2 issues I am running up against getting this set up:
1) I believe the overall concept to add the Resource to the server.xml would be in the initialization script of the deployment but couldn't think of the best way to do this. I know I could do something like a sed in the script but it feels a bit messy to do it this way. Is there a best practice for this?
2) I decided just to try it to go in and just adjust the server.xml file by hand on the server to add my pooled jdbc connection Resource but when I kicked off a restart server, I got a ClassNotFound for this:
I see in the lib directory that this jar is here which contains that class: /var/lib/tcServer-6.0.20.C-GA-solaris-x86-node/tcServer-6.0/tomcat-6.0.20.C/libtomcat-jdbc.jar
So I'd imagine it would have been in the classpath. So I was at a loss as to why the class wouldn't be found.
Any advice would be greatly appreciated!
I've answered my own question on #1. After reading various posts on the forum, it seems the best way to handle this is mounting a EBS volume that contains the customized config file and then the custom script should copy over the customized files to replace the std one.
I'm still stuck on my #2 though and still at a loss why the class is not found. The jar is definitely in the lib directory (if I'm looking at the right one!) and I've verified that jar contains the class. I'm hoping someone can point me in the right direction on this one. I'd very much like to go with the Tomcat managed pool if I can get that going.