Return-Path: Delivered-To: apmail-jakarta-tomcat-user-archive@apache.org Received: (qmail 13995 invoked from network); 19 Aug 2002 15:50:45 -0000 Received: from unknown (HELO nagoya.betaversion.org) (192.18.49.131) by daedalus.apache.org with SMTP; 19 Aug 2002 15:50:45 -0000 Received: (qmail 1066 invoked by uid 97); 19 Aug 2002 15:50:11 -0000 Delivered-To: qmlist-jakarta-archive-tomcat-user@jakarta.apache.org Received: (qmail 971 invoked by uid 97); 19 Aug 2002 15:50:09 -0000 Mailing-List: contact tomcat-user-help@jakarta.apache.org; run by ezmlm Precedence: bulk List-Unsubscribe: List-Subscribe: List-Help: List-Post: List-Id: "Tomcat Users List" Reply-To: "Tomcat Users List" Delivered-To: mailing list tomcat-user@jakarta.apache.org Received: (qmail 869 invoked by uid 98); 19 Aug 2002 15:50:09 -0000 X-Antivirus: nagoya (v4198 created Apr 24 2002) Message-ID: <20020819154937.74362.qmail@web13509.mail.yahoo.com> Date: Mon, 19 Aug 2002 08:49:37 -0700 (PDT) From: Luminous Heart Subject: RE: It would be great IF somebody answered me, ONCE, for change :( To: Tomcat Users List In-Reply-To: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Spam-Rating: daedalus.apache.org 1.6.2 0/1000/N X-Spam-Rating: daedalus.apache.org 1.6.2 0/1000/N I am sorry, but I did not get what you mean with connection limit to be a hard limit, which one is that? I am including a copy of my pool.xml if you care do point out what should be changed. Thank you in advance. ==================== Pool.xml ===================== local webdev webdev org.postgresql.Driver jdbc:postgresql://localhost:6093/webdev JustAUserName JustAUserNamePassword true 1 10 600 12 10 /usr/local/tomcat/logs/poolman.log false false 20 120 ==================== End Pool.xml ================= --- Mike Jackson wrote: > Actually now that I think about it more that might > be the cause of the null > pointer (but > probably not). In your poolman.xml file have you > set the connection limit > to be a hard > limit? If you timeout on connections (user timeout) > is fairly high you > could run out of > connections, and it might return a "null" instead of > a connection. > > But that's just a guess. Also, you might was to > also turn on logging (debug > level) in > poolman as well so that you can watch the > connections getting checked out > and in. > > --mikej > -=----- > mike jackson > mjackson@cdi-hq.com > > > -----Original Message----- > > From: Luminous Heart > [mailto:luminousheart@yahoo.com] > > Sent: Monday, August 19, 2002 8:36 AM > > To: Tomcat Users List > > Subject: Re: It would be great IF somebody > answered me, ONCE, for change > > :( > > > > > > Hi Graig, > > Here is my jsp file. I am not sure what might be > > wrong. Although the same error happens in a bigger > > application in a tc cluster of 3 tomcats. Two of > these > > tcs fail while one does not get any forwards after > > that. > > > > Please take a look at my code, if you do not mind. > > > > Best regards. > > > > ===================== JSP ===================== > > <%@ page import="java.io.*" %> > > <%@ page import="java.util.*" %> > > <%@ page import="java.text.*" %> > > > > <%@ page import="java.util.Properties" %> > > <%@ page import="java.util.Date" %> > > > > <%@ page contentType="text/html"%> > > > > <%@ page import="com.codestudio.util.*"%> > > <%@ page import="java.sql.*"%> > > > > > > > >
> name="access_form"> > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > >
> > size=5>User Access   
> >
> > border=0> > > > > > > > > > >
> size=5>User Access by userid
User > > Name
> > name="byusername" > > size=25 value="" maxlength=25> > >
> >
> >
> >
> > border=0> > > > > > > > > > >
> size=5>User Access by Date size=1> > >
Date
> > > value="" size=25 maxlength=125> > >
> >
> >
> >
> >
> > border=0> > > > > > > > > > >
> size=5>USER Access by IP Address > >
IP > Address
> > name="byipaddress" > > value="" size=25 maxlength=125> > >
> >
> >
> >
  > > > name="submit"> > >  
> >
> > <% > > String inUser = null; > > String inDate = null; > > String inIPadd = null; > > > > try{ > > inUser = > > (request.getParameter("byusername")).trim(); > > if (inUser == null) inUser = ""; > > inDate = > request.getParameter("bydate").trim(); > > if (inDate == null) inDate = ""; > > inIPadd = > > request.getParameter("byipaddress").trim(); > > if (inIPadd == null) inIPadd = ""; > > > > }catch(NullPointerException npe){ > > out.println("Please choose a query option."); > > > > } > > > > PreparedStatement ps = null; > > /* Log user access count to the system */ > > > > SQLManager thisManager = null; > > if (thisManager == null) > > thisManager = SQLManager.getInstance(); > > > > Connection myConn = null; > > > > if (myConn == null) > > myConn = thisManager.requestConnection(); > > if (((inUser != null) && !inUser.equals("") ) || > > ((inDate != null) && !inDate.equals("")) || > ((inIPadd > > != null) && !inIPadd.equals(""))) > > { > > > > java.util.Date today = new > java.util.Date(); > > java.sql.Timestamp stamp = new > > java.sql.Timestamp(today.getTime()); > > > > String stampStr = stamp.toString(); > > > > String timeofday = > > stampStr.substring(11,stampStr.length()); > > String date = stampStr.substring(0,11); > > > > String todayatZero = date + " > 00:00:00.0000"; > > > > todayatZero = "2002-08-01 00:00:00.0000"; > > > > inDate += " 00:00:00.0000"; > > > > boolean ValueEntered = false; > > if (((inUser != null)&& (inDate != null) && > (inIPadd > > != null)) && (!inUser.equals("") && > !inDate.equals("") > > && !inIPadd.equals("")) ) > === message truncated === __________________________________________________ Do You Yahoo!? HotJobs - Search Thousands of New Jobs http://www.hotjobs.com -- To unsubscribe, e-mail: For additional commands, e-mail: