unified doXXX()
I am refactoring a servlet we have used successfully for several years now to accommodate input that does not amen itself to HttpServletRequest.getParameter()... The only way it seems to be to handle our particular input (the nature/format of the input is covered by an NDA so I can not discuss it in any detail) read the raw request in the old servlet HttpServletRequest.getParameter() had a nice side effect that we where able to do something like this: public void doGet(HttpServletRequest request,HttpServletResponse response) throws IOException { handleRequest(request,response); } public void doPost(HttpServletRequest request,HttpServletResponse response) throws IOException { handleRequest(request,response); } private void handleRequest(HttpServletRequest request,HttpServletResponse response) { String input=Request.getParameter("foo"); // we are only interested in this one param process input } I want to preserve the single handler design but since getParameter barfs on our new input format and there is no unified raw input reader the only thing I can think of is make it so doGet and doPost use request.getQueryString() and request.getReader() respectivally... is there an easier way? (namely I want to keep doXXX as pure wrappers with nothing but a dispatch to handleRequest()). - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
possible memory leak tomcat 6?
Hi, My tomcat server gives often a out of mem. When dumping the heap I found much instances of these objects: Class InstanceCount TotalSize class org.apache.tomcat.util.buf.ByteChunk 439493 20656171 class org.apache.tomcat.util.buf.CharChunk 432383 16862937 class org.apache.tomcat.util.buf.MessageBytes 414753 24055674 My configuration: Tomcat: 6.0.16 Java: 1.6.0_14 OS: Solaris 10 Can this be a memory leak in Tomcat? Regards, Sander - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
SV: ROOT.war - how to access web.xml
By the way. I also have info as init-param in my struts servlet configured in the web.xml So I guess I should just loose the getServlet.getInitParameter and just use getServletContext().getInitParameter??? By the way I dont have access to the conf. I guess I have access to ROOT or webapps. Can I put the context.xml fil there? -Oprindelig meddelelse- Fra: Caldarale, Charles R [mailto:chuck.caldar...@unisys.com] Sendt: 27. februar 2010 19:21 Til: Tomcat Users List Emne: RE: ROOT.war - how to access web.xml > From: Søren Blidorf [mailto:so...@nolas.dk] > Subject: ROOT.war - how to access web.xml > > I have deployed my ROOT.war file. Is there any way to access > the web.xml. > > I save db login info in it and I would like to be able to > deploy the same ROOT.war file on different sites and only > change the web.xml after. Don't put the site-specific parameters in web.xml. Instead, nest them inside a element in a companion file to be located in conf/Catalina/[host]/ROOT.xml on each server. Use the or elements as appropriate. Look here for details: http://tomcat.apache.org/tomcat-6.0-doc/config/context.html#Context%20Parame ters http://tomcat.apache.org/tomcat-6.0-doc/config/context.html#Environment%20En tries - Chuck THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY MATERIAL and is thus for use only by the intended recipient. If you received this in error, please contact the sender and delete the e-mail and its attachments from all computers. - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
SV: ROOT.war - how to access web.xml
Great. I'll try that. Thanks alot -Oprindelig meddelelse- Fra: Caldarale, Charles R [mailto:chuck.caldar...@unisys.com] Sendt: 27. februar 2010 19:21 Til: Tomcat Users List Emne: RE: ROOT.war - how to access web.xml > From: Søren Blidorf [mailto:so...@nolas.dk] > Subject: ROOT.war - how to access web.xml > > I have deployed my ROOT.war file. Is there any way to access > the web.xml. > > I save db login info in it and I would like to be able to > deploy the same ROOT.war file on different sites and only > change the web.xml after. Don't put the site-specific parameters in web.xml. Instead, nest them inside a element in a companion file to be located in conf/Catalina/[host]/ROOT.xml on each server. Use the or elements as appropriate. Look here for details: http://tomcat.apache.org/tomcat-6.0-doc/config/context.html#Context%20Parame ters http://tomcat.apache.org/tomcat-6.0-doc/config/context.html#Environment%20En tries - Chuck THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY MATERIAL and is thus for use only by the intended recipient. If you received this in error, please contact the sender and delete the e-mail and its attachments from all computers. - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
RE: ROOT.war - how to access web.xml
> From: Søren Blidorf [mailto:so...@nolas.dk] > Subject: ROOT.war - how to access web.xml > > I have deployed my ROOT.war file. Is there any way to access > the web.xml. > > I save db login info in it and I would like to be able to > deploy the same ROOT.war file on different sites and only > change the web.xml after. Don't put the site-specific parameters in web.xml. Instead, nest them inside a element in a companion file to be located in conf/Catalina/[host]/ROOT.xml on each server. Use the or elements as appropriate. Look here for details: http://tomcat.apache.org/tomcat-6.0-doc/config/context.html#Context%20Parameters http://tomcat.apache.org/tomcat-6.0-doc/config/context.html#Environment%20Entries - Chuck THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY MATERIAL and is thus for use only by the intended recipient. If you received this in error, please contact the sender and delete the e-mail and its attachments from all computers. - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: ROOT.war - how to access web.xml
2010/2/27 Søren Blidorf : > When it is deployed the only thing I see when I FTP the site is the ROOT.war > file. If the war isn't being expanded your options to change it are limited. But it's rare (in my experience) for apps to be run from a packed war; you might want to look around a bit. Though you could manually unpack it somewhere, edit. repack and redeploy. Otherwise, you really need to configure the web.xml as part of your build process for each location. -- Hassan Schroeder hassan.schroe...@gmail.com twitter: @hassan - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
SV: ROOT.war - how to access web.xml
When it is deployed the only thing I see when I FTP the site is the ROOT.war file. -Oprindelig meddelelse- Fra: Hassan Schroeder [mailto:hassan.schroe...@gmail.com] Sendt: 27. februar 2010 19:10 Til: Tomcat Users List Emne: Re: ROOT.war - how to access web.xml 2010/2/27 Søren Blidorf : > Thanks, but I dont know what you mean. Assuming your war is being expanded, log in and edit the file. Or is that an incorrect assumption? -- Hassan Schroeder hassan.schroe...@gmail.com twitter: @hassan - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: ROOT.war - how to access web.xml
2010/2/27 Søren Blidorf : > Thanks, but I dont know what you mean. Assuming your war is being expanded, log in and edit the file. Or is that an incorrect assumption? -- Hassan Schroeder hassan.schroe...@gmail.com twitter: @hassan - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
SV: ROOT.war - how to access web.xml
Hi. Thanks, but I dont know what you mean. Kind of newbie in .war -Oprindelig meddelelse- Fra: Hassan Schroeder [mailto:hassan.schroe...@gmail.com] Sendt: 27. februar 2010 19:04 Til: Tomcat Users List Emne: Re: ROOT.war - how to access web.xml 2010/2/27 Søren Blidorf : > I have deployed my ROOT.war file. Is there any way to access the web.xml. > > I save db login info in it and I would like to be able to deploy the same > ROOT.war file on different sites and only change the web.xml after. ssh + vi should do it, eh? -- Hassan Schroeder hassan.schroe...@gmail.com twitter: @hassan - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: ROOT.war - how to access web.xml
2010/2/27 Søren Blidorf : > I have deployed my ROOT.war file. Is there any way to access the web.xml. > > I save db login info in it and I would like to be able to deploy the same > ROOT.war file on different sites and only change the web.xml after. ssh + vi should do it, eh? -- Hassan Schroeder hassan.schroe...@gmail.com twitter: @hassan - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
ROOT.war - how to access web.xml
I have deployed my ROOT.war file. Is there any way to access the web.xml. I save db login info in it and I would like to be able to deploy the same ROOT.war file on different sites and only change the web.xml after. Soren
Re: SV: When I link to a *.do I get "Page not found"
No log information to me implies: 1. The log information is being caught and written to a log file before it get's to stdout/stderr. Find the log file and you'll see your messages. 2. You may not be hitting the resource you think you are hitting. Double check your URL 3. Maybe your webapp has to be restarted to load the servlet. Normally not necessary, but if automatic reloading was shutoff on the hosted server, that might be needed. 4. If the whole webapp is new to the server, maybe it didn't deploy. In that case, the request goes to the ROOT webapp and you get a 404 error. You'll have to work with your hosting provider to find out why and how to fix it. All this is pure guessing at the moment. You really haven't provided enough detail for us to offer any really solid advice. --David On 2/27/2010 11:28 AM, Søren Blidorf wrote: > I dont have full acces to logs, but no error comes in stdout or stderr. > > Same tomcat version. But not sure about the jvm - I'll start there. > > Thanks. > > -Oprindelig meddelelse- > Fra: David Smith [mailto:d...@cornell.edu] > Sendt: 27. februar 2010 15:17 > Til: Tomcat Users List > Emne: Re: When I link to a *.do I get "Page not found" > > On 2/27/2010 8:31 AM, Søren Blidorf wrote: > >> I have made a struts application and it works just fine on my testserver. >> >> >> >> I have now uploaded it to my hosted webserver and struts does not work. >> >> >> >> When I link to a *.do I get “Page not found” >> >> >> >> Could it be a Tomcat config problem. Placing the jars and classes ect. >> >> >> >> Struts 1.2 // Tomcat 5.5 >> >> >> >> Soren >> >> >> >> >> >> > You'll have to look at your logs. It could be a lot of things causing a > 404 response including an error that prevents the servlet from being > initialized. Are you sure your test environment matches the hosted > server's version of tomcat and jvm? > > --David > > - > To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org > For additional commands, e-mail: users-h...@tomcat.apache.org > > > - > To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org > For additional commands, e-mail: users-h...@tomcat.apache.org > > -- David Smith Programmer/Analyst College of Agriculture and Life Sciences Cornell University B32 Morrison Hall Ithaca, NY 14853 Phone: (607) 255-4334 - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
SV: When I link to a *.do I get "Page not found"
I dont have full acces to logs, but no error comes in stdout or stderr. Same tomcat version. But not sure about the jvm - I'll start there. Thanks. -Oprindelig meddelelse- Fra: David Smith [mailto:d...@cornell.edu] Sendt: 27. februar 2010 15:17 Til: Tomcat Users List Emne: Re: When I link to a *.do I get "Page not found" On 2/27/2010 8:31 AM, Søren Blidorf wrote: > I have made a struts application and it works just fine on my testserver. > > > > I have now uploaded it to my hosted webserver and struts does not work. > > > > When I link to a *.do I get Page not found > > > > Could it be a Tomcat config problem. Placing the jars and classes ect. > > > > Struts 1.2 // Tomcat 5.5 > > > > Soren > > > > > You'll have to look at your logs. It could be a lot of things causing a 404 response including an error that prevents the servlet from being initialized. Are you sure your test environment matches the hosted server's version of tomcat and jvm? --David - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: IIS7 + ISAPI Redirector on 64Bit Server Platform
On 02/27/2010 03:53 PM, David Bolsover wrote: Mladen Brilliant - thanks for this; the release candidate fixes the problem I had encountered. Cool. I'll check out the full release version when available. Should be the same binary We just copy dev/ to dist/ once when voted as a release. Regards -- ^TM - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
RE: IIS7 + ISAPI Redirector on 64Bit Server Platform
Jordan Thanks for the suggestion - but have solved my particular problem using the 1.2.30 rc connector. DB -Original Message- From: Jordan Michaels [mailto:jor...@viviotech.net] Sent: 27 February 2010 06:25 To: Tomcat Users List Subject: Re: IIS7 + ISAPI Redirector on 64Bit Server Platform If it helps, I was never able to get the blasted thing to work either. I was, however, able to get 32-bit to work just fine, and have been using it for just about everything, with no issues. Wish I could help more! -Jordan - Original Message - From: "David Bolsover" To: users@tomcat.apache.org Sent: Friday, February 26, 2010 5:00:33 PM GMT -08:00 US/Canada Pacific Subject: IIS7 + ISAPI Redirector on 64Bit Server Platform Environment: Server Hardware: Dell T110 : Intel Xeon X3430, 4Gb RAM. OS: Windows Small Business Server 2008 fully patched. SQL Server standard 2008 IIS: 7.0.6000.16386 Java version "1.6.0_18" Java(TM) SE Runtime Environment (build 1.6.0_18-b07) Java HotSpot(TM) 64-Bit Server VM (build 16.0-b13, mixed mode) Tomcat: 6.0.24 ISAPI isapi_redirect-1.2.29 (amd64). Client Windows 7 filly patched, IE 8.0 Issue: Access to web application on Tomcat via port 8080, all pages are delivered correctly - no problems. Access to same web application via IIS with redirector, only the index page is delivered. Links to page menu items are non responsive although it appears that backend calls to the database are being made in response to clicks on the links - but no new pages are delivered to the client. At my wits end - same application performs flawlessly when run on Windows 7 IIS7 using 32bit redirector. Seeking inspiration on how to debug / solve this problem. Regards, DB - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
RE: IIS7 + ISAPI Redirector on 64Bit Server Platform
Thanks, just tried the 1.2.30 rc - solves my problem :-) -Original Message- From: Pid [mailto:p...@pidster.com] Sent: 27 February 2010 10:42 To: Tomcat Users List Subject: Re: IIS7 + ISAPI Redirector on 64Bit Server Platform On 27/02/2010 01:00, David Bolsover wrote: > Environment: > Server Hardware: Dell T110 : Intel Xeon X3430, 4Gb RAM. > OS: Windows Small Business Server 2008 fully patched. > SQL Server standard 2008 > IIS: 7.0.6000.16386 > Java version "1.6.0_18" > Java(TM) SE Runtime Environment (build 1.6.0_18-b07) > Java HotSpot(TM) 64-Bit Server VM (build 16.0-b13, mixed mode) > Tomcat: 6.0.24 > ISAPI isapi_redirect-1.2.29 (amd64). > > Client Windows 7 filly patched, IE 8.0 > > Issue: > Access to web application on Tomcat via port 8080, all pages are delivered > correctly - no problems. > > Access to same web application via IIS with redirector, only the index page > is delivered. Links to page menu items are non responsive although it appears > that backend calls to the database are being made in response to clicks on > the links - but no new pages are delivered to the client. > > At my wits end - same application performs flawlessly when run on Windows 7 > IIS7 using 32bit redirector. > > Seeking inspiration on how to debug / solve this problem. 1.2.30 will be released fairly rapidly, as a bug has been reported in connectors 1.2.29. You could try an earlier release until then. p - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
RE: IIS7 + ISAPI Redirector on 64Bit Server Platform
Mladen Brilliant - thanks for this; the release candidate fixes the problem I had encountered. I'll check out the full release version when available. DB -Original Message- From: Mladen Turk [mailto:mt...@apache.org] Sent: 27 February 2010 11:18 To: Tomcat Users List Subject: Re: IIS7 + ISAPI Redirector on 64Bit Server Platform On 02/27/2010 11:42 AM, Pid wrote: > On 27/02/2010 01:00, David Bolsover wrote: >> >> At my wits end - same application performs flawlessly when run on >> Windows 7 IIS7 using 32bit redirector. >> >> Seeking inspiration on how to debug / solve this problem. > > 1.2.30 will be released fairly rapidly, as a bug has been reported in > connectors 1.2.29. You could try an earlier release until then. > Right, 1.2.30 is in the release process already Candidate is available from: http://tomcat.apache.org/dev/dist/tomcat-connectors/jk/binaries/ It'll be visible in couple of hours after web server sync. Regards -- ^TM - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: When I link to a *.do I get "Page not found"
On 2/27/2010 8:31 AM, Søren Blidorf wrote: > I have made a struts application and it works just fine on my testserver. > > > > I have now uploaded it to my hosted webserver and struts does not work. > > > > When I link to a *.do I get “Page not found” > > > > Could it be a Tomcat config problem. Placing the jars and classes ect. > > > > Struts 1.2 // Tomcat 5.5 > > > > Soren > > > > > You'll have to look at your logs. It could be a lot of things causing a 404 response including an error that prevents the servlet from being initialized. Are you sure your test environment matches the hosted server's version of tomcat and jvm? --David - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
When I link to a *.do I get "Page not found"
I have made a struts application and it works just fine on my testserver. I have now uploaded it to my hosted webserver and struts does not work. When I link to a *.do I get Page not found Could it be a Tomcat config problem. Placing the jars and classes ect. Struts 1.2 // Tomcat 5.5 Soren
RE: DB connection error -Tomcat 6 config
Hi, Am Donnerstag, den 25.02.2010, 14:45 -0600 schrieb Propes, Barry L : > Sorry for the delay - supplying both my META-INF/context.xml and > webapps/WEB-INF/web.xml contents. just to be sure, the dirs META-INF and WEB-INF are both located inside your webapplication, right? Have you checked, that there is no context file present in conf/Catalina/localhost? That file would be checked first by tomcat and all your editing in META-INF/context.xml would have no effect. Bye Felix > > > Should be noted: for the factory type in the params below, I tried both > factory="org.apache.commons.dbcp.BasicDataSourceFactory" and > factory="org.apache.dbcp.BasicDataSourceFactory", each to no avail. > > I removed the commons ref to test out since there's no commons/lib dir in TC > 6.0.24, unlike in TC 4.1.31 > > Please apprise if the error is glaring here and I just can't see it. That's > certainly possible! > > Thanks, Chuck. > > > context.xml in META-INF fldr > - > > > > > auth="Container" > type="javax.sql.DataSource" > factory="org.apache.commons.dbcp.BasicDataSourceFactory" > maxActive="125" > maxIdle="15" > maxWait="7000" > removeAbandoned="true" > removeAbandonedTimeout="30" > logAbandoned="true" > username="user_name" > password="pass_word" > driverClassName="oracle.jdbc.OracleDriver" > url="jdbc:oracle:thin:@159.177.102.100:1526:MYSID" > minEvictableIdleTimeMillis="5000" > timeBetweenEvictionRunsMillis = "1" > testWhileIdle="true" > /> > > > > in webapps/WEB-INF/web.xml > > > My Ora datasource > jdbc/myoracle > javax.sql.DataSource > Container > > > -Original Message- > From: Caldarale, Charles R [mailto:chuck.caldar...@unisys.com] > Sent: Tuesday, February 23, 2010 5:53 PM > To: Tomcat Users List > Subject: RE: DB connection error -Tomcat 6 config > > If you don't mind, post your element again. The error message > indicates something doesn't match between what your JSP/servlet is requesting > and what's registered via the element. > > - Chuck > > > - > To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org > For additional commands, e-mail: users-h...@tomcat.apache.org > - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: IIS7 + ISAPI Redirector on 64Bit Server Platform
On 02/27/2010 11:42 AM, Pid wrote: On 27/02/2010 01:00, David Bolsover wrote: At my wits end - same application performs flawlessly when run on Windows 7 IIS7 using 32bit redirector. Seeking inspiration on how to debug / solve this problem. 1.2.30 will be released fairly rapidly, as a bug has been reported in connectors 1.2.29. You could try an earlier release until then. Right, 1.2.30 is in the release process already Candidate is available from: http://tomcat.apache.org/dev/dist/tomcat-connectors/jk/binaries/ It'll be visible in couple of hours after web server sync. Regards -- ^TM - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: IIS7 + ISAPI Redirector on 64Bit Server Platform
On 27/02/2010 01:00, David Bolsover wrote: Environment: Server Hardware: Dell T110 : Intel Xeon X3430, 4Gb RAM. OS: Windows Small Business Server 2008 fully patched. SQL Server standard 2008 IIS: 7.0.6000.16386 Java version "1.6.0_18" Java(TM) SE Runtime Environment (build 1.6.0_18-b07) Java HotSpot(TM) 64-Bit Server VM (build 16.0-b13, mixed mode) Tomcat: 6.0.24 ISAPI isapi_redirect-1.2.29 (amd64). Client Windows 7 filly patched, IE 8.0 Issue: Access to web application on Tomcat via port 8080, all pages are delivered correctly - no problems. Access to same web application via IIS with redirector, only the index page is delivered. Links to page menu items are non responsive although it appears that backend calls to the database are being made in response to clicks on the links - but no new pages are delivered to the client. At my wits end - same application performs flawlessly when run on Windows 7 IIS7 using 32bit redirector. Seeking inspiration on how to debug / solve this problem. 1.2.30 will be released fairly rapidly, as a bug has been reported in connectors 1.2.29. You could try an earlier release until then. p - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org