Re: application.getRealPath() in JSP from a subdirectory

2009-01-30 Thread Mark Thomas
Qiao Jin wrote: > Serving mydomain.com, what I have is one application in an unpacked > directory, 'app-root', with jsp files located in the root dir or its > subdirs. The Host for mydomain.com has its appBase pointing to 'app-root'. > > The ROOT.xml for mydomain.com has only one line: reloadabl

Shared Library Issue using JVM ext

2009-01-30 Thread Ishtiaq Ahmed
Hi follks, I know this has been discussed many time but couldn't find the exact thing I am looking for. I am deploying several application over tomcat6. Each having its own libraries in "WEB-INF/lib". Many of the applications are using the same libraries like " hibernate3.jar" so this is inc

RE: application.getRealPath() in JSP from a subdirectory

2009-01-30 Thread Qiao Jin
Serving mydomain.com, what I have is one application in an unpacked directory, 'app-root', with jsp files located in the root dir or its subdirs. The Host for mydomain.com has its appBase pointing to 'app-root'. The ROOT.xml for mydomain.com has only one line: I read the document on the two at

RE: application.getRealPath() in JSP from a subdirectory

2009-01-30 Thread Qiao Jin
I will look into your suggestion. Could you elaborate a bit on your statement: "Using getRealPath() inside an app server of any kind is pretty much always a Bad Idea"? Thanks Qiao -Original Message- From: Caldarale, Charles R [mailto:chuck.caldar...@unisys.com] Sent: Friday, January 30,

Re: application.getRealPath() in JSP from a subdirectory

2009-01-30 Thread Mark Thomas
Qiao Jin wrote: > Chuck, thanks for your response. It turns out that the auto-deploy switch > does affect the situation. New subdirs created after the auto-deploy is > turned off are no longer being treated as separate apps and getRealPath is > returning the path as I expected. This looks very muc

Tomcat 5.5 service won't start

2009-01-30 Thread arricherekk
I installed Tomcat 5.5 yesterday, with limited success. It took me until a few hours ago to manage to get all of the ports and such things set correctly, so that everything would run properly. I then tried to install a servlet that I created, and then restart Tomcat. It won't start. The progre

Re: Performance of APR

2009-01-30 Thread Filip Hanik - Dev Lists
Caldarale, Charles R wrote: From: Gregor Schneider [mailto:rc4...@googlemail.com] Subject: Re: Performance of APR However, I haven't seen any benchmarks comparing NIO with APR, especially when it comes to SSL SSL handling is the same for the NIO and the traditional Java connector, so APR

RE: application.getRealPath() in JSP from a subdirectory

2009-01-30 Thread Caldarale, Charles R
> From: Qiao Jin [mailto:bra...@gmail.com] > Subject: RE: application.getRealPath() in JSP from a subdirectory > > In my case, I need to list all the files under an image directory. Perhaps you could use the customized directory listing capability of the DefaultServlet: http://tomcat.apache.org/t

RE: application.getRealPath() in JSP from a subdirectory

2009-01-30 Thread Martin Gainty
Qiao- "file:///foo/bar" is a URI http://java.sun.com/javase/6/docs/api/java/net/URI.html Martin __ Disclaimer and confidentiality note Everything in this e-mail and any attachments relates to the official business of Sender. This transmission is of

RE: application.getRealPath() in JSP from a subdirectory

2009-01-30 Thread Qiao Jin
Chuck, thanks for your response. It turns out that the auto-deploy switch does affect the situation. New subdirs created after the auto-deploy is turned off are no longer being treated as separate apps and getRealPath is returning the path as I expected. ServletContext.getResourceAsStream() is fi

Re: Slightly OT: ApacheCon Europe 2009

2009-01-30 Thread Filip Hanik - Dev Lists
Gregor Schneider wrote: Hi Mark, knowing those conferences, I know how hard it is to get "hands on" the speaker ;) I've registered for the 3 conference days only plus tuesday hackaton. I've got actually no idea how the hackaton works, but I'm curious to meet some of you guys. So if you have a

Re: Tomcat Clustering trouble when starting up under high load

2009-01-30 Thread Filip Hanik - Dev Lists
state transfer timeout -1 is not a good setting. one should prefer to timeout rather than getting stuck, even if the timeout means we didn't get everything you may also try the backup manager, which does the state transfer in a bit smarter manner. when your system is stuck, then thread dumps

Re: Transfer all HttpSessions from one cluster node to another

2009-01-30 Thread Filip Hanik - Dev Lists
Ok, the backup manager which does two things 1. [every request] it selects a backup node and each time the session changes it publishes the delta to the back up node 2. [one time] upon session creation it also notifies the other nodes with the location of the backup node for session X should

Re: Slightly OT: ApacheCon Europe 2009

2009-01-30 Thread André Warnier
Mark Thomas wrote: Hope to see you there for a *yuck* Heinecken... I'm sure we can find something better than that :) Since we're already OT here, let's do something for the sake of general cultural enlightenment outside of Tomcat and Java. As any real amateur knows, the only really good

Re: Excel file in Tomcat Virtual Dir has junk data in it.

2009-01-30 Thread André Warnier
Gregor Schneider wrote: Server version: Apache Tomcat/6.0.18 Server built: Jul 22 2008 02:00:36 Server number: 6.0.18.0 xls application/vnd.ms-excel Which by the way, dear OP, is exactly the same as the one I posted for you yesterday, along with the reason why. Th

Re: Performance of APR

2009-01-30 Thread Jess Holle
David Boreham wrote: Jess Holle wrote: You can make your own LB using Tomcat. Yes, I /could/, but Apache already does it. I don't want to invest enough of my own time in such a thing to put it on an equal footing with mod_jk and mod_proxy_ajp. Until someone does, though, Apache is a really

RE: javax.naming.NameNotFoundException: Name jdbc is not bound in this Context

2009-01-30 Thread Hamacher, Eric
DataSource pds = null; pds = (DataSource)context.lookup(name); "name" had to be "java:/comp/jdbc/GFDataSource" and then I moved on to my next problem. -Original Message- From: Pid [mailto:p...@pidster.com] Sent: Thursday, January 29, 2009 2:43 PM To: Tomcat Users

RE: application.getRealPath() in JSP from a subdirectory

2009-01-30 Thread Caldarale, Charles R
> From: Qiao Jin [mailto:bra...@gmail.com] > Subject: application.getRealPath() in JSP from a subdirectory > > I am using Tomcat 6.0.18, JDK 1.5 on CentOS 5. From within a JSP page, > applicaton.getRealPath() is returning results that I wasn't expecting. Using getRealPath() inside an app server of

Re: commons-logging problem

2009-01-30 Thread Gregor Schneider
On Fri, Jan 30, 2009 at 8:33 PM, Rusty Wright wrote: > Does that work reliably now? I was under the impression that it caused > problems, but that may have been with a previous version of tomcat. That's > why I asked my "where else" question; I was wondering if that's what he was > thinking of.

Re: commons-logging problem

2009-01-30 Thread Rusty Wright
Does that work reliably now? I was under the impression that it caused problems, but that may have been with a previous version of tomcat. That's why I asked my "where else" question; I was wondering if that's what he was thinking of. Gregor Schneider wrote: On Fri, Jan 30, 2009 at 7:45 PM,

Re: Slightly OT: ApacheCon Europe 2009

2009-01-30 Thread Mark Thomas
Gregor Schneider wrote: > Hi Mark, > > knowing those conferences, I know how hard it is to get "hands on" the > speaker ;) > > I've registered for the 3 conference days only plus tuesday hackaton. > > I've got actually no idea how the hackaton works, but I'm curious to > meet some of you guys. >

Re: commons-logging problem

2009-01-30 Thread Gregor Schneider
On Fri, Jan 30, 2009 at 7:45 PM, Rusty Wright wrote: > John Holman wrote: >> >> Also is it a supported configuration to use commons-logging and log4j in >> WEB-INF/lib? > > Where else would you put them? > i.e. ${CATALINA_HOME}/common/lib Saves the hazzle to put them into each webapp. Rgds Gre

Re: Slightly OT: ApacheCon Europe 2009

2009-01-30 Thread Gregor Schneider
Hi Mark, knowing those conferences, I know how hard it is to get "hands on" the speaker ;) I've registered for the 3 conference days only plus tuesday hackaton. I've got actually no idea how the hackaton works, but I'm curious to meet some of you guys. So if you have any information on what's a

application.getRealPath() in JSP from a subdirectory

2009-01-30 Thread Qiao Jin
I am using Tomcat 6.0.18, JDK 1.5 on CentOS 5. From within a JSP page, applicaton.getRealPath() is returning results that I wasn't expecting. Say, my application root directory in CentOS is "app-root". From within app-root/dir-a/test.jsp, I am using application.getRealPath(). Here are the resul

Re: Slightly OT: ApacheCon Europe 2009

2009-01-30 Thread Mark Thomas
André Warnier wrote: > Gregor Schneider wrote: >> Hi guys, >> >> I'm just wondering if anyone of this list will be joining the >> ApacheCon in Amsterdam this year? >> >> If so, maybe we could set up kid of a userlist-meeting and see the >> faces behind those posts? +1 > I'm planning to go. Most

Re: commons-logging problem

2009-01-30 Thread Rusty Wright
John Holman wrote: Also is it a supported configuration to use commons-logging and log4j in WEB-INF/lib? Where else would you put them? - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-m

Re: Performance of APR

2009-01-30 Thread David Boreham
Jess Holle wrote: You can make your own LB using Tomcat. Yes, I /could/, but Apache already does it. I don't want to invest enough of my own time in such a thing to put it on an equal footing with mod_jk and mod_proxy_ajp. Until someone does, though, Apache is a really necessary piece in a

Re: Servlet 2.5 and RequestDispatcher.include + Response.setHeader, invalid?

2009-01-30 Thread Ken Johanson
Caldarale, Charles R wrote: From: Ken Johanson [mailto:tomcat-u...@kensystem.com] Subject: Re: Servlet 2.5 and RequestDispatcher.include + Response.setHeader, invalid? Do you know if that rule applies only to the Request object passed by the RequestDispatcher, or should the container also preven

Re: Excel file in Tomcat Virtual Dir has junk data in it.

2009-01-30 Thread Gregor Schneider
Server version: Apache Tomcat/6.0.18 Server built: Jul 22 2008 02:00:36 Server number: 6.0.18.0 xls application/vnd.ms-excel hth Gregor -- just because your paranoid, doesn't mean they're not after you... gpgp-fp: 79A84FA526807026795E4209D3B3FE028B3170B2 gpgp-key av

RE: Excel file in Tomcat Virtual Dir has junk data in it.

2009-01-30 Thread Caldarale, Charles R
> From: uddav [mailto:adi.upr...@gmail.com] > Subject: Re: Excel file in Tomcat Virtual Dir has junk data in it. > > It is Version 5.0.27. Which is no longer supported. I do seem to recall that the settings for .xls were incorrect in that version. If you can't upgrade to a supported Tomcat, a

Re: Excel file in Tomcat Virtual Dir has junk data in it.

2009-01-30 Thread uddav
It is Version 5.0.27. uddav wrote: > > Hello Everyone, > > I have set up a Virtual Directory (Directory Listing) in Tomcat. We use > this to distribute documents and reports. The way we do is put the > documents to be distributed in this directory on the server and all our > user go to this v

RE: Servlet 2.5 and RequestDispatcher.include + Response.setHeader, invalid?

2009-01-30 Thread Caldarale, Charles R
> From: Ken Johanson [mailto:tomcat-u...@kensystem.com] > Subject: Re: Servlet 2.5 and RequestDispatcher.include + > Response.setHeader, invalid? > > Do you know if that rule applies only to the Request > object passed by the RequestDispatcher, or should the > container also prevent this if the ori

AW: AW: NoClassDefFoundError: HttpServlet

2009-01-30 Thread Ladislav Gaspar
Maybe you miss spoke (typed?), but the servlet-api.jar should only be in $CATALINA_HOME/lib and absolutely not on any classpath environment variable. Tomcat's classloader hierarchy will make sure it's loaded as needed. --David Ladislav Gaspar wrote: > As I wrote in the original post > >> (I'v

Re: Graceful Stop

2009-01-30 Thread Mohit Anchlia
Red hat linux: Here is the script: #!/bin/sh # Licensed to the Apache Software Foundation (ASF) under one or more # contributor license agreements. See the NOTICE file distributed with # this work for additional information regarding copyright ownership. # The ASF licenses this file to You unde

Re: Servlet 2.5 and RequestDispatcher.include + Response.setHeader, invalid?

2009-01-30 Thread Ken Johanson
Caldarale, Charles R wrote: It's my understanding that servlet 2.5 loosened the requirement that a included/callee Servlet (and JSP?) cannot set the resp headers/status, and should now be able to set them if not already committed. Here's the exact text from SRV.8.3 of the servlet spec version

Re: NoClassDefFoundError: HttpServlet

2009-01-30 Thread Konstantin Kolinko
2009/1/30 Ladislav Gaspar : > > > As I wrote in the original post >>(I've cleaned up the classpath, there are no duplicate servlet-api.jar files >>around) > > The servlet-api.jar is there and it's also in the classpath. (in > $catalina_home/lib) > I do not understand. "is there and it's also"

Re: Slightly OT: ApacheCon Europe 2009

2009-01-30 Thread André Warnier
Gregor Schneider wrote: Hi guys, I'm just wondering if anyone of this list will be joining the ApacheCon in Amsterdam this year? If so, maybe we could set up kid of a userlist-meeting and see the faces behind those posts? I'm planning to go. Most of the things are usually far above my head at

Re: Apache httpd 1.3 and connection pooling

2009-01-30 Thread André Warnier
Arne Riecken wrote: If I understood right, Apache httpd 1.3 is not multi threaded but can consist of multiple processes. And one Apache process has a connection pool size of 1 that should not be changed. So is there a kind of pool of 1-connection-pools ? That I don't really know, but it sounds

RE: Performance of APR

2009-01-30 Thread Caldarale, Charles R
> From: Gregor Schneider [mailto:rc4...@googlemail.com] > Subject: Re: Performance of APR > > However, I haven't seen any benchmarks comparing NIO with APR, > especially when it comes to SSL SSL handling is the same for the NIO and the traditional Java connector, so APR wins there. Filip has rep

Re: Performance of APR

2009-01-30 Thread Jess Holle
Gregor Schneider wrote: Well, if you don't want to deal with the APR (which I don't think is all that complicated), maybe new NIO-connector is worth a try: http://tomcat.apache.org/tomcat-6.0-doc/config/http.html However, I haven't seen any benchmarks comparing NIO with APR, especially when it

Slightly OT: ApacheCon Europe 2009

2009-01-30 Thread Gregor Schneider
Hi guys, I'm just wondering if anyone of this list will be joining the ApacheCon in Amsterdam this year? If so, maybe we could set up kid of a userlist-meeting and see the faces behind those posts? Cheers Gregor -- just because your paranoid, doesn't mean they're not after you... gpgp-fp: 79A8

Re: Performance of APR

2009-01-30 Thread Gregor Schneider
Well, if you don't want to deal with the APR (which I don't think is all that complicated), maybe new NIO-connector is worth a try: http://tomcat.apache.org/tomcat-6.0-doc/config/http.html However, I haven't seen any benchmarks comparing NIO with APR, especially when it comes to SSL Btw., a hard

RE: Indicator APR is loaded - TC 5.5

2009-01-30 Thread Caldarale, Charles R
> From: Gregor Schneider [mailto:rc4...@googlemail.com] > Subject: Re: Indicator APR is loaded - TC 5.5 > > Do I understand your statement correctly in that sense, > that *if* an APRLifeCycleListener has been configured > within TC 5.5, but no APR is found due to mis-configuration, > a message then

Re: AW: NoClassDefFoundError: HttpServlet

2009-01-30 Thread David Smith
Maybe you miss spoke (typed?), but the servlet-api.jar should only be in $CATALINA_HOME/lib and absolutely not on any classpath environment variable. Tomcat's classloader hierarchy will make sure it's loaded as needed. --David Ladislav Gaspar wrote: > As I wrote in the original post > >> (I'v

Apache httpd 1.3 and connection pooling

2009-01-30 Thread Arne Riecken
If I understood right, Apache httpd 1.3 is not multi threaded but can consist of multiple processes. And one Apache process has a connection pool size of 1 that should not be changed. So is there a kind of pool of 1-connection-pools ? Is it right that it does not make sense then for mod_jk to have

Re: Performance of APR

2009-01-30 Thread Jess Holle
Mladen Turk wrote: When it comes to the large file serving then the OS sendfile support in Tomcat Native outperforms the standard Java IO by an order of magnitude (In some of my tests up to 4 times), and with constant memory usage regardless of file size. There is also some other advanced featur

Re: Performance of APR

2009-01-30 Thread Jess Holle
David Boreham wrote: Jess Holle wrote: David Boreham wrote: I think you also need to factor in the labor cost to manage two different servers. I know that in our production deployments we could buy many many machines for the cost of the time we've spent trying to make AJP work. Tomcat could b

RE: Performance of APR

2009-01-30 Thread Peter Crowther
> From: Leon Rosenberg [mailto:rosenberg.l...@googlemail.com] > Well, actually when it comes to IO performance Java outperforms C, so > I wouldn't place my money on old bets like C is faster because its C. > It isn't. Specifics! Which platform(s), which compiler(s), which runtime(s), which algor

Re: Indicator APR is loaded - TC 5.5

2009-01-30 Thread Gregor Schneider
Charles, thanks a bunch, that's explaining my observations. Do I understand your statement correctly in that sense, that *if* an APRLifeCycleListener has been configured within TC 5.5, but no APR is found due to mis-configuration, a message then will show up in the logs? Cheers Gregor -- just

AW: NoClassDefFoundError: HttpServlet

2009-01-30 Thread Ladislav Gaspar
As I wrote in the original post >(I've cleaned up the classpath, there are no duplicate servlet-api.jar files >around) The servlet-api.jar is there and it's also in the classpath. (in $catalina_home/lib) -Ursprüngliche Nachricht- Von: André Warnier [mailto:a...@ice-sa.com] Gesendet

Re: NoClassDefFoundError: HttpServlet

2009-01-30 Thread André Warnier
Ladislav Gaspar wrote: [...] What strikes me as very strange is that in the error message: java.lang.NoClassDefFoundError: HttpServlet there is no package name in HttpServlet (that's why the ClassLoader can't find the Class, I suppose). Has anyone got an idea what could be wrong? No, but

NoClassDefFoundError: HttpServlet

2009-01-30 Thread Ladislav Gaspar
I've been trying to get my App working for the last two days but I'm stuck. I'm running tomcat 6.0.14 on XP. When tomcat starts up it tries to load the first servlet and I get the following error: SCHWERWIEGEND: Error deploying configuration descriptor ITVHealthGate.xml java.lang.NoClassDefFo