Re: how to change to Tomcat work directory

2003-07-31 Thread Jon Wingfield
You should be able to set this by modifying your server.xml and all .xml files: Set the "workDir" attribute for your Host (or for the individual Contexts) http://jakarta.apache.org/tomcat/tomcat-4.1-doc/config/host.html http://jakarta.apache.org/tomcat/tomcat-4.1-doc/config/context.html Set the "

Re: [ot] RE: Bugs, Issues, Tasks, Patches, CVS integration - whichis the best tool

2003-07-29 Thread Jon Wingfield
+1 Reynir Hübner wrote: Scarab. Check out www.tigris.org It's excellent. hope it helps -reynir -Original Message- From: Donie Kelly [mailto:[EMAIL PROTECTED] Sent: 29. júlí 2003 12:55 To: 'Tomcat Users List' Subject: [ot] RE: Bugs, Issues, Tasks, Patches, CVS integration - which is

Re: application scope variable lost

2003-07-28 Thread Jon Wingfield
Even though your Servlet is loaded on startup the container (ie tomcat) is free to unload and reload servlets at any time. This is why it is so much better (IMO) to use ServletContextListeners for application configuration. Does your servlet create empty maps even if they already exist on the c

Re: Session persistance after server restart: a bug?

2003-07-24 Thread Jon Wingfield
Not a bug. Standard behaviour. Chack out the Manager element in the server.xml http://jakarta.apache.org/tomcat/tomcat-4.1-doc/config/manager.html If you haven't got a Manager explicitly added in the server.xml a default is used (stores serialized sessions in a file SESSIONS.ser under the work

Re: Problems compiling tomcat

2003-07-23 Thread Jon Wingfield
It is finding the jar, otherwise you'd be having a completely different error message. ;) The error implies you are compiling against a different version of the commons-fileupload component than the 4.1.24 src was written against. The 4.1.24 binary release bundled commons-fileupload-1.0-beta-1.j

Re: Servlet Context Listener problem...

2003-07-15 Thread Jon Wingfield
Is that the entirety of your web.xml? The error looks like the parser can't find the definition of the "listener" element, it hasn't even got to the point of worrying about element order yet. Have you got an xml prolog and a doctype at the top of the file? eg: "http://java.sun.com/dtd/web-app_

Re: JSPs not compiling

2003-07-10 Thread Jon Wingfield
Ok. Looks like you're running a JRE on Solaris. Jsp compilation requires a JDK installation. As to the "exception above was detected in native code outside the VM" error; have you installed the OS patches required for that version of java? http://java.sun.com/j2se/1.3/install-patches.html Thom

Re: getting a reply like this.

2003-06-19 Thread Jon Wingfield
I may be wrong but... This list knows nothing (as such) about [EMAIL PROTECTED] Here's what i believe is happening: 1) You post to the list. 2) List delivers said post to all subscribers. One subscriber is, say, [EMAIL PROTECTED] 3) The Mail Daemon/Post Master at logicaonline.com rejects the post

Re: [redirecting startup exception trace to a file]

2003-06-12 Thread Jon Wingfield
adding > out.txt only redirects std out. You need to redirect std err, which in dos, i think, is 2> err.txt so: catalina.bat run > out.txt 2> err.txt should do what you want. Also on windows 2000 you should be able to set the dos window buffer to, say, . Then the exceptions won't scroll off

Re: open source code and IDE

2003-05-30 Thread Jon Wingfield
You could also take a look at JEdit (www.jedit.org). It's a free, open source java ide that has a community writing plug-ins to do most of the things mentioned in previous posts. :) [EMAIL PROTECTED] wrote: thanks for the replies u got me going , although the IDE looks sweet , similar to PHPEdit

Re: PDF over https in MSIE problem

2003-04-02 Thread Jon Wingfield
We had this for content types that IE didn't know about, including application/x-zip-compressed and application/octet By default we have a filter which sets cache headers for everything: httpResponse.setHeader("Cache-Control", "no-cache"); httpResponse.setHeader("Pragma", "no-cache"); For the

Re: Scrollable Tomcatserver window

2003-03-26 Thread Jon Wingfield
nope. That'll be an NT, XP, 2000 feature. ;) Set up your web applications to use log4j (or some other logging package). Convert all System.out.println(...), System.err.println(...), e.printStackTrace() calls etc to use the logging. You won't need to look at the DOS window any more. Also, there

