database connection in web.xml
Hi, I want to specify a database connection in the web.xml file for an application. How do I do this? Where can I find docs to describe it, Thanks, kind regards, Luke -- "when my computer smiles, I'm happy" ===.~ ~, Luke Vanderfluit |'/'] Mobile: 0421 276 282\~/` - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: SSL-Tomcat
"Pirti Andrea (SPES)" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > Hello everyone, > i have a problem , with Tomcat 4.1.18 and jvm IBMJava2-141. > I opnend connector https, but during startup processing i have this > exception: > > java.lang.reflect.InvocationTargetException > at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) > at > sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.jav > a:79) > at > sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessor > Impl.java:41) > at java.lang.reflect.Method.invoke(Method.java:371) > at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:203) > Caused by: java.lang.NoClassDefFoundError: sun/security/provider/Sun > at > org.apache.tomcat.util.net.jsse.JSSEImplementation.getServerSocketFactor > y(JSSEImplementation.java:90) > at > org.apache.coyote.http11.Http11Protocol.checkSocketFactory(Http11Protoco > l.java:452) > at org.apache.coyote.http11.Http11Protocol.init(Http11Protocol.java:133) > at > org.apache.coyote.tomcat4.CoyoteConnector.initialize(CoyoteConnector.jav > a:1032) > at > org.apache.catalina.core.StandardService.initialize(StandardService.java > :579) > at > org.apache.catalina.core.StandardServer.initialize(StandardServer.java:2 > 245) > at org.apache.catalina.startup.Catalina.start(Catalina.java:511) > at org.apache.catalina.startup.Catalina.execute(Catalina.java:400) > at org.apache.catalina.startup.Catalina.process(Catalina.java:180) > > How can i resolve this problem? > You have two choices: 1) Install Sun's jsse.jar (and friends) for the 1.3.x JVM. 2) Upgrade to 4.1.24 (or, better, 4.1.28) that properly handles IBM's version of JSSE. > Thanks. > > - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Website Performance Clocking
TomCat Admins: I am having server performnce issues with my site and was wondering if their is a website perfoance tacking software that when given a URL will request all the files referance in that URL like a web browser and track 1) server responce time, and 2) transfer rate for each file. some thing that is command line driven would be best so I can add it to Windows' scheduler. Shawn Zernik Internetwork Consulting www.internetworkconsulting.net - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
SESSION REPLICATION: RedHat 9 and Sun JDK 1.4.2 do not like to play
All, I have an announcement to make since myself and some colleagues found during some serious debugging on why session replication failed miserably on their systems. When running session replication for Tomcat 4.1.24 (http://cvs.apache.org/~fhanik/) on Redhat 9 using Sun JDK 1.4.2 nothing works for me at home during my regression testing. As soon as I switch to IBM JDK 1.4.1 everything goes back to normal. The problem is that with the Sun JDK the Socket.getOutputStream().write() hangs and locks forever. I will add this to the Cluster FAQ for Tomcat 5. If you have any questions Important Note: Although I switched to IBM JDK 1.4.1 I did experience one core dump with the JDK, so at this point, I would not recommend anyone using RedHat 9 when running tomcat and session replication. For those of you who have tried other platforms,versions OS:s, let us know your experience Filip - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Getting a strange exception from Tomcat
http://jakarta.apache.org/tomcat/faq/unix.html#x -Tim Jon Yeargers wrote: Im using a tomcat installation to do a some JPEG manipulation. From most machines it works fine but one customer causes this exception when the image code is hit. Why would different client machines cause problems running the same code with the same data? Im sure its a UFU but I don't have a clue how to debug it. Suggestions? org.apache.jasper.JasperException: Can't connect to X11 window server using ':0.0' as the value of the DISPLAY variable. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: org.apache.jasper.JasperException: Unable to compile class for JSP
See the faq http://jakarta.apache.org/tomcat/faq/classnotfound.html -Tim [EMAIL PROTECTED] wrote: Hi guys! I am getting following error while trying to run a jsp page in Tomcat 4.1 and JDK 1.4. An error occurred at line: -1 in the jsp file: null Generated servlet error: [javac] Compiling 1 source file /usr/local/jakarta-tomcat-4.1.27/work/Standalone/localhost/test/intra_esolve/jsp/userMenu_jsp.java:7: '.' expected import DbConnection; ^ /usr/local/jakarta-tomcat-4.1.27/work/Standalone/localhost/test/intra_esolve/jsp/userMenu_jsp.java:8: '.' expected import Global; ^ Note: /usr/local/jakarta-tomcat-4.1.27/work/Standalone/localhost/test/intra_esolve/jsp/userMenu_jsp.java - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: RequestDispatcher and getServletContext() don't work when using init()
You must call super.init(...) in your init method. -Tim Luke Vanderfluit wrote: Hi, I found that using the init() method to set up a database connection then trying to instantiate a ServletContext object and forward to a jsp page didn't work. If placed the database connection code in the doPost() then it DID, The 2 code sets are attached, can anyone tell me why? thanks, kind regards, Luke - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Getting a strange exception from Tomcat
Im using a tomcat installation to do a some JPEG manipulation. From most machines it works fine but one customer causes this exception when the image code is hit. Why would different client machines cause problems running the same code with the same data? Im sure its a UFU but I don't have a clue how to debug it. Suggestions? org.apache.jasper.JasperException: Can't connect to X11 window server using ':0.0' as the value of the DISPLAY variable. at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:248) at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:295) at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:241) at javax.servlet.http.HttpServlet.service(HttpServlet.java:853) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:247) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:193) at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:260) at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(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.java:191) at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(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.StandardContext.invoke(StandardContext.java:2415) at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:180) at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:643) at org.apache.catalina.valves.ErrorDispatcherValve.invoke(ErrorDispatcherValve.java:170) at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:641) at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:172) at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(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.invokeNext(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.coyote.tomcat4.CoyoteAdapter.service(CoyoteAdapter.java:223) at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:432) at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.processConnection(Http11Protocol.java:386) at org.apache.tomcat.util.net.TcpWorkerThread.runIt(PoolTcpEndpoint.java:534) at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:530) at java.lang.Thread.run(Thread.java:536) - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
org.apache.jasper.JasperException: Unable to compile class for JSP
Hi guys! I am getting following error while trying to run a jsp page in Tomcat 4.1 and JDK 1.4. An error occurred at line: -1 in the jsp file: null Generated servlet error: [javac] Compiling 1 source file /usr/local/jakarta-tomcat-4.1.27/work/Standalone/localhost/test/intra_esolve/jsp/userMenu_jsp.java:7: '.' expected import DbConnection; ^ /usr/local/jakarta-tomcat-4.1.27/work/Standalone/localhost/test/intra_esolve/jsp/userMenu_jsp.java:8: '.' expected import Global; ^ Note: /usr/local/jakarta-tomcat-4.1.27/work/Standalone/localhost/test/intra_esolve/jsp/userMenu_jsp.java uses or overrides a deprecated API. Note: Recompile with -deprecation for details. 2 errors at org.apache.jasper.compiler.DefaultErrorHandler.javacError(DefaultErrorHandler.java:130) at org.apache.jasper.compiler.ErrorDispatcher.javacError(ErrorDispatcher.java:293) at org.apache.jasper.compiler.Compiler.generateClass(Compiler.java:353) at org.apache.jasper.compiler.Compiler.compile(Compiler.java:370) at org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.java:473) .and lots more... This page runs fine with Tomcat 3.2.4 and jdk 1.4. I have to port this page to Tomcat 4.1 with jdk 1.4. Here is a snapshot of jsp page listing: <%@ page language="java" %> <%@ page import = "DbConnection" %> <%@ page import = "Global" %> <%@ page import = "java.lang.*" %> <%@ page import = "java.util.*" %> <%@ page import = "java.sql.*" %> <%@ page import = "javax.servlet.http.HttpSession" %> ... Location of DbConnection.class and Global.class is /test/WEB-INF/classes. Please help me if anybody knows the reason. Thanks, Manu ____ * DISCLAIMER: The information contained in this message is intended only and solely for the addressed individual or entity indicated in this message and for the exclusive use of the said addressed individual or entity indicated in this message (or responsible for delivery of the message to such person) and may contain legally privileged and confidential information belonging to Tata Consultancy Services. It must not be printed, read, copied, disclosed, forwarded, distributed or used (in whatsoever manner) by any person other than the addressee. Unauthorized use, disclosure or copying is strictly prohibited and may constitute unlawful act and can possibly attract legal action, civil and/or criminal. The contents of this message need not necessarily reflect or endorse the views of TATA Consultancy Services on any subject matter. Any action taken or omitted to be taken based on this message is entirely at your risk and neither the originator of this message nor Tata Consultancy Services takes any responsibility or liability towards the same. Opinions, conclusions and any other information contained in this message that do not relate to the official business of Tata Consultancy Services shall be understood as neither given nor endorsed by Tata Consultancy Services or any affiliate of Tata Consultancy Services. If you have received this message in error, you should destroy this message and may please notify the sender by e-mail. Thank you. * . - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: unable to find tld's inside .jar files on 4.1.27 [FIXED]
I wrote: > Why isn't Tomcat finding the tld in the struts.jar file? Apparently because the
MAC OSX and Tomcat -4.0.1
I am having big problems getting tomcat to start. I had been using 3.2.4 before, but this has really got me stumped! Any help is good! - Thanks in advance! Here are some details: Using CLASSPATH: /Users/system/Applications/java/jakarta/jakarta-tomcat-4.0.1/bin/bootstrap.jar Using CATALINA_BASE: /Users/system/Applications/java/jakarta/jakarta-tomcat-4.0.1 Using CATALINA_HOME: /Users/system/Applications/java/jakarta/jakarta-tomcat-4.0.1 Using JAVA_HOME: /System/Library/Frameworks/JavaVM.framework/Versions/1.4.1/Home here is catalina_log Exception during startup processing java.lang.reflect.InvocationTargetException at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:324) at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:243) Caused by: java.lang.NoClassDefFoundError: javax/servlet/ServletResponse at java.lang.ClassLoader.defineClass0(Native Method) at java.lang.ClassLoader.defineClass(ClassLoader.java:502) at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:123) at java.net.URLClassLoader.defineClass(URLClassLoader.java:250) at java.net.URLClassLoader.access$100(URLClassLoader.java:54) at java.net.URLClassLoader$1.run(URLClassLoader.java:193) at java.security.AccessController.doPrivileged(Native Method) at java.net.URLClassLoader.findClass(URLClassLoader.java:186) at java.lang.ClassLoader.loadClass(ClassLoader.java:299) at java.lang.ClassLoader.loadClass(ClassLoader.java:255) at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:315) at java.lang.Class.forName0(Native Method) at java.lang.Class.forName(Class.java:140) at org.apache.catalina.util.xml.ObjectCreate.start(XmlMapper.java:616) at org.apache.catalina.util.xml.XmlMapper.matchStart(XmlMapper.java:412) at org.apache.catalina.util.xml.XmlMapper.startElement(XmlMapper.java:91) at org.xml.sax.helpers.XMLReaderAdapter.startElement(XMLReaderAdapter.java:333) at org.apache.xerces.parsers.SAXParser.startElement(SAXParser.java:1376) at org.apache.xerces.validators.common.XMLValidator.callStartElement(XMLValidator.java:1214) at org.apache.xerces.framework.XMLDocumentScanner.scanElement(XMLDocumentScanner.java:1806) at org.apache.xerces.framework.XMLDocumentScanner$ContentDispatcher.dispatch(XMLDocumentScanner.java:1182) at org.apache.xerces.framework.XMLDocumentScanner.parseSome(XMLDocumentScanner.java:381) at org.apache.xerces.framework.XMLParser.parse(XMLParser.java:1081) at org.xml.sax.helpers.XMLReaderAdapter.parse(XMLReaderAdapter.java:223) at javax.xml.parsers.SAXParser.parse(SAXParser.java:314) at javax.xml.parsers.SAXParser.parse(SAXParser.java:253) at org.apache.catalina.util.xml.XmlMapper.readXml(XmlMapper.java:228) at org.apache.catalina.startup.Catalina.start(Catalina.java:725) at org.apache.catalina.startup.Catalina.execute(Catalina.java:681) at org.apache.catalina.startup.Catalina.process(Catalina.java:179) James Snelling [EMAIL PROTECTED] --- The views expressed here are not those of the Students' Association nor can they be assumed to be those of the writer. No liability is accepted for the accuracy or the veracity of the contents. You are held to accept this and any use to which you put any contents of this communication are entirely your responsibility. DISCLAIMER: This e-mail is intended solely for the above-mentioned recipient and it may contain confidential or privileged information. If you have received it in error, please notify us immediately and delete the e-mail. You must not copy, distribute, disclose or take any action in reliance on it. This e-mail message and any attached files have been scanned for the presence of computer viruses, however, you are advised that you open any attachments at your own risk. Nothing in this email shall be construed as constituting an order for goods or services www.upsa.org.uk - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Advanced Question about tag
I have a complicated menu structure that is dynamically generated per client on login of the webapp. Each client has a different set of folders which don't change often but require a bit of processing to produce - so I decided to create an include file and cache it on the server. I include that cached HTML/Javascript menu structure with the following command: This works great! However, a problem occurs when I need to update one of these cached files because the client added or deleted a folder. Sometimes, the pages that are returned contain the state prior to any change. If I then refresh or go to another page, the folder structure is immediately changed. Sometime this happens, sometimes it works right. It seems like Tomcat is caching the contents of the file that <%= clientSession.menuPath %> is poiting to. I know for a fact that the browser is not caching the page (I've included all the appropriate HTML header tags to stop browser caching, plus there is data on the page that is changing with each page refresh). Also, I am not using any threads, and my updating of the page is happening prior to the including of the page. Has anyone had this problem before? Is ther a way to tell tomcat to always go and get the page every time? Joe Krause
Re: John Turner's Recent HowTo (Apache + Tomcat) [solved]
I figured out my issues - here's how: I had modified /usr/sbin/apachectl so that the HTTPD variable pointed to /usr/local/apache2/bin/httpd rather than /usr/sbin/httpd. I fixed it by removing /usr/bin/apachectl and executing "ln -s /usr/local/apache2/bin/apachectl /usr/sbin/apachectl". Now if I could only get the Apple Rendezvous mod working on 2.0.x. I'm running this on OS X. Matt On 10/14/03 10:03 PM, "Matt Raible" <[EMAIL PROTECTED]> wrote: > I went through John's HowTo on Tomcat and Apache on RH 9 this evening. > > http://johnturner.com/howto/apache2-tomcat4127-jk-rh9-howto.html > > All worked awesome (on OS X) until I rebooted my machine, now I'm > getting the following in Tomcat's log file: > > BAD packet 256 > In: : [EMAIL PROTECTED] 4/843 > 01 00 03 47 00 00 00 00 00 00 00 00 00 00 00 00 | ...G > 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 | > > I can access Tomcat and my apps using http://localhost:8080. > > Thanks, > > Matt > > > - > 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]
Erro in the execution of the program with JDK 1.3.1
Hello Can anybody tell me the one what I should do on that below? Those are the message of forum http://forum.java.sun.com - Java Programming - Java Virtual Machine thanks Erro in the execution of the program with JDK 1.3.1Author: Breno_Perucchi Oct 14, 2003 1:27 AM Hello guysI installed the port JDK 1.3.1 in the system operation Freebsd . But I am having a problem of execution in my Java program. My program try to create bank ticket with bar code but it doesn't get to create the bar code I already researched in the internet the followings error but up to now I didn't have any answer to solve my problem. I need the help. Below this the log of the java Below the are log of the JDK 1.3.1003-10-08 17:50:56 StandardWrapperValve[barbecue]: Servlet.service() for servlet barbecue threw exceptionjavax.servlet.ServletException: Servlet execution threw an exceptionat org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:269)at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:193)- Root Cause -java.lang.InternalError: Can't connect to X11 window server using ':0.0' as the value of the DISPLAY variable.at sun.awt.X11GraphicsEnvironment.initDisplay(Native Method)at sun.awt.X11GraphicsEnvironment.(X11GraphicsEnvironment.java:54)- Root Cause -java.lang.NoClassDefFoundError: sun/awt/motif/MToolkitat java.lang.Class.forName0(Native Method)at java.lang.Class.forName(Class.java:115) Re: Erro in the execution of the program with JDK 1.3.1 Author: andih In Reply To: Erro in the execution of the program with JDK 1.3.1 Oct 14, 2003 2:33 AM Reply 1 of 3 You either have no X server running or not the permissions to connect to the server. The message appears whenever at least one servlet uses direct or indirect SWING ( AWT) classes. The second root may be followup error of the fact that it's not possible to connect to the X server. There occured an error during initialzation of the MToolkit which the Classloder may report as a ClassNotFoundError. Ensure that there exists a X Server and you have the permissions to connect to the X server. Set the DISPLAY environment variable. Re: Erro in the execution of the program with JDK 1.3.1 Author: Breno_Perucchi In Reply To: Re: Erro in the execution of the program with JDK 1.3.1 Oct 14, 2003 11:28 AM Reply 2 of 3 I don't have X11 server installed Do I have to install X11? Even if my program is executed in the Apache webserver ?This error with awt/motif/MToolkit can be originated by mistake above ?Thanks for your help Re: Erro in the execution of the program with JDK 1.3.1 Author: SebastianM In Reply To: Re: Erro in the execution of the program with JDK 1.3.1 Oct 14, 2003 12:39 PM Reply 3 of 3 try passing the following switch with the JRE:-Djava.awt.headless=trueas injava -Djava.awt.headless=true package.MyMainProgram Re: Erro in the execution of the program with JDK 1.3.1 Author: dpz In Reply To: Re: Erro in the execution of the program with JDK 1.3.1 Oct 15, 2003 11:02 AM Reply 4 of 4 If there is an X-server some where nearby, you can point your DISPLAY variable at it. Since I presume you aren't actually displaying anything the humnan sitting at that X-Server wont notice anything. You may need to do an 'xhost +<...>' on t
RE: Tomcat RPM's?
Steve, According to Henri Gomez, the Tomcat Team will no longer be providing full or le RPMs. You can now find 4.1.27 RPMs on www.jpackage.org. I am in the middle of evaluating those and plan on publishing a short how to here when I have managed to install the now many RPMS required. Randy Watler Finali Corporation -Original Message- From: Steve Stearns To: [EMAIL PROTECTED] Sent: 10/15/03 2:44 PM Subject: Tomcat RPM's? I've noticed that there's not been an RPM release of Tomcat since the 4.1.24 release. Is the RPM version of tomcat no longer being provided? If it is still being provided, any expectation as to when we'll see a new RPM version? I looked in the mail archives and saw people asking about it, but the only responses I saw were suggesting people just use the tar version instead. I could do that, but having the RPM version would be easier for my setup and I'd rather continue to use that if it will be available. ---Steve - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
unable to find tld's inside .jar files on 4.1.27
I'm suddenly getting: org.apache.jasper.JasperException: This absolute uri (http://jakarta.apache.org/struts/tags-tiles) cannot be resolved in either web.xml or the jar files deployed with this application Tomcat 4.1.27 and the 10/14 nightly build of Struts. The struts-jar file is in WEB-INF/lib, and it has struts-tiles.tld in META-INF\tlds which has the URI mentioned above. I'm comparing to a working app, and I don't see anything different. I started with the struts-blank webapp, so I've removed the taglib stuff from web.xml and removed the tld files from WEB-INF. Why isn't Tomcat finding the tld in the struts.jar file? I put struts-tiles.tld back in WEB-INF and changed the JSP to: <%@ taglib uri="/WEB-INF/struts-tiles.tld" prefix="tiles" %> And it works. (Well, now it's complaining about the JSTL core taglib...) -- Wendy Smoak Applications Systems Analyst, Sr. Arizona State University, PA, IRM - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RequestDispatcher and getServletContext() don't work when using init()
Hi, I found that using the init() method to set up a database connection then trying to instantiate a ServletContext object and forward to a jsp page didn't work. If placed the database connection code in the doPost() then it DID, The 2 code sets are attached, can anyone tell me why? thanks, kind regards, Luke -- "when my computer smiles, I'm happy" ===.~ ~, Luke Vanderfluit |'/'] Mobile: 0421 276 282\~/` /* A servlet to display the contents Bookmarks database */ import java.io.*; import java.sql.*; import java.text.*; import java.util.*; import javax.servlet.*; import javax.servlet.http.*; public class CodeSet1 extends HttpServlet { Connection dbcon; // Connection public String getServletInfo() { return "Servlet connects to PostgreSQL"; } // "init" sets up a database connection public void init(ServletConfig config) throws ServletException { String loginUser = "luke"; String loginPasswd = ""; String loginUrl = "jdbc:postgresql:bookmarks"; // Load the PostgreSQL driver try { Class.forName("org.postgresql.Driver"); dbcon = DriverManager.getConnection(loginUrl, loginUser, loginPasswd); } catch (ClassNotFoundException ex) { System.err.println("ClassNotFoundException: " + ex.getMessage()); throw new ServletException("Class not found Error"); } catch (SQLException ex) { System.err.println("SQLException: " + ex.getMessage()); } } // end init() // == POST == public void doPost(HttpServletRequest request, HttpServletResponse response) throws IOException, ServletException { String loginUser = "luke"; String loginPasswd = ""; String loginUrl = "jdbc:postgresql:bookmarks"; /*// Load the PostgreSQL driver try { Class.forName("org.postgresql.Driver"); dbcon = DriverManager.getConnection(loginUrl, loginUser, loginPasswd); } catch (ClassNotFoundException ex) { System.err.println("ClassNotFoundException: " + ex.getMessage()); throw new ServletException("Class not found Error"); } catch (SQLException ex) { System.err.println("SQLException: " + ex.getMessage()); } */ String title = request.getParameter("title"); String url = request.getParameter("url"); String descr = request.getParameter("descr"); try { // Declare statement Statement statement = dbcon.createStatement(); String query = "insert into bookmark values('" + title + "', '" + url + "', '" + descr + "')"; // Perform update statement.executeUpdate(query); statement.close(); } catch(Exception ex){} try{ dbcon.close(); } catch(SQLException ignored) {} ServletContext context = getServletContext(); RequestDispatcher rd = context.getRequestDispatcher("/marksMain.jsp"); rd.forward(request, response); } //end doPost } /* A servlet to display the contents Bookmarks database */ import java.io.*; import java.sql.*; import java.text.*; import java.util.*; import javax.servlet.*; import javax.servlet.http.*; public class CodeSet2 extends HttpServlet { Connection dbcon; // Connection public String getServletInfo() { return "Servlet connects to PostgreSQL"; } /* // "init" sets up a database connection public void init(ServletConfig config) throws ServletException { String loginUser = "luke"; String loginPasswd = ""; String loginUrl = "jdbc:postgresql:bookmarks"; // Load the PostgreSQL driver try { Class.forName("org.postgresql.Driver"); dbcon = DriverManager.getConnection(loginUrl, loginUser, loginPasswd); } catch (ClassNotFoundException ex) { System.err.println("ClassNotFoundException: " + ex.getMessage()); throw new ServletException("Class not found Error"); } catch (SQLException ex) { System.err.println("SQLException: " + ex.getMessage()); } } // end init() */// == POST == public void doPost(HttpServletRequest request, HttpServletResponse response) throws IOException, ServletException { String loginUser = "luke"; String loginPasswd = ""; String loginUrl = "jdbc:postgresql:bookmarks"; // Load the PostgreSQL driver try { Class.forName("org.postgresql.Driver"); dbcon = DriverManager.getConnection(loginUrl, loginUser, loginPasswd); } catch (ClassNotFoundException ex) { System.err.println("ClassNotFoundException: " + ex.getMessage()); throw new ServletException("Class not found Error"); } catch (SQLException ex) { System.err.println("SQLException: " + ex.getMessage()); } String title = request.getParameter("title"); String url = request.getParameter("url"); String
Example of a logAbandonded stack trace?
Can someone please post an example of the stack trace produced when abandoned connections are logged? I am seeing stack traces like these in my logs and I'd like to know if they are coming from abandoned connections: 2003-10-08 10:17:25 StandardWrapperValve[admin]: Servlet.service() for servlet admin threw exception javax.servlet.ServletException: Nested error: java.sql.SQLException: Io exception: Socket closed at eschedule.AdminController.dispatchSelectEvent(AdminController.java:1075) at eschedule.AdminController.service(AdminController.java:133) at javax.servlet.http.HttpServlet.service(HttpServlet.java:853) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:247) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:193) at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:256) at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(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.java:191) at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(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.StandardContext.invoke(StandardContext.java:2407) at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:180) at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:643) at org.apache.catalina.valves.ErrorDispatcherValve.invoke(ErrorDispatcherValve.java:171) at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:641) at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:172) at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:641) at org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:509) at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(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.invokeNext(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.ajp.tomcat4.Ajp13Processor.process(Ajp13Processor.java:466) at org.apache.ajp.tomcat4.Ajp13Processor.run(Ajp13Processor.java:585) at java.lang.Thread.run(Thread.java:536) - Root Cause - java.sql.SQLException: Io exception: Socket closed at oracle.jdbc.dbaccess.DBError.throwSqlException(DBError.java:168) at oracle.jdbc.dbaccess.DBError.throwSqlException(DBError.java:210) at oracle.jdbc.dbaccess.DBError.throwSqlException(DBError.java:323) at oracle.jdbc.driver.OracleConnection.setAutoCommit(OracleConnection.java:799) at org.apache.commons.dbcp.DelegatingConnection.setAutoCommit(DelegatingConnection.java:237) at org.exolab.castor.jdo.engine.TransactionContextImpl.getConnection(TransactionContextImpl.java:214) at org.exolab.castor.persist.ClassMolder.load(ClassMolder.java:693) at org.exolab.castor.persist.LockEngine.load(LockEngine.java:359) at org.exolab.castor.persist.TransactionContext.load(TransactionContext.java:649) at org.exolab.castor.persist.TransactionContext.load(TransactionContext.java:555) at org.exolab.castor.persist.ClassMolder.load(ClassMolder.java:796) at org.exolab.castor.persist.LockEngine.load(LockEngine.java:359) at org.exolab.castor.persist.TransactionContext.load(TransactionContext.java:649) at org.exolab.castor.persist.TransactionContext.load(TransactionContext.java:555) at org.exolab.castor.jdo.engine.DatabaseImpl.load(DatabaseImpl.java:302) at org.exolab.castor.jdo.engine.DatabaseImpl.load(DatabaseImpl.java:315) at eschedule.AdminController.dispatchSelectEvent(AdminController.java:1053) at eschedule.AdminController.service(AdminController.java:133) at javax.servlet.http.HttpServlet.service(HttpServlet.java:853) at org.apache.catalina.core.Applica
Re: Internal Server Error
Found my problem... Since I had changed the default virtual host to "microps.com" in.. I also had to edit this line... that seem to fix it... (maybe a note in the server.xml to this effect...) Now I can uncross my eyes from staring at this file for the last hour... John... John B. Moore wrote: Just did a fresh install of 4.1.18 on NT4 Server (replacing a previous version that was working fine, but hey, I love spending hours beating my head against the wall, pulling out what few hairs I still have, so I get to figure this stuff out...) Had followed John Turners install how-to to the letter with one exception.. I replaced the default virtual host "localhost" with "microps.com" (as I had it in the previous install) in server.xml. I was testing the /examples/jsp/num/numguess.jsp and am getting an "Internal Server Error". Nothing is showing in any of the logs. Not a hint... I tested it under the "microps.com:8080" and it works fine.. only when I come through Apache (2.0.43) "www.microps.com" do I get this error.. Obviously a configuration issue.. just need some hints... Does this ring any bells as to where I should be looking...??? Thanks.. John Moore - 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]
Slow HTTP upload speed with IE and Tomcat on Solaris (works fine on Linux and Windows)
I'm having a strange problem with regard to HTTP upload speed when using Internet Explorer on Windows with Tomcat on Solaris. If I upload a 10 MB file over a 100 Mbs Ethernet connection, it takes 2 minutes 25 seconds if I use IE (~80 Kbs). If I use Mozilla, it takes 3 seconds (~3 Mbs). If I try the same thing, but, run Tomcat on Linux instead, it takes 2 seconds when using IE. It takes 1 second if I run Tomcat on my local Windows computer. I'm using Solaris 8 with a patch cluster that I downloaded and installed within the last few weeks, Tomcat 5.0.12, J2SE 1.4.1, and the version of Internet Explorer that comes with Windows XP with all the Windows updates applied. The problem seems to occur with Tomcat 4.1.24 as well. I also tried it on a different Windows 2000 computer to make sure nothing was wrong with my XP box and the other computer had the same problem. Has anyone else had this problem? Is there anyone out there that has a Solaris box that wouldn't mind running the test application that I created to see if you have the same problem? I'm wondering if the problem might be with our network, but, I don't think that's the case because I have another application on a Solaris box that does HTTP uploads using a Perl application that doesn't have the performance problem. Jon import java.text.*; import java.util.*; public class TimeSpan { public TimeSpan(Date startDate, Date endDate) { long l = (endDate.getTime() - startDate.getTime()) / 1000; hours = l / 60 / 60; minutes = l / 60 - (hours * 60); seconds = l - (hours * 60 * 60) - (minutes * 60); } public String toString() { Object[] o = {new Long(hours), new Long(minutes), new Long(seconds)}; return new MessageFormat("{0,number,00}:{1,number,00}:{2,number,00}").format(o); } public long hours; public long minutes; public long seconds; } import java.io.*; import java.util.*; import javax.servlet.*; import javax.servlet.http.*; public class FileUpload3 extends HttpServlet { public void doGet(HttpServletRequest req, HttpServletResponse resp) throws IOException { try { resp.setContentType("text/html"); PrintWriter pw = resp.getWriter(); pw.println("http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd\";>"); pw.println("File Upload"); pw.println(""); pw.println("File: "); pw.println(""); pw.println(""); pw.println(""); pw.close(); } catch(Exception e) { e.printStackTrace(); } } public void doPost(HttpServletRequest req, HttpServletResponse resp) throws IOException { try { Date d = new Date(); ServletInputStream sis = req.getInputStream(); while(sis.read() != -1); sis.close(); Date d2 = new Date(); TimeSpan ts = new TimeSpan(d, d2); resp.setContentType("text/html"); PrintWriter pw = resp.getWriter(); pw.println("http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd\";>"); pw.println("File Upload"); pw.println(""); pw.println("" + ts + ""); pw.println(""); pw.println(""); pw.close(); } catch(Exception e) { e.printStackTrace(); } } } - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Tomcat RPM's?
I've noticed that there's not been an RPM release of Tomcat since the 4.1.24 release. Is the RPM version of tomcat no longer being provided? If it is still being provided, any expectation as to when we'll see a new RPM version? I looked in the mail archives and saw people asking about it, but the only responses I saw were suggesting people just use the tar version instead. I could do that, but having the RPM version would be easier for my setup and I'd rather continue to use that if it will be available. ---Steve - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
meaning of some log output
I'm getting the following on tomcat5 for my 3 contexts at start-up: The test context is a really simple app with just a couple of JSPs. Can anyone tell me what is the significance of: action: []: null createObjectName with StandardEngine[Catalina].StandardHost[localhost].StandardContext[/blacksail] preRegister with Catalina:type=Logger,path=/blacksail,host=localhost action: []: Verifying ModuleConfig for this application module action: []: null action: []: Verification of ModuleConfig has been completed createObjectName with StandardEngine[Catalina].StandardHost[localhost].StandardContext[/test] preRegister with Catalina:type=Logger,path=/test,host=localhost action: []: Verifying ModuleConfig for this application module action: []: Verification of ModuleConfig has been completed createObjectName with StandardEngine[Catalina].StandardHost[localhost].StandardContext[/linklib] preRegister with Catalina:type=Logger,path=/linklib,host=localhost action: []: Verifying ModuleConfig for this application module action: []: null action: []: Verification of ModuleConfig has been completed thanks Adam -- struts 1.1 + tomcat 5.0.12 + java 1.4.2 Linux 2.4.20 RH9 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Restarting Apache without restarting Tomcat
Hi, I noticed if I restart Apache without restarting Tomcat, *sometimes* the request doesn't get sent properly. It's a rather weird error though. >From the tomcat debug, I can seem that the program got to the handleLogin() method in the login class. But the user will not be able to login. The database side is not the issue here. Restarting Tomcat fixed the above behaviour. So my question is: why *sometimes* restarting Apache without restarting Tomcat works, but not all the time? Does the order matter? I can always restart Tomcat without restarting Apache. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Non-HTTP requests and HttpSession instantiation
Kludgy indeed. :) Just goes to show that there's *always* a way to get things done if you're willing to jump through enough hoops. If the client supported 302 Redirects, this wouldn't be such a problem as the Filter could set the cookie in the redirect response and everything would be fine. These requests that I'm dealing with are short XML messages that should take very little processing time, for the most part, so repeating the process by creating a new request with HttpClient would be prohibitively expensive. I think the best way to do this is to write a Filter that is also a SessionListener. The SessionListener portion can keep an up-to-date collection of HttpSession objects that are keyed off the sessionId. The Filter could receive the request, parse out the sessionId, grab the appropriate HttpSession from the local collection, wrap the request with an HttpServletRequestWrapper that overrides HttpServletRequest#getSession() to return the HttpSession that the Filter finds. This shouldn't be too much of a performance hit, localizes all changes to the Filter, and does so in a portable way. It means I have to keep a local collection of HttpSessions, but that's not the end of the world. Thanks for your insights, justin At 03:42 AM 10/15/2003, you wrote: Actually on second thought there is a klugdy workaround, you can create a Filter and trap the condition where the session does not come in the "normal way". From there, the Filter uses HttpClient (or appropriate) to construct a new request rewritten to be servlet spec happy. The downside is the CPU needs and network load is doubled. -Tim Tim Funk wrote: You can't, you must use a Valve if you need to grab a Session from another source than the standard spec stated ways. Any other servlet vendor should have a similar answer. If they deviate from the above answer, they lie. -Tim Justin Ruthenbeck wrote: A general Tomcat question, irrespective of Tomcat version or platform. Here goes... For Http requests, JSESSIONID values are passed to the server from either a cookie stored by the browser or an additional parameter included in the request. Tomcat creates the appropriate HttpSession object before control gets to the Filter and/or Servlet and makes it available via HttpServlerRequest#getSession(boolean). This is fine. I have a situation now where the JSESSIONID comes from an alternate source (encoded in the body of the message, for example). Custom code at the Filter level can parse the message body and find the JSESSIONID. Tomcat, however, doesn't know this and therefore does not grab the correct HttpSession and make it available through HttpServletRequest#getSession(). Given the following constraints, does anyone have any ideas? (1) The client is not capable of understanding 302 (Redirect) responses. (2) No modification of *internal* Tomcat classes are possible. Usage of Tomcat specific Valves/etc. are possible. (3) If possible, Servlet code should not change. I would much prefer all logic to exist in a Filter (if not possible, this is flexible). (4) If possible, I don't want to maintain a separate collection of HttpSession objects local to a given Object. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] Justin Ruthenbeck Software Engineer, NextEngine Inc. justinr - AT - nextengine DOT com Confidential See http://www.nextengine.com/confidentiality.php - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Internal Server Error
Just did a fresh install of 4.1.18 on NT4 Server (replacing a previous version that was working fine, but hey, I love spending hours beating my head against the wall, pulling out what few hairs I still have, so I get to figure this stuff out...) Had followed John Turners install how-to to the letter with one exception.. I replaced the default virtual host "localhost" with "microps.com" (as I had it in the previous install) in server.xml. I was testing the /examples/jsp/num/numguess.jsp and am getting an "Internal Server Error". Nothing is showing in any of the logs. Not a hint... I tested it under the "microps.com:8080" and it works fine.. only when I come through Apache (2.0.43) "www.microps.com" do I get this error.. Obviously a configuration issue.. just need some hints... Does this ring any bells as to where I should be looking...??? Thanks.. John Moore - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Io exception: Broken pipe
Please search commons mailing list. You need to implement sort of "keep connection alive" using commons-dbcp and pool. -Original Message- From: Omkar Joshi [mailto:[EMAIL PROTECTED] Sent: October 15, 2003 11:46 AM To: [EMAIL PROTECTED] Subject: Io exception: Broken pipe Hi, I have an application running on Linux-Tomcat. Am using connection pool for Oracle data base connectivity. The problem is , when the Tomcat is kept idle for some time it gives Io exception: Broken pipe help me. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: How to roll over catalina.out?
Alright, for the archive, this seems to be working nicely... /usr/local/applications/tomcat4.1.24/common/classes/log4j.properties contains: # log4j.properties # # This file will shut off these messages in catalina.out... # # 5189887 [Thread-14] INFO common.ChannelSocket - connection timeout reached # # ## LOGGING MESSAGES. ## log4j.category.org.apache.jk.common.ChannelSocket=WARN, filer log4j.additivity.org.apache.jk.common.ChannelSocket=false log4j.appender.filer=org.apache.log4j.RollingFileAppender log4j.appender.filer.layout=org.apache.log4j.PatternLayout log4j.appender.filer.layout.ConversionPattern=%-5p %c - [%m] %d{ISO8601}%n log4j.appender.filer.File=/usr/local/applications/tomcat4.1.24/logs/cata lina.debug log4j.appender.filer.MaxFileSize=100KB log4j.appender.filer.MaxBackupIndex=4 note you need to create the file: /usr/local/applications/tomcat4.1.24/logs/catalina.debug So far there seem to be no side-effects. All 'regular' system.out messages make it to catalina.out. All other apps using log4j seem happy as well. For the most part, the catalina.debug file ought to remain empty. Unless of course, something actually happens in the org.apache.jk.common.ChannelSocket class that is logged at WARN or above. > -Original Message- > From: Shapira, Yoav [mailto:[EMAIL PROTECTED] > Sent: Wednesday, October 15, 2003 9:24 AM > To: Tomcat Users List > Subject: RE: How to roll over catalina.out? > > > > Howdy, > > >there is mention of configuring logging.properties in JRE > 1.4.x's lib > >directory. Which would be for java.util.logging, not > commons-logging. > >So configuring commons-logging is the preferred way? > > > >Where would I place the commons-logging config file? In > /common/classes > > Yes, commons-logging is the preferred way. > > You would place the commons-logging configuration in the same > repository as commons-logging-api.jar or commons-logging.jar. > (In the /classes, not /lib, part of the repository). So if > you have commons-logging.jar in common/lib, you would place > the configuration file on common/classes. > > Placing it in the same repository is not strictly required, > but is probably the least confusing of the alternative approaches. > > Yoav Shapira > > > > This e-mail, including any attachments, is a confidential > business communication, and may contain information that is > confidential, proprietary and/or privileged. This e-mail is > intended only for the individual(s) to whom it is addressed, > and may not be saved, copied, printed, disclosed or used by > anyone else. If you are not the(an) intended recipient, > please immediately delete this e-mail from your computer > system and notify the sender. Thank you. > > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Io exception: Broken pipe
Hi, I have an application running on Linux-Tomcat. Am using connection pool for Oracle data base connectivity. The problem is , when the Tomcat is kept idle for some time it gives Io exception: Broken pipe help me. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: SSL-Tomcat
Did you install JSSE? Twan - Original Message - From: "Pirti Andrea (SPES)" <[EMAIL PROTECTED]> To: <[EMAIL PROTECTED]> Sent: Wednesday, October 15, 2003 3:26 PM Subject: SSL-Tomcat > Hello everyone, > i have a problem , with Tomcat 4.1.18 and jvm IBMJava2-141. > I opnend connector https, but during startup processing i have this > exception: > > java.lang.reflect.InvocationTargetException > at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) > at > sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.jav > a:79) > at > sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessor > Impl.java:41) > at java.lang.reflect.Method.invoke(Method.java:371) > at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:203) > Caused by: java.lang.NoClassDefFoundError: sun/security/provider/Sun > at > org.apache.tomcat.util.net.jsse.JSSEImplementation.getServerSocketFactor > y(JSSEImplementation.java:90) > at > org.apache.coyote.http11.Http11Protocol.checkSocketFactory(Http11Protoco > l.java:452) > at org.apache.coyote.http11.Http11Protocol.init(Http11Protocol.java:133) > at > org.apache.coyote.tomcat4.CoyoteConnector.initialize(CoyoteConnector.jav > a:1032) > at > org.apache.catalina.core.StandardService.initialize(StandardService.java > :579) > at > org.apache.catalina.core.StandardServer.initialize(StandardServer.java:2 > 245) > at org.apache.catalina.startup.Catalina.start(Catalina.java:511) > at org.apache.catalina.startup.Catalina.execute(Catalina.java:400) > at org.apache.catalina.startup.Catalina.process(Catalina.java:180) > > How can i resolve this problem? > > Thanks. > > - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
TOMCAT on IIS 5.0 around ?
Hello all; I am a web host provider and I need to install tomcat on a windows 2k with IIS 5.0 I would like to know if anybody in the list has implemented tomcat on windows for a shared host environment. thanks - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Setting JVM options for Servlet
Howdy, >I have a servlet application that requires tuning of JVM command line >operations to have decent performace. I need to tune things like the heap >size and garbage collection parameters. How do I do this, do I have to Wouldn't hurt to RTFM or search the archives of this list. Read the top of $CATALINA_HOME/bin/catalina.sh, you're looking for the JAVA_OPTS variable. >change Tomcat startup files? Or is there a way to have contexts run in >their >own jvm and use per context/jvm command line options? One tomcat instance = one JVM instance. If you want different webapps to have different JVMs, the webapps must be deployed on separate tomcat instances. Yoav Shapira This e-mail, including any attachments, is a confidential business communication, and may contain information that is confidential, proprietary and/or privileged. This e-mail is intended only for the individual(s) to whom it is addressed, and may not be saved, copied, printed, disclosed or used by anyone else. If you are not the(an) intended recipient, please immediately delete this e-mail from your computer system and notify the sender. Thank you. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Set Tomcat to show deprecation warnings
Howdy, >I assume I need some tomcat jar in my classpath which is not currently >there? Which one has org.apache.jasper.runtime.* ? Come on now -- is this question really so tough that you need to ask the list? ;) It's $CATALINA_HOME/common/lib/jasper-runtime.jar. Yoav Shapira This e-mail, including any attachments, is a confidential business communication, and may contain information that is confidential, proprietary and/or privileged. This e-mail is intended only for the individual(s) to whom it is addressed, and may not be saved, copied, printed, disclosed or used by anyone else. If you are not the(an) intended recipient, please immediately delete this e-mail from your computer system and notify the sender. Thank you. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Can JSP run sys command lines?
The best way is to use java.util.Properties and properties files. Use the props files to setup your webapp. Works sort of like ini files in Windows. Wade -Original Message- From: Shapira, Yoav [mailto:[EMAIL PROTECTED] Sent: Wednesday, October 15, 2003 9:30 AM To: Tomcat Users List Subject: RE: Can JSP run sys command lines? Howdy, You shouldn't be doing File I/O operations from JSPs or servlets in general. You can't get the server directory or webapp directory in a servlet-specification compliant way. In fact, they might not even exist, e.g. if you're running from a packed WAR on a database server. The only directory you are guaranteed read/write access to is the context temporary directory. It's available via (File) getServletContext().getAttribute("javax.servlet.context.tempdir"); Yoav Shapira Millennium ChemInformatics >-Original Message- >From: zeallousbigpond.net.au [mailto:[EMAIL PROTECTED] >Sent: Wednesday, October 15, 2003 8:45 AM >To: [EMAIL PROTECTED] >Subject: Re: Can JSP run sys command lines? > > >Thanks... > >I ran a mkdir anson command in JSP...it works.but for some >reason.it makes the directory in my root directory??...I mean..i >thought JSP treats the main webapp dir ,say, /webapps/anson as its main >dir > >How can I make it so it points to that directory? > >Anson > >- Original Message - >From: Tim Funk <[EMAIL PROTECTED]> >Date: Wednesday, October 15, 2003 10:32 pm >Subject: Re: Can JSP run sys command lines? > >> >> The restrictions are the same as launching any process from java. >> Such as >> - Relative vs absolute command line >> - If relative - is the current working dir correct >> - Is the user_id of the running process correct >> - Environment variables carried to the child process >> - If there is a secutiry manager - will it allow exec >> - ... >> >> -Tim >> >> zeallousbigpond.net.au wrote: >> >> > Can JSP call system exec commands in linux?. >> > >> > Runtime.getRuntime().exec("pdflatex") >> > >> > does this work in JSP? ..fyi, pdflatex is installed in >> another server.. >> > >> > so..when you run exec in tomcat...does it run and view those >> commands/programs that exist ONLY in the tomcat directory? >> > >> >> >> >> - >> To unsubscribe, e-mail: [EMAIL PROTECTED] >> For additional commands, e-mail: [EMAIL PROTECTED] >> >> > > > >- >To unsubscribe, e-mail: [EMAIL PROTECTED] >For additional commands, e-mail: [EMAIL PROTECTED] This e-mail, including any attachments, is a confidential business communication, and may contain information that is confidential, proprietary and/or privileged. This e-mail is intended only for the individual(s) to whom it is addressed, and may not be saved, copied, printed, disclosed or used by anyone else. If you are not the(an) intended recipient, please immediately delete this e-mail from your computer system and notify the sender. Thank you. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: How to roll over catalina.out?
Howdy, >there is mention of configuring logging.properties in JRE 1.4.x's lib >directory. Which would be for java.util.logging, not commons-logging. >So configuring commons-logging is the preferred way? > >Where would I place the commons-logging config file? In /common/classes Yes, commons-logging is the preferred way. You would place the commons-logging configuration in the same repository as commons-logging-api.jar or commons-logging.jar. (In the /classes, not /lib, part of the repository). So if you have commons-logging.jar in common/lib, you would place the configuration file on common/classes. Placing it in the same repository is not strictly required, but is probably the least confusing of the alternative approaches. Yoav Shapira This e-mail, including any attachments, is a confidential business communication, and may contain information that is confidential, proprietary and/or privileged. This e-mail is intended only for the individual(s) to whom it is addressed, and may not be saved, copied, printed, disclosed or used by anyone else. If you are not the(an) intended recipient, please immediately delete this e-mail from your computer system and notify the sender. Thank you. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Setting JVM options for Servlet
I have a servlet application that requires tuning of JVM command line operations to have decent performace. I need to tune things like the heap size and garbage collection parameters. How do I do this, do I have to change Tomcat startup files? Or is there a way to have contexts run in their own jvm and use per context/jvm command line options? Thanks, Bill.
RE: How to roll over catalina.out?
sorry, this turned into a hijack. In http://nagoya.apache.org/bugzilla/show_bug.cgi?id=16357 there is mention of configuring logging.properties in JRE 1.4.x's lib directory. Which would be for java.util.logging, not commons-logging. So configuring commons-logging is the preferred way? Where would I place the commons-logging config file? In /common/classes ? > -Original Message- > From: Shapira, Yoav [mailto:[EMAIL PROTECTED] > Sent: Wednesday, October 15, 2003 8:57 AM > To: Tomcat Users List > Subject: RE: How to roll over catalina.out? > > > > Howdy, > > >You said: > >OTOH - After the startup message - nothing really should be > written to > >it without making an effort to do so. So only badly written > code which > uses > >System.out/err will be the victim. > > > >Here's an example of what apx. 70% of my catalina.out file contains: > >5189887 [Thread-14] INFO common.ChannelSocket - connection timeout > >reached 5201847 [Thread-10] INFO common.ChannelSocket - connection > >timeout reached > >5216537 [Thread-8] INFO common.ChannelSocket - connection timeout > >reached > >5228577 [Thread-14] INFO common.ChannelSocket - connection timeout > >reached > >5228677 [Thread-10] INFO common.ChannelSocket - connection timeout > >reached > >5236557 [Thread-28] INFO common.ChannelSocket - connection timeout > >reached > > As the messages themselves say, they're INFO-level, not a > warning or error. You can disable these by adding a > commons-logging configuration file to tomcat. > > >and on , and on with the occasional 'broken pipe' stack > trace. I guess > >the jk connector is badly coded ? > > I wouldn't say it's badly coded. > > Yoav Shapira > > > > This e-mail, including any attachments, is a confidential > business communication, and may contain information that is > confidential, proprietary and/or privileged. This e-mail is > intended only for the individual(s) to whom it is addressed, > and may not be saved, copied, printed, disclosed or used by > anyone else. If you are not the(an) intended recipient, > please immediately delete this e-mail from your computer > system and notify the sender. Thank you. > > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Set Tomcat to show deprecation warnings
Yes, I meant shown in the browser. Bummer. OK ... when I tried to compile one of the JSP java files in the work directory, I get: contactus_jsp.java:6: package org.apache.jasper.runtime does not exist import org.apache.jasper.runtime.*; ^ contactus_jsp.java:11: cannot resolve symbol symbol : class HttpJspBase location: class org.apache.jsp.contactus_jsp public class contactus_jsp extends HttpJspBase { I assume I need some tomcat jar in my classpath which is not currently there? Which one has org.apache.jasper.runtime.* ? Thanks, Neil -Original Message- From: Shapira, Yoav [mailto:[EMAIL PROTECTED] Sent: Wednesday, October 15, 2003 9:04 AM To: Tomcat Users List Subject: RE: Set Tomcat to show deprecation warnings Howdy, I assume that by "shown" you mean shown in the browser, as opposed to tomcat's log? I don't think so. That's because by default jasper doesn't compile with deprecation ;) You could change the jasper source code to do this. But you have two other options: - Take the precompiled .java files for your JSPs from the work directory, compiled them with javac -deprecation yourself, and look for the warnings. - Use JspC to precompile your JSPs, then run them through javac -deprecation, and look at the warnings. This can be done completely offline in Ant. You can even fail the build if there are any warnings. Yoav Shapira Millennium ChemInformatics >-Original Message- >From: Boemio, Neil (GEI, FGI) [mailto:[EMAIL PROTECTED] >Sent: Wednesday, October 15, 2003 1:55 AM >To: [EMAIL PROTECTED] >Subject: Set Tomcat to show deprecation warnings > >When I hit a JSP page and there are errors, Tomcat shows a page with all >the errors. If there are no errors, but there are deprecated methods being >used, Tomcat does not show this. Is there a way I can set it up so that >deprecation warnings are shown when I hit a JSP page? > >Thanks, >Neil > 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: [slightly OT] Tomcat + JMS
Howdy, Yes, it's easy to send and receive JMS messages in webapps in tomcat. (It's not easy at all to run a JMS server inside tomcat, but that's not what you're looking to do). You install a JMS server somewhere, e.g. OpenJMS. You configure a JMS topic or queue with the name you want. These servers typically have a client jar (openjms-client-xxx.jar), which you put in the WEB-INF/lib directory of your webapp. The server will have a document saying what the initial context factory class name is. It will be in the client jar. Then you just follow any JMS tutorial in the standards steps, i.e. create the initial context using the factory for the server, connect to the queue/topic, send/receive messages... Yoav Shapira Millennium ChemInformatics >-Original Message- >From: Mark W. Webb [mailto:[EMAIL PROTECTED] >Sent: Wednesday, October 15, 2003 9:48 AM >To: Tomcat Users List >Subject: [slightly OT] Tomcat + JMS > >I need to add some JMS functionality to my web app. I want to stick >with Tomcat, since I have become very familiar with it, and like it. > >Has anyone had any experience with JMS and tomcat/servlets. I need to >have a class/servlet recieve JMS messages. > > >Thanks, > > >- >To unsubscribe, e-mail: [EMAIL PROTECTED] >For additional commands, e-mail: [EMAIL PROTECTED] This e-mail, including any attachments, is a confidential business communication, and may contain information that is confidential, proprietary and/or privileged. This e-mail is intended only for the individual(s) to whom it is addressed, and may not be saved, copied, printed, disclosed or used by anyone else. If you are not the(an) intended recipient, please immediately delete this e-mail from your computer system and notify the sender. Thank you. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: How to roll over catalina.out?
Howdy, >You said: >OTOH - After the startup message - nothing really should be written to >it >without making an effort to do so. So only badly written code which uses >System.out/err will be the victim. > >Here's an example of what apx. 70% of my catalina.out file contains: >5189887 [Thread-14] INFO common.ChannelSocket - connection timeout >reached >5201847 [Thread-10] INFO common.ChannelSocket - connection timeout >reached >5216537 [Thread-8] INFO common.ChannelSocket - connection timeout >reached >5228577 [Thread-14] INFO common.ChannelSocket - connection timeout >reached >5228677 [Thread-10] INFO common.ChannelSocket - connection timeout >reached >5236557 [Thread-28] INFO common.ChannelSocket - connection timeout >reached As the messages themselves say, they're INFO-level, not a warning or error. You can disable these by adding a commons-logging configuration file to tomcat. >and on , and on with the occasional 'broken pipe' stack trace. I guess >the jk connector is badly coded ? I wouldn't say it's badly coded. Yoav Shapira This e-mail, including any attachments, is a confidential business communication, and may contain information that is confidential, proprietary and/or privileged. This e-mail is intended only for the individual(s) to whom it is addressed, and may not be saved, copied, printed, disclosed or used by anyone else. If you are not the(an) intended recipient, please immediately delete this e-mail from your computer system and notify the sender. Thank you. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
servlet mapping similarity/overlap ?
Here is a snippet from web.xml ... Controller com.xxx.Controller Controller /test Controller /test/ please notice the two servlet mappings, one to "/test" and the other to "/test/" the only difference is the trailing slash, but I wish to have both uri's mapped to the same servlet must i add both elements, or is there a better way to do this? thanks in advance ... jules Jules Yasuna Bookus-Boulet. Inc. http://www.bookus-boulet.com (508) 523-7663 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
[slightly OT] Tomcat + JMS
I need to add some JMS functionality to my web app. I want to stick with Tomcat, since I have become very familiar with it, and like it. Has anyone had any experience with JMS and tomcat/servlets. I need to have a class/servlet recieve JMS messages. Thanks, - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: How to roll over catalina.out?
On here: http://marc.theaimsgroup.com/?l=tomcat-user&m=105545518004325&w=2 You said: OTOH - After the startup message - nothing really should be written to it without making an effort to do so. So only badly written code which uses System.out/err will be the victim. Here's an example of what apx. 70% of my catalina.out file contains: 5189887 [Thread-14] INFO common.ChannelSocket - connection timeout reached 5201847 [Thread-10] INFO common.ChannelSocket - connection timeout reached 5216537 [Thread-8] INFO common.ChannelSocket - connection timeout reached 5228577 [Thread-14] INFO common.ChannelSocket - connection timeout reached 5228677 [Thread-10] INFO common.ChannelSocket - connection timeout reached 5236557 [Thread-28] INFO common.ChannelSocket - connection timeout reached and on , and on with the occasional 'broken pipe' stack trace. I guess the jk connector is badly coded ? > -Original Message- > From: Tim Funk [mailto:[EMAIL PROTECTED] > Sent: Wednesday, October 15, 2003 6:36 AM > To: Tomcat Users List > Subject: Re: How to roll over catalina.out? > > > Archives --> search keywords --> "rotate catalina.out" > > http://marc.theaimsgroup.com/?l=tomcat-user&w=2&r=1&s=catalina > .out+rotate&q=b > > -Tim > > Adam Lipscombe wrote: > > > Folks, > > > > Sorry if this in a FAQ somewhere - I couldn't find it. > > > > I need to rollover / archive catalina.out every day or week as its > > getting huge. Is there a mechanism within Tomcat for doing this? > > > > > - > 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: RNIF + Tomcat + Axis
Howdy, >Well is this combination the best way to go? From what I've read so far >RNIF >is a like ebXML, so I think I can use Axis to handle incoming RosettaNet >messages right? You can use Axis to handle these messages, yes. Axis and tomcat play along nicely (as they should), so give it a shot ;) Yoav Shapira This e-mail, including any attachments, is a confidential business communication, and may contain information that is confidential, proprietary and/or privileged. This e-mail is intended only for the individual(s) to whom it is addressed, and may not be saved, copied, printed, disclosed or used by anyone else. If you are not the(an) intended recipient, please immediately delete this e-mail from your computer system and notify the sender. Thank you. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Can JSP run sys command lines?
Howdy, You shouldn't be doing File I/O operations from JSPs or servlets in general. You can't get the server directory or webapp directory in a servlet-specification compliant way. In fact, they might not even exist, e.g. if you're running from a packed WAR on a database server. The only directory you are guaranteed read/write access to is the context temporary directory. It's available via (File) getServletContext().getAttribute("javax.servlet.context.tempdir"); Yoav Shapira Millennium ChemInformatics >-Original Message- >From: zeallousbigpond.net.au [mailto:[EMAIL PROTECTED] >Sent: Wednesday, October 15, 2003 8:45 AM >To: [EMAIL PROTECTED] >Subject: Re: Can JSP run sys command lines? > > >Thanks... > >I ran a mkdir anson command in JSP...it works.but for some >reason.it makes the directory in my root directory??...I mean..i >thought JSP treats the main webapp dir ,say, /webapps/anson >as its main dir > >How can I make it so it points to that directory? > >Anson > >- Original Message - >From: Tim Funk <[EMAIL PROTECTED]> >Date: Wednesday, October 15, 2003 10:32 pm >Subject: Re: Can JSP run sys command lines? > >> >> The restrictions are the same as launching any process from java. >> Such as >> - Relative vs absolute command line >> - If relative - is the current working dir correct >> - Is the user_id of the running process correct >> - Environment variables carried to the child process >> - If there is a secutiry manager - will it allow exec >> - ... >> >> -Tim >> >> zeallousbigpond.net.au wrote: >> >> > Can JSP call system exec commands in linux?. >> > >> > Runtime.getRuntime().exec("pdflatex") >> > >> > does this work in JSP? ..fyi, pdflatex is installed in >> another server.. >> > >> > so..when you run exec in tomcat...does it run and view those >> commands/programs that exist ONLY in the tomcat directory? >> > >> >> >> >> - >> To unsubscribe, e-mail: [EMAIL PROTECTED] >> For additional commands, e-mail: [EMAIL PROTECTED] >> >> > > > >- >To unsubscribe, e-mail: [EMAIL PROTECTED] >For additional commands, e-mail: [EMAIL PROTECTED] This e-mail, including any attachments, is a confidential business communication, and may contain information that is confidential, proprietary and/or privileged. This e-mail is intended only for the individual(s) to whom it is addressed, and may not be saved, copied, printed, disclosed or used by anyone else. If you are not the(an) intended recipient, please immediately delete this e-mail from your computer system and notify the sender. Thank you. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
SSL-Tomcat
Hello everyone, i have a problem , with Tomcat 4.1.18 and jvm IBMJava2-141. I opnend connector https, but during startup processing i have this exception: java.lang.reflect.InvocationTargetException at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.jav a:79) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessor Impl.java:41) at java.lang.reflect.Method.invoke(Method.java:371) at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:203) Caused by: java.lang.NoClassDefFoundError: sun/security/provider/Sun at org.apache.tomcat.util.net.jsse.JSSEImplementation.getServerSocketFactor y(JSSEImplementation.java:90) at org.apache.coyote.http11.Http11Protocol.checkSocketFactory(Http11Protoco l.java:452) at org.apache.coyote.http11.Http11Protocol.init(Http11Protocol.java:133) at org.apache.coyote.tomcat4.CoyoteConnector.initialize(CoyoteConnector.jav a:1032) at org.apache.catalina.core.StandardService.initialize(StandardService.java :579) at org.apache.catalina.core.StandardServer.initialize(StandardServer.java:2 245) at org.apache.catalina.startup.Catalina.start(Catalina.java:511) at org.apache.catalina.startup.Catalina.execute(Catalina.java:400) at org.apache.catalina.startup.Catalina.process(Catalina.java:180) How can i resolve this problem? Thanks.
Re: Can JSP run sys command lines?
Thanks... I ran a mkdir anson command in JSP...it works.but for some reason.it makes the directory in my root directory??...I mean..i thought JSP treats the main webapp dir ,say, /webapps/anson as its main dir How can I make it so it points to that directory? Anson - Original Message - From: Tim Funk <[EMAIL PROTECTED]> Date: Wednesday, October 15, 2003 10:32 pm Subject: Re: Can JSP run sys command lines? > > The restrictions are the same as launching any process from java. > Such as > - Relative vs absolute command line > - If relative - is the current working dir correct > - Is the user_id of the running process correct > - Environment variables carried to the child process > - If there is a secutiry manager - will it allow exec > - ... > > -Tim > > zeallousbigpond.net.au wrote: > > > Can JSP call system exec commands in linux?. > > > > Runtime.getRuntime().exec("pdflatex") > > > > does this work in JSP? ..fyi, pdflatex is installed in > another server.. > > > > so..when you run exec in tomcat...does it run and view those > commands/programs that exist ONLY in the tomcat directory? > > > > > > - > 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 jitters, then hangs - please help
Shapira, Yoav wrote: Howdy, Cool, please keep us updated ;) I want these linux questions better documented in the list archives ;) Given that RH 9 / HTTP/1.1 seems a fairly common configuration, this should be added to the known issues and the FAQ if confirmed. Since there are three options, I wonder how the "2.4 compat" mode works out. I assume Noam played it safe, and chose "2.2 compat" mode for his testing just in case ;-) I assume it would work as well as "2.2 compat", since there weren't any major problems before (again, to be confirmed; since the performance difference is likely not very significant, it's better to get stability in this case :)). -- x Rémy Maucherat Senior Developer & Consultant JBoss Group (Europe) SàRL x - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: RNIF + Tomcat + Axis
Howdy, I personally don't, but that'd be a cool project ;) If you go down the path and reach something interesting, please feel free to share your experience with the list ;) Well is this combination the best way to go? From what I've read so far RNIF is a like ebXML, so I think I can use Axis to handle incoming RosettaNet messages right? _ Op zoek naar makkelijk recept? http://www.msn.be/culinair - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: setting up the tomcat server for struts applications - HTTP 500 error
Howdy, I haven't used the book. You should have a far more detailed error in tomcat's log -- if you post that we might be able to help more. Before starting with the book's examples, ensure your tomcat installation is OK by running the examples. Also try the admin webapp, as that's a struts app. Yoav Shapira Millennium ChemInformatics >-Original Message- >From: Bajaj, Aparna [mailto:[EMAIL PROTECTED] >Sent: Tuesday, October 14, 2003 3:35 PM >To: '[EMAIL PROTECTED]' >Subject: setting up the tomcat server for struts applications - HTTP 500 >error > >Has anyone used the book, Struts in Action by Manning Publications? I am >reading that book, and just tried the first sample application from Chapter >1. The server seems to come up alright, but if I want to run my sample >application, I get the following error:- > >HTTP Status 500 > >org.apache.jasper.JasperException: /register.jsp(0,4) Invalid directive > >I know this a server error, and the problem could be because the server >hasn't been setup properly. I tried all the solutions I could find on the >web, but it still doesn't seem to solve my problem. Does anyone know what >else could be wrong? Like common mistakes? > >I am using Tomcat 4.1.27 > >Thanks, >Aparna > > >- >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: tomcat jitters, then hangs - please help
Howdy, Cool, please keep us updated ;) I want these linux questions better documented in the list archives ;) Yoav Shapira Millennium ChemInformatics >-Original Message- >From: Noam Camiel [mailto:[EMAIL PROTECTED] >Sent: Wednesday, October 15, 2003 6:37 AM >To: Euan Guttridge; Tomcat Users List >Subject: Re: tomcat jitters, then hangs - please help > >Hi Euan > >Please note the server is now up for 48 hours strait. >The change I've made is I've set LD_ASSUME_KERNEL to 2.2.5 >I will update again in another 48 hours or if the server hangs, whichever >comes first. > >Regards, >Noam > >- Original Message - >From: "Euan Guttridge" <[EMAIL PROTECTED]> >To: <[EMAIL PROTECTED]> >Sent: Wednesday, October 15, 2003 9:42 AM >Subject: FW: tomcat jitters, then hangs - please help > > >> Hi Noam, >> >> I work with Ryan on tomcat issues. I would be grateful if you would let >me >> know if your tomcat installation is *still* up (another 24 hours) since >the >> NPTL change as below. >> >> >> Regards, >> Euan >> >> -Original Message- >> From: Noam Camiel [mailto:[EMAIL PROTECTED] >> Sent: 14 October 2003 14:46 >> To: Tomcat Users List >> Subject: Re: tomcat jitters, then hangs - please help >> >> >> Hi, >> >> On Friday, October 10, 2003 11:09 AM "Ryan Lissack" >> <[EMAIL PROTECTED]> wrote: >> >> > Remy pointed out to me previously that RH9 uses a new form of threading >> and >> > based on this we have done some investigation. >> > >> > RH9 uses NTPL (Native POSIX Thread Library) >> > http://www.redhat.com/docs/manuals/linux/RHL-9-Manual/release- >notes/x86/ >> > >> > It is possible to revert to the older form of threading, >"LinuxThreads", >> by >> > setting an environment variable, namely: >> > LD_ASSUME_KERNEL= >> > - 2.4.1 - Linuxthreads with floating stacks >> > - 2.2.5 - Linuxthreads without floating stacks >> > >> > This does not revert back to an older kernel, it just changes the GNU C >> > library used http://www-106.ibm.com/developerworks/java/library/j-jtc/ >> > >> > We will be testing with these settings starting today and, if we >continue >> to >> > have problems, we will be trying another distro. >> >> setting the LD_ASSUME_KERNEL variable, the server is now running over 24 >> hours strait. >> Still, nothing conclusive as of yet.. >> Ryan, thanks for the information above. Do you have move information >> regarding this configuration? do you still encounter problems? >> >> >> On Monday, October 13, 2003 9:59 PM "Joe Zendle" ><[EMAIL PROTECTED]> >> wrote: >> >> > We had the same problem w/ TC 4.1.27, sun jvm 1.4.2 and redhat 9. The >> > thing wouldn't work for more than about 12 hours. IMHO, there are some >> > fundamental problems with tomcat as of late. Hate to say it but we >> > solved the problem by throwing away tomcat and using jetty! We are very >> > pleased so far. Jetty is very fast and about 1/3 the memory footprint. >> > >> > Good luck. >> >> >> Hi Joe, >> Thanks for sharing the info, I am considering what you suggest as well. >> As a last try before moving away from Tomcat, I'm trying out the >suggestion >> from Ryan above. >> Regards, >> Noam. >> >> >> >> - >> To unsubscribe, e-mail: [EMAIL PROTECTED] >> For additional commands, e-mail: [EMAIL PROTECTED] > > >- >To unsubscribe, e-mail: [EMAIL PROTECTED] >For additional commands, e-mail: [EMAIL PROTECTED] This e-mail, including any attachments, is a confidential business communication, and may contain information that is confidential, proprietary and/or privileged. This e-mail is intended only for the individual(s) to whom it is addressed, and may not be saved, copied, printed, disclosed or used by anyone else. If you are not the(an) intended recipient, please immediately delete this e-mail from your computer system and notify the sender. Thank you. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: shared/classes folder
Howdy, >> In order to "share" objects between webapps, you need a common >> repository. This is what shared/classes or shared/lib is for in tomcat, >> and that's why there's only one copy there. This is correct behavior. >(Yoav Shapira) >Oh. I didn't know about that. Are there any docs about this? I'd like to >see more. OH, I thought you were already using shared/classes? ;) Anyways, you should read the Classloader How-To page in the tomcat documentation. >> Personally, I'd suggest you put everything under >> WEB-INF to keep your webapp self-contained and portable >(Yoav Shapira) >Self-containment is absolutely required, because the apps are to be >deployed in different servers (therefore making the shared/classes folder >unusable). Good: self-containment is a wonderful attribute for a webapp. Yoav Shapira This e-mail, including any attachments, is a confidential business communication, and may contain information that is confidential, proprietary and/or privileged. This e-mail is intended only for the individual(s) to whom it is addressed, and may not be saved, copied, printed, disclosed or used by anyone else. If you are not the(an) intended recipient, please immediately delete this e-mail from your computer system and notify the sender. Thank you. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Set Tomcat to show deprecation warnings
Howdy, I assume that by "shown" you mean shown in the browser, as opposed to tomcat's log? I don't think so. That's because by default jasper doesn't compile with deprecation ;) You could change the jasper source code to do this. But you have two other options: - Take the precompiled .java files for your JSPs from the work directory, compiled them with javac -deprecation yourself, and look for the warnings. - Use JspC to precompile your JSPs, then run them through javac -deprecation, and look at the warnings. This can be done completely offline in Ant. You can even fail the build if there are any warnings. Yoav Shapira Millennium ChemInformatics >-Original Message- >From: Boemio, Neil (GEI, FGI) [mailto:[EMAIL PROTECTED] >Sent: Wednesday, October 15, 2003 1:55 AM >To: [EMAIL PROTECTED] >Subject: Set Tomcat to show deprecation warnings > >When I hit a JSP page and there are errors, Tomcat shows a page with all >the errors. If there are no errors, but there are deprecated methods being >used, Tomcat does not show this. Is there a way I can set it up so that >deprecation warnings are shown when I hit a JSP page? > >Thanks, >Neil > 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: RNIF + Tomcat + Axis
Howdy, I personally don't, but that'd be a cool project ;) If you go down the path and reach something interesting, please feel free to share your experience with the list ;) Yoav Shapira Millennium ChemInformatics >-Original Message- >From: Kenneth Westelinck [mailto:[EMAIL PROTECTED] >Sent: Wednesday, October 15, 2003 8:22 AM >To: [EMAIL PROTECTED] >Subject: RNIF + Tomcat + Axis > >Hi all, > >Maybe this is a little off-topic, but here goes anyway. Does anyone in the >list have experience with using Tomcat (together with Axis or something >else) to implement the Rosetta Net Implementation Framework? > > >regards, > >Kenneth > >_ >Ken je het magazine Glamo al? http://www.msn.be/glamo > > >- >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: Invalidated session
Howdy, An invalidated session is one that should not be treated as valid ;) This means a few things: - To the container: this session does not need to be persisted - To the container: this session does not need to be clustered - To the container: remove attributes from this session - To the application: ignore this session and any attribute it may contain So as Senor Hardy mentioned, programmatically invalidating a session is a valid method to accomplish any of the above goals. Yoav Shapira Millennium ChemInformatics >-Original Message- >From: Adam Hardy [mailto:[EMAIL PROTECTED] >Sent: Wednesday, October 15, 2003 8:56 AM >To: Tomcat Users List >Subject: Re: Invalidated session > >On 10/15/2003 02:10 PM Carlos-Roberto Queiroz wrote: >> Sorry for the dull question, but I´d like to know what an >invalidated >> session is, and when a session gets invalidated (just timeout ?) >> > >also when you call session.invalidate() > > >Adam > >-- >struts 1.1 + tomcat 5.0.12 + java 1.4.2 >Linux 2.4.20 RH9 > > >- >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: JSP, taking a very long time running java classes..how come? really need help
Hola, >I have a problem making use of java class files from JSP. Right now, >I'm calling a java class where (inside the method) will generate a PDF file >using Linux commands. But its taking ages for some reason. So the same java class, called from a JSP takes forever, but called from the command line outside the servlet container, takes 5 seconds? That would be odd indeed. Can you add time logging statements to see exactly where time is spent? Your JSP, I assume, is compiled already before you did the performance comparison? Yoav Shapira This e-mail, including any attachments, is a confidential business communication, and may contain information that is confidential, proprietary and/or privileged. This e-mail is intended only for the individual(s) to whom it is addressed, and may not be saved, copied, printed, disclosed or used by anyone else. If you are not the(an) intended recipient, please immediately delete this e-mail from your computer system and notify the sender. Thank you. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: How to roll over catalina.out?
Howdy, Yup, the archives have solutions. I would also ask, why is catalina.out getting huge? Perhaps you don't need all the (debug? Info?) output in there. Perhaps you need nothing there at all... Yoav Shapira Millennium ChemInformatics >-Original Message- >From: Tim Funk [mailto:[EMAIL PROTECTED] >Sent: Wednesday, October 15, 2003 7:36 AM >To: Tomcat Users List >Subject: Re: How to roll over catalina.out? > >Archives --> search keywords --> "rotate catalina.out" > >http://marc.theaimsgroup.com/?l=tomcat- >user&w=2&r=1&s=catalina.out+rotate&q=b > >-Tim > >Adam Lipscombe wrote: > >> Folks, >> >> Sorry if this in a FAQ somewhere - I couldn't find it. >> >> I need to rollover / archive catalina.out every day or week as its >> getting huge. >> Is there a mechanism within Tomcat for doing this? >> > > >- >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: I post a text XML with Microsoft.XMLHTTP to servlet
Howdy, You should be able to test this using either MockObjects or Cactus, before sending it to your clients ;) Yoav Shapira Millennium ChemInformatics >-Original Message- >From: Blackmore, John [mailto:[EMAIL PROTECTED] >Sent: Tuesday, October 14, 2003 2:01 PM >To: 'Tomcat Users List' >Subject: RE: I post a text XML with Microsoft.XMLHTTP to servlet > >Sorry, I was mistaken - what little content was there was actually another >form element which didn't belong. Looks like my XMLHTTP test app was the >problem. I think I have it working with my second approach below, however I >won't know for sure until the client "tests" it. Needless to say, they >expect it to work right the first time (sigh). > >Thanks for the quick responses! > >John > >-Original Message- >From: Shapira, Yoav [mailto:[EMAIL PROTECTED] >Sent: Tuesday, October 14, 2003 9:24 AM >To: Tomcat Users List >Subject: RE: I post a text XML with Microsoft.XMLHTTP to servlet > > > >Howdy, > >>Second, I tried to forcibly retrieve characters from the input stream, >one >>by one. >> >> String xmlDocString = getXMLString((InputStream) >>req.getInputStream()); >> Document document = builder.parse(new >>StringBufferInputStream(xmlDocString)); >> >>Note: the getXMLString() function is not very interesting... simply has >a >>loop as follows: >> >> while( (c=xmlInputStream.read()) > 0 ) >> >>When I try this, I get the same error, however I don't get an empty >string >>- >>xmlDocString has what looks like a URL encoded and truncated version of >the >>original string. > >This is the approach I had in mind. Then URL-decode it >(URLDecoder.decode(...)). Why is it truncated? > >Yoav Shapira > > > >*** *** >This e-mail and any files transmitted with it may contain privileged or >confidential information. It is solely for use by the individual for whom >it is intended, even if addressed incorrectly. If you received this e-mail >in error, please notify the sender; do not disclose, copy, distribute, or >take any action in reliance on the contents of this information; and delete >it from your system. Any other use of this e-mail is prohibited. Thank you >for your compliance. > > > > >- >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: Invalidated session
On 10/15/2003 02:10 PM Carlos-Roberto Queiroz wrote: Sorry for the dull question, but I´d like to know what an invalidated session is, and when a session gets invalidated (just timeout ?) also when you call session.invalidate() Adam -- struts 1.1 + tomcat 5.0.12 + java 1.4.2 Linux 2.4.20 RH9 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Can JSP run sys command lines?
The restrictions are the same as launching any process from java. Such as - Relative vs absolute command line - If relative - is the current working dir correct - Is the user_id of the running process correct - Environment variables carried to the child process - If there is a secutiry manager - will it allow exec - ... -Tim zeallousbigpond.net.au wrote: Can JSP call system exec commands in linux?. Runtime.getRuntime().exec("pdflatex") does this work in JSP? ..fyi, pdflatex is installed in another server.. so..when you run exec in tomcat...does it run and view those commands/programs that exist ONLY in the tomcat directory? - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RNIF + Tomcat + Axis
Hi all, Maybe this is a little off-topic, but here goes anyway. Does anyone in the list have experience with using Tomcat (together with Axis or something else) to implement the Rosetta Net Implementation Framework? regards, Kenneth _ Ken je het magazine Glamo al? http://www.msn.be/glamo - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Can JSP run sys command lines?
Can JSP call system exec commands in linux?. Runtime.getRuntime().exec("pdflatex") does this work in JSP? ..fyi, pdflatex is installed in another server.. so..when you run exec in tomcat...does it run and view those commands/programs that exist ONLY in the tomcat directory? Anson - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Invalidated session
Sorry for the dull question, but I´d like to know what an invalidated session is, and when a session gets invalidated (just timeout ?) Thanks - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
JSP, taking a very long time running java classes..how come? really need help
Hi, I have a problem making use of java class files from JSP. Right now, I'm calling a java class where (inside the method) will generate a PDF file using Linux commands. But its taking ages for some reason. But I also made a testing java class that test if that particular function works. It works in 5 secs. Do anyone of you guys know what might be the reason? I mean ...in the mozilla bar...the "sending" is completed...but the "transferring" is taking such a long time...and I dunno if it actually reached that function. The class...obviously is in the classes folder. Regards, Anson - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: How to roll over catalina.out?
Archives --> search keywords --> "rotate catalina.out" http://marc.theaimsgroup.com/?l=tomcat-user&w=2&r=1&s=catalina.out+rotate&q=b -Tim Adam Lipscombe wrote: Folks, Sorry if this in a FAQ somewhere - I couldn't find it. I need to rollover / archive catalina.out every day or week as its getting huge. Is there a mechanism within Tomcat for doing this? - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
How to roll over catalina.out?
Folks, Sorry if this in a FAQ somewhere - I couldn't find it. I need to rollover / archive catalina.out every day or week as its getting huge. Is there a mechanism within Tomcat for doing this? TIA - Adam - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Why should I use Tomcat vs .NET?
Chris, Your $450 statement is not quite correct, rather $450 per desk Huge difference even for a company. What is true however, is the learning curve and most importantly the use of "low grade staff" as you put it. That has always been MS's key to success and that is what is needed for open systems to gain popularity among the general populus. Regards Johan Kok > -Original Message- > From: Walker Chris [mailto:[EMAIL PROTECTED] > Sent: 14 October 2003 10:59 > To: 'Tomcat Users List' > Subject: RE: Why should I use Tomcat vs .NET? > > > Chuck, > > I agree with most of what you say except for your point about software > purchase costs. > > While $450 is a lot for an individual to find, for a company > the purchase > cost of software is trivial compared to the cost of learning > to use it. I > don't know what contract rates are like in San Diego, but I > bet it wouldn't > take an employer long to burn $450. > > A new technology that's easy to learn is always attractive from the > employers' point of view - they don't need to spend a lot on > training and > they can use relatively low-grade staff. That's why the > appalling VB was > such a success, but I don't think .NET is that easy to learn > - unless you're > already a Java developer! > > Chris > > > -Original Message- > From: Goehring, Chuck Mr., RCI - San Diego > [mailto:[EMAIL PROTECTED] > Sent: 13 October 2003 20:31 > To: Tomcat Users List > Subject: RE: Why should I use Tomcat vs .NET? > > > Eduardo, > > A couple interesting points involves myself and my coworker. > He has about > ten years of VB programming experience. None of his code can > be migrated to > vb.net without major rewriting because there is no semblance > of backward > compatibility. It wouldn't be practical for the customer to > pay him to > convert the app to dot.net, so he's stuck in 1998. All the > VB programmers > have been screwed by Microsoft this way. > > With me, I've been doing Java and perl for about 6 years. > Because of the > contracting environment I'm in, it looked like my work was > going to dry up. > An opportunity came along for me within the company. They > wanted to do ASP > 2.0 web development because they had to meet a variety of government > requirements and ASP had been approved for use. Thinking I > was going to > have to do that project, I checked into it. Firstly, the ASP > code they were > going to write is totally incompatible with ASP.net, so it > was going down a > dead path. To cover all the bases, I did some research into > upgrading my > copy of Visual C++ 6.0 to Visual Studio.net. MS wanted $450 for the > upgrade. That's a lot for me to fork over to start over with > a completely > different system that has limited uses. Fortunately, I > didn't have to go > that route, but it came close. > > Comparing that to continuing with Tomcat and Eclipse or > NetBeans or JCreator > (free version), I can't see why anyone would choose to go the > dot.net route. > MS has also done a powerplay on the folks that use Frontpage > Extensions. > The Frontpage 200x now requires that you subscribe to a service from > Microsoft to enable important features of the product. It is > a lot like > extortion. > > I like using the free products because I can dump any of them > at any time > without feeling guilty about wasting the company's money. > Once you spend > thousands to use a proprietary product, you may never be able > to escape. I > still have to support an ancient Developer 2000 product that can't be > cost-effectively be migrated to a newer version and has all kinds of > compatibility issues when used with newer products. > > Chuck > > > -Original Message- > From: Eduardo Vazquez [mailto:[EMAIL PROTECTED] > Sent: Monday, October 13, 2003 10:48 AM > To: 'Tomcat Users List' > Subject: RE: Why should i use Tomcat vs .NET? > > > Up front I do need to say that the support of this user > group has > been more than outstanding. I was a sole person looking for help and I > received more than I could have expected, and for that thanks to all. > Eventually I have lost the war; my CTO has decided on a new > technology on > his lonesome and has hinted that any effort expended moving > forward won't > result in any reconsideration of his decision (so much for > standards and not > putting all your eggs in one basket) Again, I've learned much > from all those > who have replied to my request and hope that others have > learnt a little > sumthin' along the way. > > Much Thanks, > Eduardo > > > > -Original Message- > From: epyonne [mailto:[EMAIL PROTECTED] > Sent: Monday, October 13, 2003 9:26 AM > To: Tomcat Users List > Subject: Re: Why should i use Tomcat vs .NET? > > Simple decision. If your company is a pure "Microsoft shop", > i.e. you use > Windows desktops, Windows servers, and SQL Server databases, > then it is a > no-brainer, go with .NET. > > On the other hand, if your company has a mixed environment > like ours,
Re: Non-HTTP requests and HttpSession instantiation
Actually on second thought there is a klugdy workaround, you can create a Filter and trap the condition where the session does not come in the "normal way". From there, the Filter uses HttpClient (or appropriate) to construct a new request rewritten to be servlet spec happy. The downside is the CPU needs and network load is doubled. -Tim Tim Funk wrote: You can't, you must use a Valve if you need to grab a Session from another source than the standard spec stated ways. Any other servlet vendor should have a similar answer. If they deviate from the above answer, they lie. -Tim Justin Ruthenbeck wrote: A general Tomcat question, irrespective of Tomcat version or platform. Here goes... For Http requests, JSESSIONID values are passed to the server from either a cookie stored by the browser or an additional parameter included in the request. Tomcat creates the appropriate HttpSession object before control gets to the Filter and/or Servlet and makes it available via HttpServlerRequest#getSession(boolean). This is fine. I have a situation now where the JSESSIONID comes from an alternate source (encoded in the body of the message, for example). Custom code at the Filter level can parse the message body and find the JSESSIONID. Tomcat, however, doesn't know this and therefore does not grab the correct HttpSession and make it available through HttpServletRequest#getSession(). Given the following constraints, does anyone have any ideas? (1) The client is not capable of understanding 302 (Redirect) responses. (2) No modification of *internal* Tomcat classes are possible. Usage of Tomcat specific Valves/etc. are possible. (3) If possible, Servlet code should not change. I would much prefer all logic to exist in a Filter (if not possible, this is flexible). (4) If possible, I don't want to maintain a separate collection of HttpSession objects local to a given Object. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: graceful setting in workers2.properties
Try to disable the channel by setting disabled to 1. Then you could gracefully switch the the sessions from one tomcat to the other. At jkstatus you could see, that gracefull will be enabled. Klaus [channel.socket:localhost:7010] info=Ajp13 forwarding over socket tomcatId=jvm2 lb_factor=1 group=lb debug=3 graceful=1 disabled=1 - Original Message - From: "Kelly Kleinfelder" <[EMAIL PROTECTED]> To: "'Tomcat Users List'" <[EMAIL PROTECTED]> Sent: Tuesday, October 14, 2003 7:51 PM Subject: graceful setting in workers2.properties > I'm using Tomcat 4.1.27 and Apache 2.0.47 built with the worker mpm and > mod_jk2 build from the 2.0.2 connectors source. > > I'm trying to use the graceful setting in workers2.properties to take one of > the workers out of service, but it doesn't seem to be working. I'm not sure > if the lb_value should be changing to reflect the use of graceful, but it's > my suspicion that this is part of the problem. > > Thanks, > Kelly > > Here's the output from my jkstatus: > > id name lb_factor lb_value route errorState graceful epCount errorTime > 2 localhost:7009 10 10 jvm1 N N 0 0 > 3 localhost:7010 1 1 jvm2 N N 0 0 > > > Here's my workers2.properties: > > [logger] > level=DEBUG > > [config:] > file=${serverRoot}/conf/workers2.properties > debug=0 > debugEnv=0 > > [uriMap:] > info=Maps the requests. Options: debug > debug=0 > > Alternate file logger > [logger.file:0] > level=DEBUG > file=${serverRoot}/logs/jk2.log > > [shm:] > info=Scoreboard. Required for reconfiguration and status with multiprocess > serve > rs > file=${serverRoot}/logs/jk2.shm > size=100 > debug=0 > disabled=0 > > [workerEnv:] > info=Global server options > timing=1 > debug=0 > # Default Native Logger (apache2 or win32 ) > # can be overriden to a file logger, useful > # when tracing win32 related issues > #logger=logger.file:0 > > [lb:lb] > info=Default load balancer. > debug=3 > stickySession=1 > > [lb:lb_1] > info=A second load balancer. > debug=0 > > [channel.socket:localhost:7009] > info=Ajp13 forwarding over socket > tomcatId=jvm1 > lb_factor=10 > group=lb > debug=3 > > [channel.socket:localhost:7010] > info=Ajp13 forwarding over socket > tomcatId=jvm2 > lb_factor=1 > group=lb > debug=3 > graceful=1 > > [channel.jni:jni] > info=The jni channel, used if tomcat is started inprocess > > [status:] > info=Status worker, displays runtime informations > > [uri:/examples] > info=Example webapp in the default context. > context=/examples > debug=0 > > > > > - > 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 jitters, then hangs - please help
Hi Euan Please note the server is now up for 48 hours strait. The change I've made is I've set LD_ASSUME_KERNEL to 2.2.5 I will update again in another 48 hours or if the server hangs, whichever comes first. Regards, Noam - Original Message - From: "Euan Guttridge" <[EMAIL PROTECTED]> To: <[EMAIL PROTECTED]> Sent: Wednesday, October 15, 2003 9:42 AM Subject: FW: tomcat jitters, then hangs - please help > Hi Noam, > > I work with Ryan on tomcat issues. I would be grateful if you would let me > know if your tomcat installation is *still* up (another 24 hours) since the > NPTL change as below. > > > Regards, > Euan > > -Original Message- > From: Noam Camiel [mailto:[EMAIL PROTECTED] > Sent: 14 October 2003 14:46 > To: Tomcat Users List > Subject: Re: tomcat jitters, then hangs - please help > > > Hi, > > On Friday, October 10, 2003 11:09 AM "Ryan Lissack" > <[EMAIL PROTECTED]> wrote: > > > Remy pointed out to me previously that RH9 uses a new form of threading > and > > based on this we have done some investigation. > > > > RH9 uses NTPL (Native POSIX Thread Library) > > http://www.redhat.com/docs/manuals/linux/RHL-9-Manual/release-notes/x86/ > > > > It is possible to revert to the older form of threading, "LinuxThreads", > by > > setting an environment variable, namely: > > LD_ASSUME_KERNEL= > > - 2.4.1 - Linuxthreads with floating stacks > > - 2.2.5 - Linuxthreads without floating stacks > > > > This does not revert back to an older kernel, it just changes the GNU C > > library used http://www-106.ibm.com/developerworks/java/library/j-jtc/ > > > > We will be testing with these settings starting today and, if we continue > to > > have problems, we will be trying another distro. > > setting the LD_ASSUME_KERNEL variable, the server is now running over 24 > hours strait. > Still, nothing conclusive as of yet.. > Ryan, thanks for the information above. Do you have move information > regarding this configuration? do you still encounter problems? > > > On Monday, October 13, 2003 9:59 PM "Joe Zendle" <[EMAIL PROTECTED]> > wrote: > > > We had the same problem w/ TC 4.1.27, sun jvm 1.4.2 and redhat 9. The > > thing wouldn't work for more than about 12 hours. IMHO, there are some > > fundamental problems with tomcat as of late. Hate to say it but we > > solved the problem by throwing away tomcat and using jetty! We are very > > pleased so far. Jetty is very fast and about 1/3 the memory footprint. > > > > Good luck. > > > Hi Joe, > Thanks for sharing the info, I am considering what you suggest as well. > As a last try before moving away from Tomcat, I'm trying out the suggestion > from Ryan above. > Regards, > Noam. > > > > - > 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]
solution problems with ssl client authentication
Hello, Here's the solution for some major problems, which i expirienced getting client authentication to work. I'll post it to help people save time. It cost me more than a week to get it working and the solution is so simple it can be done in less than half an hour. Problem 1 getting excisting certificates in keystore If you already have a ca,client and server certificate this is what to do: openssl pkcs12 -export -in servercert.crt -inkey mykey.key -out servercert.p12 -name tomcat -CAfile myCA.crt -caname root -chain this is the only command that works, trust me i've tried a lot to ;-) than set in server.xml in ssl connector keystoreType =PKCS12 Problem 2 certificate is not trusted on the net all sorts of solutions are given, but this is the only one I got working. The only solution is adding manually with a program like keytool or keyman the CA certificate of the client to JAVA_HOME\jre\lib\security\cacerts creating truststore, adding CATALINA_OPTS="-Djavax.net.ssl.trustStore=PATH_TO_TRUSTSTORE -Djavax.net.ssl.trustStorePassword=PASSWORD_FROM_TRUSTSTORE" didn't work for me Hope it helps a lot of people, Twan
Redirecting multiple virtualhosts from apache to tomcat
Hi, I've installed tomcat 4.1.27, mod_jk1.2.4 and Apache 2.0.40. Since I'm using several virtual hosts in apache and all should access servlets I try to configure the server.xml that, for example, the tomcat-examples can be accessed from all virtualhosts. Unforunately it's only possible to access them either via http://localhost/examples or when I manualy duplicate the vitualhost-entry in the mod_jk.conf and change the Virtualhost to 192.168.100.200 (the main serveradress). How do I have to change the server-xml, that my main-adress (the .200) and my two virtualhosts (.201 and .202) get the examples when I type htttp://192.168.100.201 into my browser? An example would be very helpfull. Thanks in advance Lutz - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: shared/classes folder
> In order to "share" objects between webapps, you need a common > repository. This is what shared/classes or shared/lib is for in tomcat, > and that's why there's only one copy there. This is correct behavior. (Yoav Shapira) Oh. I didn't know about that. Are there any docs about this? I'd like to see more. > Personally, I'd suggest you put everything under > WEB-INF to keep your webapp self-contained and portable (Yoav Shapira) Self-containment is absolutely required, because the apps are to be deployed in different servers (therefore making the shared/classes folder unusable). > Anything you need to exchange with > outside apps can be done in a variety of other ways, e.g. XML documents, > pinging URLs, JMS messages... (Yoav Shapira) I'm using XML. I don't know JMS messages, but i'm glad you mentioned it, i'll see more... Thanks for your help! Best regards, Carlos Pereira - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: TC5 ssl form-based authentication & mozilla
On 10/15/2003 10:32 AM Remy Maucherat wrote: With this security: SSL 4 Login /login.do user admin CONFIDENTIAL when I try to login to my login.do mapping, in mozilla I get repeated login requests from tomcat. The first time twice only, the 2nd time 5 times, 3rd time 10 times etc etc. I can see from my logging that the realm login is successful, but tomcat keeps giving the login page as stated. This does not happen in IE6 or lynx, in which the login works as normal. Has anybody else experienced this? Did you get correctly switched to SSL mode ? Yes. I have reduced the webapp to a minimum and bundled it in a war at http://www.cyberspaceroad.com/test.war (right click it & "save target as...") if you want to see what I'm doing. It contains the struts.jar and is therefore 0.85MB. If you don't have broadband I can bundle it without the jars too. Sometimes the ssl form-based authentication loops on the login page, and sometimes it gives the "invalid direct reference" error. As mentioned above, the non-SSL normal form-based login works fine. In IE6 it works fine too. Rgds Adam -- struts 1.1 + tomcat 5.0.12 + java 1.4.2 Linux 2.4.20 RH9 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: TC5 ssl form-based authentication & mozilla
Adam Hardy wrote: I have set this up with the minimum configuration possible to try to find the problem. 1 JSP, one Struts action mapping, 1 servlet mapping, and the tomcat realm - no SSO, no filters, no templates, no SSL-redirection. With this security: SSL 4 Login /login.do user admin CONFIDENTIAL when I try to login to my login.do mapping, in mozilla I get repeated login requests from tomcat. The first time twice only, the 2nd time 5 times, 3rd time 10 times etc etc. I can see from my logging that the realm login is successful, but tomcat keeps giving the login page as stated. This does not happen in IE6 or lynx, in which the login works as normal. Has anybody else experienced this? Did you get correctly switched to SSL mode ? -- x Rémy Maucherat Senior Developer & Consultant JBoss Group (Europe) SàRL x - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: mod_jk binary for Solaris 9
Take a look at http://www.johnturner.com/ - Original Message - From: "Kellam, Jeannie K Priest" <[EMAIL PROTECTED]> To: "Tomcat Users List" <[EMAIL PROTECTED]> Sent: Tuesday, October 14, 2003 9:42 PM Subject: mod_jk binary for Solaris 9 Hi, Does anyone have a Solaris 9 (sparc) binary for mod_jk available to share? If not, can anyone provide instructions from their experience building mod_jk for Solaris 9? That's for apache-1.3. Thanks, Jeannie - 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 using realm to connect to a database
Peter Ivarsson wrote: I get this error. Catalina.start: LifecycleException: Exception opening database connection: java.sql.SQLException: twz1.jdbc.mysql.jdbcMysqlDriver LifecycleException: Exception opening database connection: java.sql.SQLException: twz1.jdbc.mysql.jdbcMysqlDriver Useing driver com.mysql.jdbc.Driver version 3.09 MySQL version 3.23.38 Tomcat version 4.1.24 I have put the folowing rows into the server.xml: driverName="com.mysql.jdbc.Driver" connectionName="XXX" connectionPassword="" connectionURL="jdbc:mysql://localhost:3306/estid2" userTable="admins" userNameCol="user_name" userCredCol="user_pass" userRoleTable="user_roles" roleNameCol="role_name" /> Are you sure of your configuration? There used to be 2 jdbc drivers for MySQL, the twzl driver, and Mark Matthews mm driver. twzl stopped being maintained (IIRC), and the mm driver became the 'official' driver. Do you have both drivers visible to the classloader? If so, it looks as though it's choosing the wrong one. Delete (or move out of harms way) the twzl driver, and see if things improve. HTH Martin - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]