Re: Auto Session Creation and memory usage
Jacob Rhoden wrote: I am working on creating some more scalable tomcat applications. I have addedd a SessionListener and it seems that hitting a jsp page triggers a session to be created. If there are 1000 users and only 10 are signed in, I dont think 1000 sessions need to be created yes. How do I turn off auto session creation, or is this impossible. (Google has not been my friend in this regard, do people not think about this sort of thing?) I'd consider it very likely that people actually do think about this sort of thing. And that they set session=false in the JSP page directive if they don't want a session to be created. Regards mks - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: retrieving tomcat info from within a war
- Original Message - From: Jerry Atrick [EMAIL PROTECTED] To: users@tomcat.apache.org Sent: Wednesday, July 23, 2008 10:51 PM Subject: retrieving tomcat info from within a war Is there a way to retrieve tomcat version/info from within a War file? I actually would prefer this to be web container agnostic, but I'm working with Tomcat, so that's where I will start. I know that the manager does almost exactly what I want when going to: http://localhost:8080/manager/serverinfo but for the life of me, I can't seem to find it in the src. They hide it in a property file heres the code try { InputStream is = ServerInfo.class.getResourceAsStream (/org/apache/catalina/util/ServerInfo.properties); Properties props = new Properties(); props.load(is); is.close(); serverInfo = props.getProperty(server.info); serverBuilt = props.getProperty(server.built); serverNumber = props.getProperty(server.number); } catch (Throwable t) {} The rest of that stuff OS etc is just Java properties like... sInfo += JVM Vendor: + System.getProperty(java.vm.vendor) + \n; etc I wonder what would happen if you ran this against Glassfish I bet it works... coz TC is probably hiding in there somewhere ;) agnosticism thru theft... ha ha Have fun.. --- HARBOR : http://www.kewlstuff.co.za/index.htm The most powerful application server on earth. The only real POJO Application Server. See it in Action : http://www.kewlstuff.co.za/cd_tut_swf/whatisejb1.htm --- - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Https SSL support in Tomcat 5.5
From: Baunty ruparelia [mailto:[EMAIL PROTECTED] Subject: Https SSL support in Tomcat 5.5 when we are fire the http://localhost into the IE address bar, It not be transfer to the https://localhost:443 which should be happen, as we are define the redirect port. Just defining a redirect port is not sufficient. The requested resource must be marked with a transport-guarantee of CONFIDENTIAL in the webapp's WEB-INF/web.xml file. Read the servlet spec. - Chuck THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY MATERIAL and is thus for use only by the intended recipient. If you received this in error, please contact the sender and delete the e-mail and its attachments from all computers. - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Memory question
Ooops. It's been a long time since I've taken a look at catalina.sh. Just saw the startup.sh pass parameters along. --David Caldarale, Charles R wrote: From: David Smith [mailto:[EMAIL PROTECTED] Subject: Re: Memory question I believe the startup script accepts extra parameters and just passes them on to the JVM for startup. You should be able to do: startup.sh -Xmx512m Unfortunately not, although it certainly would be convenient. The extra parameters are passed to Tomcat's Bootstrap class, not the JVM. You really do have to use CATALINA_OPTS or JAVA_OPTS. - Chuck THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY MATERIAL and is thus for use only by the intended recipient. If you received this in error, please contact the sender and delete the e-mail and its attachments from all computers. - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- David Smith Programmer/Analyst College of Agriculture and Life Sciences Cornell University B32 Morrison Hall Ithaca, NY 14853 Phone: (607) 255-4521 - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: mod_jk for apache2-2.2.8 and tomcat4.1.30 from HP-UX server
This is the result of /usr/local/apache2/bin/apxs -q PREFIX interpreter /usr/bin/perl not found ksh: /usr/local/apache2/bin/apxs: not found Regards, Marcio Bomfim -Original Message- From: Rainer Jung [mailto:[EMAIL PROTECTED] Sent: Wednesday, July 23, 2008 6:54 PM To: Tomcat Users List Subject: Re: mod_jk for apache2-2.2.8 and tomcat4.1.30 from HP-UX server Bomfim, Marcio schrieb: Does anybody know where to find the mod_jk for apache2-2.2.8 and tomcat4.1.30? (HP-UX machine) I've downloaded from http://tomcat.apache.org/connectors-doc/ (JK 1.2.26 release sources) and ran the commands: CFLAGS=$CPPFLAGS -DHPUX11GCC -DHPUX11 \ ./configure --with-apxs=/usr/local/apache2/bin/apxs --with-apache=/usr/local/apache2 got the error configure: error: You must specify a valid --with-apxs path What's the result of /usr/local/apache2/bin/apxs -q PREFIX Regards, Rainer - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
TCP/AJP KeepAlive on Tomcat side?
Hello, on mod_jk side one can define keepalive=true for OS TCP KeepAlice Activation for the (AJP) Connections to the tomcats. Is there a possibility to activate tcp or ajp keepalive on the tomcat side? Thank You! - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: TCP/AJP KeepAlive on Tomcat side?
From: Stephanie Wullbieter [mailto:[EMAIL PROTECTED] Subject: TCP/AJP KeepAlive on Tomcat side? Is there a possibility to activate tcp or ajp keepalive on the tomcat side? Already is by default. Read the doc: http://tomcat.apache.org/tomcat-6.0-doc/config/http.html http://tomcat.apache.org/tomcat-6.0-doc/config/ajp.html - Chuck THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY MATERIAL and is thus for use only by the intended recipient. If you received this in error, please contact the sender and delete the e-mail and its attachments from all computers. - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Re direction in tomcat 5.5
I'm running TomCat 5.5 on a windows server. I am trying to get everything redirected to the ssl port 8443. I can still get to the site using the port 8080. I haven't found any examples that show how it should be configured. This is my first TomCat installation and most everything has gone well, just this one glictch. Should I just disable port 8080 in the system.xml, or is there a more elegant solution. (for my 8080 connection the redirect is to 8443). Connector port=8443 maxHttpHeaderSize=8192 maxThreads=150 minSpareThreads=25 maxSpareThreads=75 enableLookups=false disableUploadTimeout=true acceptCount=100 scheme=https secure=true clientAuth=false sslProtocol=TLS keystoreFile=D:\certkeystore\.keystore keystorePass=single1! / Connector port=8080 maxHttpHeaderSize=8192 maxThreads=150 minSpareThreads=25 maxSpareThreads=75 enableLookups=false redirectPort=8443 acceptCount=100 connectionTimeout=2 disableUploadTimeout=true / Jack W. Gordon Jr Server Administrator Information Technology Oklahoma State University Stillwater, Oklahoma 74078 405-744-4540
RE: Memory question
Thank you all! I set JAVA_OPTS in the tomcat startup and it works! Now to figure out the next problem, but that's an issue with the application I'm running and not Tomcat. On Wed, 2008-07-23 at 20:00 -0500, Caldarale, Charles R wrote: From: David Smith [mailto:[EMAIL PROTECTED] Subject: Re: Memory question I believe the startup script accepts extra parameters and just passes them on to the JVM for startup. You should be able to do: startup.sh -Xmx512m Unfortunately not, although it certainly would be convenient. The extra parameters are passed to Tomcat's Bootstrap class, not the JVM. You really do have to use CATALINA_OPTS or JAVA_OPTS. - Chuck THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY MATERIAL and is thus for use only by the intended recipient. If you received this in error, please contact the sender and delete the e-mail and its attachments from all computers. - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] Matt Burkhardt, MSTM President Impari Systems, Inc. 401 Rosemont Avenue Frederick, MD 21701 [EMAIL PROTECTED] www.imparisystems.com (301) 644-3911
RE: Re direction in tomcat 5.5
From: Gordon, Jack [mailto:[EMAIL PROTECTED] Subject: RE: Re direction in tomcat 5.5 I'm running TomCat 5.5 on a windows server. You're running Tomcat, not TomCat. I am trying to get everything redirected to the ssl port 8443. Read section 12 of the servlet spec (JSR-000154). Only protected resources with a transport-guarantee of CONFIDENTIAL or better will be automatically redirected to the SSL port. Note that the world's most popular and standards-ignoring browser (IE) frequently mishandles SSL on any port other than 443. Should I just disable port 8080 in the system.xml (That's server.xml; precision counts.) You can do that, but browsers would show an error when attempting a normal connection. You could write a simple filter or valve that just redirects HTTP requests to HTTPS on the desired port. - Chuck THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY MATERIAL and is thus for use only by the intended recipient. If you received this in error, please contact the sender and delete the e-mail and its attachments from all computers. - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
options map empty
sorry my poor english. i have trouble with loginmodule config file. i cant see options from login configurtion file. at initialize() options no keyset. TomCatAdminApplication { my.MyLoginModule required optOne=one optTwo=two optThree=three; }; tomcat 6 - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Context or Mapping problems Apache 2.2 +mod_JK+ Tomcat 5.5
Thanks for your replay. When I sent the email it generated asterisks. In the context there is not any asteriske. I do not use them. The Catalina directory name was a typo too. I removed the path and docBase attributes like this: Context path= docBase= debug=5 reloadable=true crossContext=true ** still does not work: (*The requested resource (/webapplication/welcome.do) is not available.)* Thanks, MK On 7/24/08, Caldarale, Charles R [EMAIL PROTECTED] wrote: From: kohanm [EMAIL PROTECTED] Subject: Context or Mapping problems Apache 2.2 +mod_JK+ Tomcat 5.5 If I change the directory name Tomcat5.5/webapps/*booking* to the *webapplication,* the server works fine. Which is how it's supposed to work. The URI path to the webapp is determined by the name of the webapp's directory or .war file. The content of context xml file on Tomcat5.5/conf/localhost/*webapplication.xml*: I'll presume the above is a typo, and should really be Tomcat5.5/conf/Catalina/localhost/webapplication.xml (BTW, putting asterisks in what should be verbatim configuration text only confuses things.) * * Context path=/*webapplication* docBase=*booking* The path attribute is not allowed for this Context element, and the docBase setting conflicts with the name of the .xml file. At best you'll be getting double deployment, but the behavior can not be guaranteed to be consistent across different Tomcat levels. Change the name of the deployment directory to webapplication, remove the path and docBase attributes, and it all should work. - Chuck THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY MATERIAL and is thus for use only by the intended recipient. If you received this in error, please contact the sender and delete the e-mail and its attachments from all computers. - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- Massoud
Re: retrieving tomcat info from within a war
Awesome, that worked perfectly! On Thu, Jul 24, 2008 at 5:56 AM, Johnny Kewl [EMAIL PROTECTED] wrote: - Original Message - From: Jerry Atrick [EMAIL PROTECTED] To: users@tomcat.apache.org Sent: Wednesday, July 23, 2008 10:51 PM Subject: retrieving tomcat info from within a war Is there a way to retrieve tomcat version/info from within a War file? I actually would prefer this to be web container agnostic, but I'm working with Tomcat, so that's where I will start. I know that the manager does almost exactly what I want when going to: http://localhost:8080/manager/serverinfo but for the life of me, I can't seem to find it in the src. They hide it in a property file heres the code try { InputStream is = ServerInfo.class.getResourceAsStream (/org/apache/catalina/util/ServerInfo.properties); Properties props = new Properties(); props.load(is); is.close(); serverInfo = props.getProperty(server.info); serverBuilt = props.getProperty(server.built); serverNumber = props.getProperty(server.number); } catch (Throwable t) {} The rest of that stuff OS etc is just Java properties like... sInfo += JVM Vendor: + System.getProperty(java.vm.vendor) + \n; etc I wonder what would happen if you ran this against Glassfish I bet it works... coz TC is probably hiding in there somewhere ;) agnosticism thru theft... ha ha Have fun.. --- HARBOR : http://www.kewlstuff.co.za/index.htm The most powerful application server on earth. The only real POJO Application Server. See it in Action : http://www.kewlstuff.co.za/cd_tut_swf/whatisejb1.htm --- - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: TCP/AJP KeepAlive on Tomcat side?
Stephanie Wullbieter wrote: Hello, on mod_jk side one can define keepalive=true for OS TCP KeepAlice Activation for the (AJP) Connections to the tomcats. Is there a possibility to activate tcp or ajp keepalive on the tomcat side? The term Keepalive has various meanings, depending on the protocol to which it gets applied. For upper level protocols it usually means, that some sort of established connection gets reused during multiple requests. For AJP13 this is automatically the case, no need to configure. For TCP it does mean send an empty packet automatically when the connection is idle for a long time in order to prevent intermediate network components to drop the connection information from their state table. Usually this is done with respect to firewalls sitting between the two communicating endpoints. In this scenario it is enough, if one of the two endpoints activate SO_KEEPALIVE on the socket and thus sends the packets. In the mod_jk/Tomcat case, this is done via mod_jk. Some information is also contained in http://tomcat.apache.org/connectors-doc/generic_howto/timeouts.html Regards, Rainer - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: mod_jk for apache2-2.2.8 and tomcat4.1.30 from HP-UX server
Bomfim, Marcio wrote: This is the result of /usr/local/apache2/bin/apxs -q PREFIX interpreter /usr/bin/perl not found ksh: /usr/local/apache2/bin/apxs: not found So your Apache installation is broken. If apxs doesn't work, then the build procedure for mod_jk will not work. You could either ask the people you got your Apache from, or try to repair: - Check, that /usr/local/apache2/bin/apxs itself is executable (seems to be the case) - Check the first line, Most likely something like #!/usr/bin/perl, find a working perl on your system and change the path /usr/bin/perl to the path to your working perl binary. - Try /usr/local/apache2/bin/apxs -q PREFIX again, it should output the path to your apache installation (e.g. /usr/local/apache2) If this works, try building mod_jk again. Regards, Rainer Regards, Marcio Bomfim -Original Message- From: Rainer Jung [mailto:[EMAIL PROTECTED] Sent: Wednesday, July 23, 2008 6:54 PM To: Tomcat Users List Subject: Re: mod_jk for apache2-2.2.8 and tomcat4.1.30 from HP-UX server Bomfim, Marcio schrieb: Does anybody know where to find the mod_jk for apache2-2.2.8 and tomcat4.1.30? (HP-UX machine) I've downloaded from http://tomcat.apache.org/connectors-doc/ (JK 1.2.26 release sources) and ran the commands: CFLAGS=$CPPFLAGS -DHPUX11GCC -DHPUX11 \ ./configure --with-apxs=/usr/local/apache2/bin/apxs --with-apache=/usr/local/apache2 got the error configure: error: You must specify a valid --with-apxs path What's the result of /usr/local/apache2/bin/apxs -q PREFIX Regards, Rainer - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Server.xml Host Configuration
I am facing a problem in my application with tld not found error. The absolute uri: http://www.mySite.com/tags-abc cannot be resolved in either web.xml or the jar files deployed with this application Here is my directory at server /var/www/mySitelocal_stage/philly (philly is my application root directory) Here is the taglib entry in web.xml file jsp-config taglib taglib-urihttp://www.mySite.com/tags-abc/taglib-uri taglib-location/WEB-INF/abc.tld/taglib-location /taglib /jsp-config My abc.tld is at /WEB-INF/ directory. when I try for first page with stage2.philly.mySite.com it works fine. No errors at all. But when I try http://stage2.philly.mySite.com/events/index.jsp; it gives me the error for tld. The absolute uri: http://www.mySite.com/tags-abc cannot be resolved in either web.xml or the jar files deployed with this application Both the first page's jsp and events/index.jsp is having the tld included as %@ taglib uri=http://www.mySite.com/tags-abc; prefix=app %. My home page is directly under /WEB-INF/ folder., where as for second URL I have /WEB-INF/events/index.jsp The atrange thing is, whe I try this application on my local machine, it works fine with both the URL. but on server it fails. I have server.xml entry on Server as below: Host name=stage2.philly.mySite.com appBase=/var/www/mySitelocal_stage/philly unpackWARs=true autoDeploy=false xmlValidation=false xmlNamespaceAware=false Aliasstage2.philly.mySite.com/Alias Alias192.168.1.166/Alias Alias207.97.248.156/Alias Context docBase=/var/www/mySitelocal_stage/philly path= / Valve className=org.apache.catalina.valves.AccessLogValve directory=logs prefix=www_phillymySite_com_log. suffix=.txt pattern=common resolveHosts=false/ /Host IT MUST BE CAUSING THAT. Please help me out with possible solutions for this problem. If you need anything else apart from this, then please let me know. Thank You, -- View this message in context: http://www.nabble.com/Server.xml-Host-Configuration-tp18636070p18636070.html Sent from the Tomcat - User mailing list archive at Nabble.com. - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Context or Mapping problems Apache 2.2 +mod_JK+ Tomcat 5.5
From: kohanm [mailto:[EMAIL PROTECTED] Subject: Re: Context or Mapping problems Apache 2.2 +mod_JK+ Tomcat 5.5 I removed the path and docBase attributes like this: Context path= docBase= debug=5 reloadable=true crossContext=true No, remove means remove, not change the values to null strings. Your Context element should simply be this: Context debug=5 reloadable=true crossContext=true Where is your Context element located now? Where is your webapp deployed (name of directory or war file)? The requested resource (/webapplication/welcome.do) is not available. Verify that you can access the webapp through Tomcat's HTTP connector, then try it through httpd. If you can get at it directly but not through httpd, then something's wrong with your httpd mappings, which I can't help you with. - Chuck THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY MATERIAL and is thus for use only by the intended recipient. If you received this in error, please contact the sender and delete the e-mail and its attachments from all computers. - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Context or Mapping problems Apache 2.2 +mod_JK+ Tomcat 5.5
Hi, The context located : Tomcat 5.5\conf\Catalina\localhost\webapplication.xml and I modified as you mentioned: Context debug=5 reloadable=true crossContext=true --- /Context I tried the http://localhost/webapplication/welcome.do URl it did not work. then I tried to check the Tomcat separately with it's port: http://localhost:*8080/booking*/welcome.do* it worked(* Tomcat5.5/webapps/booking*) .* ** and http://localhost:*8080/webapplication/welcome.dohttp://localhost:8080/webapplication/welcome.do did not work.* ** So I think the Tomcat does not mapping to the Tomcat5.5/webapps/*booking* directory properly*.* Any suggestions. Thanks. MK On 7/24/08, Caldarale, Charles R [EMAIL PROTECTED] wrote: From: kohanm [mailto:[EMAIL PROTECTED] Subject: Re: Context or Mapping problems Apache 2.2 +mod_JK+ Tomcat 5.5 I removed the path and docBase attributes like this: Context path= docBase= debug=5 reloadable=true crossContext=true No, remove means remove, not change the values to null strings. Your Context element should simply be this: Context debug=5 reloadable=true crossContext=true Where is your Context element located now? Where is your webapp deployed (name of directory or war file)? The requested resource (/webapplication/welcome.do) is not available. Verify that you can access the webapp through Tomcat's HTTP connector, then try it through httpd. If you can get at it directly but not through httpd, then something's wrong with your httpd mappings, which I can't help you with. - Chuck THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY MATERIAL and is thus for use only by the intended recipient. If you received this in error, please contact the sender and delete the e-mail and its attachments from all computers. - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- Massoud
Tomcat 5.5 -- Enabling of Certain Characters in URLs
Hi, Currently running the open source webapp eXist (http://exist.sourceforge.net/) on Tomcat 5.5. It works well expect for this glitch: in trying to access file names containing ( or , characters, Tomcat generates a 404 document not found message. I've tried encoding these with %29 and other encodings, but that doesn't help. Is there a setting in the conf files that can be enabled to allow ( or , in URLs preferably without encoding? In looking through the mailing list archives (see http://mail-archives.apache.org/mod_mbox/tomcat-dev/200109.mbox/[EMAIL PROTECTED]) , I noticed that there is a lt;DecodeInterceptor safe=false /gt; setting, but I don't know if that's part of Tomcat 5.5 or if it is, can it have to be added, and if to which file and where in the conf files? Or is there another setting that can be added/enabled? Thanks, Greg ?
RE: Context or Mapping problems Apache 2.2 +mod_JK+ Tomcat 5.5
From: kohanm [mailto:[EMAIL PROTECTED] Subject: Re: Context or Mapping problems Apache 2.2 +mod_JK+ Tomcat 5.5 The context located : Tomcat 5.5\conf\Catalina\localhost\webapplication.xml and I modified as you mentioned: Context debug=5 reloadable=true crossContext=true --- /Context then I tried to check the Tomcat separately with it's port: http://localhost:*8080/booking*/welcome.do* it worked(* Tomcat5.5/webapps/booking*) .* ** and http://localhost:*8080/webapplication/welcome.dohttp://localh ost:8080/webapplication/welcome.do did not work.* ** So I think the Tomcat does not mapping to the Tomcat5.5/webapps/*booking* directory properly*.* You need to decide if your application is going to be reachable by the webapplication URI or the booking URI; choose one or the other, change the name of the Context .xml file to match, change the directory name (or .war file) for the application to match, and stick with *one* name. By trying to use both, you're just creating confusion. - Chuck THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY MATERIAL and is thus for use only by the intended recipient. If you received this in error, please contact the sender and delete the e-mail and its attachments from all computers. - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: options map empty
never mind. i fixed.
Using Tomcat with ISAPI Redirector
Hi, I'm using Apache Tomcat/5.5.4 with Plesk 8.2 on a Windows Server 2003 machine. The isapi redirector program is supposed to allow me to connect to my server, and redirect my request to Tomcat, if the url matches a certain pattern. I have multiple sites configured in IIS, including: PleskControlPanel and Default Web Site. Default Web Site was previously configured with a jakarta virtual directory that allows the isapi redirector to work properly. When I try to access http://www.example.com/examples, I find the tomcat error: HTTP Status 404 - /examples/ I configured PleskControlPanel (port 8880, ssl port 8443) to use a second jakarta virtual directory. However, when I try to access http://www.example.com:8880/examples, I find the tomcat error: HTTP Status 404 - /jakarta/isapi_redirect.dll Does anyone know why IIS would be passing the URI: /jakarta/isapi_redirect.dll to Tomcat at that point? Is there a way to configure IIS so that /jakarta/isapi_redirect.dll is resolved properly (as the filter, not the URI) and so that the next URI delivered to Tomcat is /examples/ ? Patrick - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Context or Mapping problems Apache 2.2 +mod_JK+ Tomcat 5.5
I think you forgot my question, I posted this question because I want to have a webapplication name/webaplicaiton/welcome.do different than the directory name (/webapps/booking). My Tomcat works if the URL is the same as directory name(or.war file). but i want to set up the Tomcat to have (webapplication) name different than directory name under webapps directory Thanks, MK On 7/24/08, Caldarale, Charles R [EMAIL PROTECTED] wrote: From: kohanm [mailto:[EMAIL PROTECTED] Subject: Re: Context or Mapping problems Apache 2.2 +mod_JK+ Tomcat 5.5 The context located : Tomcat 5.5\conf\Catalina\localhost\webapplication.xml and I modified as you mentioned: Context debug=5 reloadable=true crossContext=true --- /Context then I tried to check the Tomcat separately with it's port: http://localhost:*8080/booking*/welcome.do* it worked(* Tomcat5.5/webapps/booking*) .* ** and http://localhost:*8080/webapplication/welcome.dohttp://localh ost:8080/webapplication/welcome.do did not work.* ** So I think the Tomcat does not mapping to the Tomcat5.5/webapps/*booking* directory properly*.* You need to decide if your application is going to be reachable by the webapplication URI or the booking URI; choose one or the other, change the name of the Context .xml file to match, change the directory name (or .war file) for the application to match, and stick with *one* name. By trying to use both, you're just creating confusion. - Chuck THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY MATERIAL and is thus for use only by the intended recipient. If you received this in error, please contact the sender and delete the e-mail and its attachments from all computers. - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- Massoud - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Context or Mapping problems Apache 2.2 +mod_JK+ Tomcat 5.5
From: kohanm [mailto:[EMAIL PROTECTED] Subject: Re: Context or Mapping problems Apache 2.2 +mod_JK+ Tomcat 5.5 I want to have a webapplication name /webaplicaiton/welcome.do different than the directory name (/webapps/booking). O.k., I'll bite: why? That's now how Tomcat is designed to work. My Tomcat works if the URL is the same as directory name(or.war file). Which is as exactly how it's supposed to work. Just use one name, and don't make things more complicated than they need to be. - Chuck THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY MATERIAL and is thus for use only by the intended recipient. If you received this in error, please contact the sender and delete the e-mail and its attachments from all computers. - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Context or Mapping problems Apache 2.2 +mod_JK+ Tomcat 5.5
The webaplication is done now, but my boss asked me to change the name of URL webapplication. IF I change the directory name than there are many jsp pages with many links with old name's webapplication. On 7/24/08, Caldarale, Charles R [EMAIL PROTECTED] wrote: From: kohanm [mailto:[EMAIL PROTECTED] Subject: Re: Context or Mapping problems Apache 2.2 +mod_JK+ Tomcat 5.5 I want to have a webapplication name /webaplicaiton/welcome.do different than the directory name (/webapps/booking). O.k., I'll bite: why? That's now how Tomcat is designed to work. My Tomcat works if the URL is the same as directory name(or.war file). Which is as exactly how it's supposed to work. Just use one name, and don't make things more complicated than they need to be. - Chuck THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY MATERIAL and is thus for use only by the intended recipient. If you received this in error, please contact the sender and delete the e-mail and its attachments from all computers. - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- Massoud - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Context or Mapping problems Apache 2.2 +mod_JK+ Tomcat 5.5
From: kohanm [mailto:[EMAIL PROTECTED] Subject: Re: Context or Mapping problems Apache 2.2 +mod_JK+ Tomcat 5.5 The webaplication is done now, but my boss asked me to change the name of URL webapplication. IF I change the directory name than there are many jsp pages with many links with old name's webapplication. Now the true problem comes out - the webapp name is hardcoded within the webapp; that's extremely bad practice. I assume fixing those won't be an easy task. In this case, you're stuck with needing to deploy the webapp in the directory corresponding to the old name; there's no way around that. You can write a filter or valve in Tomcat that forwards or redirects all requests for the new name to the old one. You should also be able to do that with mod_jk directives, but someone else will have to help with that. - Chuck THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY MATERIAL and is thus for use only by the intended recipient. If you received this in error, please contact the sender and delete the e-mail and its attachments from all computers. - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Context or Mapping problems Apache 2.2 +mod_JK+ Tomcat 5.5
Then you should have written your webapp so all the links are computed based on the webapp's context. In jsps you can do this with: ${pageContext.request.contextPath}/webapp/relative/path.jsp In servlets, you can use request.getContextPath() to get the context path and then append your path on to it.. With that strategy, at most you'd have to alter links in static html files if the webapp has any. --David kohanm wrote: The webaplication is done now, but my boss asked me to change the name of URL webapplication. IF I change the directory name than there are many jsp pages with many links with old name's webapplication. On 7/24/08, Caldarale, Charles R [EMAIL PROTECTED] wrote: From: kohanm [mailto:[EMAIL PROTECTED] Subject: Re: Context or Mapping problems Apache 2.2 +mod_JK+ Tomcat 5.5 I want to have a webapplication name /webaplicaiton/welcome.do different than the directory name (/webapps/booking). O.k., I'll bite: why? That's now how Tomcat is designed to work. My Tomcat works if the URL is the same as directory name(or.war file). Which is as exactly how it's supposed to work. Just use one name, and don't make things more complicated than they need to be. - Chuck THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY MATERIAL and is thus for use only by the intended recipient. If you received this in error, please contact the sender and delete the e-mail and its attachments from all computers. - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Server.xml Host Configuration
I can see a couple of issues: 1. It's not recommended to have Context ... / elements in server.xml. It works, but not recommended. 2. The Host's appBase and context's docBase attributes cannot point to the same directory. It worked in older versions of tomcat, but that behavior was considered a bug and fixed. Typically the appBase is set to the parent of your webapp. In your case, I recommend creating a directory named ROOT in /var/www/mySitelocal_stage/philly and moving all the webapp's files and folders into it. Then remove the Context ... / element entirely from server.xml. --David Tomcat User6 wrote: I am facing a problem in my application with tld not found error. The absolute uri: http://www.mySite.com/tags-abc cannot be resolved in either web.xml or the jar files deployed with this application Here is my directory at server /var/www/mySitelocal_stage/philly (philly is my application root directory) Here is the taglib entry in web.xml file jsp-config taglib taglib-urihttp://www.mySite.com/tags-abc/taglib-uri taglib-location/WEB-INF/abc.tld/taglib-location /taglib /jsp-config My abc.tld is at /WEB-INF/ directory. when I try for first page with stage2.philly.mySite.com it works fine. No errors at all. But when I try http://stage2.philly.mySite.com/events/index.jsp; it gives me the error for tld. The absolute uri: http://www.mySite.com/tags-abc cannot be resolved in either web.xml or the jar files deployed with this application Both the first page's jsp and events/index.jsp is having the tld included as %@ taglib uri=http://www.mySite.com/tags-abc; prefix=app %. My home page is directly under /WEB-INF/ folder., where as for second URL I have /WEB-INF/events/index.jsp The atrange thing is, whe I try this application on my local machine, it works fine with both the URL. but on server it fails. I have server.xml entry on Server as below: Host name=stage2.philly.mySite.com appBase=/var/www/mySitelocal_stage/philly unpackWARs=true autoDeploy=false xmlValidation=false xmlNamespaceAware=false Aliasstage2.philly.mySite.com/Alias Alias192.168.1.166/Alias Alias207.97.248.156/Alias Context docBase=/var/www/mySitelocal_stage/philly path= / Valve className=org.apache.catalina.valves.AccessLogValve directory=logs prefix=www_phillymySite_com_log. suffix=.txt pattern=common resolveHosts=false/ /Host IT MUST BE CAUSING THAT. Please help me out with possible solutions for this problem. If you need anything else apart from this, then please let me know. Thank You, - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Context or Mapping problems Apache 2.2 +mod_JK+ Tomcat 5.5
In my first email I copied(short) the mod_jk configuration in httpd.conf file. Mk On 7/24/08, Caldarale, Charles R [EMAIL PROTECTED] wrote: From: kohanm [mailto:[EMAIL PROTECTED] Subject: Re: Context or Mapping problems Apache 2.2 +mod_JK+ Tomcat 5.5 The webaplication is done now, but my boss asked me to change the name of URL webapplication. IF I change the directory name than there are many jsp pages with many links with old name's webapplication. Now the true problem comes out - the webapp name is hardcoded within the webapp; that's extremely bad practice. I assume fixing those won't be an easy task. In this case, you're stuck with needing to deploy the webapp in the directory corresponding to the old name; there's no way around that. You can write a filter or valve in Tomcat that forwards or redirects all requests for the new name to the old one. You should also be able to do that with mod_jk directives, but someone else will have to help with that. - Chuck THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY MATERIAL and is thus for use only by the intended recipient. If you received this in error, please contact the sender and delete the e-mail and its attachments from all computers. - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- Massoud
Re: Context or Mapping problems Apache 2.2 +mod_JK+ Tomcat 5.5
Caldarale, Charles R schrieb: From: kohanm [mailto:[EMAIL PROTECTED] Subject: Re: Context or Mapping problems Apache 2.2 +mod_JK+ Tomcat 5.5 The webaplication is done now, but my boss asked me to change the name of URL webapplication. IF I change the directory name than there are many jsp pages with many links with old name's webapplication. Now the true problem comes out - the webapp name is hardcoded within the webapp; that's extremely bad practice. I assume fixing those won't be an easy task. In this case, you're stuck with needing to deploy the webapp in the directory corresponding to the old name; there's no way around that. You can write a filter or valve in Tomcat that forwards or redirects all requests for the new name to the old one. You should also be able to do that with mod_jk directives, but someone else will have to help with that. Someone else says: If your webapp sends out responses with absolute URLs containing the wrong application name, then there's no easy solution. Case 1: You only want to make the app reachable under the new name, but you don't care if users switch to the old name sometime during app use. That's easy, simply redirect from the new name to the old name with a Redirect or RedirectMatch in Apache httpd. Case 2: You accept occasional occurence of the old name in THE URLs, but it should be mostly th enew one. Deploy the webapp under the new name as Charles suggested. Add a RewriteRule to Apache httpd to redirect any URL of the from /oldapp/something to /newapp/something. Whenever Users click on an oldapp link, the request will be answered by the redirect and the URLs quickly get replaced by the newapp URLs in the browser window. Caution: there might be problems with redirects and POST requests. All in all that's more a hack. Case 3: The oldapp name is not contained in the body of responses, but only used in redirects coming from the webapp. Then you could try using mod_proxy, which allows to change the Location headers in redirects. Case 4: You don't allow any use of the old name and the old name is contained in links in response bodies. Then you dynamically need to patch the responses. This will be a hack. Have a look at either mod_substitute (httpd 2.2.8 or above, I think) or mod_proxy_html (note: mod_proxy_html != mod_proxy_http). Regards, Rainer - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Context or Mapping problems Apache 2.2 +mod_JK+ Tomcat 5.5
Hi, my case is Case 1: can you give me an example for Redirect or RedirectMatch thanks, MK Caldarale, Charles R schrieb: From: kohanm [mailto:[EMAIL PROTECTED] Subject: Re: Context or Mapping problems Apache 2.2 +mod_JK+ Tomcat 5.5 The webaplication is done now, but my boss asked me to change the name of URL webapplication. IF I change the directory name than there are many jsp pages with many links with old name's webapplication. Now the true problem comes out - the webapp name is hardcoded within the webapp; that's extremely bad practice. I assume fixing those won't be an easy task. In this case, you're stuck with needing to deploy the webapp in the directory corresponding to the old name; there's no way around that. You can write a filter or valve in Tomcat that forwards or redirects all requests for the new name to the old one. You should also be able to do that with mod_jk directives, but someone else will have to help with that. Someone else says: If your webapp sends out responses with absolute URLs containing the wrong application name, then there's no easy solution. Case 1: You only want to make the app reachable under the new name, but you don't care if users switch to the old name sometime during app use. That's easy, simply redirect from the new name to the old name with a Redirect or RedirectMatch in Apache httpd. Case 2: You accept occasional occurence of the old name in THE URLs, but it should be mostly th enew one. Deploy the webapp under the new name as Charles suggested. Add a RewriteRule to Apache httpd to redirect any URL of the from /oldapp/something to /newapp/something. Whenever Users click on an oldapp link, the request will be answered by the redirect and the URLs quickly get replaced by the newapp URLs in the browser window. Caution: there might be problems with redirects and POST requests. All in all that's more a hack. Case 3: The oldapp name is not contained in the body of responses, but only used in redirects coming from the webapp. Then you could try using mod_proxy, which allows to change the Location headers in redirects. Case 4: You don't allow any use of the old name and the old name is contained in links in response bodies. Then you dynamically need to patch the responses. This will be a hack. Have a look at either mod_substitute (httpd 2.2.8 or above, I think) or mod_proxy_html (note: mod_proxy_html != mod_proxy_http). Regards, Rainer - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- Massoud
Question HTTP Status 408
I am getting an error since upgrading my production server to 6.0.16. Error message: 408 The time allowed for the login prosess has been exceeded 1. This is only happening with mobile devices (Blackberry Symbol Windows mobile 5) 2. The production server was working at 6.0.13. The development server had exhibited this error but I thought it was due to a slower system. 3. Login actually completes and server log shows messages in the application. 4. It does it with jdbc and jaas realms but not UserDataBase realm. It was working with the others before. Is there a configuration setting that relates to this? Is this a know bug and if so is there a patch available? Regards. - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Context or Mapping problems Apache 2.2 +mod_JK+ Tomcat 5.5
kohanm schrieb: Hi, my case is Case 1: can you give me an example for Redirect or RedirectMatch Simplest case: Redirect /oldapp http://myserver/newapp More details at http://httpd.apache.org/docs/2.2/mod/mod_alias.html#redirect Regards, Rainer thanks, MK Caldarale, Charles R schrieb: From: kohanm [mailto:[EMAIL PROTECTED] Subject: Re: Context or Mapping problems Apache 2.2 +mod_JK+ Tomcat 5.5 The webaplication is done now, but my boss asked me to change the name of URL webapplication. IF I change the directory name than there are many jsp pages with many links with old name's webapplication. Now the true problem comes out - the webapp name is hardcoded within the webapp; that's extremely bad practice. I assume fixing those won't be an easy task. In this case, you're stuck with needing to deploy the webapp in the directory corresponding to the old name; there's no way around that. You can write a filter or valve in Tomcat that forwards or redirects all requests for the new name to the old one. You should also be able to do that with mod_jk directives, but someone else will have to help with that. Someone else says: If your webapp sends out responses with absolute URLs containing the wrong application name, then there's no easy solution. Case 1: You only want to make the app reachable under the new name, but you don't care if users switch to the old name sometime during app use. That's easy, simply redirect from the new name to the old name with a Redirect or RedirectMatch in Apache httpd. Case 2: You accept occasional occurence of the old name in THE URLs, but it should be mostly th enew one. Deploy the webapp under the new name as Charles suggested. Add a RewriteRule to Apache httpd to redirect any URL of the from /oldapp/something to /newapp/something. Whenever Users click on an oldapp link, the request will be answered by the redirect and the URLs quickly get replaced by the newapp URLs in the browser window. Caution: there might be problems with redirects and POST requests. All in all that's more a hack. Case 3: The oldapp name is not contained in the body of responses, but only used in redirects coming from the webapp. Then you could try using mod_proxy, which allows to change the Location headers in redirects. Case 4: You don't allow any use of the old name and the old name is contained in links in response bodies. Then you dynamically need to patch the responses. This will be a hack. Have a look at either mod_substitute (httpd 2.2.8 or above, I think) or mod_proxy_html (note: mod_proxy_html != mod_proxy_http). Regards, Rainer - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Down the rabbit hole with JDBC
Sorry - I've been slogging through this... Anyway, I'm trying to get an application working, but all of their documentation talks about is tomcat5.5 and I've got tomcat6 I have gotten the latest Connector/J binary from MySQL and installed in into tomcat/lib but I would like to test it. So, I went to http://tomcat.apache.org/tomcat-6.0-doc/jndi-datasource-examples-howto.html and followed the instructions to set up a DBTest - but I get this HTTP Status 500 - type Exception report message description The server encountered an internal error () that prevented it from fulfilling this request. exception org.apache.jasper.JasperException: The absolute uri: http://java.sun.com/jsp/jstl/sql cannot be resolved in either web.xml or the jar files deployed with this application org.apache.jasper.compiler.DefaultErrorHandler.jspError(DefaultErrorHandler.java:51) org.apache.jasper.compiler.ErrorDispatcher.dispatch(ErrorDispatcher.java:409) org.apache.jasper.compiler.ErrorDispatcher.jspError(ErrorDispatcher.java:116) org.apache.jasper.compiler.TagLibraryInfoImpl.generateTLDLocation(TagLibraryInfoImpl.java:315) org.apache.jasper.compiler.TagLibraryInfoImpl.init(TagLibraryInfoImpl.java:148) org.apache.jasper.compiler.Parser.parseTaglibDirective(Parser.java:420) org.apache.jasper.compiler.Parser.parseDirective(Parser.java:483) org.apache.jasper.compiler.Parser.parseElements(Parser.java:1433) org.apache.jasper.compiler.Parser.parse(Parser.java:133) org.apache.jasper.compiler.ParserController.doParse(ParserController.java:216) org.apache.jasper.compiler.ParserController.parse(ParserController.java:103) org.apache.jasper.compiler.Compiler.generateJava(Compiler.java:153) org.apache.jasper.compiler.Compiler.compile(Compiler.java:314) org.apache.jasper.compiler.Compiler.compile(Compiler.java:294) org.apache.jasper.compiler.Compiler.compile(Compiler.java:281) org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.java:566) org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:317) org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:337) org.apache.jasper.servlet.JspServlet.service(JspServlet.java:266) javax.servlet.http.HttpServlet.service(HttpServlet.java:803) Here's the code that I'm running - are the taglibs incorrect? %@ taglib uri=http://java.sun.com/jsp/jstl/sql; prefix=sql % %@ taglib uri=http://java.sun.com/jsp/jstl/core; prefix=c % sql:query var=rs dataSource=jdbc/TestDB select id, foo, bar from testdata /sql:query html head titleDB Test/title /head body h2Results/h2 c:forEach var=row items=${rs.rows} Foo ${row.foo}br/ Bar ${row.bar}br/ /c:forEach /body /html Matt Burkhardt, MSTM President Impari Systems, Inc. 401 Rosemont Avenue Frederick, MD 21701 [EMAIL PROTECTED] www.imparisystems.com (301) 644-3911
Re: Context or Mapping problems Apache 2.2 +mod_JK+ Tomcat 5.5
Thanks Rainer, The probelm here is that after redirecting, the URL shows the oldapp's name but I want the url shows the newapp name. MK On 7/24/08, Rainer Jung [EMAIL PROTECTED] wrote: kohanm schrieb: Hi, my case is Case 1: can you give me an example for Redirect or RedirectMatch Simplest case: Redirect /oldapp http://myserver/newapp More details at http://httpd.apache.org/docs/2.2/mod/mod_alias.html#redirect Regards, Rainer thanks, MK Caldarale, Charles R schrieb: From: kohanm [mailto:[EMAIL PROTECTED] Subject: Re: Context or Mapping problems Apache 2.2 +mod_JK+ Tomcat 5.5 The webaplication is done now, but my boss asked me to change the name of URL webapplication. IF I change the directory name than there are many jsp pages with many links with old name's webapplication. Now the true problem comes out - the webapp name is hardcoded within the webapp; that's extremely bad practice. I assume fixing those won't be an easy task. In this case, you're stuck with needing to deploy the webapp in the directory corresponding to the old name; there's no way around that. You can write a filter or valve in Tomcat that forwards or redirects all requests for the new name to the old one. You should also be able to do that with mod_jk directives, but someone else will have to help with that. Someone else says: If your webapp sends out responses with absolute URLs containing the wrong application name, then there's no easy solution. Case 1: You only want to make the app reachable under the new name, but you don't care if users switch to the old name sometime during app use. That's easy, simply redirect from the new name to the old name with a Redirect or RedirectMatch in Apache httpd. Case 2: You accept occasional occurence of the old name in THE URLs, but it should be mostly th enew one. Deploy the webapp under the new name as Charles suggested. Add a RewriteRule to Apache httpd to redirect any URL of the from /oldapp/something to /newapp/something. Whenever Users click on an oldapp link, the request will be answered by the redirect and the URLs quickly get replaced by the newapp URLs in the browser window. Caution: there might be problems with redirects and POST requests. All in all that's more a hack. Case 3: The oldapp name is not contained in the body of responses, but only used in redirects coming from the webapp. Then you could try using mod_proxy, which allows to change the Location headers in redirects. Case 4: You don't allow any use of the old name and the old name is contained in links in response bodies. Then you dynamically need to patch the responses. This will be a hack. Have a look at either mod_substitute (httpd 2.2.8 or above, I think) or mod_proxy_html (note: mod_proxy_html != mod_proxy_http). Regards, Rainer - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- Massoud - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Solved: Question HTTP Status 408
It was a weird one. My index.jsp. It was taking too long to complete filling in a select from database values. After I streamlined the select process the page was loaded in enough time. Funny that it would masquerade as a login error. On Thu, 2008-07-24 at 15:08 -0500, Jq wrote: I am getting an error since upgrading my production server to 6.0.16. Error message: 408 The time allowed for the login prosess has been exceeded 1. This is only happening with mobile devices (Blackberry Symbol Windows mobile 5) 2. The production server was working at 6.0.13. The development server had exhibited this error but I thought it was due to a slower system. 3. Login actually completes and server log shows messages in the application. 4. It does it with jdbc and jaas realms but not UserDataBase realm. It was working with the others before. Is there a configuration setting that relates to this? Is this a know bug and if so is there a patch available? Regards. - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Context or Mapping problems Apache 2.2 +mod_JK+ Tomcat 5.5
kohanm schrieb: Thanks Rainer, The probelm here is that after redirecting, the URL shows the oldapp's name but I want the url shows the newapp name. Then it is not case 1 and you need to pick another case. MK On 7/24/08, Rainer Jung [EMAIL PROTECTED] wrote: kohanm schrieb: Hi, my case is Case 1: can you give me an example for Redirect or RedirectMatch Simplest case: Redirect /oldapp http://myserver/newapp More details at http://httpd.apache.org/docs/2.2/mod/mod_alias.html#redirect Regards, Rainer thanks, MK Caldarale, Charles R schrieb: From: kohanm [mailto:[EMAIL PROTECTED] Subject: Re: Context or Mapping problems Apache 2.2 +mod_JK+ Tomcat 5.5 The webaplication is done now, but my boss asked me to change the name of URL webapplication. IF I change the directory name than there are many jsp pages with many links with old name's webapplication. Now the true problem comes out - the webapp name is hardcoded within the webapp; that's extremely bad practice. I assume fixing those won't be an easy task. In this case, you're stuck with needing to deploy the webapp in the directory corresponding to the old name; there's no way around that. You can write a filter or valve in Tomcat that forwards or redirects all requests for the new name to the old one. You should also be able to do that with mod_jk directives, but someone else will have to help with that. Someone else says: If your webapp sends out responses with absolute URLs containing the wrong application name, then there's no easy solution. Case 1: You only want to make the app reachable under the new name, but you don't care if users switch to the old name sometime during app use. That's easy, simply redirect from the new name to the old name with a Redirect or RedirectMatch in Apache httpd. Case 2: You accept occasional occurence of the old name in THE URLs, but it should be mostly th enew one. Deploy the webapp under the new name as Charles suggested. Add a RewriteRule to Apache httpd to redirect any URL of the from /oldapp/something to /newapp/something. Whenever Users click on an oldapp link, the request will be answered by the redirect and the URLs quickly get replaced by the newapp URLs in the browser window. Caution: there might be problems with redirects and POST requests. All in all that's more a hack. Case 3: The oldapp name is not contained in the body of responses, but only used in redirects coming from the webapp. Then you could try using mod_proxy, which allows to change the Location headers in redirects. Case 4: You don't allow any use of the old name and the old name is contained in links in response bodies. Then you dynamically need to patch the responses. This will be a hack. Have a look at either mod_substitute (httpd 2.2.8 or above, I think) or mod_proxy_html (note: mod_proxy_html != mod_proxy_http). Regards, Rainer - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Context or Mapping problems Apache 2.2 +mod_JK+ Tomcat 5.5
Sorry you are right it's case2 or case3. Anyway I give up at this point. I will change the link code of jsp pages with new name. Thanks Rainer. MK On 7/24/08, Rainer Jung [EMAIL PROTECTED] wrote: kohanm schrieb: Thanks Rainer, The probelm here is that after redirecting, the URL shows the oldapp's name but I want the url shows the newapp name. Then it is not case 1 and you need to pick another case. MK On 7/24/08, Rainer Jung [EMAIL PROTECTED] wrote: kohanm schrieb: Hi, my case is Case 1: can you give me an example for Redirect or RedirectMatch Simplest case: Redirect /oldapp http://myserver/newapp More details at http://httpd.apache.org/docs/2.2/mod/mod_alias.html#redirect Regards, Rainer thanks, MK Caldarale, Charles R schrieb: From: kohanm [mailto:[EMAIL PROTECTED] Subject: Re: Context or Mapping problems Apache 2.2 +mod_JK+ Tomcat 5.5 The webaplication is done now, but my boss asked me to change the name of URL webapplication. IF I change the directory name than there are many jsp pages with many links with old name's webapplication. Now the true problem comes out - the webapp name is hardcoded within the webapp; that's extremely bad practice. I assume fixing those won't be an easy task. In this case, you're stuck with needing to deploy the webapp in the directory corresponding to the old name; there's no way around that. You can write a filter or valve in Tomcat that forwards or redirects all requests for the new name to the old one. You should also be able to do that with mod_jk directives, but someone else will have to help with that. Someone else says: If your webapp sends out responses with absolute URLs containing the wrong application name, then there's no easy solution. Case 1: You only want to make the app reachable under the new name, but you don't care if users switch to the old name sometime during app use. That's easy, simply redirect from the new name to the old name with a Redirect or RedirectMatch in Apache httpd. Case 2: You accept occasional occurence of the old name in THE URLs, but it should be mostly th enew one. Deploy the webapp under the new name as Charles suggested. Add a RewriteRule to Apache httpd to redirect any URL of the from /oldapp/something to /newapp/something. Whenever Users click on an oldapp link, the request will be answered by the redirect and the URLs quickly get replaced by the newapp URLs in the browser window. Caution: there might be problems with redirects and POST requests. All in all that's more a hack. Case 3: The oldapp name is not contained in the body of responses, but only used in redirects coming from the webapp. Then you could try using mod_proxy, which allows to change the Location headers in redirects. Case 4: You don't allow any use of the old name and the old name is contained in links in response bodies. Then you dynamically need to patch the responses. This will be a hack. Have a look at either mod_substitute (httpd 2.2.8 or above, I think) or mod_proxy_html (note: mod_proxy_html != mod_proxy_http). Regards, Rainer - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- Massoud - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Down the rabbit hole with JDBC
This isn't a JDBC error as much as it's a taglib error. You are trying to use JSTL taglibs in your web application and tomcat can't find the libraries that contain the taglib. Things to check: 1. standard.jar and jstl.jar are in the webapp's WEB-INF/lib directory -- at least for jstl 1.1. I believe jstl 1.2 consolidated things into one jar file. 2. The webapp's docBase is not the same as the Host ... element's appBase attribute in server.xml. This has already bitten one person on the list today. --David Matt Burkhardt wrote: Sorry - I've been slogging through this... Anyway, I'm trying to get an application working, but all of their documentation talks about is tomcat5.5 and I've got tomcat6 I have gotten the latest Connector/J binary from MySQL and installed in into tomcat/lib but I would like to test it. So, I went to http://tomcat.apache.org/tomcat-6.0-doc/jndi-datasource-examples-howto.html and followed the instructions to set up a DBTest - but I get this HTTP Status 500 - type Exception report message description The server encountered an internal error () that prevented it from fulfilling this request. exception org.apache.jasper.JasperException: The absolute uri: http://java.sun.com/jsp/jstl/sql cannot be resolved in either web.xml or the jar files deployed with this application org.apache.jasper.compiler.DefaultErrorHandler.jspError(DefaultErrorHandler.java:51) org.apache.jasper.compiler.ErrorDispatcher.dispatch(ErrorDispatcher.java:409) org.apache.jasper.compiler.ErrorDispatcher.jspError(ErrorDispatcher.java:116) org.apache.jasper.compiler.TagLibraryInfoImpl.generateTLDLocation(TagLibraryInfoImpl.java:315) org.apache.jasper.compiler.TagLibraryInfoImpl.init(TagLibraryInfoImpl.java:148) org.apache.jasper.compiler.Parser.parseTaglibDirective(Parser.java:420) org.apache.jasper.compiler.Parser.parseDirective(Parser.java:483) org.apache.jasper.compiler.Parser.parseElements(Parser.java:1433) org.apache.jasper.compiler.Parser.parse(Parser.java:133) org.apache.jasper.compiler.ParserController.doParse(ParserController.java:216) org.apache.jasper.compiler.ParserController.parse(ParserController.java:103) org.apache.jasper.compiler.Compiler.generateJava(Compiler.java:153) org.apache.jasper.compiler.Compiler.compile(Compiler.java:314) org.apache.jasper.compiler.Compiler.compile(Compiler.java:294) org.apache.jasper.compiler.Compiler.compile(Compiler.java:281) org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.java:566) org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:317) org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:337) org.apache.jasper.servlet.JspServlet.service(JspServlet.java:266) javax.servlet.http.HttpServlet.service(HttpServlet.java:803) Here's the code that I'm running - are the taglibs incorrect? %@ taglib uri=http://java.sun.com/jsp/jstl/sql; prefix=sql % %@ taglib uri=http://java.sun.com/jsp/jstl/core; prefix=c % sql:query var=rs dataSource=jdbc/TestDB select id, foo, bar from testdata /sql:query html head titleDB Test/title /head body h2Results/h2 c:forEach var=row items=${rs.rows} Foo ${row.foo}br/ Bar ${row.bar}br/ /c:forEach /body /html Matt Burkhardt, MSTM President Impari Systems, Inc. 401 Rosemont Avenue Frederick, MD 21701 [EMAIL PROTECTED] www.imparisystems.com (301) 644-3911 - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Tomcat 5.5 -- Enabling of Certain Characters in URLs [Take 2]
Hi, Yikes! I noticed that I had an abundance of typos in my post. Let me try to re-post in something closer to English. Here it goes:I am currently running the open source webapp eXist (http://exist.sourceforge.net/) on Tomcat 5.5. It works well with the exception of the following glitch: accessing URLs containing ( or , characters generates a 404 document not found message. I've tried encoding these URLs with %29 and other encodings, but that doesn't help. Are there any settings in the conf files that can be enabled to allow ( or , in URLs preferably without encoding? In looking through the mailing list archives, I noticed that there is a DecodeInterceptor safe=false setting that can be enabled (or added and then enabled?) to allow certain characters in URLs. So my question is this: what needs to be added or enabled in Tomcat 5.5 to allow characters such as ( or , in URLs? ? Thanks,Greg ? ? -Original Message- From: [EMAIL PROTECTED] To: users@tomcat.apache.org Sent: Thu, 24 Jul 2008 12:36 pm Subject: Tomcat 5.5 -- Enabling of Certain Characters in URLs Hi,Currently running the open source webapp eXist (http://exist.sourceforge.net/) on Tomcat 5.5. It works wellexpect for this glitch: in trying to access file names containing ( or , characters, Tomcat generates a 404 document not found message. I've tried encoding these with %29 and other encodings, but that doesn't help. Is there a setting in the conf files that can be enabled to allow ( or , in URLs preferably without encoding? In looking through the mailing list archives (see http://mail-archives.apache.org/mod_mbox/tomcat-dev/200109.mbox/[EMAIL PROTECTED]), I noticed that there is a lt;DecodeInterceptor safe=false /gt; setting, but I don't know if that's part of Tomcat 5.5 or if it is, can it have to be added, and if to which file and where in the conf files? Or is there another setting that can be added/enabled?Thanks,Greg?
Retrieving tomcat log files within war
Is there a way to programmically retrieve the tomcat log files? I can reconstruct the log location by doing a new File(System.getProperty(catalina.base)), logFileIwant ) but I'm wondering if there's a better way... Anyone had any experience with doing this?
Re: Down the rabbit hole with JDBC
Thanks - it was the first - I just had the files in the WEB-INF directory - not in the lib Is there some method for finding errors / logs? Right now, I'm trying to get an application running, and I'm just guessing. For example, my catalina.log file says INFO: The listener org.alfresco.web.app.ContextListener is already configured for this context. The duplicate definition has been ignored. Jul 24, 2008 3:46:11 PM org.apache.catalina.core.StandardContext start SEVERE: Error listenerStart Jul 24, 2008 3:46:11 PM org.apache.catalina.core.StandardContext start SEVERE: Context [/alfresco] startup failed due to previous errors Where can I go to find out what's causing this? On Thu, 2008-07-24 at 17:41 -0400, David Smith wrote: This isn't a JDBC error as much as it's a taglib error. You are trying to use JSTL taglibs in your web application and tomcat can't find the libraries that contain the taglib. Things to check: 1. standard.jar and jstl.jar are in the webapp's WEB-INF/lib directory -- at least for jstl 1.1. I believe jstl 1.2 consolidated things into one jar file. 2. The webapp's docBase is not the same as the Host ... element's appBase attribute in server.xml. This has already bitten one person on the list today. --David Matt Burkhardt wrote: Sorry - I've been slogging through this... Anyway, I'm trying to get an application working, but all of their documentation talks about is tomcat5.5 and I've got tomcat6 I have gotten the latest Connector/J binary from MySQL and installed in into tomcat/lib but I would like to test it. So, I went to http://tomcat.apache.org/tomcat-6.0-doc/jndi-datasource-examples-howto.html and followed the instructions to set up a DBTest - but I get this HTTP Status 500 - type Exception report message description The server encountered an internal error () that prevented it from fulfilling this request. exception org.apache.jasper.JasperException: The absolute uri: http://java.sun.com/jsp/jstl/sql cannot be resolved in either web.xml or the jar files deployed with this application org.apache.jasper.compiler.DefaultErrorHandler.jspError(DefaultErrorHandler.java:51) org.apache.jasper.compiler.ErrorDispatcher.dispatch(ErrorDispatcher.java:409) org.apache.jasper.compiler.ErrorDispatcher.jspError(ErrorDispatcher.java:116) org.apache.jasper.compiler.TagLibraryInfoImpl.generateTLDLocation(TagLibraryInfoImpl.java:315) org.apache.jasper.compiler.TagLibraryInfoImpl.init(TagLibraryInfoImpl.java:148) org.apache.jasper.compiler.Parser.parseTaglibDirective(Parser.java:420) org.apache.jasper.compiler.Parser.parseDirective(Parser.java:483) org.apache.jasper.compiler.Parser.parseElements(Parser.java:1433) org.apache.jasper.compiler.Parser.parse(Parser.java:133) org.apache.jasper.compiler.ParserController.doParse(ParserController.java:216) org.apache.jasper.compiler.ParserController.parse(ParserController.java:103) org.apache.jasper.compiler.Compiler.generateJava(Compiler.java:153) org.apache.jasper.compiler.Compiler.compile(Compiler.java:314) org.apache.jasper.compiler.Compiler.compile(Compiler.java:294) org.apache.jasper.compiler.Compiler.compile(Compiler.java:281) org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.java:566) org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:317) org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:337) org.apache.jasper.servlet.JspServlet.service(JspServlet.java:266) javax.servlet.http.HttpServlet.service(HttpServlet.java:803) Here's the code that I'm running - are the taglibs incorrect? %@ taglib uri=http://java.sun.com/jsp/jstl/sql; prefix=sql % %@ taglib uri=http://java.sun.com/jsp/jstl/core; prefix=c % sql:query var=rs dataSource=jdbc/TestDB select id, foo, bar from testdata /sql:query html head titleDB Test/title /head body h2Results/h2 c:forEach var=row items=${rs.rows} Foo ${row.foo}br/ Bar ${row.bar}br/ /c:forEach /body /html Matt Burkhardt, MSTM President Impari Systems, Inc. 401 Rosemont Avenue Frederick, MD 21701 [EMAIL PROTECTED] www.imparisystems.com (301) 644-3911 - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] Matt Burkhardt, MSTM President Impari Systems, Inc. 401 Rosemont Avenue Frederick, MD 21701 [EMAIL PROTECTED] www.imparisystems.com (301) 644-3911
RE: Down the rabbit hole with JDBC
From: Matt Burkhardt [mailto:[EMAIL PROTECTED] Subject: Re: Down the rabbit hole with JDBC INFO: The listener org.alfresco.web.app.ContextListener is already configured for this context. The duplicate definition has been ignored. The above is a cosmetic error in 6.0.16; it does no damage and is fixed in 6.0.17. Jul 24, 2008 3:46:11 PM org.apache.catalina.core.StandardContext start SEVERE: Context [/alfresco] startup failed due to previous errors There should be a more explanatory message further down in the catalina.log. You may also find some useful data in localhost.log (or whatever your Host name is). - Chuck THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY MATERIAL and is thus for use only by the intended recipient. If you received this in error, please contact the sender and delete the e-mail and its attachments from all computers. - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Down the rabbit hole with JDBC
Matt, If you don't find anything suggestive in the logs, try running with a debugger and put a breakpoint on the first statement in the contextInitialized method in your AppListener to try to track down why it's dying (i.e., what's causing SEVERE: Error listenerStart). Then start steppting through. You should be able to determine what the application listenters are (there may be more than one) by going to WEB-INF\web.xml and looking for the declarations listener- classpath.to.class/listener-class. Ken On Jul 24, 2008, at 6:26 PM, Matt Burkhardt wrote: Thanks - it was the first - I just had the files in the WEB-INF directory - not in the lib Is there some method for finding errors / logs? Right now, I'm trying to get an application running, and I'm just guessing. For example, my catalina.log file says INFO: The listener org.alfresco.web.app.ContextListener is already configured for this context. The duplicate definition has been ignored. Jul 24, 2008 3:46:11 PM org.apache.catalina.core.StandardContext start SEVERE: Error listenerStart Jul 24, 2008 3:46:11 PM org.apache.catalina.core.StandardContext start SEVERE: Context [/alfresco] startup failed due to previous errors Where can I go to find out what's causing this? On Thu, 2008-07-24 at 17:41 -0400, David Smith wrote: This isn't a JDBC error as much as it's a taglib error. You are trying to use JSTL taglibs in your web application and tomcat can't find the libraries that contain the taglib. Things to check: 1. standard.jar and jstl.jar are in the webapp's WEB-INF/lib directory -- at least for jstl 1.1. I believe jstl 1.2 consolidated things into one jar file. 2. The webapp's docBase is not the same as the Host ... element's appBase attribute in server.xml. This has already bitten one person on the list today. --David Matt Burkhardt wrote: Sorry - I've been slogging through this... Anyway, I'm trying to get an application working, but all of their documentation talks about is tomcat5.5 and I've got tomcat6 I have gotten the latest Connector/J binary from MySQL and installed in into tomcat/lib but I would like to test it. So, I went to http://tomcat.apache.org/tomcat-6.0-doc/jndi-datasource-examples-howto.html and followed the instructions to set up a DBTest - but I get this HTTP Status 500 - type Exception report message description The server encountered an internal error () that prevented it from fulfilling this request. exception org.apache.jasper.JasperException: The absolute uri: http://java.sun.com/jsp/jstl/sql cannot be resolved in either web.xml or the jar files deployed with this application org .apache .jasper .compiler.DefaultErrorHandler.jspError(DefaultErrorHandler.java:51) org .apache .jasper.compiler.ErrorDispatcher.dispatch(ErrorDispatcher.java:409) org .apache .jasper.compiler.ErrorDispatcher.jspError(ErrorDispatcher.java:116) org .apache .jasper .compiler .TagLibraryInfoImpl.generateTLDLocation(TagLibraryInfoImpl.java:315) org .apache .jasper.compiler.TagLibraryInfoImpl.init(TagLibraryInfoImpl.java: 148) org.apache.jasper.compiler.Parser.parseTaglibDirective(Parser.java: 420) org.apache.jasper.compiler.Parser.parseDirective(Parser.java:483) org.apache.jasper.compiler.Parser.parseElements(Parser.java:1433) org.apache.jasper.compiler.Parser.parse(Parser.java:133) org .apache .jasper.compiler.ParserController.doParse(ParserController.java:216) org .apache .jasper.compiler.ParserController.parse(ParserController.java:103) org.apache.jasper.compiler.Compiler.generateJava(Compiler.java:153) org.apache.jasper.compiler.Compiler.compile(Compiler.java:314) org.apache.jasper.compiler.Compiler.compile(Compiler.java:294) org.apache.jasper.compiler.Compiler.compile(Compiler.java:281) org .apache .jasper.JspCompilationContext.compile(JspCompilationContext.java: 566) org .apache .jasper.servlet.JspServletWrapper.service(JspServletWrapper.java: 317) org .apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java: 337) org.apache.jasper.servlet.JspServlet.service(JspServlet.java:266) javax.servlet.http.HttpServlet.service(HttpServlet.java:803) Here's the code that I'm running - are the taglibs incorrect? %@ taglib uri=http://java.sun.com/jsp/jstl/sql; prefix=sql % %@ taglib uri=http://java.sun.com/jsp/jstl/core; prefix=c % sql:query var=rs dataSource=jdbc/TestDB select id, foo, bar from testdata /sql:query html head titleDB Test/title /head body h2Results/h2 c:forEach var=row items=${rs.rows} Foo ${row.foo}br/ Bar ${row.bar}br/ /c:forEach /body /html Matt Burkhardt, MSTM President Impari Systems, Inc. 401 Rosemont Avenue Frederick, MD 21701 [EMAIL PROTECTED] www.imparisystems.com (301) 644-3911