Re: Browser got incomplete html

2003-03-24 Thread Jon Wingfield
Have a look in the tomcat log files. Either catalina.out or localhost_log..txt. I'll bet there's an exception in one of those. If a jsp scriptlet or custom tag throws an uncaught exception Tomcat may not be able to forward to any predefined error pages because part of the response has already been

Re: Possible to have default classes and taglib includes in JSPs?

2003-03-19 Thread Jon Wingfield
You can do a static include of a page which has your default imports: <%@ include file="/a_load_of_imports.jsp" %> Tim Funk wrote: No - you have to explicitly import the classes and/or taglibs. -Tim Gavin, Rick wrote: Hi all, Does anyone know if you can include classes and taglibs in all jsp

Re: Ejectute a method on an object instance when session is deactivated.

2003-03-17 Thread Jon Wingfield
I think in servlet spec 2.4 there is an event generated just before the session is invalidated. Until then: I implemented a HttpSessionAttributeListener. When a session is about to be invalidated all its attributes are removed. So, if you have an attribute which lasts for the lifetime of the se

Re: Running Tomcat on Win XP

2003-03-14 Thread Jon Wingfield
This is a wild stab in the dark but here goes. How much RAM have you got in your XP box? Is the compilation of the jsp/jsps by ant running out of memory? (I think the compilation is out-of-process, but i may be wrong.) If you think you have enough memory then play around with the -Xms and -Xmx

Re: class not found in application designed for 3.x, running on 4.1.18

2003-03-13 Thread Jon Wingfield
Try changing the filename from jsafe.zip to jsafe.jar. The classloader used for the lib directories only picks up jar files, not zip files. HTH, Jon Seeling Thomas wrote: Hallo, I am using a commercial application which now has a servlet interface in its latest version (Tivoli Framework 4.1).

Re: Setting javax.net.ssl.trustStore

2003-03-12 Thread Jon Wingfield
What happens if you also set -Djavax.net.ssl.keyStore=c:\... -Djavax.net.ssl.keyStorePassword=password Mayne, Peter wrote: I have an application running in Tomcat 4.1.18 using JDK 1.4.1 on Windows XP that makes connections to "https://...";. If I add the web server's certificate's CA to JAVA_HO

Re: Problem : Tomcat can't compile a JSP.

2003-03-07 Thread Jon Wingfield
Ah. That rings a bell. You could be running into the problem where for large pages the generated java method _jspService(...) is too long (>32k, i think) and the compilation fails. The use of a lot of custom tags REALLY bumps up the size of the generated java code. In jasper 2 (used in 4.1.x) t

Re: java.lang.NoClassDefFoundError

2003-03-05 Thread Jon Wingfield
Looks like you've using OpenEJB ;) The OpenEJB distro comes with a war file, which looks like it's been expanded to a context by your tomcat install. However, the war file doesn't contain the required OpenEJB jar files (which probably need to be put in common/lib or server/lib). The class file

Re: Tomcat on WinXP

2003-03-04 Thread Jon Wingfield
Your jdk is installed at c:\jdk1.4.1 but your echo says c:\jdk1.4 Is that a typo? Denise Mangano wrote: Thanks everyone for answering. I changed my JAVA_HOME to c:\jdk1.4.1 and restarted Tomcat. I still get the same error. The exact error in the log file is: Unable to find a javac compiler;com.s

Re: Installation - Tomcat 4.1 - Windows 2K

2003-03-04 Thread Jon Wingfield
My dev machine is XP. I haven't set an explicit classpath and everything works fine. So long as JAVA_HOME is set correctly to a JDK installation everything is sweet. Tomcat has all the jars it needs to compile jsp files. I read the link. It says to set the classpath so that DEVELOPERS can compi

Re: Objects in JSP PLEASE HELP.

2003-03-04 Thread Jon Wingfield
Given the way your page is currently set up, this should work: EditorContent content = (EditorContent)pageContext.getAttribute("content"); I can't remember exactly how the TagExtraInfo stuff works but have a look at the compiled jsp (the .java src file) in tomcat's work directory. It may ha

Re: Mime-Type

2003-03-03 Thread Jon Wingfield
A compiled jsp is a servlet. The content returned from a servlet can be pretty much anything ;) Most likely the returned content will be text/html Anthony Smith wrote: I did not know where ask to else this question. Is there a mime-type for a jsp? If so, what is it? ---

Re: locale

2003-02-28 Thread Jon Wingfield
And if, for example, you have a UK-en application hosted in a data centre in Germany... Drew Sudell wrote: Yes, but this is an per-instance attribute, isn't it? How could I make it be set in all f Tomcat's VMs? Maybe a java "-D" option? On Thu, 2003-02-27 at 14:38,

Re: Proxy

2003-02-27 Thread Jon Wingfield
try setting the following system properties: *http.proxyHost* *http.proxyPort* http://java.sun.com/j2se/1.4/docs/guide/net/properties.html Alberto A C A S Magalhães wrote: ** Este email assim como os ficheiros que possa ter em an

Re: locale

2003-02-27 Thread Jon Wingfield
via a static method on java.util.Locale. In your case the Locale call will be Locale.setDefault(new Locale("br", "PT")); You may also want to set the TimeZone in a similar manner. Felipe Schnack wrote: How can i set the default locale of my application? There is a system property to do that? I

Re: Performance .. Jsp compile import wildcards

2003-02-27 Thread Jon Wingfield
http://www.javaworld.com/javaworld/javaqa/2001-04/01-qa-0406-import.html Reynir Hübner wrote: Hi, I'm wondering what kind of performance decrease (if any) it has to use wildcards in jsp import lines. example : <%@ page import="java.util.*" %> .. but not : <%@ page import="java.util.ArrayL

Re: Filter - ServletContext

2003-02-27 Thread Jon Wingfield
Try: sctx.getInitParameter(...) instead of sctx.getAttribute(...) Günter Kukies wrote: Hello, I want to read some context-param from web.xml within a filter. But the getAttribute is always null. There is no problem to get the same context-param within a Servlet. Thanks Günter Here is the c

Re: crontab problems

2003-02-27 Thread Jon Wingfield
For jdk1.4 you should be able to set the networkaddress.cache.negative.ttl system property to control this. (Assuming the lookups are made using the java.net.* sub-system) http://java.sun.com/j2se/1.4/docs/guide/net/properties.html http://java.sun.com/j2se/1.4.1/networking-relnotes.html We're st

Re: Servlet produces HTML .. how do i pass attributes in the sessionobject ?

2003-02-14 Thread Jon Wingfield
According to the j2se javadocs neither keys nor values in a Hashtable can be null. It looks like the variable hs returned from getFruits(...) is null... HTH, Jon Mufaddal wrote: Hi ... in my doPost() I do some processing and then I do HashSet hs = getFruits(userName);

Re: error page for error code 500?

2003-02-04 Thread Jon Wingfield
If you are trying to generate a 500 by accessing a url outside a context then the error page defined within the context won't get triggered. Where are you putting your error-page tags? You could try altering the web.xml in tomcats conf directory... [EMAIL PROTECTED] wrote: Thank you for the re

Re: java.io.IOException - whats up?

2003-01-29 Thread Jon Wingfield
Just a thought. Have you set your CATALINA_TMPDIR environment variable? Its default value is $CATALINA_BASE/temp which doesn't exist by default ;) klavs klavsen wrote: Hi guys, I've gotten help from John Turner on this problem of mine (where /manager works, and /admin gives me a 404. The error

Re: about singletons (ot)

2003-01-28 Thread Jon Wingfield
Did someone say Booch utility? http://www.javaworld.com/javaworld/jw-04-1999/jw-04-toolbox.html see page 2. Actually, this entire set of articles on threading is excellent. Felipe Schnack wrote: These days I was thinking It's not so uncommon to have uses for singleton classes in our everyda

Re: servlets

2003-01-28 Thread Jon Wingfield
Problem with serialization: 1) Client asks for singleton from webapp and stores it as an instance variable. 2) Client get serialized to some persistance store (db, jms message queue, whatever) 3) webapp goes away (dies, gets shutdown, whatever) 4) webapp restored 5) Client deserialized. Which ve

Re:

2003-01-28 Thread Jon Wingfield
Are you using log4j? If you are then chack out the org.apache.log4j.net.SMPTAppender. It sends a mail each time a message of the required severity is logged. http://jakarta.apache.org/log4j/docs/api/org/apache/log4j/net/SMTPAppender.html example of log4j.properies portion for this appender: lo

