RE: Using XInclude in tomcat's config files
-Original Message- From: Shankar Unni Try an entity instead of xinclude? Not many parsers are good for xinclude as yet (a mainly uninformed statement). Entity resolution is easier if the parser is setup correctly. Oh, that's what we are doing now, but entity resolution doesn't have a concept of relative paths. Does your parser support xml:base? That makes relative paths work. All in all, entity includes are inflexible and a terrific pain to work with. Its an alternative. regards DaveP -- DISCLAIMER: NOTICE: The information contained in this email and any attachments is confidential and may be privileged. If you are not the intended recipient you should not use, disclose, distribute or copy any of the content of it or of any attachment; you are requested to notify the sender immediately of your receipt of the email and then to delete it and any attachments from your system. RNIB endeavours to ensure that emails and any attachments generated by its staff are free from viruses or other contaminants. However, it cannot accept any responsibility for any such which are transmitted. We therefore recommend you scan all attachments. Please note that the statements and views expressed in this email and any attachments are those of the author and do not necessarily represent those of RNIB. RNIB Registered Charity Number: 226227 Website: http://www.rnib.org.uk - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: servlet deployed, but Tomcat provides .war file for download only
Actually I have the same problem. I can deploy expanded web apps no probs, but I've never been able to deploy a WAR... browser always wants to download it. Is there a TC setting that tells it to deploy WARs? Shapira, Yoav [EMAIL PROTECTED] 5/10/2004 2:32:20 am Hi, Oh, it's very definitely a special case ;) If the examples didn't work for 99.9% of Tomcat users, we'd have heard about it loudly and clearly by now. That's based on actual experience, not just hypothesis ;) Yoav Shapira Millennium Research Informatics -Original Message- From: Christian Ruediger [ mailto:[EMAIL PROTECTED] Sent: Monday, October 04, 2004 12:27 PM To: Tomcat Users List Subject: Re: servlet deployed, but Tomcat provides .war file for download only Thank you so far, in case i find that the examples dont work on my system, whom could I anounce the prevent others from serching to long: Perhaps with a little comment in the Readme. Or should I see it as it is: a special case. Bye Christian On Mon, 4 Oct 2004 12:19:54 -0400, Shapira, Yoav [EMAIL PROTECTED] wrote: Hi, Actually i used the launcher, 'cause the .bat script has some errors while calling javac (I haven't tried to fix this yet). Address those before going further. You should be able to launch Tomcat using startup.bat on Windows out of the box. If not, something serious is wrong. There is, as follows an XML parser error in the stdout.log file instruction target matching [xX][mM][lL] is not allowed. org.xml.sax.SAXParseException: The processing instruction target You have one messed-up configuration ;) I'm assuming that the examples and other default web applications that ship with Tomcat are not working? It's not just your webapp or just your servlet. 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] 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.
Re: Search engine friendly URLs
There's a filter that does URL rewriting already, urlrewrite , mod_rewrite would be okay but who wants to run mod_jk - apache as his/her development environments. http://tuckey.org/urlrewrite/ The only problem then is generating the links. I think the original question was posted on the struts group the other day and that he's using html:link tags. I'd change these for jstl for the links. so rather than html:link page=/action.do .. you'd use something like.. c:url var=link value=/action.do c:param name=name value=somevalue / .. and so on /c:url this will render to /appname/action.do?name=somevalue so now lets say you've set a boolean called cleanURL, this means you can switch the functionality off if you want to deactivated urlrewrite during development. An init param in web.xml i suggest would be the best place, but for now lets set in the page. c:set var=cleanURL value=true /' c:if test=${cleanURL} c:forTokens var=badChar items=?, delims=, c:set var=cleanLink value=${fn:replace(link,badChar,'/'}'' / c:set var=link value=${cleanLink} / /c:forTokens /c:if a href=${link}Link/a Once you've set urlrewrite filter up you'll want something like this. rule from/action.do/*/*/from to type=redirect/action.do?$1=$2/to /rule HTH Mark On 4 Oct 2004, at 15:04, Shapira, Yoav wrote: Hi, You can also do this with one (or more, if you want, depending on the exact requirements) Filters. That prevents the need for a separate servlet and any associated session overhead, so the performance argument is even more moot. Yoav Shapira Millennium Research Informatics -Original Message- From: Steffen Heil [mailto:[EMAIL PROTECTED] Sent: Sunday, October 03, 2004 11:18 AM To: 'Tomcat Users List' Subject: AW: Search engine friendly URLs Hi If you want to be able to scale your application, you need to be able to move the static image handling out of tomcat to a separate web server. Using Tomcat to handle both application chores and web serving chores will limit the overall scalability of your system. I strongly disagree. Tomcat is nearly as fast as apache in serving images. So, yes, you can save a little time using apache, BUT remeber that the apache slows tomcat down. You need cpu-cycles for apache, for mod_jk and additionally for tomcat. Those cycles for apache and mod_jk are not nessesary, since tomcat can work standalone. So the question comes down to decide wether the overhead of handling apache and mod_jk for dynamic content is smaller then the difference of apache and tomcat in serving images. I guess with current versions of tomcat the overhead to apache and mod_jk is even bigger. Hence, tomcat alone will be faster. (Please also consider, that static content will mostly be taken from the browsers cache, whereas dynamic content needs to be received from tomcat. That means that the time won by using apache for static content needs to be a magnitude higher than the overhead of mod_jk. That's simply not the case.) Tomcat cannot do rewriting, that is correct, but it does not need to: I use url such as: /content/pages/test.htm where content is mapped to my servlet. The parameter is simply the rest of the url. You could do: http://localhost/site.do/books/architecture and parse the rest of the url to section = books and subsection = architecture Simply map site.do to your servlet. Reagrds, Steffen 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: servlet deployed, but Tomcat provides .war file for download only
I solved my problem: The cause is quite simple: I deleted the leading whitespace from my web.xml file. The lesson I learned: VALIDATE your xml files before using them. Here is an online checker in case you need one: http://www.stg.brown.edu/service/xmlvalid/ May the rest of the community never encounter a problem like this again. Bye Christian On Tue, 05 Oct 2004 17:21:27 +1000, Aziz Yacoub [EMAIL PROTECTED] wrote: Actually I have the same problem. I can deploy expanded web apps no probs, but I've never been able to deploy a WAR... browser always wants to download it. Is there a TC setting that tells it to deploy WARs? Shapira, Yoav [EMAIL PROTECTED] 5/10/2004 2:32:20 am Hi, Oh, it's very definitely a special case ;) If the examples didn't work for 99.9% of Tomcat users, we'd have heard about it loudly and clearly by now. That's based on actual experience, not just hypothesis ;) Yoav Shapira Millennium Research Informatics -Original Message- From: Christian Ruediger [ mailto:[EMAIL PROTECTED] Sent: Monday, October 04, 2004 12:27 PM To: Tomcat Users List Subject: Re: servlet deployed, but Tomcat provides .war file for download only Thank you so far, in case i find that the examples dont work on my system, whom could I anounce the prevent others from serching to long: Perhaps with a little comment in the Readme. Or should I see it as it is: a special case. Bye Christian On Mon, 4 Oct 2004 12:19:54 -0400, Shapira, Yoav [EMAIL PROTECTED] wrote: Hi, Actually i used the launcher, 'cause the .bat script has some errors while calling javac (I haven't tried to fix this yet). Address those before going further. You should be able to launch Tomcat using startup.bat on Windows out of the box. If not, something serious is wrong. There is, as follows an XML parser error in the stdout.log file instruction target matching [xX][mM][lL] is not allowed. org.xml.sax.SAXParseException: The processing instruction target You have one messed-up configuration ;) I'm assuming that the examples and other default web applications that ship with Tomcat are not working? It's not just your webapp or just your servlet. 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] 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: Cluster Pure Tomcat with Hardware Load Balancer
He said he had a hardware load balancer so the tomcat one is irrelevant. The main doc on the jakarta site is http://jakarta.apache.org/tomcat/tomcat-5.0-doc/cluster-howto.html, which explains what the clustering does but not much details about getting it working. To get the basic cluster working all you need to do is to uncomment the cluster section in your server.xml. The comments in there should give you some hints. Have a play around and ask any specific questions here and there are quite a few people who will be able to help. Ta Matt -Original Message- From: Ben Souther [mailto:[EMAIL PROTECTED] Sent: 05 October 2004 02:03 To: Tomcat Users List Subject: Re: Cluster Pure Tomcat with Hardware Load Balancer I take it you've read this: http://jakarta.apache.org/tomcat/tomcat-5.0-doc/balancer-howto.html Also... It's been posted on this list recently that the source to the balancer app is pretty straight forward and easy to read. On Mon, 2004-10-04 at 18:09, MITCHELL TEIXEIRA wrote: Hello to the group - I am desperately searching for information about clustering Tomcat 5 in a pure environment without Apache in front of it. I have a hardware load balancer in front of two Tomcat servers that I want to join in a cluster in order to avoid/reduce broken shopping cart sessions experienced by customers coming from so-called megaproxy ISPs like AOL. Since we can't depend on SSL session ID via the hardware load balancer (thanks to Microsoft IE5+) we believe that we must make clustering work. The problem is scarce/non-existent web documentation of Tomcat Clustering. Any help is appreciated. MitchellT - 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] 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]
Re: Cluster Pure Tomcat with Hardware Load Balancer
Here are 2 interesting articles: http://www.onjava.com/pub/a/onjava/2004/03/31/clustering.html http://www.onjava.com/pub/a/onjava/2004/04/14/clustering.html?page=1 Since you do have a hardware load balancer, the article may not make much sense. However, if your concern is mainly session persistency, I guess you should refer to your hardware load balancer vendor for possible configurations to support megaproxy ISPs. Unless you want to opt for Tomcat's clustering feature, it would replication the session throughout all cluster nodes, which *could* solve your problem. Regards, Faisal Abdullah On Mon, 4 Oct 2004 18:09:19 -0400, MITCHELL TEIXEIRA [EMAIL PROTECTED] wrote: Hello to the group - I am desperately searching for information about clustering Tomcat 5 in a pure environment without Apache in front of it. I have a hardware load balancer in front of two Tomcat servers that I want to join in a cluster in order to avoid/reduce broken shopping cart sessions experienced by customers coming from so-called megaproxy ISPs like AOL. Since we can't depend on SSL session ID via the hardware load balancer (thanks to Microsoft IE5+) we believe that we must make clustering work. The problem is scarce/non-existent web documentation of Tomcat Clustering. Any help is appreciated. MitchellT - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- There are many ways of going forward, but there is only one way of standing still. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
File upload from main program
Hi, Is there any free API around that allows uploading of files to the server (tomcat or weblogic) via a servlet from a main application program? (instead of from a web browser) Anything from the jakarta fileupload project that can be reused here? Regards, Wee Jim, Sng Capco t: +65 6395 6973 f: +65 6395 6998 e: [EMAIL PROTECTED] w: www.capco.com http://www.capco.com/ The information in this email is confidential and is intended solely for the addressee(s). Access to this email by anyone else is unauthorized. If you are not an intended recipient, please notify the sender of this email immediately. You should not copy, use or disseminate the information contained in the email. Any views expressed in this message are those of the individual sender, except where the sender specifically states them to be the views of Capco. http://www.capco.com/
WAR deploy problem
Hi all, I've been using the manager application to deploy/undeploy my webapp. I've put the context descriptor file (context.xml) in my META-INF dir and everything *seems* to run just fine. However, in the console window I'm getting a lot on noise - starting with this... (note, my context is called hal) ... ... INFO: Processing Context configuration file URL file:C:\intranet\webserver\jakarta-tomca t-5.0.28\conf\Catalina\localhost\hal.xml 04-Oct-2004 11:48:39 org.apache.commons.digester.Digester endElement SEVERE: End event threw exception java.lang.reflect.InvocationTargetException at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.jav a:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessor Impl. java:25) at java.lang.reflect.Method.invoke(Method.java:324) ... ... I thought this looked like invalid XML in the context.xml but I've checked it with XML Spy and even removed the bulk of it as a test. Any ideas? Many thanks, Chris - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: File upload from main program
-Original Message- From: Sng Wee Jim Is there any free API around that allows uploading of files to the server (tomcat or weblogic) via a servlet from a main application program? (instead of from a web browser) Anything from the jakarta fileupload project that can be reused here? http://jakarta.apache.org/commons/fileupload/ I use that (commons-fileupload); No problems, though I wanted multiple file selection, for which I had to write some javascript. HTH DaveP. -- DISCLAIMER: NOTICE: The information contained in this email and any attachments is confidential and may be privileged. If you are not the intended recipient you should not use, disclose, distribute or copy any of the content of it or of any attachment; you are requested to notify the sender immediately of your receipt of the email and then to delete it and any attachments from your system. RNIB endeavours to ensure that emails and any attachments generated by its staff are free from viruses or other contaminants. However, it cannot accept any responsibility for any such which are transmitted. We therefore recommend you scan all attachments. Please note that the statements and views expressed in this email and any attachments are those of the author and do not necessarily represent those of RNIB. RNIB Registered Charity Number: 226227 Website: http://www.rnib.org.uk - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Multiple session timeouts in same web application
Hello: Can any one please explain the behaviour of session time out with Tomcat ? For example, if I specify a session time out of 30 minutes in web.xml and and then set session.setMaxInactiveInterval to 45 minutes in a page, then will it mean that only the page where I set it as 45 minutes will have a session time out of 45 minutes and all the rest of the pages will be having 30 minutes ? Or will the whole session will have a time out of 45 minutes after accessing the page where I set it as 45 minutes? Again, if I have multiple web applications with different session timeouts specified in respecitve web.xmls and single sign on enabled, then what will be the behaviuor ? ( Like, I accessed one web app page with timeout 15 min and went to a page in the second web app with timout set to 30 minutes, (all in the same session) then when will the first page will timout- after 15 minutes or after 30 minutes ?) In general, what is the optimum solution if i want different session time outs for pages in the same web application? If anyone knows nice links on the subject, please give that also. thanks and regards, -- Kannan. -- ___ Sign-up for Ads Free at Mail.com http://promo.mail.com/adsfreejump.htm - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Doubt regarding Confguring HTTP port
Hi, I have a doubt regarding configuring the HTTP port. I know that this can be done in the conf/server.xml. But my doubt is whether this can be overridden by giving it as a startup parameter of tomcat. Kindly advise. Thanks and Regards, Satya - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Doubt regarding Confguring HTTP port
This can be done in tomcat5. For example: Connector port=${my_port} address=${my_address} maxThreads=150 minSpareThreads=25 maxSpareThreads=75 enableLookups=false redirectPort=8443 acceptCount=100 debug=0 disableUploadTimeout=true compression=off compressionMinSize=2048 noCompressionUserAgents=gozilla, traviata compressableMimeType=text/html,text/xml / [Assuming unix] - before running startup.sh - first set the JAVA_OPTS environment variable to set 2 system properties for the jvm. For example: export JAVA_OPTS='-Dmy_port=8080 -Dmy_address=10.0.0.23' On windows - see the FAQ on setting JAVA_OPTS. (for cygwin, the above command works fine) -Tim Narayan, Satya wrote: Hi, I have a doubt regarding configuring the HTTP port. I know that this can be done in the conf/server.xml. But my doubt is whether this can be overridden by giving it as a startup parameter of tomcat. Kindly advise. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: JK2 2.0.4
I didn't suggest a ServerAlias as in the bug report. The method below works very well for me and it is much easier to manage with all my vhost config in httd.conf and not spread out among different files. Charlie -Original Message- From: Joseph Shraibman [mailto:[EMAIL PROTECTED] Sent: Monday, October 04, 2004 9:26 PM To: Tomcat Users List Subject: Re: JK2 2.0.4 No, this is a known bug and will not work. See http://issues.apache.org/bugzilla/show_bug.cgi?id=28758 Cox, Charlie wrote: To avoid all confusion, I would remove your [uri: mappings from the workers2.properties and then specify the mappings in your httpd.conf: VirtualHost 1.1.1.1:80 Location / JkUriSet worker ajp13:localhost:8409 /Location /VirtualHost VirtualHost 2.2.2.2:80 Location / JkUriSet worker ajp13:localhost:8209 /Location /VirtualHost This gives you a well-defined mapping and will be more useful should you want to allow Apache to host any of your files/urls Charlie -Original Message- From: Paul D. Hester [mailto:[EMAIL PROTECTED] Sent: Thursday, September 30, 2004 6:00 PM To: 'Tomcat Users List' Subject: RE: JK2 2.0.4 I've attached my workers.properties file below. Paul #define the shared memory file [shm:] file=/usr/local/apache-2.0.50/logs/jk2.log size=100 debug=1 # Define the communication channel [channel.socket:localhost:8409] [channel.socket:localhost:8209] #define the worker [ajp13:localhost:8409] channel=channel.socket:localhost:8409 [ajp13:localhost:8209] channel=channel.socket:localhost:8209 [uri:/*] group=ajp13:localhost:8409 [uri:/*] group=ajp13:localhost:8209 - 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 XInclude in tomcat's config files
On Tue, Oct 05, 2004 at 07:55:02AM +0100, Pawson, David wrote: ::Oh, that's what we are doing now, but entity resolution ::doesn't have a concept of relative paths. : Does your parser support xml:base? : That makes relative paths work. True; but what would the base path be? You've likely seen all of the posts here concerning relative paths within a webapp and how to determine the webapp's full filesystem path. If a person wants a completely self-contained WAR file they can drop into any Tomcat instance, constructing the various config files at build time is the way to go. -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: servlet deployed, but Tomcat provides .war file for download only
On Tue, Oct 05, 2004 at 10:48:11AM +0200, Christian Ruediger wrote: : I solved my problem: : The cause is quite simple: : I deleted the leading whitespace from my web.xml file. Thanks for the solution; for the sake of the archives, could you please clarify? What leading whitespace, and in what XML file? 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: Multiple session timeouts in same web application
session.setMaxInactiveInterval is applied to the current session. If you have different timeouts in pages, the last visited page with an explicit call to session.setMaxInactiveInterval wins. -Original Message- From: Kannan V [mailto:[EMAIL PROTECTED] Sent: Tuesday, October 05, 2004 12:22 PM To: [EMAIL PROTECTED] Subject: Multiple session timeouts in same web application Can any one please explain the behaviour of session time out with Tomcat ? For example, if I specify a session time out of 30 minutes in web.xml and and then set session.setMaxInactiveInterval to 45 minutes in a page, then will it mean that only the page where I set it as 45 minutes will have a session time out of 45 minutes and all the rest of the pages will be having 30 minutes ? Or will the whole session will have a time out of 45 minutes after accessing the page where I set it as 45 minutes? Again, if I have multiple web applications with different session timeouts specified in respecitve web.xmls and single sign on enabled, then what will be the behaviuor ? ( Like, I accessed one web app page with timeout 15 min and went to a page in the second web app with timout set to 30 minutes, (all in the same session) then when will the first page will timout- after 15 minutes or after 30 minutes ?) - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Tomcat 5.0.27 Clustering and session replication
Dear All, I'm facing 2 different problems when I'm trying to configure clustering of 2 tomcat servers on 2 different LINUX machines which have identical hardware configuration. First case: On both the machines, I've uncommented the cluster block in the server.xml. On one machine, I could successfully see the message that Replication member added whereas the other machine is not able to recognize the first one and it is displaying the message No members active. Second case: When I started the tomcat server on one machine, it is running properly. But when I run the server on the other machine, an error message is getting displayed. java.net.SocketException:Unable to send mcast message. Resource is not available. Please help. Thanks in advance. Vijaya
SUM: Tomcat dies at 167M
Thank you all who sent help. We have a large number of jsp pages. Our problem was fixed by setting the MaxPermSize ( -XX:MaxPermSize=256m ). We plan to retool our pages and make them html served by apache, with an iframe to a single jsp page that will handle the dynamic content. Take Care. Shannon -Original Message- From: Shannon Scott [mailto:[EMAIL PROTECTED] Sent: Thursday, September 23, 2004 11:20 AM To: [EMAIL PROTECTED] Subject: Tomcat dies at 167M Greetings, Tomcat is running, and was working fine until the memory usage went up to 167, now none of the .jsp pages will respond ( the server hangs forever ). The last entries from the Catalina.out are : java.lang.OutOfMemoryError java.lang.OutOfMemoryError java.lang.OutOfMemoryError I don't understand how the JVM could be our of memory because I set it to use 256M. So the last time this happened, I wrote a piece of code that would leak some memory thinking that might be somehow related, but the tomcat process used more than 167M when I tested that page. I have set the CATALINA_OPTS=-Xms64M -Xmx256M, and everything looks right when I list the processes. ps -elf | grep tomcat : 0 S tomcat4 17629 1 0 85 0- 315671 schedu Sep21 ? 00:00:04 /usr/java/j2sdk1.4.2_03/bin/java -Xms64M -Xmx256M. However, after the system shows 167M in top, tomcat no longer responds. None of the tomcat logs are written to, and I find this in the mod_jk log : [Thu Sep 23 11:00:03 2004] [jk_ajp_common.c (738)]: ERROR: can't receive the response message from tomcat, network problems or tomcat is down. err=-104 [Thu Sep 23 11:00:03 2004] [jk_ajp_common.c (1137)]: Error reading reply from tomcat. Tomcat is down or network problems. [Thu Sep 23 11:00:03 2004] [jk_ajp_common.c (1290)]: ERROR: Receiving from tomcat failed, recoverable operation. err=0 [Thu Sep 23 11:00:03 2004] [jk_ajp_common.c (1309)]: sending request to tomcat failed in send loop. err=0 top output : PIDUSER PRI NI SIZE RSS SHARE STAT %CPU %MEM TIME CPU COMMAND 17629 tomcat4 250 167M 140M 12484 S 0.0 6.9 15:40 0 java RedHat Linux ES 3.0 Apache 2.0.46 with ( mod_jk ) Tomcat 4.1.24 Sun j2sdk 1.4.2_03 I am confused. Any help is greatly appreciated. Please let me know if I can provide any more informative details. Thank you for your time. Take Care. Shannon PS I have searched list archives and read the docs about tomcat OutOfMemoryError, but none seem to address my problem. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Tomcat 5.0.27 Clustering and session replication
This sounds like a networking issue. Is multicasting allowed on your network? -Original Message- From: Vijaya [mailto:[EMAIL PROTECTED] Sent: 05 October 2004 13:24 To: [EMAIL PROTECTED] Subject: Tomcat 5.0.27 Clustering and session replication Dear All, I'm facing 2 different problems when I'm trying to configure clustering of 2 tomcat servers on 2 different LINUX machines which have identical hardware configuration. First case: On both the machines, I've uncommented the cluster block in the server.xml. On one machine, I could successfully see the message that Replication member added whereas the other machine is not able to recognize the first one and it is displaying the message No members active. Second case: When I started the tomcat server on one machine, it is running properly. But when I run the server on the other machine, an error message is getting displayed. java.net.SocketException:Unable to send mcast message. Resource is not available. Please help. Thanks in advance. Vijaya 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]
RE: 5.0.28 stack overflow?
Hi, It sure looks like ApplicationHttpRequest.getRequest() returned itself a copy of itself... If you really want to track this down, you can prove (or disprove) the above by building your own tomcat that does a toString() call on the request of AppliationHttpRequest.getRequest. You'll see from the memory address if it's the same object... 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: Tomcat 5.0.27 Clustering and session replication
looks like you need to enable multicast on your second machine Filip - Original Message - From: Vijaya [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Tuesday, October 05, 2004 7:24 AM Subject: Tomcat 5.0.27 Clustering and session replication Dear All, I'm facing 2 different problems when I'm trying to configure clustering of 2 tomcat servers on 2 different LINUX machines which have identical hardware configuration. First case: On both the machines, I've uncommented the cluster block in the server.xml. On one machine, I could successfully see the message that Replication member added whereas the other machine is not able to recognize the first one and it is displaying the message No members active. Second case: When I started the tomcat server on one machine, it is running properly. But when I run the server on the other machine, an error message is getting displayed. java.net.SocketException:Unable to send mcast message. Resource is not available. Please help. Thanks in advance. Vijaya - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Classes are reloaded automatically even when reloadable is not set
Hi, I'm using Tomcat 5.0.28 on Win98. I've created a very simple web app consists of just two java files: Does your webapp have a web.xml? Where are HelloServlet and Biz located? writer.close(); This is an aside, and irrelevant to this thread, but you shouldn't close the writer. Other things (response wrappers, filters) might want to do stuff that depends on the writer. A good rule of thumb is if you didn't create it, don't terminate it: you didn't create or open the writer, so don't close it. 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: Tomcat 5.0.27 Clustering and session replication
Shall we need to manually enable multicasting? I doubt becos I've not done this explicitly on the first machine. - Original Message - From: Filip Hanik - Dev [EMAIL PROTECTED] To: Tomcat Users List [EMAIL PROTECTED] Sent: Tuesday, October 05, 2004 6:35 PM Subject: Re: Tomcat 5.0.27 Clustering and session replication looks like you need to enable multicast on your second machine Filip - Original Message - From: Vijaya [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Tuesday, October 05, 2004 7:24 AM Subject: Tomcat 5.0.27 Clustering and session replication Dear All, I'm facing 2 different problems when I'm trying to configure clustering of 2 tomcat servers on 2 different LINUX machines which have identical hardware configuration. First case: On both the machines, I've uncommented the cluster block in the server.xml. On one machine, I could successfully see the message that Replication member added whereas the other machine is not able to recognize the first one and it is displaying the message No members active. Second case: When I started the tomcat server on one machine, it is running properly. But when I run the server on the other machine, an error message is getting displayed. java.net.SocketException:Unable to send mcast message. Resource is not available. Please help. Thanks in advance. Vijaya - 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: Upload File
If these questions are asked on the main list, others can learn too? -Original Message- From: Caroline Jen I am trying to upload files from clients machine. I understand that we must specify METHOD=post and ENCTYPE=multipart/form-data in the FORM tag. Would you please help me with a number of questions: 1. Once the client makes a selection from his/her PC, the file name will appear in the text field. How do I 'save the file name'? within the servlet, DiskFileUpload upload = new DiskFileUpload(); boolean isMultipart = FileUpload.isMultipartContent(request); if (!isMultipart) { logger.warn(userName(request)+File upload is not multipart); ULerr = FORMNOTMULTIPART; } // Set upload parameters ... try { java.util.List items = upload.parseRequest(request); // Process the uploaded items String [] parms = gParms (items, request); String [] gfileList = gFiles (items, request); I have some plain textboxes as well as the list of files. I'm re-working this piece; currently /** *unwrap filelist, return as string array. **/ public String [] gFiles(java.util.List items,HttpServletRequest request){ String[] retval=null; java.util.Iterator iter = items.iterator(); int pos=0; while (iter.hasNext()) { FileItem item = (FileItem) iter.next(); if (!item.isFormField()) { String fieldName = item.getFieldName(); String fileName = item.getName(); String contentType = item.getContentType(); boolean isInMemory = item.isInMemory(); long sizeInBytes = item.getSize(); if (sizeInBytes == 0){ logger.info(userName(request)+ No files selected); out.println(liNo files selected/li); }else{ // file OK pos +=1; retval[pos] = fileName; // full path and filename } }//end of if is Form field }// end of while more items return retval; }// end of gfiles() That collects the list of filenames, prior to uploading them? That should be sufficient to get you started. The rest of my code is messed with the functionality I need? HTH DaveP. 2. Do I save what I download from the http://www.htmlhelp.com/reference/html40/forms/input.html in my $TOMCAT/common/lib directory? Do I have to save it in my $TOMCAT/webapps/AppName/WEB-INF/lib directory. No, its just java once you have the filenames. Just write them whereever you need them to be. 3. Are there anything else I have to do to make file uploading work? Patience :-) HTH DaveP. Shout again if I can help. -- DISCLAIMER: NOTICE: The information contained in this email and any attachments is confidential and may be privileged. If you are not the intended recipient you should not use, disclose, distribute or copy any of the content of it or of any attachment; you are requested to notify the sender immediately of your receipt of the email and then to delete it and any attachments from your system. RNIB endeavours to ensure that emails and any attachments generated by its staff are free from viruses or other contaminants. However, it cannot accept any responsibility for any such which are transmitted. We therefore recommend you scan all attachments. Please note that the statements and views expressed in this email and any attachments are those of the author and do not necessarily represent those of RNIB. RNIB Registered Charity Number: 226227 Website: http://www.rnib.org.uk - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Root application in Tomcat
Hello, I have a problem with installing an application at root level in Tomcat. I have an application with a specified context: Context docBase=myApp path= workDir=work/Catalina/localhost/myApp I thought that leaving the path empty and removing the ROOT application was enough to install the application att root level so I can use http://localhost to reach the application instead of http://localhost/myApp. But this doesn't seem to work. When entering the root after deployment I end up in Directory Listing for / and all applications are shown. Is there a tutorial somewhere how to solve this or can anybody please help me with this. I'm using Tomcat 5.0.28. Thanks in advance /Kax - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Root application in Tomcat
Hi, Context docBase=myApp path= workDir=work/Catalina/localhost/myApp This is fine. You probably don't need to specify workDir explicitly since you're just using the default anyways. I thought that leaving the path empty and removing the ROOT application was enough to install the application att root level so I can use http://localhost to reach the application instead of http://localhost/myApp. Your thought is correct. But this doesn't seem to work. When entering the root after deployment I end up in Directory Listing for / and all applications are shown. Do you have a welcome file in your app to match the welcome-files defines in your web.xml? 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: RE: Root application in Tomcat
Thanks for your fast reply but I still can't get it to work. When looking in the manager I can see that an application has been deployed to Context (/) and another to the Context (/myApp). When looking at the / no document base or path is visible. When trying to look at the /myApp I get an error: HTTP Status 500 - Error retrieving attribute debug What can be the problem? Thanks in advance /Kax From: Shapira, Yoav [EMAIL PROTECTED] Date: 2004/10/05 ti PM 01:42:58 GMT To: Tomcat Users List [EMAIL PROTECTED] Ämne: RE: Root application in Tomcat Hi, Context docBase=myApp path= workDir=work/Catalina/localhost/myApp This is fine. You probably don't need to specify workDir explicitly since you're just using the default anyways. I thought that leaving the path empty and removing the ROOT application was enough to install the application att root level so I can use http://localhost to reach the application instead of http://localhost/myApp. Your thought is correct. But this doesn't seem to work. When entering the root after deployment I end up in Directory Listing for / and all applications are shown. Do you have a welcome file in your app to match the welcome-files defines in your web.xml? 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]
RE: RE: Root application in Tomcat
Remember, your app is /, but the directory is actuall _. If you use tomcat manager to deploy your war, the uploaded war is at manager's work dir under name of _.war and the compiled classes etc are located at work dir's _ -Original Message- From: kax [mailto:[EMAIL PROTECTED] Sent: October 5, 2004 9:58 AM To: Tomcat Users List Subject: Re: RE: Root application in Tomcat Thanks for your fast reply but I still can't get it to work. When looking in the manager I can see that an application has been deployed to Context (/) and another to the Context (/myApp). When looking at the / no document base or path is visible. When trying to look at the /myApp I get an error: HTTP Status 500 - Error retrieving attribute debug What can be the problem? Thanks in advance /Kax From: Shapira, Yoav [EMAIL PROTECTED] Date: 2004/10/05 ti PM 01:42:58 GMT To: Tomcat Users List [EMAIL PROTECTED] Ämne: RE: Root application in Tomcat Hi, Context docBase=myApp path= workDir=work/Catalina/localhost/myApp This is fine. You probably don't need to specify workDir explicitly since you're just using the default anyways. I thought that leaving the path empty and removing the ROOT application was enough to install the application att root level so I can use http://localhost to reach the application instead of http://localhost/myApp. Your thought is correct. But this doesn't seem to work. When entering the root after deployment I end up in Directory Listing for / and all applications are shown. Do you have a welcome file in your app to match the welcome-files defines in your web.xml? 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] !DSPAM:4162a87f11832027331781!
RE: RE: Root application in Tomcat
Hi, Can you post your entire server.xml, and the myApp/WEB-INF/web.xml file? You are deploying in the simplest way, by restarting the server, right? Not using Ant or the Manager webapp? Yoav Shapira Millennium Research Informatics -Original Message- From: kax [mailto:[EMAIL PROTECTED] Sent: Tuesday, October 05, 2004 9:58 AM To: Tomcat Users List Subject: Re: RE: Root application in Tomcat Thanks for your fast reply but I still can't get it to work. When looking in the manager I can see that an application has been deployed to Context (/) and another to the Context (/myApp). When looking at the / no document base or path is visible. When trying to look at the /myApp I get an error: HTTP Status 500 - Error retrieving attribute debug What can be the problem? Thanks in advance /Kax From: Shapira, Yoav [EMAIL PROTECTED] Date: 2004/10/05 ti PM 01:42:58 GMT To: Tomcat Users List [EMAIL PROTECTED] Ämne: RE: Root application in Tomcat Hi, Context docBase=myApp path= workDir=work/Catalina/localhost/myApp This is fine. You probably don't need to specify workDir explicitly since you're just using the default anyways. I thought that leaving the path empty and removing the ROOT application was enough to install the application att root level so I can use http://localhost to reach the application instead of http://localhost/myApp. Your thought is correct. But this doesn't seem to work. When entering the root after deployment I end up in Directory Listing for / and all applications are shown. Do you have a welcome file in your app to match the welcome-files defines in your web.xml? 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] 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: Upload File
Do you just not use ActionForm, David? Michael McGrady Pawson, David wrote: If these questions are asked on the main list, others can learn too? -Original Message- From: Caroline Jen I am trying to upload files from clients machine. I understand that we must specify METHOD=post and ENCTYPE=multipart/form-data in the FORM tag. Would you please help me with a number of questions: 1. Once the client makes a selection from his/her PC, the file name will appear in the text field. How do I 'save the file name'? within the servlet, DiskFileUpload upload = new DiskFileUpload(); boolean isMultipart = FileUpload.isMultipartContent(request); if (!isMultipart) { logger.warn(userName(request)+File upload is not multipart); ULerr = FORMNOTMULTIPART; } // Set upload parameters ... try { java.util.List items = upload.parseRequest(request); // Process the uploaded items String [] parms = gParms (items, request); String [] gfileList = gFiles (items, request); I have some plain textboxes as well as the list of files. I'm re-working this piece; currently /** *unwrap filelist, return as string array. **/ public String [] gFiles(java.util.List items,HttpServletRequest request){ String[] retval=null; java.util.Iterator iter = items.iterator(); int pos=0; while (iter.hasNext()) { FileItem item = (FileItem) iter.next(); if (!item.isFormField()) { String fieldName = item.getFieldName(); String fileName = item.getName(); String contentType = item.getContentType(); boolean isInMemory = item.isInMemory(); long sizeInBytes = item.getSize(); if (sizeInBytes == 0){ logger.info(userName(request)+ No files selected); out.println(liNo files selected/li); }else{ // file OK pos +=1; retval[pos] = fileName; // full path and filename } }//end of if is Form field }// end of while more items return retval; }// end of gfiles() That collects the list of filenames, prior to uploading them? That should be sufficient to get you started. The rest of my code is messed with the functionality I need? HTH DaveP. 2. Do I save what I download from the http://www.htmlhelp.com/reference/html40/forms/input.html in my $TOMCAT/common/lib directory? Do I have to save it in my $TOMCAT/webapps/AppName/WEB-INF/lib directory. No, its just java once you have the filenames. Just write them whereever you need them to be. 3. Are there anything else I have to do to make file uploading work? Patience :-) HTH DaveP. Shout again if I can help. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: RE: Root application in Tomcat
Hi, Here are the files. No I'm not using the manager. I just drop the war in the webapp folder using autoDeploy=true. Thanks /Kax From: Shapira, Yoav [EMAIL PROTECTED] Date: 2004/10/05 ti PM 02:06:19 GMT To: Tomcat Users List [EMAIL PROTECTED] Ämne: RE: RE: Root application in Tomcat Hi, Can you post your entire server.xml, and the myApp/WEB-INF/web.xml file? You are deploying in the simplest way, by restarting the server, right? Not using Ant or the Manager webapp? Yoav Shapira Millennium Research Informatics -Original Message- From: kax [mailto:[EMAIL PROTECTED] Sent: Tuesday, October 05, 2004 9:58 AM To: Tomcat Users List Subject: Re: RE: Root application in Tomcat Thanks for your fast reply but I still can't get it to work. When looking in the manager I can see that an application has been deployed to Context (/) and another to the Context (/myApp). When looking at the / no document base or path is visible. When trying to look at the /myApp I get an error: HTTP Status 500 - Error retrieving attribute debug What can be the problem? Thanks in advance /Kax From: Shapira, Yoav [EMAIL PROTECTED] Date: 2004/10/05 ti PM 01:42:58 GMT To: Tomcat Users List [EMAIL PROTECTED] Ämne: RE: Root application in Tomcat Hi, Context docBase=myApp path= workDir=work/Catalina/localhost/myApp This is fine. You probably don't need to specify workDir explicitly since you're just using the default anyways. I thought that leaving the path empty and removing the ROOT application was enough to install the application att root level so I can use http://localhost to reach the application instead of http://localhost/myApp. Your thought is correct. But this doesn't seem to work. When entering the root after deployment I end up in Directory Listing for / and all applications are shown. Do you have a welcome file in your app to match the welcome-files defines in your web.xml? 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] 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] !-- Example Server Configuration File -- !-- Note that component elements are nested corresponding to their parent-child relationships with each other -- !-- A Server is a singleton element that represents the entire JVM, which may contain one or more Service instances. The Server listens for a shutdown command on the indicated port. Note: A Server is not itself a Container, so you may not define subcomponents such as Valves or Loggers at this level. -- Server port=8005 shutdown=SHUTDOWN debug=0 !-- Comment these entries out to disable JMX MBeans support -- !-- You may also configure custom components (e.g. Valves/Realms) by including your own mbean-descriptor file(s), and setting the descriptors attribute to point to a ';' seperated list of paths (in the ClassLoader sense) of files to add to the default list. e.g. descriptors=/com/myfirm/mypackage/mbean-descriptor.xml -- Listener className=org.apache.catalina.mbeans.ServerLifecycleListener debug=0/ Listener className=org.apache.catalina.mbeans.GlobalResourcesLifecycleListener debug=0/ !-- Global JNDI resources -- GlobalNamingResources !-- Test entry for demonstration purposes -- Environment name=simpleValue type=java.lang.Integer value=30/ !-- Editable user database that can also be used by UserDatabaseRealm to authenticate users -- Resource name=UserDatabase auth=Container
RE: How to make Apache direct Servlet to Tomcat
In your configuration, apache has no way of knowing that /ServletTest needs to be forwarded to Tomcat. Try adding something like: [uri:/ServletTest] group=lb And see if that works. If it does, you can then figure out a more efficient way for apache to redirect servlets. So you don't have to map every single servlet. -Original Message- From: Daxin Zuo [mailto:[EMAIL PROTECTED] Sent: Monday, October 04, 2004 3:32 PM To: Tomcat Users List Subject: RE: How to make Apache direct Servlet to Tomcat Bellow is my Apache2/conf/wrokers2.property. I also wonder if I need to add an listner like Listener className=org.apache.ajp.tomcat5.config.ApacheConfig / in the httpd.conf file wrokers2.property: [shm] info=Scoreboard. Requried for reconfiguration and status with multiprocess servers. file=anon # Defines a load balancer named lb. Use even if you only have one machine. [lb:lb] Bellow is the # Example socket channel, override port and host. [channel.socket:MyComputerIP:8009] port=8009 host=MyComputerIP # define the worker [ajp13:MyComputerIP:8009] channel=channel.socket:MyComputerIP:8009 group=lb # Map the Tomcat examples webapp to the Web server uri space [uri:/examples/*] group=lb [uri:/www/*] group=lb [uri:/jdbcRowset/*] group=lb [status:] info=Status worker, displays runtime information [uri:/jkstatus/*] info=The Tomcat /jkstatus handler group=status: Thank you. -Original Message- From: Lee, Paul NYC [mailto:[EMAIL PROTECTED] Sent: Friday, October 01, 2004 6:22 PM To: 'Tomcat Users List' Subject: RE: How to make Apache direct Servlet to Tomcat I can't see your attachments. Just paste the relevant parts in the body of the email. -Original Message- From: Daxin Zuo [mailto:[EMAIL PROTECTED] Sent: Friday, October 01, 2004 5:15 PM To: Tomcat Users List Subject: RE: How to make Apache direct Servlet to Tomcat Thank you for your attention. The Apache2/conf/wrokers2.property is attached. The Tomcat/conf/jk2.property is empty, all lines are commented. in the httpd.conf I added: LoadModule jk2_module modules/mod_jk2-2.0.43.so the .so files are in apache2/modules Thanks -Original Message- From: Lee, Paul NYC [mailto:[EMAIL PROTECTED] Sent: Friday, October 01, 2004 1:23 PM To: 'Tomcat Users List' Subject: RE: How to make Apache direct Servlet to Tomcat Hi, It should be done the same way you redirected jsp requests to tomcat. It needs to be mapped in your jk (or jk2) properties file. Post the relevant parts of your properties file if you're not sure why it doesn't work. -Original Message- From: Daxin Zuo [mailto:[EMAIL PROTECTED] Sent: Friday, October 01, 2004 1:38 PM To: Tomcat Users List Subject: How to make Apache direct Servlet to Tomcat On my Apache 2.0.43 + Tomcat5.0.28 on UNIX sparc, I can run the same JSP files from both Apache and Tomcat, and run servlets on Tomcat, but I cannot run Servlet from Apache. I register the servlet in tomcat/webapps/www/WEB-INF/web.xml: servlet servlet-nameServletTest/servlet-name servlet-classServletTest/servlet-class /servlet servlet-mapping servlet-nameServletTest/servlet-name url-pattern/ServletTest/url-pattern /servlet-mapping /www is the DocBase. The error message on the screen is: /ServletTest was not found on this server. From the Apache error log, I see Apache looked for the file in Apache htdocs folder, instead pass the request to Tomcat. When I start Tomcat I get some errors. The are probably not related to the problem above. the errors are: 1) in catalina.out INFO: Installing web application at context path /balancer from URL file:/usr/local/apache2/jakarta-tomcat-5.0.28/webapps/balancer Oct 1, 2004 10:14:50 AM org.apache.catalina.core.StandardContext start SEVERE: Error filterStart Oct 1, 2004 10:14:50 AM org.apache.catalina.core.StandardContext start SEVERE: Context startup failed due to previous errors . 2) in localhost_log.2004-10-01.txt 2004-10-01 10:14:50 StandardContext[/balancer]Exception starting filter BalancerFilter java.lang.NoClassDefFoundError: org/apache/commons/digester/Digester at org.apache.webapp.balancer.RulesParser.createDigester(RulesParser.java:65) ... Please help me with the servlet problem. - 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: RE: Root application in Tomcat
Hi, With autoDeploy set to true, you'll get duplicate deployment, as you've noted. Turn it off so that only the explicitly declared Context (the one with path=) is deployed. Yoav Shapira Millennium Research Informatics -Original Message- From: kax [mailto:[EMAIL PROTECTED] Sent: Tuesday, October 05, 2004 10:20 AM To: Tomcat Users List Subject: RE: RE: Root application in Tomcat Hi, Here are the files. No I'm not using the manager. I just drop the war in the webapp folder using autoDeploy=true. Thanks /Kax From: Shapira, Yoav [EMAIL PROTECTED] Date: 2004/10/05 ti PM 02:06:19 GMT To: Tomcat Users List [EMAIL PROTECTED] Ämne: RE: RE: Root application in Tomcat Hi, Can you post your entire server.xml, and the myApp/WEB-INF/web.xml file? You are deploying in the simplest way, by restarting the server, right? Not using Ant or the Manager webapp? Yoav Shapira Millennium Research Informatics -Original Message- From: kax [mailto:[EMAIL PROTECTED] Sent: Tuesday, October 05, 2004 9:58 AM To: Tomcat Users List Subject: Re: RE: Root application in Tomcat Thanks for your fast reply but I still can't get it to work. When looking in the manager I can see that an application has been deployed to Context (/) and another to the Context (/myApp). When looking at the / no document base or path is visible. When trying to look at the /myApp I get an error: HTTP Status 500 - Error retrieving attribute debug What can be the problem? Thanks in advance /Kax From: Shapira, Yoav [EMAIL PROTECTED] Date: 2004/10/05 ti PM 01:42:58 GMT To: Tomcat Users List [EMAIL PROTECTED] Ämne: RE: Root application in Tomcat Hi, Context docBase=myApp path= workDir=work/Catalina/localhost/myApp This is fine. You probably don't need to specify workDir explicitly since you're just using the default anyways. I thought that leaving the path empty and removing the ROOT application was enough to install the application att root level so I can use http://localhost to reach the application instead of http://localhost/myApp. Your thought is correct. But this doesn't seem to work. When entering the root after deployment I end up in Directory Listing for / and all applications are shown. Do you have a welcome file in your app to match the welcome-files defines in your web.xml? 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] 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] 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: Root application in Tomcat
Hi, I would also suggest adding a factory element to each ResourceParams in your d-test.xml file, and setting auth=Container for them to be complete. In addition, don't use Parameter unless you have to: that stuff can and should be included as context parameters in your web.xml. That approach is more portable and container-independent. But what you have is not illegal or invalid, the above are just suggestions. The server.xml also looks fine at a glance. So do you have a welcome-file for your webapp that matches what's in your web.xml? Yoav Shapira Millennium Research Informatics -Original Message- From: kax [mailto:[EMAIL PROTECTED] Sent: Tuesday, October 05, 2004 10:20 AM To: Tomcat Users List Subject: RE: RE: Root application in Tomcat Hi, Here are the files. No I'm not using the manager. I just drop the war in the webapp folder using autoDeploy=true. Thanks /Kax From: Shapira, Yoav [EMAIL PROTECTED] Date: 2004/10/05 ti PM 02:06:19 GMT To: Tomcat Users List [EMAIL PROTECTED] Ämne: RE: RE: Root application in Tomcat Hi, Can you post your entire server.xml, and the myApp/WEB-INF/web.xml file? You are deploying in the simplest way, by restarting the server, right? Not using Ant or the Manager webapp? Yoav Shapira Millennium Research Informatics -Original Message- From: kax [mailto:[EMAIL PROTECTED] Sent: Tuesday, October 05, 2004 9:58 AM To: Tomcat Users List Subject: Re: RE: Root application in Tomcat Thanks for your fast reply but I still can't get it to work. When looking in the manager I can see that an application has been deployed to Context (/) and another to the Context (/myApp). When looking at the / no document base or path is visible. When trying to look at the /myApp I get an error: HTTP Status 500 - Error retrieving attribute debug What can be the problem? Thanks in advance /Kax From: Shapira, Yoav [EMAIL PROTECTED] Date: 2004/10/05 ti PM 01:42:58 GMT To: Tomcat Users List [EMAIL PROTECTED] Ämne: RE: Root application in Tomcat Hi, Context docBase=myApp path= workDir=work/Catalina/localhost/myApp This is fine. You probably don't need to specify workDir explicitly since you're just using the default anyways. I thought that leaving the path empty and removing the ROOT application was enough to install the application att root level so I can use http://localhost to reach the application instead of http://localhost/myApp. Your thought is correct. But this doesn't seem to work. When entering the root after deployment I end up in Directory Listing for / and all applications are shown. Do you have a welcome file in your app to match the welcome-files defines in your web.xml? 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] 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] 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]
server has been restarted or reset this connection
Hi, I'm using mod_jk2 to link apache 2.0.48 to Tomcat 4.1.24. Recently I started getting the following messages after starting Tomcat but I'm not sure what I changed to cause this. What causes them? INFO: server has been restarted or reset this connection Oct 5, 2004 3:10:49 PM org.apache.jk.common.ChannelSocket processConnection INFO: server has been restarted or reset this connection Oct 5, 2004 3:10:59 PM org.apache.jk.common.ChannelSocket processConnection INFO: server has been restarted or reset this connection Oct 5, 2004 3:10:59 PM org.apache.jk.common.ChannelSocket processConnection INFO: server has been restarted or reset this connection Oct 5, 2004 3:11:14 PM org.apache.jk.common.ChannelSocket processConnection INFO: server has been restarted or reset this connection Oct 5, 2004 3:11:40 PM org.apache.jk.common.ChannelSocket processConnection INFO: server has been restarted or reset this connection Oct 5, 2004 3:13:09 PM org.apache.jk.common.ChannelSocket processConnection INFO: server has been restarted or reset this connection Oct 5, 2004 3:15:45 PM org.apache.jk.common.ChannelSocket processConnection INFO: server has been restarted or reset this connection Thanks, JS. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: servlet deployed, but Tomcat provides .war file for download only
On Tue, 5 Oct 2004 07:04:11 -0500, QM [EMAIL PROTECTED] wrote: On Tue, Oct 05, 2004 at 10:48:11AM +0200, Christian Ruediger wrote: : I solved my problem: : The cause is quite simple: : I deleted the leading whitespace from my web.xml file. Thanks for the solution; for the sake of the archives, could you please clarify? What leading whitespace, and in what XML file? I don't know whether this will help in your case, but i meant the web.xml file located in the deploymant path: {yourWebApp}/WEB-INF/web.xml Seems like XML files are not allowed to begin with a whitespace. Means this is wrong: xml... And this is right: xml... So far for my error Christian Thanks, -QM - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Problems with Tomcat 4.0.5
Hi I have developed a J2EE Application (1.3 specs), using Struts 1.1 Framework. It also uses Tiles, as integrated into the Struts Framework. The application is built on Tomcat 4.1.27, and works well on the development env. However, the production env /host uses Tomcat 4.0.5, and it's where it all plunges into problems. The exception is in JSP Custom Tags. My Site uses composite view pattern via Tiles, and the tomcat engine is failing to render the composite views successfully. Anyone has any idea? How to over come this issue? Host has a limitation and can't upgrade the tomcat. Is there a work around? Much appreciate your help. Thanks Hassan Stack Trace: 2004-10-05 16:18:45 WarpEngine[Apache]: Mapping request 2004-10-05 16:18:45 WarpHost[claudius.davanco.com]: Mapping request for Host 2004-10-05 16:18:45 ApplicationDispatcher[/piweb] Servlet.service() for servlet default threw exception java.lang.IllegalStateException at org.apache.jasper.runtime.ServletResponseWrapperInclude.getOutputStream(Serv letResponseWrapperInclude.java:109) at org.apache.catalina.servlets.DefaultServlet.serveResource(DefaultServlet.jav a:1146) at org.apache.catalina.servlets.DefaultServlet.doGet(DefaultServlet.java:519) at javax.servlet.http.HttpServlet.service(HttpServlet.java:740) at javax.servlet.http.HttpServlet.service(HttpServlet.java:853) at org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDispatcher. java:683) at org.apache.catalina.core.ApplicationDispatcher.doInclude(ApplicationDispatch er.java:574) at org.apache.catalina.core.ApplicationDispatcher.include(ApplicationDispatcher .java:497) at org.apache.jasper.runtime.JspRuntimeLibrary.include(JspRuntimeLibrary.java:8 19) at org.apache.jasper.runtime.PageContextImpl.include(PageContextImpl.java:391) at org.apache.struts.tiles.TilesUtilImpl.doInclude(TilesUtilImpl.java:137) at org.apache.struts.tiles.TilesUtil.doInclude(TilesUtil.java:177) at org.apache.struts.taglib.tiles.InsertTag.doInclude(InsertTag.java:756) at org.apache.struts.taglib.tiles.InsertTag$InsertHandler.doEndTag(InsertTag.ja va:881) at org.apache.struts.taglib.tiles.InsertTag.doEndTag(InsertTag.java:473) at org.apache.jsp.classicLayout$jsp._jspService(classicLayout$jsp.java:326) at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:107) at javax.servlet.http.HttpServlet.service(HttpServlet.java:853) at org.apache.jasper.servlet.JspServlet$JspServletWrapper.service(JspServlet.ja va:201) at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:381) at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:473) at javax.servlet.http.HttpServlet.service(HttpServlet.java:853) at org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDispatcher. java:683) at org.apache.catalina.core.ApplicationDispatcher.doForward(ApplicationDispatch er.java:431) at org.apache.catalina.core.ApplicationDispatcher.forward(ApplicationDispatcher .java:355) at org.apache.struts.action.RequestProcessor.doForward(RequestProcessor.java:10 69) at org.apache.struts.tiles.TilesRequestProcessor.doForward(TilesRequestProcesso r.java:274) at org.apache.struts.tiles.TilesRequestProcessor
RE: Problems with Tomcat 4.0.5
Hi, Tomcat 4.0.5 is not a good choice for a production system, because it's not a stable release. 4.0.6 was a stable release. Beyond that, I suggest you check out the status pages on the Tomcat site, which urge you to update to a more recent and supported branch, such as Tomcat 5.0. Yoav Shapira Millennium Research Informatics -Original Message- From: Hassan Sajjad [mailto:[EMAIL PROTECTED] Sent: Tuesday, October 05, 2004 12:59 PM To: [EMAIL PROTECTED] Subject: Problems with Tomcat 4.0.5 Hi I have developed a J2EE Application (1.3 specs), using Struts 1.1 Framework. It also uses Tiles, as integrated into the Struts Framework. The application is built on Tomcat 4.1.27, and works well on the development env. However, the production env /host uses Tomcat 4.0.5, and it's where it all plunges into problems. The exception is in JSP Custom Tags. My Site uses composite view pattern via Tiles, and the tomcat engine is failing to render the composite views successfully. Anyone has any idea? How to over come this issue? Host has a limitation and can't upgrade the tomcat. Is there a work around? Much appreciate your help. Thanks Hassan Stack Trace: 2004-10-05 16:18:45 WarpEngine[Apache]: Mapping request 2004-10-05 16:18:45 WarpHost[claudius.davanco.com]: Mapping request for Host 2004-10-05 16:18:45 ApplicationDispatcher[/piweb] Servlet.service() for servlet default threw exception java.lang.IllegalStateException at org.apache.jasper.runtime.ServletResponseWrapperInclude.getOutputStream (Ser v letResponseWrapperInclude.java:109) at org.apache.catalina.servlets.DefaultServlet.serveResource(DefaultServle t.ja v a:1146) at org.apache.catalina.servlets.DefaultServlet.doGet(DefaultServlet.java:5 19) at javax.servlet.http.HttpServlet.service(HttpServlet.java:740) at javax.servlet.http.HttpServlet.service(HttpServlet.java:853) at org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDispat cher . java:683) at org.apache.catalina.core.ApplicationDispatcher.doInclude(ApplicationDis patc h er.java:574) at org.apache.catalina.core.ApplicationDispatcher.include(ApplicationDispa tche r .java:497) at org.apache.jasper.runtime.JspRuntimeLibrary.include(JspRuntimeLibrary.j ava: 8 19) at org.apache.jasper.runtime.PageContextImpl.include(PageContextImpl.java: 391) at org.apache.struts.tiles.TilesUtilImpl.doInclude(TilesUtilImpl.java:137) at org.apache.struts.tiles.TilesUtil.doInclude(TilesUtil.java:177) at org.apache.struts.taglib.tiles.InsertTag.doInclude(InsertTag.java:756) at org.apache.struts.taglib.tiles.InsertTag$InsertHandler.doEndTag(InsertT ag.j a va:881) at org.apache.struts.taglib.tiles.InsertTag.doEndTag(InsertTag.java:473) at org.apache.jsp.classicLayout$jsp._jspService(classicLayout$jsp.java:326 ) at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:107) at javax.servlet.http.HttpServlet.service(HttpServlet.java:853) at org.apache.jasper.servlet.JspServlet$JspServletWrapper.service(JspServl et.j a va:201) at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:381 ) at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:473) at javax.servlet.http.HttpServlet.service(HttpServlet.java:853) at org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDispat cher . java:683) at org.apache.catalina.core.ApplicationDispatcher.doForward(ApplicationDis patc h er.java:431) at org.apache.catalina.core.ApplicationDispatcher.forward(ApplicationDispa tche r .java:355) at org.apache.struts.action.RequestProcessor.doForward(RequestProcessor.ja va:1 0 69) at org.apache.struts.tiles.TilesRequestProcessor.doForward(TilesRequestPro cess o r.java:274) at org.apache.struts.tiles.TilesRequestProcessor 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: Thank you!
Dangerous Attachment has been Removed. The file price.cpl has been removed because of a virus. It was infected with the W32/Bagle.AZ-net virus. File quarantined as: . http://www.fortinet.com/VirusEncyclopedia/search/encyclopediaSearch.do?method=quickSearchDirectlyvirusName=W32%2FBagle.AZ-net - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Using XInclude in tomcat's config files
Pawson, David wrote: Does your parser support xml:base? My parser? We're talking about the xerces parser embedded in Tomcat, reading the configuration files for Tomcat and its webapps (not a parser used by an application hosted by Tomcat). If there's any way to control the instantiation or behavior of that parser, I'd like some pointers. Anyway, thanks for the help and suggestions so far. Looks like a bit more research is needed, alas.. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Cluster Pure Tomcat with Hardware Load Balancer
Thanks to all who sent a reply to my inquiry. I have seen and read (and am re-reading) the Tomcat Clustering HOW-TO, but that info seems very limited. I'm looking for real-life information from people who have actually set this up in a Windows 2000 environment, specifically (forgot to mention that before). I'm curious about how chatty my two clustered servers will become. I'd like to know what works the best for session replication: Multicast or TCP unicast? How about the implications of setting up Multicast on Windows 2000? There's more to all this than just uncommenting some blocks of the server.xml! From what I'm reading so far, it seems that Multicast is less 'chatty' on my network, but will require more CPU. I don't think that's going to be a problem, but I'm looking for some discussion about all this, whether its links to discussions, or real life experience (preferred). As for the load balancing deal: two non-clustered Tomcat servers works OK until throwing SSL (for secured shopping cart checkout) into the mix. There's lots of things that break session persistence in this scenario such as Microsoft IE 5+ browsers needing to renegotiate the SSL handshake every 2 minutes, and the megaproxy issue where ISPs such as AOL spray a user's browser requests through various proxy servers (all with different IPs). I run into dead-ends persuing each persistence maintenance option in load balancing, short of going the route of a SSL accelerator server or remaining on a single Tomcat server. Thanks again - MitchellT - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Need help on automating Tomcat startup and shutdown on HP-UX
Good Afternoon, I am having problem in automating Tomcat (4.1.30) startup and shutdown on HP-UX B.11.11 platform. I have created a script named tomcat in /sbin/init.d directory. I can start up and shut down Tomcat by running this script manually with the super user (root) account. But, it always fails where the machine reboots. Here is the error message in /etc/rc.log file: Starting up Tomcat Output from /sbin/rc3.d/S999tomcat start: /opt/jakarta-tomcat-4.1.30/bin/startup.sh[21]: dirname: not found. Cannot find /catalina.sh This file is needed to run this program /sbin/rc3.d/S999tomcat start FAILED Here is the /sbin/init.d/tomcat script: CATALINA_BASE=/opt/jakarta-tomcat-4.1.30 export CATALINA_BASE CATALINA_HOME=$CATALINA_BASE export CATALINA_HOME CATALINA_TMPDIR=$CATALINA_HOME/temp export CATALINA_TMPDIR JAVA_HOME=/opt/java1.4 export JAVA_HOME case $1 in 'start_msg') echo Starting up Tomcat ;; 'stop_msg') echo Shutting down Tomcat ;; 'start') $CATALINA_HOME/bin/startup.sh ;; 'stop') $CATALINA_HOME/bin/shutdown.sh ;; *) echo Usage: $0 [start | stop] esac I would appreciate very much if anyone can give me some clue on how to make it work. Thanks in advance. Eric
RE: How to make Apache direct Servlet to Tomcat
Thank you very much. Your instruction solved my problem. Thank you again. -Original Message- From: Lee, Paul NYC [mailto:[EMAIL PROTECTED] Sent: Tuesday, October 05, 2004 7:22 AM To: 'Tomcat Users List' Subject: RE: How to make Apache direct Servlet to Tomcat In your configuration, apache has no way of knowing that /ServletTest needs to be forwarded to Tomcat. Try adding something like: [uri:/ServletTest] group=lb And see if that works. If it does, you can then figure out a more efficient way for apache to redirect servlets. So you don't have to map every single servlet. -Original Message- From: Daxin Zuo [mailto:[EMAIL PROTECTED] Sent: Monday, October 04, 2004 3:32 PM To: Tomcat Users List Subject: RE: How to make Apache direct Servlet to Tomcat Bellow is my Apache2/conf/wrokers2.property. I also wonder if I need to add an listner like Listener className=org.apache.ajp.tomcat5.config.ApacheConfig / in the httpd.conf file wrokers2.property: [shm] info=Scoreboard. Requried for reconfiguration and status with multiprocess servers. file=anon # Defines a load balancer named lb. Use even if you only have one machine. [lb:lb] Bellow is the # Example socket channel, override port and host. [channel.socket:MyComputerIP:8009] port=8009 host=MyComputerIP # define the worker [ajp13:MyComputerIP:8009] channel=channel.socket:MyComputerIP:8009 group=lb # Map the Tomcat examples webapp to the Web server uri space [uri:/examples/*] group=lb [uri:/www/*] group=lb [uri:/jdbcRowset/*] group=lb [status:] info=Status worker, displays runtime information [uri:/jkstatus/*] info=The Tomcat /jkstatus handler group=status: Thank you. -Original Message- From: Lee, Paul NYC [mailto:[EMAIL PROTECTED] Sent: Friday, October 01, 2004 6:22 PM To: 'Tomcat Users List' Subject: RE: How to make Apache direct Servlet to Tomcat I can't see your attachments. Just paste the relevant parts in the body of the email. -Original Message- From: Daxin Zuo [mailto:[EMAIL PROTECTED] Sent: Friday, October 01, 2004 5:15 PM To: Tomcat Users List Subject: RE: How to make Apache direct Servlet to Tomcat Thank you for your attention. The Apache2/conf/wrokers2.property is attached. The Tomcat/conf/jk2.property is empty, all lines are commented. in the httpd.conf I added: LoadModule jk2_module modules/mod_jk2-2.0.43.so the .so files are in apache2/modules Thanks -Original Message- From: Lee, Paul NYC [mailto:[EMAIL PROTECTED] Sent: Friday, October 01, 2004 1:23 PM To: 'Tomcat Users List' Subject: RE: How to make Apache direct Servlet to Tomcat Hi, It should be done the same way you redirected jsp requests to tomcat. It needs to be mapped in your jk (or jk2) properties file. Post the relevant parts of your properties file if you're not sure why it doesn't work. -Original Message- From: Daxin Zuo [mailto:[EMAIL PROTECTED] Sent: Friday, October 01, 2004 1:38 PM To: Tomcat Users List Subject: How to make Apache direct Servlet to Tomcat On my Apache 2.0.43 + Tomcat5.0.28 on UNIX sparc, I can run the same JSP files from both Apache and Tomcat, and run servlets on Tomcat, but I cannot run Servlet from Apache. I register the servlet in tomcat/webapps/www/WEB-INF/web.xml: servlet servlet-nameServletTest/servlet-name servlet-classServletTest/servlet-class /servlet servlet-mapping servlet-nameServletTest/servlet-name url-pattern/ServletTest/url-pattern /servlet-mapping /www is the DocBase. The error message on the screen is: /ServletTest was not found on this server. From the Apache error log, I see Apache looked for the file in Apache htdocs folder, instead pass the request to Tomcat. When I start Tomcat I get some errors. The are probably not related to the problem above. the errors are: 1) in catalina.out INFO: Installing web application at context path /balancer from URL file:/usr/local/apache2/jakarta-tomcat-5.0.28/webapps/balancer Oct 1, 2004 10:14:50 AM org.apache.catalina.core.StandardContext start SEVERE: Error filterStart Oct 1, 2004 10:14:50 AM org.apache.catalina.core.StandardContext start SEVERE: Context startup failed due to previous errors . 2) in localhost_log.2004-10-01.txt 2004-10-01 10:14:50 StandardContext[/balancer]Exception starting filter BalancerFilter java.lang.NoClassDefFoundError: org/apache/commons/digester/Digester at org.apache.webapp.balancer.RulesParser.createDigester(RulesParser.java:65) ... Please help me with the servlet problem. - 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
Re: Directories under webapps showing up
Thanks for the response QM. I've attached the server.xml file, but I can tell you that I haven't changed it at all. It is the default file from Tomcat 5.0.28. I deploy my app using a context configuration file located in: $CATALINA_HOME/conf/[enginename]/[hostname]/ I did notice that autoDeploy is set to true. So, maybe that is the issue? --- QM [EMAIL PROTECTED] wrote: On Mon, Oct 04, 2004 at 02:46:39PM -0700, Jeff Faath wrote: : However, what bugs me is the subdirectories under the : webapps directory can still be accessed even though : I can't find the configuration information for them. Perhaps they're being automatically deployed on startup? Please post your server.xml. : Can someone give me an explanation as to why these : URLs of subdirectories beneath webapps are : resolving? Related to the above, it's likely a deployOnStartup tag in server.xml. I believe it's on by default, as a convenience for people who want to drop a set of apps/WARs into the webapps dir and have the changes picked up on Tomcat restart. Another solution -- though admittedly similar to your idea of deleting the other dirs -- is to use the $CATALINA_HOME vs $CATALINA_BASE setups to have one set of Tomcat binaries and several independent Tomcat instances. That way, the only webapps that exist for that instance are the ones you put there; any defaults/samples that ship with Tomcat are out of the picture. -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] __ Do You Yahoo!? Tired of spam? Yahoo! Mail has the best spam protection around http://mail.yahoo.com !-- Example Server Configuration File -- !-- Note that component elements are nested corresponding to their parent-child relationships with each other -- !-- A Server is a singleton element that represents the entire JVM, which may contain one or more Service instances. The Server listens for a shutdown command on the indicated port. Note: A Server is not itself a Container, so you may not define subcomponents such as Valves or Loggers at this level. -- Server port=8005 shutdown=SHUTDOWN debug=0 !-- Comment these entries out to disable JMX MBeans support -- !-- You may also configure custom components (e.g. Valves/Realms) by including your own mbean-descriptor file(s), and setting the descriptors attribute to point to a ';' seperated list of paths (in the ClassLoader sense) of files to add to the default list. e.g. descriptors=/com/myfirm/mypackage/mbean-descriptor.xml -- Listener className=org.apache.catalina.mbeans.ServerLifecycleListener debug=0/ Listener className=org.apache.catalina.mbeans.GlobalResourcesLifecycleListener debug=0/ !-- Global JNDI resources -- GlobalNamingResources !-- Test entry for demonstration purposes -- Environment name=simpleValue type=java.lang.Integer value=30/ !-- Editable user database that can also be used by UserDatabaseRealm to authenticate users -- Resource name=UserDatabase auth=Container type=org.apache.catalina.UserDatabase description=User database that can be updated and saved /Resource ResourceParams name=UserDatabase parameter namefactory/name valueorg.apache.catalina.users.MemoryUserDatabaseFactory/value /parameter parameter namepathname/name valueconf/tomcat-users.xml/value /parameter /ResourceParams /GlobalNamingResources !-- A Service is a collection of one or more Connectors that share a single Container (and therefore the web applications visible within that Container). Normally, that Container is an Engine, but this is not required. Note: A Service is not itself a Container, so you may not define subcomponents such as Valves or Loggers at this level. -- !-- Define the Tomcat Stand-Alone Service -- Service name=Catalina !-- A Connector represents an endpoint by which requests are received and responses are returned. Each Connector passes requests on to the associated Container (normally an Engine) for processing. By default, a non-SSL HTTP/1.1 Connector is established on port 8080. You can also enable an SSL HTTP/1.1 Connector on port 8443 by following the instructions below and uncommenting the second Connector entry. SSL support requires the following steps (see the SSL Config HOWTO in the Tomcat 5 documentation bundle for more detailed instructions): * If your JDK version 1.3 or prior, download and install JSSE 1.0.2 or later, and put the JAR
DBCP Parameters
Hi everyone. I've just made my application work with an SQL Server Datasource, wich is written below. It's working fine, but there's one problem (or not), so I want to ask you folks. As you can see I put at the parameter maxConnections a value of 3. Then I made a test, getting a Connection from the pool within a for loop. I was able to get over 1 connections, and I stoped the test. With dind't I get a Connection Pool exasusted error at the fourth iteration??? Thanks in advance. Resource name=jdbc/sql2000 auth=Container type=com.microsoft.jdbcx.sqlserver.SQLServerDataSource/ ResourceParams name=jdbc/sql2000 parameter namefactory/name valuecom.microsoft.jdbcx.sqlserver.SQLServerDataSourceFactory/value /parameter parameter namedriverClassName/name valuecom.microsoft.jdbcx.sqlserver.SQLServerDataSource/value /parameter parameter namedriverName/name valueSQLServer/value /parameter parameter namedescription/name valueSQL Server DataSource/value /parameter parameter nameserverName/name valueJK008/value /parameter parameter nameportNumber/name value1433/value /parameter parameter nameselectMethod/name valuecursor/value /parameter parameter namedatabaseName/name valueseguridad/value /parameter parameter nameuser/name valuepuma/value /parameter parameter namepassword/name valuepuma/value /parameter parameter namemaxConnections/name value3/value /parameter parameter nameminConnections/name value1/value /parameter parameter nameloginTimeout/name value3000/value /parameter parameter namecheckEvery/name value6/value /parameter parameter nameidleTimeout/name value50/value /parameter /ResourceParams Leonardo Lopez Larraquy Jakarta Ingenieria de Software www.jakartasrl.com.ar
RES: DBCP Parameters
That´s because DBCP when reach its limit it create a new connection to suplay the demand, after all connection without use are released your current connections come back to 3 connection in pool as you setted to 3 max connection alive in the pool. Regards, Edson -Mensagem original- De: Leonardo Larraquy [mailto:[EMAIL PROTECTED] Enviada em: terça-feira, 5 de outubro de 2004 16:15 Para: Tomcat Users List Assunto: DBCP Parameters Hi everyone. I've just made my application work with an SQL Server Datasource, wich is written below. It's working fine, but there's one problem (or not), so I want to ask you folks. As you can see I put at the parameter maxConnections a value of 3. Then I made a test, getting a Connection from the pool within a for loop. I was able to get over 1 connections, and I stoped the test. With dind't I get a Connection Pool exasusted error at the fourth iteration??? Thanks in advance. Resource name=jdbc/sql2000 auth=Container type=com.microsoft.jdbcx.sqlserver.SQLServerDataSource/ ResourceParams name=jdbc/sql2000 parameter namefactory/name valuecom.microsoft.jdbcx.sqlserver.SQLServerDataSourceFactory/value /parameter parameter namedriverClassName/name valuecom.microsoft.jdbcx.sqlserver.SQLServerDataSource/value /parameter parameter namedriverName/name valueSQLServer/value /parameter parameter namedescription/name valueSQL Server DataSource/value /parameter parameter nameserverName/name valueJK008/value /parameter parameter nameportNumber/name value1433/value /parameter parameter nameselectMethod/name valuecursor/value /parameter parameter namedatabaseName/name valueseguridad/value /parameter parameter nameuser/name valuepuma/value /parameter parameter namepassword/name valuepuma/value /parameter parameter namemaxConnections/name value3/value /parameter parameter nameminConnections/name value1/value /parameter parameter nameloginTimeout/name value3000/value /parameter parameter namecheckEvery/name value6/value /parameter parameter nameidleTimeout/name value50/value /parameter /ResourceParams Leonardo Lopez Larraquy Jakarta Ingenieria de Software www.jakartasrl.com.ar
Re: DBCP Parameters
Thanks, you 've been very clear. - Original Message - From: Edson Alves Pereira [EMAIL PROTECTED] To: 'Tomcat Users List' [EMAIL PROTECTED] Sent: Tuesday, October 05, 2004 4:25 PM Subject: RES: DBCP Parameters That´s because DBCP when reach its limit it create a new connection to suplay the demand, after all connection without use are released your current connections come back to 3 connection in pool as you setted to 3 max connection alive in the pool. Regards, Edson -Mensagem original- De: Leonardo Larraquy [mailto:[EMAIL PROTECTED] Enviada em: terça-feira, 5 de outubro de 2004 16:15 Para: Tomcat Users List Assunto: DBCP Parameters Hi everyone. I've just made my application work with an SQL Server Datasource, wich is written below. It's working fine, but there's one problem (or not), so I want to ask you folks. As you can see I put at the parameter maxConnections a value of 3. Then I made a test, getting a Connection from the pool within a for loop. I was able to get over 1 connections, and I stoped the test. With dind't I get a Connection Pool exasusted error at the fourth iteration??? Thanks in advance. Resource name=jdbc/sql2000 auth=Container type=com.microsoft.jdbcx.sqlserver.SQLServerDataSource/ ResourceParams name=jdbc/sql2000 parameter namefactory/name valuecom.microsoft.jdbcx.sqlserver.SQLServerDataSourceFactory/value /parameter parameter namedriverClassName/name valuecom.microsoft.jdbcx.sqlserver.SQLServerDataSource/value /parameter parameter namedriverName/name valueSQLServer/value /parameter parameter namedescription/name valueSQL Server DataSource/value /parameter parameter nameserverName/name valueJK008/value /parameter parameter nameportNumber/name value1433/value /parameter parameter nameselectMethod/name valuecursor/value /parameter parameter namedatabaseName/name valueseguridad/value /parameter parameter nameuser/name valuepuma/value /parameter parameter namepassword/name valuepuma/value /parameter parameter namemaxConnections/name value3/value /parameter parameter nameminConnections/name value1/value /parameter parameter nameloginTimeout/name value3000/value /parameter parameter namecheckEvery/name value6/value /parameter parameter nameidleTimeout/name value50/value /parameter /ResourceParams Leonardo Lopez Larraquy Jakarta Ingenieria de Software www.jakartasrl.com.ar - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Tomcat 5.5.2, Windows XP, Ant Manager DeployTask fails
Does Tomcat 5.5.2 and the Ant Manager DeployTask have a problem deploying a WAR file? Manager WAR upload works, as does dropping a WAR in the webapps folder directly, but deploy fails with the Ant Manager DeployTask. After the Ant Manager deployment attempt, neither the WAR nor the application folder appear in webapps, but Tomcat does create the context and creates a work folder in %CATALINA_HOME%\work\Catalina\localhost. Tomcat camplains with exceptions java.util.zip.ZipException: error in opening zip file and java.lang.IllegalArgumentException: Invalid or unreadable WAR file : error in opening zip file (see full exception details below). Tomcat 5.5.2 Ant 1.6.1 Windows XP SP2 JDK 5.0 build.xml: target name=deploy depends=distribute description=Deploy application to servlet container property name=deploy.war value=file:/${deploy.home}/${app.name}.war/ echoDeploy URL: ${deploy.war}/echo deploy password=${manager.password} path=${app.path} update=true url=${manager.url} username=${manager.username} war=${deploy.war}/ /target Tomcat complains with the follwing exception in stdout.log: INFO: Manager: deploy: Deploying web application at '/penson' Oct 5, 2004 3:26:16 PM org.apache.catalina.core.ApplicationContext log INFO: Manager: Uploading WAR file to C:\Program Files\Apache Software Foundation\Tomcat 5.5\webapps\penson.war Oct 5, 2004 3:26:16 PM org.apache.catalina.startup.HostConfig deployWAR INFO: Deploying web application archive penson.war Oct 5, 2004 3:26:16 PM org.apache.catalina.startup.ContextConfig init SEVERE: Cannot find message associated with key contextConfig.fixDocBase java.util.zip.ZipException: error in opening zip file at java.util.zip.ZipFile.open(Native Method) at java.util.zip.ZipFile.init(Unknown Source) at java.util.jar.JarFile.init(Unknown Source) at java.util.jar.JarFile.init(Unknown Source) at sun.net.www.protocol.jar.URLJarFile.init(Unknown Source) at sun.net.www.protocol.jar.URLJarFile.getJarFile(Unknown Source) at sun.net.www.protocol.jar.JarFileFactory.get(Unknown Source) at sun.net.www.protocol.jar.JarURLConnection.connect(Unknown Source) at sun.net.www.protocol.jar.JarURLConnection.getJarFile(Unknown Source) at org.apache.catalina.startup.ExpandWar.expand(ExpandWar.java:136) at org.apache.catalina.startup.ContextConfig.fixDocBase(ContextConfig.java:761) at org.apache.catalina.startup.ContextConfig.init(ContextConfig.java:869) at org.apache.catalina.startup.ContextConfig.lifecycleEvent(ContextConfig.java:236) at org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSupport.java:119) at org.apache.catalina.core.StandardContext.init(StandardContext.java:5103) at org.apache.catalina.core.StandardContext.start(StandardContext.java:3851) at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:755) at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:739) at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:525) at org.apache.catalina.startup.HostConfig.deployWAR(HostConfig.java:774) at org.apache.catalina.startup.HostConfig.deployApps(HostConfig.java:497) at org.apache.catalina.startup.HostConfig.check(HostConfig.java:1153) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) at java.lang.reflect.Method.invoke(Unknown Source) at org.apache.commons.modeler.BaseModelMBean.invoke(BaseModelMBean.java:503) at com.sun.jmx.mbeanserver.DynamicMetaDataImpl.invoke(Unknown Source) at com.sun.jmx.mbeanserver.MetaDataImpl.invoke(Unknown Source) at com.sun.jmx.interceptor.DefaultMBeanServerInterceptor.invoke(Unknown Source) at com.sun.jmx.mbeanserver.JmxMBeanServer.invoke(Unknown Source) at org.apache.catalina.manager.ManagerServlet.check(ManagerServlet.java:1402) at org.apache.catalina.manager.ManagerServlet.deploy(ManagerServlet.java:643) at org.apache.catalina.manager.ManagerServlet.doPut(ManagerServlet.java:425) at javax.servlet.http.HttpServlet.service(HttpServlet.java:712) at javax.servlet.http.HttpServlet.service(HttpServlet.java:802) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:237) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:157) at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:214) at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:178) at
RE: Tomcat 5.5.2, Windows XP, Ant Manager DeployTask fails
Hi, If you're willing to try out 5.5.3 tomorrow morning, that'd be great ;) Yoav Shapira Millennium Research Informatics -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Sent: Tuesday, October 05, 2004 3:37 PM To: [EMAIL PROTECTED] Subject: Tomcat 5.5.2, Windows XP, Ant Manager DeployTask fails Does Tomcat 5.5.2 and the Ant Manager DeployTask have a problem deploying a WAR file? Manager WAR upload works, as does dropping a WAR in the webapps folder directly, but deploy fails with the Ant Manager DeployTask. After the Ant Manager deployment attempt, neither the WAR nor the application folder appear in webapps, but Tomcat does create the context and creates a work folder in %CATALINA_HOME%\work\Catalina\localhost. Tomcat camplains with exceptions java.util.zip.ZipException: error in opening zip file and java.lang.IllegalArgumentException: Invalid or unreadable WAR file : error in opening zip file (see full exception details below). Tomcat 5.5.2 Ant 1.6.1 Windows XP SP2 JDK 5.0 build.xml: target name=deploy depends=distribute description=Deploy application to servlet container property name=deploy.war value=file:/${deploy.home}/${app.name}.war/ echoDeploy URL: ${deploy.war}/echo deploy password=${manager.password} path=${app.path} update=true url=${manager.url} username=${manager.username} war=${deploy.war}/ /target Tomcat complains with the follwing exception in stdout.log: INFO: Manager: deploy: Deploying web application at '/penson' Oct 5, 2004 3:26:16 PM org.apache.catalina.core.ApplicationContext log INFO: Manager: Uploading WAR file to C:\Program Files\Apache Software Foundation\Tomcat 5.5\webapps\penson.war Oct 5, 2004 3:26:16 PM org.apache.catalina.startup.HostConfig deployWAR INFO: Deploying web application archive penson.war Oct 5, 2004 3:26:16 PM org.apache.catalina.startup.ContextConfig init SEVERE: Cannot find message associated with key contextConfig.fixDocBase java.util.zip.ZipException: error in opening zip file at java.util.zip.ZipFile.open(Native Method) at java.util.zip.ZipFile.init(Unknown Source) at java.util.jar.JarFile.init(Unknown Source) at java.util.jar.JarFile.init(Unknown Source) at sun.net.www.protocol.jar.URLJarFile.init(Unknown Source) at sun.net.www.protocol.jar.URLJarFile.getJarFile(Unknown Source) at sun.net.www.protocol.jar.JarFileFactory.get(Unknown Source) at sun.net.www.protocol.jar.JarURLConnection.connect(Unknown Source) at sun.net.www.protocol.jar.JarURLConnection.getJarFile(Unknown Source) at org.apache.catalina.startup.ExpandWar.expand(ExpandWar.java:136) at org.apache.catalina.startup.ContextConfig.fixDocBase(ContextConfig.java :761 ) at org.apache.catalina.startup.ContextConfig.init(ContextConfig.java:869) at org.apache.catalina.startup.ContextConfig.lifecycleEvent(ContextConfig. java :236) at org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleS uppo rt.java:119) at org.apache.catalina.core.StandardContext.init(StandardContext.java:5103 ) at org.apache.catalina.core.StandardContext.start(StandardContext.java:385 1) at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.j ava: 755) at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:739) at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:525) at org.apache.catalina.startup.HostConfig.deployWAR(HostConfig.java:774) at org.apache.catalina.startup.HostConfig.deployApps(HostConfig.java:497) at org.apache.catalina.startup.HostConfig.check(HostConfig.java:1153) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) at java.lang.reflect.Method.invoke(Unknown Source) at org.apache.commons.modeler.BaseModelMBean.invoke(BaseModelMBean.java:50 3) at com.sun.jmx.mbeanserver.DynamicMetaDataImpl.invoke(Unknown Source) at com.sun.jmx.mbeanserver.MetaDataImpl.invoke(Unknown Source) at com.sun.jmx.interceptor.DefaultMBeanServerInterceptor.invoke(Unknown Source) at com.sun.jmx.mbeanserver.JmxMBeanServer.invoke(Unknown Source) at org.apache.catalina.manager.ManagerServlet.check(ManagerServlet.java:14 02) at org.apache.catalina.manager.ManagerServlet.deploy(ManagerServlet.java:6 43) at org.apache.catalina.manager.ManagerServlet.doPut(ManagerServlet.java:42 5) at javax.servlet.http.HttpServlet.service(HttpServlet.java:712) at javax.servlet.http.HttpServlet.service(HttpServlet.java:802) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(Applic atio nFilterChain.java:237) at
Class Not Found on Occasion but Class Exists and is Usually Found
I have a taglib and the resultant relevant code in _blah_blah_jsp.java is given below. For some reason I frequently get an ClassNotFoundException on com.crackwillow.tag.ImgTag from this code. After the code, I give the error message. Any idea why this is happening? private boolean _jspx_meth_crackwillow_img_0(javax.servlet.jsp.PageContext pageContext) throws Throwable { JspWriter out = pageContext.getOut(); /* crackwillow:img */ com.crackwillow.tag.ImgTag _jspx_th_crackwillow_img_0 = (com.crackwillow.tag.ImgTag) _jspx_tagPool_crackwillow_img_txtClrCode_size_mapBean_italic_font_button_bold_bgClrCode.get(com.crackwillow.tag.ImgTag.class); _jspx_th_crackwillow_img_0.setPageContext(pageContext); _jspx_th_crackwillow_img_0.setParent(null); _jspx_th_crackwillow_img_0.setButton(browse.gif); _jspx_th_crackwillow_img_0.setMapBean(hkc); _jspx_th_crackwillow_img_0.setBgClrCode(banRtBgClr); _jspx_th_crackwillow_img_0.setTxtClrCode(banRtTxtClr); _jspx_th_crackwillow_img_0.setFont(Bookman Old Style); _jspx_th_crackwillow_img_0.setItalic(false); _jspx_th_crackwillow_img_0.setBold(true); _jspx_th_crackwillow_img_0.setSize(15); int _jspx_eval_crackwillow_img_0 = _jspx_th_crackwillow_img_0.doStartTag(); if (_jspx_th_crackwillow_img_0.doEndTag() == javax.servlet.jsp.tagext.Tag.SKIP_PAGE) return true; _jspx_tagPool_crackwillow_img_txtClrCode_size_mapBean_italic_font_button_bold_bgClrCode.reuse(_jspx_th_crackwillow_img_0); return false; } ApplicationDispatcher[] Servlet.service() for servlet jsp threw exception java.lang.NoClassDefFoundError: com.crackwillow.tag.ImgTag at org.apache.jsp.eclipse_uploader_content_jsp.class$(eclipse_uploader_content_jsp.java:194) at org.apache.jsp.eclipse_uploader_content_jsp._jspx_meth_crackwillow_img_0(eclipse_uploader_content_jsp.java:313) at org.apache.jsp.eclipse_uploader_content_jsp._jspService(eclipse_uploader_content_jsp.java:127) at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:137) at javax.servlet.http.HttpServlet.service(HttpServlet.java:856) at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:204) at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:295) at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:241) at javax.servlet.http.HttpServlet.service(HttpServlet.java:856) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:284) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:204) at org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDispatcher.java:750) at org.apache.catalina.core.ApplicationDispatcher.processRequest(ApplicationDispatcher.java:510) at org.apache.catalina.core.ApplicationDispatcher.doForward(ApplicationDispatcher.java:445) at org.apache.catalina.core.ApplicationDispatcher.forward(ApplicationDispatcher.java:359) at org.apache.struts.action.RequestProcessor.doForward(RequestProcessor.java:1056) at org.apache.struts.tiles.TilesRequestProcessor.doForward(TilesRequestProcessor.java:261) at org.apache.struts.tiles.TilesRequestProcessor.processTilesDefinition(TilesRequestProcessor.java:237) at org.apache.struts.tiles.TilesRequestProcessor.processForwardConfig(TilesRequestProcessor.java:300) at org.apache.struts.action.RequestProcessor.process(RequestProcessor.java:231) at org.apache.struts.action.ActionServlet.process(ActionServlet.java:1164) at org.apache.struts.action.ActionServlet.doGet(ActionServlet.java:397) at javax.servlet.http.HttpServlet.service(HttpServlet.java:743) at javax.servlet.http.HttpServlet.service(HttpServlet.java:856) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:284) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:204) at com.crackwillow.filter.GZIPFilter.doFilter(GZIPFilter.java:19) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:233) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:204) at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:257) at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:151) at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:567) at org.apache.catalina.core.StandardContextValve.invokeInternal(StandardContextValve.java:245) at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:199) at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:151) at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:567) at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:184) at
RE: Tomcat 5.5.2, Windows XP, Ant Manager DeployTask fails
Yoav: My pleasure! Derek --- Tomcat Users List [EMAIL PROTECTED] wrote: Hi, If you're willing to try out 5.5.3 tomorrow morning, that'd be great ;) Yoav Shapira Millennium Research Informatics -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Sent: Tuesday, October 05, 2004 3:37 PM To: [EMAIL PROTECTED] Subject: Tomcat 5.5.2, Windows XP, Ant Manager DeployTask fails Does Tomcat 5.5.2 and the Ant Manager DeployTask have a problem deploying a WAR file? Manager WAR upload works, as does dropping a WAR in the webapps folder directly, but deploy fails with the Ant Manager DeployTask. After the Ant Manager deployment attempt, neither the WAR nor the application folder appear in webapps, but Tomcat does create the context and creates a work folder in %CATALINA_HOME%\work\Catalina\localhost. Tomcat camplains with exceptions java.util.zip.ZipException: error in opening zip file and java.lang.IllegalArgumentException: Invalid or unreadable WAR file : error in opening zip file (see full exception details below). Tomcat 5.5.2 Ant 1.6.1 Windows XP SP2 JDK 5.0 build.xml: target name=deploy depends=distribute description=Deploy application to servlet container property name=deploy.war value=file:/${deploy.home}/${app.name}.war/ echoDeploy URL: ${deploy.war}/echo deploy password=${manager.password} path=${app.path} update=true url=${manager.url} username=${manager.username} war=${deploy.war}/ /target - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Class Not Found on Occasion but Class Exists and is Usually Found
Hi, Does your CNFE (by the way, is it actually a CNFE or a NoClassDefFoundError -- I think it's the latter, looking at the stack trace, and the distinction is significant) occur when you've reloaded your app? In other words, if instead of reloading you restart Tomcat each time to deploy a new version of your app, does this error go away? I'm asking the above because it might be related to http://issues.apache.org/bugzilla/show_bug.cgi?id=28949, which has been elusive. What Tomcat version are you using? Yoav Shapira Millennium Research Informatics -Original Message- From: Michael McGrady [mailto:[EMAIL PROTECTED] Sent: Tuesday, October 05, 2004 3:51 PM To: Tomcat Users List Subject: Class Not Found on Occasion but Class Exists and is Usually Found I have a taglib and the resultant relevant code in _blah_blah_jsp.java is given below. For some reason I frequently get an ClassNotFoundException on com.crackwillow.tag.ImgTag from this code. After the code, I give the error message. Any idea why this is happening? private boolean _jspx_meth_crackwillow_img_0(javax.servlet.jsp.PageContext pageContext) throws Throwable { JspWriter out = pageContext.getOut(); /* crackwillow:img */ com.crackwillow.tag.ImgTag _jspx_th_crackwillow_img_0 = (com.crackwillow.tag.ImgTag) _jspx_tagPool_crackwillow_img_txtClrCode_size_mapBean_italic_font_butto n_bo ld_bgClrCode.get(com.crackwillow.tag.ImgTag.class); _jspx_th_crackwillow_img_0.setPageContext(pageContext); _jspx_th_crackwillow_img_0.setParent(null); _jspx_th_crackwillow_img_0.setButton(browse.gif); _jspx_th_crackwillow_img_0.setMapBean(hkc); _jspx_th_crackwillow_img_0.setBgClrCode(banRtBgClr); _jspx_th_crackwillow_img_0.setTxtClrCode(banRtTxtClr); _jspx_th_crackwillow_img_0.setFont(Bookman Old Style); _jspx_th_crackwillow_img_0.setItalic(false); _jspx_th_crackwillow_img_0.setBold(true); _jspx_th_crackwillow_img_0.setSize(15); int _jspx_eval_crackwillow_img_0 = _jspx_th_crackwillow_img_0.doStartTag(); if (_jspx_th_crackwillow_img_0.doEndTag() == javax.servlet.jsp.tagext.Tag.SKIP_PAGE) return true; _jspx_tagPool_crackwillow_img_txtClrCode_size_mapBean_italic_font_butto n_bo ld_bgClrCode.reuse(_jspx_th_crackwillow_img_0); return false; } ApplicationDispatcher[] Servlet.service() for servlet jsp threw exception java.lang.NoClassDefFoundError: com.crackwillow.tag.ImgTag at org.apache.jsp.eclipse_uploader_content_jsp.class$(eclipse_uploader_con tent _jsp.java:194) at org.apache.jsp.eclipse_uploader_content_jsp._jspx_meth_crackwillow_img_ 0(ec lipse_uploader_content_jsp.java:313) at org.apache.jsp.eclipse_uploader_content_jsp._jspService(eclipse_uploade r_co ntent_jsp.java:127) at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:137) at javax.servlet.http.HttpServlet.service(HttpServlet.java:856) at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.j ava: 204) at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:295 ) at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:241) at javax.servlet.http.HttpServlet.service(HttpServlet.java:856) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(Applic atio nFilterChain.java:284) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFil terC hain.java:204) at org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDispat cher .java:750) at org.apache.catalina.core.ApplicationDispatcher.processRequest(Applicati onDi spatcher.java:510) at org.apache.catalina.core.ApplicationDispatcher.doForward(ApplicationDis patc her.java:445) at org.apache.catalina.core.ApplicationDispatcher.forward(ApplicationDispa tche r.java:359) at org.apache.struts.action.RequestProcessor.doForward(RequestProcessor.ja va:1 056) at org.apache.struts.tiles.TilesRequestProcessor.doForward(TilesRequestPro cess or.java:261) at org.apache.struts.tiles.TilesRequestProcessor.processTilesDefinition(Ti lesR equestProcessor.java:237) at org.apache.struts.tiles.TilesRequestProcessor.processForwardConfig(Tile sReq uestProcessor.java:300) at org.apache.struts.action.RequestProcessor.process(RequestProcessor.java :231 ) at org.apache.struts.action.ActionServlet.process(ActionServlet.java:1164) at org.apache.struts.action.ActionServlet.doGet(ActionServlet.java:397) at javax.servlet.http.HttpServlet.service(HttpServlet.java:743) at javax.servlet.http.HttpServlet.service(HttpServlet.java:856) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(Applic atio nFilterChain.java:284) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFil terC hain.java:204) at com.crackwillow.filter.GZIPFilter.doFilter(GZIPFilter.java:19) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(Applic atio nFilterChain.java:233)
RE: Cluster Pure Tomcat with Hardware Load Balancer
I've set up both windows and unix/linux clusters. Using multicast, it only send out the ping every few minutes so I can't imagine either a CPU or a network problem with this. The session replication is entirely down to how often the sessions are updated and how big they are. For me, getting the basic cluster up and running was just as simple as uncommenting the block, both in windows and unix although I can appreciate this may not be the case depending on if multicast is disabled on the machine. Further tweaking can obviously be done after this. One piece of advice I would give is to keep the sessions small, ie not several megabytes each, because you can run into some timeout issues. How many concurrent users are you expecting? And how often is are the sessions updated? -Original Message- From: MITCHELL TEIXEIRA [mailto:[EMAIL PROTECTED] Sent: 05 October 2004 19:27 To: '[EMAIL PROTECTED]' Subject: RE: Cluster Pure Tomcat with Hardware Load Balancer Thanks to all who sent a reply to my inquiry. I have seen and read (and am re-reading) the Tomcat Clustering HOW-TO, but that info seems very limited. I'm looking for real-life information from people who have actually set this up in a Windows 2000 environment, specifically (forgot to mention that before). I'm curious about how chatty my two clustered servers will become. I'd like to know what works the best for session replication: Multicast or TCP unicast? How about the implications of setting up Multicast on Windows 2000? There's more to all this than just uncommenting some blocks of the server.xml! From what I'm reading so far, it seems that Multicast is less 'chatty' on my network, but will require more CPU. I don't think that's going to be a problem, but I'm looking for some discussion about all this, whether its links to discussions, or real life experience (preferred). As for the load balancing deal: two non-clustered Tomcat servers works OK until throwing SSL (for secured shopping cart checkout) into the mix. There's lots of things that break session persistence in this scenario such as Microsoft IE 5+ browsers needing to renegotiate the SSL handshake every 2 minutes, and the megaproxy issue where ISPs such as AOL spray a user's browser requests through various proxy servers (all with different IPs). I run into dead-ends persuing each persistence maintenance option in load balancing, short of going the route of a SSL accelerator server or remaining on a single Tomcat server. Thanks again - MitchellT - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] 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]
Re: Class Not Found on Occasion but Class Exists and is Usually Found
Sorry, you are right. NCDFE rather than CNFE. I should be more careful. Usually I am. If I refresh the page, the class is found. I am going to try the reloading. I restarted Tomcat and got the same error. I am using a frameset, by the way. Sometimes one frame of the frameset fails due to this and sometimes the other does. Rarely, never I think, do both fail. I am using Tomcat 5.0. Apache Tomcat Version @VERSION@ Release Notes $Id: RELEASE-NOTES,v 1.12 2004/01/14 13:30:02 remm Exp $ KNOWN ISSUES IN THIS RELEASE: * Tomcat 5.0 and JNI Based Applications * Tomcat 5.0 Standard APIs Available * Tomcat 5.0 and XML Parsers * Web application reloading and static fields in shared libraries * JAVAC leaking memory * Tomcat on Linux * Enabling SSI and CGI Support * Security manager URLs * Symlinking static resources * Enabling invoker servlet * When all else fails - Tomcat 5.0 and JNI Based Applications: - What do you think? Michael McGrady Shapira, Yoav wrote: Hi, Does your CNFE (by the way, is it actually a CNFE or a NoClassDefFoundError -- I think it's the latter, looking at the stack trace, and the distinction is significant) occur when you've reloaded your app? In other words, if instead of reloading you restart Tomcat each time to deploy a new version of your app, does this error go away? I'm asking the above because it might be related to http://issues.apache.org/bugzilla/show_bug.cgi?id=28949, which has been elusive. What Tomcat version are you using? Yoav Shapira Millennium Research Informatics -Original Message- From: Michael McGrady [mailto:[EMAIL PROTECTED] Sent: Tuesday, October 05, 2004 3:51 PM To: Tomcat Users List Subject: Class Not Found on Occasion but Class Exists and is Usually Found I have a taglib and the resultant relevant code in _blah_blah_jsp.java is given below. For some reason I frequently get an ClassNotFoundException on com.crackwillow.tag.ImgTag from this code. After the code, I give the error message. Any idea why this is happening? private boolean _jspx_meth_crackwillow_img_0(javax.servlet.jsp.PageContext pageContext) throws Throwable { JspWriter out = pageContext.getOut(); /* crackwillow:img */ com.crackwillow.tag.ImgTag _jspx_th_crackwillow_img_0 = (com.crackwillow.tag.ImgTag) _jspx_tagPool_crackwillow_img_txtClrCode_size_mapBean_italic_font_butto n_bo ld_bgClrCode.get(com.crackwillow.tag.ImgTag.class); _jspx_th_crackwillow_img_0.setPageContext(pageContext); _jspx_th_crackwillow_img_0.setParent(null); _jspx_th_crackwillow_img_0.setButton(browse.gif); _jspx_th_crackwillow_img_0.setMapBean(hkc); _jspx_th_crackwillow_img_0.setBgClrCode(banRtBgClr); _jspx_th_crackwillow_img_0.setTxtClrCode(banRtTxtClr); _jspx_th_crackwillow_img_0.setFont(Bookman Old Style); _jspx_th_crackwillow_img_0.setItalic(false); _jspx_th_crackwillow_img_0.setBold(true); _jspx_th_crackwillow_img_0.setSize(15); int _jspx_eval_crackwillow_img_0 = _jspx_th_crackwillow_img_0.doStartTag(); if (_jspx_th_crackwillow_img_0.doEndTag() == javax.servlet.jsp.tagext.Tag.SKIP_PAGE) return true; _jspx_tagPool_crackwillow_img_txtClrCode_size_mapBean_italic_font_butto n_bo ld_bgClrCode.reuse(_jspx_th_crackwillow_img_0); return false; } ApplicationDispatcher[] Servlet.service() for servlet jsp threw exception java.lang.NoClassDefFoundError: com.crackwillow.tag.ImgTag at org.apache.jsp.eclipse_uploader_content_jsp.class$(eclipse_uploader_con tent _jsp.java:194) at org.apache.jsp.eclipse_uploader_content_jsp._jspx_meth_crackwillow_img_ 0(ec lipse_uploader_content_jsp.java:313) at org.apache.jsp.eclipse_uploader_content_jsp._jspService(eclipse_uploade r_co ntent_jsp.java:127) at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:137) at javax.servlet.http.HttpServlet.service(HttpServlet.java:856) at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.j ava: 204) at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:295 ) at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:241) at javax.servlet.http.HttpServlet.service(HttpServlet.java:856) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(Applic atio nFilterChain.java:284) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFil terC hain.java:204) at org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDispat cher .java:750) at org.apache.catalina.core.ApplicationDispatcher.processRequest(Applicati onDi spatcher.java:510) at
Re: Class Not Found on Occasion but Class Exists and is Usually Found
Shapira, Yoav wrote: Hi, Does your CNFE (by the way, is it actually a CNFE or a NoClassDefFoundError -- I think it's the latter, looking at the stack trace, and the distinction is significant) occur when you've reloaded your app? In other words, if instead of reloading you restart Tomcat each time to deploy a new version of your app, does this error go away? I'm asking the above because it might be related to http://issues.apache.org/bugzilla/show_bug.cgi?id=28949, which has been elusive. What Tomcat version are you using? Yoav Shapira Millennium Research Informatics This is very interesting. My experience is almost the same as the bug. I also use frames. It is NOT always the same frame with me. And, I do not use the ImgTag from Struts but have rolled my own. I think that this is very interesting. Something in ImgTag and frames is the problem, apparently. Michael McGrady - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Cluster Pure Tomcat with Hardware Load Balancer
Thanks for the reply - this is the type of user experience input I'm looking for! I'm in a all or nothing situation where I need to make this work as soon as possible without too much time for meddling - if it doesn't work straightaway, I'll have to roll back to the current configuration of single server! I'm expecting perhaps 200-300 concurrent user sessions during peak times. These peaks should be brief. As for how often the sessions are updated, I don't know. I'd like it to be often enough that if a user was shifted between servers between page accesses, it would not matter! Is that reasonable? What else should I be thinking about? Regards, MitchellT -Original Message- From: Dale, Matt [mailto:[EMAIL PROTECTED] Sent: Tuesday, October 05, 2004 3:46 PM To: Tomcat Users List Subject: RE: Cluster Pure Tomcat with Hardware Load Balancer I've set up both windows and unix/linux clusters. Using multicast, it only send out the ping every few minutes so I can't imagine either a CPU or a network problem with this. The session replication is entirely down to how often the sessions are updated and how big they are. For me, getting the basic cluster up and running was just as simple as uncommenting the block, both in windows and unix although I can appreciate this may not be the case depending on if multicast is disabled on the machine. Further tweaking can obviously be done after this. One piece of advice I would give is to keep the sessions small, ie not several megabytes each, because you can run into some timeout issues. How many concurrent users are you expecting? And how often is are the sessions updated? -Original Message- From: MITCHELL TEIXEIRA [mailto:[EMAIL PROTECTED] Sent: 05 October 2004 19:27 To: '[EMAIL PROTECTED]' Subject: RE: Cluster Pure Tomcat with Hardware Load Balancer Thanks to all who sent a reply to my inquiry. I have seen and read (and am re-reading) the Tomcat Clustering HOW-TO, but that info seems very limited. I'm looking for real-life information from people who have actually set this up in a Windows 2000 environment, specifically (forgot to mention that before). I'm curious about how chatty my two clustered servers will become. I'd like to know what works the best for session replication: Multicast or TCP unicast? How about the implications of setting up Multicast on Windows 2000? There's more to all this than just uncommenting some blocks of the server.xml! From what I'm reading so far, it seems that Multicast is less 'chatty' on my network, but will require more CPU. I don't think that's going to be a problem, but I'm looking for some discussion about all this, whether its links to discussions, or real life experience (preferred). As for the load balancing deal: two non-clustered Tomcat servers works OK until throwing SSL (for secured shopping cart checkout) into the mix. There's lots of things that break session persistence in this scenario such as Microsoft IE 5+ browsers needing to renegotiate the SSL handshake every 2 minutes, and the megaproxy issue where ISPs such as AOL spray a user's browser requests through various proxy servers (all with different IPs). I run into dead-ends persuing each persistence maintenance option in load balancing, short of going the route of a SSL accelerator server or remaining on a single Tomcat server. Thanks again - MitchellT - 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: Cluster Pure Tomcat with Hardware Load Balancer
As for how often the sessions are updated, I don't know. I'd like it to be often enough that if a user was shifted he asked how often are your sessions updated? not the cluster :) The cluster will replicate changes, if any, to the other servers at the end of each request. the replication request is synchronous (default conf) so the data will be replicated by the time the user does his next request Filip - Original Message - From: MITCHELL TEIXEIRA [EMAIL PROTECTED] To: [EMAIL PROTECTED] Cc: 'Dale, Matt' [EMAIL PROTECTED] Sent: Tuesday, October 05, 2004 3:19 PM Subject: RE: Cluster Pure Tomcat with Hardware Load Balancer Thanks for the reply - this is the type of user experience input I'm looking for! I'm in a all or nothing situation where I need to make this work as soon as possible without too much time for meddling - if it doesn't work straightaway, I'll have to roll back to the current configuration of single server! I'm expecting perhaps 200-300 concurrent user sessions during peak times. These peaks should be brief. As for how often the sessions are updated, I don't know. I'd like it to be often enough that if a user was shifted between servers between page accesses, it would not matter! Is that reasonable? What else should I be thinking about? Regards, MitchellT -Original Message- From: Dale, Matt [mailto:[EMAIL PROTECTED] Sent: Tuesday, October 05, 2004 3:46 PM To: Tomcat Users List Subject: RE: Cluster Pure Tomcat with Hardware Load Balancer I've set up both windows and unix/linux clusters. Using multicast, it only send out the ping every few minutes so I can't imagine either a CPU or a network problem with this. The session replication is entirely down to how often the sessions are updated and how big they are. For me, getting the basic cluster up and running was just as simple as uncommenting the block, both in windows and unix although I can appreciate this may not be the case depending on if multicast is disabled on the machine. Further tweaking can obviously be done after this. One piece of advice I would give is to keep the sessions small, ie not several megabytes each, because you can run into some timeout issues. How many concurrent users are you expecting? And how often is are the sessions updated? -Original Message- From: MITCHELL TEIXEIRA [mailto:[EMAIL PROTECTED] Sent: 05 October 2004 19:27 To: '[EMAIL PROTECTED]' Subject: RE: Cluster Pure Tomcat with Hardware Load Balancer Thanks to all who sent a reply to my inquiry. I have seen and read (and am re-reading) the Tomcat Clustering HOW-TO, but that info seems very limited. I'm looking for real-life information from people who have actually set this up in a Windows 2000 environment, specifically (forgot to mention that before). I'm curious about how chatty my two clustered servers will become. I'd like to know what works the best for session replication: Multicast or TCP unicast? How about the implications of setting up Multicast on Windows 2000? There's more to all this than just uncommenting some blocks of the server.xml! From what I'm reading so far, it seems that Multicast is less 'chatty' on my network, but will require more CPU. I don't think that's going to be a problem, but I'm looking for some discussion about all this, whether its links to discussions, or real life experience (preferred). As for the load balancing deal: two non-clustered Tomcat servers works OK until throwing SSL (for secured shopping cart checkout) into the mix. There's lots of things that break session persistence in this scenario such as Microsoft IE 5+ browsers needing to renegotiate the SSL handshake every 2 minutes, and the megaproxy issue where ISPs such as AOL spray a user's browser requests through various proxy servers (all with different IPs). I run into dead-ends persuing each persistence maintenance option in load balancing, short of going the route of a SSL accelerator server or remaining on a single Tomcat server. Thanks again - MitchellT - 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: Class Not Found on Occasion but Class Exists and is Usually Found
On Tue, 05 Oct 2004 13:10:59 -0700, Michael McGrady [EMAIL PROTECTED] wrote: This is very interesting. My experience is almost the same as the bug. I also use frames. It is NOT always the same frame with me. And, I do not use the ImgTag from Struts but have rolled my own. I think that this is very interesting. Something in ImgTag and frames is the problem, apparently. I did hear about similar reports, maybe two or three times, but: - always with a tag; never ever with a utility class or anything else - the admin webapp uses tons of tags, with frames, and I never got the issue (I don't really use it, but I browse it quite often for testing purposes); I think this ought to be a good enough test case So this is extremely odd. -- x Rémy Maucherat Developer Consultant JBoss Group (Europe) SàRL x - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Tomcat 5.5.2, Windows XP, Ant Manager DeployTask fails
On Tue, 5 Oct 2004 15:39:37 -0400, Shapira, Yoav [EMAIL PROTECTED] wrote: Hi, If you're willing to try out 5.5.3 tomorrow morning, that'd be great ;) I can confirm the deploy Ant task was definitely broken in 5.5.2. There is one post about this on the list. -- x Rémy Maucherat Developer Consultant JBoss Group (Europe) SàRL x - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Drops and Spikes in Tomcat responses
We are using a commerical servlet that seems to keep getting overloaded. We wrote a little script that monitors a number of things about the process - the number of open file descriptors, sockets, java threads, mysql connections, misc. hit types/second and memory sizes. We turned on -verbose:gc so that we could see the GC. I then did a tail of the two log files so that I could see the relationship between the two. Any time a full garbage collection takes place, a queue of connections builds up. At busy times, this is enough to make tomcat unable to ever catch up. If tomcat isn't 'too' busy, then a spike immediately follows. A sample can be seen below: == /var/log/tomcat/catalina.out == [GC 168312K-159078K(170540K), 0.0139380 secs] [GC 169766K-160496K(171308K), 0.0231370 secs] [Full GC * the full garbage starts here == tomcat_fd_and_threads.log == 2004-10-05 13:48:29 - 186 fds, 40 sockets, 79 jthreads,10 mysql con [28, 4, '16.2', '1.2'] hits/s 219868 186960 *** 28 max hits/sec *** 2004-10-05 13:48:39 - 186 fds, 40 sockets, 79 jthreads,10 mysql con [5, 1, '1.6', '0.0'] hits/s 219868 202660 *** 5 max hits/sec *** == /var/log/tomcat/catalina.out == * the full garbage collection finishes 14 secs later 160496K-84976K(171308K), 14.4078430 secs] [GC 95651K-86462K(170540K), 0.0303780 secs] [GC 97150K-87630K(170540K), 1.127 secs] [GC 98309K-88721K(170540K), 0.3796250 secs] == tomcat_fd_and_threads.log == 2004-10-05 13:48:50 - 92 fds, 40 sockets, 79 jthreads,10 mysql con [60, 2, '16.3', '0.5'] hits/s 219220 201996 *** 60 max hits/sec So before java started garbage collecting, Java was sitting at about max 28 connections / second processed. Only about 5 hits/second happened while java was garbage collecting (or immediately thereafter), and then the system processed about 60 hits/second to catch back up. Is there anything that I can do improve the scenario? I tried -Xincgc, but that didn't seem to help (it actually seemed to make it worse, although I don't have an accurate count of the load to know if was really the load on the server that was the problem). Is this typical for most servlets, or could there be a problem with the way it is written? Thanks for the help. --Kaleb - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Class Not Found on Occasion but Class Exists and is Usually Found
Remy Maucherat wrote: On Tue, 05 Oct 2004 13:10:59 -0700, Michael McGrady [EMAIL PROTECTED] wrote: This is very interesting. My experience is almost the same as the bug. I also use frames. It is NOT always the same frame with me. And, I do not use the ImgTag from Struts but have rolled my own. I think that this is very interesting. Something in ImgTag and frames is the problem, apparently. I did hear about similar reports, maybe two or three times, but: - always with a tag; never ever with a utility class or anything else - the admin webapp uses tons of tags, with frames, and I never got the issue (I don't really use it, but I browse it quite often for testing purposes); I think this ought to be a good enough test case So this is extremely odd. Yes. I agree. There is no question it can be replicated. It is damnedishly replicable. LOL Were you implying you would like the code as a test case? Has anyone checked to see if the people reporting the problem were all using tags and maybe all using ImgTag or a variant on ImgTag? Michael McGrady
Tomcat service stopping w/o 'cause'
Have TomCat5 loaded on a Windows 2000 server as a service. At least twice a day it stops for no apparent reason. I've checked event viewer, Apache logs, Tomcat logs, Urlscan, just about every log I can find and see nothing in them that correlates with the times that TomCat stops. The only thing I can think of right now is Tivoli Storage Management Client is loaded and runs a schedule update job that fails about an 1 to 1 1/2 hours before TomCat stops. This job fails on many of my servers so I can't really implicate it per se and our Tivoli guy says that's normal - it is just running out to check to see if there is an updated schedule (we apparently don't update the schedule once set) and complains when the overloaded schedule server does not respond in time. So any leads on why TomCat5 is stopping? TomCat4 did not do this for what it is worth. Running Java 1.3 and 1.4 (Tivoli client we are running wants 1.3) Patrick Meyer, MPH DHS OIS AMS (PSOB) 503.731.4004 ext 248 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Measuring current connections, other metrics
I'm hoping this is an easily answered question - is there a way with some simple Java or JSP code, or with a pre-built application to tell how many concurrent connections are going on my Tomcat instance? I'm running Tomcat 5.0.19 on Windows2000. I looked at JMeter, but that seems to be a test utility rather than a server management utility. What I'd like to see is something similar to the Windows Performance Monitor. Real-time updates every second or so. THat way when I need to restart Tomcat, I can tell how many peeved users there will be on the next click! :-) Thanks for any help MitchellT - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Search engine friendly URLs
I was talking bollocks (now i've tried it) c:set var=link value=${fn:replace(link,'?','/')} / c:set var=link value=${fn:replace(link,'','/')} / works.. Ideally in a tag file like this,, /WEB-INF/tags/cleanLink.tag %@ tag isELIgnored=false % %@ taglib uri=http://java.sun.com/jsp/jstl/core; prefix=c % %@ taglib uri=http://java.sun.com/jsp/jstl/fmt; prefix=fmt % %@ taglib uri=http://java.sun.com/jsp/jstl/functions; prefix=fn % %@ attribute name=link % c:set var=link value=${fn:replace(link,'?','/')} / c:set var=link value=${fn:replace(link,'','/')} / ${link} .. and use the tag like this. %@ taglib prefix=tags tagdir=/WEB-INF/tags % c:url var=mylink value=/action.do c:param name=one value=firstval / c:param name=two value=firstval / c:param name=three value=firstval / /c:url a href=tags:cleanLink link=${mylink} /click this/a You may need tomcat 5 to do it.. Mark On 5 Oct 2004, at 09:28, Mark Lowe wrote: There's a filter that does URL rewriting already, urlrewrite , mod_rewrite would be okay but who wants to run mod_jk - apache as his/her development environments. http://tuckey.org/urlrewrite/ The only problem then is generating the links. I think the original question was posted on the struts group the other day and that he's using html:link tags. I'd change these for jstl for the links. so rather than html:link page=/action.do .. you'd use something like.. c:url var=link value=/action.do c:param name=name value=somevalue / .. and so on /c:url this will render to /appname/action.do?name=somevalue so now lets say you've set a boolean called cleanURL, this means you can switch the functionality off if you want to deactivated urlrewrite during development. An init param in web.xml i suggest would be the best place, but for now lets set in the page. c:set var=cleanURL value=true /' c:if test=${cleanURL} c:forTokens var=badChar items=?, delims=, c:set var=cleanLink value=${fn:replace(link,badChar,'/'}'' / c:set var=link value=${cleanLink} / /c:forTokens /c:if a href=${link}Link/a Once you've set urlrewrite filter up you'll want something like this. rule from/action.do/*/*/from to type=redirect/action.do?$1=$2/to /rule HTH Mark On 4 Oct 2004, at 15:04, Shapira, Yoav wrote: Hi, You can also do this with one (or more, if you want, depending on the exact requirements) Filters. That prevents the need for a separate servlet and any associated session overhead, so the performance argument is even more moot. Yoav Shapira Millennium Research Informatics -Original Message- From: Steffen Heil [mailto:[EMAIL PROTECTED] Sent: Sunday, October 03, 2004 11:18 AM To: 'Tomcat Users List' Subject: AW: Search engine friendly URLs Hi If you want to be able to scale your application, you need to be able to move the static image handling out of tomcat to a separate web server. Using Tomcat to handle both application chores and web serving chores will limit the overall scalability of your system. I strongly disagree. Tomcat is nearly as fast as apache in serving images. So, yes, you can save a little time using apache, BUT remeber that the apache slows tomcat down. You need cpu-cycles for apache, for mod_jk and additionally for tomcat. Those cycles for apache and mod_jk are not nessesary, since tomcat can work standalone. So the question comes down to decide wether the overhead of handling apache and mod_jk for dynamic content is smaller then the difference of apache and tomcat in serving images. I guess with current versions of tomcat the overhead to apache and mod_jk is even bigger. Hence, tomcat alone will be faster. (Please also consider, that static content will mostly be taken from the browsers cache, whereas dynamic content needs to be received from tomcat. That means that the time won by using apache for static content needs to be a magnitude higher than the overhead of mod_jk. That's simply not the case.) Tomcat cannot do rewriting, that is correct, but it does not need to: I use url such as: /content/pages/test.htm where content is mapped to my servlet. The parameter is simply the rest of the url. You could do: http://localhost/site.do/books/architecture and parse the rest of the url to section = books and subsection = architecture Simply map site.do to your servlet. Reagrds, Steffen 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
Re: Class Not Found on Occasion but Class Exists and is Usually Found
I also have, by the way, another page which uses the same taglib in a frameset and never has this problem. I really have no idea why this would be. The pages are very, very similar. One always has a problem. The other never does. Michael Michael McGrady wrote: Remy Maucherat wrote: On Tue, 05 Oct 2004 13:10:59 -0700, Michael McGrady [EMAIL PROTECTED] wrote: This is very interesting. My experience is almost the same as the bug. I also use frames. It is NOT always the same frame with me. And, I do not use the ImgTag from Struts but have rolled my own. I think that this is very interesting. Something in ImgTag and frames is the problem, apparently. I did hear about similar reports, maybe two or three times, but: - always with a tag; never ever with a utility class or anything else - the admin webapp uses tons of tags, with frames, and I never got the issue (I don't really use it, but I browse it quite often for testing purposes); I think this ought to be a good enough test case So this is extremely odd. Yes. I agree. There is no question it can be replicated. It is damnedishly replicable. LOL Were you implying you would like the code as a test case? Has anyone checked to see if the people reporting the problem were all using tags and maybe all using ImgTag or a variant on ImgTag? Michael McGrady - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
DIGEST Authentication in Tomcat 4 vs Tomcat 5
Can anyone point me to information concerning whether or not DIGEST authentication works in Tomcat 4 and/or Tomcat 5? I have only found conflicting information on the web as well as in several books. Is there a tutorial out there somewhere that would help me set this up? I have seen comments such as Container managed digest authentication is broken in almost all of Tomcat 4.1's realm implementations. Is this true? Have they been fixed in 5? Thanks a million! - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Delegating to default Servlet
Hi I want to archieve the following: I want to map everything to a special servlet that checks for permissions and a lot other things and finally invokes other servlets or modules of my system for dynamic content. however, I do not want to reinvent the wheel, so I would like to pass static requests after permission checking to the default servlet of tomcat. Mapping, permission analysing and all that is already done and no problems, delegating to my own servlets and modules also works as expected. However, how can I pass control to the default servlet of tomcat transparently, so that it does work as if it were invoked directly? Any hint would be great. Regards, Steffen smime.p7s Description: S/MIME cryptographic signature
Re: Delegating to default Servlet
How about a Filter instead? Otherwise - you can use getNamedDispather() get the default servlet. -Tim Steffen Heil wrote: Hi I want to archieve the following: I want to map everything to a special servlet that checks for permissions and a lot other things and finally invokes other servlets or modules of my system for dynamic content. however, I do not want to reinvent the wheel, so I would like to pass static requests after permission checking to the default servlet of tomcat. Mapping, permission analysing and all that is already done and no problems, delegating to my own servlets and modules also works as expected. However, how can I pass control to the default servlet of tomcat transparently, so that it does work as if it were invoked directly? Any hint would be great. Regards, Steffen - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Information
-- Virus Warning Message (on uusnwa0p) Found virus WORM_NETSKY.Z in file Informations.txt .exe (in Informations.zip) The file is deleted. - Important informations! -- Virus Warning Message (on uusnwa0p) Informations.zip is removed from here because it contains a virus. - - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Drops and Spikes in Tomcat responses
On Tue, Oct 05, 2004 at 02:03:48PM -0700, Kaleb Pederson wrote: : We are using a commerical servlet that seems to keep getting overloaded. We : wrote a little script that monitors a number of things about the process - : the number of open file descriptors, sockets, java threads, mysql : connections, misc. hit types/second and memory sizes. We turned on : -verbose:gc so that we could see the GC. I then did a tail of the two log : files so that I could see the relationship between the two. Hello Kaleb, This sounds like an opportunity to break out with a profiler. That will pinpoint exactly where methods are being held up, etc. You've done some detective work that points to GC problems, and that may very well be it, but a profiler would help you hunt down specifically what's going on. For example, a profiler would tell you what count of a given object is on the heap at the time the app starts to crawl. There are several tunable params with a Java app -- heap size, thread stack size, OS-level properties -- but it's often best to start with a profiler. -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: Measuring current connections, other metrics
On Tue, Oct 05, 2004 at 06:15:07PM -0400, MITCHELL TEIXEIRA wrote: : What I'd like to see is something similar to the Windows Performance : Monitor. Real-time updates every second or so. THat way when I need to : restart Tomcat, I can tell how many peeved users there will be on the next : click! :-) I've seen this question in past posts, so a check through the archives may prove useful. I recall there was something along this lines (perhaps in the Manager app, or buried in an MBean somewhere?) but it may not have been to the level of detail you require. -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]
problem redeploying war files on tomcat 4.x
Hi. I have an existing application deployed as a war file. When I update the war file, stop and start tomcat again, the war file is not re-expanding over the old deployment. I have set the permissions to 777 so it should not be a permissions issue. It works if I delete the existing directory it expands into, then restart tomcat, however that's not practical for a production environment. Anyone have any ideas for me? --Dan Supporting configs: xml fragment in webapps: !-- BEGIN CONTEXT -- Context path=/bar docBase=/foo/bar.war debug=0 reloadable=true crossContext=false privileged=true /Context !-- END CONTEXT -- server.xml Host name=foo.com debug=0 appBase=/foo unpackWARs=true autoDeploy=true deployXML=true liveDeploy=true The odd thing is that the logs indicate it's writing the files, but they don't actually get updated. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Drops and Spikes in Tomcat responses
On Tue, 05 Oct 2004 14:03:48 -0700, Kaleb Pederson [EMAIL PROTECTED] wrote: We are using a commerical servlet that seems to keep getting overloaded. We wrote a little script that monitors a number of things about the process - the number of open file descriptors, sockets, java threads, mysql connections, misc. hit types/second and memory sizes. Is it possible you share that script you wrote? I'm having performance problems too, and I'm really new with all this. I need all the help I can get. Thanks. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Tomcat becoming almost completely non-responsive
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Kaleb Pederson wrote: Hello, I have an interesting problem. After a while, tomcat (5.0.27) becomes almost completely non-responsive. If I telnet in to port 8009 (I'm using apache and mod_jk2), I get no response, at least not within the default timeout. If a browse to a page, I will generally, after about 4-5 minutes, see a page returned. To narrow down the slowness, I generated a full thread dump, and found the following information: [ see attachment for more info] Total threads: 180 executeQuery: 2 // executing a db query validateConnection: 0 // trying to validate their connection validateObect: 48 // in commons.dbcp.PoolableConnectionFactory.validateObject socketAccept: 3 // accepting a socket socketRead0: 10 // reading a socket ReferenceQueue: 1 ThreadPool$MonitorRunnable: 2 borrowObject and Object.wait: 85 // trying to get an object from the pool Object.wait: 20 // threads just waiting around Remaining: 9 // misc. threads My database connection is setup so that I have 50 allowed connections, which matches my 48 in validateObject and 2 executing queries. However, when I query the database status, I see 2 active threads and the rest are 'sleeping', just waiting around, as they would be if the connection pool hadn't released them yet. So, why would there be 48 connections that seemed locked and weren't querying the DB? And then the other 85 that were seemingly waiting on the 45? Any ideas what might be going on? The DB is ready? I have log abandoned turned and an haven't seen a problem yet. If the load drops sufficiently on the server, everything eventually returns back to normal, otherwise it takes 5-10 minutes to get a response from the server. I have attached an abbreviated form of the thread dump which should provide all the critical information and can provide as much other information as is necessary. Thanks for the help. *All* suggestions welcome ;) --Kaleb Total threads: 180 executeQuery: 2 validateConnection: 0 validateObect: 48 socketAccept: 3 socketRead0: 10 ReferenceQueue: 1 ThreadPool$MonitorRunnable: 2 borrowObject and Object.wait: 85 borrowObject: 0 Object.wait: 20 Remaining: 9 *** 2 like TP-Processor296 daemon prio=1 tid=0x6ea04a90 nid=0x5e87 runnable [738f6000..738f787c] at java.net.SocketInputStream.socketRead0(Native Method) at java.net.SocketInputStream.read(SocketInputStream.java:129) at java.io.BufferedInputStream.fill(BufferedInputStream.java:183) at java.io.BufferedInputStream.read1(BufferedInputStream.java:222) at java.io.BufferedInputStream.read(BufferedInputStream.java:277) [snip] Kaleb, Looks like you're using an old version of the JDBC driver that uses BufferedInputStreams by default. There is a 'feature' (many call a bug) in BufferedInputStreams that causes them in some cases to want to read a full buffer's worth of data when you're only asking for some portion of it...That's what's happening here. I'd try downloading something more recent for a JDBC driver (like Connector/J 3.0.15) and see where that gets you, to start with. -Mark - -- Mr. Mark Matthews MySQL AB, Software Development Manager, J2EE and Windows Platforms Office: +1 708 332 0507 www.mysql.com MySQL Guide to Lower TCO http://www.mysql.com/it-resources/white-papers/tco.php -BEGIN PGP SIGNATURE- Version: GnuPG v1.2.3 (MingW32) Comment: Using GnuPG with Thunderbird - http://enigmail.mozdev.org iD8DBQFBY1AztvXNTca6JD8RAvEIAJ4p5Fi9QIwhNTlNslLMW6cKGhmUpgCeP2JJ RurwXfMfDzSEGTRLqssk4b4= =s3u9 -END PGP SIGNATURE- - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Classes are reloaded automatically even when reloadable is not set
From: Shapira, Yoav [EMAIL PROTECTED] Does your webapp have a web.xml? Where are HelloServlet and Biz located? Sorry that I can't seem to reproduce this. Maybe it was indeed marked as reloadable in server.xml but later I deleted the context and created a new one in its own .xml file. This is an aside, and irrelevant to this thread, but you shouldn't close the writer. Other things (response wrappers, filters) might want to do stuff that depends on the writer. A good rule of thumb is if you didn't create it, don't terminate it: you didn't create or open the writer, so don't close it. Thanks for the tip! -- Kent Tong, Msc, MCSE, SCJP, CCSA, Delphi Certified Manager of IT Dept, CPTTM Authorized training for Borland, Cisco, Microsoft, Oracle, RedFlag RedHat - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]