the only time i lost request parameters was because the form was multipart/form-data. In that case you need to use a form upload processer like commons FileUploader.
ADC -----Original Message----- From: Shapira, Yoav [mailto:[EMAIL PROTECTED] Sent: 13 April 2004 13:49 To: Tomcat Users List Subject: RE: Request parameters getting lost Hi, Whatever the root cause of this issue is, your servlets should be tolerant of these parameters not being specified, i.e. being null. You should never NPE in your own code due to improper input parameter checking. Yoav Shapira Millennium Research Informatics >-----Original Message----- >From: Frank W. Zammetti [mailto:[EMAIL PROTECTED] >Sent: Monday, April 12, 2004 7:51 PM >To: [EMAIL PROTECTED] >Subject: Request parameters getting lost > >I have a very odd situation... > >I have an app running on Tomcat 5.0.1.8. We're using it as both a web >server and servlet container. What's happening is I'm getting >NullPointerExceptions in both JSP's and servlets that is a result of >request >parameters seemingly being lost somewhere along the way. In other words, >if >I submit a form to a servlet with a couple of fields, the parameters are >not >showing up in the request object, hence I get NullPointerExceptions trying >to access them. > >This is an intermittent problem, in fact it's fairly rare (which has saved >my a** at work thus far!), but I still have not been able to explain it. >It >is happening at various points in my app, no consistent pattern that I've >been able to discern, all of which should theoretically be impossible to >have no parameters because the user is forced to enter things via >JavaScript, or clicking a button submits a hidden form, things like that. >I've tried the best I can to get it to happen on my development >installation, but of course I've been unable to replicate it, but I have >seen it on the production server so I know it's not just a stupid user >trick >(although I can't rule out them doing something stupid that I just haven't >imagined). > >I have a sneaking suspicion that it's a server tuning issue, and in fact I >just did some reading and it looks like my predecessor in charge of tuning >Tomcat really screwed up some things. Here's his connector configuration: > > <Connector > allowTrace="true" > enableLookups="false" > redirectPort="8443" > secure="false" > acceptCount="100" > bufferSize="4096" > compression="off" > connectionLinger="-1" > connectionTimeout="60000" > debug="0" > disableUploadTimeout="true" > maxHttpHeaderSize="8192" > maxKeepAliveRequests="200" > maxSpareThreads="175" > maxThreads="300" > minSpareThreads="100" > port="8181" > socketBuffer="12000" > tcpNoDelay="true" > /> > >That looks incredibly wrong to me in terms of tuning. The app has a TOTAL >of 87 users, and not all of them are using the app at the same time, and >the >requests are certainly not coming all at the same time. I'm guessing we're >talking about an average of maybe 20 concurrent requests at any given time, >not a huge load by any stretch. > >So, my question is twofold... One, has anyone ever seen such an issue as >missing parameters before, and if so, what information can you share with >me >about it? Two, am I off my rocker to think that connector config is way >out >of wack, and assuming it is, what suggestions would you guys have to fix >it, >given the approximate load I've stated here? > >Thanks in advance everyone! > >Frank > > > >--------------------------------------------------------------------- >To unsubscribe, e-mail: [EMAIL PROTECTED] >For additional commands, e-mail: [EMAIL PROTECTED] This e-mail, including any attachments, is a confidential business communication, and may contain information that is confidential, proprietary and/or privileged. This e-mail is intended only for the individual(s) to whom it is addressed, and may not be saved, copied, printed, disclosed or used by anyone else. If you are not the(an) intended recipient, please immediately delete this e-mail from your computer system and notify the sender. Thank you. --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] <FONT SIZE=1 FACE="VERDANA,ARIAL" COLOR=BLUE> ------------------------------------------------------- QAS Ltd. Developers of QuickAddress Software <a href="http://www.qas.com">www.qas.com</a> Registered in England: No 2582055 Registered in Australia: No 082 851 474 ------------------------------------------------------- </FONT> --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