Re: WAP?

2003-01-03 Thread jon . wingfield
Just googled "serving wml from tomcat" and this article was one of the first: http://www.javaworld.com/javaworld/javatips/jw-javatip123.html HTH, Jon Quoting Vano Beridze <[EMAIL PROTECTED]>: > Hello > > I would like to serve WAP clients from my existing WEB App > > Could you please provide m

RE: "Naive question" thread

2002-12-19 Thread jon wingfield
i use pstree -aup. Very useful with multiple java apps running on one server :) -Original Message- From: Milt Epstein [mailto:[EMAIL PROTECTED]] Sent: 18 December 2002 20:15 To: Tomcat Users List Subject: "Naive question" thread Saw a post in the "naive question" thread earlier today th

RE: How do you select to call doPost or doGet method of servlet?

2002-12-03 Thread jon wingfield
although you can, in theory, wrap the original request in a javax.servlet.http.HttpServletRequestWrapper with getMethod() overridden to return the required value. (If you want to) -Original Message- From: news [mailto:[EMAIL PROTECTED]]On Behalf Of Bill Barker Sent: 03 December 2002 07:5

RE: NoSuchMethodError

2002-11-27 Thread jon wingfield
The compiled tomcat code (class org.apache.catalina.session.StandardSession) is calling a method not available at runtime. That probably means that the tomcat code was compiled with a later version of either the jdk or the servlet jars than the version you are running tomcat with. I've just browsed

RE: OFF-TOPIC: testing

2002-10-30 Thread jon wingfield
Or you could use the mockobjects project (www.mockobjects.com) to write JUnit testcases which require no physical database connection. You can set up the sql statements you expect your code to execute and the data you expect to be returned. Using mock objects you can also simulate database failure

RE: REPOST: How to use JspC with ANT

2002-10-22 Thread jon wingfield
We're still using 4.0.x in production. We use(d) an ant/jspc target and got the same error message. It went away when I forked the java process: ... ;) -Original Message- From: Felipe Schnack [mailto:felipes@;ritterdosreis.br] Sent: 22 October 2002 12:17 To: Tomcat Users List Subject: R

RE: Error with multipartParser

2002-10-16 Thread jon wingfield
be, is there a default somewhere that I'm missing? cheers S >From: "jon wingfield" <[EMAIL PROTECTED]> >Reply-To: "Tomcat Users List" <[EMAIL PROTECTED]> >To: "Tomcat Users List" <[EMAIL PROTECTED]> >Subject: RE: Error with multipartP

RE: Unable to compile JSP

2002-10-14 Thread jon wingfield
is WEB_INF a typo? it needs to be WEB-INF -Original Message- From: Shanniew [mailto:[EMAIL PROTECTED]] Sent: 14 October 2002 08:04 To: [EMAIL PROTECTED] Subject: Unable to compile JSP I have already set the JAVA_HOME, CATALINA_HOME. \webapps\myjsp\WEB_INF\classes \webapps\myjs

RE: Error with multipartParser

2002-10-11 Thread jon wingfield
tomcat doesn't use the classpath. It derives where tools.jar is from the JAVA_HOME environment variables. Your application classes should be placed under CATALINE_HOME/webapps/YOUR_WEBAPP_NAME/WEB-INF/classes and your application jar files (ie cos.jar) under CATALINE_HOME/webapps/YOUR_WEBAPP_NAME/

RE: XMLMapper:Can't find resource for entity error

2002-10-09 Thread jon wingfield
your web.xml file for the xsltExample webapp refers to the servlet 2.3 specification dtd and you are running tomcat 3.x which is an implementation of the servlet 2.2 specification. Tomcat has a cached version of the dtd in one of the jar files that are part of the distribution. This is in case the

RE: error with doUpload() in bean

