Re: Poolman under Tomcat 4
Ted, I just installed Tomcat4 and got poolman to work for me. As I said, my typical setup is to have poolman.jar in each WEB-INF/lib and poolman.xml in each WEB-INF/classes. After setting up tomcat4 for struts (copying jaxp.jar and crimson.jar from /tomcat4/jasper to /tomcat4/lib) and for poolman (jdbc2_0-stdext, jta, xerces into /tomcat4/lib), I simply copied one of my webapps to the webapp directory, and it ran fine. Will - Original Message - From: "Ted Husted" <[EMAIL PROTECTED]> To: <[EMAIL PROTECTED]> Sent: Wednesday, August 08, 2001 10:29 AM Subject: Poolman under Tomcat 4 Has anyone using Poolman configured it properly for Tomcat 4? Since it supports both JNDI and a static call for retreiving the datasource, it works well with layered applications. I have it running under Tomcat 3 well enough. But configuring it to play nice with Tomcat 4 is eluding me. I have the requisite poolman support JARs in the Tomcat lib (jdbc2_0-stdext, jta, xerces), except for poolman.jar, which is in its own folder. The poolman.xml is in the poolman folder, and both the JAR and the folder and the JAR on the classpath. I'm using findDatasource(), but the Tomcat log reports it can't find the class. If I move the poolman.jar to the Tomcat4 lib orthe WEB-INF\lib, a "Network Error: Peer reset connection" error is exposed by the browser, and Tomcat suddenly quits. My guess is that TC4 is not finding the poolman.xml (whereas TC3 does). If anyone sorts this out, I'd love to hear about it. Meanwhile, if anyone else is trying Poolman under TC3, I found that it really does want Xerces for the parser, so swap out the Tomcat default. It is also really-not-kidding about having the poolman.xml on the server's classpath. Having it a lib folder isn't enough. But after that, it works just great. You can import the poolman class into your Data Access Object (which is why I have it in its own folder), and have it snag the datasource using a static method (findDataSource(String name), just like our favorite son ;-). This way your Web layer doesn't need to know where the connection is coming from (as recommended by our other favorite Sun 8-). < http://www.codestudio.com/ > -Ted.
Re: Poolman under Tomcat 4
Ahh, the poolman.xml under classes! I was trying it in lib .. so this did help, William! And it works just as well under Tomcat 4, so I'm back to having no CLASSPATH again! -Ted. William Jaynes wrote: > > As another data point, I use resin and tomcat3. I typically configure poolman > locally for each web app. That is, I put poolman.jar into each WEB-INF/lib > directory and an application specific poolman.xml into each WEB-INF/classes > directory. Things also work if I configure poolman globally by putting > poolman.jar into the /resin/lib or /tomcat/lib directory, and putting > poolman.xml into /resin/classes or /tomcat/classes. (this poolman.xml has > configuration for all web apps). > > Things get complicated if one tries to mix local and global configs on the same > app server. > > Unfortunately I haven't used tomcat4 yet, so I can't actually help you out. > > - Original Message - > From: "Alan Inser" <[EMAIL PROTECTED]> > To: <[EMAIL PROTECTED]> > Sent: Wednesday, August 08, 2001 11:20 AM > Subject: RE: Poolman under Tomcat 4 > > Hi Ted, > > In my Tomcat 3 configuration, I put poolman.xml in the WEB-INF folder. Then > you have to add this folder's path in the classpath, see my classpath from > Tomcat.bat: > > set > CP=%CP%;D:\Projects\MyApp\Source\webapps\regbl\WEB-INF;D:\DevTools\JTA\jta.j > ar;D:\DevTools\JavaLibs\classes12.jar;D:\DevTools\JavaLibs\jdbc2_0-stdext.ja > r;D:\DevTools\poolman-2.0.4\lib\poolman.jar;D:\DevTools\poolman-2.0.4\lib\xe > rces.jar; > > I've seen no problem using xerces for Poolman and jaxp for Tomcat 3. > > Adriano Labate > > -Original Message- > From: Ted Husted [mailto:[EMAIL PROTECTED]] > Sent: Wednesday, August 08, 2001 4:30 PM > To: [EMAIL PROTECTED] > Subject: Poolman under Tomcat 4 > > Has anyone using Poolman configured it properly for Tomcat 4? > > Since it supports both JNDI and a static call for retreiving the > datasource, it works well with layered applications. I have it running > under Tomcat 3 well enough. But configuring it to play nice with Tomcat > 4 is eluding me. > > I have the requisite poolman support JARs in the Tomcat lib > (jdbc2_0-stdext, jta, xerces), except for poolman.jar, which is in its > own folder. The poolman.xml is in the poolman folder, and both the JAR > and the folder and the JAR on the classpath. I'm using findDatasource(), > but the Tomcat log reports it can't find the class. > > If I move the poolman.jar to the Tomcat4 lib orthe WEB-INF\lib, a > "Network Error: Peer reset connection" error is exposed by the browser, > and Tomcat suddenly quits. My guess is that TC4 is not finding the > poolman.xml (whereas TC3 does). If anyone sorts this out, I'd love to > hear about it. > > Meanwhile, if anyone else is trying Poolman under TC3, I found that it > really does want Xerces for the parser, so swap out the Tomcat default. > It is also really-not-kidding about having the poolman.xml on the > server's classpath. Having it a lib folder isn't enough. > > But after that, it works just great. You can import the poolman class > into your Data Access Object (which is why I have it in its own folder), > and have it snag the datasource using a static method > (findDataSource(String name), just like our favorite son ;-). > > This way your Web layer doesn't need to know where the connection is > coming from (as recommended by our other favorite Sun 8-). > > < http://www.codestudio.com/ > > > -Ted.
Re: Poolman under Tomcat 4
As another data point, I use resin and tomcat3. I typically configure poolman locally for each web app. That is, I put poolman.jar into each WEB-INF/lib directory and an application specific poolman.xml into each WEB-INF/classes directory. Things also work if I configure poolman globally by putting poolman.jar into the /resin/lib or /tomcat/lib directory, and putting poolman.xml into /resin/classes or /tomcat/classes. (this poolman.xml has configuration for all web apps). Things get complicated if one tries to mix local and global configs on the same app server. Unfortunately I haven't used tomcat4 yet, so I can't actually help you out. - Original Message - From: "Alan Inser" <[EMAIL PROTECTED]> To: <[EMAIL PROTECTED]> Sent: Wednesday, August 08, 2001 11:20 AM Subject: RE: Poolman under Tomcat 4 Hi Ted, In my Tomcat 3 configuration, I put poolman.xml in the WEB-INF folder. Then you have to add this folder's path in the classpath, see my classpath from Tomcat.bat: set CP=%CP%;D:\Projects\MyApp\Source\webapps\regbl\WEB-INF;D:\DevTools\JTA\jta.j ar;D:\DevTools\JavaLibs\classes12.jar;D:\DevTools\JavaLibs\jdbc2_0-stdext.ja r;D:\DevTools\poolman-2.0.4\lib\poolman.jar;D:\DevTools\poolman-2.0.4\lib\xe rces.jar; I've seen no problem using xerces for Poolman and jaxp for Tomcat 3. Adriano Labate -Original Message- From: Ted Husted [mailto:[EMAIL PROTECTED]] Sent: Wednesday, August 08, 2001 4:30 PM To: [EMAIL PROTECTED] Subject: Poolman under Tomcat 4 Has anyone using Poolman configured it properly for Tomcat 4? Since it supports both JNDI and a static call for retreiving the datasource, it works well with layered applications. I have it running under Tomcat 3 well enough. But configuring it to play nice with Tomcat 4 is eluding me. I have the requisite poolman support JARs in the Tomcat lib (jdbc2_0-stdext, jta, xerces), except for poolman.jar, which is in its own folder. The poolman.xml is in the poolman folder, and both the JAR and the folder and the JAR on the classpath. I'm using findDatasource(), but the Tomcat log reports it can't find the class. If I move the poolman.jar to the Tomcat4 lib orthe WEB-INF\lib, a "Network Error: Peer reset connection" error is exposed by the browser, and Tomcat suddenly quits. My guess is that TC4 is not finding the poolman.xml (whereas TC3 does). If anyone sorts this out, I'd love to hear about it. Meanwhile, if anyone else is trying Poolman under TC3, I found that it really does want Xerces for the parser, so swap out the Tomcat default. It is also really-not-kidding about having the poolman.xml on the server's classpath. Having it a lib folder isn't enough. But after that, it works just great. You can import the poolman class into your Data Access Object (which is why I have it in its own folder), and have it snag the datasource using a static method (findDataSource(String name), just like our favorite son ;-). This way your Web layer doesn't need to know where the connection is coming from (as recommended by our other favorite Sun 8-). < http://www.codestudio.com/ > -Ted.
RE: Poolman under Tomcat 4
Hi Ted, In my Tomcat 3 configuration, I put poolman.xml in the WEB-INF folder. Then you have to add this folder's path in the classpath, see my classpath from Tomcat.bat: set CP=%CP%;D:\Projects\MyApp\Source\webapps\regbl\WEB-INF;D:\DevTools\JTA\jta.j ar;D:\DevTools\JavaLibs\classes12.jar;D:\DevTools\JavaLibs\jdbc2_0-stdext.ja r;D:\DevTools\poolman-2.0.4\lib\poolman.jar;D:\DevTools\poolman-2.0.4\lib\xe rces.jar; I've seen no problem using xerces for Poolman and jaxp for Tomcat 3. Adriano Labate -Original Message- From: Ted Husted [mailto:[EMAIL PROTECTED]] Sent: Wednesday, August 08, 2001 4:30 PM To: [EMAIL PROTECTED] Subject: Poolman under Tomcat 4 Has anyone using Poolman configured it properly for Tomcat 4? Since it supports both JNDI and a static call for retreiving the datasource, it works well with layered applications. I have it running under Tomcat 3 well enough. But configuring it to play nice with Tomcat 4 is eluding me. I have the requisite poolman support JARs in the Tomcat lib (jdbc2_0-stdext, jta, xerces), except for poolman.jar, which is in its own folder. The poolman.xml is in the poolman folder, and both the JAR and the folder and the JAR on the classpath. I'm using findDatasource(), but the Tomcat log reports it can't find the class. If I move the poolman.jar to the Tomcat4 lib orthe WEB-INF\lib, a "Network Error: Peer reset connection" error is exposed by the browser, and Tomcat suddenly quits. My guess is that TC4 is not finding the poolman.xml (whereas TC3 does). If anyone sorts this out, I'd love to hear about it. Meanwhile, if anyone else is trying Poolman under TC3, I found that it really does want Xerces for the parser, so swap out the Tomcat default. It is also really-not-kidding about having the poolman.xml on the server's classpath. Having it a lib folder isn't enough. But after that, it works just great. You can import the poolman class into your Data Access Object (which is why I have it in its own folder), and have it snag the datasource using a static method (findDataSource(String name), just like our favorite son ;-). This way your Web layer doesn't need to know where the connection is coming from (as recommended by our other favorite Sun 8-). < http://www.codestudio.com/ > -Ted.