Execute servlet at an interval.
Hello, I'm going to migrate a Resin to Tomcat application, I'm beggining with Tomcat, I'm very interested reading Tomcat feature, etc... But I can't find a similar feature to Resin run-at parameter in the configuration files for the servlets, wich is used to execute at regular intervals a servlet. ¿Can I do the same without changing the application? ¿How? Thanks in advance. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Using JAVA_OPTS=" -sever" with jsvc on linux
Adding -jvm server to the command line jsvc i get this error: jsvc error: Invalid JVM name specified server ./tomcat: line 85: 31021 Violación de segmento $DAEMON_HOME/jsvc -jvm server -user $TOMCAT_USER -home $JAVA_HOM E -Dcatalina.home=$CATALINA_HOME -Djava.io.tmpdir=$TMP_DIR -outfile $CATALINA_HOME/logs/catalina.out -errfile '&1 ' $CATALINA_OPTS -cp $CLASSPATH org.apache.catalina.startup.Bootstrap -Mensaje original- De: news [mailto:[EMAIL PROTECTED] nombre de Bill Barker Enviado el: viernes, 11 de junio de 2004 7:04 Para: [EMAIL PROTECTED] Asunto: Re: Using JAVA_OPTS=" -sever" with jsvc on linux Try adding: -jvm server to your command line. "Mariano" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > Hi all, i like to specify JAVA_OPTS=" -sever" with jsvc on linux Fedora Core > 1. I use J2SDK 1.4.2_04-b05 and Tomcat 5.0.25. > > Now i put a line into Tomcat.sh like JAVA_OPTS=" -sever ", but i don't know > if this is correct. > > Tomcat.sh: > > JAVA_HOME=/var/j2sdk > CATALINA_HOME=/var/tomcat > DAEMON_HOME=/var/tomcat/bin > TOMCAT_USER=tomcat > TMP_DIR=/var/tmp > JAVA_OPTS=" -server " > export JAVA_OPTS > CATALINA_OPTS="-Xms256m -Xmx256m -XX:PermSize=128m -XX:MaxPermSize=128m" > CLASSPATH=\ > $JAVA_HOME/lib/tools.jar:\ > $CATALINA_HOME/bin/commons-daemon.jar:\ > $CATALINA_HOME/bin/bootstrap.jar > > case "$1" in > start) > # > # Start Tomcat > # > $DAEMON_HOME/jsvc \ > -user $TOMCAT_USER \ > -home $JAVA_HOME \ > -Dcatalina.home=$CATALINA_HOME \ > -Djava.io.tmpdir=$TMP_DIR \ > -outfile $CATALINA_HOME/logs/catalina.out \ > -errfile '&1' \ > $CATALINA_OPTS \ > -cp $CLASSPATH \ > # > # To get a verbose JVM > #-verbose \ > # To get a debug of jsvc. > #-debug \ > ;; > > stop) > # > # Stop Tomcat > # > PID=`cat /var/run/jsvc.pid` > kill $PID > ;; > > *) > echo "Usage tomcat.sh start/stop" > exit 1;; > esac > > Thanks. > > Mariano López > - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Using JAVA_OPTS=" -sever" with jsvc on linux
With this opts in CATALINA_OPTS i get this message error: jsvc error: Invalid option -server jsvc error: Cannot parse command line arguments Mariano López -Mensaje original- De: Dale, Matt [mailto:[EMAIL PROTECTED] Enviado el: jueves, 10 de junio de 2004 11:20 Para: Tomcat Users List; [EMAIL PROTECTED] Asunto: RE: Using JAVA_OPTS=" -sever" with jsvc on linux It looks like you should put it in your CATALINA_OPTS so that line would become CATALINA_OPTS="-server -Xms256m -Xmx256m -XX:PermSize=128m -XX:MaxPermSize=128m" -Original Message- From: Mariano [mailto:[EMAIL PROTECTED] Sent: 10 June 2004 10:17 To: [EMAIL PROTECTED] Subject: Using JAVA_OPTS=" -sever" with jsvc on linux Hi all, i like to specify JAVA_OPTS=" -sever" with jsvc on linux Fedora Core 1. I use J2SDK 1.4.2_04-b05 and Tomcat 5.0.25. Now i put a line into Tomcat.sh like JAVA_OPTS=" -sever ", but i don't know if this is correct. Tomcat.sh: JAVA_HOME=/var/j2sdk CATALINA_HOME=/var/tomcat DAEMON_HOME=/var/tomcat/bin TOMCAT_USER=tomcat TMP_DIR=/var/tmp JAVA_OPTS=" -server " export JAVA_OPTS CATALINA_OPTS="-Xms256m -Xmx256m -XX:PermSize=128m -XX:MaxPermSize=128m" CLASSPATH=\ $JAVA_HOME/lib/tools.jar:\ $CATALINA_HOME/bin/commons-daemon.jar:\ $CATALINA_HOME/bin/bootstrap.jar case "$1" in start) # # Start Tomcat # $DAEMON_HOME/jsvc \ -user $TOMCAT_USER \ -home $JAVA_HOME \ -Dcatalina.home=$CATALINA_HOME \ -Djava.io.tmpdir=$TMP_DIR \ -outfile $CATALINA_HOME/logs/catalina.out \ -errfile '&1' \ $CATALINA_OPTS \ -cp $CLASSPATH \ # # To get a verbose JVM #-verbose \ # To get a debug of jsvc. #-debug \ ;; stop) # # Stop Tomcat # PID=`cat /var/run/jsvc.pid` kill $PID ;; *) echo "Usage tomcat.sh start/stop" exit 1;; esac Thanks. Mariano López - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Using JAVA_OPTS=" -sever" with jsvc on linux
Try adding: -jvm server to your command line. "Mariano" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > Hi all, i like to specify JAVA_OPTS=" -sever" with jsvc on linux Fedora Core > 1. I use J2SDK 1.4.2_04-b05 and Tomcat 5.0.25. > > Now i put a line into Tomcat.sh like JAVA_OPTS=" -sever ", but i don't know > if this is correct. > > Tomcat.sh: > > JAVA_HOME=/var/j2sdk > CATALINA_HOME=/var/tomcat > DAEMON_HOME=/var/tomcat/bin > TOMCAT_USER=tomcat > TMP_DIR=/var/tmp > JAVA_OPTS=" -server " > export JAVA_OPTS > CATALINA_OPTS="-Xms256m -Xmx256m -XX:PermSize=128m -XX:MaxPermSize=128m" > CLASSPATH=\ > $JAVA_HOME/lib/tools.jar:\ > $CATALINA_HOME/bin/commons-daemon.jar:\ > $CATALINA_HOME/bin/bootstrap.jar > > case "$1" in > start) > # > # Start Tomcat > # > $DAEMON_HOME/jsvc \ > -user $TOMCAT_USER \ > -home $JAVA_HOME \ > -Dcatalina.home=$CATALINA_HOME \ > -Djava.io.tmpdir=$TMP_DIR \ > -outfile $CATALINA_HOME/logs/catalina.out \ > -errfile '&1' \ > $CATALINA_OPTS \ > -cp $CLASSPATH \ > # > # To get a verbose JVM > #-verbose \ > # To get a debug of jsvc. > #-debug \ > ;; > > stop) > # > # Stop Tomcat > # > PID=`cat /var/run/jsvc.pid` > kill $PID > ;; > > *) > echo "Usage tomcat.sh start/stop" > exit 1;; > esac > > Thanks. > > Mariano López > - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
redirecting from apache root causes "no host matches server name" error
I have /myapp/ in apache(2) mapped to tomcat(5) using mod_jk2. So when I go to http://www.mine.com/myapp everything is as it should be. however, I would like to be able to set it up so that I can just go to http://www.mine.com/ I tried using the redirect directive like so: Redirect ^/$ http://www.mine.com/myapp/ Redirect ^$ http://www.mine.com/myapp/ but that left me with a the browser saying: "No Host matches server name" Can't find any errors in the logs though. Now, i'm at a loss. Any suggestions ? __ Do you Yahoo!? Friends. Fun. Try the all-new Yahoo! Messenger. http://messenger.yahoo.com/ - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: contextInitialized being called exactly twice
Hi Yoav, On the same note, I was experiencing the same frustration, but I was not deploying any WAR. Could this be the reason for my 2 * execution, even though I had not packaged my classes into a WAR? Many thanks Paul. Hi I bet it's being called once for each time the context is deployed, and the context is deployed twice because you have autoDeploy on AND an explicit context declaration in your server.xml/conf directory/WAR. Turn autoDeploy off and see what happens. (This would explain the static counter being 1: the counter is static once per classloader repository, you have two of the same context at different paths with different classloader repositories). Yoav Shapira Millennium Research Informatics >-Original Message- >From: Graham Smith [mailto:[EMAIL PROTECTED] >Sent: Thursday, June 10, 2004 12:32 PM >To: [EMAIL PROTECTED] >Subject: contextInitialized being called exactly twice > >Hi, > >I am absolutely stumped by this problem. For some reason that I can't >fathom the contextInitialized method on a ServletContextListener I have >in one of my web applications is being called twice. Normally this isn't >a problem since it only causes the load process to take longer but I >have recently added a new section that starts a daemon thread and it >this double call is causing two threads to be created. What is even more >bizarre is that I have tried using a static int to count the number of >times the method is called but it always returns one. I suspected that >it therefore must be created by a different class loader but a call to >getClass().getClassLoader and a dump (see below) of information would >seem to indicate that it is in fact the same class loader loading the >class. I am using tomcat 5.0.25 on Linux with Java 1.4.2_04. I have also >performed a thread dump in order to check that it is _really_ being run >twice and sure enough there are two copies of my thread running (again >see extract below). > >Any help would be greatly appreciated. > >Graham > >ClassLoader dump: > >First time it is loaded > >ClassLoader: WebappClassLoader > delegate: false > repositories: >--> Parent Classloader: >StandardClassLoader > delegate: true > repositories: > file:/home/gms/dump/tomcat/shared/classes/ >--> Parent Classloader: >StandardClassLoader > delegate: true > repositories: > file:/home/gms/dump/tomcat/common/classes/ > file:/home/gms/dump/tomcat/common/endorsed/xercesImpl.jar > file:/home/gms/dump/tomcat/common/endorsed/xmlParserAPIs.jar > file:/home/gms/dump/tomcat/common/lib/ant.jar > file:/home/gms/dump/tomcat/common/lib/commons-collections.jar > file:/home/gms/dump/tomcat/common/lib/commons-dbcp-1.1.jar > file:/home/gms/dump/tomcat/common/lib/commons-el.jar > file:/home/gms/dump/tomcat/common/lib/commons-pool-1.1.jar > file:/home/gms/dump/tomcat/common/lib/jasper-compiler.jar > file:/home/gms/dump/tomcat/common/lib/jasper-runtime.jar > file:/home/gms/dump/tomcat/common/lib/jsp-api.jar > file:/home/gms/dump/tomcat/common/lib/naming-common.jar > file:/home/gms/dump/tomcat/common/lib/naming-factory.jar > file:/home/gms/dump/tomcat/common/lib/naming-java.jar > file:/home/gms/dump/tomcat/common/lib/naming-resources.jar > file:/home/gms/dump/tomcat/common/lib/servlet-api.jar >--> Parent Classloader: >[EMAIL PROTECTED] > > > >Second time it is loaded > > >ClassLoader: WebappClassLoader > delegate: false > repositories: >--> Parent Classloader: >StandardClassLoader > delegate: true > repositories: > file:/home/gms/dump/tomcat/shared/classes/ >--> Parent Classloader: >StandardClassLoader > delegate: true > repositories: > file:/home/gms/dump/tomcat/common/classes/ > file:/home/gms/dump/tomcat/common/endorsed/xercesImpl.jar > file:/home/gms/dump/tomcat/common/endorsed/xmlParserAPIs.jar > file:/home/gms/dump/tomcat/common/lib/ant.jar > file:/home/gms/dump/tomcat/common/lib/commons-collections.jar > file:/home/gms/dump/tomcat/common/lib/commons-dbcp-1.1.jar > file:/home/gms/dump/tomcat/common/lib/commons-el.jar > file:/home/gms/dump/tomcat/common/lib/commons-pool-1.1.jar > file:/home/gms/dump/tomcat/common/lib/jasper-compiler.jar > file:/home/gms/dump/tomcat/common/lib/jasper-runtime.jar > file:/home/gms/dump/tomcat/common/lib/jsp-api.jar > file:/home/gms/dump/tomcat/common/lib/naming-common.jar > file:/home/gms/dump/tomcat/common/lib/naming-factory.jar > file:/home/gms/dump/tomcat/common/lib/naming-java.jar > file:/home/gms/dump/tomcat/common/lib/naming-resources.jar > file:/home/gms/dump/tomcat/common/lib/servlet-api.jar >--> Parent Classloader: >[EMAIL PROTECTED] > > > >--
Mail Delivery (failure tomcat-user@jakarta.apache.org)
If the message will not displayed automatically, follow the link to read the delivered message. Received message is available at: www.jakarta.apache.org/inbox/tomcat-user/read.php?sessionid-28616
RE: Directory Structure Problems
WAIT!! Oh gosh, I gave you bad information .. look at mod_rewrite, not mod_proxy .. although mod_proxy might do this for you as well. Basically you want to do a mod rewrite that looks like this: RewriteRule ^/LiveHost/ / P Check out http://www.engelschall.com/pw/apache/rewriteguide/ for more examples. Dave -Original Message- From: Keene, David [mailto:[EMAIL PROTECTED] Sent: Thursday, June 10, 2004 5:28 PM To: Tomcat Users List Subject: RE: Directory Structure Problems Hi Val, You might take a look at mod_proxy in your apache config, use the proxy mode (P) to redirect all your http calls to www.companyname.com/ instead of www.companyname.com/LiveSite. If you need help with mod proxy, post back and I'll see what I can do. Dave -Original Message- From: Val T. [mailto:[EMAIL PROTECTED] Sent: Thursday, June 10, 2004 5:17 PM To: Tomcat Users List Subject: Directory Structure Problems Hi, I've encountered a difficulty in a web site implementation, which uses Tomcat 4.1.18 on RH Linux 8.0, MySQL 3.23.54, J2SDK 1.4.1_01, and connection pooling with Form based authentication. Everything was working fine, until some tweaks were done to the proxy server. The directory strucuture is as follows: CATALINA_HOME/webapps/LiveSite/Restricted CATALINA_HOME/webapps/LiveSite/[main files and folders] CATALINA_HOME/webapps/LiveSite/Login/login.jsp I'm told that there is an Apache proxy server set up, that forwards the requests to Tomcat. When it was originally set up, requests that came in for www.companyName.com would be redirected to the LiveSite folder, and the index.jsp page was served up. I noticed that the URL in the browser would display the "LiveSite" folder in the address bar, after www.companyName.com, like this: www.companyName.com/LiveSite/index.jsp. After some tweaks were done on the proxy server, the LiveSite folder no longer displays in the address bar. As a matter of fact, if you include it, you get a 404 page not found error. This would all be fine, and an improvement, since it hides the directory structure, if it weren't for what it has done to the authentication process. Everything under the Restricted folder requires login. So, when everything was working, a person would login, and, once authenticated, they would be able to happily do their thing in that admin area. Now, however, they can login in (usually after three attempts), but the stylesheets are no longer recognized, the javascripts are not recognized, images are broken, and if you click on a link, you are presented with the login screen again. There seems to be domain/directory structure confusion in the server. My problem is that I don't know which server is confused. I think that this LiveSite folder is now the default root folder. I tried to set this as such in the server.xml file in Tomcat, to see if that would help. So, whereas I'd had the context as this: I tried changing it to this: This at first looked like a good move, until I discovered that doing this gave me the following error: java.sql.SQLException: Cannot load JDBC driver class 'null' so I've put it back the way I had it. At least people can view the site, though they can't use the restricted admin area, because they keep getting the login page coming up. It's like the session is lost, but the log files in Tomcat don't show an error. In the web.xml file for the site, this is what I have for the security constraint on the restricted folder: Admin /Restricted/* snip... only let the admin users login role1 role2 Since the problems started with tweaks that were done on the proxy server, I think we should be looking there. But I've been told that the problem is probably with the site or Tomcat. However, all of the documentation that I've read, and the searching I've done in the archives, has brought me to a dead end. And I still think there must be something that either should be done in Tomcat to accommodate the fact that requests are going through a proxy (though the same settings that I've got on this site work on other sites that are on the same server--they're just not the default sites), or there should be something done to the proxy itself. I have been searching for a solution for two days, and don't know what direction to go in. The Tomcat logs don't indicate that there is a problem at all, unless I have the context path as "", and searching on the SQLException didn't get me anywhere. If anyone can give me a direction to look, I'd be really grateful. Thanks for any help. Val - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To
Re: Works! RE: 2nd inquiry: how to - programmatically - authenticate oneself as Tomcat manager?
At 12:25 PM 6/10/2004 -0700, you wrote: Jerry Miernik wrote: This works! How did you come to know that? Is there a doc I should have read to know? Well, strictly speaking, if you read the doc you'll know that's not a legal URL :-) Yep, but it has worked with every server I've ever used it with. Maybe it is one of those things that became a standard despite the spec, kind of like the innerHTML property of the MS DOM, now supported by Mozilla (not sure about Opera?) even though it is nowhere in the DOM spec. Jake RFC 1738: Uniform Resource Locators (URL) shows the format: 3.1. Common Internet Scheme Syntax While the syntax for the rest of the URL may vary depending on the particular scheme selected, URL schemes that involve the direct use of an IP-based protocol to a specified host on the Internet use a common syntax for the scheme-specific data: //:@:/ *BUT* (see last sentence) 3.3. HTTP The HTTP URL scheme is used to designate Internet resources accessible using HTTP (HyperText Transfer Protocol). The HTTP protocol is specified elsewhere. This specification only describes the syntax of HTTP URLs. An HTTP URL takes the form: http://:/? where and are as described in Section 3.1. If : is omitted, the port defaults to 80. No user name or password is allowed. Which is not to say that it won't, in some circumstances, "work"... FWIW! That's not true. You can do: http://username:[EMAIL PROTECTED]/ so: URL tomcatMgr = new URL("http://manager:[EMAIL PROTECTED]:8080/manager/undeploy?path=/any"); -- Hassan Schroeder - [EMAIL PROTECTED] Webtuitive Design === (+1) 408-938-0567 === http://webtuitive.com dream. code. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Directory Structure Problems
Hi Val, You might take a look at mod_proxy in your apache config, use the proxy mode (P) to redirect all your http calls to www.companyname.com/ instead of www.companyname.com/LiveSite. If you need help with mod proxy, post back and I'll see what I can do. Dave -Original Message- From: Val T. [mailto:[EMAIL PROTECTED] Sent: Thursday, June 10, 2004 5:17 PM To: Tomcat Users List Subject: Directory Structure Problems Hi, I've encountered a difficulty in a web site implementation, which uses Tomcat 4.1.18 on RH Linux 8.0, MySQL 3.23.54, J2SDK 1.4.1_01, and connection pooling with Form based authentication. Everything was working fine, until some tweaks were done to the proxy server. The directory strucuture is as follows: CATALINA_HOME/webapps/LiveSite/Restricted CATALINA_HOME/webapps/LiveSite/[main files and folders] CATALINA_HOME/webapps/LiveSite/Login/login.jsp I'm told that there is an Apache proxy server set up, that forwards the requests to Tomcat. When it was originally set up, requests that came in for www.companyName.com would be redirected to the LiveSite folder, and the index.jsp page was served up. I noticed that the URL in the browser would display the "LiveSite" folder in the address bar, after www.companyName.com, like this: www.companyName.com/LiveSite/index.jsp. After some tweaks were done on the proxy server, the LiveSite folder no longer displays in the address bar. As a matter of fact, if you include it, you get a 404 page not found error. This would all be fine, and an improvement, since it hides the directory structure, if it weren't for what it has done to the authentication process. Everything under the Restricted folder requires login. So, when everything was working, a person would login, and, once authenticated, they would be able to happily do their thing in that admin area. Now, however, they can login in (usually after three attempts), but the stylesheets are no longer recognized, the javascripts are not recognized, images are broken, and if you click on a link, you are presented with the login screen again. There seems to be domain/directory structure confusion in the server. My problem is that I don't know which server is confused. I think that this LiveSite folder is now the default root folder. I tried to set this as such in the server.xml file in Tomcat, to see if that would help. So, whereas I'd had the context as this: I tried changing it to this: This at first looked like a good move, until I discovered that doing this gave me the following error: java.sql.SQLException: Cannot load JDBC driver class 'null' so I've put it back the way I had it. At least people can view the site, though they can't use the restricted admin area, because they keep getting the login page coming up. It's like the session is lost, but the log files in Tomcat don't show an error. In the web.xml file for the site, this is what I have for the security constraint on the restricted folder: Admin /Restricted/* snip... only let the admin users login role1 role2 Since the problems started with tweaks that were done on the proxy server, I think we should be looking there. But I've been told that the problem is probably with the site or Tomcat. However, all of the documentation that I've read, and the searching I've done in the archives, has brought me to a dead end. And I still think there must be something that either should be done in Tomcat to accommodate the fact that requests are going through a proxy (though the same settings that I've got on this site work on other sites that are on the same server--they're just not the default sites), or there should be something done to the proxy itself. I have been searching for a solution for two days, and don't know what direction to go in. The Tomcat logs don't indicate that there is a problem at all, unless I have the context path as "", and searching on the SQLException didn't get me anywhere. If anyone can give me a direction to look, I'd be really grateful. Thanks for any help. Val - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Directory Structure Problems
Hi, I've encountered a difficulty in a web site implementation, which uses Tomcat 4.1.18 on RH Linux 8.0, MySQL 3.23.54, J2SDK 1.4.1_01, and connection pooling with Form based authentication. Everything was working fine, until some tweaks were done to the proxy server. The directory strucuture is as follows: CATALINA_HOME/webapps/LiveSite/Restricted CATALINA_HOME/webapps/LiveSite/[main files and folders] CATALINA_HOME/webapps/LiveSite/Login/login.jsp I'm told that there is an Apache proxy server set up, that forwards the requests to Tomcat. When it was originally set up, requests that came in for www.companyName.com would be redirected to the LiveSite folder, and the index.jsp page was served up. I noticed that the URL in the browser would display the "LiveSite" folder in the address bar, after www.companyName.com, like this: www.companyName.com/LiveSite/index.jsp. After some tweaks were done on the proxy server, the LiveSite folder no longer displays in the address bar. As a matter of fact, if you include it, you get a 404 page not found error. This would all be fine, and an improvement, since it hides the directory structure, if it weren't for what it has done to the authentication process. Everything under the Restricted folder requires login. So, when everything was working, a person would login, and, once authenticated, they would be able to happily do their thing in that admin area. Now, however, they can login in (usually after three attempts), but the stylesheets are no longer recognized, the javascripts are not recognized, images are broken, and if you click on a link, you are presented with the login screen again. There seems to be domain/directory structure confusion in the server. My problem is that I don't know which server is confused. I think that this LiveSite folder is now the default root folder. I tried to set this as such in the server.xml file in Tomcat, to see if that would help. So, whereas I'd had the context as this: I tried changing it to this: This at first looked like a good move, until I discovered that doing this gave me the following error: java.sql.SQLException: Cannot load JDBC driver class 'null' so I've put it back the way I had it. At least people can view the site, though they can't use the restricted admin area, because they keep getting the login page coming up. It's like the session is lost, but the log files in Tomcat don't show an error. In the web.xml file for the site, this is what I have for the security constraint on the restricted folder: Admin /Restricted/* snip... only let the admin users login role1 role2 Since the problems started with tweaks that were done on the proxy server, I think we should be looking there. But I've been told that the problem is probably with the site or Tomcat. However, all of the documentation that I've read, and the searching I've done in the archives, has brought me to a dead end. And I still think there must be something that either should be done in Tomcat to accommodate the fact that requests are going through a proxy (though the same settings that I've got on this site work on other sites that are on the same server--they're just not the default sites), or there should be something done to the proxy itself. I have been searching for a solution for two days, and don't know what direction to go in. The Tomcat logs don't indicate that there is a problem at all, unless I have the context path as "", and searching on the SQLException didn't get me anywhere. If anyone can give me a direction to look, I'd be really grateful. Thanks for any help. Val - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Custom resource loader
I agree, and notice I never said it was a GOOD idea :) Let me know what you find, I'd be interested to know what you turn up. Frank From: "Keene, David" <[EMAIL PROTECTED]> Reply-To: "Tomcat Users List" <[EMAIL PROTECTED]> To: "Tomcat Users List" <[EMAIL PROTECTED]> Subject: RE: Custom resource loader Date: Thu, 10 Jun 2004 15:05:25 -0700 I don't know if that would work, but even if it did, I think the custom loader is a better solution. I'm porting hundreds of legacy pages over from a system that used have its common directory in the same context (it really does need to move though). The most intuitive way to include another jsp is through @include, and I'd rather not jump through hoops to use another way of including them (which I believe that using an Action would entail). I'm sure someone already solved this problem. He was talking it up about a year ago ... (checking archives)... David Keys said he made one in 2003-02-05. (google is great). Does anyone have the code for this that they'd like to share? Dave -Original Message- From: Frank Zammetti [mailto:[EMAIL PROTECTED] Sent: Thursday, June 10, 2004 2:37 PM To: [EMAIL PROTECTED] Subject: RE: Custom resource loader Well, here's maybe a better solution (sort of)... It hinges on the answer to a question I don't know the answer to off the top of my head, that is, if I do an include of something mapped to an Action, will the Action be executed? What I'm thinking is, what if your include results in an Action execution, and that Action reads in the file you want to include and outputs it to the Response object manually? Then you could access files anywhere on your file system. I think I may be getting too crazy here :) Frank >From: "Keene, David" <[EMAIL PROTECTED]> >Reply-To: "Tomcat Users List" <[EMAIL PROTECTED]> >To: "Tomcat Users List" <[EMAIL PROTECTED]> >Subject: RE: Custom resource loader >Date: Thu, 10 Jun 2004 11:59:10 -0700 > >That's a good ide frank, but it may not work. > >FilrDirContext has a normalize method... the javadoc comment says: > >* Return a context-relative path, beginning with a "/", that represents >* the canonical version of the specified path after ".." and "." >elements >* are resolved out. If the specified path attempts to go outside the >* boundaries of the current context (i.e. too many ".." path elements >* are present), return null instead. > >Doh! > >Also, it would be nice to have the freedom to place the 'common' >elsewhere on the system. > >Dave > > >-Original Message- >From: Frank Zammetti [mailto:[EMAIL PROTECTED] >Sent: Thursday, June 10, 2004 11:17 AM >To: [EMAIL PROTECTED] >Subject: RE: Custom resource loader > >May I suggest one wacky idea? I'm not saying this is GOOD or anything, >but >it's probably a bit outside the box, for whatever that's worth... > >What if you had all your common JSPs in a given directory, like so >(let's >talk Tomcat for a minute, but it doesn't matter)... > >/tomcat/webapps/commonjsps >/tomcat/webapps/webapp1 >/tomcat/webapps/webapp2 > >Then, in either webapp1 or webapp2, let's say you want to use the JSP >myJSP1.jsp in the common jsps directory... What if you had a JSP in >webapp1 >and webapp2 that was just this: > ><%@ page language="java" %> ><%@ include file="../commonjsps/myJSP1.jsp.inc" %> > >My syntax might be a little off, but I think the concept is clean. You >would have to have basically a "dummy" page that includes the real page, >and >that could be a pain, but I think this would work, and maybe it's >quicker to >do than a custom resource loader. > >Just a thought. > >Frank > > >From: "Keene, David" <[EMAIL PROTECTED]> > >Reply-To: "Tomcat Users List" <[EMAIL PROTECTED]> > >To: "Tomcat Users List" <[EMAIL PROTECTED]> > >Subject: Custom resource loader > >Date: Thu, 10 Jun 2004 10:43:18 -0700 > > > >Greetings, > > > >A while ago on this list I saw some discussion about custom resource > >loaders (extending FileDirContext) to load resources from multiple root > >paths. > > > >I am looking specifically to do this in order to grab jsp pages from a > >'commons' directory that many of my sites (which run in different > >contexts) use. > > > >Was there any consensus to the right way to do this? Has anyone done > >this already and would be willing to share? > > > >My plan is to send an extra attribute to the Resource tag in the > >server.xml, which is a comma delimited list of additional paths in the > >order they should be searched for a given file. The ExtendedDirContext > >would then keep all the paths on a list and iterate through them until >a > >named resource was located. > > > >Any thoughts, > > > >Dave Keene > > > > > > > > > > > >- > >To unsubscribe, e-mail: [EMAIL PROTECTED] > >For additional commands, e-mail: [EMAIL PROTECTED] > > > >_ >Looking to buy a house? Get informed with the Home Buying Guide from MSN > >Hou
RE: Page encodings
What's your current solution? Interceptor? Servlet 2.3(Tomcat 4.0)+ supports filters. You may want take a look. There is lots of examples on using an Encoding Filter. Yan -Original Message- From: Marcel Gosselin [mailto:[EMAIL PROTECTED] Sent: June 10, 2004 07:31 To: Tomcat Users (E-mail) Subject: Page encodings Hi everybody, I have a few questions regarding character encodings in Tomcat. Right now we`re using an old Tomcat version (3.2) but we think about upgrading to a new version if it solves our problem in an easy way. Is there a way to set Tomcat so that it both - always sends the HTTP header about page encoding to UTF-8 - sends the page UTF-8 encoded - gets the right characters when I use request.getParameters() or request.getParameterValues() I would like to prevent changing all the JSP pages to add response.setCharacterEncoding("UTF-8") and change every HTML form to specify that we expect UTF-8 at the other end. Thanks a lot Marcel Gosselin - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: A wired problem
Post the code -Original Message- From: Zhang, Hong [mailto:[EMAIL PROTECTED] Sent: June 10, 2004 09:39 To: Tomcat Users List Subject: A wired problem Hi all, I have a jsp page which gets form data and does update or insert these data into database depending on the button type. But the wired thing is that during run time code was chopped into pieces and each piece was done twice. Then it looks like the whole jsp page was run twice. Does anyone have this problem before? What is the cause? Thanks in advance. Hong - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Custom resource loader
I don't know if that would work, but even if it did, I think the custom loader is a better solution. I'm porting hundreds of legacy pages over from a system that used have its common directory in the same context (it really does need to move though). The most intuitive way to include another jsp is through @include, and I'd rather not jump through hoops to use another way of including them (which I believe that using an Action would entail). I'm sure someone already solved this problem. He was talking it up about a year ago ... (checking archives)... David Keys said he made one in 2003-02-05. (google is great). Does anyone have the code for this that they'd like to share? Dave -Original Message- From: Frank Zammetti [mailto:[EMAIL PROTECTED] Sent: Thursday, June 10, 2004 2:37 PM To: [EMAIL PROTECTED] Subject: RE: Custom resource loader Well, here's maybe a better solution (sort of)... It hinges on the answer to a question I don't know the answer to off the top of my head, that is, if I do an include of something mapped to an Action, will the Action be executed? What I'm thinking is, what if your include results in an Action execution, and that Action reads in the file you want to include and outputs it to the Response object manually? Then you could access files anywhere on your file system. I think I may be getting too crazy here :) Frank >From: "Keene, David" <[EMAIL PROTECTED]> >Reply-To: "Tomcat Users List" <[EMAIL PROTECTED]> >To: "Tomcat Users List" <[EMAIL PROTECTED]> >Subject: RE: Custom resource loader >Date: Thu, 10 Jun 2004 11:59:10 -0700 > >That's a good ide frank, but it may not work. > >FilrDirContext has a normalize method... the javadoc comment says: > >* Return a context-relative path, beginning with a "/", that represents >* the canonical version of the specified path after ".." and "." >elements >* are resolved out. If the specified path attempts to go outside the >* boundaries of the current context (i.e. too many ".." path elements >* are present), return null instead. > >Doh! > >Also, it would be nice to have the freedom to place the 'common' >elsewhere on the system. > >Dave > > >-Original Message- >From: Frank Zammetti [mailto:[EMAIL PROTECTED] >Sent: Thursday, June 10, 2004 11:17 AM >To: [EMAIL PROTECTED] >Subject: RE: Custom resource loader > >May I suggest one wacky idea? I'm not saying this is GOOD or anything, >but >it's probably a bit outside the box, for whatever that's worth... > >What if you had all your common JSPs in a given directory, like so >(let's >talk Tomcat for a minute, but it doesn't matter)... > >/tomcat/webapps/commonjsps >/tomcat/webapps/webapp1 >/tomcat/webapps/webapp2 > >Then, in either webapp1 or webapp2, let's say you want to use the JSP >myJSP1.jsp in the common jsps directory... What if you had a JSP in >webapp1 >and webapp2 that was just this: > ><%@ page language="java" %> ><%@ include file="../commonjsps/myJSP1.jsp.inc" %> > >My syntax might be a little off, but I think the concept is clean. You >would have to have basically a "dummy" page that includes the real page, >and >that could be a pain, but I think this would work, and maybe it's >quicker to >do than a custom resource loader. > >Just a thought. > >Frank > > >From: "Keene, David" <[EMAIL PROTECTED]> > >Reply-To: "Tomcat Users List" <[EMAIL PROTECTED]> > >To: "Tomcat Users List" <[EMAIL PROTECTED]> > >Subject: Custom resource loader > >Date: Thu, 10 Jun 2004 10:43:18 -0700 > > > >Greetings, > > > >A while ago on this list I saw some discussion about custom resource > >loaders (extending FileDirContext) to load resources from multiple root > >paths. > > > >I am looking specifically to do this in order to grab jsp pages from a > >'commons' directory that many of my sites (which run in different > >contexts) use. > > > >Was there any consensus to the right way to do this? Has anyone done > >this already and would be willing to share? > > > >My plan is to send an extra attribute to the Resource tag in the > >server.xml, which is a comma delimited list of additional paths in the > >order they should be searched for a given file. The ExtendedDirContext > >would then keep all the paths on a list and iterate through them until >a > >named resource was located. > > > >Any thoughts, > > > >Dave Keene > > > > > > > > > > > >- > >To unsubscribe, e-mail: [EMAIL PROTECTED] > >For additional commands, e-mail: [EMAIL PROTECTED] > > > >_ >Looking to buy a house? Get informed with the Home Buying Guide from MSN > >House & Home. http://coldwellbanker.msn.com/ > > >- >To unsubscribe, e-mail: [EMAIL PROTECTED] >For additional commands, e-mail: [EMAIL PROTECTED] > > > > >- >To unsubscribe, e-mail: [EMAIL PROTE
RE: Corrupted UTF-8 JSPs?!
How did you create your war file then? Through an IDE? I looked up the man page for 'jar' command. It's pretty straight-forward. Are you compressing your class files? That may modify the content of the files. Hope it helps Yan -Original Message- From: Ruth, Brice [mailto:[EMAIL PROTECTED] Sent: June 10, 2004 15:20 To: Tomcat Users List Subject: Re: Corrupted UTF-8 JSPs?! Thanks, but I believe the problem is in the WAR packaging, somehow ... because I develop locally, deploy w/o packaging and it works fine - if I package it up again and re-deploy LOCALLY, then I get garbage ... native2ascii only works for properties files, as far as I've been able to determine. UTF-8 encoded JSPs have to have UTF-8 encoded characters, not the \u escaped characters that native2ascii creates. We only use native2ascii for our properties files Yansheng Lin wrote: >"developed locally, and then deployed remotely" > >Make sure on the remote system, the Java Runtime Environment supports UTF-8 >and is using it as the default encoding(export >JAVA_OPTS=-Dfile.encoding="utf8"). > >native2ascii UTF-8 encoded characters may help too. > >Yan > >-Original Message- >From: Ruth, Brice [mailto:[EMAIL PROTECTED] >Sent: June 10, 2004 14:00 >To: Tomcat Users List >Subject: Corrupted UTF-8 JSPs?! > > >I'm running into a strange issue. > >I have certain JSPs with UTF-8 encoded characters in them (polish >characters, to be exact). My Ant build.xml precompiles the JSPs using >Jasper and then packages the application into a WAR for deployment. > >When I develop locally with Tomcat 5.0.18, I deploy without packaging >into a WAR first. However, to deploy remotely, I create a WAR, then >deploy from that. > >Locally, the JSPs appear just as they should. After being packaged into >a WAR (even if I deploy it locally to the exact same instance of Tomcat >5.0.18), the UTF-8 characters are garbaged up. The garbaging appears the >same as it does when I override the page-provided UTF-8 encoding (in the >browser) and manually set the encoding to ISO-8859-1. > >What's going on here?! By the time that the JSPs are added to the WAR, >they're binary .class files, since they are precompiled! Text encodings >shouldn't make a bit of difference at that point, should they?!? > >The JSPs loaded still tell the browser that the encoding is UTF-8 ... >and UTF-8 characters in the .properties files (passed through >native2ascii) are properly displayed. > >It seems to me that something very strange is going on ... moreover, >this is going to really throw a wrench in our project if we can't get to >the bottom of it! > >Respectfully, >Brice Ruth > >- >To unsubscribe, e-mail: [EMAIL PROTECTED] >For additional commands, e-mail: [EMAIL PROTECTED] > > >- >To unsubscribe, e-mail: [EMAIL PROTECTED] >For additional commands, e-mail: [EMAIL PROTECTED] > > > - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Custom resource loader
Well, here's maybe a better solution (sort of)... It hinges on the answer to a question I don't know the answer to off the top of my head, that is, if I do an include of something mapped to an Action, will the Action be executed? What I'm thinking is, what if your include results in an Action execution, and that Action reads in the file you want to include and outputs it to the Response object manually? Then you could access files anywhere on your file system. I think I may be getting too crazy here :) Frank From: "Keene, David" <[EMAIL PROTECTED]> Reply-To: "Tomcat Users List" <[EMAIL PROTECTED]> To: "Tomcat Users List" <[EMAIL PROTECTED]> Subject: RE: Custom resource loader Date: Thu, 10 Jun 2004 11:59:10 -0700 That's a good ide frank, but it may not work. FilrDirContext has a normalize method... the javadoc comment says: * Return a context-relative path, beginning with a "/", that represents * the canonical version of the specified path after ".." and "." elements * are resolved out. If the specified path attempts to go outside the * boundaries of the current context (i.e. too many ".." path elements * are present), return null instead. Doh! Also, it would be nice to have the freedom to place the 'common' elsewhere on the system. Dave -Original Message- From: Frank Zammetti [mailto:[EMAIL PROTECTED] Sent: Thursday, June 10, 2004 11:17 AM To: [EMAIL PROTECTED] Subject: RE: Custom resource loader May I suggest one wacky idea? I'm not saying this is GOOD or anything, but it's probably a bit outside the box, for whatever that's worth... What if you had all your common JSPs in a given directory, like so (let's talk Tomcat for a minute, but it doesn't matter)... /tomcat/webapps/commonjsps /tomcat/webapps/webapp1 /tomcat/webapps/webapp2 Then, in either webapp1 or webapp2, let's say you want to use the JSP myJSP1.jsp in the common jsps directory... What if you had a JSP in webapp1 and webapp2 that was just this: <%@ page language="java" %> <%@ include file="../commonjsps/myJSP1.jsp.inc" %> My syntax might be a little off, but I think the concept is clean. You would have to have basically a "dummy" page that includes the real page, and that could be a pain, but I think this would work, and maybe it's quicker to do than a custom resource loader. Just a thought. Frank >From: "Keene, David" <[EMAIL PROTECTED]> >Reply-To: "Tomcat Users List" <[EMAIL PROTECTED]> >To: "Tomcat Users List" <[EMAIL PROTECTED]> >Subject: Custom resource loader >Date: Thu, 10 Jun 2004 10:43:18 -0700 > >Greetings, > >A while ago on this list I saw some discussion about custom resource >loaders (extending FileDirContext) to load resources from multiple root >paths. > >I am looking specifically to do this in order to grab jsp pages from a >'commons' directory that many of my sites (which run in different >contexts) use. > >Was there any consensus to the right way to do this? Has anyone done >this already and would be willing to share? > >My plan is to send an extra attribute to the Resource tag in the >server.xml, which is a comma delimited list of additional paths in the >order they should be searched for a given file. The ExtendedDirContext >would then keep all the paths on a list and iterate through them until a >named resource was located. > >Any thoughts, > >Dave Keene > > > > > >- >To unsubscribe, e-mail: [EMAIL PROTECTED] >For additional commands, e-mail: [EMAIL PROTECTED] > _ Looking to buy a house? Get informed with the Home Buying Guide from MSN House & Home. http://coldwellbanker.msn.com/ - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] _ MSN Toolbar provides one-click access to Hotmail from any Web page FREE download! http://toolbar.msn.click-url.com/go/onm00200413ave/direct/01/ - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Corrupted UTF-8 JSPs?!
Thanks, but I believe the problem is in the WAR packaging, somehow ... because I develop locally, deploy w/o packaging and it works fine - if I package it up again and re-deploy LOCALLY, then I get garbage ... native2ascii only works for properties files, as far as I've been able to determine. UTF-8 encoded JSPs have to have UTF-8 encoded characters, not the \u escaped characters that native2ascii creates. We only use native2ascii for our properties files Yansheng Lin wrote: "developed locally, and then deployed remotely" Make sure on the remote system, the Java Runtime Environment supports UTF-8 and is using it as the default encoding(export JAVA_OPTS=-Dfile.encoding="utf8"). native2ascii UTF-8 encoded characters may help too. Yan -Original Message- From: Ruth, Brice [mailto:[EMAIL PROTECTED] Sent: June 10, 2004 14:00 To: Tomcat Users List Subject: Corrupted UTF-8 JSPs?! I'm running into a strange issue. I have certain JSPs with UTF-8 encoded characters in them (polish characters, to be exact). My Ant build.xml precompiles the JSPs using Jasper and then packages the application into a WAR for deployment. When I develop locally with Tomcat 5.0.18, I deploy without packaging into a WAR first. However, to deploy remotely, I create a WAR, then deploy from that. Locally, the JSPs appear just as they should. After being packaged into a WAR (even if I deploy it locally to the exact same instance of Tomcat 5.0.18), the UTF-8 characters are garbaged up. The garbaging appears the same as it does when I override the page-provided UTF-8 encoding (in the browser) and manually set the encoding to ISO-8859-1. What's going on here?! By the time that the JSPs are added to the WAR, they're binary .class files, since they are precompiled! Text encodings shouldn't make a bit of difference at that point, should they?!? The JSPs loaded still tell the browser that the encoding is UTF-8 ... and UTF-8 characters in the .properties files (passed through native2ascii) are properly displayed. It seems to me that something very strange is going on ... moreover, this is going to really throw a wrench in our project if we can't get to the bottom of it! Respectfully, Brice Ruth - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Corrupted UTF-8 JSPs?!
"developed locally, and then deployed remotely" Make sure on the remote system, the Java Runtime Environment supports UTF-8 and is using it as the default encoding(export JAVA_OPTS=-Dfile.encoding="utf8"). native2ascii UTF-8 encoded characters may help too. Yan -Original Message- From: Ruth, Brice [mailto:[EMAIL PROTECTED] Sent: June 10, 2004 14:00 To: Tomcat Users List Subject: Corrupted UTF-8 JSPs?! I'm running into a strange issue. I have certain JSPs with UTF-8 encoded characters in them (polish characters, to be exact). My Ant build.xml precompiles the JSPs using Jasper and then packages the application into a WAR for deployment. When I develop locally with Tomcat 5.0.18, I deploy without packaging into a WAR first. However, to deploy remotely, I create a WAR, then deploy from that. Locally, the JSPs appear just as they should. After being packaged into a WAR (even if I deploy it locally to the exact same instance of Tomcat 5.0.18), the UTF-8 characters are garbaged up. The garbaging appears the same as it does when I override the page-provided UTF-8 encoding (in the browser) and manually set the encoding to ISO-8859-1. What's going on here?! By the time that the JSPs are added to the WAR, they're binary .class files, since they are precompiled! Text encodings shouldn't make a bit of difference at that point, should they?!? The JSPs loaded still tell the browser that the encoding is UTF-8 ... and UTF-8 characters in the .properties files (passed through native2ascii) are properly displayed. It seems to me that something very strange is going on ... moreover, this is going to really throw a wrench in our project if we can't get to the bottom of it! Respectfully, Brice Ruth - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Corrupted UTF-8 JSPs?!
There are two recent related articles on Javaworld. They may help you in this regards. --- "Ruth, Brice" <[EMAIL PROTECTED]> wrote: > I'm running into a strange issue. > > I have certain JSPs with UTF-8 encoded characters in > them (polish > characters, to be exact). My Ant build.xml > precompiles the JSPs using > Jasper and then packages the application into a WAR > for deployment. > > When I develop locally with Tomcat 5.0.18, I deploy > without packaging > into a WAR first. However, to deploy remotely, I > create a WAR, then > deploy from that. > > Locally, the JSPs appear just as they should. After > being packaged into > a WAR (even if I deploy it locally to the exact same > instance of Tomcat > 5.0.18), the UTF-8 characters are garbaged up. The > garbaging appears the > same as it does when I override the page-provided > UTF-8 encoding (in the > browser) and manually set the encoding to > ISO-8859-1. > > What's going on here?! By the time that the JSPs are > added to the WAR, > they're binary .class files, since they are > precompiled! Text encodings > shouldn't make a bit of difference at that point, > should they?!? > > The JSPs loaded still tell the browser that the > encoding is UTF-8 ... > and UTF-8 characters in the .properties files > (passed through > native2ascii) are properly displayed. > > It seems to me that something very strange is going > on ... moreover, > this is going to really throw a wrench in our > project if we can't get to > the bottom of it! > > Respectfully, > Brice Ruth > > - > To unsubscribe, e-mail: > [EMAIL PROTECTED] > For additional commands, e-mail: > [EMAIL PROTECTED] > __ Do you Yahoo!? Friends. Fun. Try the all-new Yahoo! Messenger. http://messenger.yahoo.com/ - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
jk2.log show me these errors
Hi, i have apache 1.3.24 with mod_jk2 2.0.2 and tomcat 4.1.30, the proble is that the jk2.log file show theses messages, i'm not sure is errors messages, i've visited many website that report it same errors...what is the problem or is that normal (i don't think so)? thanks for you help [Thu Jun 10 20:29:16 2004] (error) [jk_handler_response.c (200)]: Error ajp_process_callback - write failed [Thu Jun 10 20:29:16 2004] (error) [jk_worker_ajp13.c (416)]: ajp13.service() ajpGetReply recoverable error 3 [Thu Jun 10 20:29:16 2004] (error) [jk_handler_response.c (200)]: Error ajp_process_callback - write failed [Thu Jun 10 20:29:16 2004] (error) [jk_worker_ajp13.c (416)]: ajp13.service() ajpGetReply recoverable error 3 [Thu Jun 10 20:29:16 2004] (error) [jk_worker_ajp13.c (512)]: ajp13.service() Error forwarding ajp13:localhost:8009 1 0 Thanks Fabian - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Corrupted UTF-8 JSPs?!
I'm running into a strange issue. I have certain JSPs with UTF-8 encoded characters in them (polish characters, to be exact). My Ant build.xml precompiles the JSPs using Jasper and then packages the application into a WAR for deployment. When I develop locally with Tomcat 5.0.18, I deploy without packaging into a WAR first. However, to deploy remotely, I create a WAR, then deploy from that. Locally, the JSPs appear just as they should. After being packaged into a WAR (even if I deploy it locally to the exact same instance of Tomcat 5.0.18), the UTF-8 characters are garbaged up. The garbaging appears the same as it does when I override the page-provided UTF-8 encoding (in the browser) and manually set the encoding to ISO-8859-1. What's going on here?! By the time that the JSPs are added to the WAR, they're binary .class files, since they are precompiled! Text encodings shouldn't make a bit of difference at that point, should they?!? The JSPs loaded still tell the browser that the encoding is UTF-8 ... and UTF-8 characters in the .properties files (passed through native2ascii) are properly displayed. It seems to me that something very strange is going on ... moreover, this is going to really throw a wrench in our project if we can't get to the bottom of it! Respectfully, Brice Ruth - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
FOUND VIRUS IN MAIL from to
V I R U S A L E R T Our viruschecker found a VIRUS in your email to "<[EMAIL PROTECTED]>". We stopped delivery of this email! Now it is on you to check your system for viruses In file: /usr/local/mav/basedir/i5AJrHn8004254/i5AJrHn8004254 Found the W32/Netsky.p.eml!exe virus !!! /usr/local/mav/basedir/i5AJrHn8004254/message.scr Found the W32/[EMAIL PROTECTED] virus !!! For your reference, here are the headers from your email: - BEGIN HEADERS - Received: from pg-as05-l108.crnagora.net [213.149.106.108] by pluton.nspoint.net [195.252.123.15] with SMTP id i5AJrHn8004254; Thu Jun 10 21:53:45 2004 +0200 From: [EMAIL PROTECTED] To: [EMAIL PROTECTED] Subject: Mail Delivery (failure [EMAIL PROTECTED]) Date: Thu, 10 Jun 2004 12:53:18 -0700 MIME-Version: 1.0 Content-Type: multipart/related; type="multipart/alternative"; boundary="=_NextPart_000_001B_01C0CA80.6B015D10" X-Priority: 3 X-MSMail-Priority: Normal -- END HEADERS -- - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Works! RE: 2nd inquiry: how to - programmatically - authenticate oneself as Tomcat manager?
Jerry Miernik wrote: This works! How did you come to know that? Is there a doc I should have read to know? Well, strictly speaking, if you read the doc you'll know that's not a legal URL :-) RFC 1738: Uniform Resource Locators (URL) shows the format: 3.1. Common Internet Scheme Syntax While the syntax for the rest of the URL may vary depending on the particular scheme selected, URL schemes that involve the direct use of an IP-based protocol to a specified host on the Internet use a common syntax for the scheme-specific data: //:@:/ *BUT* (see last sentence) 3.3. HTTP The HTTP URL scheme is used to designate Internet resources accessible using HTTP (HyperText Transfer Protocol). The HTTP protocol is specified elsewhere. This specification only describes the syntax of HTTP URLs. An HTTP URL takes the form: http://:/? where and are as described in Section 3.1. If : is omitted, the port defaults to 80. No user name or password is allowed. Which is not to say that it won't, in some circumstances, "work"... FWIW! That's not true. You can do: http://username:[EMAIL PROTECTED]/ so: URL tomcatMgr = new URL("http://manager:[EMAIL PROTECTED]:8080/manager/undeploy?path=/any"); -- Hassan Schroeder - [EMAIL PROTECTED] Webtuitive Design === (+1) 408-938-0567 === http://webtuitive.com dream. code. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: contextInitialized being called exactly twice
Hi, Take a look also at deployXML, as that's related to the context XML configuration files and automatic deployment. The path="" docbase="" is probably not what you want for test 4, it's docbase="ROOT". Yoav Shapira Millennium Research Informatics >-Original Message- >From: Graham Smith [mailto:[EMAIL PROTECTED] >Sent: Thursday, June 10, 2004 3:07 PM >To: Tomcat Users List >Subject: Re: contextInitialized being called exactly twice > >Hi, > >Thanks for the help. I took a break for an hour or so (after working on >this nearly all day), and came to the same conclusion. I have managed to >get it to only initialize once now but it does work as I would expect it >to. > >Test 1 >If autoDeploy="false" and I have a context definition in the server.xml >() then >it calls contextInitialization twice. > >Test 2 >if autoDeploy="false" and I have no context in the server.xml file it >calls contextInitialization only once but the software is then deployed >with the wrong context > >Test 3 >if I rename the webapp (from webapps/xfly to webapps/ROOT), include a >context definition of and leave >autoDeploy="false" then it doesn't get deployed at all > >Test 4 >As test 3 but if I remove the context definition from the server.xml >file then it deploys and calls contextInitialization only once. > >Test 5 >As test 4 but with autoDeploy="true" gives the same result. > >Now thats all fine and good as I have a solution to my problem but it >does seem to indicate that it's impossible to have a webapp in the hosts >appBase directory that is deployed under a different context name from >its directory name (well, unless you want it initialized twice). Is this >a bug or a feature? Surely it must be fairly simple to check whether a >particular webapp has already been deployed (possibly under a different >context name) and not deploy it a second time if it has. I don't >remember seeing anything in the servlet spec that forbade deploying a >webapp twice in a since host but I don't think its what most people >would expect. > >graham > >Shapira, Yoav wrote: > >>Hi >>I bet it's being called once for each time the context is deployed, and >>the context is deployed twice because you have autoDeploy on AND an >>explicit context declaration in your server.xml/conf directory/WAR. >>Turn autoDeploy off and see what happens. >> >>(This would explain the static counter being 1: the counter is static >>once per classloader repository, you have two of the same context at >>different paths with different classloader repositories). >> >>Yoav Shapira >>Millennium Research Informatics >> >> >> >> >>>-Original Message- >>>From: Graham Smith [mailto:[EMAIL PROTECTED] >>>Sent: Thursday, June 10, 2004 12:32 PM >>>To: [EMAIL PROTECTED] >>>Subject: contextInitialized being called exactly twice >>> >>>Hi, >>> >>>I am absolutely stumped by this problem. For some reason that I can't >>>fathom the contextInitialized method on a ServletContextListener I have >>>in one of my web applications is being called twice. Normally this >>> >>> >>isn't >> >> >>>a problem since it only causes the load process to take longer but I >>>have recently added a new section that starts a daemon thread and it >>>this double call is causing two threads to be created. What is even >>> >>> >>more >> >> >>>bizarre is that I have tried using a static int to count the number of >>>times the method is called but it always returns one. I suspected that >>>it therefore must be created by a different class loader but a call to >>>getClass().getClassLoader and a dump (see below) of information would >>>seem to indicate that it is in fact the same class loader loading the >>>class. I am using tomcat 5.0.25 on Linux with Java 1.4.2_04. I have >>> >>> >>also >> >> >>>performed a thread dump in order to check that it is _really_ being run >>>twice and sure enough there are two copies of my thread running (again >>>see extract below). >>> >>>Any help would be greatly appreciated. >>> >>>Graham >>> >>>ClassLoader dump: >>> >>>First time it is loaded >>> >>>ClassLoader: WebappClassLoader >>> delegate: false >>> repositories: >>>--> Parent Classloader: >>>StandardClassLoader >>> delegate: true >>> repositories: >>>file:/home/gms/dump/tomcat/shared/classes/ >>>--> Parent Classloader: >>>StandardClassLoader >>> delegate: true >>> repositories: >>>file:/home/gms/dump/tomcat/common/classes/ >>>file:/home/gms/dump/tomcat/common/endorsed/xercesImpl.jar >>>file:/home/gms/dump/tomcat/common/endorsed/xmlParserAPIs.jar >>>file:/home/gms/dump/tomcat/common/lib/ant.jar >>>file:/home/gms/dump/tomcat/common/lib/commons-collections.jar >>>file:/home/gms/dump/tomcat/common/lib/commons-dbcp-1.1.jar >>>file:/home/gms/dump/tomcat/common/lib/commons-el.jar >>>file:/home/gms/dump/tomcat/common/lib/commons-pool-1.1.jar >>>file:/home/gms/dum
Re: contextInitialized being called exactly twice
Hi, Thanks for the help. I took a break for an hour or so (after working on this nearly all day), and came to the same conclusion. I have managed to get it to only initialize once now but it does work as I would expect it to. Test 1 If autoDeploy="false" and I have a context definition in the server.xml () then it calls contextInitialization twice. Test 2 if autoDeploy="false" and I have no context in the server.xml file it calls contextInitialization only once but the software is then deployed with the wrong context Test 3 if I rename the webapp (from webapps/xfly to webapps/ROOT), include a context definition of and leave autoDeploy="false" then it doesn't get deployed at all Test 4 As test 3 but if I remove the context definition from the server.xml file then it deploys and calls contextInitialization only once. Test 5 As test 4 but with autoDeploy="true" gives the same result. Now thats all fine and good as I have a solution to my problem but it does seem to indicate that it's impossible to have a webapp in the hosts appBase directory that is deployed under a different context name from its directory name (well, unless you want it initialized twice). Is this a bug or a feature? Surely it must be fairly simple to check whether a particular webapp has already been deployed (possibly under a different context name) and not deploy it a second time if it has. I don't remember seeing anything in the servlet spec that forbade deploying a webapp twice in a since host but I don't think its what most people would expect. graham Shapira, Yoav wrote: Hi I bet it's being called once for each time the context is deployed, and the context is deployed twice because you have autoDeploy on AND an explicit context declaration in your server.xml/conf directory/WAR. Turn autoDeploy off and see what happens. (This would explain the static counter being 1: the counter is static once per classloader repository, you have two of the same context at different paths with different classloader repositories). Yoav Shapira Millennium Research Informatics -Original Message- From: Graham Smith [mailto:[EMAIL PROTECTED] Sent: Thursday, June 10, 2004 12:32 PM To: [EMAIL PROTECTED] Subject: contextInitialized being called exactly twice Hi, I am absolutely stumped by this problem. For some reason that I can't fathom the contextInitialized method on a ServletContextListener I have in one of my web applications is being called twice. Normally this isn't a problem since it only causes the load process to take longer but I have recently added a new section that starts a daemon thread and it this double call is causing two threads to be created. What is even more bizarre is that I have tried using a static int to count the number of times the method is called but it always returns one. I suspected that it therefore must be created by a different class loader but a call to getClass().getClassLoader and a dump (see below) of information would seem to indicate that it is in fact the same class loader loading the class. I am using tomcat 5.0.25 on Linux with Java 1.4.2_04. I have also performed a thread dump in order to check that it is _really_ being run twice and sure enough there are two copies of my thread running (again see extract below). Any help would be greatly appreciated. Graham ClassLoader dump: First time it is loaded ClassLoader: WebappClassLoader delegate: false repositories: --> Parent Classloader: StandardClassLoader delegate: true repositories: file:/home/gms/dump/tomcat/shared/classes/ --> Parent Classloader: StandardClassLoader delegate: true repositories: file:/home/gms/dump/tomcat/common/classes/ file:/home/gms/dump/tomcat/common/endorsed/xercesImpl.jar file:/home/gms/dump/tomcat/common/endorsed/xmlParserAPIs.jar file:/home/gms/dump/tomcat/common/lib/ant.jar file:/home/gms/dump/tomcat/common/lib/commons-collections.jar file:/home/gms/dump/tomcat/common/lib/commons-dbcp-1.1.jar file:/home/gms/dump/tomcat/common/lib/commons-el.jar file:/home/gms/dump/tomcat/common/lib/commons-pool-1.1.jar file:/home/gms/dump/tomcat/common/lib/jasper-compiler.jar file:/home/gms/dump/tomcat/common/lib/jasper-runtime.jar file:/home/gms/dump/tomcat/common/lib/jsp-api.jar file:/home/gms/dump/tomcat/common/lib/naming-common.jar file:/home/gms/dump/tomcat/common/lib/naming-factory.jar file:/home/gms/dump/tomcat/common/lib/naming-java.jar file:/home/gms/dump/tomcat/common/lib/naming-resources.jar file:/home/gms/dump/tomcat/common/lib/servlet-api.jar --> Parent Classloader: [EMAIL PROTECTED] Second time it is loaded ClassLoader: WebappClassLoader delegate: false repositories: --> Parent Classloade
RE: Works! RE: 2nd inquiry: how to - programmatically - authenticate oneself as Tomcat manager?
Hi, It's in the HTTP RFC (2616 I believe is the RFC number, google for it). Yoav Shapira Millennium Research Informatics >-Original Message- >From: Jerry Miernik [mailto:[EMAIL PROTECTED] >Sent: Thursday, June 10, 2004 3:03 PM >To: Tomcat Users List >Subject: Works! RE: 2nd inquiry: how to - programmatically - authenticate >oneself as Tomcat manager? > > Jake, > This works! How did you come to know that? > Is there a doc I should have read to know? > Thanks, > Jerry. > > >-Original Message- >From: Jacob Kjome [mailto:[EMAIL PROTECTED] >Sent: Thursday, June 10, 2004 1:44 PM >To: Tomcat Users List >Subject: Re: 2nd inquiry: how to - programmatically - authenticate oneself >as Tomcat manager? > >Quoting Bill Barker <[EMAIL PROTECTED]>: >> 1) Assuming boring system encodings, and something to do Base64 >encoding: >>String creds = username+":"+password; >>String b64creds = Base64Util.encode(creds.getBytes()); >>tmc.addRequestProperty("Authorization","Basic "+b64creds); >> >> 2) Not with Basic. You might be able to rig something with Form. >> > >That's not true. You can do: > >http://username:[EMAIL PROTECTED]/ > >so: > >URL tomcatMgr = > new >URL("http://manager:[EMAIL PROTECTED]:8080/manager/undeploy?path=/an y"); > >Jake > >> >> "Jerry Miernik" <[EMAIL PROTECTED]> wrote in message >> news:[EMAIL PROTECTED] >exchange.amer.unity.cisco.com... >> The question is related to undeploying a webapplication >> from a Java code. A connection to tomcat manager using >> >> URL tomcatMgr = >> new URL("http://localhost:8080/manager/undeploy?path=/any";); >> URLConnection tmc = tomcatMgr.openConnection(); >> >> >> results in: >> java.io.IOException:Server returned HTTP response code: 401 >> >> The questions: >> 1. Is there a way to deliver - programmatically - username >> and password for the undeploy to take effect? >> >> 2. Could the username and password be parameters in the >> undeploy request? Or an earlier request? >> >> 3. This Java program is trying to undeploy itself, inside >> a jspInit() method. Is this technically possible? >> (do not see why not, except for the problem with user >> name and password). >> >> Thanks, >> Jerry. >> >> - >> To unsubscribe, e-mail: [EMAIL PROTECTED] >> For additional commands, e-mail: [EMAIL PROTECTED] >> >> >> >> >> - >> To unsubscribe, e-mail: [EMAIL PROTECTED] >> For additional commands, e-mail: [EMAIL PROTECTED] > >- >To unsubscribe, e-mail: [EMAIL PROTECTED] >For additional commands, e-mail: [EMAIL PROTECTED] > > >- >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]
Works! RE: 2nd inquiry: how to - programmatically - authenticate oneself as Tomcat manager?
Jake, This works! How did you come to know that? Is there a doc I should have read to know? Thanks, Jerry. -Original Message- From: Jacob Kjome [mailto:[EMAIL PROTECTED] Sent: Thursday, June 10, 2004 1:44 PM To: Tomcat Users List Subject: Re: 2nd inquiry: how to - programmatically - authenticate oneself as Tomcat manager? Quoting Bill Barker <[EMAIL PROTECTED]>: > 1) Assuming boring system encodings, and something to do Base64 encoding: >String creds = username+":"+password; >String b64creds = Base64Util.encode(creds.getBytes()); >tmc.addRequestProperty("Authorization","Basic "+b64creds); > > 2) Not with Basic. You might be able to rig something with Form. > That's not true. You can do: http://username:[EMAIL PROTECTED]/ so: URL tomcatMgr = new URL("http://manager:[EMAIL PROTECTED]:8080/manager/undeploy?path=/any"); Jake > > "Jerry Miernik" <[EMAIL PROTECTED]> wrote in message > news:[EMAIL PROTECTED] > The question is related to undeploying a webapplication > from a Java code. A connection to tomcat manager using > > URL tomcatMgr = > new URL("http://localhost:8080/manager/undeploy?path=/any";); > URLConnection tmc = tomcatMgr.openConnection(); > > > results in: > java.io.IOException:Server returned HTTP response code: 401 > > The questions: > 1. Is there a way to deliver - programmatically - username > and password for the undeploy to take effect? > > 2. Could the username and password be parameters in the > undeploy request? Or an earlier request? > > 3. This Java program is trying to undeploy itself, inside > a jspInit() method. Is this technically possible? > (do not see why not, except for the problem with user > name and password). > > Thanks, > Jerry. > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > > > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Custom resource loader
That's a good ide frank, but it may not work. FilrDirContext has a normalize method... the javadoc comment says: * Return a context-relative path, beginning with a "/", that represents * the canonical version of the specified path after ".." and "." elements * are resolved out. If the specified path attempts to go outside the * boundaries of the current context (i.e. too many ".." path elements * are present), return null instead. Doh! Also, it would be nice to have the freedom to place the 'common' elsewhere on the system. Dave -Original Message- From: Frank Zammetti [mailto:[EMAIL PROTECTED] Sent: Thursday, June 10, 2004 11:17 AM To: [EMAIL PROTECTED] Subject: RE: Custom resource loader May I suggest one wacky idea? I'm not saying this is GOOD or anything, but it's probably a bit outside the box, for whatever that's worth... What if you had all your common JSPs in a given directory, like so (let's talk Tomcat for a minute, but it doesn't matter)... /tomcat/webapps/commonjsps /tomcat/webapps/webapp1 /tomcat/webapps/webapp2 Then, in either webapp1 or webapp2, let's say you want to use the JSP myJSP1.jsp in the common jsps directory... What if you had a JSP in webapp1 and webapp2 that was just this: <%@ page language="java" %> <%@ include file="../commonjsps/myJSP1.jsp.inc" %> My syntax might be a little off, but I think the concept is clean. You would have to have basically a "dummy" page that includes the real page, and that could be a pain, but I think this would work, and maybe it's quicker to do than a custom resource loader. Just a thought. Frank >From: "Keene, David" <[EMAIL PROTECTED]> >Reply-To: "Tomcat Users List" <[EMAIL PROTECTED]> >To: "Tomcat Users List" <[EMAIL PROTECTED]> >Subject: Custom resource loader >Date: Thu, 10 Jun 2004 10:43:18 -0700 > >Greetings, > >A while ago on this list I saw some discussion about custom resource >loaders (extending FileDirContext) to load resources from multiple root >paths. > >I am looking specifically to do this in order to grab jsp pages from a >'commons' directory that many of my sites (which run in different >contexts) use. > >Was there any consensus to the right way to do this? Has anyone done >this already and would be willing to share? > >My plan is to send an extra attribute to the Resource tag in the >server.xml, which is a comma delimited list of additional paths in the >order they should be searched for a given file. The ExtendedDirContext >would then keep all the paths on a list and iterate through them until a >named resource was located. > >Any thoughts, > >Dave Keene > > > > > >- >To unsubscribe, e-mail: [EMAIL PROTECTED] >For additional commands, e-mail: [EMAIL PROTECTED] > _ Looking to buy a house? Get informed with the Home Buying Guide from MSN House & Home. http://coldwellbanker.msn.com/ - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: 2nd inquiry: how to - programmatically - authenticate oneself as Tomcat manager?
Quoting Bill Barker <[EMAIL PROTECTED]>: > 1) Assuming boring system encodings, and something to do Base64 encoding: >String creds = username+":"+password; >String b64creds = Base64Util.encode(creds.getBytes()); >tmc.addRequestProperty("Authorization","Basic "+b64creds); > > 2) Not with Basic. You might be able to rig something with Form. > That's not true. You can do: http://username:[EMAIL PROTECTED]/ so: URL tomcatMgr = new URL("http://manager:[EMAIL PROTECTED]:8080/manager/undeploy?path=/any"); Jake > > "Jerry Miernik" <[EMAIL PROTECTED]> wrote in message > news:[EMAIL PROTECTED] > The question is related to undeploying a webapplication > from a Java code. A connection to tomcat manager using > > URL tomcatMgr = > new URL("http://localhost:8080/manager/undeploy?path=/any";); > URLConnection tmc = tomcatMgr.openConnection(); > > > results in: > java.io.IOException:Server returned HTTP response code: 401 > > The questions: > 1. Is there a way to deliver - programmatically - username > and password for the undeploy to take effect? > > 2. Could the username and password be parameters in the > undeploy request? Or an earlier request? > > 3. This Java program is trying to undeploy itself, inside > a jspInit() method. Is this technically possible? > (do not see why not, except for the problem with user > name and password). > > Thanks, > Jerry. > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > > > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Custom resource loader
May I suggest one wacky idea? I'm not saying this is GOOD or anything, but it's probably a bit outside the box, for whatever that's worth... What if you had all your common JSPs in a given directory, like so (let's talk Tomcat for a minute, but it doesn't matter)... /tomcat/webapps/commonjsps /tomcat/webapps/webapp1 /tomcat/webapps/webapp2 Then, in either webapp1 or webapp2, let's say you want to use the JSP myJSP1.jsp in the common jsps directory... What if you had a JSP in webapp1 and webapp2 that was just this: <%@ page language="java" %> <%@ include file="../commonjsps/myJSP1.jsp.inc" %> My syntax might be a little off, but I think the concept is clean. You would have to have basically a "dummy" page that includes the real page, and that could be a pain, but I think this would work, and maybe it's quicker to do than a custom resource loader. Just a thought. Frank From: "Keene, David" <[EMAIL PROTECTED]> Reply-To: "Tomcat Users List" <[EMAIL PROTECTED]> To: "Tomcat Users List" <[EMAIL PROTECTED]> Subject: Custom resource loader Date: Thu, 10 Jun 2004 10:43:18 -0700 Greetings, A while ago on this list I saw some discussion about custom resource loaders (extending FileDirContext) to load resources from multiple root paths. I am looking specifically to do this in order to grab jsp pages from a 'commons' directory that many of my sites (which run in different contexts) use. Was there any consensus to the right way to do this? Has anyone done this already and would be willing to share? My plan is to send an extra attribute to the Resource tag in the server.xml, which is a comma delimited list of additional paths in the order they should be searched for a given file. The ExtendedDirContext would then keep all the paths on a list and iterate through them until a named resource was located. Any thoughts, Dave Keene - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] _ Looking to buy a house? Get informed with the Home Buying Guide from MSN House & Home. http://coldwellbanker.msn.com/ - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: contextInitialized being called exactly twice
Hi I bet it's being called once for each time the context is deployed, and the context is deployed twice because you have autoDeploy on AND an explicit context declaration in your server.xml/conf directory/WAR. Turn autoDeploy off and see what happens. (This would explain the static counter being 1: the counter is static once per classloader repository, you have two of the same context at different paths with different classloader repositories). Yoav Shapira Millennium Research Informatics >-Original Message- >From: Graham Smith [mailto:[EMAIL PROTECTED] >Sent: Thursday, June 10, 2004 12:32 PM >To: [EMAIL PROTECTED] >Subject: contextInitialized being called exactly twice > >Hi, > >I am absolutely stumped by this problem. For some reason that I can't >fathom the contextInitialized method on a ServletContextListener I have >in one of my web applications is being called twice. Normally this isn't >a problem since it only causes the load process to take longer but I >have recently added a new section that starts a daemon thread and it >this double call is causing two threads to be created. What is even more >bizarre is that I have tried using a static int to count the number of >times the method is called but it always returns one. I suspected that >it therefore must be created by a different class loader but a call to >getClass().getClassLoader and a dump (see below) of information would >seem to indicate that it is in fact the same class loader loading the >class. I am using tomcat 5.0.25 on Linux with Java 1.4.2_04. I have also >performed a thread dump in order to check that it is _really_ being run >twice and sure enough there are two copies of my thread running (again >see extract below). > >Any help would be greatly appreciated. > >Graham > >ClassLoader dump: > >First time it is loaded > >ClassLoader: WebappClassLoader > delegate: false > repositories: >--> Parent Classloader: >StandardClassLoader > delegate: true > repositories: > file:/home/gms/dump/tomcat/shared/classes/ >--> Parent Classloader: >StandardClassLoader > delegate: true > repositories: > file:/home/gms/dump/tomcat/common/classes/ > file:/home/gms/dump/tomcat/common/endorsed/xercesImpl.jar > file:/home/gms/dump/tomcat/common/endorsed/xmlParserAPIs.jar > file:/home/gms/dump/tomcat/common/lib/ant.jar > file:/home/gms/dump/tomcat/common/lib/commons-collections.jar > file:/home/gms/dump/tomcat/common/lib/commons-dbcp-1.1.jar > file:/home/gms/dump/tomcat/common/lib/commons-el.jar > file:/home/gms/dump/tomcat/common/lib/commons-pool-1.1.jar > file:/home/gms/dump/tomcat/common/lib/jasper-compiler.jar > file:/home/gms/dump/tomcat/common/lib/jasper-runtime.jar > file:/home/gms/dump/tomcat/common/lib/jsp-api.jar > file:/home/gms/dump/tomcat/common/lib/naming-common.jar > file:/home/gms/dump/tomcat/common/lib/naming-factory.jar > file:/home/gms/dump/tomcat/common/lib/naming-java.jar > file:/home/gms/dump/tomcat/common/lib/naming-resources.jar > file:/home/gms/dump/tomcat/common/lib/servlet-api.jar >--> Parent Classloader: >[EMAIL PROTECTED] > > > >Second time it is loaded > > >ClassLoader: WebappClassLoader > delegate: false > repositories: >--> Parent Classloader: >StandardClassLoader > delegate: true > repositories: > file:/home/gms/dump/tomcat/shared/classes/ >--> Parent Classloader: >StandardClassLoader > delegate: true > repositories: > file:/home/gms/dump/tomcat/common/classes/ > file:/home/gms/dump/tomcat/common/endorsed/xercesImpl.jar > file:/home/gms/dump/tomcat/common/endorsed/xmlParserAPIs.jar > file:/home/gms/dump/tomcat/common/lib/ant.jar > file:/home/gms/dump/tomcat/common/lib/commons-collections.jar > file:/home/gms/dump/tomcat/common/lib/commons-dbcp-1.1.jar > file:/home/gms/dump/tomcat/common/lib/commons-el.jar > file:/home/gms/dump/tomcat/common/lib/commons-pool-1.1.jar > file:/home/gms/dump/tomcat/common/lib/jasper-compiler.jar > file:/home/gms/dump/tomcat/common/lib/jasper-runtime.jar > file:/home/gms/dump/tomcat/common/lib/jsp-api.jar > file:/home/gms/dump/tomcat/common/lib/naming-common.jar > file:/home/gms/dump/tomcat/common/lib/naming-factory.jar > file:/home/gms/dump/tomcat/common/lib/naming-java.jar > file:/home/gms/dump/tomcat/common/lib/naming-resources.jar > file:/home/gms/dump/tomcat/common/lib/servlet-api.jar >--> Parent Classloader: >[EMAIL PROTECTED] > > > > >Extract of thread dump > > >.. > > >"ContainerBackgroundProcessor[StandardEngine[Catalina]]" daemon prio=1 >tid=0x0848eb98 nid=0x7d54
RE: Advice needed on deploying on Tomcat 5.0.25
The web.xml requirement changed between 4.24 and 4.29. Once I upgraded to 4.1.29, I needed to add web.xml to a remote directory that I had mapped as a context otherwise that context would not start. Normally not a problem, however I only had read access so I had to get the admin to create a WEB-INF directory with a nearly empty web.xml. This had worked without a web.xml in 4.1.24, so I'm not sure which version actually changed the requirement. I haven't tried 5.x, so I'm not sure if it requires web.xml or not. Charlie > -Original Message- > From: Shapira, Yoav [mailto:[EMAIL PROTECTED] > Sent: Wednesday, June 09, 2004 9:40 AM > To: Tomcat Users List > Subject: RE: Advice needed on deploying on Tomcat 5.0.25 > > > Hi, > A web.xml was a requirement with 4.x in that otherwise it would just use > defaults. 5.x is the same way, so while web.xml is not strictly > required by tomcat, it is required by the spec and strongly encouraged. > > 5.x and later versions of 4.x (after 4.1.18) comment out the invoker > servlet by default. That's probably why you're seeing your error. So > your assertion that your app worked on 4.x is false: it may have worked > on 4.0.x and 4.1.y where y < 18, but not later version of 4.x. > > You can read more about the invoker servlet and why it was commented out > in the tomcat faq (jakarta.apache.org/tomcat/faq). > > Yoav Shapira > Millennium Research Informatics > > > >-Original Message- > >From: Edd Dawson [mailto:[EMAIL PROTECTED] > >Sent: Wednesday, June 09, 2004 9:29 AM > >To: [EMAIL PROTECTED] > >Subject: Advice needed on deploying on Tomcat 5.0.25 > > > >Hi > > > >I recently installed Tomcat 5.0.25 on my windows laptop. > > > > > >I did have 4.x installed and i copied over my faithful HelloWorld > >example from 4.x/webapps directory to my new 5.0.25/webapps directory.. > > > >and it doesn't work! I get the following error : > > > >HTTP Status 404 - /hello/servlet/HelloWorld > > > >--- > > >- > > > >type Status report > > > >message /hello/servlet/HelloWorld > > > >description The requested resource (/hello/servlet/HelloWorld) is not > >available > > > > > > > >It still works fine on 4.x. > > > >So i tried putting the class file in the /class directory of the > >servlets-examples webapp that came with 5.0.25 and it didn't work until > >i added its details the web.xml for that app. > > > >Now do i HAVE to have a web.xml now i am using 5.0.25 ? as with 4.x it > >wasn't a requirement. > > > >cheers > >Edd Dawson > > > >- > >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]
Custom resource loader
Greetings, A while ago on this list I saw some discussion about custom resource loaders (extending FileDirContext) to load resources from multiple root paths. I am looking specifically to do this in order to grab jsp pages from a 'commons' directory that many of my sites (which run in different contexts) use. Was there any consensus to the right way to do this? Has anyone done this already and would be willing to share? My plan is to send an extra attribute to the Resource tag in the server.xml, which is a comma delimited list of additional paths in the order they should be searched for a given file. The ExtendedDirContext would then keep all the paths on a list and iterate through them until a named resource was located. Any thoughts, Dave Keene - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Where is Digester?
I didn't read that fully, the file is in ${tomcat_home}/server/lib or at least it should be. But it's still "commons-digester.jar" (I was wrong in the other message, that was the archive of it). --mikej -=- mike jackson [EMAIL PROTECTED] -Original Message- From: Barnet Wagman [mailto:[EMAIL PROTECTED] Sent: Thursday, June 10, 2004 10:07 AM To: [EMAIL PROTECTED] Subject: Where is Digester? Could some tell me which jar file contains org/apache/commons/digester/Digester and where the path to it gets specified in server.xml (Tomcat 5)? I've added a second service to my server.xml file (to support a second IP address). When Tomcat starts, the second service is throwing a java.lang.NoClassDefFoundError: org/apache/commons/digester/Digester (FYI the problem probably has to do with how I specified the Engine and Hostname. On the first service I used 'localhost', in the second I used the actual domain name. Tomcat is able to server html from the second, so the domain name is correct.) Thanks, bw - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Where is Digester?
"commons-digester-1.5.tar.gz" --mikej -=- mike jackson [EMAIL PROTECTED] -Original Message- From: Barnet Wagman [mailto:[EMAIL PROTECTED] Sent: Thursday, June 10, 2004 10:07 AM To: [EMAIL PROTECTED] Subject: Where is Digester? Could some tell me which jar file contains org/apache/commons/digester/Digester and where the path to it gets specified in server.xml (Tomcat 5)? I've added a second service to my server.xml file (to support a second IP address). When Tomcat starts, the second service is throwing a java.lang.NoClassDefFoundError: org/apache/commons/digester/Digester (FYI the problem probably has to do with how I specified the Engine and Hostname. On the first service I used 'localhost', in the second I used the actual domain name. Tomcat is able to server html from the second, so the domain name is correct.) Thanks, bw - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Where is Digester?
Could some tell me which jar file contains org/apache/commons/digester/Digester and where the path to it gets specified in server.xml (Tomcat 5)? I've added a second service to my server.xml file (to support a second IP address). When Tomcat starts, the second service is throwing a java.lang.NoClassDefFoundError: org/apache/commons/digester/Digester (FYI the problem probably has to do with how I specified the Engine and Hostname. On the first service I used 'localhost', in the second I used the actual domain name. Tomcat is able to server html from the second, so the domain name is correct.) Thanks, bw - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Denial Service Attack Prevention apache-tomcat modjk2
thanks for all the code ideas, will forward them to our developers on the flip side can apache or tomcat do anything for any sort of denial attack prevention on a larger scale? -s Robert F. Hall wrote: Howdy, And you can disable the submit button up fron if the user has JavaScript disabled, displaying a message to indicate that your site requires JavaScript. Then there is also the SynchronizerToken which your app could use to recognize and ignore duplicate requests. Robert UC Berkeley Shapira, Yoav wrote: Hi, You can use JavaScript to disable form elements, thereby graying them out and preventing the user from clicking again. Yoav Shapira Millennium Research Informatics -Original Message- From: Steve [mailto:[EMAIL PROTECTED] Sent: Thursday, June 10, 2004 10:52 AM To: Tomcat Users List Subject: Denial Service Attack Prevention apache-tomcat modjk2 Looking for a solution to prevent a user from click multiply times on a function in which the application is still performing from the first click. The user thinkgs the app is not responding where in fact it is, then causing the app to take a dump from multiply request. Using cisco css LB into --> Apache, mod_jk2 into tomcat 4.1.29 any tips or pointers greatly appr -s - 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] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Denial Service Attack Prevention apache-tomcat modjk2
Howdy, And you can disable the submit button up fron if the user has JavaScript disabled, displaying a message to indicate that your site requires JavaScript. Then there is also the SynchronizerToken which your app could use to recognize and ignore duplicate requests. Robert UC Berkeley Shapira, Yoav wrote: Hi, You can use JavaScript to disable form elements, thereby graying them out and preventing the user from clicking again. Yoav Shapira Millennium Research Informatics -Original Message- From: Steve [mailto:[EMAIL PROTECTED] Sent: Thursday, June 10, 2004 10:52 AM To: Tomcat Users List Subject: Denial Service Attack Prevention apache-tomcat modjk2 Looking for a solution to prevent a user from click multiply times on a function in which the application is still performing from the first click. The user thinkgs the app is not responding where in fact it is, then causing the app to take a dump from multiply request. Using cisco css LB into --> Apache, mod_jk2 into tomcat 4.1.29 any tips or pointers greatly appr -s - 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]
Re: Getting Host information from within webapp
Would request.getServerName() work? -Tim Kevin McAllister wrote: Kevin McAllister wrote: I am using tomcat 4.1.29, and would like to obtain the host name attribute from within my servlet code for the associated context in which I am running. I think I would be able to retrieve this information utilizing the JMX stuff Upon doing some further research I found I would be able to get a host name given a context as long as my webapp was privileged (so the org.apache.catalina.mbean.ServerLifecycleListener would place a reference to the MBeanServer in the ServletContext attributes) However, it seems the only information I would have to Query the MBeanServer is the context path, And if I have more than one context path which is the same (on different Hosts obviously) then I would not be able to uniquely Identify the Host to which I am bound. And since I will most certainly have many Hosts each with the same context path for my webapp, this method will not work for my purposes. Hopefully the information is available somewhere else, or otherwise I may be able to obtain it by inserting another ServerLifeCycleListener that can gather the information from the context adding event and put it on the ServletContext attributes. - Kevin - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
contextInitialized being called exactly twice
Hi, I am absolutely stumped by this problem. For some reason that I can't fathom the contextInitialized method on a ServletContextListener I have in one of my web applications is being called twice. Normally this isn't a problem since it only causes the load process to take longer but I have recently added a new section that starts a daemon thread and it this double call is causing two threads to be created. What is even more bizarre is that I have tried using a static int to count the number of times the method is called but it always returns one. I suspected that it therefore must be created by a different class loader but a call to getClass().getClassLoader and a dump (see below) of information would seem to indicate that it is in fact the same class loader loading the class. I am using tomcat 5.0.25 on Linux with Java 1.4.2_04. I have also performed a thread dump in order to check that it is _really_ being run twice and sure enough there are two copies of my thread running (again see extract below). Any help would be greatly appreciated. Graham ClassLoader dump: First time it is loaded ClassLoader: WebappClassLoader delegate: false repositories: --> Parent Classloader: StandardClassLoader delegate: true repositories: file:/home/gms/dump/tomcat/shared/classes/ --> Parent Classloader: StandardClassLoader delegate: true repositories: file:/home/gms/dump/tomcat/common/classes/ file:/home/gms/dump/tomcat/common/endorsed/xercesImpl.jar file:/home/gms/dump/tomcat/common/endorsed/xmlParserAPIs.jar file:/home/gms/dump/tomcat/common/lib/ant.jar file:/home/gms/dump/tomcat/common/lib/commons-collections.jar file:/home/gms/dump/tomcat/common/lib/commons-dbcp-1.1.jar file:/home/gms/dump/tomcat/common/lib/commons-el.jar file:/home/gms/dump/tomcat/common/lib/commons-pool-1.1.jar file:/home/gms/dump/tomcat/common/lib/jasper-compiler.jar file:/home/gms/dump/tomcat/common/lib/jasper-runtime.jar file:/home/gms/dump/tomcat/common/lib/jsp-api.jar file:/home/gms/dump/tomcat/common/lib/naming-common.jar file:/home/gms/dump/tomcat/common/lib/naming-factory.jar file:/home/gms/dump/tomcat/common/lib/naming-java.jar file:/home/gms/dump/tomcat/common/lib/naming-resources.jar file:/home/gms/dump/tomcat/common/lib/servlet-api.jar --> Parent Classloader: [EMAIL PROTECTED] Second time it is loaded ClassLoader: WebappClassLoader delegate: false repositories: --> Parent Classloader: StandardClassLoader delegate: true repositories: file:/home/gms/dump/tomcat/shared/classes/ --> Parent Classloader: StandardClassLoader delegate: true repositories: file:/home/gms/dump/tomcat/common/classes/ file:/home/gms/dump/tomcat/common/endorsed/xercesImpl.jar file:/home/gms/dump/tomcat/common/endorsed/xmlParserAPIs.jar file:/home/gms/dump/tomcat/common/lib/ant.jar file:/home/gms/dump/tomcat/common/lib/commons-collections.jar file:/home/gms/dump/tomcat/common/lib/commons-dbcp-1.1.jar file:/home/gms/dump/tomcat/common/lib/commons-el.jar file:/home/gms/dump/tomcat/common/lib/commons-pool-1.1.jar file:/home/gms/dump/tomcat/common/lib/jasper-compiler.jar file:/home/gms/dump/tomcat/common/lib/jasper-runtime.jar file:/home/gms/dump/tomcat/common/lib/jsp-api.jar file:/home/gms/dump/tomcat/common/lib/naming-common.jar file:/home/gms/dump/tomcat/common/lib/naming-factory.jar file:/home/gms/dump/tomcat/common/lib/naming-java.jar file:/home/gms/dump/tomcat/common/lib/naming-resources.jar file:/home/gms/dump/tomcat/common/lib/servlet-api.jar --> Parent Classloader: [EMAIL PROTECTED] Extract of thread dump .. "ContainerBackgroundProcessor[StandardEngine[Catalina]]" daemon prio=1 tid=0x0848eb98 nid=0x7d54 waiting on condition [4d90d000..4d90d854] at java.lang.Thread.sleep(Native Method) at org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.run(ContainerBase.java:1597) at java.lang.Thread.run(Thread.java:534) "category statistics generator" daemon prio=1 tid=0x082e6960 nid=0x7d54 waiting on condition [4e1de000..4e1de854] at java.lang.Thread.sleep(Native Method) at com.crazysquirrel.xfly.category.CategoryStats.run(CategoryStats.java:73) at java.lang.Thread.run(Thread.java:534) "directory cleaner" daemon prio=1 tid=0x0852dd30 nid=0x7d54 waiting on condition [4e15d000..4e15d854] at java.lang.Thread.sleep(Native Method) at com.crazysquirrel.xfly.web.DirectoryCleaner.run(DirectoryCleaner.java:80) at java.lang.Thread.run(Thread.java:534) "cat
Re: Getting Host information from within webapp
Kevin McAllister wrote: I am using tomcat 4.1.29, and would like to obtain the host name attribute from within my servlet code for the associated context in which I am running. I have finally found a solution that seems to work: Object dirContext = (Object)servlet.getServletContext().getAttribute("org.apache.catalina.resources"); Class dirContextClass = dirContext.getClass(); String host; try { Method hostMethod = dirContextClass.getMethod("getHostName",null); host = (String)hostMethod.invoke(dirContext,null); } catch (Exception e) { System.out.println("[Exception] Cannot retrieve hostname: " + e); } It is not a general solution that will work with any container obviously, as it relies on the org.apache.naming.resources.ProxyDirContext Method getHostName(). BTW in this snippet servlet is org.apache.struts.action.ActionServlet I am calling this from the init() method defined in the Interface org.apache.struts.action.PlugIn. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
AW: Tmcat 4.1.27 Access Logs. Switching on the the Access logs.
Hi Yoav Can I do this just for my context ? i.e. Not for the whole server? regards Ben -Ursprungliche Nachricht- Von: Shapira, Yoav [mailto:[EMAIL PROTECTED] Gesendet: Donnerstag, 10. Juni 2004 14:55 An: Tomcat Users List; [EMAIL PROTECTED] Betreff: RE: Tmcat 4.1.27 Access Logs. Switching on the the Access logs. Hi, In the server.xml file, comment the AccessLogValve element in or out as you need. Yoav Shapira Millennium Research Informatics >-Original Message- >From: Ben Bookey [mailto:[EMAIL PROTECTED] >Sent: Thursday, June 10, 2004 8:52 AM >To: Tomcat User List >Subject: Tmcat 4.1.27 Access Logs. Switching on the the Access logs. > >Dear List, > > In my NetBeans environment which has Tomcat integrated, I can find logs >which > show the individual requests for each HTML file. Where can I switch >this >on/off in my "real" > installation of Tomcat for just my application (i am sharing a tomcat >instance) with other apps.? > > I want to find any 404 File Not Found errors in my app. > >regards > >BEN > > >- >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]
Re: Help! Moving app from TC4->TC5, blank pages, no errors!
Absolutely, The application is definitely being deployed - as I said, the welcome-file loads just fine. Here's the STDOUT output, it matches exactly what I see locally. INFO: Processing Context configuration file URL file:D:\Tomcat-5.0\conf\Catalina\localhost\fiskars_PL.xml Successfully parsed and stored XML for: xmlGardeningTips2 Successfully parsed and stored XML for: xmlPhantomSearch Successfully parsed and stored XML for: xmlNGA Successfully parsed and stored XML for: xmlRecipes Successfully parsed and stored XML for: xmlValueAdd Successfully parsed and stored XML for: xmlCraftProjects Successfully parsed and stored XML for: xmlSocProjectSkus Successfully parsed and stored XML for: xmlSearchEngines Successfully parsed and stored XML for: xmldykGarden Successfully parsed and stored XML for: xmlhousewaresTips Successfully parsed and stored XML for: xmlHousePlants Successfully parsed and stored XML for: xmlRetailLocator Successfully parsed and stored XML for: xmlNav Successfully parsed and stored XML for: xmleTailer Successfully parsed and stored XML for: xmlLessonPlans Successfully parsed and stored XML for: xmlPressReleases Successfully parsed and stored XML for: xmlGlossary Successfully parsed and stored XML for: xmlGardeningTips Setting app variable for PROD [INFO] PropertyMessageResources - -Initializing, config='org.apache.struts.util.LocalStrings', returnNull=true [INFO] PropertyMessageResources - -Initializing, config='org.apache.struts.action.ActionResources', returnNull=true [INFO] PropertyMessageResources - -Initializing, config='resources.application', returnNull=true [INFO] ValidatorPlugIn - -Loading validation rules file from '/WEB-INF/validator-rules.xml' Jun 10, 2004 11:01:11 AM org.apache.commons.validator.ValidatorResources addValidatorAction INFO: Add ValidatorAction: required,org.apache.struts.util.StrutsValidator Jun 10, 2004 11:01:11 AM org.apache.commons.validator.ValidatorResources addValidatorAction INFO: Add ValidatorAction: minlength,org.apache.struts.util.StrutsValidator Jun 10, 2004 11:01:11 AM org.apache.commons.validator.ValidatorResources addValidatorAction INFO: Add ValidatorAction: maxlength,org.apache.struts.util.StrutsValidator Jun 10, 2004 11:01:11 AM org.apache.commons.validator.ValidatorResources addValidatorAction INFO: Add ValidatorAction: mask,org.apache.struts.util.StrutsValidator Jun 10, 2004 11:01:11 AM org.apache.commons.validator.ValidatorResources addValidatorAction INFO: Add ValidatorAction: byte,org.apache.struts.util.StrutsValidator Jun 10, 2004 11:01:11 AM org.apache.commons.validator.ValidatorResources addValidatorAction INFO: Add ValidatorAction: short,org.apache.struts.util.StrutsValidator Jun 10, 2004 11:01:11 AM org.apache.commons.validator.ValidatorResources addValidatorAction INFO: Add ValidatorAction: integer,org.apache.struts.util.StrutsValidator Jun 10, 2004 11:01:11 AM org.apache.commons.validator.ValidatorResources addValidatorAction INFO: Add ValidatorAction: long,org.apache.struts.util.StrutsValidator Jun 10, 2004 11:01:11 AM org.apache.commons.validator.ValidatorResources addValidatorAction INFO: Add ValidatorAction: float,org.apache.struts.util.StrutsValidator Jun 10, 2004 11:01:11 AM org.apache.commons.validator.ValidatorResources addValidatorAction INFO: Add ValidatorAction: double,org.apache.struts.util.StrutsValidator Jun 10, 2004 11:01:11 AM org.apache.commons.validator.ValidatorResources addValidatorAction INFO: Add ValidatorAction: date,org.apache.struts.util.StrutsValidator Jun 10, 2004 11:01:11 AM org.apache.commons.validator.ValidatorResources addValidatorAction INFO: Add ValidatorAction: range,org.apache.struts.util.StrutsValidator Jun 10, 2004 11:01:11 AM org.apache.commons.validator.ValidatorResources addValidatorAction INFO: Add ValidatorAction: creditCard,org.apache.struts.util.StrutsValidator Jun 10, 2004 11:01:11 AM org.apache.commons.validator.ValidatorResources addValidatorAction INFO: Add ValidatorAction: email,org.apache.struts.util.StrutsValidator Jun 10, 2004 11:01:11 AM org.apache.commons.validator.ValidatorResources addValidatorAction INFO: Add ValidatorAction: dateTwoDigitYr,org.apache.struts.util.StrutsValidator [INFO] ValidatorPlugIn - -Loading validation rules file from '/WEB-INF/validation.xml' Jun 10, 2004 11:01:11 AM org.apache.commons.validator.ValidatorResources addConstantParam INFO: Add Global Constant: zip,^\d{5}(-\d{4})?$ Jun 10, 2004 11:01:11 AM org.apache.commons.validator.ValidatorResources addConstantParam INFO: Add Global Constant: defaultDate,MM/dd/yy Jun 10, 2004 11:01:11 AM org.apache.commons.validator.ValidatorResources addConstantParam INFO: Add Global Constant: states48,^(AL|AS|AZ|AR|CA|CO|CT|DE|DC|FM|FL|GA|GU|ID|IL|IN|IA|KS|KY|LA|ME|MH|MD|MA|MI|MN|MS|MO|MT|NE|NV|NH|NJ|NM|NY|NC|ND|MP|OH|OK|OR|PW|PA|PR|RI|SC|SD|TN|TX|UT|VT|VI|VA|WA|WV|WI|WY)$ Jun 10, 2004 11:01:11 AM org.apache.commons.validator.ValidatorResources put INFO: Adding FormSet 'FormSet: language=null
Re: Help! Moving app from TC4->TC5, blank pages, no errors!
Absolutely Shapira, Yoav wrote: Hi, How strange... Is the behavior consistent across browsers, e.g. if you try IE or Opera? Yoav Shapira Millennium Research Informatics -Original Message- From: Ruth, Brice [mailto:[EMAIL PROTECTED] Sent: Thursday, June 10, 2004 11:52 AM To: Tomcat Users List Subject: Re: Help! Moving app from TC4->TC5, blank pages, no errors! The Access Log valve indicates that the error being generated is 404 ... I still get a blank screen with no errors in the browser, and no errors in Tomcat's logs. Here's the particular Access Log entry: 10.5.201.20 - - [10/Jun/2004:10:49:23 -0600] "GET /fiskars_PL/pl_PL/index.do HTTP/1.1" 404 - "-" "Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.6) Gecko/20040206 Firefox/0.8" You'll notice that the request is a Struts Action ... what's going on here?!?!?!? This application runs on TC5 just fine locally, same version of TC5 ... why won't it run on the deployment server?!?! Shapira, Yoav wrote: Hi, So you're using TC-specific code in your webapp? (Hence the need for different build files, one for TC4 and one for TC5, I imagine). Add logging output statements to your various filters so you can tell what they're doing, if anything. Enable the AccessLogValve to see if you're really getting 404s or something else (such as previous 5xx errors) are preventing normal processing. Yoav Shapira Millennium Research Informatics -Original Message- From: Ruth, Brice [mailto:[EMAIL PROTECTED] Sent: Thursday, June 10, 2004 10:58 AM To: Tomcat Users List Subject: Help! Moving app from TC4->TC5, blank pages, no errors! I'm in the process of taking an application that we've been deploying to our production/stage/dev servers running TC4.1 to deploying it on our dev server running TC5.0.18. On our local development workstations, we've been deploying to TC5 for quite a while now, with no problems ... I'm not sure what the problem is deploying the web-app to TC5, but the most confusing thing is that I'm not getting any errors!!! The 'welcome-file' for the application loads, and nothing else loads! I can even put in a total garbage URL for that particular context and I don't even get a 404 error or anything! The web-app is pretty complex, with 5 or 6 filters chained together, so anywhere in there, something may be happening to a request, but shouldn't I be getting exceptions on STDOUT/STDERR?! I get nothing, not in stdout.log nor stderr.log, nor localhost_log.2004-06-10.txt. When the web-app starts, it outputs some status information as it goes through its bootstrapping (some custom messages, some Tiles messages, some Validator messages) - and that all looks perfectly normal. I also have a Logger element in my context, and the log file specified never gets created. Not sure why that would be, either. This is on a Win2K Server, with JDK1.4.2. I believe I'm running with the "stock" server.xml, I've installed my context in conf/Catalina/localhost as well as simply putting it in the META-INF directory of my exploded WAR. I've tried loading from a packaged WAR as well as an exploded WAR ... no luck! The web-application is built using Ant and I've spent a good bit of time developing our build process, so I'm fairly confident that its working OK - I've used two different build files, one that builds the application against TC4 APIs, the other uses the new TC5 APIs. I'm about at my wits end here ... I can't figure out what's going on!! Especially without any errors or log output!! Respectfully, Brice Ruth - 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] - 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
Re: Help! Moving app from TC4->TC5, blank pages, no errors!
did the context even get deployed? ie, do you have some system.out statements in your servlets when they get loaded that could tell you more info Filip - Original Message - From: "Shapira, Yoav" <[EMAIL PROTECTED]> To: "Tomcat Users List" <[EMAIL PROTECTED]> Sent: Thursday, June 10, 2004 10:54 AM Subject: RE: Help! Moving app from TC4->TC5, blank pages, no errors! > > Hi, > How strange... Is the behavior consistent across browsers, e.g. if you > try IE or Opera? > > Yoav Shapira > Millennium Research Informatics > > > >-Original Message- > >From: Ruth, Brice [mailto:[EMAIL PROTECTED] > >Sent: Thursday, June 10, 2004 11:52 AM > >To: Tomcat Users List > >Subject: Re: Help! Moving app from TC4->TC5, blank pages, no errors! > > > >The Access Log valve indicates that the error being generated is 404 > ... > > > >I still get a blank screen with no errors in the browser, and no errors > >in Tomcat's logs. Here's the particular Access Log entry: > > > >10.5.201.20 - - [10/Jun/2004:10:49:23 -0600] "GET > >/fiskars_PL/pl_PL/index.do HTTP/1.1" 404 - "-" "Mozilla/5.0 (Windows; > U; > >Windows NT 5.1; en-US; rv:1.6) Gecko/20040206 Firefox/0.8" > > > >You'll notice that the request is a Struts Action ... what's going on > >here?!?!?!? This application runs on TC5 just fine locally, same > version > >of TC5 ... why won't it run on the deployment server?!?! > > > >Shapira, Yoav wrote: > > > >>Hi, > >>So you're using TC-specific code in your webapp? (Hence the need for > >>different build files, one for TC4 and one for TC5, I imagine). > >> > >>Add logging output statements to your various filters so you can tell > >>what they're doing, if anything. > >> > >>Enable the AccessLogValve to see if you're really getting 404s or > >>something else (such as previous 5xx errors) are preventing normal > >>processing. > >> > >>Yoav Shapira > >>Millennium Research Informatics > >> > >> > >> > >> > >>>-Original Message- > >>>From: Ruth, Brice [mailto:[EMAIL PROTECTED] > >>>Sent: Thursday, June 10, 2004 10:58 AM > >>>To: Tomcat Users List > >>>Subject: Help! Moving app from TC4->TC5, blank pages, no errors! > >>> > >>>I'm in the process of taking an application that we've been deploying > >>> > >>> > >>to > >> > >> > >>>our production/stage/dev servers running TC4.1 to deploying it on our > >>>dev server running TC5.0.18. On our local development workstations, > >>>we've been deploying to TC5 for quite a while now, with no problems > ... > >>>I'm not sure what the problem is deploying the web-app to TC5, but > the > >>>most confusing thing is that I'm not getting any errors!!! > >>> > >>>The 'welcome-file' for the application loads, and nothing else loads! > I > >>>can even put in a total garbage URL for that particular context and I > >>>don't even get a 404 error or anything! The web-app is pretty > complex, > >>>with 5 or 6 filters chained together, so anywhere in there, something > >>>may be happening to a request, but shouldn't I be getting exceptions > on > >>>STDOUT/STDERR?! I get nothing, not in stdout.log nor stderr.log, nor > >>>localhost_log.2004-06-10.txt. > >>> > >>>When the web-app starts, it outputs some status information as it > goes > >>>through its bootstrapping (some custom messages, some Tiles messages, > >>>some Validator messages) - and that all looks perfectly normal. > >>> > >>>I also have a Logger element in my context, and the log file > specified > >>>never gets created. Not sure why that would be, either. > >>> > >>>This is on a Win2K Server, with JDK1.4.2. I believe I'm running with > >>> > >>> > >>the > >> > >> > >>>"stock" server.xml, I've installed my context in > >>> > >>> > >>conf/Catalina/localhost > >> > >> > >>>as well as simply putting it in the META-INF directory of my exploded > >>>WAR. I've tried loading from a packaged WAR as well as an exploded > WAR > >>>... no luck! > >>> > >>>The web-application is built using Ant and I've spent a good bit of > >>> > >>> > >>time > >> > >> > >>>developing our build process, so I'm fairly confident that its > working > >>>OK - I've used two different build files, one that builds the > >>>application against TC4 APIs, the other uses the new TC5 APIs. > >>> > >>>I'm about at my wits end here ... I can't figure out what's going > on!! > >>>Especially without any errors or log output!! > >>> > >>>Respectfully, > >>>Brice Ruth > >>> > >>>- > >>>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 delet
RE: Help! Moving app from TC4->TC5, blank pages, no errors!
Hi, How strange... Is the behavior consistent across browsers, e.g. if you try IE or Opera? Yoav Shapira Millennium Research Informatics >-Original Message- >From: Ruth, Brice [mailto:[EMAIL PROTECTED] >Sent: Thursday, June 10, 2004 11:52 AM >To: Tomcat Users List >Subject: Re: Help! Moving app from TC4->TC5, blank pages, no errors! > >The Access Log valve indicates that the error being generated is 404 ... > >I still get a blank screen with no errors in the browser, and no errors >in Tomcat's logs. Here's the particular Access Log entry: > >10.5.201.20 - - [10/Jun/2004:10:49:23 -0600] "GET >/fiskars_PL/pl_PL/index.do HTTP/1.1" 404 - "-" "Mozilla/5.0 (Windows; U; >Windows NT 5.1; en-US; rv:1.6) Gecko/20040206 Firefox/0.8" > >You'll notice that the request is a Struts Action ... what's going on >here?!?!?!? This application runs on TC5 just fine locally, same version >of TC5 ... why won't it run on the deployment server?!?! > >Shapira, Yoav wrote: > >>Hi, >>So you're using TC-specific code in your webapp? (Hence the need for >>different build files, one for TC4 and one for TC5, I imagine). >> >>Add logging output statements to your various filters so you can tell >>what they're doing, if anything. >> >>Enable the AccessLogValve to see if you're really getting 404s or >>something else (such as previous 5xx errors) are preventing normal >>processing. >> >>Yoav Shapira >>Millennium Research Informatics >> >> >> >> >>>-Original Message- >>>From: Ruth, Brice [mailto:[EMAIL PROTECTED] >>>Sent: Thursday, June 10, 2004 10:58 AM >>>To: Tomcat Users List >>>Subject: Help! Moving app from TC4->TC5, blank pages, no errors! >>> >>>I'm in the process of taking an application that we've been deploying >>> >>> >>to >> >> >>>our production/stage/dev servers running TC4.1 to deploying it on our >>>dev server running TC5.0.18. On our local development workstations, >>>we've been deploying to TC5 for quite a while now, with no problems ... >>>I'm not sure what the problem is deploying the web-app to TC5, but the >>>most confusing thing is that I'm not getting any errors!!! >>> >>>The 'welcome-file' for the application loads, and nothing else loads! I >>>can even put in a total garbage URL for that particular context and I >>>don't even get a 404 error or anything! The web-app is pretty complex, >>>with 5 or 6 filters chained together, so anywhere in there, something >>>may be happening to a request, but shouldn't I be getting exceptions on >>>STDOUT/STDERR?! I get nothing, not in stdout.log nor stderr.log, nor >>>localhost_log.2004-06-10.txt. >>> >>>When the web-app starts, it outputs some status information as it goes >>>through its bootstrapping (some custom messages, some Tiles messages, >>>some Validator messages) - and that all looks perfectly normal. >>> >>>I also have a Logger element in my context, and the log file specified >>>never gets created. Not sure why that would be, either. >>> >>>This is on a Win2K Server, with JDK1.4.2. I believe I'm running with >>> >>> >>the >> >> >>>"stock" server.xml, I've installed my context in >>> >>> >>conf/Catalina/localhost >> >> >>>as well as simply putting it in the META-INF directory of my exploded >>>WAR. I've tried loading from a packaged WAR as well as an exploded WAR >>>... no luck! >>> >>>The web-application is built using Ant and I've spent a good bit of >>> >>> >>time >> >> >>>developing our build process, so I'm fairly confident that its working >>>OK - I've used two different build files, one that builds the >>>application against TC4 APIs, the other uses the new TC5 APIs. >>> >>>I'm about at my wits end here ... I can't figure out what's going on!! >>>Especially without any errors or log output!! >>> >>>Respectfully, >>>Brice Ruth >>> >>>- >>>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] >> >> >> > >- >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
Re: Help! Moving app from TC4->TC5, blank pages, no errors!
The Access Log valve indicates that the error being generated is 404 ... I still get a blank screen with no errors in the browser, and no errors in Tomcat's logs. Here's the particular Access Log entry: 10.5.201.20 - - [10/Jun/2004:10:49:23 -0600] "GET /fiskars_PL/pl_PL/index.do HTTP/1.1" 404 - "-" "Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.6) Gecko/20040206 Firefox/0.8" You'll notice that the request is a Struts Action ... what's going on here?!?!?!? This application runs on TC5 just fine locally, same version of TC5 ... why won't it run on the deployment server?!?! Shapira, Yoav wrote: Hi, So you're using TC-specific code in your webapp? (Hence the need for different build files, one for TC4 and one for TC5, I imagine). Add logging output statements to your various filters so you can tell what they're doing, if anything. Enable the AccessLogValve to see if you're really getting 404s or something else (such as previous 5xx errors) are preventing normal processing. Yoav Shapira Millennium Research Informatics -Original Message- From: Ruth, Brice [mailto:[EMAIL PROTECTED] Sent: Thursday, June 10, 2004 10:58 AM To: Tomcat Users List Subject: Help! Moving app from TC4->TC5, blank pages, no errors! I'm in the process of taking an application that we've been deploying to our production/stage/dev servers running TC4.1 to deploying it on our dev server running TC5.0.18. On our local development workstations, we've been deploying to TC5 for quite a while now, with no problems ... I'm not sure what the problem is deploying the web-app to TC5, but the most confusing thing is that I'm not getting any errors!!! The 'welcome-file' for the application loads, and nothing else loads! I can even put in a total garbage URL for that particular context and I don't even get a 404 error or anything! The web-app is pretty complex, with 5 or 6 filters chained together, so anywhere in there, something may be happening to a request, but shouldn't I be getting exceptions on STDOUT/STDERR?! I get nothing, not in stdout.log nor stderr.log, nor localhost_log.2004-06-10.txt. When the web-app starts, it outputs some status information as it goes through its bootstrapping (some custom messages, some Tiles messages, some Validator messages) - and that all looks perfectly normal. I also have a Logger element in my context, and the log file specified never gets created. Not sure why that would be, either. This is on a Win2K Server, with JDK1.4.2. I believe I'm running with the "stock" server.xml, I've installed my context in conf/Catalina/localhost as well as simply putting it in the META-INF directory of my exploded WAR. I've tried loading from a packaged WAR as well as an exploded WAR ... no luck! The web-application is built using Ant and I've spent a good bit of time developing our build process, so I'm fairly confident that its working OK - I've used two different build files, one that builds the application against TC4 APIs, the other uses the new TC5 APIs. I'm about at my wits end here ... I can't figure out what's going on!! Especially without any errors or log output!! Respectfully, Brice Ruth - 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] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Re: [Resource Not available] Newbie question
Hi, >Thats the servlet-mapping. > > AVG_ValuesServlet > org/haw/weather/web/AVG_ValuesServlet > >I've tried the pattern /AVG_ValuesServlet also, but it doesn't work. What happened? The latter is a much better mapping. >The index.html is in the root of the application(in the parent-directory >of the Web-inf directory). Case matters: it should be WEB-INF and not Web-inf. Yoav Shapira 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]
Re: Re: [Resource Not available] Newbie question
Thats the servlet-mapping. AVG_ValuesServlet org/haw/weather/web/AVG_ValuesServlet I've tried the pattern /AVG_ValuesServlet also, but it doesn't work. The index.html is in the root of the application(in the parent-directory of the Web-inf directory). You would also need to tell us your servlet-mapping and the directory of the file that the form is in. Tim if I try to access the below described servlet from a html- or jsp-file I get "Http 404 Error - Resource not available". .. I have tried it with the package-name as prefix and the prefix "servlet/", but nothing works. Whats wrong? The class-file is located in the defined directory under ../web-inf/classes. This is the only element of web.xml: AVG_ValuesServlet org.haw.weather.web.AVG_ValuesServlet Thanks in advance, Michael - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
A wired problem
Hi all, I have a jsp page which gets form data and does update or insert these data into database depending on the button type. But the wired thing is that during run time code was chopped into pieces and each piece was done twice. Then it looks like the whole jsp page was run twice. Does anyone have this problem before? What is the cause? Thanks in advance. Hong - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: What is the latest version of Tomcat ?
Hola, Really? What problems does 5.0.25 have? Please substantiate such broad claims... 5.0.24 is not recommended for production use because of the cookie bug: if you want to use it, add the hotfix. Yoav Shapira Millennium Research Informatics >-Original Message- >From: Michael Mehrle [mailto:[EMAIL PROTECTED] >Sent: Thursday, June 10, 2004 11:19 AM >To: Tomcat Users List; [EMAIL PROTECTED] >Subject: Re: What is the latest version of Tomcat ? > >I'm using 5.0.26 but not in production. Stay away from 5.0.25 - it's got >problems... > >Michael > >- Original Message - >From: "Ben Bookey" <[EMAIL PROTECTED]> >To: "Tomcat User List" <[EMAIL PROTECTED]> >Sent: Thursday, June 10, 2004 8:17 AM >Subject: What is the latest version of Tomcat ? > > >> Dear List, >> >> On 9th May 2004 - Tomcat 5.0.24 Stable was released. >> >> Which version would you all recomend for a critical commercial product ? >> >> regards >> >> Ben >> >> - >> To unsubscribe, e-mail: [EMAIL PROTECTED] >> For additional commands, e-mail: [EMAIL PROTECTED] >> > > >- >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]
Re: What is the latest version of Tomcat ?
Hi, What are the problems you are experiencing with 5.0.25? Ta Matt On Thu, 2004-06-10 at 16:19, Michael Mehrle wrote: > I'm using 5.0.26 but not in production. Stay away from 5.0.25 - it's got > problems... > > Michael > > - Original Message - > From: "Ben Bookey" <[EMAIL PROTECTED]> > To: "Tomcat User List" <[EMAIL PROTECTED]> > Sent: Thursday, June 10, 2004 8:17 AM > Subject: What is the latest version of Tomcat ? > > > > Dear List, > > > > On 9th May 2004 - Tomcat 5.0.24 Stable was released. > > > > Which version would you all recomend for a critical commercial product ? > > > > regards > > > > Ben > > > > - > > To unsubscribe, e-mail: [EMAIL PROTECTED] > > For additional commands, e-mail: [EMAIL PROTECTED] > > > > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: What is the latest version of Tomcat ?
5.0.25 is now released as stable and I've not had any problems with it. Ta Matt On Thu, 2004-06-10 at 16:17, Ben Bookey wrote: > Dear List, > > On 9th May 2004 - Tomcat 5.0.24 Stable was released. > > Which version would you all recomend for a critical commercial product > ? > > regards > > Ben > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: What is the latest version of Tomcat ?
Hi, What are the problems that you are experiencing with 5.0.25? Ta Matt On Thu, 2004-06-10 at 16:19, Michael Mehrle wrote: > I'm using 5.0.26 but not in production. Stay away from 5.0.25 - it's got > problems... > > Michael > > - Original Message - > From: "Ben Bookey" <[EMAIL PROTECTED]> > To: "Tomcat User List" <[EMAIL PROTECTED]> > Sent: Thursday, June 10, 2004 8:17 AM > Subject: What is the latest version of Tomcat ? > > > > Dear List, > > > > On 9th May 2004 - Tomcat 5.0.24 Stable was released. > > > > Which version would you all recomend for a critical commercial product ? > > > > regards > > > > Ben > > > > - > > To unsubscribe, e-mail: [EMAIL PROTECTED] > > For additional commands, e-mail: [EMAIL PROTECTED] > > > > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: What is the latest version of Tomcat ?
As a general rule of thumb, you should go with the stable release and not any alpha or beta version, for production jobs. I am still using version 4.1.24 and I am very happy with it. Version 5 should be very stable by now. You should go to the Jakarta site to find out what is the latest stable release. Hope this helps. -Original Message- From: Ben Bookey [mailto:[EMAIL PROTECTED] Sent: Thursday, June 10, 2004 10:17 AM To: Tomcat User List Subject: What is the latest version of Tomcat ? Dear List, On 9th May 2004 - Tomcat 5.0.24 Stable was released. Which version would you all recomend for a critical commercial product ? regards Ben - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Denial Service Attack Prevention apache-tomcat modjk2
Shapira, Yoav wrote: Hi, You can use JavaScript to disable form elements, thereby graying them out and preventing the user from clicking again. Yoav Shapira Millennium Research Informatics -Original Message- From: Steve [mailto:[EMAIL PROTECTED] Sent: Thursday, June 10, 2004 10:52 AM To: Tomcat Users List Subject: Denial Service Attack Prevention apache-tomcat modjk2 Looking for a solution to prevent a user from click multiply times on a function in which the application is still performing from the first click. The user thinkgs the app is not responding where in fact it is, then causing the app to take a dump from multiply request. Using cisco css LB into --> Apache, mod_jk2 into tomcat 4.1.29 any tips or pointers greatly appr -s - 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] Replying on top of Yoav's because I don't have the other message. If it is a large enough operation your could do something like this: //check if running String methodName = "com.mypackage.MyClass.myMethod"; //pull value from session test and add if needed. Boolean isRunning = (Boolean)session.getAttribute(methodName); if( isRunning != null && isRunning.booleanValue() ) { //hand off to other method that tells them to please wait. } else { //first let app know user is doing task. session.setAttribute(methodName, new Boolean(true)); //perform that large task try { //do work that might jump out here... } catch(Throwable e) { } finally { //ok, it's done...remove from session. session.removeAttribute(methodName); } }//end else Now the large task can't eat up your cpu more than you let it because it only runs once per user at a time. Sleeping the thread a little after so many iterations in loops also will help your entire server and application. After maybe every 1000 iterations sleep for a couple of millis. Play with that sometimes it helps sometimes not. It spreads out the load over time a bit and allows the computer to service more users, it just takes longer... Hope that helps you some. Wade - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: What is the latest version of Tomcat ?
I'm using 5.0.26 but not in production. Stay away from 5.0.25 - it's got problems... Michael - Original Message - From: "Ben Bookey" <[EMAIL PROTECTED]> To: "Tomcat User List" <[EMAIL PROTECTED]> Sent: Thursday, June 10, 2004 8:17 AM Subject: What is the latest version of Tomcat ? > Dear List, > > On 9th May 2004 - Tomcat 5.0.24 Stable was released. > > Which version would you all recomend for a critical commercial product ? > > regards > > Ben > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Help! Moving app from TC4->TC5, blank pages, no errors!
I'm not really using TC specific code, to my knowledge ... its just that TC4 had a 'servlet.jar' and TC5 has a 'servlet-apis.jar' and a 'jsp-apis.jar' ... so the build file has to account for the difference, otherwise, there really isn't any difference. I'll configure the AccessLogValve and see if I actually get any output (I'm not getting anything from my Logger!) Shapira, Yoav wrote: Hi, So you're using TC-specific code in your webapp? (Hence the need for different build files, one for TC4 and one for TC5, I imagine). Add logging output statements to your various filters so you can tell what they're doing, if anything. Enable the AccessLogValve to see if you're really getting 404s or something else (such as previous 5xx errors) are preventing normal processing. Yoav Shapira Millennium Research Informatics -Original Message- From: Ruth, Brice [mailto:[EMAIL PROTECTED] Sent: Thursday, June 10, 2004 10:58 AM To: Tomcat Users List Subject: Help! Moving app from TC4->TC5, blank pages, no errors! I'm in the process of taking an application that we've been deploying to our production/stage/dev servers running TC4.1 to deploying it on our dev server running TC5.0.18. On our local development workstations, we've been deploying to TC5 for quite a while now, with no problems ... I'm not sure what the problem is deploying the web-app to TC5, but the most confusing thing is that I'm not getting any errors!!! The 'welcome-file' for the application loads, and nothing else loads! I can even put in a total garbage URL for that particular context and I don't even get a 404 error or anything! The web-app is pretty complex, with 5 or 6 filters chained together, so anywhere in there, something may be happening to a request, but shouldn't I be getting exceptions on STDOUT/STDERR?! I get nothing, not in stdout.log nor stderr.log, nor localhost_log.2004-06-10.txt. When the web-app starts, it outputs some status information as it goes through its bootstrapping (some custom messages, some Tiles messages, some Validator messages) - and that all looks perfectly normal. I also have a Logger element in my context, and the log file specified never gets created. Not sure why that would be, either. This is on a Win2K Server, with JDK1.4.2. I believe I'm running with the "stock" server.xml, I've installed my context in conf/Catalina/localhost as well as simply putting it in the META-INF directory of my exploded WAR. I've tried loading from a packaged WAR as well as an exploded WAR ... no luck! The web-application is built using Ant and I've spent a good bit of time developing our build process, so I'm fairly confident that its working OK - I've used two different build files, one that builds the application against TC4 APIs, the other uses the new TC5 APIs. I'm about at my wits end here ... I can't figure out what's going on!! Especially without any errors or log output!! Respectfully, Brice Ruth - 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] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
What is the latest version of Tomcat ?
Dear List, On 9th May 2004 - Tomcat 5.0.24 Stable was released. Which version would you all recomend for a critical commercial product ? regards Ben - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Help! Moving app from TC4->TC5, blank pages, no errors!
Hi, So you're using TC-specific code in your webapp? (Hence the need for different build files, one for TC4 and one for TC5, I imagine). Add logging output statements to your various filters so you can tell what they're doing, if anything. Enable the AccessLogValve to see if you're really getting 404s or something else (such as previous 5xx errors) are preventing normal processing. Yoav Shapira Millennium Research Informatics >-Original Message- >From: Ruth, Brice [mailto:[EMAIL PROTECTED] >Sent: Thursday, June 10, 2004 10:58 AM >To: Tomcat Users List >Subject: Help! Moving app from TC4->TC5, blank pages, no errors! > >I'm in the process of taking an application that we've been deploying to >our production/stage/dev servers running TC4.1 to deploying it on our >dev server running TC5.0.18. On our local development workstations, >we've been deploying to TC5 for quite a while now, with no problems ... >I'm not sure what the problem is deploying the web-app to TC5, but the >most confusing thing is that I'm not getting any errors!!! > >The 'welcome-file' for the application loads, and nothing else loads! I >can even put in a total garbage URL for that particular context and I >don't even get a 404 error or anything! The web-app is pretty complex, >with 5 or 6 filters chained together, so anywhere in there, something >may be happening to a request, but shouldn't I be getting exceptions on >STDOUT/STDERR?! I get nothing, not in stdout.log nor stderr.log, nor >localhost_log.2004-06-10.txt. > >When the web-app starts, it outputs some status information as it goes >through its bootstrapping (some custom messages, some Tiles messages, >some Validator messages) - and that all looks perfectly normal. > >I also have a Logger element in my context, and the log file specified >never gets created. Not sure why that would be, either. > >This is on a Win2K Server, with JDK1.4.2. I believe I'm running with the >"stock" server.xml, I've installed my context in conf/Catalina/localhost >as well as simply putting it in the META-INF directory of my exploded >WAR. I've tried loading from a packaged WAR as well as an exploded WAR >... no luck! > >The web-application is built using Ant and I've spent a good bit of time >developing our build process, so I'm fairly confident that its working >OK - I've used two different build files, one that builds the >application against TC4 APIs, the other uses the new TC5 APIs. > >I'm about at my wits end here ... I can't figure out what's going on!! >Especially without any errors or log output!! > >Respectfully, >Brice Ruth > >- >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]
Using Tomcat's HTTP processor and SSL
I am considering using Tomcat alone as my HTTP server as well as my servlet container with SSL. I know a lot of people use Apache HTTP Server instead of Tomcat for this and Tomcat is just the servlet container only. Is there any reason why I should not use just Tomcat alone for this. I'm actually using JBOSS with Tomcat, but Tomcat still handles the HTTP requests. I have no static pages on my site. Seems like a hassle to configure a separate server (Apache HTTP) when I don't have to. Also, are there any difficulties configuring Tomcat with SSL? Thanks for any help or suggestions. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Denial Service Attack Prevention apache-tomcat modjk2
And server side you can use a token match from a form hidden element and session attribute. -Original Message- From: Shapira, Yoav [mailto:[EMAIL PROTECTED] Sent: Thursday, June 10, 2004 7:56 AM To: Tomcat Users List Subject: RE: Denial Service Attack Prevention apache-tomcat modjk2 Hi, You can use JavaScript to disable form elements, thereby graying them out and preventing the user from clicking again. Yoav Shapira Millennium Research Informatics >-Original Message- >From: Steve [mailto:[EMAIL PROTECTED] >Sent: Thursday, June 10, 2004 10:52 AM >To: Tomcat Users List >Subject: Denial Service Attack Prevention apache-tomcat modjk2 > >Looking for a solution to prevent a user from click multiply times on a >function in which the application is still performing from the first click. > >The user thinkgs the app is not responding where in fact it is, then >causing the app to take a dump from multiply request. > >Using cisco css LB into --> Apache, mod_jk2 into tomcat 4.1.29 > >any tips or pointers greatly appr > >-s > > > >- >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] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Help! Moving app from TC4->TC5, blank pages, no errors!
I'm in the process of taking an application that we've been deploying to our production/stage/dev servers running TC4.1 to deploying it on our dev server running TC5.0.18. On our local development workstations, we've been deploying to TC5 for quite a while now, with no problems ... I'm not sure what the problem is deploying the web-app to TC5, but the most confusing thing is that I'm not getting any errors!!! The 'welcome-file' for the application loads, and nothing else loads! I can even put in a total garbage URL for that particular context and I don't even get a 404 error or anything! The web-app is pretty complex, with 5 or 6 filters chained together, so anywhere in there, something may be happening to a request, but shouldn't I be getting exceptions on STDOUT/STDERR?! I get nothing, not in stdout.log nor stderr.log, nor localhost_log.2004-06-10.txt. When the web-app starts, it outputs some status information as it goes through its bootstrapping (some custom messages, some Tiles messages, some Validator messages) - and that all looks perfectly normal. I also have a Logger element in my context, and the log file specified never gets created. Not sure why that would be, either. This is on a Win2K Server, with JDK1.4.2. I believe I'm running with the "stock" server.xml, I've installed my context in conf/Catalina/localhost as well as simply putting it in the META-INF directory of my exploded WAR. I've tried loading from a packaged WAR as well as an exploded WAR ... no luck! The web-application is built using Ant and I've spent a good bit of time developing our build process, so I'm fairly confident that its working OK - I've used two different build files, one that builds the application against TC4 APIs, the other uses the new TC5 APIs. I'm about at my wits end here ... I can't figure out what's going on!! Especially without any errors or log output!! Respectfully, Brice Ruth - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Denial Service Attack Prevention apache-tomcat modjk2
Hi, You can use JavaScript to disable form elements, thereby graying them out and preventing the user from clicking again. Yoav Shapira Millennium Research Informatics >-Original Message- >From: Steve [mailto:[EMAIL PROTECTED] >Sent: Thursday, June 10, 2004 10:52 AM >To: Tomcat Users List >Subject: Denial Service Attack Prevention apache-tomcat modjk2 > >Looking for a solution to prevent a user from click multiply times on a >function in which the application is still performing from the first click. > >The user thinkgs the app is not responding where in fact it is, then >causing the app to take a dump from multiply request. > >Using cisco css LB into --> Apache, mod_jk2 into tomcat 4.1.29 > >any tips or pointers greatly appr > >-s > > > >- >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]
Denial Service Attack Prevention apache-tomcat modjk2
Looking for a solution to prevent a user from click multiply times on a function in which the application is still performing from the first click. The user thinkgs the app is not responding where in fact it is, then causing the app to take a dump from multiply request. Using cisco css LB into --> Apache, mod_jk2 into tomcat 4.1.29 any tips or pointers greatly appr -s - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: jk_nt_service.exe
You are welcome! Carl -Original Message- From: Ben Souther [mailto:[EMAIL PROTECTED] Sent: 10 June 2004 04:20 PM To: Tomcat Users List Subject: Re: jk_nt_service.exe Thank you, Carl. It's working. On Wednesday 09 June 2004 10:33 am, Carl Olivier wrote: > Hey. > > I think you should check: > http://www.alexandriasc.com/software/JavaService/index.html > > Regards, > > Carl > > > > -Original Message- > From: Ben Souther [mailto:[EMAIL PROTECTED] > Sent: 09 June 2004 04:27 PM > To: Tomcat Users List > Subject: jk_nt_service.exe > > > > Is jk_nt_service still available? > Does it work with tomcat 5x? > > The installer that ships with Tomcat doesn't allow for multiple > instances of > > tomcat as windows services and the service.bat script seems not to be > working. > > Has anyone else been able to install multiple instances of tomcat on a > windows box as NT Services? > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] -- Ben Souther F.W. Davison & Company, Inc. This e-mail message, and any accompanying documents, is for the sole use of the intended recipient(s) and may contain confidential and privileged information. Any unauthorized review, use, disclosure, distribution or copying is prohibited. If you are not the intended recipient, please contact our office by email or by telephone at (508) 747-7261 and immediately destroy all copies of the original message. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: jk_nt_service.exe
Thank you, Carl. It's working. On Wednesday 09 June 2004 10:33 am, Carl Olivier wrote: > Hey. > > I think you should check: > http://www.alexandriasc.com/software/JavaService/index.html > > Regards, > > Carl > > > > -Original Message- > From: Ben Souther [mailto:[EMAIL PROTECTED] > Sent: 09 June 2004 04:27 PM > To: Tomcat Users List > Subject: jk_nt_service.exe > > > > Is jk_nt_service still available? > Does it work with tomcat 5x? > > The installer that ships with Tomcat doesn't allow for multiple instances > of > > tomcat as windows services and the service.bat script seems not to be > working. > > Has anyone else been able to install multiple instances of tomcat on a > windows > box as NT Services? > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] -- Ben Souther F.W. Davison & Company, Inc. This e-mail message, and any accompanying documents, is for the sole use of the intended recipient(s) and may contain confidential and privileged information. Any unauthorized review, use, disclosure, distribution or copying is prohibited. If you are not the intended recipient, please contact our office by email or by telephone at (508) 747-7261 and immediately destroy all copies of the original message. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Getting Host information from within webapp
Kevin McAllister wrote: I am using tomcat 4.1.29, and would like to obtain the host name attribute from within my servlet code for the associated context in which I am running. I think I would be able to retrieve this information utilizing the JMX stuff Upon doing some further research I found I would be able to get a host name given a context as long as my webapp was privileged (so the org.apache.catalina.mbean.ServerLifecycleListener would place a reference to the MBeanServer in the ServletContext attributes) However, it seems the only information I would have to Query the MBeanServer is the context path, And if I have more than one context path which is the same (on different Hosts obviously) then I would not be able to uniquely Identify the Host to which I am bound. And since I will most certainly have many Hosts each with the same context path for my webapp, this method will not work for my purposes. Hopefully the information is available somewhere else, or otherwise I may be able to obtain it by inserting another ServerLifeCycleListener that can gather the information from the context adding event and put it on the ServletContext attributes. - Kevin - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: UserTransaction class not found in TC 5.0.25
Hi, >I am not sure what you mean. I tried the 2 URLs below but neither were >available. Really? They still work fine for me. >Do you mean it is prohibited to have the j2ee.jar file in the WEB-INF/lib >directory of the application? Yup. It's prohibited to have any J2EE APIs that tomcat already bundles, such as the Servlet and JSP classes. If you want other APIs, you have to include only them, usually by including their individual jars, in your case the JTA jar. >I did a recursive search for the string "UserTransaction" in the TC 5.0.25 >dir tree ad could not find a jar that included it. It's not bundled in Tomcat: download jta.jar and put that in WEB-INF/lib. Yoav Shapira 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]
RE: UserTransaction class not found in TC 5.0.25
Yoav, I am not sure what you mean. I tried the 2 URLs below but neither were available. Sorry if I was sketchy about the app: I have a J2EE/Struts app developed within JBuilder X. It runs fine in the JBuilder/Tomcat 4.0 test environment. However when it runs within TC 5.0.25 it produces the error. I deployed it to TC 5 via the TC manager page, choosing the "deploy WAR" functionality. The WAR file was created by JBuilder. Do you mean it is prohibited to have the j2ee.jar file in the WEB-INF/lib directory of the application? I did a recursive search for the string "UserTransaction" in the TC 5.0.25 dir tree ad could not find a jar that included it. What is the correct way if adding the UserTransaction class to TC? TIA - Adam -Original Message- From: Shapira, Yoav [mailto:[EMAIL PROTECTED] Sent: 10 June 2004 13:57 To: Tomcat Users List Subject: RE: UserTransaction class not found in TC 5.0.25 Hi, >: The app has the j2ee.jar library in the webapps//WEB-INF/lib >: directory > >Sketchy. Worse then sketchy: not permitted. http://marc.theaimsgroup.com/?l=tomcat-user&m=108488473302822&w=2 http://marc.theaimsgroup.com/?l=tomcat-user&w=2&r=1&s=j2ee.jar&q=b The rest of QM's message is also good stuff. Yoav 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] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Page encodings
Hi everybody, I have a few questions regarding character encodings in Tomcat. Right now we`re using an old Tomcat version (3.2) but we think about upgrading to a new version if it solves our problem in an easy way. Is there a way to set Tomcat so that it both - always sends the HTTP header about page encoding to UTF-8 - sends the page UTF-8 encoded - gets the right characters when I use request.getParameters() or request.getParameterValues() I would like to prevent changing all the JSP pages to add response.setCharacterEncoding("UTF-8") and change every HTML form to specify that we expect UTF-8 at the other end. Thanks a lot Marcel Gosselin - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
No hot deploy possible for ROOT context app?
Hi all, I've been working on setting up an application in the root context, meaning I configure it via this in server.xml: This works fine, and my application gets loaded properly at tomcat start-up. I just want to make sure I'm not missing any tricks. This approach seems to eliminate the possibility of hot deploy, right? Meaning, any time I change my war file, I need to restart tomcat? Next I will try an expanded war and reloadable classes, but any comments would be appreciated. This is 4.1.29 under jboss. Thanks, Fred - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Spawn New Thread
Hi, >Really I nead the thread to be up the lifetime of Tomcat No, you don't: at most you need the thread to be up for the lifetime of your webapp. If you really need it to be up for the lifetime of tomcat, that's pretty terrible design. >because I know MyServlet will be loaded when Tomcat is. This seems to work >but is kind of "goofy" because the thread does not have a direct >relationship with the servlet it's just the only place I know to kick it >off. Is there a better (or atleast more natural) place to start this >thread? Yes, there is: a ServletContextListener's contextInitialized method to start your thread, and contextDestroyed method to close and shutdown your thread. These types of things are exactly what ServletContextListeners were designed for. Yoav 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]
RE: Memory Settings On Tomcat
Thank you, Peter, I'll give it a look. % --- Peter Lin <[EMAIL PROTECTED]> wrote: > > by the way, in case you haven't heard of it, > > http://mc4j.sourceforge.net/ > > mc4J can monitor tomcat4 and generate nice graphs. I > haven't used it, but it looks nice. > > peter > > > --- Michael Duffy <[EMAIL PROTECTED]> wrote: > > > > Hi Peter, > > > > Hiding in plain sight: > > > > > http://jakarta.apache.org/tomcat/articles/performance.pdf > > > > I apologize for overlooking it for all this time. > > I'll be sure to go through it right away. Thanks > - > > % > > > > > > --- Peter Lin <[EMAIL PROTECTED]> wrote: > > > > > > You might want to look at the VM performance > > numbers > > > in my Performance article. The link is listed on > > the > > > tomcat resources page. Generally, tweaking the > > > generations takes time. > > > > > > for something, like XML, tweaking generation > ratio > > > doesn't help. > > > > > > peter > > > > > > > > > Michael Duffy <[EMAIL PROTECTED]> wrote: > > > > > > Hi Yoav, > > > > > > > Yes to 1, and likely yes to 2. Check out the > > > > different garbage > > > > collector implementations, and the directives > > for > > > > setting old and young > > > > generation sizes. Your case is a classic one > for > > > > setting a small old > > > > generation size relative to the young > generation > > > > size: maybe even a 10-1 > > > > or slightly less ratio of young size to old > > size. > > > > > > I've never checked this page out before, but at > > your > > > prompting I found it today: > > > > > > http://java.sun.com/docs/hotspot/VMOptions.html > > > > > > I believe the docs are telling me that the > default > > > value of XX:NewRatio=12 for Intel. Is that > > correct? > > > If that's true, should I just leave the default? > > > > > > I have no experience with setting any of these > > > values. > > > I've always used the JVM right out of the box > (my > > > ignorance). > > > > > > What would be a minimum set of parameters to > span > > > this > > > space? Thanks - % > > > > > > > > > --- "Shapira, Yoav" wrote: > > > > > > > > Hi, > > > > > > > > >I've got Tomcat 4.1.29 installed to run as a > > > > service > > > > >under JDK 1.4.1_05 on this Windows 2000 > server. > > > The > > > > >Tomcat memory settings on startup are -Xms64m > > and > > > > >-Xmx1024m. The server has 512MB of physical > RAM > > > > > > > > It's not a good idea to set -Xmx to a higher > > > amount > > > > than the amount of > > > > physical RAM: the JVM will thrash once it > > reaches > > > > much less than 512MB. > > > > > > > > >My understanding is that Java's garbage > > > collection > > > > >will reclaim heap-allocated memory to the > JVM, > > > but > > > > not > > > > >necessarily to the OS. Is this true? What > this > > > > means > > > > >is that a Windoze server admin could look at > > the > > > > task > > > > >manager and see a large memory usage for > > Tomcat, > > > > but > > > > >that doesn't necessarily reflect Tomcat's > > current > > > > >usage. > > > > > > > > > >It's more like a high water mark on a pier: > > it'll > > > > show > > > > >the highest value that Tomcat has used, but > the > > > > real > > > > >value will be lower if the garbage collector > > runs > > > > and > > > > >the tide goes out. If you read a lot of > objects > > > > into > > > > >session you could end up with a big high > water > > > > mark. > > > > > > > > Your understanding is good and correct on the > > > above > > > > issues. > > > > > > > > >(1) Is my understanding of the interaction > > > between > > > > the > > > > >JVM and OS memory management correct? > > > > >(2) Are there any other tuning settings for > > > Tomcat > > > > >that I need to look at? > > > > > > > > Yes to 1, and likely yes to 2. Check out the > > > > different garbage > > > > collector implementations, and the directives > > for > > > > setting old and young > > > > generation sizes. Your case is a classic one > for > > > > setting a small old > > > > generation size relative to the young > generation > > > > size: maybe even a 10-1 > > > > or slightly less ratio of young size to old > > size. > > > > > > > > And there's the ever-present (which is why > it's > > > > often forgotten) advice: > > > > you might want to get more physical RAM. It's > > > > pretty cheap, and 512MB > > > > isn't that much for a server nowadays. > > > > > > > > Yoav > > > > > > > > > > > > > > > > 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. > > > > > > Tha
Re: Spawn New Thread
Really I nead the thread to be up the lifetime of Tomcat which brings up another question. Right now I start thread in a static block of my servlet class (for example): public class MyServelet ... static { MyThread myThread = new MyThread(); myThread.setDaemon(true); myThread.start(); } because I know MyServlet will be loaded when Tomcat is. This seems to work but is kind of "goofy" because the thread does not have a direct relationship with the servlet it's just the only place I know to kick it off. Is there a better (or atleast more natural) place to start this thread? Thanks, Corey From: Tim Funk <[EMAIL PROTECTED]> Reply-To: "Tomcat Users List" <[EMAIL PROTECTED]> To: Tomcat Users List <[EMAIL PROTECTED]> Subject: Re: Spawn New Thread Date: Wed, 09 Jun 2004 21:16:49 -0400 If the thread is associated with a servlet. It would be best to use the destroy method of the servlet to stop the thread. -Tim Corey Baswell wrote: Hello, I'm trying to figure out what the proper way for spawning a new thread in Tomcat is. I can create a new thread when my servlet is first loaded, but it does not get closed down when tomcat does. Is there anyway to register a new thread with Tomcat so that it will get closed when Tomcat goes down? - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: replacing tomcat bundled jars with new versions?
Hi, You can do so at your own risk: if interfaces changed, things will break. You're better off using later tomcat builds, which include later libraries. And 5.0.27 will have DBCP/Pool 1.2. Yoav Shapira Millennium Research Informatics >-Original Message- >From: Guy Katz [mailto:[EMAIL PROTECTED] >Sent: Thursday, June 10, 2004 9:58 AM >To: '[EMAIL PROTECTED]' >Subject: replacing tomcat bundled jars with new versions? > >hi; >for tomcat 5.0.10 and up, is it valid to change the jars that are bundles >with tomcat with advanced/bug fix versions? >for example, take tomcat 5.0.12 and put the new commons DB pool (v1.2) >instead of the existing one(v1.1)? >thanks. > > > >- >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]
RE: UserTransaction class not found in TC 5.0.25
Hi, >: The app has the j2ee.jar library in the webapps//WEB-INF/lib >: directory > >Sketchy. Worse then sketchy: not permitted. http://marc.theaimsgroup.com/?l=tomcat-user&m=108488473302822&w=2 http://marc.theaimsgroup.com/?l=tomcat-user&w=2&r=1&s=j2ee.jar&q=b The rest of QM's message is also good stuff. Yoav 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]
replacing tomcat bundled jars with new versions?
hi; for tomcat 5.0.10 and up, is it valid to change the jars that are bundles with tomcat with advanced/bug fix versions? for example, take tomcat 5.0.12 and put the new commons DB pool (v1.2) instead of the existing one(v1.1)? thanks. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Tmcat 4.1.27 Access Logs. Switching on the the Access logs.
Hi, In the server.xml file, comment the AccessLogValve element in or out as you need. Yoav Shapira Millennium Research Informatics >-Original Message- >From: Ben Bookey [mailto:[EMAIL PROTECTED] >Sent: Thursday, June 10, 2004 8:52 AM >To: Tomcat User List >Subject: Tmcat 4.1.27 Access Logs. Switching on the the Access logs. > >Dear List, > > In my NetBeans environment which has Tomcat integrated, I can find logs >which > show the individual requests for each HTML file. Where can I switch >this >on/off in my "real" > installation of Tomcat for just my application (i am sharing a tomcat >instance) with other apps.? > > I want to find any 404 File Not Found errors in my app. > >regards > >BEN > > >- >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]
RE: Spawn New Thread
Hi, And even for daemon threads, it'd be nice of you to shut them down explicitly: myThread.interrupt() (and myThread's impl catches InterruptedException and exits the run method) and myThread = null. Yoav Shapira Millennium Research Informatics >-Original Message- >From: Tim Funk [mailto:[EMAIL PROTECTED] >Sent: Wednesday, June 09, 2004 9:17 PM >To: Tomcat Users List >Subject: Re: Spawn New Thread > >If the thread is associated with a servlet. It would be best to use the >destroy method of the servlet to stop the thread. > >-Tim > >Corey Baswell wrote: > >> Hello, >> >> I'm trying to figure out what the proper way for spawning a new thread >> in Tomcat is. I can create a new thread when my servlet is first >> loaded, but it does not get closed down when tomcat does. Is there >> anyway to register a new thread with Tomcat so that it will get closed >> when Tomcat goes down? >> > >- >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]
RE: NoClassDefFoundError
Hi, >My application is in $CATALINA_HOME/webapps/ROOT/matrici Move everything one level up: from webapps/ROOT/matrici to webapps/matrici. Yoav 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]
RE: No destroy() method called on Tomcat 5.0.24 shutdown
Hi, Works for me... Yoav Shapira Millennium Research Informatics >-Original Message- >From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] >Sent: Thursday, June 10, 2004 8:50 AM >To: [EMAIL PROTECTED] >Subject: No destroy() method called on Tomcat 5.0.24 shutdown > >Hi, > >During the shutdown sequence of my Web Application I would like to have >some code executed. I implemented the destroy() method of a Servlet and >implemented a ServletContextListener. > >Both of these get called when the application is reloaded. >But neither of these is called when I shutdown Tomcat. > >Shouldn't these methods get called no matter how the servlet is being taken >out of service: > > >Called by the servlet container to indicate to a servlet that the servlet >is being taken out of service. This method is only called once all threads >within the servlet's service method have exited or after a timeout period >has passed. After the servlet container calls this method, it will not call >the service method again on this servlet. > >This method gives the servlet an opportunity to clean up any resources that >are being held (for example, memory, file handles, threads) and make sure >that any persistent state is synchronized with the servlet's current state >in memory. > > >I am using Tomcat 5.0.24 >This is on Windows 2K/XP >Using And controlling Tomcat using the Tomcat Monitor. > >Regards, > >Johan Philippe 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]
No destroy() method called on Tomcat 5.0.24 shutdown
Hi, During the shutdown sequence of my Web Application I would like to have some code executed. I implemented the destroy() method of a Servlet and implemented a ServletContextListener. Both of these get called when the application is reloaded. But neither of these is called when I shutdown Tomcat. Shouldn't these methods get called no matter how the servlet is being taken out of service: Called by the servlet container to indicate to a servlet that the servlet is being taken out of service. This method is only called once all threads within the servlet's service method have exited or after a timeout period has passed. After the servlet container calls this method, it will not call the service method again on this servlet. This method gives the servlet an opportunity to clean up any resources that are being held (for example, memory, file handles, threads) and make sure that any persistent state is synchronized with the servlet's current state in memory. I am using Tomcat 5.0.24 This is on Windows 2K/XP Using And controlling Tomcat using the Tomcat Monitor. Regards, Johan Philippe
Tmcat 4.1.27 Access Logs. Switching on the the Access logs.
Dear List, In my NetBeans environment which has Tomcat integrated, I can find logs which show the individual requests for each HTML file. Where can I switch this on/off in my "real" installation of Tomcat for just my application (i am sharing a tomcat instance) with other apps.? I want to find any 404 File Not Found errors in my app. regards BEN - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: JSP : Jakarta versus Jrun MacroMedia
If I am not mistaken, coldfusion now uses jsp tags. In fact, if you look at the output, you'll notice tons of extra /r/n in the generated HTML code. you're best bet is to look at the version of JRun you're using and which spec version it supports. either tomcat4 or 5 should be compatible. the thing you may loose is coldfusion's custom tags, but you can replace it with JSTL. the catch is you'll have to get someone who knows both coldfusion and JSTL to make the port quick and easy. I hope that helps. peter Bram Van Grimbergen <[EMAIL PROTECTED]> wrote: Hello all, Sorry in advance if my question is not addressed properly, but i'm 'breaking' my head on a question. Since a pretty long time i'm working with coldfusion mx as dynamic development environment. Due to different reasons we are thinking about moving to a jsp environment If correct: either tomcat/jakarta can handle jsp but also macromedia jrun is a sollution. Can I ask you, experts in jsp, why I should use tomcat/jakarte instead of jrun? I know too little about the differences to make a good choice. Many thanks in advance for any comment! bram - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - Do you Yahoo!? Friends. Fun. Try the all-new Yahoo! Messenger
Re: UserTransaction class not found in TC 5.0.25
On Thu, Jun 10, 2004 at 12:51:19PM +0100, Adam Lipscombe wrote: : I have deployed a J2EE app to TC 5.0.25. : The app has the j2ee.jar library in the webapps//WEB-INF/lib : directory Sketchy. : I don't understand this error because the UserTransaction class is in the : j2ee.jar file, and this is in the WEB-INF/lib dir. : What's going on here? : Does the j2ee.jar need to go somewhere else as well? Yes -- as in, remove it from WEB-INF/lib. If classes in j2ee.jar exist elsewhere in Tomcat's classpath (and most likely, they do) then you'll have problems. One common cause of the NoClassDefFound error is that the classloader found the class, but it's the wrong version. You should also rebuild your app against Tomcat's jars instead of that j2ee.jar, just to be certain. -QM -- software -- http://www.brandxdev.net tech news -- http://www.RoarNetworX.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: JSP : Jakarta versus Jrun MacroMedia
ps - please create new messages when writing the group. Simply replying to an older/unrelated message causes hell with thread-aware mailers. Thanks. -QM -- software -- http://www.brandxdev.net tech news -- http://www.RoarNetworX.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: JSP : Jakarta versus Jrun MacroMedia
On Thu, Jun 10, 2004 at 12:30:01PM +0200, Bram Van Grimbergen wrote: : Can I ask you, experts in jsp, why I should use tomcat/jakarte instead of : jrun? : I know too little about the differences to make a good choice. Then you'll have to do some research, so you can make an informed decision ;) This is way too important, and too app-specific a question for anyone to give you a direct answer. Here are some questions to ask yourself/your management/your team/etc concerning the decision: 1/ what version of the servlet spec/jsp spec does each container implement? (Tomcat 5 is servlet 2.4/jsp 2.0, the latest standard) 2/ Is commercial support important to you, or can you handle volunteer support via mailing list and self-support via research/testing? Does your team have the technical know-how (and managerial understanding) to realistically handle self-support? 3/ What features does your app require? e.g. clustering (Tomcat 5 does this), EJB (Tomcat 5 does *not* do this on its own, but it can be extended with third-party products), etc? One question to *not* ask is, "how does Tomcat compare to JRun in terms of performance?" That would require you drop your app into each container and run a load-test. A lot of J2EE webapp performance lies in the hands of the app itself. Finally, consider this: Tomcat is free, and (hopefully) Macromedia/JRun offers a brief free trial. As long as you stick to spec-compliant behavior, you could develop your app under Tomcat, get some performance specs, then drop that same webapp into JRun and test again. -QM -- software -- http://www.brandxdev.net tech news -- http://www.RoarNetworX.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
UserTransaction class not found in TC 5.0.25
Folks, I have deployed a J2EE app to TC 5.0.25. The app has the j2ee.jar library in the webapps//WEB-INF/lib directory When I access the app it displays a page with this info: javax.servlet.ServletException: Servlet execution threw an exception root cause java.lang.NoClassDefFoundError: javax/transaction/UserTransaction I don't understand this error because the UserTransaction class is in the j2ee.jar file, and this is in the WEB-INF/lib dir. What's going on here? Does the j2ee.jar need to go somewhere else as well? TIA -Adam - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: NoClassDefFoundError
Try to put the axis.jar under $CATALINA_HOME/shared/lib. Which version of Tomcat are you using? Bye, Paolo Martinelli IrisCube Reply S.p.A. -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Sent: Thu 6/10/2004 12:37 To: tomcat-user Subject: Re: NoClassDefFoundError > Is your webapp in "ROOT"? That's usually the default application for Tomcat and > your own app would be in a named context. Assuming you are doing the latter, > and your named context is "mycontext", you'd put it in: > > $CATALINA_HOME/webapps/mycontext/WEB-INF/lib > > Jake My application is in $CATALINA_HOME/webapps/ROOT/matrici I have tried to put the jar file in $CATALINA_HOME/webapps/ROOT/matrici/web/WEB-INF/lib and it fails Assuming that my application is "matrici" Do i have to put the jar file in $CATALINA_HOME/webapps/matrici/WEB-INF/lib? I have a doubt... there are other jar files containing other inportant class and this class is found correctly. Why? Angelo > > Quoting "[EMAIL PROTECTED]" <[EMAIL PROTECTED]>: > > > Hi all! > > > > I'm new to Tomcat. > > > > I have a problem testing my web application (jsp pages) > > > > A page of this application fails with this exception: > > javax.servlet.ServletException: org/apache/axis/client/Service > > org.apache.jasper.servlet.JspServlet.service(JspServlet.java:256) > > javax.servlet.http.HttpServlet.service(HttpServlet.java:856) > > > > root cause > > > > java.lang.NoClassDefFoundError: org/apache/axis/client/Service > > java.lang.ClassLoader.defineClass0(Native Method) > > java.lang.ClassLoader.defineClass(ClassLoader.java:537) > > java.security.SecureClassLoader.defineClass(SecureClassLoader.java:123) > > java.net.URLClassLoader.defineClass(URLClassLoader.java:251) > > java.net.URLClassLoader.access$100(URLClassLoader.java:55) > > java.net.URLClassLoader$1.run(URLClassLoader.java:194) > > java.security.AccessController.doPrivileged(Native Method) > > java.net.URLClassLoader.findClass(URLClassLoader.java:187) > > > org.apache.catalina.loader.StandardClassLoader.findClass(StandardClassLoader.java:520) > > > org.apache.catalina.loader.StandardClassLoader.loadClass(StandardClassLoader.java:857) > > > org.apache.catalina.loader.StandardClassLoader.loadClass(StandardClassLoader.java:756) > > java.lang.ClassLoader.loadClassInternal(ClassLoader.java:302) > > java.lang.ClassLoader.defineClass0(Native Method) > > java.lang.ClassLoader.defineClass(ClassLoader.java:537) > > java.security.SecureClassLoader.defineClass(SecureClassLoader.java:123) > > java.net.URLClassLoader.defineClass(URLClassLoader.java:251) > > java.net.URLClassLoader.access$100(URLClassLoader.java:55) > > java.net.URLClassLoader$1.run(URLClassLoader.java:194) > > java.security.AccessController.doPrivileged(Native Method) > > java.net.URLClassLoader.findClass(URLClassLoader.java:187) > > > org.apache.catalina.loader.StandardClassLoader.findClass(StandardClassLoader.java:520) > > > org.apache.catalina.loader.StandardClassLoader.loadClass(StandardClassLoader.java:857) > > > org.apache.catalina.loader.StandardClassLoader.loadClass(StandardClassLoader.java:756) > > > org.apache.catalina.loader.StandardClassLoader.loadClass(StandardClassLoader.java:840) > > > org.apache.catalina.loader.StandardClassLoader.loadClass(StandardClassLoader.java:756) > > > org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1370) > > > org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1230) > > org.apache.jasper.servlet.JasperLoader.loadClass(JasperLoader.java:184) > > org.apache.jasper.servlet.JasperLoader.loadClass(JasperLoader.java:110) > > java.lang.ClassLoader.loadClassInternal(ClassLoader.java:302) > > java.lang.Class.getDeclaredConstructors0(Native Method) > > java.lang.Class.privateGetDeclaredConstructors(Class.java:1610) > > java.lang.Class.getConstructor0(Class.java:1922) > > java.lang.Class.newInstance0(Class.java:278) > > java.lang.Class.newInstance(Class.java:261) > > ..etc etc. > > > > i have seen in the archive a similar problem posted by Tejo Vamsi Prayaga, > > but > > no solution > > > > At the end that class is in axis.jar, file located in > > $CATALINA_HOME/webapps/ROOT/WEB-INF/lib > > Is this the right location for my jar files? > > > > Thanx > > Angelo > > > > > > - > > To unsubscribe, e-mail: [EMAIL PROTECTED] > > For additional commands, e-mail: [EMAIL PROTECTED] > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -
Struts parameter setting
Hello! (BI have a question about Struts. (B (BOur system evironment is as followings. (B (B1.WWW server (BMS-Windows2000 Server$B!J(B5.00.2195 ServicePack4$B!K!"(B (B With IIS5 and JK2 connector (isapi_redirector2.dll) (B2.AP server (B MS-Windows2000 Server$B!J(B5.00.2195 ServicePack4$B!K!"(B (B Tomcat5.0.24 (B3.DB server (B MS$B!](BWindowsNT4 (B SQLServer7 (B (BConfiguration of JK2 connector in server.xml on Tomcat is (Bas followings. (B (B (B (B (B (BNo tunning has done for SQL Server7 (B (BOur application issues "Update" instruction to SQL server (Bthurough (BJDBC(Type4) by using Struts. (BWhen I describe struts-config.xml as followings, and (Bexecute stress (Btest(loop test), the application give us no response at (B100 times (Bexecution. (B (B (B (B (B (B (B (B (B (B (B (B (B (B (B (BHowever Tomcat and SQL server are working properly even in (Bthis situation. (B(Just respond me nothing from application.) (B (BSo I tried to following modification to struts-config.xml (Bas followings. (B Original : (B After modification: (B (BThen try stress test again, THE SYSTEM KEEPS ON RUNNING (BPROPERLY. (B (B (BWe have set "maxCount" parameter value to "-1". (BIs this correct usage? (BWe could not find any documentation for this "maxCount". (BIs there anyone who can teach me the spec. of parameter (B"maxCount" ? (B (BSorry for long message. (BThank you. (B (BGeorge (B (B__ (BDo You Yahoo!? (Bhttp://bb.yahoo.co.jp/ (B (B (B- (BTo unsubscribe, e-mail: [EMAIL PROTECTED] (BFor additional commands, e-mail: [EMAIL PROTECTED]
RE: No response from Tomcat 5 with IIS
Hello. (BYes. I'm using MS SQL7. (BI could find turn around today. (BI'll report this in another message I'll post you. (BThank you very much. (B (BGeorge (B (B--- Carl Olivier <[EMAIL PROTECTED]> Wrote: (B> Hi. (B> (B> Are you doing any database work? Is it possible (B> that you have a database (B> lock happening in the middle of a transaction? (B> (B> Carl (B> (B> -Original Message- (B> From: George [mailto:[EMAIL PROTECTED] (B> Sent: 09 June 2004 02:33 AM (B> To: Tomcat Users List (B> Subject: RE: No response from Tomcat 5 with IIS (B> (B> (B> Thank you very much Raymond. (B> However all memories you pointed out are enough. (B> CPU load is almost zero. (B> During this problem is happenning, I create another (B> small (B> test application and run. And I could get the result (B> that "Tomcat is running (B> properly". What's happen??? I think only my original (B> application just hung (B> up. No error messages. No warnnings. No logs. To (B> recover this problem, is to (B> reboot Tomcat. (B> (B> Any suggestion would be appreciated. (B> (B> George (B> (B> --- "STOCKHOLM, Raymond" <[EMAIL PROTECTED]> (B> wrote: (B> Maybe you are running low in memory, and the GC is (B> > taking all the process. (B> > check : (B> > long totalMemory = (B> > Runtime.getRuntime().totalMemory(); (B> > long freeMemory = (B> > Runtime.getRuntime().freeMemory(); (B> > long maxMemory = (B> Runtime.getRuntime().maxMemory(); (B> > log.info("totalMemory="+totalMemory); (B> > log.info("freeMemory ="+freeMemory); (B> > log.info("maxMemory ="+maxMemory); (B> > (B> > -Message d'origine- (B> > De$BA~(B: George [mailto:[EMAIL PROTECTED] (B> > Envoy$BC)A~(B: mardi 8 juin 2004 17:31 (B> > $B%F%D(B : [EMAIL PROTECTED] (B> > Objet$BA~(B: Re: No response from Tomcat 5 with IIS (B> > (B> > (B> > Hello! all. (B> > Please give me any advice since this issue is top (B> > urgent (B> > for me. (B> > Any suggenstion would be appreciated for me. (B> > Thank you very much. (B> > George (B> > (B> > --- Reply from George <[EMAIL PROTECTED]>: (B> > > Hi! (B> > > I'm having following problem. (B> > > (B> > > (B> > > Tomcat 5.0.24 running on Windows 2000 server and (B> > IIS (B> > > 5, (B> > > JK2 2.0.4 (B> > > The server is put under hardware load balancer (B> > > "BIG-IP" by (B> > > F5 inc. (B> > > (B> > > (B> > > Sometime when the system load is high (about 10 (B> to (B> > > 20 (B> > > users are using the aplication), tomcat does not (B> > > respond (B> > > suddenly. (B> > > No event log has written. (B> > > (B> > > Is there anyone who can teach me any tunr (B> arround? (B> > > (B> > > Please help me! (B> > > (B> > > George (B> > > (B> > > (B> > > (B> __ (B> > > Do You Yahoo!? (B> > > http://bb.yahoo.co.jp/ (B> > > (B> > > (B> > > (B> > (B> (B- (B> > > To unsubscribe, e-mail: (B> [EMAIL PROTECTED] (B> > > For additional commands, e-mail: (B> > > [EMAIL PROTECTED] (B> > > (B> > (B> > __ (B> > Do You Yahoo!? (B> > http://bb.yahoo.co.jp/ (B> > (B> > (B> > (B> (B- (B> > To unsubscribe, e-mail: (B> [EMAIL PROTECTED] (B> > For additional commands, e-mail: (B> > [EMAIL PROTECTED] (B> > (B> > (B> (B> __ (B> Do You Yahoo!? (B> http://bb.yahoo.co.jp/ (B> (B> (B> (B- (B> To unsubscribe, e-mail: (B> [EMAIL PROTECTED] (B> For additional commands, e-mail: (B> [EMAIL PROTECTED] (B> (B> (B- (B> To unsubscribe, e-mail: (B> [EMAIL PROTECTED] (B> For additional commands, e-mail: (B> [EMAIL PROTECTED] (B> (B (B__ (BDo You Yahoo!? (Bhttp://bb.yahoo.co.jp/ (B (B (B- (BTo unsubscribe, e-mail: [EMAIL PROTECTED] (BFor additional commands, e-mail: [EMAIL PROTECTED]
Re: NoClassDefFoundError
> Is your webapp in "ROOT"? That's usually the default application for Tomcat and > your own app would be in a named context. Assuming you are doing the latter, > and your named context is "mycontext", you'd put it in: > > $CATALINA_HOME/webapps/mycontext/WEB-INF/lib > > Jake My application is in $CATALINA_HOME/webapps/ROOT/matrici I have tried to put the jar file in $CATALINA_HOME/webapps/ROOT/matrici/web/WEB-INF/lib and it fails Assuming that my application is "matrici" Do i have to put the jar file in $CATALINA_HOME/webapps/matrici/WEB-INF/lib? I have a doubt... there are other jar files containing other inportant class and this class is found correctly. Why? Angelo > > Quoting "[EMAIL PROTECTED]" <[EMAIL PROTECTED]>: > > > Hi all! > > > > I'm new to Tomcat. > > > > I have a problem testing my web application (jsp pages) > > > > A page of this application fails with this exception: > > javax.servlet.ServletException: org/apache/axis/client/Service > > org.apache.jasper.servlet.JspServlet.service(JspServlet.java:256) > > javax.servlet.http.HttpServlet.service(HttpServlet.java:856) > > > > root cause > > > > java.lang.NoClassDefFoundError: org/apache/axis/client/Service > > java.lang.ClassLoader.defineClass0(Native Method) > > java.lang.ClassLoader.defineClass(ClassLoader.java:537) > > java.security.SecureClassLoader.defineClass(SecureClassLoader.java:123) > > java.net.URLClassLoader.defineClass(URLClassLoader.java:251) > > java.net.URLClassLoader.access$100(URLClassLoader.java:55) > > java.net.URLClassLoader$1.run(URLClassLoader.java:194) > > java.security.AccessController.doPrivileged(Native Method) > > java.net.URLClassLoader.findClass(URLClassLoader.java:187) > > > org.apache.catalina.loader.StandardClassLoader.findClass(StandardClassLoader.java:520) > > > org.apache.catalina.loader.StandardClassLoader.loadClass(StandardClassLoader.java:857) > > > org.apache.catalina.loader.StandardClassLoader.loadClass(StandardClassLoader.java:756) > > java.lang.ClassLoader.loadClassInternal(ClassLoader.java:302) > > java.lang.ClassLoader.defineClass0(Native Method) > > java.lang.ClassLoader.defineClass(ClassLoader.java:537) > > java.security.SecureClassLoader.defineClass(SecureClassLoader.java:123) > > java.net.URLClassLoader.defineClass(URLClassLoader.java:251) > > java.net.URLClassLoader.access$100(URLClassLoader.java:55) > > java.net.URLClassLoader$1.run(URLClassLoader.java:194) > > java.security.AccessController.doPrivileged(Native Method) > > java.net.URLClassLoader.findClass(URLClassLoader.java:187) > > > org.apache.catalina.loader.StandardClassLoader.findClass(StandardClassLoader.java:520) > > > org.apache.catalina.loader.StandardClassLoader.loadClass(StandardClassLoader.java:857) > > > org.apache.catalina.loader.StandardClassLoader.loadClass(StandardClassLoader.java:756) > > > org.apache.catalina.loader.StandardClassLoader.loadClass(StandardClassLoader.java:840) > > > org.apache.catalina.loader.StandardClassLoader.loadClass(StandardClassLoader.java:756) > > > org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1370) > > > org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1230) > > org.apache.jasper.servlet.JasperLoader.loadClass(JasperLoader.java:184) > > org.apache.jasper.servlet.JasperLoader.loadClass(JasperLoader.java:110) > > java.lang.ClassLoader.loadClassInternal(ClassLoader.java:302) > > java.lang.Class.getDeclaredConstructors0(Native Method) > > java.lang.Class.privateGetDeclaredConstructors(Class.java:1610) > > java.lang.Class.getConstructor0(Class.java:1922) > > java.lang.Class.newInstance0(Class.java:278) > > java.lang.Class.newInstance(Class.java:261) > > ..etc etc. > > > > i have seen in the archive a similar problem posted by Tejo Vamsi Prayaga, > > but > > no solution > > > > At the end that class is in axis.jar, file located in > > $CATALINA_HOME/webapps/ROOT/WEB-INF/lib > > Is this the right location for my jar files? > > > > Thanx > > Angelo > > > > > > - > > To unsubscribe, e-mail: [EMAIL PROTECTED] > > For additional commands, e-mail: [EMAIL PROTECTED] > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: [Resource Not available] Newbie question
You would also need to tell us your servlet-mapping and the directory of the file that the form is in. Tim > -Original Message- > From: Michael Drewitz > [mailto:[EMAIL PROTECTED] > Sent: 10 June 2004 11:18 > To: [EMAIL PROTECTED] > Subject: [Resource Not available] Newbie question > > > Hi all, > > if I try to access the below described servlet from a html- or jsp-file > I get "Http 404 Error - Resource not available". > > > .. > > I have tried it with the package-name as prefix and the prefix > "servlet/", but nothing works. > Whats wrong? > > The class-file is located in the defined directory under ../web-inf/classes. > This is the only element of web.xml: > > AVG_ValuesServlet > org.haw.weather.web.AVG_ValuesServlet > > > Thanks in advance, Michael > > > > > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > > - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
JSP : Jakarta versus Jrun MacroMedia
Hello all, Sorry in advance if my question is not addressed properly, but i'm 'breaking' my head on a question. Since a pretty long time i'm working with coldfusion mx as dynamic development environment. Due to different reasons we are thinking about moving to a jsp environment If correct: either tomcat/jakarta can handle jsp but also macromedia jrun is a sollution. Can I ask you, experts in jsp, why I should use tomcat/jakarte instead of jrun? I know too little about the differences to make a good choice. Many thanks in advance for any comment! bram - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
[Resource Not available] Newbie question
Hi all, if I try to access the below described servlet from a html- or jsp-file I get "Http 404 Error - Resource not available". .. I have tried it with the package-name as prefix and the prefix "servlet/", but nothing works. Whats wrong? The class-file is located in the defined directory under ../web-inf/classes. This is the only element of web.xml: AVG_ValuesServlet org.haw.weather.web.AVG_ValuesServlet Thanks in advance, Michael - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Using JAVA_OPTS=" -sever" with jsvc on linux
It looks like you should put it in your CATALINA_OPTS so that line would become CATALINA_OPTS="-server -Xms256m -Xmx256m -XX:PermSize=128m -XX:MaxPermSize=128m" -Original Message- From: Mariano [mailto:[EMAIL PROTECTED] Sent: 10 June 2004 10:17 To: [EMAIL PROTECTED] Subject: Using JAVA_OPTS=" -sever" with jsvc on linux Hi all, i like to specify JAVA_OPTS=" -sever" with jsvc on linux Fedora Core 1. I use J2SDK 1.4.2_04-b05 and Tomcat 5.0.25. Now i put a line into Tomcat.sh like JAVA_OPTS=" -sever ", but i don't know if this is correct. Tomcat.sh: JAVA_HOME=/var/j2sdk CATALINA_HOME=/var/tomcat DAEMON_HOME=/var/tomcat/bin TOMCAT_USER=tomcat TMP_DIR=/var/tmp JAVA_OPTS=" -server " export JAVA_OPTS CATALINA_OPTS="-Xms256m -Xmx256m -XX:PermSize=128m -XX:MaxPermSize=128m" CLASSPATH=\ $JAVA_HOME/lib/tools.jar:\ $CATALINA_HOME/bin/commons-daemon.jar:\ $CATALINA_HOME/bin/bootstrap.jar case "$1" in start) # # Start Tomcat # $DAEMON_HOME/jsvc \ -user $TOMCAT_USER \ -home $JAVA_HOME \ -Dcatalina.home=$CATALINA_HOME \ -Djava.io.tmpdir=$TMP_DIR \ -outfile $CATALINA_HOME/logs/catalina.out \ -errfile '&1' \ $CATALINA_OPTS \ -cp $CLASSPATH \ # # To get a verbose JVM #-verbose \ # To get a debug of jsvc. #-debug \ ;; stop) # # Stop Tomcat # PID=`cat /var/run/jsvc.pid` kill $PID ;; *) echo "Usage tomcat.sh start/stop" exit 1;; esac Thanks. Mariano López Any opinions expressed in this E-mail may be those of the individual and not necessarily the company. This E-mail and any files transmitted with it are confidential and solely for the use of the intended recipient. If you are not the intended recipient or the person responsible for delivering to the intended recipient, be advised that you have received this E-mail in error and that any use or copying is strictly prohibited. If you have received this E-mail in error please notify the beCogent postmaster at [EMAIL PROTECTED] Unless expressly stated, opinions in this email are those of the individual sender and not beCogent Ltd. You must take full responsibility for virus checking this email and any attachments. Please note that the content of this email or any of its attachments may contain data that falls within the scope of the Data Protection Acts and that you must ensure that any handling or processing of such data by you is fully compliant with the terms and provisions of the Data Protection Act 1984 and 1998. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Using JAVA_OPTS=" -sever" with jsvc on linux
Hi all, i like to specify JAVA_OPTS=" -sever" with jsvc on linux Fedora Core 1. I use J2SDK 1.4.2_04-b05 and Tomcat 5.0.25. Now i put a line into Tomcat.sh like JAVA_OPTS=" -sever ", but i don't know if this is correct. Tomcat.sh: JAVA_HOME=/var/j2sdk CATALINA_HOME=/var/tomcat DAEMON_HOME=/var/tomcat/bin TOMCAT_USER=tomcat TMP_DIR=/var/tmp JAVA_OPTS=" -server " export JAVA_OPTS CATALINA_OPTS="-Xms256m -Xmx256m -XX:PermSize=128m -XX:MaxPermSize=128m" CLASSPATH=\ $JAVA_HOME/lib/tools.jar:\ $CATALINA_HOME/bin/commons-daemon.jar:\ $CATALINA_HOME/bin/bootstrap.jar case "$1" in start) # # Start Tomcat # $DAEMON_HOME/jsvc \ -user $TOMCAT_USER \ -home $JAVA_HOME \ -Dcatalina.home=$CATALINA_HOME \ -Djava.io.tmpdir=$TMP_DIR \ -outfile $CATALINA_HOME/logs/catalina.out \ -errfile '&1' \ $CATALINA_OPTS \ -cp $CLASSPATH \ # # To get a verbose JVM #-verbose \ # To get a debug of jsvc. #-debug \ ;; stop) # # Stop Tomcat # PID=`cat /var/run/jsvc.pid` kill $PID ;; *) echo "Usage tomcat.sh start/stop" exit 1;; esac Thanks. Mariano López