2002-10-09 Thread jon wingfield
It's a ClassNotFoundException wrapped by a ServletException then a JasperException. The classloader can't find com.oreilly.servlet.MultipartRequest class (and probably the o'reilly jar) at runtime. -Original Message- From: Sam Seaver [mailto:[EMAIL PROTECTED]] Sent: 08 October 2002 22:46

RE: Action on close

2002-10-07 Thread jon wingfield
You can't rely on the destroy() method on the servlet for this purpose. The container has the right to unload servlets when it chooses as a part of resources management. If you are using a servlet 2.3 spec container use the ServletContextListener as Jake suggests. Death to all load on startup se

RE: Tomcat stop when exit telnet session

2002-10-04 Thread jon wingfield
I've never used solaris8 so the following may be in error, but here goes. On linux using & seems not only to put the process in the background but also seems to be nohup (no hang up). On hp-ux 10/11 using & seems only to put the process in the background and NOT nohup. So, i surmise that solaris

RE: Getting the name of the context

2002-10-04 Thread jon wingfield
you could extract it from servletContext.getRealPath("/"); -Original Message- From: shanmugampl [mailto:[EMAIL PROTECTED]] Sent: 04 October 2002 12:51 To: [EMAIL PROTECTED] Subject: Getting the name of the context Hi, I have a requirement where i need to know the name of the context

RE: Does anybody know ?- error 500

2002-10-03 Thread jon wingfield
Compiled Code) at java.lang.Thread.run(Compiled Code) -Original Message- From: jon wingfield [mailto:[EMAIL PROTECTED]] Sent: Thursday, October 03, 2002 12:21 PM To: Tomcat Users List Subject: RE: Does anybody know ?- error 500 Two stabs in the dark: Does the user running tomcat have writ

RE: Does anybody know ?- error 500

2002-10-03 Thread jon wingfield
Two stabs in the dark: Does the user running tomcat have write permissions to the work directory? Out of disk space on the /var/tomcat/work/ filesystem? -Original Message- From: Skorupski Paweł ,(PZUZ) [mailto:[EMAIL PROTECTED]] Sent: 03 October 2002 11:05 To: '[EMAIL PROTECTED]' Subject:

RE: non-static method cannot be referenced from static context error

2002-10-03 Thread jon wingfield
The oreilly MultipartRequest uses DefaultFileRenamePolicy as, funnily enough, a default when constructing as you have it in your code. Later versions of the API (since 9thMay02) have overloaded constructors where you can specify the FileRenamePolicy. The policy is asked to rename the file before

RE: problem using MultipartParser and MultipartRequest together

2002-10-02 Thread jon wingfield
Have you seen: http://www.servlets.com/cos/javadoc/com/oreilly/servlet/multipart/FileRename Policy.html http://www.servlets.com/cos/javadoc/com/oreilly/servlet/multipart/DefaultFil eRenamePolicy.html We use an implementation of FileRenamePolicy when instantiating the MultipartRequest. This may be

RE: problem using MultipartParser and MultipartRequest together

2002-10-02 Thread jon wingfield
Have you seen: http://www.servlets.com/cos/javadoc/com/oreilly/servlet/multipart/FileRename Policy.html http://www.servlets.com/cos/javadoc/com/oreilly/servlet/multipart/DefaultFil eRenamePolicy.html We use an implementation of FileRenamePolicy when instantiating the MultipartRequest. This may be

RE: HTTP status 500 on a SOAP call

2002-09-26 Thread jon wingfield
you've got a NullPointerException at line 35 of RPCRouterServlet. Have a look at javadoc or java source for that class. Your request is probably not passing some parameter the servlet requires (as a best guess). Tomcat returns an html error report and the soap client is expecting a response with a

RE: Retrieving ServletContext Objects via PageContext

2002-09-24 Thread jon wingfield
The following will work: pageContext.getServletContext().getAttribute("dbPool"); -Original Message- From: Jason Johnston [mailto:[EMAIL PROTECTED]] Sent: 24 September 2002 17:25 To: <"Tomcat Users List" Subject: Retrieving ServletContext Objects via PageContext This may be a stupid que

RE: Dumb Question com.justatest.test.MyServlet error

2002-09-21 Thread jon wingfield
Open the InitSnoop.java source file. If the first line is not: package com.justatest.test; then that is your problem. The directory structure under WEB-INF/classes maps to the package stucture of your servlet and other java classes deployed in the webapp. Change the package name to the right on

RE: Which Tomcat version for production environment ?

2002-09-20 Thread jon wingfield
You've had 4.0.4 in a test environment and is stable. Deploy it. It's the most stable of the 4.0.x tomcat tree. Then put 4.1.x in the test environment and if is stable after system/uat testing migrate your production environment to that release of tomcat. There are a number of implementation cha

