Re: improved
Your document. Attachment: No Virus found Norton AntiVirus - www.symantec.de - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Lib directory
Hello, I am developping a web application using several servlets. And I was wondering how could I add sub-directory in the lib directory of my webapp. I need something like 20 jar files and without organization, it is a big mess. I just don't know how to make tomcat know that I am using sub-directory in the lib directory. Thanx Doud - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
OutOfMemoryError: unable to create new native thread
Greetings. I am periodically having to restart a normally very stable tomcat 5 instance due to: OutOfMemoryError: unable to create new native thread Now, as far as I understand the following are the reasons for this: - Actually ran out of memory - Hit max # of threads allowed to run (OS dependant?) - Ran out of file handles - File handles include open files AND sockets - (?) Your JVM is bigger than the max process size allowed - Other things I don't know Does anyone have any tips on how to track this sucker down? The OS is Windows 2000 Server Jdk1.4.2_01 Tomcat 5.0.27 How do you increase the max thread count at an OS level? Tomcat seems fine as the heap is never huge at the time of the memory (in fact only 40% MAX utilisation)? Thanks in advance! Carl - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Problem with logging in Eclipse
Hi guys I have the same problem and it's driving me nuts. I have a run configuration in Eclipse 3.0 for tomcat 4.1.18 and I call bootstrap.jar directly within eclipse to start tomcat. The only jars I put in the run configuration class path are the tomcat ones. This starts tomcat as it would be normally run and tomcat then inits the webapps directory and creates the classpath for each webapp based on the contents of the WEB-INF/lib. I have commons-logging.jar in my WEB-INF/lib as it's required by some code. This has problems finding log4j even though it's there. When I send in a request that uses com.sun.xml.messaging.saaj.soap.dom4j.ElementFactory tomcat throws an exception into Catalina.out log showing the following stack trace below. Now, if I put log4j.jar into the run configuration class path the problem goes away? Why can't tomcat find this jar under Eclipse 3 However, because I have multiple webapps running, the logging for the different webapps is the same as the log4j.jar is now global so the last webapp to init sets the logging scheme and location. Painful. Thanks Donie 2004-10-28 11:14:41 StandardWrapperValve[webclient]: Servlet.service() for servlet webclient threw exception javax.servlet.ServletException: Servlet execution threw an exception at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(Application FilterChain.java:269) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterCh ain.java:193) at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.ja va:260) at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invok eNext(StandardPipeline.java:643) at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:480) at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:995) at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.ja va:191) at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invok eNext(StandardPipeline.java:643) at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase .java:493) at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invok eNext(StandardPipeline.java:641) at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:480) at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:995) at org.apache.catalina.core.StandardContext.invoke(StandardContext.java:2415) at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:180 ) at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invok eNext(StandardPipeline.java:643) at org.apache.catalina.valves.ErrorDispatcherValve.invoke(ErrorDispatcherValve. java:170) at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invok eNext(StandardPipeline.java:641) at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:172 ) at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invok eNext(StandardPipeline.java:641) at org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:509) at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invok eNext(StandardPipeline.java:641) at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:480) at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:995) at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java :174) at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invok eNext(StandardPipeline.java:643) at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:480) at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:995) at org.apache.catalina.connector.http.HttpProcessor.process(HttpProcessor.java: 1040) at org.apache.catalina.connector.http.HttpProcessor.run(HttpProcessor.java:1151 ) at java.lang.Thread.run(Thread.java:534) - Root Cause - java.lang.NoClassDefFoundError: org/apache/log4j/Layout at org.apache.commons.logging.impl.Log4jFactory.getInstance(Log4jFactory.java:1 40) at org.apache.commons.logging.impl.LogFactoryImpl.getInstance(LogFactoryImpl.ja va:257) at com.sun.xml.messaging.saaj.soap.dom4j.ElementFactory.clinit(ElementFactory .java:84) at com.sun.xml.messaging.saaj.soap.dom4j.EnvelopeFactoryImpl.createEnvelope(Env elopeFactoryImpl.java:67) at com.sun.xml.messaging.saaj.soap.SOAPPartImpl.getEnvelope(SOAPPartImpl.java:8 7) at com.tecnomen.mms.client.eai.SOAPEncoder.decode(SOAPEncoder.java:256) at com.tecnomen.mms.client.eai.MessageFactory.createMIMEMessage(MessageFactory. java:340) at
No Images Displayed
Hi, We have just moved to a new server with tomcat 5 and apache 2 which are linked using modjk. I have uploaded a working version of an application to the webapps directory on the server. My problem is when I try and access the login page of the application none of the images or style sheets are being loaded and all I see is a plain page with some text and username and password text boxes. Would any of you know what is causing this? Thanks, Ciaran
Re: JNDI Resources in web.xml
Hi. As I understand it from lurking on this list a very long time, servlet spec 2.3 and earlier validated the web.xml file on a DTD. DTDs require the elements be in the right order and tomcat will throw an exception when the webapp is deployed with elements out of order. Servlet Spec 2.4 web.xml files are validated against a schema and don't suffer that limitation. --David Steve Kirk wrote: that section opens by talking about the web-app element and says All sub elements under this element can be in an arbitrary order. so it seems that even if orderingused to be an issue, it's not any longer. Also, the docs caution that I should respect element ordering in the web.xml file, but they don't tell me what the ordering should be. Where is this ordering documented? SRV.13.4 of the Servlet Spec lists the order. http://www.jcp.org/aboutJava/communityprocess/final/jsr154/ - 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: JNDI Resources in web.xml
The question is not 'DTD or schema'. The question is, 'does the 2.4 schema relax the order, and does Tomcat comply?' -Original Message- From: David Smith [mailto:[EMAIL PROTECTED] Sent: Thursday, October 28, 2004 7:49 AM To: Tomcat Users List Subject: Re: JNDI Resources in web.xml Hi. As I understand it from lurking on this list a very long time, servlet spec 2.3 and earlier validated the web.xml file on a DTD. DTDs require the elements be in the right order and tomcat will throw an exception when the webapp is deployed with elements out of order. Servlet Spec 2.4 web.xml files are validated against a schema and don't suffer that limitation. --David Steve Kirk wrote: that section opens by talking about the web-app element and says All sub elements under this element can be in an arbitrary order. so it seems that even if orderingused to be an issue, it's not any longer. Also, the docs caution that I should respect element ordering in the web.xml file, but they don't tell me what the ordering should be. Where is this ordering documented? SRV.13.4 of the Servlet Spec lists the order. http://www.jcp.org/aboutJava/communityprocess/final/jsr154/ - 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: No Images Displayed
if you right click on one of the missing images and view properties, what does the URL look like? does it point to where you would expect? this sounds like the URL to the images is not visible via the web server AC -Original Message- From: Ciaran Hanley [mailto:[EMAIL PROTECTED] Sent: 28 October 2004 12:32 To: Tomcat User Mailing List Subject: No Images Displayed Hi, We have just moved to a new server with tomcat 5 and apache 2 which are linked using modjk. I have uploaded a working version of an application to the webapps directory on the server. My problem is when I try and access the login page of the application none of the images or style sheets are being loaded and all I see is a plain page with some text and username and password text boxes. Would any of you know what is causing this? Thanks, Ciaran FONT SIZE=1 FACE=VERDANA,ARIAL COLOR=BLUE --- QAS Ltd. Developers of QuickAddress Software a href=http://www.qas.com;www.qas.com/a Registered in England: No 2582055 Registered in Australia: No 082 851 474 --- /FONT - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: c:forEach within custom tag definition
... I wanted to raise it here for suggestions before submitting a bug report... Just as well I didn't do a bug report! It's now resolved. The book I was using didn't have the necessary info, but I've now found it and fixed the problem. The attribute in the tag file defaults to type 'java.lang.String', so for my case I needed to make the following change: %@ attribute name=list required=true % To %@ attribute name=list required=true type=java.util.Collection % - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
problems with apache-tomcat connection ...
Hi everybody, sorry if this is a silly question because I am not an expert, but I was looking for the solution to my problem consulting to google and nobody has answered about the following problems with apache-tomcat connection: a) I have Solaris 8, apache 2.0.47, jdk 1.4.2, tomcat 4.1.24 and the binary module of mod_jk version 2-2.0.42 b) Seems that the system works ok, however I got the following messages in the apache error_log file: [error] Error ajp_process_callback - write failed [error] ajp13.service() ajpGetReply recoverable error 3 Error ajp_process_callback - write failed ajp13.service() ajpGetReply recoverable error 3 ajp13.service() Error forwarding ajp13:localhost:8009 1 0 [error] mod_jk.handler() Error connecting to tomcat 3 [Thu Oct 28 08:02:26 2004] [error] mod_jk child init 1 0 [Thu Oct 28 08:02:31 2004] [error] jk2_init() Can't find child 8163 in scoreboard [Thu Oct 28 08:02:31 2004] [error] mod_jk child init 1 -2 and in the tomcat logs file: StandardWrapperValve[default]: Servlet.service() for servlet default threw exception java.net.SocketException: Broken pipe at java.net.SocketOutputStream.socketWrite0(Native Method) at java.net.SocketOutputStream.socketWrite(SocketOutputStream.java:92) at java.net.SocketOutputStream.write(SocketOutputStream.java:136) at org.apache.jk.common.ChannelSocket.send(ChannelSocket.java:407) at org.apache.jk.common.ChannelSocket.invoke(ChannelSocket.java:599) at org.apache.jk.server.JkCoyoteHandler.doWrite(JkCoyoteHandler.java:216) at org.apache.coyote.Response.doWrite(Response.java:524) at org.apache.coyote.tomcat4.OutputBuffer.realWriteBytes(OutputBuffer.java:384) at org.apache.tomcat.util.buf.ByteChunk.flushBuffer(ByteChunk.java:439) at org.apache.tomcat.util.buf.ByteChunk.append(ByteChunk.java:359) at org.apache.coyote.tomcat4.OutputBuffer.writeBytes(OutputBuffer.java:411) at org.apache.coyote.tomcat4.OutputBuffer.write(OutputBuffer.java:398) at org.apache.coyote.tomcat4.CoyoteOutputStream.write(CoyoteOutputStream.java:110) at org.apache.catalina.servlets.DefaultServlet.copyRange(DefaultServlet.java:1996) ... My question is, what is missing in my configuration ?. How these problems affect the performance of my system ?. Thanks a lot, -- Clara Ines Pe¤a de Carrillo Divisi¢n de Servicios de Informaci¢n Universidad Industrial de Santander Bucaramanga, Colombia - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Servlet gateway to legacy cgi application
I'm not personally aware of anything already built in to TC that specifically handles request, although having said that I haven't really ever had the need for it. However I think that the standard features of TC will probably make this quite straightforward to do. Have you written Java and/or Servlets before, and how much do you know already about servlets with respect to: Filters authentication request forwarding -Original Message- From: Shawn Church [mailto:[EMAIL PROTECTED] Sent: Thursday 28 October 2004 03:58 To: [EMAIL PROTECTED] Subject: Servlet gateway to legacy cgi application I am planning to migrate an old cgi (actually iSeries/AS/400 Net.DATA) application to Java, but in the meantime I would like to create a servlet-based gateway to the application, so that all requests are filtered through this gateway prior to being forwarded to the cgi application. Likewise, all responses should flow back through the servlet. I would also like to use Apache as the web server. I have no problem integrating Apache and Tomcat, but I'm not sure of the best method of sitting in front of the cgi app. I am needing to do this to integrate security with other Java apps (running on other servers), and it would be convenient if I could develop a gateway app to filter requests to the cgi application. I would appreciate some pointers on how to approach this. I would prefer to handle this in my own custom servlet, but if there is something already built into Tomcat I would like to know about it. Thanks, Shawn - 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: Problem Authenticating Users in LDAP
Hi, have a look in your log files. It should tell you something about your authentication process... Mark Sandeep N wrote: Hi, I have a problem trying to authenticate users, whose details are stored in the LDAP directory through Apache Tomcat. The details of the software I am using are as follows : LDAP: OpenLDAP V 2.2.17 Web-Server: Apache-Tomcat V 4.1.30 OS: Suse - Linux The LDAP directory structure is somewhat like this - dc=my-domain,dc=com cn= Manager cn=person1 cn=person2 and so on In the server.xml file (under APACHE-TOMCAT-DIR/conf/) I have included he following piece of code - Realm className=org.apache.catalina.realm.JNDIRealm debug=99 connectionName=cn=Manager,dc=my-domain,dc=com connectionPassword=secret connectionURL=ldap://localhost:389; roleName=cn roleSearch=(uniqueMember={0}) userPassword=userPassword userPattern=cn={0},cn=Manager,dn=my-domain,dn=com / The folder I have to authenticate is param_test and this resides under APACHE-TOMCAT-DIR/webapps. The web.xml file under the param_test folder contains the following piece of code - .. security-constraint web-resource-collection web-resource-nametest/web-resource-name url-pattern/*/url-pattern /web-resource-collection auth-constraint role-namecn/role-name /auth-constraint /security-constraint login-config auth-methodBASIC/auth-method realm-nametest/realm-name /login-config .. I have even copied the jndi.jar, ldap.jar files to APACHE-TOMCAT-DIR/server/lib directory When I try to access the link, http://localhost:8089/param_test, it prompts me for the username and password. When I type in these parameters as per the entries in the LDAP directory, the pop-up reappears and this goes on continously. If I cancel this pop-up, HTTP error 401 is returned. Any guesses where I have gone wrong? Thanks in advance. Regards, Sandeep - 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: Apache, Tomcat and mod_jk2 - question about layout
Think of an empty jk2.properties. -Original Message- From: Allen Williams [mailto:[EMAIL PROTECTED] Sent: October 27, 2004 7:20 PM To: Tomcat Users List Subject: RE: Apache, Tomcat and mod_jk2 - question about layout Thanks so much. I'll try it today or tomorrow. Even though you didn't change it, could you please post your jk2.properties? Don't need the httpd.conf- it's pretty straightforward. Thanks again, allen -Original Message- From: Phillip Qin [mailto:[EMAIL PROTECTED] Sent: Wednesday, October 27, 2004 10:23 AM To: 'Tomcat Users List' Subject: RE: Apache, Tomcat and mod_jk2 - question about layout This is my workers2.properties (not workers.properties). You don't need to touch jk2.properties or httpd.conf. # shared memory handling. [shm] file=C:\Program Files\Apache Group\Tomcat 4.1\work\jk2.shm size=1048576 # Defines a load balancer named lb. Use even if you only have one machine. #[lb:lb] # example socket channel, explicitly set port and host [channel.socket:localhost:8009] #tomcatId=localhost:8009 port=8009 host=127.0.0.1 tomcatId=jvm1 # define the worker [ajp13:localhost:8009] channel=channel.socket:localhost:8009 #group=lb # uri mapping #[uri:/examples/*] #group=lb [uri:investments.localhost/lciponline/*] #group=lb [uri:test.localhost/onlinestore/*] #group=lb #[uri:/investments/*] #group=lb # ROOT [uri:investments.localhost/*] [uri:test.localhost/*] [uri:investments.localhost/manager/*] #group=lb [uri:test.localhost/manager/*] [uri:investments.localhost/admin/*] [uri:test.localhost/admin/*] [status:] info=Status worker, displays runtime information [uri:investments.localhost/jkstatus/*] #worker=status:status group=status: [uri:test.localhost/jkstatus/*] #worker=status:status group=status: -Original Message- From: Allen Williams [mailto:[EMAIL PROTECTED] Sent: October 27, 2004 9:03 AM To: Tomcat Users List Subject: RE: Apache, Tomcat and mod_jk2 - question about layout Second request: Would you post what you did to integrate the two? I've followed all the clues on both apache and tomcat websites, which is exactly what it says in three books I've got, and I still get a File Not Found error from apache when I go to the dynamic content. Is there some reference and description of the parameters and values for the workers.properties, jk2.properties, and httpd.conf files? Although the Jakarta website has some of this, the examples showing the parameters being used are pretty sparse. What does JkMount do? I can't find this documented anywhere. I assure you, I've spent DAYS on the websites, in the books, and looking for documentation whereever I can find it. Thanks, Allen -Original Message- From: footh [mailto:[EMAIL PROTECTED] Sent: Tuesday, October 26, 2004 10:08 PM To: Tomcat Users List Subject: Re: Apache, Tomcat and mod_jk2 - question about layout Thanks for the tips. I believe the site will be using SSL at some point so that may be a reason to use Apache. But for the time being, I suppose I might as well use Tomcat standalone knowing that I can just flip a switch (well, a couple switches) to get Apache back in there. --- Peter Johnson [EMAIL PROTECTED] wrote: I am using Apache2, jk2 and Tomcat5 but I do so because I want to offload the SSL and compression onto a first tier leaving the second just to generate the content. I also use the first tier for uri rewriting using mod_rewrite. If you don't need uri rewriting I would consider using Tomcat standalone as the performance is likely to be comparable but the reduced admin by removing Apache and jk would be a big benefit. Why have more steps that can go wrong? More to debug when it does? To answer the questions from your first email. The images will be being returned from Apache, remember that an image is a separate request. I will qualify this by stating that any dynamically generated images will be returned by Tomcat. Regarding the directory setup ... it is whatever works best for you. I personally do the following: Apache Content - /sites/static/site name/... Tomcat Content - /sites/webapps/site name/ This means that all of the Tomcat content is outside the realm of Apache and thus security concerns are reduced. my 2c, PJ footh wrote: I've read the FAQ on the topic of whether to go through Apache or just use Tomcat stand-alone and frankly, it seemed inconclusive. Then I did a search and it seemed the general consensus was to use Tomcat stand-alone for development enviroments and Apache for production. Really, that's all I went by. I figured using Apache, Tomcat and mod_jk was the more robust solution and better suited for the long haul. More and more features will likely be added to
RE: problems with apache-tomcat connection ...
It took a while to figure out that broken pipe. It's not that fancy. It usually happens when use visits a page and stop/cancel during page loading. -Original Message- From: Clara Ines Pena de Carrillo [mailto:[EMAIL PROTECTED] Sent: October 28, 2004 9:12 AM To: [EMAIL PROTECTED] Subject: problems with apache-tomcat connection ... Hi everybody, sorry if this is a silly question because I am not an expert, but I was looking for the solution to my problem consulting to google and nobody has answered about the following problems with apache-tomcat connection: a) I have Solaris 8, apache 2.0.47, jdk 1.4.2, tomcat 4.1.24 and the binary module of mod_jk version 2-2.0.42 b) Seems that the system works ok, however I got the following messages in the apache error_log file: [error] Error ajp_process_callback - write failed [error] ajp13.service() ajpGetReply recoverable error 3 Error ajp_process_callback - write failed ajp13.service() ajpGetReply recoverable error 3 ajp13.service() Error forwarding ajp13:localhost:8009 1 0 [error] mod_jk.handler() Error connecting to tomcat 3 [Thu Oct 28 08:02:26 2004] [error] mod_jk child init 1 0 [Thu Oct 28 08:02:31 2004] [error] jk2_init() Can't find child 8163 in scoreboard [Thu Oct 28 08:02:31 2004] [error] mod_jk child init 1 -2 and in the tomcat logs file: StandardWrapperValve[default]: Servlet.service() for servlet default threw exception java.net.SocketException: Broken pipe at java.net.SocketOutputStream.socketWrite0(Native Method) at java.net.SocketOutputStream.socketWrite(SocketOutputStream.java:92) at java.net.SocketOutputStream.write(SocketOutputStream.java:136) at org.apache.jk.common.ChannelSocket.send(ChannelSocket.java:407) at org.apache.jk.common.ChannelSocket.invoke(ChannelSocket.java:599) at org.apache.jk.server.JkCoyoteHandler.doWrite(JkCoyoteHandler.java:216) at org.apache.coyote.Response.doWrite(Response.java:524) at org.apache.coyote.tomcat4.OutputBuffer.realWriteBytes(OutputBuffer.java:384) at org.apache.tomcat.util.buf.ByteChunk.flushBuffer(ByteChunk.java:439) at org.apache.tomcat.util.buf.ByteChunk.append(ByteChunk.java:359) at org.apache.coyote.tomcat4.OutputBuffer.writeBytes(OutputBuffer.java:411) at org.apache.coyote.tomcat4.OutputBuffer.write(OutputBuffer.java:398) at org.apache.coyote.tomcat4.CoyoteOutputStream.write(CoyoteOutputStream.java:1 10) at org.apache.catalina.servlets.DefaultServlet.copyRange(DefaultServlet.java:19 96) ... My question is, what is missing in my configuration ?. How these problems affect the performance of my system ?. Thanks a lot, -- Clara Ines Pe¤a de Carrillo Divisi¢n de Servicios de Informaci¢n Universidad Industrial de Santander Bucaramanga, Colombia - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] !DSPAM:4180f0b6312441493824945!
RE: Servlet gateway to legacy cgi application
Steve, I've developed servlet-based webapps for several years, I've written servlet filters and implemented many various types of authentication mechanisms, and I've also done request forwarding within an application. I was hoping to implement something similar to request forwarding, but according to Sun, Requests may be forwarded only to components within the same application context root, never between applications. I have to think however that there must be a way to accomplish this. This need has never arisen for me either, so I would not be surprised to find there may be something within the servlet API or within the Tomcat container itself which with I am not familiar. Any thoughts? Thanks, Shawn Quoting Steve Kirk [EMAIL PROTECTED]: I'm not personally aware of anything already built in to TC that specifically handles request, although having said that I haven't really ever had the need for it. However I think that the standard features of TC will probably make this quite straightforward to do. Have you written Java and/or Servlets before, and how much do you know already about servlets with respect to: Filters authentication request forwarding -Original Message- From: Shawn Church [mailto:[EMAIL PROTECTED] Sent: Thursday 28 October 2004 03:58 To: [EMAIL PROTECTED] Subject: Servlet gateway to legacy cgi application I am planning to migrate an old cgi (actually iSeries/AS/400 Net.DATA) application to Java, but in the meantime I would like to create a servlet-based gateway to the application, so that all requests are filtered through this gateway prior to being forwarded to the cgi application. Likewise, all responses should flow back through the servlet. I would also like to use Apache as the web server. I have no problem integrating Apache and Tomcat, but I'm not sure of the best method of sitting in front of the cgi app. I am needing to do this to integrate security with other Java apps (running on other servers), and it would be convenient if I could develop a gateway app to filter requests to the cgi application. I would appreciate some pointers on how to approach this. I would prefer to handle this in my own custom servlet, but if there is something already built into Tomcat I would like to know about it. Thanks, Shawn - 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: Virtual Hosts and useCanonical
Thanks Bill. I suppose I must have been dreaming about getServerName working. Our current production box is TC4.1.30, and for our next version of the app, I wanted to target TC5.0.29. Looks like it is a must have. Yoav will be happy. ;) -Original Message- From: news [mailto:[EMAIL PROTECTED] On Behalf Of Bill Barker Sent: Thursday, October 28, 2004 12:21 AM To: [EMAIL PROTECTED] Subject: Re: Virtual Hosts and useCanonical request.getServerName() is the value of the Host header. You want request.getLocalName(). - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: JNDI Resources in web.xml
Yes to both. --David Benson Margulies wrote: The question is not 'DTD or schema'. The question is, 'does the 2.4 schema relax the order, and does Tomcat comply?' -Original Message- From: David Smith [mailto:[EMAIL PROTECTED] Sent: Thursday, October 28, 2004 7:49 AM To: Tomcat Users List Subject: Re: JNDI Resources in web.xml Hi. As I understand it from lurking on this list a very long time, servlet spec 2.3 and earlier validated the web.xml file on a DTD. DTDs require the elements be in the right order and tomcat will throw an exception when the webapp is deployed with elements out of order. Servlet Spec 2.4 web.xml files are validated against a schema and don't suffer that limitation. --David Steve Kirk wrote: that section opens by talking about the web-app element and says All sub elements under this element can be in an arbitrary order. so it seems that even if orderingused to be an issue, it's not any longer. Also, the docs caution that I should respect element ordering in the web.xml file, but they don't tell me what the ordering should be. Where is this ordering documented? SRV.13.4 of the Servlet Spec lists the order. http://www.jcp.org/aboutJava/communityprocess/final/jsr154/ - 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: Servlet gateway to legacy cgi application
Maybe it's too obvious to say ... but does the cgi servlet (that comes with Tomcat) fit your needs ? http://jakarta.apache.org/tomcat/tomcat-5.0-doc/cgi-howto.html -Original Message- From: Shawn Church [mailto:[EMAIL PROTECTED] Sent: Wednesday, October 27, 2004 9:58 PM To: [EMAIL PROTECTED] Subject: Servlet gateway to legacy cgi application I am planning to migrate an old cgi (actually iSeries/AS/400 Net.DATA) application to Java, but in the meantime I would like to create a servlet-based gateway to the application, so that all requests are filtered through this gateway prior to being forwarded to the cgi application. Likewise, all responses should flow back through the servlet. I would also like to use Apache as the web server. I have no problem integrating Apache and Tomcat, but I'm not sure of the best method of sitting in front of the cgi app. I am needing to do this to integrate security with other Java apps (running on other servers), and it would be convenient if I could develop a gateway app to filter requests to the cgi application. I would appreciate some pointers on how to approach this. I would prefer to handle this in my own custom servlet, but if there is something already built into Tomcat I would like to know about it. Thanks, Shawn - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Servlet gateway to legacy cgi application
The only issue I can see that he will have is the path in web.xml with CGIServlet. I have to move all cgi scripts to a directory under my ${catalina_home}/webapps/${host} -Original Message- From: Mike Curwen [mailto:[EMAIL PROTECTED] Sent: October 28, 2004 10:33 AM To: 'Tomcat Users List' Subject: RE: Servlet gateway to legacy cgi application Maybe it's too obvious to say ... but does the cgi servlet (that comes with Tomcat) fit your needs ? http://jakarta.apache.org/tomcat/tomcat-5.0-doc/cgi-howto.html -Original Message- From: Shawn Church [mailto:[EMAIL PROTECTED] Sent: Wednesday, October 27, 2004 9:58 PM To: [EMAIL PROTECTED] Subject: Servlet gateway to legacy cgi application I am planning to migrate an old cgi (actually iSeries/AS/400 Net.DATA) application to Java, but in the meantime I would like to create a servlet-based gateway to the application, so that all requests are filtered through this gateway prior to being forwarded to the cgi application. Likewise, all responses should flow back through the servlet. I would also like to use Apache as the web server. I have no problem integrating Apache and Tomcat, but I'm not sure of the best method of sitting in front of the cgi app. I am needing to do this to integrate security with other Java apps (running on other servers), and it would be convenient if I could develop a gateway app to filter requests to the cgi application. I would appreciate some pointers on how to approach this. I would prefer to handle this in my own custom servlet, but if there is something already built into Tomcat I would like to know about it. Thanks, Shawn - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] !DSPAM:4181030a319441307757648!
Tomcat Manager roles
I have setup multiple Manager's and can isolate the apps. The problem is the tomcat-users.xml file. Both version of the manager use the same tomcat-users.xml. The one that was last defined for permission. So when I give the developer's access to one manager they can just change the port and access the other apps as well. Is there anyway other than running totally separate tomcat version to give the developer's access to only there app. Thanks Robert Hi, I would like to be able to limit the access in Tomcat manager. I would like to be able to setup a user account that is able to start, stop and remove the examples application, but only the example application. The problem is that when I give a user the role manager they have access to shutdown and start all the other application. How would I set it up so that they can only use the commands for the app they are responsible for? Here's one idea. The Manager webapp is designed to manage all apps in one Host, for better or worse. So if you want to have it manage only one app, put that app AND the Manager webapp (or a copy of it) in that Host. That means defining multiple Hosts in server.xml, each with its own appBase, and moving your webapps around as needed. It's not a big deal, doesn't require any coding. Yoav - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Re[2]: JNDI DataSource GlobalResources problem
Benson wrote: Yoav, in one posting, explained that the servlet spec is written from a point of view that only requires support for applications in unexploded WAR files. Does the spec explicitly state that point of view? I can't find that anywhere in the spec doc. Therefore this makes me ask (out of polite curiosity) what is that statement based on? Yoav has already patiently explained the rationale for why mandating open filesystem support would exclude certain platforms - that aspect is now clear, even if not written up explicitly in the spec. Thanks for that insight, Yoav. He also said that he believes that the spec implicitly only requires support for warfiles because it only discusses packed war files. However, I can't see that from my readings of it. I've been through it a few times (at least once wearing warfile only goggles), but find sections that mention both packed and open webapp deployments, which seems to imply that either/both are OK. Further, SRV.9.6 says that web apps can be packaged into a war. It doesn't say must, so to me this implies that warfiles are optional from a webapp developer point of view (but mandatory from the container author point of view). Further still, I can't see anywhere in the spec that says that webapps must be deployed in warfiles, or that support for open filesystem deployment is optional. I happily stand to be corrected on any of these points if someone can point out the relevant section :) I don't mean to be a PITA ;) . As it happens, I adopted warfiles yesterday as my deployment method during development, after Yoav's comments on this thread (and I learned to use Ant and upgraded to 5.0.28 in the process). So I hope you can see that I'm not just being stubborn - I just want to learn :) - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Servlet gateway to legacy cgi application
I initially looked at CGIServlet, but I run the Apache http server, rather than using Tomcat's implementation. I also need to implement my own functionality (primarily for user authentication). But yes, this is close to what I'm after. I'm sure I can roll my own, but it would be nice to find an existing solution. I just googled cgiservlet, and this may yield something useful. I will let you know. Thanks, Shawn Quoting Mike Curwen [EMAIL PROTECTED]: Maybe it's too obvious to say ... but does the cgi servlet (that comes with Tomcat) fit your needs ? http://jakarta.apache.org/tomcat/tomcat-5.0-doc/cgi-howto.html -Original Message- From: Shawn Church [mailto:[EMAIL PROTECTED] Sent: Wednesday, October 27, 2004 9:58 PM To: [EMAIL PROTECTED] Subject: Servlet gateway to legacy cgi application I am planning to migrate an old cgi (actually iSeries/AS/400 Net.DATA) application to Java, but in the meantime I would like to create a servlet-based gateway to the application, so that all requests are filtered through this gateway prior to being forwarded to the cgi application. Likewise, all responses should flow back through the servlet. I would also like to use Apache as the web server. I have no problem integrating Apache and Tomcat, but I'm not sure of the best method of sitting in front of the cgi app. I am needing to do this to integrate security with other Java apps (running on other servers), and it would be convenient if I could develop a gateway app to filter requests to the cgi application. I would appreciate some pointers on how to approach this. I would prefer to handle this in my own custom servlet, but if there is something already built into Tomcat I would like to know about it. Thanks, Shawn - 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]
Tomcat logging
I am currently having a problem getting my JSPs to log with the JDK 1.4 logging. When I configure my logging.properties file to set the global .level to FINEST I can see everything including all the org.apache.jsp.[my packages] logs I'm looking for, but if I set .level to INFO and explicitly set org.apache.jsp.level = FINEST nothing shows up. Can anyone explain this? Derek Greer - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: JNDI DataSource GlobalResources problem
I have been in learning mode about Resource/Context config for the last few weeks, mainly from the point of view of DBCP config. I did find all the alternatives confusing at first, but having read more and more docs, and getting some help from the good people on this list, I'm starting to get it now. I've had DBCP working for several months, the confusing issue is how best to config it. IMHO, TC provides very good support for configuring Resources/Contexts, and doesn't need to change (although there may be one or two documentation tweaks that would help beginners, which I intend to submit soon). Whether you are a container administrator wanting to config global resources, or per-webapp resources, or a webapp author wanting to config your own resources, TC provides you with at least one way to do it. And these are all bonus features, in the sense that they are not mandated in the servlet spec. Again IMHO, if there is a problem in this area, it's that these features are TC-specific, so if you use them in developing your webapp, you are making your webapp less portable to other containers (as Yoav has pointed out). An improvement in portability can only really come if the servlet spec changes to mandate how this stuff is configured. So the spec is the area that needs to be addressed next, rather than TC. Until then, there are ways of doing pretty much what you want with TC already in this area. It might not be _exactly_ as you would ideally like, but hey, it works if you really need it, and you can be bothered to use what's already there. And this list is always there to help you if you are confused as to which option to choose. all just IMHO :) -Original Message- From: Benson Margulies [mailto:[EMAIL PROTECTED] Sent: Thursday 28 October 2004 02:28 To: Tomcat Users List; Allen Holub Subject: RE: Re[2]: JNDI DataSource GlobalResources problem As I read the discussion, I don't think that anyone claimed that only WAR's are interesting or important. Yoav, in one posting, explained that the servlet spec is written from a point of view that only requires support for applications in unexploded WAR files. That is not the same thing as stating that only WARs are interesting. It is just a way of illuminating some requirements for behaviors of the container. In another posting, Yoav expressed a generic distaste for Global resources -- all other things being equal. Of late, there's been a rash of people wanting to use global resources, either for database pooling or for JNI reasons. The commercial containers have various kinds of adminstrative UI arrangements for this purpose. No one that I know of supports a self-contained package that bundles a web app with administrative/resource/global configuration, but I haven't made a comprehensive survey. Semi-seriously, I wonder about a GRaR -- a Global Resource aRchive, as a way to package up a set of global classlibs and the config to deploy them into JNDI. I've experimented with writing a simple Java command-line application to set up an application with global resources. It assumes that the app will deploy outside the webapps dir. It edits server.xml and creates the context file to point to the tree. It wasn't very complex. I have some ideas as to why them-that-vote are not enthused about META-INF/server.xml as a generic feature of a web application tree. If there is also context file in Catalina/HOST/xxx.xml, which one wins? How loudly will someone yell when a WAR file has unexpected implications because it has a server.xml? As things are, META-INF/server.xml is a feature of a particular management path, not a feature of webapps. Mostly, I end up feeling that this is more of a documentation problem. Developer after developer reads the servlet spec, which is quite murky in this area since it defers important stuff to the container. Then, they either never read the relevant tomcat howtos, or fail to understand them. As a recent contributor to them I get some of the blame for the later turn of events. In big letters, someplace, people need to see 'if your webapp needs resources from the container, and especially if you need container-wide shared resources, you are not in Kansas any longer'. - 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: Tomcat Manager roles
Hi, You can define different Realms for the Manager, as you need. You can do so per Host or even per Manager webapp inside its Context. It's actually pretty easy. They can be Memory Realms driven from any file you want, or any other kind of Realm. Yoav Shapira http://www.yoavshapira.com -Original Message- From: Robert Humble [mailto:[EMAIL PROTECTED] Sent: Thursday, October 28, 2004 10:38 AM To: Tomcat Users List Subject: Tomcat Manager roles I have setup multiple Manager's and can isolate the apps. The problem is the tomcat-users.xml file. Both version of the manager use the same tomcat-users.xml. The one that was last defined for permission. So when I give the developer's access to one manager they can just change the port and access the other apps as well. Is there anyway other than running totally separate tomcat version to give the developer's access to only there app. Thanks Robert Hi, I would like to be able to limit the access in Tomcat manager. I would like to be able to setup a user account that is able to start, stop and remove the examples application, but only the example application. The problem is that when I give a user the role manager they have access to shutdown and start all the other application. How would I set it up so that they can only use the commands for the app they are responsible for? Here's one idea. The Manager webapp is designed to manage all apps in one Host, for better or worse. So if you want to have it manage only one app, put that app AND the Manager webapp (or a copy of it) in that Host. That means defining multiple Hosts in server.xml, each with its own appBase, and moving your webapps around as needed. It's not a big deal, doesn't require any coding. Yoav - 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[2]: JNDI DataSource GlobalResources problem
The standard make a series of provisions for the case in which there is no 'pathname' corresponding to some resource in a web application. These provisions were intended to support a model where a WAR file is never exploded into a native file system. Conceptually, you can model this as supporting unexploded WAR, but that's just a conceptual model. The conspicuous practical case is Oracle, which unpacks the WAR into the database. However, I respecfully submit that all of this is beside your original point. I think that the important point is that the specifications only deal with self-contained web applications, whether or not anyone ever assembles one into a WAR file. Tomcat is not trying to be a full J2EE container (c.f. jboss). The designers are willing to add functionality to permit the use of the J2EE resource model, but they are very protective of Tomcat's status as a relatively tight, lightweight device. The META-INF/server.xml thing isn't, currently, a WAR feature. It's narrower than that. It's restricted to a particular tool for deploying from a WAR. This very narrow view is much more a reflection of the desire to avoid feature bloat than any particular tilt to or from WAR files. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: JNDI DataSource GlobalResources problem
Hi, Besides completely agreeing with Steve (so Benson, your time could probably be better spent elsewhere, such as by putting on the tech writer hat you mentioned earlier), I wanted to mention one other alternative. You *always* have the option of *not* using container-managed resources, and managing them yourself. I do this 99% of the time, as the portability and management advantages overwhelmingly cover cons. For the DBCP case, you take the DBCP jar (and its two dependent jars), put them in WEB-INF/lib, and write a couple of lines of code to configure your pool(s). Literally, that's all it takes, and now you've got your one package with no need for a server-specific configuration file etc. Yoav Shapira http://www.yoavshapira.com -Original Message- From: Steve Kirk [mailto:[EMAIL PROTECTED] Sent: Thursday, October 28, 2004 11:11 AM To: 'Tomcat Users List' Subject: RE: JNDI DataSource GlobalResources problem I have been in learning mode about Resource/Context config for the last few weeks, mainly from the point of view of DBCP config. I did find all the alternatives confusing at first, but having read more and more docs, and getting some help from the good people on this list, I'm starting to get it now. I've had DBCP working for several months, the confusing issue is how best to config it. IMHO, TC provides very good support for configuring Resources/Contexts, and doesn't need to change (although there may be one or two documentation tweaks that would help beginners, which I intend to submit soon). Whether you are a container administrator wanting to config global resources, or per-webapp resources, or a webapp author wanting to config your own resources, TC provides you with at least one way to do it. And these are all bonus features, in the sense that they are not mandated in the servlet spec. Again IMHO, if there is a problem in this area, it's that these features are TC-specific, so if you use them in developing your webapp, you are making your webapp less portable to other containers (as Yoav has pointed out). An improvement in portability can only really come if the servlet spec changes to mandate how this stuff is configured. So the spec is the area that needs to be addressed next, rather than TC. Until then, there are ways of doing pretty much what you want with TC already in this area. It might not be _exactly_ as you would ideally like, but hey, it works if you really need it, and you can be bothered to use what's already there. And this list is always there to help you if you are confused as to which option to choose. all just IMHO :) -Original Message- From: Benson Margulies [mailto:[EMAIL PROTECTED] Sent: Thursday 28 October 2004 02:28 To: Tomcat Users List; Allen Holub Subject: RE: Re[2]: JNDI DataSource GlobalResources problem As I read the discussion, I don't think that anyone claimed that only WAR's are interesting or important. Yoav, in one posting, explained that the servlet spec is written from a point of view that only requires support for applications in unexploded WAR files. That is not the same thing as stating that only WARs are interesting. It is just a way of illuminating some requirements for behaviors of the container. In another posting, Yoav expressed a generic distaste for Global resources -- all other things being equal. Of late, there's been a rash of people wanting to use global resources, either for database pooling or for JNI reasons. The commercial containers have various kinds of adminstrative UI arrangements for this purpose. No one that I know of supports a self-contained package that bundles a web app with administrative/resource/global configuration, but I haven't made a comprehensive survey. Semi-seriously, I wonder about a GRaR -- a Global Resource aRchive, as a way to package up a set of global classlibs and the config to deploy them into JNDI. I've experimented with writing a simple Java command-line application to set up an application with global resources. It assumes that the app will deploy outside the webapps dir. It edits server.xml and creates the context file to point to the tree. It wasn't very complex. I have some ideas as to why them-that-vote are not enthused about META-INF/server.xml as a generic feature of a web application tree. If there is also context file in Catalina/HOST/xxx.xml, which one wins? How loudly will someone yell when a WAR file has unexpected implications because it has a server.xml? As things are, META-INF/server.xml is a feature of a particular management path, not a feature of webapps. Mostly, I end up feeling that this is more of a documentation problem. Developer after developer reads the servlet spec, which is quite murky in this area since it defers important stuff to the container. Then, they either never read the relevant tomcat howtos, or fail to understand them. As a recent contributor to them I get some of the blame for
RE: Lib directory
Hi, You can't without significant effort. 20 jars is no big deal, and the Spec does not provide for subdirectories under a classloader repository. If you really want to do this, you need to write a custom classloader (implementing Tomcat's Loader interface and likely extending WebappClassloader), and configure Tomcat to use it for your webapp. Yoav Shapira http://www.yoavshapira.com -Original Message- From: Edouard Dalla-Costa [mailto:[EMAIL PROTECTED] Sent: Thursday, October 28, 2004 4:08 AM To: [EMAIL PROTECTED] Subject: Lib directory Hello, I am developping a web application using several servlets. And I was wondering how could I add sub-directory in the lib directory of my webapp. I need something like 20 jar files and without organization, it is a big mess. I just don't know how to make tomcat know that I am using sub-directory in the lib directory. Thanx Doud - 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[2]: JNDI DataSource GlobalResources problem
Hi, Yeah, well put, saving me time to type up this response yet again ;) To the OP (I think) who said it'd be nice if context.xml was handled uniformly: sure, that would be nice. Please submit patches for any area you find inconsistent. Yoav Shapira http://www.yoavshapira.com -Original Message- From: Benson Margulies [mailto:[EMAIL PROTECTED] Sent: Thursday, October 28, 2004 11:21 AM To: Tomcat Users List Subject: RE: Re[2]: JNDI DataSource GlobalResources problem The standard make a series of provisions for the case in which there is no 'pathname' corresponding to some resource in a web application. These provisions were intended to support a model where a WAR file is never exploded into a native file system. Conceptually, you can model this as supporting unexploded WAR, but that's just a conceptual model. The conspicuous practical case is Oracle, which unpacks the WAR into the database. However, I respecfully submit that all of this is beside your original point. I think that the important point is that the specifications only deal with self-contained web applications, whether or not anyone ever assembles one into a WAR file. Tomcat is not trying to be a full J2EE container (c.f. jboss). The designers are willing to add functionality to permit the use of the J2EE resource model, but they are very protective of Tomcat's status as a relatively tight, lightweight device. The META-INF/server.xml thing isn't, currently, a WAR feature. It's narrower than that. It's restricted to a particular tool for deploying from a WAR. This very narrow view is much more a reflection of the desire to avoid feature bloat than any particular tilt to or from WAR files. - 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: Context mapping question
Hi, Context path=/ docBase=app1 debug=9 Changing this one path to path= instead of /. Set autoDeploy/liveDeploy/deployOnStartup to false for both of your Hosts. Because they share an appBase, the apps are being deployed once *per* Host. The rest of your approach is correct (and very good). 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: OutOfMemoryError: unable to create new native thread
Hi, - Actually ran out of memory - Hit max # of threads allowed to run (OS dependant?) This is the most likely cause in your case, and it's OS-dependent as you surmised. On *nix this is adjusted via the ulimit (-n) command. But on Windows 2000 Server, I'm not sure off the top of my head. Google? 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]
File upload
Configuration: Tomcat 5.0.24 IIS 5.0 JK2 connector Isapi_redirector2.dll Struts 1.1 Commons file upload 1.0 I seem to have an issue that when the file is a certain size it is written to a temp file on the file system before it is parsed by the multipart parser (at least that's what the exception message leads me to believe). However, since the working directory is my web app (/WEB-INF/ilt), the parser can't seem to find the file (not a fully qualified file name). This is a guess, but if correct I don't know how to fix the problem. Any help is appreciated. Belows is the stack trace and data from the request dumper valve: 2004-10-28 10:59:32 RequestDumperValve[/ilt]: === 2004-10-28 10:59:43 RequestDumperValve[/ilt]: REQUEST URI =/ilt/ilt/iltPerformUpload.do 2004-10-28 10:59:43 RequestDumperValve[/ilt]: authType=null 2004-10-28 10:59:43 RequestDumperValve[/ilt]: characterEncoding=null 2004-10-28 10:59:43 RequestDumperValve[/ilt]: contentLength=340147 2004-10-28 10:59:43 RequestDumperValve[/ilt]: contentType=multipart/form-data; boundary=---41184676334 2004-10-28 10:59:43 RequestDumperValve[/ilt]:contextPath=/ilt 2004-10-28 10:59:43 RequestDumperValve[/ilt]: cookie=com.skillsoft.mgs.sso.RedirectorServlet.ReturnToSkillPort=http:// dkoesxp/djk/home/index.cfm?selectdTab=0 2004-10-28 10:59:43 RequestDumperValve[/ilt]: cookie=CFMX_JSESSIONID=c8301990451098975559821 2004-10-28 10:59:43 RequestDumperValve[/ilt]: cookie=CFID=19459 2004-10-28 10:59:43 RequestDumperValve[/ilt]: cookie=CFTOKEN=98634115 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=accept=text/xml,application/xml,application/xhtml+xml,text/html;q =0.9,text/plain;q=0.8,image/png,*/*;q=0.5 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=accept-language=en-us,en;q=0.5 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=connection=keep-alive 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=host=dkoesxp 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=referer=http://dkoesxp/ilt/ilt/iltUpload.do;jsessionid=3048D443AD 4341273FB5FED42958E7C4 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=user-agent=Mozilla/5.0 (Windows; U; Windows NT 5.1; rv:1.7.3) Gecko/20041001 Firefox/0.10.1 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=cookie=com.skillsoft.mgs.sso.RedirectorServlet.ReturnToSkillPort= http://dkoesxp/djk/home/index.cfm?selectdTab=0; CFMX_JSESSIONID=c8301990451098975559821; CFID=19459; CFTOKEN=98634115 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=content-length=340147 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=content-type=multipart/form-data; boundary=---41184676334 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=accept-encoding=gzip,deflate 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=accept-charset=ISO-8859-1,utf-8;q=0.7,*;q=0.7 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=keep-alive=300 2004-10-28 10:59:43 RequestDumperValve[/ilt]: locale=en_US 2004-10-28 10:59:43 RequestDumperValve[/ilt]: method=POST 2004-10-28 10:59:43 RequestDumperValve[/ilt]: pathInfo=null 2004-10-28 10:59:43 RequestDumperValve[/ilt]: protocol=HTTP/1.1 2004-10-28 10:59:43 RequestDumperValve[/ilt]:queryString=null 2004-10-28 10:59:43 RequestDumperValve[/ilt]: remoteAddr=10.20.3.42 2004-10-28 10:59:43 RequestDumperValve[/ilt]: remoteHost=10.20.3.42 2004-10-28 10:59:43 RequestDumperValve[/ilt]: remoteUser=null 2004-10-28 10:59:43 RequestDumperValve[/ilt]: requestedSessionId=3048D443AD4341273FB5FED42958E7C4 2004-10-28 10:59:43 RequestDumperValve[/ilt]: scheme=http 2004-10-28 10:59:43 RequestDumperValve[/ilt]: serverName=dkoesxp 2004-10-28 10:59:43 RequestDumperValve[/ilt]: serverPort=80 2004-10-28 10:59:43 RequestDumperValve[/ilt]: servletPath=/ilt/iltPerformUpload.do 2004-10-28 10:59:43 RequestDumperValve[/ilt]: isSecure=false 2004-10-28 10:59:43 RequestDumperValve[/ilt]: --- 2004-10-28 10:59:43 StandardWrapperValve[action]: Servlet.service() for servlet action threw exception org.apache.commons.fileupload.FileUploadException: Processing of multipart/form-data request failed. \WEB-INF\ilt\temp\upload_0001.tmp (The system cannot find the path specified) at org.apache.commons.fileupload.FileUploadBase.parseRequest(FileUploadBase .java:429) at org.apache.struts.upload.CommonsMultipartRequestHandler.handleRequest(Co mmonsMultipartRequestHandler.java:233) at org.apache.struts.util.RequestUtils.populate(RequestUtils.java:1209) at org.apache.struts.action.RequestProcessor.processPopulate(RequestProcess or.java:821) at org.apache.struts.action.RequestProcessor.process(RequestProcessor.java: 254) at org.apache.struts.action.ActionServlet.process(ActionServlet.java:1482) at
RE: File upload
Hi, First question, as always: does it work on Tomcat standalone, i.e. removing IIS, JK2, and the redirector out of the mix (just for now, for testing)? Yoav Shapira http://www.yoavshapira.com -Original Message- From: Derrick Koes [mailto:[EMAIL PROTECTED] Sent: Thursday, October 28, 2004 11:52 AM To: Tomcat Users List Subject: File upload Configuration: Tomcat 5.0.24 IIS 5.0 JK2 connector Isapi_redirector2.dll Struts 1.1 Commons file upload 1.0 I seem to have an issue that when the file is a certain size it is written to a temp file on the file system before it is parsed by the multipart parser (at least that's what the exception message leads me to believe). However, since the working directory is my web app (/WEB-INF/ilt), the parser can't seem to find the file (not a fully qualified file name). This is a guess, but if correct I don't know how to fix the problem. Any help is appreciated. Belows is the stack trace and data from the request dumper valve: 2004-10-28 10:59:32 RequestDumperValve[/ilt]: === 2004-10-28 10:59:43 RequestDumperValve[/ilt]: REQUEST URI =/ilt/ilt/iltPerformUpload.do 2004-10-28 10:59:43 RequestDumperValve[/ilt]: authType=null 2004-10-28 10:59:43 RequestDumperValve[/ilt]: characterEncoding=null 2004-10-28 10:59:43 RequestDumperValve[/ilt]: contentLength=340147 2004-10-28 10:59:43 RequestDumperValve[/ilt]: contentType=multipart/form-data; boundary=---41184676334 2004-10-28 10:59:43 RequestDumperValve[/ilt]:contextPath=/ilt 2004-10-28 10:59:43 RequestDumperValve[/ilt]: cookie=com.skillsoft.mgs.sso.RedirectorServlet.ReturnToSkillPort=http:/ / dkoesxp/djk/home/index.cfm?selectdTab=0 2004-10-28 10:59:43 RequestDumperValve[/ilt]: cookie=CFMX_JSESSIONID=c8301990451098975559821 2004-10-28 10:59:43 RequestDumperValve[/ilt]: cookie=CFID=19459 2004-10-28 10:59:43 RequestDumperValve[/ilt]: cookie=CFTOKEN=98634115 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=accept=text/xml,application/xml,application/xhtml+xml,text/html; q =0.9,text/plain;q=0.8,image/png,*/*;q=0.5 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=accept-language=en-us,en;q=0.5 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=connection=keep-alive 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=host=dkoesxp 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=referer=http://dkoesxp/ilt/ilt/iltUpload.do;jsessionid=3048D443A D 4341273FB5FED42958E7C4 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=user-agent=Mozilla/5.0 (Windows; U; Windows NT 5.1; rv:1.7.3) Gecko/20041001 Firefox/0.10.1 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=cookie=com.skillsoft.mgs.sso.RedirectorServlet.ReturnToSkillPort = http://dkoesxp/djk/home/index.cfm?selectdTab=0; CFMX_JSESSIONID=c8301990451098975559821; CFID=19459; CFTOKEN=98634115 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=content-length=340147 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=content-type=multipart/form-data; boundary=---41184676334 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=accept-encoding=gzip,deflate 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=accept-charset=ISO-8859-1,utf-8;q=0.7,*;q=0.7 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=keep-alive=300 2004-10-28 10:59:43 RequestDumperValve[/ilt]: locale=en_US 2004-10-28 10:59:43 RequestDumperValve[/ilt]: method=POST 2004-10-28 10:59:43 RequestDumperValve[/ilt]: pathInfo=null 2004-10-28 10:59:43 RequestDumperValve[/ilt]: protocol=HTTP/1.1 2004-10-28 10:59:43 RequestDumperValve[/ilt]:queryString=null 2004-10-28 10:59:43 RequestDumperValve[/ilt]: remoteAddr=10.20.3.42 2004-10-28 10:59:43 RequestDumperValve[/ilt]: remoteHost=10.20.3.42 2004-10-28 10:59:43 RequestDumperValve[/ilt]: remoteUser=null 2004-10-28 10:59:43 RequestDumperValve[/ilt]: requestedSessionId=3048D443AD4341273FB5FED42958E7C4 2004-10-28 10:59:43 RequestDumperValve[/ilt]: scheme=http 2004-10-28 10:59:43 RequestDumperValve[/ilt]: serverName=dkoesxp 2004-10-28 10:59:43 RequestDumperValve[/ilt]: serverPort=80 2004-10-28 10:59:43 RequestDumperValve[/ilt]: servletPath=/ilt/iltPerformUpload.do 2004-10-28 10:59:43 RequestDumperValve[/ilt]: isSecure=false 2004-10-28 10:59:43 RequestDumperValve[/ilt]: --- 2004-10-28 10:59:43 StandardWrapperValve[action]: Servlet.service() for servlet action threw exception org.apache.commons.fileupload.FileUploadException: Processing of multipart/form-data request failed. \WEB-INF\ilt\temp\upload_0001.tmp (The system cannot find the path specified) at org.apache.commons.fileupload.FileUploadBase.parseRequest(FileUploadBas e .java:429) at org.apache.struts.upload.CommonsMultipartRequestHandler.handleRequest(C o mmonsMultipartRequestHandler.java:233) at
RE: File upload
you have the _exact_ same setup as we do here (except we are on 5.0.25). we upload files using a multipart form and file control. then in the struts action List items = null; try { DiskFileUpload upload = new DiskFileUpload(); items = upload.parseRequest(request); } catch (FileUploadException fuE) { logger.error(user.getUsername() + : error.checkin.parse; + fuE.getMessage()); errors.add(ActionMessages.GLOBAL_MESSAGE, new ActionMessage(error.checkin.parse)); break DO_CHECKIN; } FileItem primaryFile = null; while (iterator.hasNext()) { FileItem item = (FileItem) iterator.next(); ... // capture the actual upload file if (! item.isFormField()) { primaryFile = item; } } this was out of the box tomcat/common fileupload/struts, so you must have configured something somewhere? -Original Message- From: Shapira, Yoav [mailto:[EMAIL PROTECTED] Sent: 28 October 2004 16:56 To: Tomcat Users List Subject: RE: File upload Hi, First question, as always: does it work on Tomcat standalone, i.e. removing IIS, JK2, and the redirector out of the mix (just for now, for testing)? Yoav Shapira http://www.yoavshapira.com -Original Message- From: Derrick Koes [mailto:[EMAIL PROTECTED] Sent: Thursday, October 28, 2004 11:52 AM To: Tomcat Users List Subject: File upload Configuration: Tomcat 5.0.24 IIS 5.0 JK2 connector Isapi_redirector2.dll Struts 1.1 Commons file upload 1.0 I seem to have an issue that when the file is a certain size it is written to a temp file on the file system before it is parsed by the multipart parser (at least that's what the exception message leads me to believe). However, since the working directory is my web app (/WEB-INF/ilt), the parser can't seem to find the file (not a fully qualified file name). This is a guess, but if correct I don't know how to fix the problem. Any help is appreciated. Belows is the stack trace and data from the request dumper valve: 2004-10-28 10:59:32 RequestDumperValve[/ilt]: === 2004-10-28 10:59:43 RequestDumperValve[/ilt]: REQUEST URI =/ilt/ilt/iltPerformUpload.do 2004-10-28 10:59:43 RequestDumperValve[/ilt]: authType=null 2004-10-28 10:59:43 RequestDumperValve[/ilt]: characterEncoding=null 2004-10-28 10:59:43 RequestDumperValve[/ilt]: contentLength=340147 2004-10-28 10:59:43 RequestDumperValve[/ilt]: contentType=multipart/form-data; boundary=---41184676334 2004-10-28 10:59:43 RequestDumperValve[/ilt]:contextPath=/ilt 2004-10-28 10:59:43 RequestDumperValve[/ilt]: cookie=com.skillsoft.mgs.sso.RedirectorServlet.ReturnToSkillP ort=http:/ / dkoesxp/djk/home/index.cfm?selectdTab=0 2004-10-28 10:59:43 RequestDumperValve[/ilt]: cookie=CFMX_JSESSIONID=c8301990451098975559821 2004-10-28 10:59:43 RequestDumperValve[/ilt]: cookie=CFID=19459 2004-10-28 10:59:43 RequestDumperValve[/ilt]: cookie=CFTOKEN=98634115 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=accept=text/xml,application/xml,application/xhtml+xml, text/html; q =0.9,text/plain;q=0.8,image/png,*/*;q=0.5 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=accept-language=en-us,en;q=0.5 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=connection=keep-alive 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=host=dkoesxp 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=referer=http://dkoesxp/ilt/ilt/iltUpload.do;jsessionid =3048D443A D 4341273FB5FED42958E7C4 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=user-agent=Mozilla/5.0 (Windows; U; Windows NT 5.1; rv:1.7.3) Gecko/20041001 Firefox/0.10.1 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=cookie=com.skillsoft.mgs.sso.RedirectorServlet.ReturnT oSkillPort = http://dkoesxp/djk/home/index.cfm?selectdTab=0; CFMX_JSESSIONID=c8301990451098975559821; CFID=19459; CFTOKEN=98634115 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=content-length=340147 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=content-type=multipart/form-data; boundary=---41184676334 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=accept-encoding=gzip,deflate 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=accept-charset=ISO-8859-1,utf-8;q=0.7,*;q=0.7 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=keep-alive=300 2004-10-28 10:59:43 RequestDumperValve[/ilt]: locale=en_US 2004-10-28 10:59:43 RequestDumperValve[/ilt]: method=POST 2004-10-28 10:59:43 RequestDumperValve[/ilt]: pathInfo=null 2004-10-28 10:59:43 RequestDumperValve[/ilt]: protocol=HTTP/1.1 2004-10-28 10:59:43 RequestDumperValve[/ilt]:queryString=null 2004-10-28 10:59:43 RequestDumperValve[/ilt]: remoteAddr=10.20.3.42 2004-10-28 10:59:43
Re: File upload
Are you following the struts-upload.war example that comes with the Struts 1.1? In that example, the uploaded file size is checked. If a file is stored somewhere under the AppName/WEB-INF directory, you have to use the stream to read the file. --- Derrick Koes [EMAIL PROTECTED] wrote: Configuration: Tomcat 5.0.24 IIS 5.0 JK2 connector Isapi_redirector2.dll Struts 1.1 Commons file upload 1.0 I seem to have an issue that when the file is a certain size it is written to a temp file on the file system before it is parsed by the multipart parser (at least that's what the exception message leads me to believe). However, since the working directory is my web app (/WEB-INF/ilt), the parser can't seem to find the file (not a fully qualified file name). This is a guess, but if correct I don't know how to fix the problem. Any help is appreciated. Belows is the stack trace and data from the request dumper valve: 2004-10-28 10:59:32 RequestDumperValve[/ilt]: === 2004-10-28 10:59:43 RequestDumperValve[/ilt]: REQUEST URI =/ilt/ilt/iltPerformUpload.do 2004-10-28 10:59:43 RequestDumperValve[/ilt]: authType=null 2004-10-28 10:59:43 RequestDumperValve[/ilt]: characterEncoding=null 2004-10-28 10:59:43 RequestDumperValve[/ilt]: contentLength=340147 2004-10-28 10:59:43 RequestDumperValve[/ilt]: contentType=multipart/form-data; boundary=---41184676334 2004-10-28 10:59:43 RequestDumperValve[/ilt]: contextPath=/ilt 2004-10-28 10:59:43 RequestDumperValve[/ilt]: cookie=com.skillsoft.mgs.sso.RedirectorServlet.ReturnToSkillPort=http:// dkoesxp/djk/home/index.cfm?selectdTab=0 2004-10-28 10:59:43 RequestDumperValve[/ilt]: cookie=CFMX_JSESSIONID=c8301990451098975559821 2004-10-28 10:59:43 RequestDumperValve[/ilt]: cookie=CFID=19459 2004-10-28 10:59:43 RequestDumperValve[/ilt]: cookie=CFTOKEN=98634115 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=accept=text/xml,application/xml,application/xhtml+xml,text/html;q =0.9,text/plain;q=0.8,image/png,*/*;q=0.5 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=accept-language=en-us,en;q=0.5 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=connection=keep-alive 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=host=dkoesxp 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=referer=http://dkoesxp/ilt/ilt/iltUpload.do;jsessionid=3048D443AD 4341273FB5FED42958E7C4 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=user-agent=Mozilla/5.0 (Windows; U; Windows NT 5.1; rv:1.7.3) Gecko/20041001 Firefox/0.10.1 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=cookie=com.skillsoft.mgs.sso.RedirectorServlet.ReturnToSkillPort= http://dkoesxp/djk/home/index.cfm?selectdTab=0; CFMX_JSESSIONID=c8301990451098975559821; CFID=19459; CFTOKEN=98634115 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=content-length=340147 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=content-type=multipart/form-data; boundary=---41184676334 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=accept-encoding=gzip,deflate 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=accept-charset=ISO-8859-1,utf-8;q=0.7,*;q=0.7 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=keep-alive=300 2004-10-28 10:59:43 RequestDumperValve[/ilt]: locale=en_US 2004-10-28 10:59:43 RequestDumperValve[/ilt]: method=POST 2004-10-28 10:59:43 RequestDumperValve[/ilt]: pathInfo=null 2004-10-28 10:59:43 RequestDumperValve[/ilt]: protocol=HTTP/1.1 2004-10-28 10:59:43 RequestDumperValve[/ilt]: queryString=null 2004-10-28 10:59:43 RequestDumperValve[/ilt]: remoteAddr=10.20.3.42 2004-10-28 10:59:43 RequestDumperValve[/ilt]: remoteHost=10.20.3.42 2004-10-28 10:59:43 RequestDumperValve[/ilt]: remoteUser=null 2004-10-28 10:59:43 RequestDumperValve[/ilt]: requestedSessionId=3048D443AD4341273FB5FED42958E7C4 2004-10-28 10:59:43 RequestDumperValve[/ilt]: scheme=http 2004-10-28 10:59:43 RequestDumperValve[/ilt]: serverName=dkoesxp 2004-10-28 10:59:43 RequestDumperValve[/ilt]: serverPort=80 2004-10-28 10:59:43 RequestDumperValve[/ilt]: servletPath=/ilt/iltPerformUpload.do 2004-10-28 10:59:43 RequestDumperValve[/ilt]: isSecure=false 2004-10-28 10:59:43 RequestDumperValve[/ilt]: --- 2004-10-28 10:59:43 StandardWrapperValve[action]: Servlet.service() for servlet action threw exception org.apache.commons.fileupload.FileUploadException: Processing of multipart/form-data request failed. \WEB-INF\ilt\temp\upload_0001.tmp (The system cannot find the path specified) at org.apache.commons.fileupload.FileUploadBase.parseRequest(FileUploadBase .java:429) at
Can Tomcat Contexts have class naming collisions?
We have Tomcat 4.1.30 in Win2000 using JDK 1.4.2_05. We are having a problem where ONE of our classes will not load. The class name is Marketplace.class (package com.marketplace.core) Our Tomcat webapp (Context) is named 'marketplace'. Code works fine except when you try to reference the 'Marketplace' class. (with and without the fqdn) You get a NoClassDefFoundError. If I rename the class to something else, it works fine. We tried other 1.4 java versions, and they do not effect the problem. If your context is named 'marketplace', will Tomcat have trouble with a class named 'Marketplace'? (this is the effect we are seeing) Thanks for any help/advice you can offer. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: problems with apache-tomcat connection ...
On Thu, 28 Oct 2004, Phillip Qin wrote: Hi Phillip, Thank you for your comment about my doubt, however I want to know what the apache errors mean and if those affect the performance of my system anyway. Greetings, Clara Ines Pe¤a de Carrillo Divisi¢n de Servicios de Informaci¢n Universidad Industrial de Santander Bucaramanga, Colombia It took a while to figure out that broken pipe. It's not that fancy. It usually happens when use visits a page and stop/cancel during page loading. -Original Message- From: Clara Ines Pena de Carrillo [mailto:[EMAIL PROTECTED] Sent: October 28, 2004 9:12 AM To: [EMAIL PROTECTED] Subject: problems with apache-tomcat connection ... Hi everybody, sorry if this is a silly question because I am not an expert, but I was looking for the solution to my problem consulting to google and nobody has answered about the following problems with apache-tomcat connection: a) I have Solaris 8, apache 2.0.47, jdk 1.4.2, tomcat 4.1.24 and the binary module of mod_jk version 2-2.0.42 b) Seems that the system works ok, however I got the following messages in the apache error_log file: [error] Error ajp_process_callback - write failed [error] ajp13.service() ajpGetReply recoverable error 3 Error ajp_process_callback - write failed ajp13.service() ajpGetReply recoverable error 3 ajp13.service() Error forwarding ajp13:localhost:8009 1 0 [error] mod_jk.handler() Error connecting to tomcat 3 [Thu Oct 28 08:02:26 2004] [error] mod_jk child init 1 0 [Thu Oct 28 08:02:31 2004] [error] jk2_init() Can't find child 8163 in scoreboard [Thu Oct 28 08:02:31 2004] [error] mod_jk child init 1 -2 and in the tomcat logs file: StandardWrapperValve[default]: Servlet.service() for servlet default threw exception java.net.SocketException: Broken pipe at java.net.SocketOutputStream.socketWrite0(Native Method) at java.net.SocketOutputStream.socketWrite(SocketOutputStream.java:92) at java.net.SocketOutputStream.write(SocketOutputStream.java:136) at org.apache.jk.common.ChannelSocket.send(ChannelSocket.java:407) at org.apache.jk.common.ChannelSocket.invoke(ChannelSocket.java:599) at org.apache.jk.server.JkCoyoteHandler.doWrite(JkCoyoteHandler.java:216) at org.apache.coyote.Response.doWrite(Response.java:524) at org.apache.coyote.tomcat4.OutputBuffer.realWriteBytes(OutputBuffer.java:384) at org.apache.tomcat.util.buf.ByteChunk.flushBuffer(ByteChunk.java:439) at org.apache.tomcat.util.buf.ByteChunk.append(ByteChunk.java:359) at org.apache.coyote.tomcat4.OutputBuffer.writeBytes(OutputBuffer.java:411) at org.apache.coyote.tomcat4.OutputBuffer.write(OutputBuffer.java:398) at org.apache.coyote.tomcat4.CoyoteOutputStream.write(CoyoteOutputStream.java:1 10) at org.apache.catalina.servlets.DefaultServlet.copyRange(DefaultServlet.java:19 96) ... My question is, what is missing in my configuration ?. How these problems affect the performance of my system ?. Thanks a lot, -- Clara Ines Pe¤a de Carrillo Divisi¢n de Servicios de Informaci¢n Universidad Industrial de Santander Bucaramanga, Colombia - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Can Tomcat Contexts have class naming collisions?
Hi, If your context is named 'marketplace', will Tomcat have trouble with a class named 'Marketplace'? (this is the effect we are seeing) No, Tomcat won't have this kind of trouble. Have you considered the difference between a ClassNotFoundException and a NoClassDefFoundError? Your message said the latter is what you're getting, not the former. Search your runtime classpath (e.g. common/lib, shared/lib, WEB-INF/classes, WEB-INF/lib) to ensure there's only one version of Marketplace.class in the classpath, and that version is the one expected by the calling code. 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: File upload
The error occurs before execution makes it to my upload action. -Original Message- From: Allistair Crossley [mailto:[EMAIL PROTECTED] Sent: Thursday, October 28, 2004 12:02 PM To: Tomcat Users List Subject: RE: File upload you have the _exact_ same setup as we do here (except we are on 5.0.25). we upload files using a multipart form and file control. then in the struts action List items = null; try { DiskFileUpload upload = new DiskFileUpload(); items = upload.parseRequest(request); } catch (FileUploadException fuE) { logger.error(user.getUsername() + : error.checkin.parse; + fuE.getMessage()); errors.add(ActionMessages.GLOBAL_MESSAGE, new ActionMessage(error.checkin.parse)); break DO_CHECKIN; } FileItem primaryFile = null; while (iterator.hasNext()) { FileItem item = (FileItem) iterator.next(); ... // capture the actual upload file if (! item.isFormField()) { primaryFile = item; } } this was out of the box tomcat/common fileupload/struts, so you must have configured something somewhere? -Original Message- From: Shapira, Yoav [mailto:[EMAIL PROTECTED] Sent: 28 October 2004 16:56 To: Tomcat Users List Subject: RE: File upload Hi, First question, as always: does it work on Tomcat standalone, i.e. removing IIS, JK2, and the redirector out of the mix (just for now, for testing)? Yoav Shapira http://www.yoavshapira.com -Original Message- From: Derrick Koes [mailto:[EMAIL PROTECTED] Sent: Thursday, October 28, 2004 11:52 AM To: Tomcat Users List Subject: File upload Configuration: Tomcat 5.0.24 IIS 5.0 JK2 connector Isapi_redirector2.dll Struts 1.1 Commons file upload 1.0 I seem to have an issue that when the file is a certain size it is written to a temp file on the file system before it is parsed by the multipart parser (at least that's what the exception message leads me to believe). However, since the working directory is my web app (/WEB-INF/ilt), the parser can't seem to find the file (not a fully qualified file name). This is a guess, but if correct I don't know how to fix the problem. Any help is appreciated. Belows is the stack trace and data from the request dumper valve: 2004-10-28 10:59:32 RequestDumperValve[/ilt]: === 2004-10-28 10:59:43 RequestDumperValve[/ilt]: REQUEST URI =/ilt/ilt/iltPerformUpload.do 2004-10-28 10:59:43 RequestDumperValve[/ilt]: authType=null 2004-10-28 10:59:43 RequestDumperValve[/ilt]: characterEncoding=null 2004-10-28 10:59:43 RequestDumperValve[/ilt]: contentLength=340147 2004-10-28 10:59:43 RequestDumperValve[/ilt]: contentType=multipart/form-data; boundary=---41184676334 2004-10-28 10:59:43 RequestDumperValve[/ilt]:contextPath=/ilt 2004-10-28 10:59:43 RequestDumperValve[/ilt]: cookie=com.skillsoft.mgs.sso.RedirectorServlet.ReturnToSkillP ort=http:/ / dkoesxp/djk/home/index.cfm?selectdTab=0 2004-10-28 10:59:43 RequestDumperValve[/ilt]: cookie=CFMX_JSESSIONID=c8301990451098975559821 2004-10-28 10:59:43 RequestDumperValve[/ilt]: cookie=CFID=19459 2004-10-28 10:59:43 RequestDumperValve[/ilt]: cookie=CFTOKEN=98634115 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=accept=text/xml,application/xml,application/xhtml+xml, text/html; q =0.9,text/plain;q=0.8,image/png,*/*;q=0.5 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=accept-language=en-us,en;q=0.5 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=connection=keep-alive 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=host=dkoesxp 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=referer=http://dkoesxp/ilt/ilt/iltUpload.do;jsessionid =3048D443A D 4341273FB5FED42958E7C4 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=user-agent=Mozilla/5.0 (Windows; U; Windows NT 5.1; rv:1.7.3) Gecko/20041001 Firefox/0.10.1 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=cookie=com.skillsoft.mgs.sso.RedirectorServlet.ReturnT oSkillPort = http://dkoesxp/djk/home/index.cfm?selectdTab=0; CFMX_JSESSIONID=c8301990451098975559821; CFID=19459; CFTOKEN=98634115 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=content-length=340147 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=content-type=multipart/form-data; boundary=---41184676334 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=accept-encoding=gzip,deflate 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=accept-charset=ISO-8859-1,utf-8;q=0.7,*;q=0.7 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=keep-alive=300 2004-10-28 10:59:43 RequestDumperValve[/ilt]: locale=en_US 2004-10-28 10:59:43 RequestDumperValve[/ilt]: method=POST 2004-10-28 10:59:43 RequestDumperValve[/ilt]: pathInfo=null 2004-10-28 10:59:43
Tiles and other sruts tags in Tomcat5
I am trying to use Struts 1.2.4 on Tomcat 5.0. I seem to get errors for any of the struts tags including the tiles tag due to incompatibility with JSP2.0 or something, I guess. Here is the error: :\wqt\vcs\tis\nb\tel-web-ube\build\generated\src\org\apache\jsp\jsp\shop \Input_jsp.java:112: _jspx_meth_html_base_0(javax.servlet.jsp.tagext.JspTag,javax.servlet.jsp .PageContext) in org.apache.jsp.jsp.shop.Input_jsp cannot be applied to (org.apache.struts.taglib.html.HtmlTag,javax.servlet.jsp.PageContext) if (_jspx_meth_html_base_0(_jspx_th_html_html_0, _jspx_page_context)) ^ C:\wqt\vcs\tis\nb\tel-web-ube\build\generated\src\org\apache\jsp\jsp\sho p\Input_jsp.java:148: _jspx_meth_html_radio_0(javax.servlet.jsp.tagext.JspTag,javax.servlet.js p.PageContext) in org.apache.jsp.jsp.shop.Input_jsp cannot be applied to (org.apache.struts.taglib.html.FormTag,javax.servlet.jsp.PageContext) I am assuming others use struts tags running on tomcat 5.0 container. Is there any reason why I get this error? If so, how can it be fixed? Thanks. Geeth - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
newbie question
Is there an easy way to specify that one of the apps in the webapps folder be served off one port (e.g. 80) whereas another app should be served off another port (8080)? Thanks for your help, Luke Fernandez Weber State University - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: File upload
oh i see. i guess we don't use it in this way. org.apache.commons.fileupload.FileUploadException is being thrown before you hit the action you say? how do you involve common fileupload direct from the form post if you don't mind my asking? -Original Message- From: Derrick Koes [mailto:[EMAIL PROTECTED] Sent: 28 October 2004 17:08 To: Tomcat Users List Subject: RE: File upload The error occurs before execution makes it to my upload action. -Original Message- From: Allistair Crossley [mailto:[EMAIL PROTECTED] Sent: Thursday, October 28, 2004 12:02 PM To: Tomcat Users List Subject: RE: File upload you have the _exact_ same setup as we do here (except we are on 5.0.25). we upload files using a multipart form and file control. then in the struts action List items = null; try { DiskFileUpload upload = new DiskFileUpload(); items = upload.parseRequest(request); } catch (FileUploadException fuE) { logger.error(user.getUsername() + : error.checkin.parse; + fuE.getMessage()); errors.add(ActionMessages.GLOBAL_MESSAGE, new ActionMessage(error.checkin.parse)); break DO_CHECKIN; } FileItem primaryFile = null; while (iterator.hasNext()) { FileItem item = (FileItem) iterator.next(); ... // capture the actual upload file if (! item.isFormField()) { primaryFile = item; } } this was out of the box tomcat/common fileupload/struts, so you must have configured something somewhere? -Original Message- From: Shapira, Yoav [mailto:[EMAIL PROTECTED] Sent: 28 October 2004 16:56 To: Tomcat Users List Subject: RE: File upload Hi, First question, as always: does it work on Tomcat standalone, i.e. removing IIS, JK2, and the redirector out of the mix (just for now, for testing)? Yoav Shapira http://www.yoavshapira.com -Original Message- From: Derrick Koes [mailto:[EMAIL PROTECTED] Sent: Thursday, October 28, 2004 11:52 AM To: Tomcat Users List Subject: File upload Configuration: Tomcat 5.0.24 IIS 5.0 JK2 connector Isapi_redirector2.dll Struts 1.1 Commons file upload 1.0 I seem to have an issue that when the file is a certain size it is written to a temp file on the file system before it is parsed by the multipart parser (at least that's what the exception message leads me to believe). However, since the working directory is my web app (/WEB-INF/ilt), the parser can't seem to find the file (not a fully qualified file name). This is a guess, but if correct I don't know how to fix the problem. Any help is appreciated. Belows is the stack trace and data from the request dumper valve: 2004-10-28 10:59:32 RequestDumperValve[/ilt]: === 2004-10-28 10:59:43 RequestDumperValve[/ilt]: REQUEST URI =/ilt/ilt/iltPerformUpload.do 2004-10-28 10:59:43 RequestDumperValve[/ilt]: authType=null 2004-10-28 10:59:43 RequestDumperValve[/ilt]: characterEncoding=null 2004-10-28 10:59:43 RequestDumperValve[/ilt]: contentLength=340147 2004-10-28 10:59:43 RequestDumperValve[/ilt]: contentType=multipart/form-data; boundary=---41184676334 2004-10-28 10:59:43 RequestDumperValve[/ilt]: contextPath=/ilt 2004-10-28 10:59:43 RequestDumperValve[/ilt]: cookie=com.skillsoft.mgs.sso.RedirectorServlet.ReturnToSkillP ort=http:/ / dkoesxp/djk/home/index.cfm?selectdTab=0 2004-10-28 10:59:43 RequestDumperValve[/ilt]: cookie=CFMX_JSESSIONID=c8301990451098975559821 2004-10-28 10:59:43 RequestDumperValve[/ilt]: cookie=CFID=19459 2004-10-28 10:59:43 RequestDumperValve[/ilt]: cookie=CFTOKEN=98634115 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=accept=text/xml,application/xml,application/xhtml+xml, text/html; q =0.9,text/plain;q=0.8,image/png,*/*;q=0.5 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=accept-language=en-us,en;q=0.5 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=connection=keep-alive 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=host=dkoesxp 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=referer=http://dkoesxp/ilt/ilt/iltUpload.do;jsessionid =3048D443A D 4341273FB5FED42958E7C4 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=user-agent=Mozilla/5.0 (Windows; U; Windows NT 5.1; rv:1.7.3) Gecko/20041001 Firefox/0.10.1 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=cookie=com.skillsoft.mgs.sso.RedirectorServlet.ReturnT oSkillPort = http://dkoesxp/djk/home/index.cfm?selectdTab=0; CFMX_JSESSIONID=c8301990451098975559821; CFID=19459; CFTOKEN=98634115 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=content-length=340147 2004-10-28 10:59:43 RequestDumperValve[/ilt]:
RE: JNDI DataSource GlobalResources problem
Funny, I was thinking of mentioning that in my post below, but didn't because I hadn't checked that it would definitely work. But that's what I'm going to do from now on. Thanks Yoav, this looks like the right answer to me. Don't know why I didn't think of it earlier really. I suppose it's because when you first try this, you google for something like servlet connection pooling, and get to various DBCP how-to pages, and away you go down that path, and get tied up with context.xml vs server.xml, META-INF/ vs conf/, and WARs vs unpacked apps. etc etc. No more context.xml or Contexts for me. Unless the spec changes -Original Message- From: Shapira, Yoav [mailto:[EMAIL PROTECTED] Sent: Thursday 28 October 2004 16:21 To: Tomcat Users List Subject: RE: JNDI DataSource GlobalResources problem Hi, Besides completely agreeing with Steve (so Benson, your time could probably be better spent elsewhere, such as by putting on the tech writer hat you mentioned earlier), I wanted to mention one other alternative. You *always* have the option of *not* using container-managed resources, and managing them yourself. I do this 99% of the time, as the portability and management advantages overwhelmingly cover cons. For the DBCP case, you take the DBCP jar (and its two dependent jars), put them in WEB-INF/lib, and write a couple of lines of code to configure your pool(s). Literally, that's all it takes, and now you've got your one package with no need for a server-specific configuration file etc. Yoav Shapira http://www.yoavshapira.com -Original Message- From: Steve Kirk [mailto:[EMAIL PROTECTED] Sent: Thursday, October 28, 2004 11:11 AM To: 'Tomcat Users List' Subject: RE: JNDI DataSource GlobalResources problem I have been in learning mode about Resource/Context config for the last few weeks, mainly from the point of view of DBCP config. I did find all the alternatives confusing at first, but having read more and more docs, and getting some help from the good people on this list, I'm starting to get it now. I've had DBCP working for several months, the confusing issue is how best to config it. IMHO, TC provides very good support for configuring Resources/Contexts, and doesn't need to change (although there may be one or two documentation tweaks that would help beginners, which I intend to submit soon). Whether you are a container administrator wanting to config global resources, or per-webapp resources, or a webapp author wanting to config your own resources, TC provides you with at least one way to do it. And these are all bonus features, in the sense that they are not mandated in the servlet spec. Again IMHO, if there is a problem in this area, it's that these features are TC-specific, so if you use them in developing your webapp, you are making your webapp less portable to other containers (as Yoav has pointed out). An improvement in portability can only really come if the servlet spec changes to mandate how this stuff is configured. So the spec is the area that needs to be addressed next, rather than TC. Until then, there are ways of doing pretty much what you want with TC already in this area. It might not be _exactly_ as you would ideally like, but hey, it works if you really need it, and you can be bothered to use what's already there. And this list is always there to help you if you are confused as to which option to choose. all just IMHO :) -Original Message- From: Benson Margulies [mailto:[EMAIL PROTECTED] Sent: Thursday 28 October 2004 02:28 To: Tomcat Users List; Allen Holub Subject: RE: Re[2]: JNDI DataSource GlobalResources problem As I read the discussion, I don't think that anyone claimed that only WAR's are interesting or important. Yoav, in one posting, explained that the servlet spec is written from a point of view that only requires support for applications in unexploded WAR files. That is not the same thing as stating that only WARs are interesting. It is just a way of illuminating some requirements for behaviors of the container. In another posting, Yoav expressed a generic distaste for Global resources -- all other things being equal. Of late, there's been a rash of people wanting to use global resources, either for database pooling or for JNI reasons. The commercial containers have various kinds of adminstrative UI arrangements for this purpose. No one that I know of supports a self-contained package that bundles a web app with administrative/resource/global configuration, but I haven't made a comprehensive survey. Semi-seriously, I wonder about a GRaR -- a Global Resource aRchive, as a way to package up a set of global classlibs and the config to deploy them into JNDI. I've experimented with writing a simple Java command-line application to set up an application
RE: problems with apache-tomcat connection ...
I can't represent other people. My observation is it has no impact on performance. -Original Message- From: Clara Ines Pena de Carrillo [mailto:[EMAIL PROTECTED] Sent: October 28, 2004 12:06 PM To: Phillip Qin Cc: 'Tomcat Users List' Subject: RE: problems with apache-tomcat connection ... On Thu, 28 Oct 2004, Phillip Qin wrote: Hi Phillip, Thank you for your comment about my doubt, however I want to know what the apache errors mean and if those affect the performance of my system anyway. Greetings, Clara Ines Pe¤a de Carrillo Divisi¢n de Servicios de Informaci¢n Universidad Industrial de Santander Bucaramanga, Colombia It took a while to figure out that broken pipe. It's not that fancy. It usually happens when use visits a page and stop/cancel during page loading. -Original Message- From: Clara Ines Pena de Carrillo [mailto:[EMAIL PROTECTED] Sent: October 28, 2004 9:12 AM To: [EMAIL PROTECTED] Subject: problems with apache-tomcat connection ... Hi everybody, sorry if this is a silly question because I am not an expert, but I was looking for the solution to my problem consulting to google and nobody has answered about the following problems with apache-tomcat connection: a) I have Solaris 8, apache 2.0.47, jdk 1.4.2, tomcat 4.1.24 and the binary module of mod_jk version 2-2.0.42 b) Seems that the system works ok, however I got the following messages in the apache error_log file: [error] Error ajp_process_callback - write failed [error] ajp13.service() ajpGetReply recoverable error 3 Error ajp_process_callback - write failed ajp13.service() ajpGetReply recoverable error 3 ajp13.service() Error forwarding ajp13:localhost:8009 1 0 [error] mod_jk.handler() Error connecting to tomcat 3 [Thu Oct 28 08:02:26 2004] [error] mod_jk child init 1 0 [Thu Oct 28 08:02:31 2004] [error] jk2_init() Can't find child 8163 in scoreboard [Thu Oct 28 08:02:31 2004] [error] mod_jk child init 1 -2 and in the tomcat logs file: StandardWrapperValve[default]: Servlet.service() for servlet default threw exception java.net.SocketException: Broken pipe at java.net.SocketOutputStream.socketWrite0(Native Method) at java.net.SocketOutputStream.socketWrite(SocketOutputStream.java:92) at java.net.SocketOutputStream.write(SocketOutputStream.java:136) at org.apache.jk.common.ChannelSocket.send(ChannelSocket.java:407) at org.apache.jk.common.ChannelSocket.invoke(ChannelSocket.java:599) at org.apache.jk.server.JkCoyoteHandler.doWrite(JkCoyoteHandler.java:216) at org.apache.coyote.Response.doWrite(Response.java:524) at org.apache.coyote.tomcat4.OutputBuffer.realWriteBytes(OutputBuffer.java:384) at org.apache.tomcat.util.buf.ByteChunk.flushBuffer(ByteChunk.java:439) at org.apache.tomcat.util.buf.ByteChunk.append(ByteChunk.java:359) at org.apache.coyote.tomcat4.OutputBuffer.writeBytes(OutputBuffer.java:411) at org.apache.coyote.tomcat4.OutputBuffer.write(OutputBuffer.java:398) at org.apache.coyote.tomcat4.CoyoteOutputStream.write(CoyoteOutputStream.java:1 10) at org.apache.catalina.servlets.DefaultServlet.copyRange(DefaultServlet.java:19 96) ... My question is, what is missing in my configuration ?. How these problems affect the performance of my system ?. Thanks a lot, -- Clara Ines Pe¤a de Carrillo Divisi¢n de Servicios de Informaci¢n Universidad Industrial de Santander Bucaramanga, Colombia - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] !DSPAM:418119616796902398182!
RE: JNDI DataSource GlobalResources problem
Hi, Don't know why I didn't think of it earlier really. I suppose it's because when you first try this, you google for something like servlet connection pooling, and get to various DBCP how-to pages, and away you go down that path, and get tied up with context.xml vs server.xml, META-INF/ vs conf/, and WARs vs unpacked apps. etc etc. Yeah, and *that* may be where our docs are lacking: we should make it clear container-managed-resource stuff is optional, and explain the alternatives, pros/cons, etc. 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: newbie question
Hi, Yes: define separate Engines or Services for the two apps in your server.xml, and put each connector only in the Service where you want it. Yoav Shapira http://www.yoavshapira.com -Original Message- From: Luke FERNANDEZ [mailto:[EMAIL PROTECTED] Sent: Thursday, October 28, 2004 12:16 PM To: [EMAIL PROTECTED] Subject: newbie question Is there an easy way to specify that one of the apps in the webapps folder be served off one port (e.g. 80) whereas another app should be served off another port (8080)? Thanks for your help, Luke Fernandez Weber State University - 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: File upload
The stack trace shows that struts'org.apache.struts.upload.CommonsMultipartRequestHandler.handleReq uest(CommonsMultipartRequestHandler.java:233) invokes commons file upload. I honestly don't know how struts decides to do this. I'm assuming like any other application by examining the request header. I also assume this happens before struts determines what action to run, otherwise I'd be getting to my action. Derrick ContactInfo NameDerrick Koes/Name TitleSenior Software Engineer/Title Company name=SkillSoft url=http://www.skillsoft.com/ AIMcodeauthor2001/AIM Email[EMAIL PROTECTED]/Email Phone(603) 305-1753/Phone Fax/ Quote attributedTo=YodaNo, try not, do or do not, there is no try./Quote /ContactInfo -Original Message- From: Allistair Crossley [mailto:[EMAIL PROTECTED] Sent: Thursday, October 28, 2004 12:13 PM To: Tomcat Users List Subject: RE: File upload oh i see. i guess we don't use it in this way. org.apache.commons.fileupload.FileUploadException is being thrown before you hit the action you say? how do you involve common fileupload direct from the form post if you don't mind my asking? -Original Message- From: Derrick Koes [mailto:[EMAIL PROTECTED] Sent: 28 October 2004 17:08 To: Tomcat Users List Subject: RE: File upload The error occurs before execution makes it to my upload action. -Original Message- From: Allistair Crossley [mailto:[EMAIL PROTECTED] Sent: Thursday, October 28, 2004 12:02 PM To: Tomcat Users List Subject: RE: File upload you have the _exact_ same setup as we do here (except we are on 5.0.25). we upload files using a multipart form and file control. then in the struts action List items = null; try { DiskFileUpload upload = new DiskFileUpload(); items = upload.parseRequest(request); } catch (FileUploadException fuE) { logger.error(user.getUsername() + : error.checkin.parse; + fuE.getMessage()); errors.add(ActionMessages.GLOBAL_MESSAGE, new ActionMessage(error.checkin.parse)); break DO_CHECKIN; } FileItem primaryFile = null; while (iterator.hasNext()) { FileItem item = (FileItem) iterator.next(); ... // capture the actual upload file if (! item.isFormField()) { primaryFile = item; } } this was out of the box tomcat/common fileupload/struts, so you must have configured something somewhere? -Original Message- From: Shapira, Yoav [mailto:[EMAIL PROTECTED] Sent: 28 October 2004 16:56 To: Tomcat Users List Subject: RE: File upload Hi, First question, as always: does it work on Tomcat standalone, i.e. removing IIS, JK2, and the redirector out of the mix (just for now, for testing)? Yoav Shapira http://www.yoavshapira.com -Original Message- From: Derrick Koes [mailto:[EMAIL PROTECTED] Sent: Thursday, October 28, 2004 11:52 AM To: Tomcat Users List Subject: File upload Configuration: Tomcat 5.0.24 IIS 5.0 JK2 connector Isapi_redirector2.dll Struts 1.1 Commons file upload 1.0 I seem to have an issue that when the file is a certain size it is written to a temp file on the file system before it is parsed by the multipart parser (at least that's what the exception message leads me to believe). However, since the working directory is my web app (/WEB-INF/ilt), the parser can't seem to find the file (not a fully qualified file name). This is a guess, but if correct I don't know how to fix the problem. Any help is appreciated. Belows is the stack trace and data from the request dumper valve: 2004-10-28 10:59:32 RequestDumperValve[/ilt]: === 2004-10-28 10:59:43 RequestDumperValve[/ilt]: REQUEST URI =/ilt/ilt/iltPerformUpload.do 2004-10-28 10:59:43 RequestDumperValve[/ilt]: authType=null 2004-10-28 10:59:43 RequestDumperValve[/ilt]: characterEncoding=null 2004-10-28 10:59:43 RequestDumperValve[/ilt]: contentLength=340147 2004-10-28 10:59:43 RequestDumperValve[/ilt]: contentType=multipart/form-data; boundary=---41184676334 2004-10-28 10:59:43 RequestDumperValve[/ilt]: contextPath=/ilt 2004-10-28 10:59:43 RequestDumperValve[/ilt]: cookie=com.skillsoft.mgs.sso.RedirectorServlet.ReturnToSkillP ort=http:/ / dkoesxp/djk/home/index.cfm?selectdTab=0 2004-10-28 10:59:43 RequestDumperValve[/ilt]: cookie=CFMX_JSESSIONID=c8301990451098975559821 2004-10-28 10:59:43 RequestDumperValve[/ilt]: cookie=CFID=19459 2004-10-28 10:59:43 RequestDumperValve[/ilt]: cookie=CFTOKEN=98634115 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=accept=text/xml,application/xml,application/xhtml+xml, text/html; q =0.9,text/plain;q=0.8,image/png,*/*;q=0.5 2004-10-28 10:59:43 RequestDumperValve[/ilt]:
RE: File upload
As I mentioned in another reply, I never get to my action. And, yes my action mirrors the struts-upload.war example pretty closely. Multiple files may have been uploaded in my case, so I have to handle that. In the case posted, only one file was uploaded. Derrick ContactInfo NameDerrick Koes/Name TitleSenior Software Engineer/Title Company name=SkillSoft url=http://www.skillsoft.com/ AIMcodeauthor2001/AIM Email[EMAIL PROTECTED]/Email Phone(603) 305-1753/Phone Fax/ Quote attributedTo=YodaNo, try not, do or do not, there is no try./Quote /ContactInfo -Original Message- From: Caroline Jen [mailto:[EMAIL PROTECTED] Sent: Thursday, October 28, 2004 12:04 PM To: Tomcat Users List Subject: Re: File upload Are you following the struts-upload.war example that comes with the Struts 1.1? In that example, the uploaded file size is checked. If a file is stored somewhere under the AppName/WEB-INF directory, you have to use the stream to read the file. --- Derrick Koes [EMAIL PROTECTED] wrote: Configuration: Tomcat 5.0.24 IIS 5.0 JK2 connector Isapi_redirector2.dll Struts 1.1 Commons file upload 1.0 I seem to have an issue that when the file is a certain size it is written to a temp file on the file system before it is parsed by the multipart parser (at least that's what the exception message leads me to believe). However, since the working directory is my web app (/WEB-INF/ilt), the parser can't seem to find the file (not a fully qualified file name). This is a guess, but if correct I don't know how to fix the problem. Any help is appreciated. Belows is the stack trace and data from the request dumper valve: 2004-10-28 10:59:32 RequestDumperValve[/ilt]: === 2004-10-28 10:59:43 RequestDumperValve[/ilt]: REQUEST URI =/ilt/ilt/iltPerformUpload.do 2004-10-28 10:59:43 RequestDumperValve[/ilt]: authType=null 2004-10-28 10:59:43 RequestDumperValve[/ilt]: characterEncoding=null 2004-10-28 10:59:43 RequestDumperValve[/ilt]: contentLength=340147 2004-10-28 10:59:43 RequestDumperValve[/ilt]: contentType=multipart/form-data; boundary=---41184676334 2004-10-28 10:59:43 RequestDumperValve[/ilt]: contextPath=/ilt 2004-10-28 10:59:43 RequestDumperValve[/ilt]: cookie=com.skillsoft.mgs.sso.RedirectorServlet.ReturnToSkillPort=http:// dkoesxp/djk/home/index.cfm?selectdTab=0 2004-10-28 10:59:43 RequestDumperValve[/ilt]: cookie=CFMX_JSESSIONID=c8301990451098975559821 2004-10-28 10:59:43 RequestDumperValve[/ilt]: cookie=CFID=19459 2004-10-28 10:59:43 RequestDumperValve[/ilt]: cookie=CFTOKEN=98634115 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=accept=text/xml,application/xml,application/xhtml+xml,text/html;q =0.9,text/plain;q=0.8,image/png,*/*;q=0.5 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=accept-language=en-us,en;q=0.5 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=connection=keep-alive 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=host=dkoesxp 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=referer=http://dkoesxp/ilt/ilt/iltUpload.do;jsessionid=3048D443AD 4341273FB5FED42958E7C4 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=user-agent=Mozilla/5.0 (Windows; U; Windows NT 5.1; rv:1.7.3) Gecko/20041001 Firefox/0.10.1 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=cookie=com.skillsoft.mgs.sso.RedirectorServlet.ReturnToSkillPort= http://dkoesxp/djk/home/index.cfm?selectdTab=0; CFMX_JSESSIONID=c8301990451098975559821; CFID=19459; CFTOKEN=98634115 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=content-length=340147 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=content-type=multipart/form-data; boundary=---41184676334 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=accept-encoding=gzip,deflate 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=accept-charset=ISO-8859-1,utf-8;q=0.7,*;q=0.7 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=keep-alive=300 2004-10-28 10:59:43 RequestDumperValve[/ilt]: locale=en_US 2004-10-28 10:59:43 RequestDumperValve[/ilt]: method=POST 2004-10-28 10:59:43 RequestDumperValve[/ilt]: pathInfo=null 2004-10-28 10:59:43 RequestDumperValve[/ilt]: protocol=HTTP/1.1 2004-10-28 10:59:43 RequestDumperValve[/ilt]: queryString=null 2004-10-28 10:59:43 RequestDumperValve[/ilt]: remoteAddr=10.20.3.42 2004-10-28 10:59:43 RequestDumperValve[/ilt]: remoteHost=10.20.3.42 2004-10-28 10:59:43 RequestDumperValve[/ilt]: remoteUser=null 2004-10-28 10:59:43 RequestDumperValve[/ilt]: requestedSessionId=3048D443AD4341273FB5FED42958E7C4 2004-10-28 10:59:43 RequestDumperValve[/ilt]: scheme=http 2004-10-28 10:59:43 RequestDumperValve[/ilt]: serverName=dkoesxp 2004-10-28 10:59:43 RequestDumperValve[/ilt]:
RE: OutOfMemoryError: unable to create new native thread
Hi Yoav. Thanks for the response. I believe I have found the issue. Apparently Windows NT/2000 defaults to a 1mb virtual thread stack size per thread unless otherwise stated. In addition a maximum of 2gb of thread stack space per process is allowed by Windows (not sure if this can be changed or not!). Thus the tomcat JVM could only have 2000 odd concurrent threads - and on a server that hosts 50 sites, of which 20 are fairly busy this could be a problem. Thus I reduced the thread stack size to 512k (via -Xss512k). In addition there were about 12 connectors in tomcat where the minSpareThreads were set too high - so set them back to default of 4 (from between 50 and 100). Hectic. Now we see how she bahaves! Regards, Carl -Original Message- From: Shapira, Yoav [mailto:[EMAIL PROTECTED] Sent: Thursday, October 28, 2004 5:38 PM To: Tomcat Users List Subject: RE: OutOfMemoryError: unable to create new native thread Hi, - Actually ran out of memory - Hit max # of threads allowed to run (OS dependant?) This is the most likely cause in your case, and it's OS-dependent as you surmised. On *nix this is adjusted via the ulimit (-n) command. But on Windows 2000 Server, I'm not sure off the top of my head. Google? 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: OutOfMemoryError: unable to create new native thread
Hi, Apparently Windows NT/2000 defaults to a 1mb virtual thread stack size per thread unless otherwise stated. In addition a maximum of 2gb of thread stack space per process is allowed by Windows (not sure if this can be changed or not!). Thus the tomcat JVM could only have 2000 odd concurrent threads - and on a server that hosts 50 sites, of which 20 are fairly busy this could be a problem. Thanks for posting your findings and solutions. These type of posts make the best archival materials, assuming people bother to search the archives. Just out of curiosity, why are you running all the sites on one Tomcat instance? Reduced maintenance? I'm not arguing against it, it clearly works fine, and I do similar things myself. Just curious for your reasoning. 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]
channelUnix.file is missing
I read that tomcat is supposed to create the channelUnix.file=${jkHome}/work/jk2.socket file. But it did not. I use the binary of tomcat, do i have to use src to be able to use unixsocket ? Thanks FM - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: newbie question
Or you could run multiple instances of Tomcat On Thu, 2004-10-28 at 12:23, Shapira, Yoav wrote: Hi, Yes: define separate Engines or Services for the two apps in your server.xml, and put each connector only in the Service where you want it. Yoav Shapira http://www.yoavshapira.com -Original Message- From: Luke FERNANDEZ [mailto:[EMAIL PROTECTED] Sent: Thursday, October 28, 2004 12:16 PM To: [EMAIL PROTECTED] Subject: newbie question Is there an easy way to specify that one of the apps in the webapps folder be served off one port (e.g. 80) whereas another app should be served off another port (8080)? Thanks for your help, Luke Fernandez Weber State University - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] This e-mail, including any attachments, is a confidential business communication, and may contain information that is confidential, proprietary and/or privileged. This e-mail is intended only for the individual(s) to whom it is addressed, and may not be saved, copied, printed, disclosed or used by anyone else. If you are not the(an) intended recipient, please immediately delete this e-mail from your computer system and notify the sender. Thank you. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Upload MS DOC or Image file errors.
Hi, I am use the File Upload. I need to read the whole file contents in a String buffer. If the file is text, it works. But if the file is in other format, such as MS Doc, I can load the file, and the file size is the same comparing the original file, but the format is changed, and I cannot open it. The related code in a servlet is as following: . int nSize=0; // now !item.isFormField() java.io.InputStream fstrm = item.getInputStream(); int rnum=0; buf = new byte[262144]; // the doc file size I am testing is 13 buyes. while (rnum=0){ // I have to read all the contents rnum = fstrm.read(buf, (int)nSize, 100); if (rnum 0) nSize += rnum; } fstrm.close(); if ( nSize0) { pBuffer = new String(buf, 0, (int)nSize); // I like to test if it read correctly: FileWriter fileOut = new FileWriter(C:/DocAttachment/strFileName.doc); fileOut.write(pBuffer); fileOut.flush(); fileOut.close(); .. } I use Apache2 and Tomcat5. Please forward instruction. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
proxy support and X-Forwarded-For
Hallo, Does Tomcat support the headers: X-Forwarded-For, X-Forwarded-Host and X-Forwarded-Server when running behind a proxy? And if not, would this be a nice feature? I'm running Tomcat 5.0.25 behind Apache 1.3/mod_proxy and doesn't look like Tomcat uses these headers. Any thoughts? I'm willing to try to implement these if it is needed by more people. Ronald.
AW: Upload MS DOC or Image file errors.
Hi Hi, I am use the File Upload. I need to read the whole file contents in a String buffer. Why into a String buffer? This is propably a charset encoding problem. Do NOT read it into a stringbuffer. See FileWriter documentation: FileWriter is meant for writing streams of characters. For writing streams of raw bytes, consider using a FileOutputStream. So change your method: . int nSize=0; // now !item.isFormField() java.io.InputStream fstrm = item.getInputStream(); int rnum=0; buf = new byte[262144]; // the doc file size I am testing is 13 buyes. while (rnum=0){ // I have to read all the contents rnum = fstrm.read(buf, (int)nSize, 100); if (rnum 0) nSize += rnum; } fstrm.close(); if ( nSize0) { // I like to test if it read correctly: FileOutputStream fileOut = new FileOutputStream(C:/DocAttachment/strFileName.doc); fileOut.write(buf, 0, nSize); fileOut.flush(); fileOut.close(); .. } Beside that: You know that you could simply do: item.write( new File( C:/DocAttachment/strFileName.doc ) ); Regards, Steffen smime.p7s Description: S/MIME cryptographic signature
AW: proxy support and X-Forwarded-For
Hi Does Tomcat support the headers: X-Forwarded-For, X-Forwarded-Host and X-Forwarded-Server when running behind a proxy? I'm running Tomcat 5.0.25 behind Apache 1.3/mod_proxy and doesn't look like Tomcat uses these headers. What would you expect tomcat to do when these headers are present? Regards, Steffen smime.p7s Description: S/MIME cryptographic signature
Re: AW: proxy support and X-Forwarded-For
On Thu Oct 28 19:50:35 CEST 2004 Steffen Heil [EMAIL PROTECTED] wrote: Hi Does Tomcat support the headers: X-Forwarded-For, X-Forwarded-Host and X-Forwarded-Server when running behind a proxy? I'm running Tomcat 5.0.25 behind Apache 1.3/mod_proxy and doesn't look like Tomcat uses these headers. What would you expect tomcat to do when these headers are present? Regards, Steffen X-Forwarded-For contains the IP address of the client, so Tomcat can return that in ServletRequest.getRemoteAddr() in stead of the IP of the proxy server. I understand this is a security risk if you didn't close your firewall. It is possible to add an option trustProxy=true|false to the config. X-Forwarded-Host and X-Forwarded-Server contain the server name from the request. This can override the setting proxyName. I still have to find out the difference between X-Forwarded-Host and X-Forwarded-Server as Apache fills them with the same value in my case. Ronald.
RE: newbie question
Can you run multiple instances of Tomcat? I tried this but I ran into problems. I'm running Sakai (the open source Learning Management System) which installs its own Tomcat engine. When I try to start up my own non-Sakai Tomcat instance from the command line (which resides in a completely separate jakarta-tomcat-5.0.28 folder) a new DOS window pops up and it seems like it goes through the entire deployment in the conventional manner. But instead of staying open, that second DOS window eventually closes. And then when I try to request pages against the second Tomcat instance I don't get anything back in the browser. The Sakai instance still serves pages correctly. However, if the Sakai Tomcat server is turned off I can turn on my other instance and serve pages from it. Is there a way to make both Tomcat engines run simultaneously without conflict? Cheers, Luke Fernandez [EMAIL PROTECTED] 10/28/2004 11:11:05 AM Or you could run multiple instances of Tomcat On Thu, 2004-10-28 at 12:23, Shapira, Yoav wrote: Hi, Yes: define separate Engines or Services for the two apps in your server.xml, and put each connector only in the Service where you want it. Yoav Shapira http://www.yoavshapira.com -Original Message- From: Luke FERNANDEZ [mailto:[EMAIL PROTECTED] Sent: Thursday, October 28, 2004 12:16 PM To: [EMAIL PROTECTED] Subject: newbie question Is there an easy way to specify that one of the apps in the webapps folder be served off one port (e.g. 80) whereas another app should be served off another port (8080)? Thanks for your help, Luke Fernandez Weber State University - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] This e-mail, including any attachments, is a confidential business communication, and may contain information that is confidential, proprietary and/or privileged. This e-mail is intended only for the individual(s) to whom it is addressed, and may not be saved, copied, printed, disclosed or used by anyone else. If you are not the(an) intended recipient, please immediately delete this e-mail from your computer system and notify the sender. Thank you. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: No Images Displayed
The problem was that modJK was only set up to serve .jsp files through tomcat, but not the images bundled in my application. I reconfigured it to handle all the applications in the webapps directory and any files in their sub directories. Thanks -Original Message- From: Allistair Crossley [mailto:[EMAIL PROTECTED] Sent: 28 October 2004 13:24 To: Tomcat Users List Subject: RE: No Images Displayed if you right click on one of the missing images and view properties, what does the URL look like? does it point to where you would expect? this sounds like the URL to the images is not visible via the web server AC -Original Message- From: Ciaran Hanley [mailto:[EMAIL PROTECTED] Sent: 28 October 2004 12:32 To: Tomcat User Mailing List Subject: No Images Displayed Hi, We have just moved to a new server with tomcat 5 and apache 2 which are linked using modjk. I have uploaded a working version of an application to the webapps directory on the server. My problem is when I try and access the login page of the application none of the images or style sheets are being loaded and all I see is a plain page with some text and username and password text boxes. Would any of you know what is causing this? Thanks, Ciaran FONT SIZE=1 FACE=VERDANA,ARIAL COLOR=BLUE --- QAS Ltd. Developers of QuickAddress Software a href=http://www.qas.com;www.qas.com/a Registered in England: No 2582055 Registered in Australia: No 082 851 474 --- /FONT - 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: File upload
Upon reviewing some struts code and documentation, the memory threshold for a file to be parsed for upload is 256K (configurable). If the file is over that size, I believe the uploader puts it in a temp file. However, since the url to retrieve it for parsing is a relative path, the parser cannot find it. Can anyone verify this? Thanks, Derrick -Original Message- From: Derrick Koes [mailto:[EMAIL PROTECTED] Sent: Thursday, October 28, 2004 11:52 AM To: Tomcat Users List Subject: File upload Configuration: Tomcat 5.0.24 IIS 5.0 JK2 connector Isapi_redirector2.dll Struts 1.1 Commons file upload 1.0 I seem to have an issue that when the file is a certain size it is written to a temp file on the file system before it is parsed by the multipart parser (at least that's what the exception message leads me to believe). However, since the working directory is my web app (/WEB-INF/ilt), the parser can't seem to find the file (not a fully qualified file name). This is a guess, but if correct I don't know how to fix the problem. Any help is appreciated. Belows is the stack trace and data from the request dumper valve: 2004-10-28 10:59:32 RequestDumperValve[/ilt]: === 2004-10-28 10:59:43 RequestDumperValve[/ilt]: REQUEST URI =/ilt/ilt/iltPerformUpload.do 2004-10-28 10:59:43 RequestDumperValve[/ilt]: authType=null 2004-10-28 10:59:43 RequestDumperValve[/ilt]: characterEncoding=null 2004-10-28 10:59:43 RequestDumperValve[/ilt]: contentLength=340147 2004-10-28 10:59:43 RequestDumperValve[/ilt]: contentType=multipart/form-data; boundary=---41184676334 2004-10-28 10:59:43 RequestDumperValve[/ilt]:contextPath=/ilt 2004-10-28 10:59:43 RequestDumperValve[/ilt]: cookie=com.skillsoft.mgs.sso.RedirectorServlet.ReturnToSkillPort=http:// dkoesxp/djk/home/index.cfm?selectdTab=0 2004-10-28 10:59:43 RequestDumperValve[/ilt]: cookie=CFMX_JSESSIONID=c8301990451098975559821 2004-10-28 10:59:43 RequestDumperValve[/ilt]: cookie=CFID=19459 2004-10-28 10:59:43 RequestDumperValve[/ilt]: cookie=CFTOKEN=98634115 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=accept=text/xml,application/xml,application/xhtml+xml,text/html;q =0.9,text/plain;q=0.8,image/png,*/*;q=0.5 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=accept-language=en-us,en;q=0.5 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=connection=keep-alive 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=host=dkoesxp 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=referer=http://dkoesxp/ilt/ilt/iltUpload.do;jsessionid=3048D443AD 4341273FB5FED42958E7C4 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=user-agent=Mozilla/5.0 (Windows; U; Windows NT 5.1; rv:1.7.3) Gecko/20041001 Firefox/0.10.1 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=cookie=com.skillsoft.mgs.sso.RedirectorServlet.ReturnToSkillPort= http://dkoesxp/djk/home/index.cfm?selectdTab=0; CFMX_JSESSIONID=c8301990451098975559821; CFID=19459; CFTOKEN=98634115 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=content-length=340147 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=content-type=multipart/form-data; boundary=---41184676334 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=accept-encoding=gzip,deflate 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=accept-charset=ISO-8859-1,utf-8;q=0.7,*;q=0.7 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=keep-alive=300 2004-10-28 10:59:43 RequestDumperValve[/ilt]: locale=en_US 2004-10-28 10:59:43 RequestDumperValve[/ilt]: method=POST 2004-10-28 10:59:43 RequestDumperValve[/ilt]: pathInfo=null 2004-10-28 10:59:43 RequestDumperValve[/ilt]: protocol=HTTP/1.1 2004-10-28 10:59:43 RequestDumperValve[/ilt]:queryString=null 2004-10-28 10:59:43 RequestDumperValve[/ilt]: remoteAddr=10.20.3.42 2004-10-28 10:59:43 RequestDumperValve[/ilt]: remoteHost=10.20.3.42 2004-10-28 10:59:43 RequestDumperValve[/ilt]: remoteUser=null 2004-10-28 10:59:43 RequestDumperValve[/ilt]: requestedSessionId=3048D443AD4341273FB5FED42958E7C4 2004-10-28 10:59:43 RequestDumperValve[/ilt]: scheme=http 2004-10-28 10:59:43 RequestDumperValve[/ilt]: serverName=dkoesxp 2004-10-28 10:59:43 RequestDumperValve[/ilt]: serverPort=80 2004-10-28 10:59:43 RequestDumperValve[/ilt]: servletPath=/ilt/iltPerformUpload.do 2004-10-28 10:59:43 RequestDumperValve[/ilt]: isSecure=false 2004-10-28 10:59:43 RequestDumperValve[/ilt]: --- 2004-10-28 10:59:43 StandardWrapperValve[action]: Servlet.service() for servlet action threw exception org.apache.commons.fileupload.FileUploadException: Processing of multipart/form-data request failed. \WEB-INF\ilt\temp\upload_0001.tmp (The system cannot find the path specified) at
RE: newbie question
you have conflict in ports, both tomcats can not run on the same port at the same time. instead of calling start.bat, call catalina.bat run to have the windows stay the same and not shutdown on you FIlip -Original Message- From: Luke FERNANDEZ [mailto:[EMAIL PROTECTED] Sent: Thursday, October 28, 2004 1:27 PM To: [EMAIL PROTECTED] Subject: RE: newbie question Can you run multiple instances of Tomcat? I tried this but I ran into problems. I'm running Sakai (the open source Learning Management System) which installs its own Tomcat engine. When I try to start up my own non-Sakai Tomcat instance from the command line (which resides in a completely separate jakarta-tomcat-5.0.28 folder) a new DOS window pops up and it seems like it goes through the entire deployment in the conventional manner. But instead of staying open, that second DOS window eventually closes. And then when I try to request pages against the second Tomcat instance I don't get anything back in the browser. The Sakai instance still serves pages correctly. However, if the Sakai Tomcat server is turned off I can turn on my other instance and serve pages from it. Is there a way to make both Tomcat engines run simultaneously without conflict? Cheers, Luke Fernandez [EMAIL PROTECTED] 10/28/2004 11:11:05 AM Or you could run multiple instances of Tomcat On Thu, 2004-10-28 at 12:23, Shapira, Yoav wrote: Hi, Yes: define separate Engines or Services for the two apps in your server.xml, and put each connector only in the Service where you want it. Yoav Shapira http://www.yoavshapira.com -Original Message- From: Luke FERNANDEZ [mailto:[EMAIL PROTECTED] Sent: Thursday, October 28, 2004 12:16 PM To: [EMAIL PROTECTED] Subject: newbie question Is there an easy way to specify that one of the apps in the webapps folder be served off one port (e.g. 80) whereas another app should be served off another port (8080)? Thanks for your help, Luke Fernandez Weber State University - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] This e-mail, including any attachments, is a confidential business communication, and may contain information that is confidential, proprietary and/or privileged. This e-mail is intended only for the individual(s) to whom it is addressed, and may not be saved, copied, printed, disclosed or used by anyone else. If you are not the(an) intended recipient, please immediately delete this e-mail from your computer system and notify the sender. Thank you. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] --- Incoming mail is certified Virus Free. Checked by AVG anti-virus system (http://www.grisoft.com). Version: 6.0.778 / Virus Database: 525 - Release Date: 10/15/2004 --- Outgoing mail is certified Virus Free. Checked by AVG anti-virus system (http://www.grisoft.com). Version: 6.0.778 / Virus Database: 525 - Release Date: 10/15/2004 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: No Images Displayed
Thats fine that what JK is supposed to do and thats what it is doing.. I assume your mappings are *.jsp or /servlet/* and such like. It sounds like you you apache virtual host just needs configuring .. DocumentRoot /path to webapp/appname This way when requests for stuff that isn't handled by JK/Tomcat apache can deal with it. Mark On Thu, 28 Oct 2004 19:25:03 +0100, Ciaran Hanley [EMAIL PROTECTED] wrote: The problem was that modJK was only set up to serve .jsp files through tomcat, but not the images bundled in my application. I reconfigured it to handle all the applications in the webapps directory and any files in their sub directories. Thanks -Original Message- From: Allistair Crossley [mailto:[EMAIL PROTECTED] Sent: 28 October 2004 13:24 To: Tomcat Users List Subject: RE: No Images Displayed if you right click on one of the missing images and view properties, what does the URL look like? does it point to where you would expect? this sounds like the URL to the images is not visible via the web server AC -Original Message- From: Ciaran Hanley [mailto:[EMAIL PROTECTED] Sent: 28 October 2004 12:32 To: Tomcat User Mailing List Subject: No Images Displayed Hi, We have just moved to a new server with tomcat 5 and apache 2 which are linked using modjk. I have uploaded a working version of an application to the webapps directory on the server. My problem is when I try and access the login page of the application none of the images or style sheets are being loaded and all I see is a plain page with some text and username and password text boxes. Would any of you know what is causing this? Thanks, Ciaran FONT SIZE=1 FACE=VERDANA,ARIAL COLOR=BLUE --- QAS Ltd. Developers of QuickAddress Software a href=http://www.qas.com;www.qas.com/a Registered in England: No 2582055 Registered in Australia: No 082 851 474 --- /FONT - 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: File upload
Yep, taking IIS and the connector out of the picture produces the same problem. ContactInfo NameDerrick Koes/Name TitleSenior Software Engineer/Title Company name=SkillSoft url=http://www.skillsoft.com/ AIMcodeauthor2001/AIM Email[EMAIL PROTECTED]/Email Phone(603) 305-1753/Phone Fax/ Quote attributedTo=YodaNo, try not, do or do not, there is no try./Quote /ContactInfo -Original Message- From: Shapira, Yoav [mailto:[EMAIL PROTECTED] Sent: Thursday, October 28, 2004 11:56 AM To: Tomcat Users List Subject: RE: File upload Hi, First question, as always: does it work on Tomcat standalone, i.e. removing IIS, JK2, and the redirector out of the mix (just for now, for testing)? Yoav Shapira http://www.yoavshapira.com -Original Message- From: Derrick Koes [mailto:[EMAIL PROTECTED] Sent: Thursday, October 28, 2004 11:52 AM To: Tomcat Users List Subject: File upload Configuration: Tomcat 5.0.24 IIS 5.0 JK2 connector Isapi_redirector2.dll Struts 1.1 Commons file upload 1.0 I seem to have an issue that when the file is a certain size it is written to a temp file on the file system before it is parsed by the multipart parser (at least that's what the exception message leads me to believe). However, since the working directory is my web app (/WEB-INF/ilt), the parser can't seem to find the file (not a fully qualified file name). This is a guess, but if correct I don't know how to fix the problem. Any help is appreciated. Belows is the stack trace and data from the request dumper valve: 2004-10-28 10:59:32 RequestDumperValve[/ilt]: === 2004-10-28 10:59:43 RequestDumperValve[/ilt]: REQUEST URI =/ilt/ilt/iltPerformUpload.do 2004-10-28 10:59:43 RequestDumperValve[/ilt]: authType=null 2004-10-28 10:59:43 RequestDumperValve[/ilt]: characterEncoding=null 2004-10-28 10:59:43 RequestDumperValve[/ilt]: contentLength=340147 2004-10-28 10:59:43 RequestDumperValve[/ilt]: contentType=multipart/form-data; boundary=---41184676334 2004-10-28 10:59:43 RequestDumperValve[/ilt]:contextPath=/ilt 2004-10-28 10:59:43 RequestDumperValve[/ilt]: cookie=com.skillsoft.mgs.sso.RedirectorServlet.ReturnToSkillPort=http:/ / dkoesxp/djk/home/index.cfm?selectdTab=0 2004-10-28 10:59:43 RequestDumperValve[/ilt]: cookie=CFMX_JSESSIONID=c8301990451098975559821 2004-10-28 10:59:43 RequestDumperValve[/ilt]: cookie=CFID=19459 2004-10-28 10:59:43 RequestDumperValve[/ilt]: cookie=CFTOKEN=98634115 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=accept=text/xml,application/xml,application/xhtml+xml,text/html; q =0.9,text/plain;q=0.8,image/png,*/*;q=0.5 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=accept-language=en-us,en;q=0.5 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=connection=keep-alive 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=host=dkoesxp 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=referer=http://dkoesxp/ilt/ilt/iltUpload.do;jsessionid=3048D443A D 4341273FB5FED42958E7C4 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=user-agent=Mozilla/5.0 (Windows; U; Windows NT 5.1; rv:1.7.3) Gecko/20041001 Firefox/0.10.1 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=cookie=com.skillsoft.mgs.sso.RedirectorServlet.ReturnToSkillPort = http://dkoesxp/djk/home/index.cfm?selectdTab=0; CFMX_JSESSIONID=c8301990451098975559821; CFID=19459; CFTOKEN=98634115 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=content-length=340147 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=content-type=multipart/form-data; boundary=---41184676334 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=accept-encoding=gzip,deflate 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=accept-charset=ISO-8859-1,utf-8;q=0.7,*;q=0.7 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=keep-alive=300 2004-10-28 10:59:43 RequestDumperValve[/ilt]: locale=en_US 2004-10-28 10:59:43 RequestDumperValve[/ilt]: method=POST 2004-10-28 10:59:43 RequestDumperValve[/ilt]: pathInfo=null 2004-10-28 10:59:43 RequestDumperValve[/ilt]: protocol=HTTP/1.1 2004-10-28 10:59:43 RequestDumperValve[/ilt]:queryString=null 2004-10-28 10:59:43 RequestDumperValve[/ilt]: remoteAddr=10.20.3.42 2004-10-28 10:59:43 RequestDumperValve[/ilt]: remoteHost=10.20.3.42 2004-10-28 10:59:43 RequestDumperValve[/ilt]: remoteUser=null 2004-10-28 10:59:43 RequestDumperValve[/ilt]: requestedSessionId=3048D443AD4341273FB5FED42958E7C4 2004-10-28 10:59:43 RequestDumperValve[/ilt]: scheme=http 2004-10-28 10:59:43 RequestDumperValve[/ilt]: serverName=dkoesxp 2004-10-28 10:59:43 RequestDumperValve[/ilt]: serverPort=80 2004-10-28 10:59:43 RequestDumperValve[/ilt]: servletPath=/ilt/iltPerformUpload.do 2004-10-28 10:59:43 RequestDumperValve[/ilt]: isSecure=false 2004-10-28 10:59:43 RequestDumperValve[/ilt]:
RE: newbie question
Ok I'll research that. Any chance you could give me an example of how to write this in the server.xml? I've got the following webapp folder structure. balancer jsp-examples ROOT_OLD sakai-chef-tool sakai-dav sakai-embedded sakai-framework-component sakai-james sakai-legacy-component sakai-provider sakai-shared sakai-z-last servlets-examples TomProj The Sakai app should continue to be served (as it is currently) using the 8080 port. I'd like the TomProj app to be served from port 80. If you feel like I should figure this out myself maybe point me to a clear tutorial? Cheers, Luke [EMAIL PROTECTED] 10/28/2004 10:23:13 AM Hi, Yes: define separate Engines or Services for the two apps in your server.xml, and put each connector only in the Service where you want it. Yoav Shapira http://www.yoavshapira.com -Original Message- From: Luke FERNANDEZ [mailto:[EMAIL PROTECTED] Sent: Thursday, October 28, 2004 12:16 PM To: [EMAIL PROTECTED] Subject: newbie question Is there an easy way to specify that one of the apps in the webapps folder be served off one port (e.g. 80) whereas another app should be served off another port (8080)? Thanks for your help, Luke Fernandez Weber State University - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] This e-mail, including any attachments, is a confidential business communication, and may contain information that is confidential, proprietary and/or privileged. This e-mail is intended only for the individual(s) to whom it is addressed, and may not be saved, copied, printed, disclosed or used by anyone else. If you are not the(an) intended recipient, please immediately delete this e-mail from your computer system and notify the sender. Thank you. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: newbie question
There would be port conflict even though the Sakai Tomcat app serves from port 8080 while my Tomcat instance serves from port 80? Luke [EMAIL PROTECTED] 10/28/2004 12:28:46 PM you have conflict in ports, both tomcats can not run on the same port at the same time. instead of calling start.bat, call catalina.bat run to have the windows stay the same and not shutdown on you FIlip -Original Message- From: Luke FERNANDEZ [mailto:[EMAIL PROTECTED] Sent: Thursday, October 28, 2004 1:27 PM To: [EMAIL PROTECTED] Subject: RE: newbie question Can you run multiple instances of Tomcat? I tried this but I ran into problems. I'm running Sakai (the open source Learning Management System) which installs its own Tomcat engine. When I try to start up my own non-Sakai Tomcat instance from the command line (which resides in a completely separate jakarta-tomcat-5.0.28 folder) a new DOS window pops up and it seems like it goes through the entire deployment in the conventional manner. But instead of staying open, that second DOS window eventually closes. And then when I try to request pages against the second Tomcat instance I don't get anything back in the browser. The Sakai instance still serves pages correctly. However, if the Sakai Tomcat server is turned off I can turn on my other instance and serve pages from it. Is there a way to make both Tomcat engines run simultaneously without conflict? Cheers, Luke Fernandez [EMAIL PROTECTED] 10/28/2004 11:11:05 AM Or you could run multiple instances of Tomcat On Thu, 2004-10-28 at 12:23, Shapira, Yoav wrote: Hi, Yes: define separate Engines or Services for the two apps in your server.xml, and put each connector only in the Service where you want it. Yoav Shapira http://www.yoavshapira.com -Original Message- From: Luke FERNANDEZ [mailto:[EMAIL PROTECTED] Sent: Thursday, October 28, 2004 12:16 PM To: [EMAIL PROTECTED] Subject: newbie question Is there an easy way to specify that one of the apps in the webapps folder be served off one port (e.g. 80) whereas another app should be served off another port (8080)? Thanks for your help, Luke Fernandez Weber State University - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] This e-mail, including any attachments, is a confidential business communication, and may contain information that is confidential, proprietary and/or privileged. This e-mail is intended only for the individual(s) to whom it is addressed, and may not be saved, copied, printed, disclosed or used by anyone else. If you are not the(an) intended recipient, please immediately delete this e-mail from your computer system and notify the sender. Thank you. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] --- Incoming mail is certified Virus Free. Checked by AVG anti-virus system (http://www.grisoft.com). Version: 6.0.778 / Virus Database: 525 - Release Date: 10/15/2004 --- Outgoing mail is certified Virus Free. Checked by AVG anti-virus system (http://www.grisoft.com). Version: 6.0.778 / Virus Database: 525 - Release Date: 10/15/2004 - 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: newbie question
did you look at the other connectors? catalina.bat run - will tell you the message, try that Filip -Original Message- From: Luke FERNANDEZ [mailto:[EMAIL PROTECTED] Sent: Thursday, October 28, 2004 1:52 PM To: [EMAIL PROTECTED] Subject: RE: newbie question There would be port conflict even though the Sakai Tomcat app serves from port 8080 while my Tomcat instance serves from port 80? Luke [EMAIL PROTECTED] 10/28/2004 12:28:46 PM you have conflict in ports, both tomcats can not run on the same port at the same time. instead of calling start.bat, call catalina.bat run to have the windows stay the same and not shutdown on you FIlip -Original Message- From: Luke FERNANDEZ [mailto:[EMAIL PROTECTED] Sent: Thursday, October 28, 2004 1:27 PM To: [EMAIL PROTECTED] Subject: RE: newbie question Can you run multiple instances of Tomcat? I tried this but I ran into problems. I'm running Sakai (the open source Learning Management System) which installs its own Tomcat engine. When I try to start up my own non-Sakai Tomcat instance from the command line (which resides in a completely separate jakarta-tomcat-5.0.28 folder) a new DOS window pops up and it seems like it goes through the entire deployment in the conventional manner. But instead of staying open, that second DOS window eventually closes. And then when I try to request pages against the second Tomcat instance I don't get anything back in the browser. The Sakai instance still serves pages correctly. However, if the Sakai Tomcat server is turned off I can turn on my other instance and serve pages from it. Is there a way to make both Tomcat engines run simultaneously without conflict? Cheers, Luke Fernandez [EMAIL PROTECTED] 10/28/2004 11:11:05 AM Or you could run multiple instances of Tomcat On Thu, 2004-10-28 at 12:23, Shapira, Yoav wrote: Hi, Yes: define separate Engines or Services for the two apps in your server.xml, and put each connector only in the Service where you want it. Yoav Shapira http://www.yoavshapira.com -Original Message- From: Luke FERNANDEZ [mailto:[EMAIL PROTECTED] Sent: Thursday, October 28, 2004 12:16 PM To: [EMAIL PROTECTED] Subject: newbie question Is there an easy way to specify that one of the apps in the webapps folder be served off one port (e.g. 80) whereas another app should be served off another port (8080)? Thanks for your help, Luke Fernandez Weber State University - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] This e-mail, including any attachments, is a confidential business communication, and may contain information that is confidential, proprietary and/or privileged. This e-mail is intended only for the individual(s) to whom it is addressed, and may not be saved, copied, printed, disclosed or used by anyone else. If you are not the(an) intended recipient, please immediately delete this e-mail from your computer system and notify the sender. Thank you. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] --- Incoming mail is certified Virus Free. Checked by AVG anti-virus system (http://www.grisoft.com). Version: 6.0.778 / Virus Database: 525 - Release Date: 10/15/2004 --- Outgoing mail is certified Virus Free. Checked by AVG anti-virus system (http://www.grisoft.com). Version: 6.0.778 / Virus Database: 525 - Release Date: 10/15/2004 - 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] --- Incoming mail is certified Virus Free. Checked by AVG anti-virus system (http://www.grisoft.com). Version: 6.0.778 / Virus Database: 525 - Release Date: 10/15/2004 --- Outgoing mail is certified Virus Free. Checked by AVG anti-virus system (http://www.grisoft.com). Version: 6.0.778 / Virus Database: 525 - Release Date: 10/15/2004 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: newbie question
Ok. When I use catalina.bat run instead of startup the window stays open but the second instance (on port 80) still isnt serving pages. I've included the screen output that happens after running catalina.bat run. Looks like its saying something about address already in use: C:\tomcat\jakarta-tomcat-5.0.28\bincatalina.bat run Using CATALINA_BASE: C:\tomcat\jakarta-tomcat-5.0.28 Using CATALINA_HOME: C:\tomcat\jakarta-tomcat-5.0.28 Using CATALINA_TMPDIR: C:\tomcat\jakarta-tomcat-5.0.28\temp Using JAVA_HOME: C:\j2sdk1.4.2_05 Oct 28, 2004 12:58:57 PM org.apache.coyote.http11.Http11Protocol init INFO: Initializing Coyote HTTP/1.1 on http-80 Oct 28, 2004 12:58:57 PM org.apache.catalina.startup.Catalina load INFO: Initialization processed in 1953 ms Oct 28, 2004 12:58:57 PM org.apache.catalina.core.StandardService start INFO: Starting service Catalina Oct 28, 2004 12:58:57 PM org.apache.catalina.core.StandardEngine start INFO: Starting Servlet Engine: Apache Tomcat/5.0.28 Oct 28, 2004 12:58:57 PM org.apache.catalina.core.StandardHost start INFO: XML validation disabled Oct 28, 2004 12:58:57 PM org.apache.catalina.core.StandardHost getDeployer INFO: Create Host deployer for direct deployment ( non-jmx ) Oct 28, 2004 12:58:57 PM org.apache.catalina.core.StandardHostDeployer install INFO: Processing Context configuration file URL file:C:\tomcat\jakarta-tomcat-5. 0.28\conf\Catalina\localhost\admin.xml Oct 28, 2004 12:58:59 PM org.apache.struts.util.PropertyMessageResources init INFO: Initializing, config='org.apache.struts.util.LocalStrings', returnNull=tru e Oct 28, 2004 12:58:59 PM org.apache.struts.util.PropertyMessageResources init INFO: Initializing, config='org.apache.struts.action.ActionResources', returnNul l=true Oct 28, 2004 12:58:59 PM org.apache.struts.util.PropertyMessageResources init INFO: Initializing, config='org.apache.webapp.admin.ApplicationResources', retur nNull=true Oct 28, 2004 12:59:02 PM org.apache.catalina.core.StandardHostDeployer install INFO: Processing Context configuration file URL file:C:\tomcat\jakarta-tomcat-5. 0.28\conf\Catalina\localhost\balancer.xml Oct 28, 2004 12:59:02 PM org.apache.catalina.core.StandardHostDeployer install INFO: Processing Context configuration file URL file:C:\tomcat\jakarta-tomcat-5. 0.28\conf\Catalina\localhost\manager.xml Oct 28, 2004 12:59:02 PM org.apache.catalina.core.StandardHostDeployer install INFO: Installing web application at context path /jsp-examples from URL file:C:\ tomcat\jakarta-tomcat-5.0.28\webapps\jsp-examples Oct 28, 2004 12:59:03 PM org.apache.catalina.core.StandardHostDeployer install INFO: Installing web application at context path /Login from URL file:C:\tomcat\ jakarta-tomcat-5.0.28\webapps\Login Oct 28, 2004 12:59:04 PM org.apache.struts.util.PropertyMessageResources init INFO: Initializing, config='org.apache.struts.util.LocalStrings', returnNull=tru e Oct 28, 2004 12:59:04 PM org.apache.struts.util.PropertyMessageResources init INFO: Initializing, config='org.apache.struts.action.ActionResources', returnNul l=true Oct 28, 2004 12:59:04 PM org.apache.struts.util.PropertyMessageResources init INFO: Initializing, config='ApplicationResources', returnNull=true Oct 28, 2004 12:59:04 PM org.apache.catalina.core.StandardHostDeployer install INFO: Installing web application at context path from URL file:C:\tomcat\jakart a-tomcat-5.0.28\webapps\ROOT Oct 28, 2004 12:59:04 PM org.apache.catalina.core.StandardHostDeployer install INFO: Installing web application at context path /servlets-examples from URL fil e:C:\tomcat\jakarta-tomcat-5.0.28\webapps\servlets-examples Oct 28, 2004 12:59:05 PM org.apache.catalina.core.StandardHostDeployer install INFO: Installing web application at context path /tomcat-docs from URL file:C:\t omcat\jakarta-tomcat-5.0.28\webapps\tomcat-docs Oct 28, 2004 12:59:05 PM org.apache.catalina.core.StandardHostDeployer install INFO: Installing web application at context path /TomProj from URL file:C:\tomca t\jakarta-tomcat-5.0.28\webapps\TomProj Oct 28, 2004 12:59:06 PM org.apache.catalina.core.StandardHostDeployer install INFO: Installing web application at context path /webdav from URL file:C:\tomcat \jakarta-tomcat-5.0.28\webapps\webdav Oct 28, 2004 12:59:07 PM org.apache.coyote.http11.Http11Protocol start INFO: Starting Coyote HTTP/1.1 on http-80 Oct 28, 2004 12:59:07 PM org.apache.jk.common.ChannelSocket init INFO: Port busy 8009 java.net.BindException: Address already in use: JVM_Bind Oct 28, 2004 12:59:07 PM org.apache.jk.common.ChannelSocket init INFO: JK2: ajp13 listening on /0.0.0.0:8010 Oct 28, 2004 12:59:07 PM org.apache.jk.server.JkMain start INFO: Jk running ID=1 time=16/172 config=C:\tomcat\jakarta-tomcat-5.0.28\conf\j k2.properties Oct 28, 2004 12:59:07 PM org.apache.catalina.startup.Catalina start INFO: Server startup in 10437 ms StandardServer.await: create[8005]: java.net.BindException: Address already in u se: JVM_Bind java.net.BindException: Address already in use: JVM_Bind
RE: newbie question
you can have them run at the same time but you need to configure them to run on separate ports. for your standard TC 5.0.28 the file to edit is CATALINA_HOME/conf/server.xml - see the docs at http://jakarta.apache.org/tomcat/tomcat-5.0-doc/config/index.html for an explanation of how server.xml works (click links in the left margin to access further pages) -Original Message- From: Filip Hanik (lists) [mailto:[EMAIL PROTECTED] Sent: Thursday 28 October 2004 19:29 To: Tomcat Users List Subject: RE: newbie question you have conflict in ports, both tomcats can not run on the same port at the same time. instead of calling start.bat, call catalina.bat run to have the windows stay the same and not shutdown on you FIlip -Original Message- From: Luke FERNANDEZ [mailto:[EMAIL PROTECTED] Sent: Thursday, October 28, 2004 1:27 PM To: [EMAIL PROTECTED] Subject: RE: newbie question Can you run multiple instances of Tomcat? I tried this but I ran into problems. I'm running Sakai (the open source Learning Management System) which installs its own Tomcat engine. When I try to start up my own non-Sakai Tomcat instance from the command line (which resides in a completely separate jakarta-tomcat-5.0.28 folder) a new DOS window pops up and it seems like it goes through the entire deployment in the conventional manner. But instead of staying open, that second DOS window eventually closes. And then when I try to request pages against the second Tomcat instance I don't get anything back in the browser. The Sakai instance still serves pages correctly. However, if the Sakai Tomcat server is turned off I can turn on my other instance and serve pages from it. Is there a way to make both Tomcat engines run simultaneously without conflict? Cheers, Luke Fernandez [EMAIL PROTECTED] 10/28/2004 11:11:05 AM Or you could run multiple instances of Tomcat On Thu, 2004-10-28 at 12:23, Shapira, Yoav wrote: Hi, Yes: define separate Engines or Services for the two apps in your server.xml, and put each connector only in the Service where you want it. Yoav Shapira http://www.yoavshapira.com -Original Message- From: Luke FERNANDEZ [mailto:[EMAIL PROTECTED] Sent: Thursday, October 28, 2004 12:16 PM To: [EMAIL PROTECTED] Subject: newbie question Is there an easy way to specify that one of the apps in the webapps folder be served off one port (e.g. 80) whereas another app should be served off another port (8080)? Thanks for your help, Luke Fernandez Weber State University - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] This e-mail, including any attachments, is a confidential business communication, and may contain information that is confidential, proprietary and/or privileged. This e-mail is intended only for the individual(s) to whom it is addressed, and may not be saved, copied, printed, disclosed or used by anyone else. If you are not the(an) intended recipient, please immediately delete this e-mail from your computer system and notify the sender. Thank you. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] --- Incoming mail is certified Virus Free. Checked by AVG anti-virus system (http://www.grisoft.com). Version: 6.0.778 / Virus Database: 525 - Release Date: 10/15/2004 --- Outgoing mail is certified Virus Free. Checked by AVG anti-virus system (http://www.grisoft.com). Version: 6.0.778 / Virus Database: 525 - Release Date: 10/15/2004 - 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: newbie question
yes, and if you actually read the message StandardServer.await: create[8005]: java.net.BindException: Address already in u se: JVM_Bind java.net.BindException: Address already in use: JVM_Bind look for 8005 in your server.xml and you will find out that this is the shutdown port. Filip -Original Message- From: Luke FERNANDEZ [mailto:[EMAIL PROTECTED] Sent: Thursday, October 28, 2004 2:10 PM To: [EMAIL PROTECTED] Subject: RE: newbie question Ok. When I use catalina.bat run instead of startup the window stays open but the second instance (on port 80) still isnt serving pages. I've included the screen output that happens after running catalina.bat run. Looks like its saying something about address already in use: C:\tomcat\jakarta-tomcat-5.0.28\bincatalina.bat run Using CATALINA_BASE: C:\tomcat\jakarta-tomcat-5.0.28 Using CATALINA_HOME: C:\tomcat\jakarta-tomcat-5.0.28 Using CATALINA_TMPDIR: C:\tomcat\jakarta-tomcat-5.0.28\temp Using JAVA_HOME: C:\j2sdk1.4.2_05 Oct 28, 2004 12:58:57 PM org.apache.coyote.http11.Http11Protocol init INFO: Initializing Coyote HTTP/1.1 on http-80 Oct 28, 2004 12:58:57 PM org.apache.catalina.startup.Catalina load INFO: Initialization processed in 1953 ms Oct 28, 2004 12:58:57 PM org.apache.catalina.core.StandardService start INFO: Starting service Catalina Oct 28, 2004 12:58:57 PM org.apache.catalina.core.StandardEngine start INFO: Starting Servlet Engine: Apache Tomcat/5.0.28 Oct 28, 2004 12:58:57 PM org.apache.catalina.core.StandardHost start INFO: XML validation disabled Oct 28, 2004 12:58:57 PM org.apache.catalina.core.StandardHost getDeployer INFO: Create Host deployer for direct deployment ( non-jmx ) Oct 28, 2004 12:58:57 PM org.apache.catalina.core.StandardHostDeployer install INFO: Processing Context configuration file URL file:C:\tomcat\jakarta-tomcat-5. 0.28\conf\Catalina\localhost\admin.xml Oct 28, 2004 12:58:59 PM org.apache.struts.util.PropertyMessageResources init INFO: Initializing, config='org.apache.struts.util.LocalStrings', returnNull=tru e Oct 28, 2004 12:58:59 PM org.apache.struts.util.PropertyMessageResources init INFO: Initializing, config='org.apache.struts.action.ActionResources', returnNul l=true Oct 28, 2004 12:58:59 PM org.apache.struts.util.PropertyMessageResources init INFO: Initializing, config='org.apache.webapp.admin.ApplicationResources', retur nNull=true Oct 28, 2004 12:59:02 PM org.apache.catalina.core.StandardHostDeployer install INFO: Processing Context configuration file URL file:C:\tomcat\jakarta-tomcat-5. 0.28\conf\Catalina\localhost\balancer.xml Oct 28, 2004 12:59:02 PM org.apache.catalina.core.StandardHostDeployer install INFO: Processing Context configuration file URL file:C:\tomcat\jakarta-tomcat-5. 0.28\conf\Catalina\localhost\manager.xml Oct 28, 2004 12:59:02 PM org.apache.catalina.core.StandardHostDeployer install INFO: Installing web application at context path /jsp-examples from URL file:C:\ tomcat\jakarta-tomcat-5.0.28\webapps\jsp-examples Oct 28, 2004 12:59:03 PM org.apache.catalina.core.StandardHostDeployer install INFO: Installing web application at context path /Login from URL file:C:\tomcat\ jakarta-tomcat-5.0.28\webapps\Login Oct 28, 2004 12:59:04 PM org.apache.struts.util.PropertyMessageResources init INFO: Initializing, config='org.apache.struts.util.LocalStrings', returnNull=tru e Oct 28, 2004 12:59:04 PM org.apache.struts.util.PropertyMessageResources init INFO: Initializing, config='org.apache.struts.action.ActionResources', returnNul l=true Oct 28, 2004 12:59:04 PM org.apache.struts.util.PropertyMessageResources init INFO: Initializing, config='ApplicationResources', returnNull=true Oct 28, 2004 12:59:04 PM org.apache.catalina.core.StandardHostDeployer install INFO: Installing web application at context path from URL file:C:\tomcat\jakart a-tomcat-5.0.28\webapps\ROOT Oct 28, 2004 12:59:04 PM org.apache.catalina.core.StandardHostDeployer install INFO: Installing web application at context path /servlets-examples from URL fil e:C:\tomcat\jakarta-tomcat-5.0.28\webapps\servlets-examples Oct 28, 2004 12:59:05 PM org.apache.catalina.core.StandardHostDeployer install INFO: Installing web application at context path /tomcat-docs from URL file:C:\t omcat\jakarta-tomcat-5.0.28\webapps\tomcat-docs Oct 28, 2004 12:59:05 PM org.apache.catalina.core.StandardHostDeployer install INFO: Installing web application at context path /TomProj from URL file:C:\tomca t\jakarta-tomcat-5.0.28\webapps\TomProj Oct 28, 2004 12:59:06 PM org.apache.catalina.core.StandardHostDeployer install INFO: Installing web application at context path /webdav from URL file:C:\tomcat \jakarta-tomcat-5.0.28\webapps\webdav Oct 28, 2004 12:59:07 PM org.apache.coyote.http11.Http11Protocol start INFO: Starting Coyote HTTP/1.1 on http-80 Oct 28, 2004 12:59:07 PM org.apache.jk.common.ChannelSocket init INFO: Port busy 8009 java.net.BindException: Address already in use: JVM_Bind Oct 28, 2004 12:59:07 PM org.apache.jk.common.ChannelSocket init
RE: newbie question
So its more complicated than configuring server.xml for first instance (e.g. Sakai) as: !-- Define a non-SSL Coyote HTTP/1.1 Connector on port 8080 -- Connector port=8080 maxThreads=150 minSpareThreads=25 maxSpareThreads=75 enableLookups=false redirectPort=8443 acceptCount=100 debug=0 connectionTimeout=2 disableUploadTimeout=true / And the second server.xml for the second tomcat instance to be (notice 8080 is now 80): !-- Define a non-SSL Coyote HTTP/1.1 Connector on port 8080 -- Connector port=80 maxThreads=150 minSpareThreads=25 maxSpareThreads=75 enableLookups=false redirectPort=8443 acceptCount=100 debug=0 connectionTimeout=2 disableUploadTimeout=true / I need to go read the doc? Luke [EMAIL PROTECTED] 10/28/2004 1:08:28 PM you can have them run at the same time but you need to configure them to run on separate ports. for your standard TC 5.0.28 the file to edit is CATALINA_HOME/conf/server.xml - see the docs at http://jakarta.apache.org/tomcat/tomcat-5.0-doc/config/index.html for an explanation of how server.xml works (click links in the left margin to access further pages) -Original Message- From: Filip Hanik (lists) [mailto:[EMAIL PROTECTED] Sent: Thursday 28 October 2004 19:29 To: Tomcat Users List Subject: RE: newbie question you have conflict in ports, both tomcats can not run on the same port at the same time. instead of calling start.bat, call catalina.bat run to have the windows stay the same and not shutdown on you FIlip -Original Message- From: Luke FERNANDEZ [mailto:[EMAIL PROTECTED] Sent: Thursday, October 28, 2004 1:27 PM To: [EMAIL PROTECTED] Subject: RE: newbie question Can you run multiple instances of Tomcat? I tried this but I ran into problems. I'm running Sakai (the open source Learning Management System) which installs its own Tomcat engine. When I try to start up my own non-Sakai Tomcat instance from the command line (which resides in a completely separate jakarta-tomcat-5.0.28 folder) a new DOS window pops up and it seems like it goes through the entire deployment in the conventional manner. But instead of staying open, that second DOS window eventually closes. And then when I try to request pages against the second Tomcat instance I don't get anything back in the browser. The Sakai instance still serves pages correctly. However, if the Sakai Tomcat server is turned off I can turn on my other instance and serve pages from it. Is there a way to make both Tomcat engines run simultaneously without conflict? Cheers, Luke Fernandez [EMAIL PROTECTED] 10/28/2004 11:11:05 AM Or you could run multiple instances of Tomcat On Thu, 2004-10-28 at 12:23, Shapira, Yoav wrote: Hi, Yes: define separate Engines or Services for the two apps in your server.xml, and put each connector only in the Service where you want it. Yoav Shapira http://www.yoavshapira.com -Original Message- From: Luke FERNANDEZ [mailto:[EMAIL PROTECTED] Sent: Thursday, October 28, 2004 12:16 PM To: [EMAIL PROTECTED] Subject: newbie question Is there an easy way to specify that one of the apps in the webapps folder be served off one port (e.g. 80) whereas another app should be served off another port (8080)? Thanks for your help, Luke Fernandez Weber State University - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] This e-mail, including any attachments, is a confidential business communication, and may contain information that is confidential, proprietary and/or privileged. This e-mail is intended only for the individual(s) to whom it is addressed, and may not be saved, copied, printed, disclosed or used by anyone else. If you are not the(an) intended recipient, please immediately delete this e-mail from your computer system and notify the sender. Thank you. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] --- Incoming mail is certified Virus Free. Checked by AVG anti-virus system (http://www.grisoft.com). Version: 6.0.778 / Virus Database: 525 - Release Date: 10/15/2004 --- Outgoing mail is certified Virus Free. Checked by AVG anti-virus system (http://www.grisoft.com). Version: 6.0.778 /
RE: newbie question
Hi, The shutdown port is also in server.xml, at the top of the file. Yoav Shapira http://www.yoavshapira.com -Original Message- From: Luke FERNANDEZ [mailto:[EMAIL PROTECTED] Sent: Thursday, October 28, 2004 3:19 PM To: [EMAIL PROTECTED] Subject: RE: newbie question So its more complicated than configuring server.xml for first instance (e.g. Sakai) as: !-- Define a non-SSL Coyote HTTP/1.1 Connector on port 8080 -- Connector port=8080 maxThreads=150 minSpareThreads=25 maxSpareThreads=75 enableLookups=false redirectPort=8443 acceptCount=100 debug=0 connectionTimeout=2 disableUploadTimeout=true / And the second server.xml for the second tomcat instance to be (notice 8080 is now 80): !-- Define a non-SSL Coyote HTTP/1.1 Connector on port 8080 -- Connector port=80 maxThreads=150 minSpareThreads=25 maxSpareThreads=75 enableLookups=false redirectPort=8443 acceptCount=100 debug=0 connectionTimeout=2 disableUploadTimeout=true / I need to go read the doc? Luke [EMAIL PROTECTED] 10/28/2004 1:08:28 PM you can have them run at the same time but you need to configure them to run on separate ports. for your standard TC 5.0.28 the file to edit is CATALINA_HOME/conf/server.xml - see the docs at http://jakarta.apache.org/tomcat/tomcat-5.0-doc/config/index.html for an explanation of how server.xml works (click links in the left margin to access further pages) -Original Message- From: Filip Hanik (lists) [mailto:[EMAIL PROTECTED] Sent: Thursday 28 October 2004 19:29 To: Tomcat Users List Subject: RE: newbie question you have conflict in ports, both tomcats can not run on the same port at the same time. instead of calling start.bat, call catalina.bat run to have the windows stay the same and not shutdown on you FIlip -Original Message- From: Luke FERNANDEZ [mailto:[EMAIL PROTECTED] Sent: Thursday, October 28, 2004 1:27 PM To: [EMAIL PROTECTED] Subject: RE: newbie question Can you run multiple instances of Tomcat? I tried this but I ran into problems. I'm running Sakai (the open source Learning Management System) which installs its own Tomcat engine. When I try to start up my own non-Sakai Tomcat instance from the command line (which resides in a completely separate jakarta-tomcat-5.0.28 folder) a new DOS window pops up and it seems like it goes through the entire deployment in the conventional manner. But instead of staying open, that second DOS window eventually closes. And then when I try to request pages against the second Tomcat instance I don't get anything back in the browser. The Sakai instance still serves pages correctly. However, if the Sakai Tomcat server is turned off I can turn on my other instance and serve pages from it. Is there a way to make both Tomcat engines run simultaneously without conflict? Cheers, Luke Fernandez [EMAIL PROTECTED] 10/28/2004 11:11:05 AM Or you could run multiple instances of Tomcat On Thu, 2004-10-28 at 12:23, Shapira, Yoav wrote: Hi, Yes: define separate Engines or Services for the two apps in your server.xml, and put each connector only in the Service where you want it. Yoav Shapira http://www.yoavshapira.com -Original Message- From: Luke FERNANDEZ [mailto:[EMAIL PROTECTED] Sent: Thursday, October 28, 2004 12:16 PM To: [EMAIL PROTECTED] Subject: newbie question Is there an easy way to specify that one of the apps in the webapps folder be served off one port (e.g. 80) whereas another app should be served off another port (8080)? Thanks for your help, Luke Fernandez Weber State University - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] This e-mail, including any attachments, is a confidential business communication, and may contain information that is confidential, proprietary and/or privileged. This e-mail is intended only for the individual(s) to whom it is addressed, and may not be saved, copied, printed, disclosed or used by anyone else. If you are not the(an) intended recipient, please immediately delete this e-mail from your computer system and notify the sender. Thank you. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] --- Incoming mail is certified Virus Free. Checked by
RE: newbie question
I would advise that you read the doc, because it only takes a few mins, and then you'll understand what's really happening ;) But to get you going, assuming that you have not changed the standard server.xml significantly: 1. Change any active connector ports. The one you mention below is the first, but you need to change any others that are active, that are the same in both servers. 2. Locate the server tag (at the top of the file) and change its shutdown port (it can't be the same for both, otherwise both servers try to run a shutdown listener service on the same port) e.g. Server port=8005 shutdown=SHUTDOWN debug=0 These are the main things. If you have customised server.xml at all you might want to be sure there are no others by searching for port in server.xml in your text editor, and this will highlight all the possible places where port numbers might need to be changed. Note that any parts of server.xml commented out between !-- and -- are not active so you can ignore them for the time being. -Original Message- From: Luke FERNANDEZ [mailto:[EMAIL PROTECTED] Sent: Thursday 28 October 2004 20:19 To: [EMAIL PROTECTED] Subject: RE: newbie question So its more complicated than configuring server.xml for first instance (e.g. Sakai) as: !-- Define a non-SSL Coyote HTTP/1.1 Connector on port 8080 -- Connector port=8080 maxThreads=150 minSpareThreads=25 maxSpareThreads=75 enableLookups=false redirectPort=8443 acceptCount=100 debug=0 connectionTimeout=2 disableUploadTimeout=true / And the second server.xml for the second tomcat instance to be (notice 8080 is now 80): !-- Define a non-SSL Coyote HTTP/1.1 Connector on port 8080 -- Connector port=80 maxThreads=150 minSpareThreads=25 maxSpareThreads=75 enableLookups=false redirectPort=8443 acceptCount=100 debug=0 connectionTimeout=2 disableUploadTimeout=true / I need to go read the doc? Luke [EMAIL PROTECTED] 10/28/2004 1:08:28 PM you can have them run at the same time but you need to configure them to run on separate ports. for your standard TC 5.0.28 the file to edit is CATALINA_HOME/conf/server.xml - see the docs at http://jakarta.apache.org/tomcat/tomcat-5.0-doc/config/index.html for an explanation of how server.xml works (click links in the left margin to access further pages) -Original Message- From: Filip Hanik (lists) [mailto:[EMAIL PROTECTED] Sent: Thursday 28 October 2004 19:29 To: Tomcat Users List Subject: RE: newbie question you have conflict in ports, both tomcats can not run on the same port at the same time. instead of calling start.bat, call catalina.bat run to have the windows stay the same and not shutdown on you FIlip -Original Message- From: Luke FERNANDEZ [mailto:[EMAIL PROTECTED] Sent: Thursday, October 28, 2004 1:27 PM To: [EMAIL PROTECTED] Subject: RE: newbie question Can you run multiple instances of Tomcat? I tried this but I ran into problems. I'm running Sakai (the open source Learning Management System) which installs its own Tomcat engine. When I try to start up my own non-Sakai Tomcat instance from the command line (which resides in a completely separate jakarta-tomcat-5.0.28 folder) a new DOS window pops up and it seems like it goes through the entire deployment in the conventional manner. But instead of staying open, that second DOS window eventually closes. And then when I try to request pages against the second Tomcat instance I don't get anything back in the browser. The Sakai instance still serves pages correctly. However, if the Sakai Tomcat server is turned off I can turn on my other instance and serve pages from it. Is there a way to make both Tomcat engines run simultaneously without conflict? Cheers, Luke Fernandez [EMAIL PROTECTED] 10/28/2004 11:11:05 AM Or you could run multiple instances of Tomcat On Thu, 2004-10-28 at 12:23, Shapira, Yoav wrote: Hi, Yes: define separate Engines or Services for the two apps in your server.xml, and put each connector only in the Service where you want it. Yoav Shapira http://www.yoavshapira.com -Original Message- From: Luke FERNANDEZ [mailto:[EMAIL PROTECTED] Sent: Thursday, October 28, 2004 12:16 PM To: [EMAIL PROTECTED] Subject: newbie question Is there an easy way to specify that one of the apps in the webapps folder be served off one port (e.g. 80) whereas another app should be served off another port (8080)? Thanks for your help, Luke Fernandez Weber State University - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands,
RE: newbie question
Am I spamming if I say thanks to all of you for your help? I changed the following line in server.xml and now both instances run: !-- Server port=8005 shutdown=SHUTDOWN debug=0 -- Server port=8007 shutdown=SHUTDOWN debug=0 I hope I wasn't imposing by asking all these naive questions.for me this is a great way to learn. Like you said, I actually have to read the message (although I didn't know that create[8005] was referring to a port). I wonder if there's a way to filter out some of all the stuff that is outputted on startup so one can zero in more easily on the error? And why not output attempting to create port 8005 instead of create[8005]? But those are standard quibbles about cryptic error messages.thanks again for your help. Luke [EMAIL PROTECTED] 10/28/2004 1:09:55 PM yes, and if you actually read the message StandardServer.await: create[8005]: java.net.BindException: Address already in u se: JVM_Bind java.net.BindException: Address already in use: JVM_Bind look for 8005 in your server.xml and you will find out that this is the shutdown port. Filip -Original Message- From: Luke FERNANDEZ [mailto:[EMAIL PROTECTED] Sent: Thursday, October 28, 2004 2:10 PM To: [EMAIL PROTECTED] Subject: RE: newbie question Ok. When I use catalina.bat run instead of startup the window stays open but the second instance (on port 80) still isnt serving pages. I've included the screen output that happens after running catalina.bat run. Looks like its saying something about address already in use: C:\tomcat\jakarta-tomcat-5.0.28\bincatalina.bat run Using CATALINA_BASE: C:\tomcat\jakarta-tomcat-5.0.28 Using CATALINA_HOME: C:\tomcat\jakarta-tomcat-5.0.28 Using CATALINA_TMPDIR: C:\tomcat\jakarta-tomcat-5.0.28\temp Using JAVA_HOME: C:\j2sdk1.4.2_05 Oct 28, 2004 12:58:57 PM org.apache.coyote.http11.Http11Protocol init INFO: Initializing Coyote HTTP/1.1 on http-80 Oct 28, 2004 12:58:57 PM org.apache.catalina.startup.Catalina load INFO: Initialization processed in 1953 ms Oct 28, 2004 12:58:57 PM org.apache.catalina.core.StandardService start INFO: Starting service Catalina Oct 28, 2004 12:58:57 PM org.apache.catalina.core.StandardEngine start INFO: Starting Servlet Engine: Apache Tomcat/5.0.28 Oct 28, 2004 12:58:57 PM org.apache.catalina.core.StandardHost start INFO: XML validation disabled Oct 28, 2004 12:58:57 PM org.apache.catalina.core.StandardHost getDeployer INFO: Create Host deployer for direct deployment ( non-jmx ) Oct 28, 2004 12:58:57 PM org.apache.catalina.core.StandardHostDeployer install INFO: Processing Context configuration file URL file:C:\tomcat\jakarta-tomcat-5. 0.28\conf\Catalina\localhost\admin.xml Oct 28, 2004 12:58:59 PM org.apache.struts.util.PropertyMessageResources init INFO: Initializing, config='org.apache.struts.util.LocalStrings', returnNull=tru e Oct 28, 2004 12:58:59 PM org.apache.struts.util.PropertyMessageResources init INFO: Initializing, config='org.apache.struts.action.ActionResources', returnNul l=true Oct 28, 2004 12:58:59 PM org.apache.struts.util.PropertyMessageResources init INFO: Initializing, config='org.apache.webapp.admin.ApplicationResources', retur nNull=true Oct 28, 2004 12:59:02 PM org.apache.catalina.core.StandardHostDeployer install INFO: Processing Context configuration file URL file:C:\tomcat\jakarta-tomcat-5. 0.28\conf\Catalina\localhost\balancer.xml Oct 28, 2004 12:59:02 PM org.apache.catalina.core.StandardHostDeployer install INFO: Processing Context configuration file URL file:C:\tomcat\jakarta-tomcat-5. 0.28\conf\Catalina\localhost\manager.xml Oct 28, 2004 12:59:02 PM org.apache.catalina.core.StandardHostDeployer install INFO: Installing web application at context path /jsp-examples from URL file:C:\ tomcat\jakarta-tomcat-5.0.28\webapps\jsp-examples Oct 28, 2004 12:59:03 PM org.apache.catalina.core.StandardHostDeployer install INFO: Installing web application at context path /Login from URL file:C:\tomcat\ jakarta-tomcat-5.0.28\webapps\Login Oct 28, 2004 12:59:04 PM org.apache.struts.util.PropertyMessageResources init INFO: Initializing, config='org.apache.struts.util.LocalStrings', returnNull=tru e Oct 28, 2004 12:59:04 PM org.apache.struts.util.PropertyMessageResources init INFO: Initializing, config='org.apache.struts.action.ActionResources', returnNul l=true Oct 28, 2004 12:59:04 PM org.apache.struts.util.PropertyMessageResources init INFO: Initializing, config='ApplicationResources', returnNull=true Oct 28, 2004 12:59:04 PM org.apache.catalina.core.StandardHostDeployer install INFO: Installing web application at context path from URL file:C:\tomcat\jakart a-tomcat-5.0.28\webapps\ROOT Oct 28, 2004 12:59:04 PM org.apache.catalina.core.StandardHostDeployer install INFO: Installing web application at context path /servlets-examples from URL fil e:C:\tomcat\jakarta-tomcat-5.0.28\webapps\servlets-examples Oct 28, 2004 12:59:05 PM org.apache.catalina.core.StandardHostDeployer install INFO: Installing web application
RE: newbie question
Some more thooughts that came to mind after hitting send: You might find it easier to use server-minimal.xml if you are using TC 5.0.28 standalone. It's much smaller and easier to follow if you are just getting started. Restart the server after you have replaced the file. Re your changed TC 5.0.28 config below, two minor points: (a) you have not edited 8080 to 80 in the comment line. Of course this has no functional impact, but might cause to to mis-read the config file later. It's a good habit to always review and edit the comments associated with your code when you edit the code itself. (b) you have left the redirectPort as 8443 in both cases. Again, this won't affect you at first, and might even be what you want, but if it's not what you want, it might catch you our later if you don't change it now. -Original Message- From: Steve Kirk [mailto:[EMAIL PROTECTED] Sent: Thursday 28 October 2004 20:27 To: 'Tomcat Users List' Subject: RE: newbie question I would advise that you read the doc, because it only takes a few mins, and then you'll understand what's really happening ;) But to get you going, assuming that you have not changed the standard server.xml significantly: 1. Change any active connector ports. The one you mention below is the first, but you need to change any others that are active, that are the same in both servers. 2. Locate the server tag (at the top of the file) and change its shutdown port (it can't be the same for both, otherwise both servers try to run a shutdown listener service on the same port) e.g. Server port=8005 shutdown=SHUTDOWN debug=0 These are the main things. If you have customised server.xml at all you might want to be sure there are no others by searching for port in server.xml in your text editor, and this will highlight all the possible places where port numbers might need to be changed. Note that any parts of server.xml commented out between !-- and -- are not active so you can ignore them for the time being. -Original Message- From: Luke FERNANDEZ [mailto:[EMAIL PROTECTED] Sent: Thursday 28 October 2004 20:19 To: [EMAIL PROTECTED] Subject: RE: newbie question So its more complicated than configuring server.xml for first instance (e.g. Sakai) as: !-- Define a non-SSL Coyote HTTP/1.1 Connector on port 8080 -- Connector port=8080 maxThreads=150 minSpareThreads=25 maxSpareThreads=75 enableLookups=false redirectPort=8443 acceptCount=100 debug=0 connectionTimeout=2 disableUploadTimeout=true / And the second server.xml for the second tomcat instance to be (notice 8080 is now 80): !-- Define a non-SSL Coyote HTTP/1.1 Connector on port 8080 -- Connector port=80 maxThreads=150 minSpareThreads=25 maxSpareThreads=75 enableLookups=false redirectPort=8443 acceptCount=100 debug=0 connectionTimeout=2 disableUploadTimeout=true / I need to go read the doc? Luke [EMAIL PROTECTED] 10/28/2004 1:08:28 PM you can have them run at the same time but you need to configure them to run on separate ports. for your standard TC 5.0.28 the file to edit is CATALINA_HOME/conf/server.xml - see the docs at http://jakarta.apache.org/tomcat/tomcat-5.0-doc/config/index.html for an explanation of how server.xml works (click links in the left margin to access further pages) -Original Message- From: Filip Hanik (lists) [mailto:[EMAIL PROTECTED] Sent: Thursday 28 October 2004 19:29 To: Tomcat Users List Subject: RE: newbie question you have conflict in ports, both tomcats can not run on the same port at the same time. instead of calling start.bat, call catalina.bat run to have the windows stay the same and not shutdown on you FIlip -Original Message- From: Luke FERNANDEZ [mailto:[EMAIL PROTECTED] Sent: Thursday, October 28, 2004 1:27 PM To: [EMAIL PROTECTED] Subject: RE: newbie question Can you run multiple instances of Tomcat? I tried this but I ran into problems. I'm running Sakai (the open source Learning Management System) which installs its own Tomcat engine. When I try to start up my own non-Sakai Tomcat instance from the command line (which resides in a completely separate jakarta-tomcat-5.0.28 folder) a new DOS window pops up and it seems like it goes through the entire deployment in the conventional manner. But instead of staying open, that second DOS window eventually closes. And then when I try to request pages against the second Tomcat instance I don't get anything back in the browser. The Sakai instance still serves pages correctly. However, if the Sakai Tomcat server is turned off I can turn on
RE: Upload MS DOC or Image file errors.
Thanks. It works. -Original Message- From: Steffen Heil [mailto:[EMAIL PROTECTED] Sent: Thursday, October 28, 2004 10:49 AM To: 'Tomcat Users List' Subject: AW: Upload MS DOC or Image file errors. Hi Hi, I am use the File Upload. I need to read the whole file contents in a String buffer. Why into a String buffer? This is propably a charset encoding problem. Do NOT read it into a stringbuffer. See FileWriter documentation: FileWriter is meant for writing streams of characters. For writing streams of raw bytes, consider using a FileOutputStream. So change your method: . int nSize=0; // now !item.isFormField() java.io.InputStream fstrm = item.getInputStream(); int rnum=0; buf = new byte[262144]; // the doc file size I am testing is 13 buyes. while (rnum=0){ // I have to read all the contents rnum = fstrm.read(buf, (int)nSize, 100); if (rnum 0) nSize += rnum; } fstrm.close(); if ( nSize0) { // I like to test if it read correctly: FileOutputStream fileOut = new FileOutputStream(C:/DocAttachment/strFileName.doc); fileOut.write(buf, 0, nSize); fileOut.flush(); fileOut.close(); .. } Beside that: You know that you could simply do: item.write( new File( C:/DocAttachment/strFileName.doc ) ); Regards, Steffen - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: JNDI DataSource GlobalResources problem
I think that JNI is the only counter-example. Forgive me if the following is well know but seen as unimportant to all concerned. There is a JVM restriction: any given class with native members can only be loaded into one classloader of a JVM. So, if two webapps both try to include a native class, the second fails. If you load a webapp with a native class, and then reload it later during development, you are likely (at least, you used to be very likely) to fail and have to restart tomcat. I confess I haven't tried this lately. So, if you have a class library with native classes, and you want to use it in more than one webapp, you are, as far as I know, stuck with the common directory. Using JNDI to coordinate the use of this sort of thing just seemed to me to be an example of using the materials at hand. If tomcat wanted to take the design approach that 'we're not a J2EE container, we don't have any support for shared resources, go find a big fat J2EE container if you want that', you'd get no squeaking from me, whatever difference that makes. I am, however, stuck with the practical problem of JNI, and more than willing to lend a hand to an alternative scheme. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: newbie question
On Thu, 2004-10-28 at 15:34, Luke FERNANDEZ wrote: Am I spamming if I say thanks to all of you for your help? No, there is nothing wrong with a thank you. I changed the following line in server.xml and now both instances run: !-- Server port=8005 shutdown=SHUTDOWN debug=0 -- Server port=8007 shutdown=SHUTDOWN debug=0 I hope I wasn't imposing by asking all these naive questions.for me this is a great way to learn. It's a great way to get out of a bind. Out of courtesy to everyone else though, it's good to exhaust all other avenues before posting to the list. These include, the Tomcat docs, Google, and the archives to this list. You may have noticed this link on your way to signing up for the list: http://www.catb.org/~esr/faqs/smart-questions.html There are a handful of questions that get asked here every single day, bloating the list with endless repetition. They are all answered in the FAQ so they often get ignored. Like you said, I actually have to read the message (although I didn't know that create[8005] was referring to a port). I wonder if there's a way to filter out some of all the stuff that is outputted on startup so one can zero in more easily on the error? Before you go too far down the road, you might want to look at log4j. http://logging.apache.org/log4j It's easy to set up and use, and it can be tuned to throttle the amount of logging you see without having to change your soure. There are others out there too but this IMHO is the best. But those are standard quibbles about cryptic error messages.thanks again for your help. Luke Good luck with your project, -Ben [EMAIL PROTECTED] 10/28/2004 1:09:55 PM yes, and if you actually read the message StandardServer.await: create[8005]: java.net.BindException: Address already in u se: JVM_Bind java.net.BindException: Address already in use: JVM_Bind look for 8005 in your server.xml and you will find out that this is the shutdown port. Filip -Original Message- From: Luke FERNANDEZ [mailto:[EMAIL PROTECTED] Sent: Thursday, October 28, 2004 2:10 PM To: [EMAIL PROTECTED] Subject: RE: newbie question Ok. When I use catalina.bat run instead of startup the window stays open but the second instance (on port 80) still isnt serving pages. I've included the screen output that happens after running catalina.bat run. Looks like its saying something about address already in use: C:\tomcat\jakarta-tomcat-5.0.28\bincatalina.bat run Using CATALINA_BASE: C:\tomcat\jakarta-tomcat-5.0.28 Using CATALINA_HOME: C:\tomcat\jakarta-tomcat-5.0.28 Using CATALINA_TMPDIR: C:\tomcat\jakarta-tomcat-5.0.28\temp Using JAVA_HOME: C:\j2sdk1.4.2_05 Oct 28, 2004 12:58:57 PM org.apache.coyote.http11.Http11Protocol init INFO: Initializing Coyote HTTP/1.1 on http-80 Oct 28, 2004 12:58:57 PM org.apache.catalina.startup.Catalina load INFO: Initialization processed in 1953 ms Oct 28, 2004 12:58:57 PM org.apache.catalina.core.StandardService start INFO: Starting service Catalina Oct 28, 2004 12:58:57 PM org.apache.catalina.core.StandardEngine start INFO: Starting Servlet Engine: Apache Tomcat/5.0.28 Oct 28, 2004 12:58:57 PM org.apache.catalina.core.StandardHost start INFO: XML validation disabled Oct 28, 2004 12:58:57 PM org.apache.catalina.core.StandardHost getDeployer INFO: Create Host deployer for direct deployment ( non-jmx ) Oct 28, 2004 12:58:57 PM org.apache.catalina.core.StandardHostDeployer install INFO: Processing Context configuration file URL file:C:\tomcat\jakarta-tomcat-5. 0.28\conf\Catalina\localhost\admin.xml Oct 28, 2004 12:58:59 PM org.apache.struts.util.PropertyMessageResources init INFO: Initializing, config='org.apache.struts.util.LocalStrings', returnNull=tru e Oct 28, 2004 12:58:59 PM org.apache.struts.util.PropertyMessageResources init INFO: Initializing, config='org.apache.struts.action.ActionResources', returnNul l=true Oct 28, 2004 12:58:59 PM org.apache.struts.util.PropertyMessageResources init INFO: Initializing, config='org.apache.webapp.admin.ApplicationResources', retur nNull=true Oct 28, 2004 12:59:02 PM org.apache.catalina.core.StandardHostDeployer install INFO: Processing Context configuration file URL file:C:\tomcat\jakarta-tomcat-5. 0.28\conf\Catalina\localhost\balancer.xml Oct 28, 2004 12:59:02 PM org.apache.catalina.core.StandardHostDeployer install INFO: Processing Context configuration file URL file:C:\tomcat\jakarta-tomcat-5. 0.28\conf\Catalina\localhost\manager.xml Oct 28, 2004 12:59:02 PM org.apache.catalina.core.StandardHostDeployer install INFO: Installing web application at context path /jsp-examples from URL file:C:\ tomcat\jakarta-tomcat-5.0.28\webapps\jsp-examples Oct 28, 2004 12:59:03 PM org.apache.catalina.core.StandardHostDeployer install INFO: Installing web application at context path /Login from URL file:C:\tomcat\ jakarta-tomcat-5.0.28\webapps\Login
Tomcat 4.1.18: jsessionid in URL on first access, but not subsequent access
Hi all, Using Tomcat 4.1.18, I am getting (what I believe) is inconsistent behaviour with respect to session handling. Hopefully someone here can clear this up for me. Running Tomcat Standalone on my local machine, if I go into my browser, and go to http://mattm:8080/myapp/index.jsp, it uses a Struts redirect I have set up to take me to the welcome page for my app, except it appends the jsessionid on it (so I end up going to http://mattm:8080/myapp/Welcome.do;jsessionid=**) Now, If I immediately go back to the URL and enter in the exact same URL again (without closing the browser) (i.e. go back and put in http://mattm:8080/myapp/index.jsp), once again I am forwarded to the welcome page for my app, but it does NOT contain the jsessionid, which I assume means that it's storing the session in a cookie. Subsequently, if I keep accessing the site, the jsessionid is never appended to the URL again. (Until i close the browser, of course -- which I realize should reset the session id) In my context, I do have cookies=true, and I do not have cookies disabled in my browser (as far as I know). Is there a reason why the first access includes the jsessionid and does not appear to use browser cookies? Is it because Tomcat doesn't know if my browser supports cookies yet? Is there a way to force the page to load with cookies immediately? (By following another redirect or something). I don't want to disable support for cookie-disabled browsers -- I just want to see if I can support cookie-enabled browsers better by not appended the jsessionid in every URL. (The reason I want to get rid of the jsessionid if possible is because the 'Welcome' page (not index.jsp, but the page it forwards to) is a Logon page, and if the user bookmarks that page with the jsessionid in it, IE won't remember their username and password for the future -- minor annoyance, but it'd be great if it could be fixed.) Thanks for your help, Matt Mejaski
RE: Upload MS DOC or Image file errors.
This is much more than a character encoding problem. Extracting text from a Microsoft Word file is a very complex process. Microsoft provides 'IFilter' support for this purpose. Various vendors sell more portable solutions. I don't know of a full open-source solution. You can tell the user to save as .txt and then upload that, and THEN you merely have a character encoding problem. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: File upload
Just in case someone else runs into this, the tomcat workDir and the struts-config tempDir property values MUST match. Otherwise, files greater than the threshold size (default 256K) won't be found for parsing. -Original Message- From: Derrick Koes [mailto:[EMAIL PROTECTED] Sent: Thursday, October 28, 2004 11:52 AM To: Tomcat Users List Subject: File upload Configuration: Tomcat 5.0.24 IIS 5.0 JK2 connector Isapi_redirector2.dll Struts 1.1 Commons file upload 1.0 I seem to have an issue that when the file is a certain size it is written to a temp file on the file system before it is parsed by the multipart parser (at least that's what the exception message leads me to believe). However, since the working directory is my web app (/WEB-INF/ilt), the parser can't seem to find the file (not a fully qualified file name). This is a guess, but if correct I don't know how to fix the problem. Any help is appreciated. Belows is the stack trace and data from the request dumper valve: 2004-10-28 10:59:32 RequestDumperValve[/ilt]: === 2004-10-28 10:59:43 RequestDumperValve[/ilt]: REQUEST URI =/ilt/ilt/iltPerformUpload.do 2004-10-28 10:59:43 RequestDumperValve[/ilt]: authType=null 2004-10-28 10:59:43 RequestDumperValve[/ilt]: characterEncoding=null 2004-10-28 10:59:43 RequestDumperValve[/ilt]: contentLength=340147 2004-10-28 10:59:43 RequestDumperValve[/ilt]: contentType=multipart/form-data; boundary=---41184676334 2004-10-28 10:59:43 RequestDumperValve[/ilt]:contextPath=/ilt 2004-10-28 10:59:43 RequestDumperValve[/ilt]: cookie=com.skillsoft.mgs.sso.RedirectorServlet.ReturnToSkillPort=http:// dkoesxp/djk/home/index.cfm?selectdTab=0 2004-10-28 10:59:43 RequestDumperValve[/ilt]: cookie=CFMX_JSESSIONID=c8301990451098975559821 2004-10-28 10:59:43 RequestDumperValve[/ilt]: cookie=CFID=19459 2004-10-28 10:59:43 RequestDumperValve[/ilt]: cookie=CFTOKEN=98634115 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=accept=text/xml,application/xml,application/xhtml+xml,text/html;q =0.9,text/plain;q=0.8,image/png,*/*;q=0.5 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=accept-language=en-us,en;q=0.5 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=connection=keep-alive 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=host=dkoesxp 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=referer=http://dkoesxp/ilt/ilt/iltUpload.do;jsessionid=3048D443AD 4341273FB5FED42958E7C4 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=user-agent=Mozilla/5.0 (Windows; U; Windows NT 5.1; rv:1.7.3) Gecko/20041001 Firefox/0.10.1 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=cookie=com.skillsoft.mgs.sso.RedirectorServlet.ReturnToSkillPort= http://dkoesxp/djk/home/index.cfm?selectdTab=0; CFMX_JSESSIONID=c8301990451098975559821; CFID=19459; CFTOKEN=98634115 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=content-length=340147 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=content-type=multipart/form-data; boundary=---41184676334 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=accept-encoding=gzip,deflate 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=accept-charset=ISO-8859-1,utf-8;q=0.7,*;q=0.7 2004-10-28 10:59:43 RequestDumperValve[/ilt]: header=keep-alive=300 2004-10-28 10:59:43 RequestDumperValve[/ilt]: locale=en_US 2004-10-28 10:59:43 RequestDumperValve[/ilt]: method=POST 2004-10-28 10:59:43 RequestDumperValve[/ilt]: pathInfo=null 2004-10-28 10:59:43 RequestDumperValve[/ilt]: protocol=HTTP/1.1 2004-10-28 10:59:43 RequestDumperValve[/ilt]:queryString=null 2004-10-28 10:59:43 RequestDumperValve[/ilt]: remoteAddr=10.20.3.42 2004-10-28 10:59:43 RequestDumperValve[/ilt]: remoteHost=10.20.3.42 2004-10-28 10:59:43 RequestDumperValve[/ilt]: remoteUser=null 2004-10-28 10:59:43 RequestDumperValve[/ilt]: requestedSessionId=3048D443AD4341273FB5FED42958E7C4 2004-10-28 10:59:43 RequestDumperValve[/ilt]: scheme=http 2004-10-28 10:59:43 RequestDumperValve[/ilt]: serverName=dkoesxp 2004-10-28 10:59:43 RequestDumperValve[/ilt]: serverPort=80 2004-10-28 10:59:43 RequestDumperValve[/ilt]: servletPath=/ilt/iltPerformUpload.do 2004-10-28 10:59:43 RequestDumperValve[/ilt]: isSecure=false 2004-10-28 10:59:43 RequestDumperValve[/ilt]: --- 2004-10-28 10:59:43 StandardWrapperValve[action]: Servlet.service() for servlet action threw exception org.apache.commons.fileupload.FileUploadException: Processing of multipart/form-data request failed. \WEB-INF\ilt\temp\upload_0001.tmp (The system cannot find the path specified) at org.apache.commons.fileupload.FileUploadBase.parseRequest(FileUploadBase .java:429) at org.apache.struts.upload.CommonsMultipartRequestHandler.handleRequest(Co
auto reload?
Sorry I am drawing a blank at the end of the day. IS this what I enable to have a development environment reload classes automatically? And where do I enable this? _ Powerful Parental Controls Let your child discover the best the Internet has to offer. http://join.msn.com/?pgmarket=en-capage=byoa/premxAPID=1994DI=1034SU=http://hotmail.com/encaHL=Market_MSNIS_Taglines Start enjoying all the benefits of MSN® Premium right now and get the first two months FREE*. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: auto reload?
Hi, Add reloadable=true to your Context declaration in server.xml (or wherever you declare your context). When drawing a blank, I usually find the docs useful. Yoav Shapira http://www.yoavshapira.com -Original Message- From: Didier McGillis [mailto:[EMAIL PROTECTED] Sent: Thursday, October 28, 2004 4:24 PM To: [EMAIL PROTECTED] Subject: auto reload? Sorry I am drawing a blank at the end of the day. IS this what I enable to have a development environment reload classes automatically? And where do I enable this? _ Powerful Parental Controls Let your child discover the best the Internet has to offer. http://join.msn.com/?pgmarket=en- capage=byoa/premxAPID=1994DI=1034SU=http://hotmail.com/encaHL=Mark et_M SNIS_Taglines Start enjoying all the benefits of MSN(r) Premium right now and get the first two months FREE*. - 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: auto reload?
I think you might mean this? Context docBase=... myapp location ... path=/myapp reloadable=true You can put this line in server.xml (within the standard Host tag) or in context.xml For more details on Context and the reloadable attribute, see (for version 5.0.x): http://jakarta.apache.org/tomcat/tomcat-5.0-doc/config/context.html -Original Message- From: Didier McGillis [mailto:[EMAIL PROTECTED] Sent: Thursday 28 October 2004 21:24 To: [EMAIL PROTECTED] Subject: auto reload? Sorry I am drawing a blank at the end of the day. IS this what I enable to have a development environment reload classes automatically? And where do I enable this? _ Powerful Parental Controls Let your child discover the best the Internet has to offer. http://join.msn.com/?pgmarket=en-capage=byoa/premxAPID=1994; DI=1034SU=http://hotmail.com/encaHL=Market_MSNIS_Taglines Start enjoying all the benefits of MSNR Premium right now and get the first two months FREE*. - 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: auto reload?
Thanks From: Steve Kirk [EMAIL PROTECTED] Reply-To: Tomcat Users List [EMAIL PROTECTED] To: 'Tomcat Users List' [EMAIL PROTECTED] Subject: RE: auto reload? Date: Thu, 28 Oct 2004 21:30:33 +0100 I think you might mean this? Context docBase=... myapp location ... path=/myapp reloadable=true You can put this line in server.xml (within the standard Host tag) or in context.xml For more details on Context and the reloadable attribute, see (for version 5.0.x): http://jakarta.apache.org/tomcat/tomcat-5.0-doc/config/context.html -Original Message- From: Didier McGillis [mailto:[EMAIL PROTECTED] Sent: Thursday 28 October 2004 21:24 To: [EMAIL PROTECTED] Subject: auto reload? Sorry I am drawing a blank at the end of the day. IS this what I enable to have a development environment reload classes automatically? And where do I enable this? _ Powerful Parental Controls Let your child discover the best the Internet has to offer. http://join.msn.com/?pgmarket=en-capage=byoa/premxAPID=1994; DI=1034SU=http://hotmail.com/encaHL=Market_MSNIS_Taglines Start enjoying all the benefits of MSNR Premium right now and get the first two months FREE*. - 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] _ Designer Mail isn't just fun to send, it's fun to receive. Use special stationery, fonts and colors. http://join.msn.com/?pgmarket=en-capage=byoa/premxAPID=1994DI=1034SU=http://hotmail.com/encaHL=Market_MSNIS_Taglines Start enjoying all the benefits of MSN® Premium right now and get the first two months FREE*. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: auto reload?
I looked for a bit and couldnt find what I thought it was, didnt notice reloadable :(, searched the archives, which btw we referencing the wrong archived files. Anyway this was my last resort after Google had jack ... how about those Red Sox From: Shapira, Yoav [EMAIL PROTECTED] Reply-To: Tomcat Users List [EMAIL PROTECTED] To: Tomcat Users List [EMAIL PROTECTED] Subject: RE: auto reload? Date: Thu, 28 Oct 2004 16:26:17 -0400 Hi, Add reloadable=true to your Context declaration in server.xml (or wherever you declare your context). When drawing a blank, I usually find the docs useful. Yoav Shapira http://www.yoavshapira.com -Original Message- From: Didier McGillis [mailto:[EMAIL PROTECTED] Sent: Thursday, October 28, 2004 4:24 PM To: [EMAIL PROTECTED] Subject: auto reload? Sorry I am drawing a blank at the end of the day. IS this what I enable to have a development environment reload classes automatically? And where do I enable this? _ Powerful Parental Controls Let your child discover the best the Internet has to offer. http://join.msn.com/?pgmarket=en- capage=byoa/premxAPID=1994DI=1034SU=http://hotmail.com/encaHL=Mark et_M SNIS_Taglines Start enjoying all the benefits of MSN(r) Premium right now and get the first two months FREE*. - 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] _ Don't just Search. Find! http://search.sympatico.msn.ca/default.aspx The new MSN Search! Check it out! - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: auto reload?
Hi, searched the archives, which btw we referencing the wrong archived files. Can you elaborate on this one please? ;) Anyway this was my last resort after Google had jack ... how about those Red Sox Go Sox ;) I probably shouldn't be committing stuff to CVS today given the amount of drinking and partying over the past 24 hours... 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: JNDI DataSource GlobalResources problem
Benson, I read your post on classloading JNI classloading with interest. Certainly wasn't well-known to me. Only one question: counter-example to what? i.e. is there a configuration approach on this thread that makes JNI classloading not work for multiple webapps? at a guess are you talking about putting the DBCP jars in WEB-INF/lib? if so, wouldn't putting them in shared/lib instead solve it? -Original Message- From: Benson Margulies [mailto:[EMAIL PROTECTED] Sent: Thursday 28 October 2004 20:47 To: Tomcat Users List Subject: RE: JNDI DataSource GlobalResources problem I think that JNI is the only counter-example. Forgive me if the following is well know but seen as unimportant to all concerned. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: JNDI DataSource GlobalResources problem
Cancel that - I RTFM'd : each webapp has own classloader. but I'm not sure now what point you're making re the thread? You've piqued my interest on this, I'd be interested if you could clarify please. -Original Message- From: Steve Kirk [mailto:[EMAIL PROTECTED] Sent: Thursday 28 October 2004 21:49 To: 'Tomcat Users List' Subject: RE: JNDI DataSource GlobalResources problem Benson, I read your post on classloading JNI classloading with interest. Certainly wasn't well-known to me. Only one question: counter-example to what? i.e. is there a configuration approach on this thread that makes JNI classloading not work for multiple webapps? at a guess are you talking about putting the DBCP jars in WEB-INF/lib? if so, wouldn't putting them in shared/lib instead solve it? -Original Message- From: Benson Margulies [mailto:[EMAIL PROTECTED] Sent: Thursday 28 October 2004 20:47 To: Tomcat Users List Subject: RE: JNDI DataSource GlobalResources problem I think that JNI is the only counter-example. Forgive me if the following is well know but seen as unimportant to all concerned. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: JNDI DataSource GlobalResources problem
I'm reading this thread as the following meta-discussion. I may be confused. Steve and others: Help us, we've having trouble making global resources work due to poor documentation and problems deciding what to put in the 'common' classpath and what to put in the webapp class path. Yoav and others: Well, OK, here's some help, but why do you want to use global resources anyway? Steve: Wait a minute, now I see, I don't really need any global resources, I can let each webapp get its own database connection, and configure the whole business in the Context element. Benson: That's all well and good for those of you who were using global resources to pool DB connections. However, us poor suckers who use JNI are forced into global resources for other reasons. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: JNDI DataSource GlobalResources problem
Whoops, I missed a point: 'counter-example' to the general idea that anything you can do as a global resource you can do just as well as a per-web-app resource. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: JNDI DataSource GlobalResources problem
There is a section in the release notes on JNI classes that are shared by multiple apps. I assume this is what he's talking about. What it boils down to is that you can't put multiple copies of the same library in each of the webapps, you have to put them in either common/lib or shared/lib. This is a headach for us. On Thu, 2004-10-28 at 17:06, Steve Kirk wrote: Cancel that - I RTFM'd : each webapp has own classloader. but I'm not sure now what point you're making re the thread? You've piqued my interest on this, I'd be interested if you could clarify please. -Original Message- From: Steve Kirk [mailto:[EMAIL PROTECTED] Sent: Thursday 28 October 2004 21:49 To: 'Tomcat Users List' Subject: RE: JNDI DataSource GlobalResources problem Benson, I read your post on classloading JNI classloading with interest. Certainly wasn't well-known to me. Only one question: counter-example to what? i.e. is there a configuration approach on this thread that makes JNI classloading not work for multiple webapps? at a guess are you talking about putting the DBCP jars in WEB-INF/lib? if so, wouldn't putting them in shared/lib instead solve it? -Original Message- From: Benson Margulies [mailto:[EMAIL PROTECTED] Sent: Thursday 28 October 2004 20:47 To: Tomcat Users List Subject: RE: JNDI DataSource GlobalResources problem I think that JNI is the only counter-example. Forgive me if the following is well know but seen as unimportant to all concerned. - 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: JNDI DataSource GlobalResources problem
OK and I've just read the classloading how-to. so if I'm understanding correctly, although each webapp has its own classloader, when a webapp loads a class that's stored in common/ , the class is always loaded by the common classloader, rather than the webapp's own classloader? and even when TC itself wants to load that class, the same classloader is used? and presumably similar principle for shared/ , except that TC itself will not load classes via the shared classloaders, only webapps will? -Original Message- From: Ben Souther [mailto:[EMAIL PROTECTED] Sent: Thursday 28 October 2004 22:13 To: Tomcat Users List Subject: RE: JNDI DataSource GlobalResources problem There is a section in the release notes on JNI classes that are shared by multiple apps. I assume this is what he's talking about. What it boils down to is that you can't put multiple copies of the same library in each of the webapps, you have to put them in either common/lib or shared/lib. This is a headach for us. On Thu, 2004-10-28 at 17:06, Steve Kirk wrote: Cancel that - I RTFM'd : each webapp has own classloader. but I'm not sure now what point you're making re the thread? You've piqued my interest on this, I'd be interested if you could clarify please. -Original Message- From: Steve Kirk [mailto:[EMAIL PROTECTED] Sent: Thursday 28 October 2004 21:49 To: 'Tomcat Users List' Subject: RE: JNDI DataSource GlobalResources problem Benson, I read your post on classloading JNI classloading with interest. Certainly wasn't well-known to me. Only one question: counter-example to what? i.e. is there a configuration approach on this thread that makes JNI classloading not work for multiple webapps? at a guess are you talking about putting the DBCP jars in WEB-INF/lib? if so, wouldn't putting them in shared/lib instead solve it? -Original Message- From: Benson Margulies [mailto:[EMAIL PROTECTED] Sent: Thursday 28 October 2004 20:47 To: Tomcat Users List Subject: RE: JNDI DataSource GlobalResources problem I think that JNI is the only counter-example. Forgive me if the following is well know but seen as unimportant to all concerned. - 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]
Embedded Tomcat NullPointer Exception
Hi, I am trying to run Tomcat(5.0.28) as embedded application and I am getting following exception. Oct 28, 2004 5:16:33 PM org.apache.catalina.startup.Embedded start INFO: Starting tomcat server Oct 28, 2004 5:16:33 PM org.apache.catalina.core.StandardEngine start INFO: Starting Servlet Engine: Apache Tomcat/5.0.28 Oct 28, 2004 5:16:34 PM org.apache.catalina.core.StandardHost start INFO: XML validation disabled java.lang.NullPointerException at org.apache.catalina.startup.DigesterFactory.register(DigesterFactory.j ava:174) at org.apache.catalina.startup.DigesterFactory.registerLocalSchema(Digest erFactory.java:139) at org.apache.catalina.startup.DigesterFactory.newDigester(DigesterFactor y.java:92) at org.apache.catalina.startup.ContextConfig.createWebXmlDigester(Context Config.java:435) at org.apache.catalina.startup.ContextConfig.createWebDigester(ContextCon fig.java:422) at org.apache.catalina.startup.ContextConfig.defaultConfig(ContextConfig. java:499) at org.apache.catalina.startup.ContextConfig.start(ContextConfig.java:623 ) at org.apache.catalina.startup.ContextConfig.lifecycleEvent(ContextConfig .java:216) at org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(Lifecycle Support.java:119) at org.apache.catalina.core.StandardContext.start(StandardContext.java:42 90) at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1083) at org.apache.catalina.core.StandardHost.start(StandardHost.java:789) at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1083) at org.apache.catalina.core.StandardEngine.start(StandardEngine.java:478) at org.apache.catalina.startup.Embedded.start(Embedded.java:846) at com.tellabs.metrowatch.server.startup.EmbeddedTomcat.startTomcat(Embed dedTomcat.java:96) at com.tellabs.metrowatch.server.startup.EmbeddedTomcat.main(EmbeddedTomc at.java:171) Can somebody help me with this? Thanks Kamal - The information contained in this message may be privileged and confidential and protected from disclosure. If the reader of this message is not the intended recipient, or an employee or agent responsible for delivering this message to the intended recipient, you are hereby notified that any reproduction, dissemination or distribution of this communication is strictly prohibited. If you have received this communication in error, please notify us immediately by replying to the message and deleting it from your computer.Thank you. Tellabs
AW: Upload MS DOC or Image file errors.
Hi This is much more than a character encoding problem. No. Daxin simply wanted to upload binary data (he even mentioned images...). So he didn't want to extract text from word documents. What he did was, he loaded binary data, converted that to a string and finally wrote the string to a file. But java's character encodings changed the binary data on that way, thus the binary files (ms-doc or images) were damaged. Regards, Steffen smime.p7s Description: S/MIME cryptographic signature
AW: Upload MS DOC or Image file errors.
Thanks. It works. Fine. But what? Switching to FileOutputStream or just using item.write? (They should both work, though the second seems to make more sence. Just asking for interest.) Regards, Steffen smime.p7s Description: S/MIME cryptographic signature
RE: JNDI DataSource GlobalResources problem
Benson wrote: I'm reading this thread as the following meta-discussion. I may be confused. It's been a fairly long thread. You've got the jist though, except: I don't use global resources and I'm not for or against either them or per-webapp resources. I joined the thread to help someone else who was having trouble configuring a global resource. My interest is learning about and following standards where I can, although I'm not religious about that either if it gets too difficult ;) I don't think the problem are over whether to put jars under webapps or common (at least, not the problems mentioned on this thread). It's been more about which config file to put the resource config in. I don't think the TC docs are poor, I think they are 99% spot on. It is a confusing area for DBCP/JNDI newbies, because there are several docs, and a few choices to make about which approach to take (plus, in my case, I didn't find the docs at first because I didn't know they were there, and other things came higher on google). I have spotted a few possible small enhancements to the existing docs, which I intend to contribute just as soon as I've worked out how to diff the files on my windows box. My eureka moment was Yoav pointing out that often (but not always) it's not necessary to use container-managed resources, and in fact if you avoid them, you will have a more portable webapp. If only I'd realised that earlier, I wouldn't have got into the whole container-managed resource thing at all. Doh. However, us poor suckers who use JNI are forced into global resources for other reasons. Now I see where you're coming from on JNI, and I agree, it's a good reason to use them. But as I said above, I'm not against global resources anyway, nor is anyone else on this thread as far as I can tell. Except maybe Yoav ;) Whoops, I missed a point: 'counter-example' to the general idea that anything you can do as a global resource you can do just as well as a per-web-app resource. Aha! Thanks for explaining that. I agree - that general idea is probably not true (and likewise vice-versa). I also think there are probably many more counter-examples, including many in the situation where container adminstrators want to configure resources rather than letting a load of webapp programmers loose on DIYing it. In summary then, I think that both global and per-webapp resources have their place; each to his own according to personal taste :) - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Context mapping question
On Thursday 28 October 2004 15:35, Shapira, Yoav wrote: Hi, Context path=/ docBase=app1 debug=9 Changing this one path to path= instead of /. Set autoDeploy/liveDeploy/deployOnStartup to false for both of your Hosts. Because they share an appBase, the apps are being deployed once *per* Host. That cleaned up the multiple contexts and some of the uri cross over. After looking at Http11Processor, I realized that the service connectors did not have an ip address setting. That cleaned up the rest of the cross over. I guess I thought that a reverse lookup would be done on the host names to derive the ip. Thanks Yoav. Bob Tellefson BizDash LLC (310) 499-4868 ext 2 [EMAIL PROTECTED] http://www.BizDash.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Log4j with Tomcat .. (3 questions)
Hi, Am new to log4j. Am using Tomcat 5 and my webapp-myNiceWebApp is in Tomcat/webapps/myNiceWebApp I have a class that I have the following code in: Logger logger = Logger.getLogger(Helper.class); SimpleLayout layout = new SimpleLayout(); FileAppender appender = null; try { appender = new FileAppender(layout,output1.txt,false); } catch(Exception e) { e.printStackTrace(); } logger.addAppender(appender); logger.setLevel((Level)Level.DEBUG); logger.debug(some message); Que 1. Where does the file output1.txt get created? Que 2. How does log4j know where to create it and can it be controlled? Que 3. I am going to use a configuration file either use the DOMConfigurator or PropertyConfigurator to load the log4j properties. Where do i place this file log4j configuration file? Thanks,
Tomcat5.5.3 serious problems!
HI! I tried to use GUI manager to upload war file (war file to deploy, the message says OK, but nothing happened. no context files deployed. nothing. then I tried to upload the same war file using deploy directory or war file located on server, the upload problem entered into an infinitive loop, just kept runnin...runing. What happened! The war file I tried to upload works perfect on Tomcat5.0.29. Thanks David Lee
Re: Log4j with Tomcat .. (3 questions)
Log4j looks on your class path for a properties file log4j.properties. If you put the file in WEB-INF/classes it will find it. Here's a real simple example: log4j.rootCategory=DEBUG, dest1 log4j.appender.dest1=org.apache.log4j.RollingFileAppender log4j.appender.dest1.file=/usr/local/tomcat/logs/myapp.log log4j.appender.dest1.layout=org.apache.log4j.PatternLayout log4j.appender.dest1.layout.ConversionPattern=%-5p: %m%n On Thu, 2004-10-28 at 19:08, Mufaddal Khumri wrote: Hi, Am new to log4j. Am using Tomcat 5 and my webapp-myNiceWebApp is in Tomcat/webapps/myNiceWebApp I have a class that I have the following code in: Logger logger = Logger.getLogger(Helper.class); SimpleLayout layout = new SimpleLayout(); FileAppender appender = null; try { appender = new FileAppender(layout,output1.txt,false); } catch(Exception e) { e.printStackTrace(); } logger.addAppender(appender); logger.setLevel((Level)Level.DEBUG); logger.debug(some message); Que 1. Where does the file output1.txt get created? Que 2. How does log4j know where to create it and can it be controlled? Que 3. I am going to use a configuration file either use the DOMConfigurator or PropertyConfigurator to load the log4j properties. Where do i place this file log4j configuration file? Thanks, - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]