RE: RE: Reloading .jsp-Pages

2002-09-18 Thread jon wingfield
the version before. i deleted the file, restarted the server, got my 404, copied the file again, restarted the server. guess: still from server-cache... i guess the 'reloadable'-switch doesnt work for some reason... -Ursprüngliche Nachricht- Von: jon wingfield [mailto:[EMAIL PROT

RE: RE: Reloading .jsp-Pages

2002-09-18 Thread jon wingfield
... and if you are only changing included files then touch the jsp doing the include -Original Message- From: Dominik Jednoralski [mailto:[EMAIL PROTECTED]] Sent: 17 September 2002 13:47 To: Tomcat User Help Subject: RE: RE: Reloading .jsp-Pages thats the point: it doesn't recompile eve

RE: line feeds in response

2002-09-09 Thread jon wingfield
There are 3 linefeeds in your jsp before the code that generates the xml. Remove them and you should be ok. There has been a discussion on this before on this list. Search the archives :) -Original Message- From: Alexander Stage [mailto:[EMAIL PROTECTED]] Sent: 09 September 2002 12:12 To:

RE: Still need help w. Tomcat installation

2002-09-09 Thread jon wingfield
No trailing semi-colon. No trailing slash. :) -Original Message- From: STEVE BURRUS [mailto:[EMAIL PROTECTED]] Sent: 08 September 2002 20:53 To: [EMAIL PROTECTED] Subject: Still need help w. Tomcat installation I STILL need some degree of help/assistance from someone in this newsgroup

RE: error accessing a context-param from web.xml

2002-09-04 Thread jon wingfield
The error you are getting is the JSP parser mistaking the data "<%= application.getInitParameter(" as the value for the driver parameter of the sql:setDataSource tag. Then it reports a parsing error as the next parameter is sees is jdbc.driver with no '=', and hence no value, after it. If you rea

RE: OFF-TOPIC: Pointers to CallableStatement docs?

2002-08-20 Thread jon wingfield
John, I've dug out some old code and i think you may have to set initial values for the OUT parameters as well. We used functions with oracle 8i with no problems in this way: One of the CallableStatements we prepared with "{?=call pk_housekeeping.f_purge_inactive_consumers(?)}" and used as below:

RE: problem..plz help me out

2002-06-10 Thread jon wingfield
Puneet, Fairly certain that puneet has to be either a bona fide DNS name (or for development an alias in your hosts file) Jon -Original Message- From: puneet sachar [mailto:[EMAIL PROTECTED]] Sent: 08 June 2002 20:22 To: Xinji Gu Subject: problem..plz help me out Hi friends, this is m

RE: context param is null outside doGet

2002-06-08 Thread jon wingfield
With out looking at the HttpServlet source to confirm i would guess that: In servlet 2 the member variable basepath is assigned a value after the super class (HttpServlet) constructor returns but before the servlets init(...) method is called by the servlet container. Therefore at the time of assi

RE: tomact not staring

2002-06-05 Thread jon wingfield
change the memory settings for the DOS console. When I run TC under windows I have the initial environment memory set to 4096 (the maximum available through the UI). -Original Message- From: puneet sachar [mailto:[EMAIL PROTECTED]] Sent: 05 June 2002 07:06 To: Tomcat Users List Subject: t

RE: How to redirect the log file from the command window to a file?

2002-05-02 Thread Jon Wingfield
1) alter the catalina.bat file: ... extract ... %_EXECJAVA% %JAVA_OPTS% %CATALINA_OPTS% %DEBUG_OPTS% -Djava.endorsed.dirs="%JAVA_ENDORSED_DIRS%" -classpath "%CLASSPATH%" -Dcatalina.base="%CATALINA_BASE%" -Dcatalina.home="%CATALINA_H OME%" -Djava.io.tmpdir="%CATALINA_TMPDIR%" %MAINCLASS% %CMD_LINE

RE: NullPointerException when using JDBC ResultSet next() method

2002-04-09 Thread Jon Wingfield
Maybe reading the code wrong but you're declaring the variable rs on the third line of doGet(...) but putting the return value of the stmt.executeQuery() in a variable called rset. Then you call next() on the original variable, which is null ;) A few other points: You are definately loading the d

<    1   2   3