JAAS

2005-07-11 Thread ronald
I've been trying to get the JavaWorld example located at
http://www.javaworld.com/javaworld/jw-03-2005/jw-0307-captcha.html

On tomcat v5.5.9 (JDK 1.5) on Linux without any luck. It goes through
the authentication process and reports it's assigned the anonymous
principle but when I go to access the protected directory again it
prompts for the login.jsp page again. 


Any ideas guys 


Thanks 

Ron 







-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Retry, problems using j2ee JMS in Tomcat 4.x.x

2002-10-24 Thread Ronald Haring
Hi all,

Using win2k, JDK1.3.1, J2ee1.3.1.

I have created a small JMS system to generate pdf files. I created a very
short test servlet.
In tomcat 3.2.3 my queue is found. In tomcat 4.0.4 and 4.1.12 I get the next
error:

NamingException
javax.naming.NameNotFoundException: Name QueueConnectionFactory is not bound
in
this Context
at org.apache.naming.NamingContext.lookup(NamingContext.java:811)
at org.apache.naming.NamingContext.lookup(NamingContext.java:181)
at org.apache.naming.NamingContext.lookup(NamingContext.java:822)
at org.apache.naming.NamingContext.lookup(NamingContext.java:181)
at org.apache.naming.NamingContext.lookup(NamingContext.java:822)
at org.apache.naming.NamingContext.lookup(NamingContext.java:194)
at org.apache.naming.SelectorContext.lookup(SelectorContext.java:183)
at javax.naming.InitialContext.lookup(InitialContext.java:350)

My code is :

protected void handle(HttpServletRequest request, HttpServletResponse
response) throws ServletException, IOException {
   try {
  // Create the initial context
  Context ctx = new InitialContext();
  Hashtable env = ctx.getEnvironment();
  Enumeration enum = env.keys();
  while (enum.hasMoreElements()) {
 String key = (String) enum.nextElement();
 System.out.println(key +  =  + env.get(key));
  }
  QueueConnectionFactory queueConnectionFactory = null;
  Queue queue = null;
  try {
 // The next definition works in tomcat 3.2.3
 queueConnectionFactory = (QueueConnectionFactory)
ctx.lookup(QueueConnectionFactory);
 queue = (Queue) ctx.lookup(generatePDF);
 // The next definition doesnt work in either tomcat
 //queueConnectionFactory = (QueueConnectionFactory)
ctx.lookup(java:comp/env/QueueConnectionFactory);
 //queue = (Queue) ctx.lookup(java:comp/env/generatePDF);
 System.out.println(Found the queue generatePDF);
  }
  catch (NamingException e) {
 System.out.println(NamingException);
 e.printStackTrace();
  }
  // Close the context when we're done
  ctx.close();
   }
   catch (NamingException e) {
  System.err.println(Problem  + e);
   }
}


And here is my JmsDestination and JmsFactory listing:
D:\jakarta-tomcat-4.0.4\binj2eeadmin -listJmsDestination
JmsDestination
--
 JMS Destination : sendPDF , javax.jms.Queue 
 JMS Destination : jms/Topic , javax.jms.Topic 
 JMS Destination : jms/Queue , javax.jms.Queue 
 JMS Destination : generatePDF , javax.jms.Queue 
D:\jakarta-tomcat-4.0.4\binj2eeadmin -listJmsFactory
JmsFactory
--
 JMS Cnx Factory : QueueConnectionFactory , Queue , No properties 
 JMS Cnx Factory : jms/TopicConnectionFactory , Topic , No properties 
 JMS Cnx Factory : TopicConnectionFactory , Topic , No properties 
 JMS Cnx Factory : jms/QueueConnectionFactory , Queue , No properties 
D:\jakarta-tomcat-4.0.4\bin

After running the servlet on 3.2.3 I get 2 errors for loading ejb and
security.properties file, but after that it prints the following for the
enumeration
on the context:
java.naming.corba.orb = com.sun.enterprise.iiop.POAEJBORBa49e0

and for tomcat 4.0.4
java.naming.factory.initial = org.apache.naming.java.javaURLContextFactory
java.naming.factory.url.pkgs = org.apache.naming:com.sun.enterprise.naming

So here is a big difference. The one from 3.2.3 appears to be an instance of
a class
whereas the ones from 4.0.4 are just string representations of classes to
load.

Now how can I activate my Jms system, in order for Tomcat 4.0.4 to find it?
Or what should I do so Tomcat will be able to find my queues and use them?





Re: Retry, problems using j2ee JMS in Tomcat 4.x.x

2002-10-24 Thread Ronald Haring
Thanks for your answer Jean-Francois.
The QueueConnectionFactory indeed isnt defined in my web.xml environment
tags. I will see if I can find a good j2ee list to help me get along on the
road, but thx for tips

Gr
Ronald

- Original Message -
From: Jean-Francois Arcand [EMAIL PROTECTED]
To: Tomcat Users List [EMAIL PROTECTED]
Sent: Thursday, October 24, 2002 23:31
Subject: Re: Retry, problems using j2ee JMS in Tomcat 4.x.x


 OK I will give a try. I think you have to define your

 QueueConnectionFactory

 in your web.xml file in order. Is it the case? Look at the Servlet Spec
for more info:

 http://jcp.org/aboutJava/communityprocess/first/jsr154/

 Specifically in the DTD section. Also, maybe a j2ee related list might be
the place to have a faster answer ;-)

 -- Jeanfrancois



 Ronald Haring wrote:

 Hi all,
 
 Using win2k, JDK1.3.1, J2ee1.3.1.
 
 I have created a small JMS system to generate pdf files. I created a very
 short test servlet.
 In tomcat 3.2.3 my queue is found. In tomcat 4.0.4 and 4.1.12 I get the
next
 error:
 
 NamingException
 javax.naming.NameNotFoundException: Name QueueConnectionFactory is not
bound
 in
 this Context
 at org.apache.naming.NamingContext.lookup(NamingContext.java:811)
 at org.apache.naming.NamingContext.lookup(NamingContext.java:181)
 at org.apache.naming.NamingContext.lookup(NamingContext.java:822)
 at org.apache.naming.NamingContext.lookup(NamingContext.java:181)
 at org.apache.naming.NamingContext.lookup(NamingContext.java:822)
 at org.apache.naming.NamingContext.lookup(NamingContext.java:194)
 at org.apache.naming.SelectorContext.lookup(SelectorContext.java:183)
 at javax.naming.InitialContext.lookup(InitialContext.java:350)
 
 My code is :
 
 protected void handle(HttpServletRequest request, HttpServletResponse
 response) throws ServletException, IOException {
try {
   // Create the initial context
   Context ctx = new InitialContext();
   Hashtable env = ctx.getEnvironment();
   Enumeration enum = env.keys();
   while (enum.hasMoreElements()) {
  String key = (String) enum.nextElement();
  System.out.println(key +  =  + env.get(key));
   }
   QueueConnectionFactory queueConnectionFactory = null;
   Queue queue = null;
   try {
  // The next definition works in tomcat 3.2.3
  queueConnectionFactory = (QueueConnectionFactory)
 ctx.lookup(QueueConnectionFactory);
  queue = (Queue) ctx.lookup(generatePDF);
  // The next definition doesnt work in either tomcat
  //queueConnectionFactory = (QueueConnectionFactory)
 ctx.lookup(java:comp/env/QueueConnectionFactory);
  //queue = (Queue) ctx.lookup(java:comp/env/generatePDF);
  System.out.println(Found the queue generatePDF);
   }
   catch (NamingException e) {
  System.out.println(NamingException);
  e.printStackTrace();
   }
   // Close the context when we're done
   ctx.close();
}
catch (NamingException e) {
   System.err.println(Problem  + e);
}
 }
 
 
 And here is my JmsDestination and JmsFactory listing:
 D:\jakarta-tomcat-4.0.4\binj2eeadmin -listJmsDestination
 JmsDestination
 --
  JMS Destination : sendPDF , javax.jms.Queue 
  JMS Destination : jms/Topic , javax.jms.Topic 
  JMS Destination : jms/Queue , javax.jms.Queue 
  JMS Destination : generatePDF , javax.jms.Queue 
 D:\jakarta-tomcat-4.0.4\binj2eeadmin -listJmsFactory
 JmsFactory
 --
  JMS Cnx Factory : QueueConnectionFactory , Queue , No properties 
  JMS Cnx Factory : jms/TopicConnectionFactory , Topic , No properties 
  JMS Cnx Factory : TopicConnectionFactory , Topic , No properties 
  JMS Cnx Factory : jms/QueueConnectionFactory , Queue , No properties 
 D:\jakarta-tomcat-4.0.4\bin
 
 After running the servlet on 3.2.3 I get 2 errors for loading ejb and
 security.properties file, but after that it prints the following for the
 enumeration
 on the context:
 java.naming.corba.orb = com.sun.enterprise.iiop.POAEJBORB@a49e0
 
 and for tomcat 4.0.4
 java.naming.factory.initial =
org.apache.naming.java.javaURLContextFactory
 java.naming.factory.url.pkgs =
org.apache.naming:com.sun.enterprise.naming
 
 So here is a big difference. The one from 3.2.3 appears to be an instance
of
 a class
 whereas the ones from 4.0.4 are just string representations of classes to
 load.
 
 Now how can I activate my Jms system, in order for Tomcat 4.0.4 to find
it?
 Or what should I do so Tomcat will be able to find my queues and use
them?
 
 
 
 
 


 --
 To unsubscribe, e-mail:
mailto:tomcat-user-unsubscribe;jakarta.apache.org
 For additional commands, e-mail:
mailto:tomcat-user-help;jakarta.apache.org



--
To unsubscribe, e-mail:   mailto:tomcat-user-unsubscribe;jakarta.apache.org
For additional commands, e-mail: mailto:tomcat-user-help;jakarta.apache.org




Error with new install

2002-11-05 Thread Ronald Aronica
I just installed Tomcat 4.1.12 with JDK 1.4.1 and am running into a 
problem when trying to use the manager. I receive a server error 500 
with the following:
org.apache.jasper.JasperException: Unable to compile class for JSP
An error occurred at line: -1 in the jsp file: null
Generated servlet error:
[javac] Compiling 1 source file
at 
org.apache.jasper.compiler.DefaultErrorHandler.javacError(DefaultErrorHandler.java:120)
at 
org.apache.jasper.compiler.ErrorDispatcher.javacError(ErrorDispatcher.java:293)
at org.apache.jasper.compiler.Compiler.generateClass(Compiler.java:313)
at org.apache.jasper.compiler.Compiler.compile(Compiler.java:324)
at 
org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.java:474)
at 
org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:184)
   etc.
Any ideas as to the problem, and its solution?



--
To unsubscribe, e-mail:   mailto:tomcat-user-unsubscribe;jakarta.apache.org
For additional commands, e-mail: mailto:tomcat-user-help;jakarta.apache.org



Re: Error with new install

2002-11-06 Thread Ronald Aronica
Please disregard as I found the problem by reading the thread 
Installing and using manager app.

Ronald Aronica wrote:

I just installed Tomcat 4.1.12 with JDK 1.4.1 and am running into a 
problem when trying to use the manager. I receive a server error 500 
with the following:
org.apache.jasper.JasperException: Unable to compile class for JSP
An error occurred at line: -1 in the jsp file: null
Generated servlet error:
[javac] Compiling 1 source file
at 
org.apache.jasper.compiler.DefaultErrorHandler.javacError(DefaultErrorHandler.java:120) 

at 
org.apache.jasper.compiler.ErrorDispatcher.javacError(ErrorDispatcher.java:293) 

at org.apache.jasper.compiler.Compiler.generateClass(Compiler.java:313)
at org.apache.jasper.compiler.Compiler.compile(Compiler.java:324)
at 
org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.java:474) 

at 
org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:184) 

   etc.
Any ideas as to the problem, and its solution?



--
To unsubscribe, e-mail:   
mailto:tomcat-user-unsubscribe;jakarta.apache.org
For additional commands, e-mail: 
mailto:tomcat-user-help;jakarta.apache.org






--
To unsubscribe, e-mail:   mailto:tomcat-user-unsubscribe;jakarta.apache.org
For additional commands, e-mail: mailto:tomcat-user-help;jakarta.apache.org




How do I unsubscribe?

2002-11-19 Thread Ronald Aronica
I have tried most everything including sending blank messages to: 
[EMAIL PROTECTED], and 
[EMAIL PROTECTED]; 
and a request to be removed from the list to 
[EMAIL PROTECTED] Nothing seems to work.  What 
should I do? HELP!

Thanks,
Ron Aronica



--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]



Asynchronous messages from servlets

2002-01-22 Thread Ronald Wildenberg

Hi,

I have the following problem. A simple form submits data
to a servlet. The servlet sends a message via JMS to
another application (in another JVM). Once the message
has been sent, the 'service' method of the servlet ends.
After a while, say five seconds, the other application would
like to send back a response. How do I show this response
to the user?

Since the 'service' method has finished after sending the
message, I have lost control over the output from the other
application.

What I need is a way to push the response to the browser. I
would like the server to take the initiative in updating the browser
window, not the user. Is this possible in any way?

Thanks in advance,
Ronald Wildenberg



--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]




SSL with Tomcat/mod_jserv via Apache

2001-07-18 Thread Ronald Ruzicka

Hello,

does anyone know, if it is possible to run SSL on a Tomcat/mod_jserv based
solution connected to Apache-mod_ssl.

Is there a document like TomCat and SSL (which describes a TomCAT/mod_jk
based solution), only for Tomcat/mod_jserv.

Thank you for your help.

Ronald Ruzicka
Simutech
Tel. +43-1-888 36 10-21
Fax  +43-1-888 36 10-49
emailmailto:[EMAIL PROTECTED]
homepage www.simutech.at





RE: RE: SSL with Tomcat/mod_jserv via Apache

2001-07-19 Thread Ronald Ruzicka

Dear John,

The .conf files would be a great help - please can you mail them?

Thanks a lot!

Sincerely,

Ronald Ruzicka
Simutech
Tel. +43-1-888 36 10-21
Fax  +43-1-888 36 10-49
emailmailto:[EMAIL PROTECTED]
homepage www.simutech.at
 

From: John Bazeley 
Subject:  RE: SSL with Tomcat/mod_jserv via Apache
Date:  Thu, 19 Jul 2001 10:32:27 +1200

You can run apache/mod_ssl/mod_jserv/tomcat quite happily. I've got
a box here doing just that. Solaris 2.6/tomcat 3.2/apache 1.3.14/
mod_ssl 2.7.1.

Without mod_jk you lose certain pieces of information, though, like
I don't think your servlet knows whether it was called via SSL or
regular http. Mine don't care, though, so neither do I.

Do you need a copy of httpd.conf/tomcat.conf etc?

--
John


 -Original Message-
 From: Ravishankar.S [mailto:[EMAIL PROTECTED]]
 Sent: Tuesday, 26 June 2001 00:41
 To: [EMAIL PROTECTED]
 Subject: Re: SSL with Tomcat/mod_jserv via Apache


 dear ronald,
 mod_jk directly supports SSL whereas modJServ does not
 .if u r going
 for SSL i suggest mod_jk and if u r trying it in windows then
may all the
 saints bless u.i tried and failed after  a week's
effort



 Ravishankar.S
 IonIdea Enterprise Solutions,
 #38-40,EPIP,Whitefield,
 Bangalore-560054,
 PH: 91-80-8411366-71  ext: 1042
 E-Mail: [EMAIL PROTECTED]
 URL : www.ionideasolutions.com
 - Original Message -
 From: Ronald Ruzicka [EMAIL PROTECTED]
 To: [EMAIL PROTECTED]
 Sent: Wednesday, July 18, 2001 5:37 PM
 Subject: SSL with Tomcat/mod_jserv via Apache


  Hello,
 
  does anyone know, if it is possible to run SSL on a
 Tomcat/mod_jserv based
  solution connected to Apache-mod_ssl.
 
  Is there a document like TomCat and SSL (which describes
a
 TomCAT/mod_jk
  based solution), only for Tomcat/mod_jserv.
 
  Thank you for your help.
 
  Ronald Ruzicka
  Simutech
  Tel. +43-1-888 36 10-21
  Fax  +43-1-888 36 10-49
  emailmailto:[EMAIL PROTECTED]
  homepage www.simutech.at
 







Tomcat dies... help!

2001-08-13 Thread Ronald Vyhmeister

Tomcat is having serious problems which only happen at night when the usage goes 
light... go figure.  here's the one consistent thing I know.  It gives this error and 
then dies...

[jk_ajp13_worker.c (203)]: connection_tcp_get_message: Error - jk_tcp_socket_rec
vfull failed
[jk_ajp13_worker.c (621)]: Error reading request
[jk_connect.c (143)]: jk_open_socket, connect() failed errno = 146
[jk_ajp13_worker.c (173)]: In jk_endpoint_t::connect_to_tomcat, failed errno = 1
46
...

What is wrong?  What can I do to fix it?

Thanks!

Ron Vyhmeister



NullPointerException in JDBCStore

2002-09-03 Thread Ronald Klop

Hello,

I get a NullPointerException in org.apache.catalina.session.JDBCStore. 
(Tomcat 4.0.4 and 4.1.9)
I think it can be solved with the following patch.
Is there a possibility for this to be committed?


--- JDBCStore-old.java  Wed Sep  4 02:13:53 2002
+++ JDBCStore.java  Wed Sep  4 02:18:12 2002
@@ -759,37 +759,43 @@
  }

  try {
-preparedSizeSql.close();
+if (preparedSizeSql != null)
+preparedSizeSql.close();
  } catch (SQLException e) {
  ;
  }

  try {
-preparedKeysSql.close();
+if (preparedKeysSql != null)
+preparedKeysSql.close();
  } catch (SQLException e) {
  ;
  }

  try {
-preparedSaveSql.close();
+if (preparedSaveSql != null)
+preparedSaveSql.close();
  } catch (SQLException e) {
  ;
  }

  try {
-preparedClearSql.close();
+if (preparedClearSql != null)
+preparedClearSql.close();
  } catch (SQLException e) {
  ;
  }

  try {
-preparedRemoveSql.close();
+if (preparedRemoveSql != null)
+preparedRemoveSql.close();
  } catch (SQLException e) {
  ;
  }

  try {
-preparedLoadSql.close();
+if (preparedLoadSql != null)
+preparedLoadSql.close();
  } catch (SQLException e) {
  ;
  }


-- 
  Ronald Klop
  Amsterdam, The Netherlands


--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




Re: Problem running Tomcat 4.0.4 under JDK 1.4.1

2002-09-06 Thread Ronald Klop

Hello,

I've seen the same problem by a colleague. He installed JDK 1.4 next to 
JDK 1.3 and mixed the standard classpaths of both JDK's. JDK 1.4 uses a 
new class-file format. JDK 1.4 is backwards compatible, but you must use 
its own standard classes.

So, make sure your old JDK is completely uninstalled. Or rename the 
directory of the old JDK, so the system doesn't find the 
classes/programms anymore.

Greetings,

Ronald.

Donie Kelly wrote:
 C:\java -version
 java version 1.4.1-beta
 Java(TM) 2 Runtime Environment, Standard Edition (build 1.4.1-beta-b14)
 Java HotSpot(TM) Client VM (build 1.4.1-beta-b14, mixed mode)
 
 It's not so cool when you NEED it to work. Ok, maybe I'm too bleeding edge.
 I need to take the foot off the throttle :)
 Donie
 
 
 -Original Message-
 From: Shapira, Yoav [mailto:[EMAIL PROTECTED]]
 Sent: 05 September 2002 17:09
 To: Tomcat Users List
 Subject: RE: Problem running Tomcat 4.0.4 under JDK 1.4.1
 
 Hi,
 That's the coolest error I've seen in a while ;)
 
 Do you get it using JDK 1.4.0?  1.4.1 is not final yet, so it may be a
 packaging issue with the 1.4.1 version you're using.  What's the output
 of java -version?
 
 Yoav Shapira
 Millennium ChemInformatics
 
 
 
-Original Message-
From: Donie Kelly [mailto:[EMAIL PROTECTED]]
Sent: Thursday, September 05, 2002 11:51 AM
To: 'Tomcat Users List'
Subject: Problem running Tomcat 4.0.4 under JDK 1.4.1

Hi all,

I've upgraded to jdk 1.4.1 and Tomcat 4.0.4 and now my jsp pages give
 
 the
 
following error...

org.apache.jasper.JasperException: Unable to compile class for
 
 JSPerror:
 
Invalid class file format in
C:\mmsdev\tools\win32\jdk1.4.1\jre\lib\rt.jar(java/lang/Object.class).
 
 The
 
major.minor version '48.0' is too recent for this tool to understand.
error: Class java.lang.Object not found in class
com.tecnomen.mms.relay.Alarms.
2 errors

  at
 
 org.apache.jasper.compiler.Compiler.compile(Compiler.java:285)
 
  at
 
 org.apache.jasper.servlet.JspServlet.loadJSP(JspServlet.java:548)
 
  at
org.apache.jasper.servlet.JspServlet$JspServletWrapper.loadIfNecessary(
 
 JspS
 
e
rvlet.java:176)
  at
org.apache.jasper.servlet.JspServlet$JspServletWrapper.service(JspServl
 
 et.j
 
a
va:188)
  at
org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:381
 
 )
 
  at
 
 org.apache.jasper.servlet.JspServlet.service(JspServlet.java:473)
 
  at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
  at
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(Applic
 
 atio
 
n
FilterChain.java:247)
  at
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFil
 
 terC
 
h
ain.java:193)
  at
org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperVal
 
 ve.j
 
a
va:243)
  at
org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.j
 
 ava:
 
5
66)
  at
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:
 
 472)
 
  at
org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:943)
  at
org.apache.catalina.core.StandardContextValve.invoke(StandardContextVal
 
 ve.j
 
a
va:190)
  at
org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.j
 
 ava:
 
5
66)
  at
org.apache.catalina.authenticator.AuthenticatorBase.invoke(Authenticato
 
 rBas
 
e
.java:531)
  at
org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.j
 
 ava:
 
5
64)
  at
org.apache.catalina.valves.CertificatesValve.invoke(CertificatesValve.j
 
 ava:
 
2
46)
  at
org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.j
 
 ava:
 
5
64)
  at
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:
 
 472)
 
  at
org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:943)
  at
org.apache.catalina.core.StandardContext.invoke(StandardContext.java:23
 
 47)
 
  at
org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.jav
 
 a:18
 
0
)
  at
org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.j
 
 ava:
 
5
66)
  at
org.apache.catalina.valves.ErrorDispatcherValve.invoke(ErrorDispatcherV
 
 alve
 
.
java:170)
  at
org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.j
 
 ava:
 
5
64)
  at
org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.jav
 
 a:17
 
0
)
  at
org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.j
 
 ava:
 
5
64)
  at
org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:46
 
 8)
 
  at
org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.j
 
 ava:
 
5
64)
  at
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:
 
 472)
 
  at
org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:943)
  at
org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve
 
 .jav
 
a
:174

Re: Problem running Tomcat 4.0.4 under JDK 1.4.1

2002-09-06 Thread Ronald Klop

I can tell you I've Tomcat 4.0.4 and JDK 1.4.1 running. So it does work.

And I also use a lot of third-party packages compiled under previous 
JDK's, so that's not a problem. Just don't mix the base classes and make 
sure you don't run JDK 1.3 with the JDK 1.4 classes accidently.

Windows is a bit non-transparent in where it defines it path's and 
stuff, so I'm always unsure which application is run. My experience is 
that the path can be different in a dos-box and from windows self.

Ronald.

Donie Kelly wrote:
 I'm doing a good cleanout at the moment. I'm rebuilding all my jar's and
 removing every class file that is linked to my source. I've also downgraded
 to JDK 1.4.0 so that I minimise my problems. 
 
 I'll let you know if this is the solution.
 Donie
 
 
 -Original Message-
 From: Ronald Klop [mailto:[EMAIL PROTECTED]]
 Sent: 06 September 2002 11:28
 To: Tomcat Users List
 Subject: Re: Problem running Tomcat 4.0.4 under JDK 1.4.1
 
 Hello,
 
 I've seen the same problem by a colleague. He installed JDK 1.4 next to
 JDK 1.3 and mixed the standard classpaths of both JDK's. JDK 1.4 uses a
 new class-file format. JDK 1.4 is backwards compatible, but you must use
 its own standard classes.
 
 So, make sure your old JDK is completely uninstalled. Or rename the
 directory of the old JDK, so the system doesn't find the
 classes/programms anymore.
 
 Greetings,
 
 Ronald.
 
 Donie Kelly wrote:
 
C:\java -version
java version 1.4.1-beta
Java(TM) 2 Runtime Environment, Standard Edition (build 1.4.1-beta-b14)
Java HotSpot(TM) Client VM (build 1.4.1-beta-b14, mixed mode)

It's not so cool when you NEED it to work. Ok, maybe I'm too bleeding
 
 edge.
 
I need to take the foot off the throttle :)
Donie


-Original Message-
From: Shapira, Yoav [mailto:[EMAIL PROTECTED]]
Sent: 05 September 2002 17:09
To: Tomcat Users List
Subject: RE: Problem running Tomcat 4.0.4 under JDK 1.4.1

Hi,
That's the coolest error I've seen in a while ;)

Do you get it using JDK 1.4.0?  1.4.1 is not final yet, so it may be a
packaging issue with the 1.4.1 version you're using.  What's the output
of java -version?

Yoav Shapira
Millennium ChemInformatics




-Original Message-
From: Donie Kelly [mailto:[EMAIL PROTECTED]]
Sent: Thursday, September 05, 2002 11:51 AM
To: 'Tomcat Users List'
Subject: Problem running Tomcat 4.0.4 under JDK 1.4.1

Hi all,

I've upgraded to jdk 1.4.1 and Tomcat 4.0.4 and now my jsp pages give

the


following error...

org.apache.jasper.JasperException: Unable to compile class for

JSPerror:


Invalid class file format in
C:\mmsdev\tools\win32\jdk1.4.1\jre\lib\rt.jar(java/lang/Object.class).

The


major.minor version '48.0' is too recent for this tool to understand.
error: Class java.lang.Object not found in class
com.tecnomen.mms.relay.Alarms.
2 errors

 at

org.apache.jasper.compiler.Compiler.compile(Compiler.java:285)


 at

org.apache.jasper.servlet.JspServlet.loadJSP(JspServlet.java:548)


 at
org.apache.jasper.servlet.JspServlet$JspServletWrapper.loadIfNecessary(

JspS


e
rvlet.java:176)
 at
org.apache.jasper.servlet.JspServlet$JspServletWrapper.service(JspServl

et.j


a
va:188)
 at
org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:381

)


 at

org.apache.jasper.servlet.JspServlet.service(JspServlet.java:473)


 at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
 at
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(Applic

atio


n
FilterChain.java:247)
 at
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFil

terC


h
ain.java:193)
 at
org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperVal

ve.j


a
va:243)
 at
org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.j

ava:


5
66)
 at
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:

472)


 at
org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:943)
 at
org.apache.catalina.core.StandardContextValve.invoke(StandardContextVal

ve.j


a
va:190)
 at
org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.j

ava:


5
66)
 at
org.apache.catalina.authenticator.AuthenticatorBase.invoke(Authenticato

rBas


e
.java:531)
 at
org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.j

ava:


5
64)
 at
org.apache.catalina.valves.CertificatesValve.invoke(CertificatesValve.j

ava:


2
46)
 at
org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.j

ava:


5
64)
 at
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:

472)


 at
org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:943)
 at
org.apache.catalina.core.StandardContext.invoke(StandardContext.java:23

47)


 at
org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.jav

a:18


0
)
 at
org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.j

ava:


5
66

Re: Running a long transaction with tomcat but responding to userqui ckly

2002-09-06 Thread Ronald Klop

Try something like this in your servlet.

void doGet(request, response) {
...
// Get request info
...
out = response.getOutputStream();
out.write(htmlbodyHello, everything is ok./body/html);
out.close();
...
// Do the transaction here
...
}

Greetings,

Ronald.

Donie Kelly wrote:
 Hi all
 
 I want to run a long transaction which lasts about 2 seconds with tomcat but
 after I have gathered the information from the request I want to return 200
 OK to user and close the connection to the browser. However, the thread
 should continue to process the request and when finished it should return to
 the thread pool tomcat has.
 
 I want to set the tomcat pool up as follows in server.xml
 Connector className=org.apache.catalina.connector.http.HttpConnector
 port=80 minProcessors=5 maxProcessors=5
enableLookups=true redirectPort=443 acceptCount=100
 debug=0 connectionTimeout=6/
 So basically, I want only 5 threads running at any time and under load
 conditions it should cause a backlog of 100 with 5 threads doing the
 processing. It is important though that the threads return quickly to the
 user.
 
 Thanks for any solutions
 Donie
 
 
 --
 To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
 For additional commands, e-mail: mailto:[EMAIL PROTECTED]
 

-- 
  Ronald Klop
  Amsterdam, The Netherlands


--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




Re: Does Tomcat require restart when chaning classes?

2002-09-13 Thread Ronald Klop

-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

Why not just enable the manager webapp and call:

http://localhost/manager/reload?path=/webapp

You don't need to enable 'reloadable' for this.

Greetings,

Ronald.

Mauro Daniel Ardolino wrote:
| I think you have to restart Tomcat for changes like this.
| Do someone know another way to do it?
|
| Mauro
|
| On Thu, 12 Sep 2002, Chuck Carson wrote:
|
|
|
|I had the following class:
|$TOMCAT_HOME/webapps/ROOT/WEB-INF/classes/MyClass.class
|
|If I modify this class (ie recompile) how can I make it active w/o
|restarting tomcat? As it stands now (with my current server config,
|which is pretty much default) I can only get news changes visible after
|a server restart.
|
|Thanks,
|CC
|
|Chuck Carson
|Sr. Systems Administrator
|Syrrx, Inc.
|10410 Science Center Drive
|San Diego, CA 92121
|E: [EMAIL PROTECTED] mailto:[EMAIL PROTECTED]
|W: 858.731.3540
|M: 858.442.0827
|
|
|--
|This message contains confidential information and is intended only for
|the individual named. If you are not the named addressee you should not
|disseminate, distribute or copy this e-mail. Please notify the sender
|immediately by e-mail if you have received this e-mail by mistake and
|delete this e-mail from your system. E-mail transmission cannot be
|guaranteed to be secure or error-free as information could be
|intercepted, corrupted, lost, destroyed, arrive late or incomplete, or
|contain viruses. The sender therefore does not accept liability for any
|errors or omissions in the contents of this message, which arise as a
|result of e-mail transmission. If verification is required please
|request a hard-copy version.
|
|
|

- --
~ Ronald Klop
~ Amsterdam, The Netherlands
-BEGIN PGP SIGNATURE-
Version: GnuPG v1.0.7 (FreeBSD)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iD8DBQE9geKrPgc4rWsY77MRAkphAKCG3KY5LIolMx60+YxBLYE0W6Pq5QCfSItZ
ZcCERRM5P3tkv5E/juU0Qgc=
=Duha
-END PGP SIGNATURE-


--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




nullpointerexception jdbcstore

2002-09-18 Thread Ronald Klop

-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

Hello,

On September 4th I reported bug 12286 with a fix included. Is somebody
planning to commit this? What is the normal time before fixes get into
the tree and is there something more I have to do to get this committed?

Greetings,

Ronald.

- --
~ Ronald Klop
~ Amsterdam, The Netherlands
-BEGIN PGP SIGNATURE-
Version: GnuPG v1.0.7 (FreeBSD)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iD8DBQE9iDvAPgc4rWsY77MRArISAKCyQnZyRmoil/S3zAGR1INvXdwUqwCeKSph
uJnpOsKzMvPwsH7mL4XZZi8=
=+F8J
-END PGP SIGNATURE-


--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




Re: nullpointerexception jdbcstore

2002-09-18 Thread Ronald Klop

-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

Hello,

Robert L Sowders wrote:
| Did you cross post this to the tomcat-dev list?  Anyway the PR states it
| affects 4.1.10 but your statements in the explanation pertain only 4.0.4.
|
| Which way is it?

I first reported it for 4.0.4, but it wasn't fixed in 4.1.10, so I
changed that. To make clear that the bug was still there. I didn't
cross-post this to the -dev list. I don't know the policies about that
in these mailinglists yet. If -dev is for developers only or for all
talk about development. And I was thinking that most developers wil be
subscribed to both lists anyway.

| It doesn't look like it's gotten much attention in any case.
| Perhaps you need to freshen it to bring it to the top again.

That is what I'm trying to do with this mail, but I wil try to get some
attention to it later today on the -dev list. I hope it wil be used. I
have found more bugs which are easy to fix (NPE-stuff, etc.), but I
don't want to spent time for fixing it if the fixes aren't used (or
rejected with good reasons).

Ronald Klop.

|
| Ronald Klop [EMAIL PROTECTED]
| 09/18/2002 01:39 AM
| Please respond to Tomcat Users List
|
|
| To: [EMAIL PROTECTED]
| cc:
| Subject:nullpointerexception jdbcstore
|
| Hello,
|
| On September 4th I reported bug 12286 with a fix included. Is somebody
| planning to commit this? What is the normal time before fixes get into
| the tree and is there something more I have to do to get this committed?
|
| Greetings,
|
| Ronald.
|
| --
| ~ Ronald Klop
| ~ Amsterdam, The Netherlands

- --
To unsubscribe, e-mail:
mailto:[EMAIL PROTECTED]
For additional commands, e-mail:
mailto:[EMAIL PROTECTED]





- --
To unsubscribe, e-mail:
mailto:[EMAIL PROTECTED]
For additional commands, e-mail:
mailto:[EMAIL PROTECTED]


- --
~ Ronald Klop
~ Amsterdam, The Netherlands
-BEGIN PGP SIGNATURE-
Version: GnuPG v1.0.7 (FreeBSD)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iD8DBQE9iGkEPgc4rWsY77MRAqypAJwO9bbtE7YFv2LkoL9hLpgo0lMuTgCfaSSz
lmiu+1uha8cKJIR3AZyY8XM=
=ZzxS
-END PGP SIGNATURE-


--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




can't display jsp compile errors when using error-page.

2003-07-14 Thread Ronald Klop
Hello,

If I use error-page in web.xml, jsp compile and runtime errors are going 
to the error handler. If you use errorPage='error.jsp' only runtime 
errors are handled by my error page.

I put this in my web.xml:

error-page
exception-typejava.lang.Throwable/exception-type
location/progs/error.jsp/location
/error-page
Now all exceptions are redirected to my error page. If Jasper throws an 
JasperException, because of a JSP compile error it is also handled by 
this page, but there is no exception in the error.jsp page. Because it 
is probably handled as a '500 Interal Server Error'.

How can I get the error/exception of this in my error.jsp?

If I put errorPage='/progs/error.jsp' in the jsp page, compile errors 
are displayed by tomcat and runtime error are redirected to my errorpage.

I hope my question is clear.

Greetings,

Ronald.



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


Re: can't display jsp compile errors when using error-page.

2003-07-14 Thread Ronald Klop
Creating my own exceptions is probably the best solution for now.

But I also found this 'solution'. Now I can catch all and exclude some.

error-page
  exception-typeorg.apache.jasper.JasperException/exception-type
  location
/progs/does-not-exist-so-we-get-the-default-error-handler.jsp
  /location
/error-page
error-page
  exception-typejava.lang.Throwable/exception-type
  location/progs/error.jsp/location
/error-page
Greetings,

Ronald.

Abid Ali Teepo wrote:

I don't really understand your question apart from the problem that all exceptions shows your error page. This is because you have set up Throwable in your web.xml file.

The Throwable class is the superclass of all errors and exceptions in the Java language.  is a snippet from the documentation. I suggest you make more mappings, one for each exception you want to show a specific errorpage for. I think it would be a good idea to maybe make your own exceptions that trigger the error page.

Abid

-Original Message-
From: Ronald Klop [mailto:[EMAIL PROTECTED]
Sent: 14. juli 2003 15:02
To: [EMAIL PROTECTED]
Subject: can't display jsp compile errors when using error-page.
Hello,

If I use error-page in web.xml, jsp compile and runtime errors are going 
to the error handler. If you use errorPage='error.jsp' only runtime 
errors are handled by my error page.

I put this in my web.xml:

error-page
exception-typejava.lang.Throwable/exception-type
location/progs/error.jsp/location
/error-page
Now all exceptions are redirected to my error page. If Jasper throws an 
JasperException, because of a JSP compile error it is also handled by 
this page, but there is no exception in the error.jsp page. Because it 
is probably handled as a '500 Interal Server Error'.

How can I get the error/exception of this in my error.jsp?

If I put errorPage='/progs/error.jsp' in the jsp page, compile errors 
are displayed by tomcat and runtime error are redirected to my errorpage.

I hope my question is clear.

Greetings,

Ronald.



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]




-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


Re: Looking for suggestions or pointers ..

2003-07-14 Thread Ronald Klop
See javax.servlet.ServletContextListener.
A context is destroyed and initialized when Tomcat is reloaded.
You can define a context listener in WEB-INF/web.xml:
listener
listener-classbla.bla.MyContextListener/listener-class
/listener

Works very well for my applications.
Note: Take a look at the various SessionListeners also. They can be very easy 
to use also for clean up.

Greetings,

Ronald.

On Monday 14 July 2003 10:14, Mufaddal Khumri wrote:
 The problem:

 We have some codebase that uses a legacy connection pool manager (cpm)
 to manage database connections with mysql. The very first time the
 login.jsp is used by a user  causes an instance of cpm being created
 and stored in the application context. The cpm gets and frees
 connection objects . Everything works fine, but when the webapp is
 reloaded a few times it gives the errors that i have logged below. The
 reason for the error is that the connections that are created and
 maintained by cpm are not being closed when the webapp is reloaded in
 tomcat. Is there a way or where in tomcat can we write clean up code ,
 for example close connections to databases. ??

 Thanks.

 // Error show in Browser
 
 java.lang.NullPointerException
   at
 com.wavesinmotion.cw.classes.db.ConnectionPoolManager.getConnectionPool(
 ConnectionPoolManager.java:112)
   at
 com.wavesinmotion.cw.classes.jsphelpers.LoginServlet.isValid(LoginServle
 t.java:78)
   at
 com.wavesinmotion.cw.classes.jsphelpers.LoginServlet.doPost(LoginServlet
 .java:32)
   at javax.servlet.http.HttpServlet.service(HttpServlet.java:760)
   at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
   at
 org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(Applica
 tionFilterChain.java:247)
   at
 org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilt
 erChain.java:193)
   at
 org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValv
 e.java:260)
   at
 org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.i
 nvokeNext(StandardPipeline.java:643)
   at
 org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:4
 80)
   at
 org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:995)
   at
 org.apache.catalina.core.StandardContextValve.invoke(StandardContextValv
 e.java:191)
   at
 org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.i
 nvokeNext(StandardPipeline.java:643)
   at
 org.apache.catalina.valves.CertificatesValve.invoke(CertificatesValve.ja
 va:246)
   at
 org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.i
 nvokeNext(StandardPipeline.java:641)
   at
 org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:4
 80)
   at
 org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:995)
   at
 org.apache.catalina.core.StandardContext.invoke(StandardContext.java:241
 5)
   at
 org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java

 :180)

   at
 org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.i
 nvokeNext(StandardPipeline.java:643)
   at
 org.apache.catalina.valves.ErrorDispatcherValve.invoke(ErrorDispatcherVa
 lve.java:170)
   at
 org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.i
 nvokeNext(StandardPipeline.java:641)
   at
 org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java

 :172)

   at
 org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.i
 nvokeNext(StandardPipeline.java:641)
   at
 org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:4
 80)
   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.i
 nvokeNext(StandardPipeline.java:643)
   at
 org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:4
 80)
   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:43
 2)
   at
 org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.processC
 onnection(Http11Protocol.java:386)
   at
 org.apache.tomcat.util.net.TcpWorkerThread.runIt(PoolTcpEndpoint.java:53
 4)
   at
 org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool
 .java:530)
   at java.lang.Thread.run(Thread.java:554)


 // Error show in log.out
 
 2003-07-14 12:09:01 StandardWrapperValve[LoginServlet]:
 Servlet.service() for servlet LoginServlet threw exception

GZIP support in Coyote HTTP/1.1?

2003-03-17 Thread Ronald Klop
Hello,

The RELEASE-NOTES state:

[4.1.19] CoyoteConnector:
 Add HTTP/1.1 GZIP compression support.
Is this in org.apache.coyote.tomcat4.CoyoteConnector or in another 
connector?
I can't find an option to enable it and it doesn't seem to be enabled by 
default.
Am I missing something?

Greetings,

Ronald Klop.



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


gzip compression in Coyote on 4.1.24

2003-04-01 Thread Ronald Klop
Hello,

Sorry if this is send twice, but I think my previous mail got lost in 
cyberspace somewhere. (Can't even find it in my Sent-box.)

I'm trying to use gzip compression with tomcat 4.1.24. And it doesn't 
work, because it checks if content-type is 'text/html', but this fails 
if the content-type is 'text/html; charset=us-ascii'.
So compression='force' is the only way to use compression, but this also 
compresses image/gif, etc.

Does anybody else use this?

I made a bugreport with a (possible) fix. See bug 18073 (made by myself) 
and 2820 [1].

Greetings,

Ronald.

[1]
http://nagoya.apache.org/bugzilla/show_bug.cgi?id=18073
http://nagoya.apache.org/bugzilla/show_bug.cgi?id=2820


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


gzip compression in Coyote from 4.1.24

2003-04-01 Thread Ronald Klop
Hello,

Can somebody confirm if gzip compression works in Tomcat 4.1.24?
I have found that it is not working if the Content-Type contains extra 
info like ';charset=us-ascii'.

The only bug reports I can find about this are: 18073 (made by myself) 
and 2820 [1].

I am wondering if other people are using this feature?

Greetings,

Ronald.

[1]
http://nagoya.apache.org/bugzilla/show_bug.cgi?id=2820
http://nagoya.apache.org/bugzilla/show_bug.cgi?id=18073


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


tag and method overloading

2003-06-04 Thread Ronald Klop
Hello,

Is it possible to overload a method of a tag.

In JSP:
String arg1 = bla;
int arg2 = 5;
mytag name=%= arg1 % /
mytag name=%= arg2 % /
In the class:
public void setName(String s) {
...
}
public void setName(int i) {
...
}
I get errors like: can't find setter method for String.

Is this supported? If yes, are their known pitfalls?
Any pointers to docs about this? Already tried google, but didn't find 
anything relevant.

Greetings,

Ronald.



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


Re: tag and method overloading

2003-06-04 Thread Ronald Klop
Tim Funk wrote:
No. You'll need to do the conversion yourself.
Ok, if I have a tag which can get a String or a List of Strings.
Should I make one setter which gets Object as parameter? And than check 
at runtime for the right types?
Are there any guidelines for this?

Greetings,

Ronald.

-Tim

Ronald Klop wrote:

Hello,

Is it possible to overload a method of a tag.

In JSP:
String arg1 = bla;
int arg2 = 5;
mytag name=%= arg1 % /
mytag name=%= arg2 % /
In the class:
public void setName(String s) {
...
}
public void setName(int i) {
...
}
I get errors like: can't find setter method for String.

Is this supported? If yes, are their known pitfalls?
Any pointers to docs about this? Already tried google, but didn't find 
anything relevant.

Greetings,

Ronald.



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]




-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


RE: HttpServletResponse.sendRedirect() closes the stream

2004-03-10 Thread Ronald Wildenberg
 -Oorspronkelijk bericht-
 Van: suviswan [mailto:[EMAIL PROTECTED]
 Verzonden: woensdag 10 maart 2004 10:20
 Aan: Tomcat Users List
 Onderwerp: HttpServletResponse.sendRedirect() closes the stream
 
 
 Hi
 I am using Tomcat 4.1.29. When i do
 HttpServletResponse.sendRedirect() inside my servlet doGet(), it
 automatically closes the stream
 So when i call the real close() function it throws IOException
 
 java.io.IOException: The stream has been closed
 at
 org.apache.catalina.connector.ResponseStream.close(ResponseStr
 eam.java:219)
 
 Please let me know how to solve on this.


The easiest way would be not to call close() on the response's output
stream. Is there a reason you need to call close()?

The servlet spec says that sendRedirect has the side effect of committing
the response and terminating it. If the response is terminated, its
related OutputStream is closed, so it can not be closed again.


 
 Thanks
 Surendra
 

Regards,
Ronald.

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



RE: Tomcat 4.1 hangs on File Reading

2004-03-10 Thread Ronald Wildenberg
snip

 
 public static LoginLog[] readLog()throws FileNotFoundException
 {
   Vector log = new Vector();
 
   try {
 FileReader inFile = new FileReader( /var/log/GFWlogin.log );
 BufferedReader bfFile = new BufferedReader( inFile );
   while ( bfFile.ready() ) {
 LoginLog logentry = getLogentry( bfFile );
 log.add( logentry );
   }
 bfFile.close();
} catch ( IOException e ) {} ;
return (LoginLog[])log.toArray( new LoginLog[log.size()] );
 }
 


Why not simply use:

   String line = null;
   while ((line = bfFile.readLine()) != null) {
  LoginLog logEntry = getLogEntry(line); // Create log entry from the
line just read.
  log.add(logEntry);
   }

There is no need to use 'bfFile.ready()'. This method only checks
whether the call to a read method may block, which is not a problem
at all.


Regards,
Ronald.

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



RE: Tomcat Realm Authentication + Storing Objects In The Session

2004-03-10 Thread Ronald Wildenberg
 My biggest unknown right now is, because the server handles 
 the creation
 of the session, what would it take to make the server grab a 
 user object
 from the database and store it in the session after the user 
 logs in?  
 


Can't you use an HttpSessionListener for this? It is called right
after a session is created (and when it's destroyed again). I'm
not sure though whether there's enough information in the HttpSession
object for you to be able to grab something from the database at
the time HttpSessionListener.sessionCreated() is called.

Regards,
Ronald.

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



RE: release method in taglib

2004-03-11 Thread Ronald Wildenberg
 I have created several custom tag libs, I notice there is a 
 release() method in the TagSupport class.  Will the release() 
 method be automically called the tag lib is finished?  If 
 not, where should I call it?  Thanks!
 


It will be called by the JSP page implementation object
automatically, so you don't have to call this yourself.
Multiple invocations on doStartTag and doEndTag may have
occurred before this method is called (for example when
multiple tags of the same type occur on a page).


Regards, Ronald.

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



RE: redirect and request´s attributes doubts

2004-03-12 Thread Ronald Wildenberg
   Hello dudes, i´m trying to set some attributes to a 
 request in my
 servlet, that´s pretty easy as you know, but after i must use 
 redirect to a
 JSP page and when i try to recall those attributes created before they
 doesn´t appear in JSP´s request object. Even thought i set a request´s
 attribute and use redirect i cannot get it again, can i?
 


The attributes you add to the request are added on the server. There
is a request object on the server that you add attributes to.

If you use sendRedirect, the client (browser) receives a redirect
response from the server (status code 3xx), with the location to
redirect to. The client then creates a _new_ request for the new url
and sends it to the server. The server creates a new HttpServletRequest
object for you that has nothing to do with the old object.


Regards, Ronald.

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



RE: Dump HTTP Request and Response Headers

2004-03-12 Thread Ronald Wildenberg
 Dear folks,
   How could i dump HTTP Response and Request headers. 
   Im using Apache 1.3 and Tomcat 4.0 MOD_JK.
 

For Mozilla you have a tool called Live HTTP Headers
(http://livehttpheaders.mozdev.org/) that does exactly
what you want. You install it into Mozilla and it
shows you the headers that are sent and received by the
browser.

Undoubtedly for IE there exist similar tools.


Regards, Ronald.

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



RE: Setting page content Type

2004-03-12 Thread Ronald Wildenberg
 I have been experiementing with
 
 jsp:directive.page contentType=... /
 @ page contentType=... /
 
 but none of them seem to be able to take a variable value for 
 contentType,
 

These constructs will indeed not work (and they never will work in
future versions either). The constructs you use are directives
(the first one in XML syntax, the second in JSP syntax). Directives
are interpreted at page translation time. The tags you attempt to
use are not executed at page translation time but at page
execution time (when a request is received for the page).

Directives can not have variables as attributes, since the value
of these variables can never be known at the time the page is
translated to a servlet.

Regards, Ronald.

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



RE: Passing init params to a listener?

2004-03-15 Thread Ronald Wildenberg
 G'day,
 
 I assume from this that init parameters can only be accessed 
 by a listener
 if they have been declared globally within the applications 
 context and not
 from within the scope of the listener itself?  
 
 Hm


You can not specify initialization parameters for individual
listeners. The syntax you use is even illegal.

I do not really see why this should not be possible, since
all other web components (servlets, filters) can be parameterized,
but that may be something for a future specification.

Regards, Ronald.

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



RE: How can I get a method to be called every 60 seconds in Tomca t?

2004-03-16 Thread Ronald Wildenberg
 I want to get a method to automatically get called every 60 
 seconds in Tomcat.  The method reset() will reset monitoring 
 information.  How can I do this?  
 

java.util.Timer and java.util.TimerTask


Regards, Ronald.

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



RE: Filters and load-on-startup

2004-03-16 Thread Ronald Wildenberg
 Hi,
 
 Do filters get loaded before servlets regardless of load-on-startup
 value?
 
 I don't think so: as filters can be mapped to servlet-name, servlets
 must be loaded first.  (Although I suppose you could read web.xml, so
 you have the servlet info, then instantiance filters, then instantiate
 servlets, but tomcat doesn't do this).
 
 I wouldn't rely on this order unless you had to, however, as it's not
 mandated either way by the Servlet Specification.
 


Actually, it is. SRV9.12 mandates the following load order: listeners,
filters, servlets (Servlet Specification 2.4). So any filters should be
loaded before any servlets, regardless of load-on-startup value.


Regards, Ronald.

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



RE: caching static objects

2004-03-23 Thread Ronald Wildenberg
 We are running Tomcat-standalone and are having some caching 
 issues. It
 appears to be a browser issue, but there's got to be some workaround.
 We've got the headers set to pragma nocache, but it continues to cache
 objects, such as charts that are created dynamically. I suppose this
 wouldn't be an issue if the code worked with Apache. Also, creating
 unique identifiers for each object has been shot down. Does 
 anyone know
 of a way to get server.xml to set each object not to cache? Thanks.
 


The 'Pragma' header you use is from HTTP/1.0. Most caches, including
browser cache, by now use HTTP/1.1, where cache control is achieved
differently. You should use 'Cache-Control' headers (although it never
hurts to also use 'Pragma' headers, in case you encounter an older
HTTP/1.0 cache).

For more information you can look at the HTTP/1.1 RFC at:

   ftp://ftp.isi.edu/in-notes/rfc2616.txt

and search for the text 'Cache-Control'.


Regards, Ronald.

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



upload file with non-ascii characters in name

2004-04-09 Thread Ronald Klop
Hello,
When I run Tomcat on Windows and upload (with IE)a file with non-ascii characters in the filename it goes well.But when I run Tomcat on Linux and do the same upload it doesn't recognize the non-ascii characters and prints them as squares or question mark.
Does anybody have experience with this?
Greeting,
Ronald.? java-src/jspc
? web/test.html
? web/WEB-INF/jsp/forms/maintenance
Index: java-src/nl/base/rela/entities/Hour.java
===
RCS file: /var/cvs/crm/java-src/nl/base/rela/entities/Hour.java,v
retrieving revision 1.7
diff -b -u -r1.7 Hour.java
--- java-src/nl/base/rela/entities/Hour.java27 Nov 2003 11:39:37 -  1.7
+++ java-src/nl/base/rela/entities/Hour.java2 Dec 2003 09:12:28 -
@@ -62,7 +62,8 @@
String field = s.getString(field);
String value = s.getString(value);
list.addFieldValue(field, value);
-System.err.println(queryId+ queryId);
+System.err.println(queryId + queryId);
+

String employee = s.getString(employeesearch);
if (queryId.equals(longhours)) {
Index: web/WEB-INF/database.xml
===
RCS file: /var/cvs/crm/web/WEB-INF/database.xml,v
retrieving revision 1.44
diff -b -u -r1.44 database.xml
--- web/WEB-INF/database.xml25 Nov 2003 15:38:55 -  1.44
+++ web/WEB-INF/database.xml2 Dec 2003 09:12:29 -
@@ -116,7 +116,7 @@
table name=department ownerColumn=none /
table name=emailidentities /
table name=grouprights /
-   table name=groups ownerColumn=none /
+   table name=groups keyColumn=groupid ownerColumn=none /
table name=keynum /
table name=logins /
table name=rights /
Index: web/WEB-INF/modules.xml
===
RCS file: /var/cvs/crm/web/WEB-INF/modules.xml,v
retrieving revision 1.11
diff -b -u -r1.11 modules.xml
--- web/WEB-INF/modules.xml 28 Nov 2003 12:17:07 -  1.11
+++ web/WEB-INF/modules.xml 2 Dec 2003 09:12:29 -
@@ -22,7 +22,6 @@
 ]
 
 modules
-
group name=rela
module name=bookmark class=nl.base.rela.entities.Employee
htmlViewData 
Index: web/WEB-INF/jsp/forms/rela/mainemployee.jsp
===
RCS file: /var/cvs/crm/web/WEB-INF/jsp/forms/rela/mainemployee.jsp,v
retrieving revision 1.6
diff -b -u -r1.6 mainemployee.jsp
--- web/WEB-INF/jsp/forms/rela/mainemployee.jsp 21 Nov 2003 11:38:34 -  1.6
+++ web/WEB-INF/jsp/forms/rela/mainemployee.jsp 2 Dec 2003 09:12:29 -
@@ -19,8 +19,21 @@
 
html:flowlayout direction=horizontal
 
-   html:flowlayout width=80 direction=vertical
+   html:flowlayout width=80 direction=vertical padding=3
html:button label=Bewaar submit=true /
+   html:button label=Bewaar / sluit submit=true /
+   html:button label=Annuleren submit=false /
+   html:spacer height=8 /
+   html:button label=Brieven / email submit=true /
+   html:button label=Uren submit=true /
+   html:button label=Kenmerken submit=false /
+   html:button label=SMS submit=true /
+   html:button label=Etiket submit=true /
+   html:button label=Agenda submit=false /
+   html:button label=Taken submit=true /
+   html:spacer height=8 /
+   html:button label=Route submit=true /
+   html:button label=Buurtinfo submit=false /
/html:flowlayout
 
html:spacer width=10 /
@@ -30,90 +43,169 @@
html:flowlayout direction=horizontal padding=3
html:labelEdit labelWidth=65 
inputWidth=65 label=Relatiecode field=rcode disabled=true /
html:spacer width=90 /
-   html:labelCombo disabled=true 
label=Afdeling field=rowner2 labelWidth=50 mask=%= 
user.getSettings().getXML(uren_department) %/
+   html:labelCombo label=Afdeling 
field=rowner2 labelWidth=50 mask=%= user.getSettings().getXML(uren_department) 
%/
html:labelDateTime label=Last update 
field=rlastup labelWidth=70 disabled=true /
/html:flowlayout
 
html:spacer /
 
-   html:flowlayout direction=horizontal

Re: Tomcat for FreeBSD

2004-04-13 Thread Ronald Klop
If you have installed the FreeBSD ports collection (which you probably have), than do this:

cd /usr/ports/www/jakarta-tomcat5
make
make install
make clean
The 'make' command wil show some settings, which may be readable depending on how fast your computer scrolls text.

Greetings,

Ronald.

On Sat Apr 10 17:43:04 CEST 2004 Shawn Zernik [EMAIL PROTECTED] wrote:



Tomcat Gurus:

Is their a *current* version of Java/Tomcat that been assembled for FreeBSD
5.0?
Shawn Zernik
Internetwork Consulting
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



bug in JDBCStore in 4.1.27

2003-09-09 Thread Ronald Klop
Hello,

Is anybody interested to fix BUG# 19034 (InvalidClassException in 
StoreBase.java)?

http://nagoya.apache.org/bugzilla/show_bug.cgi?id=19034

It is still in there and generates a lot of errors if I update my 
web-application.

Greetings,

Ronald.



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


mail.jar and activation.jar in Tomcat 4.1.29

2003-11-26 Thread Ronald Klop

Hello,
 
Why is mail.jar and activation.jar added in Tomcat 4.1.29 in common/lib?
 
My webapp uses it's own mail.jar (1.3.1 in stead of 1.2) and activation.jar and 
everything doesn't work anymore.
I think this is a major 'API' change for a minor release.
 
For what are these api's used by Tomcat? I can't think of anything that a webserver 
does with mail.
 
Greetings,
 
Ronald.

 

RE: mail.jar and activation.jar in Tomcat 4.1.29

2003-11-26 Thread Ronald Klop

I have made handlers for multipart/related, etc. for use in a web based mailclient. 
This gives a lot of trouble with ClassLoaders.
Removing mail.jar and activation.jar from common/lib solves the problem.
And I'm 100% sure, that I've never had to do that before 4.1.29.
 
Greetings,
 
Ronald.
 
On Wed Nov 26 16:36:53 CET 2003 Shapira, Yoav [EMAIL PROTECTED] wrote:


 
Howdy,
Tomcat can provide mail sessions to you via JNDI as illustrated
here:
http://jakarta.apache.org/tomcat/tomcat-4.1-doc/jndi-resources-howto.htm
l.

mail.jar and activation.jar are not new nor moved in 4.1.29, they were
in common/lib before. FYI, I also use mail 1.3.1 by putting it in
WEB-INF/lib (which overrides common/lib in the classloader hierarchy)
without a problem.

Yoav Shapira
Millennium ChemInformatics


-Original Message-
From: Ronald Klop [mailto:[EMAIL PROTECTED]
Sent: Wednesday, November 26, 2003 10:16 AM
To: [EMAIL PROTECTED]
Subject: mail.jar and activation.jar in Tomcat 4.1.29


Hello,

Why is mail.jar and activation.jar added in Tomcat 4.1.29 in
common/lib?

My webapp uses it's own mail.jar (1.3.1 in stead of 1.2) and
activation.jar
and everything doesn't work anymore.
I think this is a major 'API' change for a minor release.

For what are these api's used by Tomcat? I can't think of anything that
a
webserver does with mail.

Greetings,

Ronald.





This e-mail, including any attachments, is a confidential business communication, and 
may contain information that is confidential, proprietary and/or privileged. This 
e-mail is intended only for the individual(s) to whom it is addressed, and may not be 
saved, copied, printed, disclosed or used by anyone else. If you are not the(an) 
intended recipient, please immediately delete this e-mail from your computer system 
and notify the sender. Thank you.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]




Re: RE:how to set encoding parameter in Tomcat4...

2004-11-02 Thread Ronald Klop
I set request.setCharacterEncoding(...) before handling the request. My Tomcat-5 
doesn't pick up the content-type of the request from a browser, because browsers do 
not send content encoding as http headers. Maybe xmlRPC does the same.
I recommend you to use a network sniffer for looking what bytes are really send over 
the wire between the application and the server and tomcat and the database.
Ronald.
http://jakarta.apache.org/tomcat/tomcat-4.1-doc/servletapi/javax/servlet/ServletRequest.html#setCharacterEncoding(java.lang.String)
On Mon Nov 01 20:48:07 CET 2004 Shilpa Nalgonda [EMAIL PROTECTED] wrote:
Hi,
I am working on an application which has international clients like Japan,
Europe etc.,
Our java Application is using Tomcat4, XmlRPC and Oracle database. This
application will insert the international characters in database. But the
inserted data is all garbage and is inserted as ''. Initially i thought
the problem is in the database layer, but i found out that problem is not in
that layer. The request sent by the client is in Unicode, encoding is
UTF-8. But when the request is printed in the XmlRPC, it is getting
garbage. And XMLRPC encoding is set to UTF-8 in the application. So there
might be some place in tomcat where i should set the encoding. Can anyone
suggest me how to do that and give me any other suggestions.
And also i am testing this both on my local PC Tomcat instance and on Linux
box. Same code is being executed on both instances, but the behaviour is
different, on My PC instance i see that some of the field are encoded right,
but on Unix, evrything is inserted as . Both instances point to same
database and XMLRpc lib is same and Tomcat versions are same.
I am definitely missing something here. can someone please help



--- Shilpa Nalgonda [EMAIL PROTECTED] wrote:
can u point me to a resource how i can do it.

-Original Message-
From: Evgeny Gesin [mailto:[EMAIL PROTECTED]
Sent: Friday, October 29, 2004 9:42 AM
To: Tomcat Users List
Subject: Re: Internationalization of characters
--UTF8 encoding


.. is supposed to take japanese characters an
insert
them into database. Is there any setting in
Tomcat4
where i should be giving the encoding option.

You can specify parameters for SQL driver when you define DataSource
in Tomcat's server.xml. I think most of Oracle drivers can process
UTF-8, without the needs for such parameters, but MySQL 3.xx, for
example, needs such parameters...

Evgeny
Javadesk / AllTelescopes



__
Do you Yahoo!?
Yahoo! Mail Address AutoComplete - You start. We finish.
http://promotions.yahoo.com/new_mail


-
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]



__
Do you Yahoo!?
Yahoo! Mail Address AutoComplete - You start. We finish.
http://promotions.yahoo.com/new_mail
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



exception in clustering

2004-11-09 Thread Ronald Klop
Hello,
I've a cluster of two nodes with 5.0.25 running on Linux.
Everythings works fine for most of the day, but we are now getting this a lot 
on one server.
After shutting down this server, the other one still runs.
Nov 9, 2004 4:50:24 PM org.apache.catalina.cluster.tcp.TcpReplicationThread run
SEVERE: TCP Worker thread in cluster caught 'java.io.IOException: Connection 
reset by peer' closing channel
java.io.IOException: Connection reset by peer
 at sun.nio.ch.FileDispatcher.read0(Native Method)
 at sun.nio.ch.SocketDispatcher.read(SocketDispatcher.java:21)
 at sun.nio.ch.IOUtil.readIntoNativeBuffer(IOUtil.java:233)
 at sun.nio.ch.IOUtil.read(IOUtil.java:206)
 at sun.nio.ch.SocketChannelImpl.read(SocketChannelImpl.java:207)
 at 
org.apache.catalina.cluster.tcp.TcpReplicationThread.drainChannel(TcpReplicationThread.java:123)
 at 
org.apache.catalina.cluster.tcp.TcpReplicationThread.run(TcpReplicationThread.java:67)
and I also see this:
SEVERE: TCP Worker thread in cluster caught 'java.io.IOException: Connection 
reset by peer' closing channel
java.io.IOException: Connection reset by peer
 at sun.nio.ch.FileDispatcher.read0(Native Method)
 at sun.nio.ch.SocketDispatcher.read(SocketDispatcher.java:21)
 at sun.nio.ch.IOUtil.readIntoNativeBuffer(IOUtil.java:233)
 at sun.nio.ch.IOUtil.read(IOUtil.java:206)
 at sun.nio.ch.SocketChannelImpl.read(SocketChannelImpl.java:207)
 at 
org.apache.catalina.cluster.tcp.TcpReplicationThread.drainChannel(TcpReplicationThread.java:123)
 at 
org.apache.catalina.cluster.tcp.TcpReplicationThread.run(TcpReplicationThread.java:67)
 at org.apache.jk.server.JkCoyoteHandler.invoke(JkCoyoteHandler.java:296)
 at org.apache.jk.common.HandlerRequest.invoke(HandlerRequest.java:372)
 at org.apache.jk.common.ChannelSocket.invoke(ChannelSocket.java:694)
 at org.apache.jk.common.ChannelSocket.processConnection(ChannelSocket.java:626)
 at org.apache.jk.common.SocketConnection.runIt(ChannelSocket.java:807)
 at 
org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:644)
 at java.lang.Thread.run(Thread.java:534)
Can I solve this by tweaking some timeouts?
I'm about to upgrade to 5.0.28 soon. Is this going to help?
Ronald.


Re: exception in clustering

2004-11-09 Thread Ronald Klop
Yes, I understand that, but I was wondering if there is more experience with 
using a cluster under load.
I am thinking about timeout settings? Or maybe something else.
I have everything as default now.
Ronald.
On Tue Nov 09 17:21:47 CET 2004 Filip Hanik - Dev [EMAIL PROTECTED] wrote:
looks pretty normal, this shows that a connection was broken between one server 
and the other,
you need to figure out why it breaks? restart? network?
Filip
- Original Message - 
From: Ronald Klop [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Tuesday, November 09, 2004 10:02 AM
Subject: exception in clustering

Hello,
I've a cluster of two nodes with 5.0.25 running on Linux.
Everythings works fine for most of the day, but we are now getting this a lot 
on one server.
After shutting down this server, the other one still runs.
Nov 9, 2004 4:50:24 PM org.apache.catalina.cluster.tcp.TcpReplicationThread run
SEVERE: TCP Worker thread in cluster caught 'java.io.IOException: Connection 
reset by peer' closing channel
java.io.IOException: Connection reset by peer
at sun.nio.ch.FileDispatcher.read0(Native Method)
at sun.nio.ch.SocketDispatcher.read(SocketDispatcher.java:21)
at sun.nio.ch.IOUtil.readIntoNativeBuffer(IOUtil.java:233)
at sun.nio.ch.IOUtil.read(IOUtil.java:206)
at sun.nio.ch.SocketChannelImpl.read(SocketChannelImpl.java:207)
at 
org.apache.catalina.cluster.tcp.TcpReplicationThread.drainChannel(TcpReplicationThread.java:123)
at 
org.apache.catalina.cluster.tcp.TcpReplicationThread.run(TcpReplicationThread.java:67)
and I also see this:
SEVERE: TCP Worker thread in cluster caught 'java.io.IOException: Connection 
reset by peer' closing channel
java.io.IOException: Connection reset by peer
at sun.nio.ch.FileDispatcher.read0(Native Method)
at sun.nio.ch.SocketDispatcher.read(SocketDispatcher.java:21)
at sun.nio.ch.IOUtil.readIntoNativeBuffer(IOUtil.java:233)
at sun.nio.ch.IOUtil.read(IOUtil.java:206)
at sun.nio.ch.SocketChannelImpl.read(SocketChannelImpl.java:207)
at 
org.apache.catalina.cluster.tcp.TcpReplicationThread.drainChannel(TcpReplicationThread.java:123)
at 
org.apache.catalina.cluster.tcp.TcpReplicationThread.run(TcpReplicationThread.java:67)
at org.apache.jk.server.JkCoyoteHandler.invoke(JkCoyoteHandler.java:296)
at org.apache.jk.common.HandlerRequest.invoke(HandlerRequest.java:372)
at org.apache.jk.common.ChannelSocket.invoke(ChannelSocket.java:694)
at org.apache.jk.common.ChannelSocket.processConnection(ChannelSocket.java:626)
at org.apache.jk.common.SocketConnection.runIt(ChannelSocket.java:807)
at 
org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:644)
at java.lang.Thread.run(Thread.java:534)
Can I solve this by tweaking some timeouts?
I'm about to upgrade to 5.0.28 soon. Is this going to help?
Ronald.
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Tomcat and -server option

2004-11-15 Thread Ronald Klop
System.getProperty(...);
java.vm.name=Java HotSpot(TM) Client VM
(I'm not running with -server option...)
Ronald.
On Wed Nov 10 19:28:39 CET 2004 Mufaddal Khumri [EMAIL PROTECTED] wrote:
Hi,
I have specified the -server option in my catalina.sh using JAVA_OPTS.
JAVA_OPTS=-server -Djava.awt.headless=true -Xms1g -Xmx1g 
-Dfile.encoding=ISO-8859-1

When I log into the manager app in tomcat I can see that its taking the 
correct memory settings , but I could not find a way to verify that it 
is taking the -server flag into consideration. Is there a way to make 
sure that my JVM is taking the -server flag into consideration?

Additional info:
Tomcat Version: Apache Tomcat/5.0.27
JVM Version: 1.4.2_05-141.3
JVM Vendor: Apple Computer, Inc.
OS Name: Mac OS X
OS Version: 10.3.5
OS Architecture: ppc
Thanks.


Re: Tomcat and -server option

2004-11-15 Thread Ronald Klop
You are running Mac OS X. Does Apple support the Server Hotspot version? Maybe 
it falls back to client by default.
Ronald.
On Fri Nov 12 22:08:42 CET 2004 Mufaddal Khumri [EMAIL PROTECTED] wrote:
Hi,
I have: JAVA_OPTS=-server -Djava.awt.headless=true -Xms1g -Xmx1g 
-Dfile.encoding=ISO-8859-1 in catalina.sh

I just tried:
logger.info(java.vm.name:  + System.getProperty(java.vm.name));
and i get:
INFO - java.vm.name: Java HotSpot(TM) Client VM
Why is the -server option not taking effect?
Does java.vm.name display the mode the JVM is executing in or its name 
of the JVM installed on my machine? (because if its just the name of 
the JVM installed on my machine the -server option must be taking 
effect)

Thanks.
On Nov 12, 2004, at 1:53 PM, Shapira, Yoav wrote:

Hi,
Cool, good tip.

Yoav Shapira http://www.yoavshapira.com


-Original Message-
From: Caldarale, Charles R [mailto:[EMAIL PROTECTED]
Sent: Friday, November 12, 2004 3:14 PM
To: Tomcat Users List
Subject: RE: Tomcat and -server option

From: Shapira, Yoav [mailto:[EMAIL PROTECTED]
Subject: RE: Tomcat and -server option

Is there a way to make sure that my JVM is taking
the -server flag into consideration?

I'm not aware of a programmatic way to verify this.

The Java property java.vm.name (use System.getProperty(java.vm.name)
to
retrieve it) contains either Java HotSpot(TM) Server VM or Java
HotSpot(TM) Client VM when using Sun JVMs. Other vendors will, of
course,
set this property differently.

- Chuck


THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE
PROPRIETARY
MATERIAL and is thus for use only by the intended recipient. If you
received this in error, please contact the sender and delete the 
e-mail
and
its attachments from all computers.

-
To 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]


Mufaddal Khumri
Software Developer
Waves In Motion
Phone: 602 956 7080 x 26
Email: [EMAIL PROTECTED]



Re: Tomcat and -server option

2004-11-15 Thread Ronald Klop
java.library.path=/usr/local/j2sdk1.4.2_05/jre/lib/i386/client:...
   ^^
java.vm.name=Java HotSpot(TM) Client VM
 ^^
Ronald.
On Wed Nov 10 19:28:39 CET 2004 Mufaddal Khumri [EMAIL PROTECTED] wrote:
Hi,
I have specified the -server option in my catalina.sh using JAVA_OPTS.
JAVA_OPTS=-server -Djava.awt.headless=true -Xms1g -Xmx1g 
-Dfile.encoding=ISO-8859-1

When I log into the manager app in tomcat I can see that its taking the 
correct memory settings , but I could not find a way to verify that it 
is taking the -server flag into consideration. Is there a way to make 
sure that my JVM is taking the -server flag into consideration?

Additional info:
Tomcat Version: Apache Tomcat/5.0.27
JVM Version: 1.4.2_05-141.3
JVM Vendor: Apple Computer, Inc.
OS Name: Mac OS X
OS Version: 10.3.5
OS Architecture: ppc
Thanks.


NoSuchElementException in cluster

2004-11-16 Thread Ronald Klop
Hello,
I'm seeing these exceptions on one of my 2 nodes.
The memory cosumption of this server is now growing for a couple of hours, but 
I cannot tell if that is related with this.
I removed the server from the worker list of mod_jk so it is still in the 
cluster, but not receiving any requests anymore.
Any ideas about the exceptions. Are they harmless? Can they be related to a 
constantly growing amount of in-use memory?
I'm running Tomcat 5.0.25 on Linux 2.4 and 2.6 with JDK 1.4.2. It runs very 
well most of the time.
Ronald.
SEVERE: Unable to perform replication request.
java.util.NoSuchElementException
  at java.util.LinkedList.remove(LinkedList.java:579)
  at java.util.LinkedList.removeFirst(LinkedList.java:131)
  at 
org.apache.catalina.cluster.session.DeltaRequest.reset(DeltaRequest.java:153)
  at 
org.apache.catalina.cluster.session.DeltaSession.resetDeltaRequest(DeltaSession.java:938)
  at 
org.apache.catalina.cluster.session.DeltaManager.requestCompleted(DeltaManager.java:786)
  at 
org.apache.catalina.cluster.tcp.ReplicationValve.invoke(ReplicationValve.java:203)
  at 
org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:102)
  at 
org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:118)
  at 
org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:102)
  at 
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520)
  at 
org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
  at 
org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:104)
  at 
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520)
  at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:929)
  at org.apache.coyote.tomcat5.CoyoteAdapter.service(CoyoteAdapter.java:160)
  at org.apache.jk.server.JkCoyoteHandler.invoke(JkCoyoteHandler.java:300)
  at org.apache.jk.common.HandlerRequest.invoke(HandlerRequest.java:374)
  at org.apache.jk.common.ChannelSocket.invoke(ChannelSocket.java:743)
  at 
org.apache.jk.common.ChannelSocket.processConnection(ChannelSocket.java:675)
  at org.apache.jk.common.SocketConnection.runIt(ChannelSocket.java:866)
  at 
org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:683)
  at java.lang.Thread.run(Thread.java:534)
SEVERE: Unable to receive message through TCP channel
java.util.NoSuchElementException
  at java.util.LinkedList.remove(LinkedList.java:579)
  at java.util.LinkedList.removeFirst(LinkedList.java:131)
  at 
org.apache.catalina.cluster.session.DeltaRequest.reset(DeltaRequest.java:153)
  at 
org.apache.catalina.cluster.session.DeltaRequest.readExternal(DeltaRequest.java:184)
  at 
org.apache.catalina.cluster.session.DeltaManager.loadDeltaRequest(DeltaManager.java:385)
  at 
org.apache.catalina.cluster.session.DeltaManager.messageReceived(DeltaManager.java:898)
  at 
org.apache.catalina.cluster.session.DeltaManager.messageDataReceived(DeltaManager.java:762)
  at 
org.apache.catalina.cluster.tcp.SimpleTcpCluster.messageDataReceived(SimpleTcpCluster.java:576)
  at 
org.apache.catalina.cluster.io.ObjectReader.execute(ObjectReader.java:70)
  at 
org.apache.catalina.cluster.tcp.TcpReplicationThread.drainChannel(TcpReplicationThread.java:129)
  at 
org.apache.catalina.cluster.tcp.TcpReplicationThread.run(TcpReplicationThread.java:67)



Re: NoSuchElementException in cluster

2004-11-16 Thread Ronald Klop
Sorry, I'm using Tomcat 5.0.28. Somebody upgraded the boxes.
On Tue Nov 16 16:43:29 CET 2004 Ronald Klop [EMAIL PROTECTED] wrote:
Hello,
I'm seeing these exceptions on one of my 2 nodes.
The memory cosumption of this server is now growing for a couple of hours, but 
I cannot tell if that is related with this.
I removed the server from the worker list of mod_jk so it is still in the 
cluster, but not receiving any requests anymore.
Any ideas about the exceptions. Are they harmless? Can they be related to a 
constantly growing amount of in-use memory?
I'm running Tomcat 5.0.25 on Linux 2.4 and 2.6 with JDK 1.4.2. It runs very 
well most of the time.
Ronald.
SEVERE: Unable to perform replication request.
java.util.NoSuchElementException
at java.util.LinkedList.remove(LinkedList.java:579)
at java.util.LinkedList.removeFirst(LinkedList.java:131)
at org.apache.catalina.cluster.session.DeltaRequest.reset(DeltaRequest.java:153)
at 
org.apache.catalina.cluster.session.DeltaSession.resetDeltaRequest(DeltaSession.java:938)
at 
org.apache.catalina.cluster.session.DeltaManager.requestCompleted(DeltaManager.java:786)
at 
org.apache.catalina.cluster.tcp.ReplicationValve.invoke(ReplicationValve.java:203)
at 
org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:102)
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:118)
at 
org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:102)
at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520)
at 
org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
at 
org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:104)
at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520)
at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:929)
at org.apache.coyote.tomcat5.CoyoteAdapter.service(CoyoteAdapter.java:160)
at org.apache.jk.server.JkCoyoteHandler.invoke(JkCoyoteHandler.java:300)
at org.apache.jk.common.HandlerRequest.invoke(HandlerRequest.java:374)
at org.apache.jk.common.ChannelSocket.invoke(ChannelSocket.java:743)
at org.apache.jk.common.ChannelSocket.processConnection(ChannelSocket.java:675)
at org.apache.jk.common.SocketConnection.runIt(ChannelSocket.java:866)
at 
org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:683)
at java.lang.Thread.run(Thread.java:534)
SEVERE: Unable to receive message through TCP channel
java.util.NoSuchElementException
at java.util.LinkedList.remove(LinkedList.java:579)
at java.util.LinkedList.removeFirst(LinkedList.java:131)
at org.apache.catalina.cluster.session.DeltaRequest.reset(DeltaRequest.java:153)
at 
org.apache.catalina.cluster.session.DeltaRequest.readExternal(DeltaRequest.java:184)
at 
org.apache.catalina.cluster.session.DeltaManager.loadDeltaRequest(DeltaManager.java:385)
at 
org.apache.catalina.cluster.session.DeltaManager.messageReceived(DeltaManager.java:898)
at 
org.apache.catalina.cluster.session.DeltaManager.messageDataReceived(DeltaManager.java:762)
at 
org.apache.catalina.cluster.tcp.SimpleTcpCluster.messageDataReceived(SimpleTcpCluster.java:576)
at org.apache.catalina.cluster.io.ObjectReader.execute(ObjectReader.java:70)
at 
org.apache.catalina.cluster.tcp.TcpReplicationThread.drainChannel(TcpReplicationThread.java:129)
at 
org.apache.catalina.cluster.tcp.TcpReplicationThread.run(TcpReplicationThread.java:67)




mod_jk / sticky_session / fallback question

2004-11-19 Thread Ronald Klop
Hello,
I'm searching the internet for this question, but can't find the answer.
If I use mod_jk with sticky_session=true and session replication between to 
tomcat nodes.
Does mod_jk send the session to another server if the 'sticky' server fails?
Ronald.


Re: NoSuchElementException in cluster

2004-11-19 Thread Ronald Klop
Hello,
I found these two bug reports, looking similar to my issue below.
http://issues.apache.org/bugzilla/show_bug.cgi?id=27104
http://issues.apache.org/bugzilla/show_bug.cgi?id=31328
Are there any comments/ideas on this for version 5.0.x?
Ronald.
On Tue Nov 16 18:23:14 CET 2004 Ronald Klop [EMAIL PROTECTED] wrote:
Sorry, I'm using Tomcat 5.0.28. Somebody upgraded the boxes.
On Tue Nov 16 16:43:29 CET 2004 Ronald Klop [EMAIL PROTECTED] wrote:
Hello,
 
I'm seeing these exceptions on one of my 2 nodes.
The memory cosumption of this server is now growing for a couple of hours, but I cannot tell if that is related with this.
I removed the server from the worker list of mod_jk so it is still in the cluster, but not receiving any requests anymore.
 
Any ideas about the exceptions. Are they harmless? Can they be related to a constantly growing amount of in-use memory?
I'm running Tomcat 5.0.25 on Linux 2.4 and 2.6 with JDK 1.4.2. It runs very well most of the time.
 
Ronald.
 
SEVERE: Unable to perform replication request.
java.util.NoSuchElementException
at java.util.LinkedList.remove(LinkedList.java:579)
at java.util.LinkedList.removeFirst(LinkedList.java:131)
at org.apache.catalina.cluster.session.DeltaRequest.reset(DeltaRequest.java:153)
at org.apache.catalina.cluster.session.DeltaSession.resetDeltaRequest(DeltaSession.java:938)
at org.apache.catalina.cluster.session.DeltaManager.requestCompleted(DeltaManager.java:786)
at org.apache.catalina.cluster.tcp.ReplicationValve.invoke(ReplicationValve.java:203)
at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:102)
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:118)
at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:102)
at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520)
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:104)
at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520)
at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:929)
at org.apache.coyote.tomcat5.CoyoteAdapter.service(CoyoteAdapter.java:160)
at org.apache.jk.server.JkCoyoteHandler.invoke(JkCoyoteHandler.java:300)
at org.apache.jk.common.HandlerRequest.invoke(HandlerRequest.java:374)
at org.apache.jk.common.ChannelSocket.invoke(ChannelSocket.java:743)
at org.apache.jk.common.ChannelSocket.processConnection(ChannelSocket.java:675)
at org.apache.jk.common.SocketConnection.runIt(ChannelSocket.java:866)
at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:683)
at java.lang.Thread.run(Thread.java:534)
 
SEVERE: Unable to receive message through TCP channel
java.util.NoSuchElementException
at java.util.LinkedList.remove(LinkedList.java:579)
at java.util.LinkedList.removeFirst(LinkedList.java:131)
at org.apache.catalina.cluster.session.DeltaRequest.reset(DeltaRequest.java:153)
at org.apache.catalina.cluster.session.DeltaRequest.readExternal(DeltaRequest.java:184)
at org.apache.catalina.cluster.session.DeltaManager.loadDeltaRequest(DeltaManager.java:385)
at org.apache.catalina.cluster.session.DeltaManager.messageReceived(DeltaManager.java:898)
at org.apache.catalina.cluster.session.DeltaManager.messageDataReceived(DeltaManager.java:762)
at org.apache.catalina.cluster.tcp.SimpleTcpCluster.messageDataReceived(SimpleTcpCluster.java:576)
at org.apache.catalina.cluster.io.ObjectReader.execute(ObjectReader.java:70)
at org.apache.catalina.cluster.tcp.TcpReplicationThread.drainChannel(TcpReplicationThread.java:129)
at org.apache.catalina.cluster.tcp.TcpReplicationThread.run(TcpReplicationThread.java:67)
 
 
 




Re: NoSuchElementException in cluster

2004-11-22 Thread Ronald Klop
Thanks.
How bad is it that I get these errors now? Wil I loose sessions?
Ronald.
On Fri Nov 19 20:34:21 CET 2004 Filip Hanik - Dev [EMAIL PROTECTED] wrote:
I've updated the delta request to avoid these errors in the next release of tomcat5.0 and tomcat 5.5
 
Filip
- Original Message -
From: Ronald Klop
To: Filip Hanik - Dev
Sent: Friday, November 19, 2004 10:44 AM
Subject: Re: NoSuchElementException in cluster
Yes, but we never change the session. It only holds the User object, which is 
set at login.
I have looked at the tomcat code. This session replication is not thread safe 
as is documented.
This is my server.xml. It is a quite heavily used web-application with about 
2000-3000 sessions, 30 req/sec.
   Cluster className=org.apache.catalina.cluster.tcp.SimpleTcpCluster

managerClassName=org.apache.catalina.cluster.session.DeltaManager
expireSessionsOnShutdown=false
useDirtyFlag=true
   Membership
   className=org.apache.catalina.cluster.mcast.McastService
   mcastAddr=228.0.0.4
   mcastPort=45564
   mcastFrequency=500
   mcastDropTime=3000/
   Receiver
   className=org.apache.catalina.cluster.tcp.ReplicationListener
   tcpListenAddress=213.53.208.169
   tcpListenPort=4001
   tcpSelectorTimeout=100
   tcpThreadCount=6/
   Sender
   
className=org.apache.catalina.cluster.tcp.ReplicationTransmitter
   replicationMode=pooled/
   Valve className=org.apache.catalina.cluster.tcp.ReplicationValve
  filter=.*\.gif;.*\.js;.*\.jpg;.*\.htm;.*\.html;.*\.txt;/
   /Cluster
Ronald.
On Fri Nov 19 17:17:19 CET 2004 Filip Hanik - Dev [EMAIL PROTECTED] wrote:
are you using frames or in anyway have your system setup to access the same 
session by more than one thread?
Filip
- Original Message - 
From: Ronald Klop [EMAIL PROTECTED]
To: Tomcat Users List [EMAIL PROTECTED]
Cc: Ronald Klop [EMAIL PROTECTED]
Sent: Friday, November 19, 2004 5:35 AM
Subject: Re: NoSuchElementException in cluster

Hello,
I found these two bug reports, looking similar to my issue below.
http://issues.apache.org/bugzilla/show_bug.cgi?id=27104
http://issues.apache.org/bugzilla/show_bug.cgi?id=31328
Are there any comments/ideas on this for version 5.0.x?
Ronald.
On Tue Nov 16 18:23:14 CET 2004 Ronald Klop [EMAIL PROTECTED] wrote:
Sorry, I'm using Tomcat 5.0.28. Somebody upgraded the boxes.
 
On Tue Nov 16 16:43:29 CET 2004 Ronald Klop [EMAIL PROTECTED] wrote:
Hello,
 
I'm seeing these exceptions on one of my 2 nodes.
The memory cosumption of this server is now growing for a couple of hours, but I cannot tell if that is related with this.
I removed the server from the worker list of mod_jk so it is still in the cluster, but not receiving any requests anymore.
 
Any ideas about the exceptions. Are they harmless? Can they be related to a constantly growing amount of in-use memory?
I'm running Tomcat 5.0.25 on Linux 2.4 and 2.6 with JDK 1.4.2. It runs very well most of the time.
 
Ronald.
 
SEVERE: Unable to perform replication request.
java.util.NoSuchElementException
at java.util.LinkedList.remove(LinkedList.java:579)
at java.util.LinkedList.removeFirst(LinkedList.java:131)
at org.apache.catalina.cluster.session.DeltaRequest.reset(DeltaRequest.java:153)
at org.apache.catalina.cluster.session.DeltaSession.resetDeltaRequest(DeltaSession.java:938)
at org.apache.catalina.cluster.session.DeltaManager.requestCompleted(DeltaManager.java:786)
at org.apache.catalina.cluster.tcp.ReplicationValve.invoke(ReplicationValve.java:203)
at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:102)
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:118)
at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:102)
at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520)
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:104)
at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520)
at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:929)
at org.apache.coyote.tomcat5.CoyoteAdapter.service(CoyoteAdapter.java:160)
at org.apache.jk.server.JkCoyoteHandler.invoke(JkCoyoteHandler.java:300)
at org.apache.jk.common.HandlerRequest.invoke(HandlerRequest.java:374)
at org.apache.jk.common.ChannelSocket.invoke(ChannelSocket.java:743)
at org.apache.jk.common.ChannelSocket.processConnection(ChannelSocket.java:675)
at org.apache.jk.common.SocketConnection.runIt(ChannelSocket.java:866)
at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:683)
at java.lang.Thread.run(Thread.java:534)
 
SEVERE: Unable to receive message through TCP channel

Re: high traffic Tomcat sites out there?

2004-11-22 Thread Ronald Klop
On Mon Nov 22 11:55:08 CET 2004 LAM Kwun Wa Joseph [EMAIL PROTECTED] wrote:
For my Tomcat cluster I'm looking for an upper limit on the estimation of
how much traffic it may face. Say, would thousands of HTTP req/s be too
'astronomical' for a 4-node Dual P4 Xeon cluster to achieve? (I'm talking
about dynamic pages such as stock quotes and news)
Does anyone know of any high traffic JSP/servlet sites(running Tomcat or
similar servlet container)? I'm mostly interested to know what's the
typical magnitude of their HTTP throughput (e.g. hundreds or thousands
of HTTP/s) and what kinds of apps are they running.
Joseph Lam

Hello,
I am also interested in some realworld figures. Our configuration is this.
2-node cluster of 2-cpu P4-2.8Ghz machines.
The  web-application is a database application (with a lot of updates and 
non-index queries) for logged-in users.
We have about 1500 logged in persons doing 70 req/s. Half of the requests go to 
Tomcat, the other half to Apache for static content.
The average (Tomcat) req takes about 250 ms in our system.
But I have no idea if this is an high/average/low load compared to other 
systems.
Btw, we are using Tomcat 5.0.28, JDK 1.4.2, Debian Sarge (linux 2.6.x), Apache 
1.3.x/mod_jk 1.2.6.
Ronald.


Re: HTTP Compression

2004-11-24 Thread Ronald Klop
I think two things are mixed here.
Compression and port value are different things.
BTW: we use compression=on. I like using defaults as long as they work.
Ronald.
On Tue Nov 23 17:49:20 CET 2004 deepak shripat mane [EMAIL PROTECTED] wrote:
 For client purpose u have to specify port value so must be specify integer 
value that value between 1024 to 65536
Deepak

On Tue, 23 Nov 2004 andrew wrote :
Hi all,

I am looking at enabling compression on Tomcat 5.0.25.
Is everyone using compress=on or should I use an integer (?number of bytes?)

Thanks

Andrew

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]




Re: Does Tomcat Rollback transactions automatically.

2004-11-24 Thread Ronald Klop
Do not mix webserver and database logic.
Tomcat does only webserving.
Ronald.
On Tue Nov 23 22:35:06 CET 2004 Shilpa Nalgonda [EMAIL PROTECTED] wrote:
Hi ,
I am using Tomcat 4.1.30, and using datasource to get the Connection from
Pool.
When there is an exception in the database operations, the trasaction is
supposed to rollback.
Is it automatically performed in Tomcat?

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Tomcat Requirements?

2004-11-30 Thread Ronald Klop
Is the system using swap? You should tune the java app (Tomcat) to not use more 
memory than is available without swapping.
Ronald.
On Mon Nov 29 20:43:07 CET 2004 Chris Cherrett [EMAIL PROTECTED] wrote:
I have a client who is claiming that my software is slowing down. I cannot 
determine why this would be. He is running the following:

P3 - 450 with 360MB of RAM
with 2 IDE - 7200 RPM drives mirrored Raid 1 with Win2k
I have found that any client running a faster system works great. Do you have 
any suggestions as to how to speed things up on this hardware configuration? 
example increase memory allocated to Tomcat.

Thanks
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



jsp+bean (tomcat) Sample Code

2004-12-23 Thread Ronald Andia
***
Your mail has been scanned by InterScan.
***-***


Hi, I am developing a new application using jsp+bean with tomcat 5.
 
I don't have problems whit forms, but I don't know if bean is a good
architecture for reports...(using the bean to access the database)...or
maybe is better use only jsp for report purposes?
 
If you have any code sample, I appreciate it
 
thanks



Re: Running lots of virtual hosts on tomcat

2005-01-19 Thread Ronald Klop
RJ,
I think with a filter we can do our own version of mod_vhost.
But for reloading the classes/jsps it needs two instances of Tomcat (maybe on 
the same machine) with a loadbalancer to update one without interrupting the 
user.
Or is the compiler build into Tomcat 5.5 fast enough (and without memory leaks 
enough) to run it on a production machine.
Ronald.

On Wed Jan 19 15:37:30 CET 2005 Tomcat Users List tomcat-user@jakarta.apache.org wrote:
Hi,
Our web department is thinking about moving from coldfusion to tomcat.
Currently we have about 400 websites using apache's mod_vhost module.
This works great. The only thing one needs to do is create a new
directory www.bla.nl and the website is up and running.
How would one do this in tomcat? I figured putting all the domainnames
in server.xml is not an option since it would require restarting
tomcat all the time. Using one Engine with a Context for each website
seems more usable.
Does anybody here have this kind of setup? Any pitfalls we might run
into? Suggestions?
Regards,
Robbert-Jan Roos
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Found a racing condition?

2004-05-25 Thread Ronald Klop
Today I got this when doing a request during Tomcat startup. Can it be a racing 
condition?
Greetings,
Ronald.
INFO: Starting Coyote HTTP/1.1 on port 8080
May 25, 2004 1:37:14 PM org.apache.coyote.tomcat5.CoyoteAdapter service
SEVERE: An exception or error occurred in the container during the request processing
java.lang.NullPointerException
   at 
org.apache.catalina.realm.RealmBase.findSecurityConstraints(RealmBase.java:475)
   at 
org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:502)
   at 
org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:149)
   at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:567)
   at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:184)
   at 
org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:151)
   at 
org.apache.catalina.cluster.tcp.ReplicationValve.invoke(ReplicationValve.java:182)
   at 
org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:149)
   at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:164)
   at 
org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:149)
   at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:567)
   at 
org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:156)
   at 
org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:151)
   at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:567)
   at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:972)
   at org.apache.coyote.tomcat5.CoyoteAdapter.service(CoyoteAdapter.java:206)
   at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:833)
   at 
org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.processConnection(Http11Protocol.java:732)
   at org.apache.tomcat.util.net.TcpWorkerThread.runIt(PoolTcpEndpoint.java:619)
   at 
org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:688)
   at java.lang.Thread.run(Thread.java:534)
May 25, 2004 1:37:15 PM org.apache.jk.common.ChannelSocket init
INFO: JK2: ajp13 listening on /0.0.0.0:8009


RE: Found a racing condition?

2004-05-26 Thread Ronald Klop
I don't know why it is a race condition. The error just happened once and I could 
not reproduce it.
But I don't know enough about the internals of Tomcat to what really happens there. 
Just mailed it, so somebody who knows can do something with (or not).
Ronald.
On Tue May 25 14:50:06 CEST 2004 Shapira, Yoav [EMAIL PROTECTED] wrote:

Hi,
I don't think that's a race condition (it's race, not racing, by the way ;)). But I'm 
curious to hear your reasoning as to why you suspect that?
Yoav Shapira
Millennium Research Informatics

-Original Message-
From: Ronald Klop [mailto:[EMAIL PROTECTED]
Sent: Tuesday, May 25, 2004 8:18 AM
To: [EMAIL PROTECTED]
Subject: Found a racing condition?
Today I got this when doing a request during Tomcat startup. Can it be a
racing condition?
Greetings,
Ronald.
INFO: Starting Coyote HTTP/1.1 on port 8080
May 25, 2004 1:37:14 PM org.apache.coyote.tomcat5.CoyoteAdapter service
SEVERE: An exception or error occurred in the container during the request
processing
java.lang.NullPointerException
   at
org.apache.catalina.realm.RealmBase.findSecurityConstraints(RealmBase.java:
475)
   at
org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBas
e.java:502)
   at
org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveConte
xt.java:149)
   at
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:567)
   at
org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:18
4)
   at
org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveConte
xt.java:151)
   at
org.apache.catalina.cluster.tcp.ReplicationValve.invoke(ReplicationValve.ja
va:182)
   at
org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveConte
xt.java:149)
   at
org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:16
4)
   at
org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveConte
xt.java:149)
   at
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:567)
   at
org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.jav
a:156)
   at
org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveConte
xt.java:151)
   at
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:567)
   at
org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:972)
   at
org.apache.coyote.tomcat5.CoyoteAdapter.service(CoyoteAdapter.java:206)
   at
org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:833)
   at
org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.processConn
ection(Http11Protocol.java:732)
   at
org.apache.tomcat.util.net.TcpWorkerThread.runIt(PoolTcpEndpoint.java:619)
   at
org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.ja
va:688)
   at java.lang.Thread.run(Thread.java:534)
May 25, 2004 1:37:15 PM org.apache.jk.common.ChannelSocket init
INFO: JK2: ajp13 listening on /0.0.0.0:8009


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]



default for reloadable setting

2004-06-02 Thread Ronald Klop
Hello,
The docs on http://jakarta.apache.org/tomcat/tomcat-5.0-doc/config/context.html do not 
mention the default setting of reloadable.
Does anybody know what it is?
Greetings,
Ronald.


maxPostSize and file upload

2004-06-02 Thread Ronald Klop
Hello,
Does the maxPostSize setting for the Connector in server.xml affect the max. size of a 
file upload?
Ronald.


Re: maxPostSize and file upload

2004-06-02 Thread Ronald Klop
Is it possible that this does not work?
The docs (http://jakarta.apache.org/tomcat/tomcat-5.0-doc/config/ajp.html) say that 
the default is 2MB, but I can download much larger files.
Is this a bug or a feature?
By the way: I upload using commons-fileupload.
Ronald.
On Wed Jun 02 14:04:45 CEST 2004 Veniamin Fichin [EMAIL PROTECTED] wrote:

Ronald Klop wrote:
Does the maxPostSize setting for the Connector in server.xml affect the
max. size of a file upload?
Since file upload occurs with POST method, yes it restricts upload
file size.
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: maxPostSize and file upload

2004-06-02 Thread Ronald Klop
After rereading the docs I understand that the maxPostSize if for FORM URL 
parameter passing.
I think they mean the parameters in the form key1=val2key2=val2... So it is not for 
file upload I think, only for regular posts.
Unfortunately I don't have time to look in the source, but if somebody knows about 
this maybe the docs can be updated to be more verbose about this.
Ronald.
On Wed Jun 02 15:44:24 CEST 2004 Veniamin Fichin [EMAIL PROTECTED] wrote:

Ronald Klop wrote:
Is it possible that this does not work?
The docs
(http://jakarta.apache.org/tomcat/tomcat-5.0-doc/config/ajp.html) say
that the default is 2MB, but I can download much larger files.
Is this a bug or a feature?
Don't know, I never used it. Additionally, I have no ajp.html file
in my Tomcat-5.0.16 distribution, that's strange, 'cause online site has
it. Try to set maxPostSize to 2Mb explicitlyto see if it will work.
It was a long time ago when I read one article on PHP file upload
where it was said that you can't determine a size of uploading data
before it at least reaches defined limit, furthermore an error only
arised when upload is finished regardless of its actual size (will it be
100Mb or even 100Gb). But I may be wrong.
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: HTTP header for dynamic pdf and IE6

2004-06-07 Thread Ronald Klop
Is it possible that IE saves the document in the cache than starts acrobat with 
the filename in the cache and than removes the file because you set no-cache and 
expire options before acrobat can open it?
Ronald.
On Sat Jun 05 11:52:03 CEST 2004 Dean A. Hoover [EMAIL PROTECTED] wrote:

I have a java web application that allows
an end-user in their browser to download
a file, which happens to be bytes stored
in a database.
In experimenting with how to do this, I have
this snippet of code in my servlet:
AttachmentListItem attachment =
EmailSQL.getAttachmentListItem(connection, 3, 1);
response.setContentType(attachment.getContentType());
byte[] data =
EmailSQL.getAttachmentBytes(connection, 3, 1);
response.setContentLength(data.length);
response.setHeader(Content-Disposition,
attachment; filename=\ + attachment.getFileName() + \);
ServletOutputStream out = response.getOutputStream();
out.write(data);
out.flush();
out.close();
To test this out, I hit the link in my IE browser which brings up
a dialog box allowing me to Open or Save the file. If I save
the file, it does the right thing. If I press the open button, Acrobat
Reader opens up and then errors out with an alert box:
There was an error opening the document. The file does not exist.
I have a yahoo email account that I tried a test on. I sent an email
message with the same pdf file attached to that account. I wanted to
see if yahoo figured out how to make this work. They did! (but I can't
figure out how to replicate)
Their header looks like this:
Date: Thu, 03 Jun 2004 15:37:58 GMT
P3P: policyref=http://p3p.yahoo.com/w3c/p3p.xml;, CP=CAO DSP COR CUR
ADM DEV TAI PSA PSD IVAi IVDi CONi TELo OTPi OUR DELi SAMi OTRi UNRi
PUBi IND PHY ONL UNI PUR FIN COM NAV INT DEM CNT STA POL HEA PRE GOV
Content-Disposition: attachment; filename=reference.pdf
Connection: close
Transfer-Encoding: chunked
Content-Type: application/pdf; filename=foo.bar
.s4g--v=1
There is also some other stuff I am seeing just after the header: .s4g-v=1
which looks something like a query string, but I'm not sure.
My header looks like this:
HTTP/1.1 200 OK
Date: Thu, 03 Jun 2004 15:35:15 GMT
Server: Apache/2.0.40 (Red Hat Linux) mod_perl/1.99_07-dev Perl/v5.8.0
mod_jk/1.2.5 PHP/4.2.2 mod_python/3.0.1 Python/2.2.2 mod_ssl/2.0.40
OpenSSL/0.9.7a
Set-Cookie: JSESSIONID=DD3D0938B780EEBEBDC1B558CCBAD095; Path=/
Pragma: No-cache
Cache-Control: no-cache
Expires: Thu, 01 Jan 1970 00:00:00 GMT
Content-Disposition: attachment; filename=reference.pdf
Content-Length: 214982
Keep-Alive: timeout=15, max=100
Connection: Keep-Alive
Content-Type: application/pdf;charset=UTF-8
Does anyone know how to work around this problem? I suppose
there are actually 2 parts to this:
1) What is the magic in the HTTP header that allows this to work?
2) How can one create such a header in java?
Thanks.
Dean Hoover

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Tomcat on FreeBSD

2004-06-28 Thread Ronald Klop
You can also try this question on [EMAIL PROTECTED] or [EMAIL PROTECTED]
Did you use the ports version of tomcat5?
If not, please do.
Does it work if you first install jdk14 and then tomcat5. I think the port will notice 
that jdk14 is already installed.
If no jdk is installed I think it will try jdk13 first, because that is the only 
'licensed by Sun' version for FreeBSD for now.
But I'm not really sure about this. I do have jdk14 and tomcat5 running here.
Greetings,
Ronald.
On Mon Jun 28 09:37:06 CEST 2004 Sergey Velikanov [UzPAK] [EMAIL PROTECTED] wrote:

Hello
I'm trying install tomcat on FreeBSD, but why tomcat needs
/usr/local/diablo-jdk1.3.1 in startup process although on installation
it use /usr/local/jdk1.4.2/bin/java
why it so? and how I can run tomcat with /usr/local/jdk1.4.2/bin/java
# uname -sr
FreeBSD 5.2.1-RELEASE
[root jakarta-tomcat5]# make install
=== Installing for jakarta-tomcat-5.0.19
=== jakarta-tomcat-5.0.19 depends on file: /usr/local/jdk1.4.2/bin/java - found
=== Generating temporary packing list
=== Checking if www/jakarta-tomcat5 already installed
Creating destination directory... [ DONE ]
Copying files to destination directory... [ DONE ]
Compiling and installing control program... [ DONE ]
Installing startup script... [ DONE ]
Installing man pages... [ DONE ]
Creating log files... [ DONE ]
Creating symlink to tools.jar... [ DONE ]
Fixing ownership settings... [ DONE ]
Fixing permissions... [ DONE ]
Creating PID file... [ DONE ]
Jakarta Tomcat 5.0.19 has been installed in /usr/local/jakarta-tomcat5.0.
If a user should be able to use tomcat50ctl, then put this user in the group www.
Use 'man tomcat50ctl' for information about starting and stopping Jakarta Tomcat.
[root jakarta-tomcat5]# /usr/local/bin/tomcat50ctl start
Reading PID file (/var/run/tomcat50.pid)... [ DONE ]
Starting Jakarta Tomcat 5.0.19... [ FAILED ]
tomcat50ctl: Unable to stat /usr/local/diablo-jdk1.3.1: No such file or directory

Sergey Velikanov
Technical Division
National Data Network UzPAK
tel +(99871) 114-6326
e-mail: [EMAIL PROTECTED]
http://www.uzpak.uz/

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: RE: Klaus-Dieter -V715101- Ackermann/Volksfuersorge/AMComNET/DE ist außer Haus.

2004-06-28 Thread Ronald Klop
It is a german out-of-office message.
On Mon Jun 28 18:43:56 CEST 2004 Guy [EMAIL PROTECTED] wrote:

What is this crap?
-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED]
Sent: Monday, June 28, 2004 12:19 PM
To: Tomcat Users List
Subject: Klaus-Dieter -V715101- Ackermann/Volksfuersorge/AMComNET/DE ist
außer Haus.


Ich werde ab 28.06.2004 nicht im Büro sein. Ich kehre zurück am
01.07.2004.
Ich werde Ihre Nachrichten nach meiner Rückkehr beantworten.
-
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]



compressableMimeTypes

2004-07-06 Thread Ronald Klop
Hello,
I have put this in my server.xml.
compression=on
compressableMimeTypes=text/html,text/xml,text/plain,text/javascript,text/css
But it does not compress text/javascript and text/css. (It does compress text/html.)
Is this setting ignored? Not implemented yet?
I don't have the source at hand, so I can't check it myself.
Greetings,
Ronald.


Re: compressableMimeTypes (extra info)

2004-07-07 Thread Ronald Klop
I forgot to mention I'm running Tomcat 5.0.25 on Debian Linux with Sun JDK 1.4.2.
Ronald.
On Tue Jul 06 15:39:27 CEST 2004 Ronald Klop [EMAIL PROTECTED] wrote:

Hello,
I have put this in my server.xml.
compression=on
compressableMimeTypes=text/html,text/xml,text/plain,text/javascript,text/css
But it does not compress text/javascript and text/css. (It does compress text/html.)
Is this setting ignored? Not implemented yet?
I don't have the source at hand, so I can't check it myself.
Greetings,
Ronald.


Anybody using compressableMimeTypes?

2004-07-13 Thread Ronald Klop
Hello,
I'm using the Connector options compression=on and 
compressableMimeTypes=text/html,text/xml,text/plain,text/javascript,text/css. But it looks 
like Tomcat is just using its defaults for compressableMimeTypes. Does anybody experience the same thing? 
I filed a bugreport on this earlier this week, but am looking for more info. I'm using Tomcat 5.0.25 in a 
standalone environment (no apache in front of it).
Greetings,
Ronald.


Re: Wildcard virtual hosts help

2004-07-16 Thread Ronald Klop
You can use a default host if I remember correct.
All hosts which don't have there own mapping will be handled by the default host.
Ronald.
On Thu Jul 15 22:11:03 CEST 2004 Cott Lang [EMAIL PROTECTED] wrote:

I have a specific problem that requires that I map hundreds of thousands
(yes, hundreds of thousands) of domain names to a dozen or so different
web-apps based on domain name. I currently use Resin to handle this, but
really wish to abandon Resin for Tomcat for a variety of reasons.
Uniquely defining each one as a web app isn't practical due to the sheer
number involved, and the fact that hundreds of domain names come and go
during the day.
I've googled and searched the archives, and I can't seem to find an
answer to how to do this with Tomcat 5, if it's even possible. I've seen
several people asked, and the only one I found a number of responses to
was chided for his decision to use wildcards. :)
I would immensely appreciate it if anyone could point me in the
direction of how to implement something like:
Host name='*.mydomain.com'
(which I've tried to no avail)
thanks!

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Bug in deploying .war with Tomcat Manager.

2004-08-13 Thread Ronald Klop
)
   at 
org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.processChildren(ContainerBase.java:1619)
   at 
org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.processChildren(ContainerBase.java:1628)
   at 
org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.run(ContainerBase.java:1608)
   at java.lang.Thread.run(Thread.java:534)
13-aug-2004 11:00:54 org.apache.catalina.core.StandardHostDeployer install
INFO: Installing web application at context path /crm from URL 
file:C:/Tomcat5/webapps/crm
13-aug-2004 11:00:58 org.apache.catalina.core.StandardHostDeployer install
INFO: Installing web application at context path /crm from URL 
file:C:/Tomcat5/webapps/crm
End stacktrace

Does anybody use this? Is this a known problem?
Greetings,
Ronald.


Re: Changing session-cookie(JSESSIONID) name in tomat

2004-08-23 Thread Ronald Klop
Use grep JSESSIONID * and build your own Tomcat.
Ronald.
On Mon Aug 23 18:26:55 CEST 2004 Dineshram Villuri [EMAIL PROTECTED] wrote:

Hi,
Is there a way we can change JSESSIONID name? I mean can we have a different
cookie name to store sessionid? If yes how I can configure it in tomcat.
I have two applications running on different tomcats in the same physical
box. Both applications use the same authentication mechanism (wherein when 2
users are logged in with the same username the earlier one is kicked
out/logged off). At any time there should be only one user logged in with
the same user name. Though both these use the same mechanism they are 2
independent application but for some weird reasons should run on the same
box.
Now we understand that the problem is with the cookie-name JSESSIONID. Since
both the applications are having the same cookie name(JSESSIONID) if one
user logs on into app1 and an other one is logged on to app2(diff tomcat)
with the same username the earlier one is kicked out.
We are facing this problem only when 2 tomcats are running on the same box.
When they are running on different boxes it works fine but we have to run
them on the same box for other reasons.
Can someone please point me to a different solution (if available) in case
JSESSIONID cannot be changed?
Any help is greatly appreciated.
Thanks,
Dinesh.


Re: Tomcat Server Status

2004-08-31 Thread Ronald Klop
Look at the http://your-hostname/manager/html webapp.
See also: http://jakarta.apache.org/tomcat/tomcat-5.0-doc/manager-howto.html
Ronald.
On Tue Aug 31 12:54:51 CEST 2004 Kashif Siddiqui [EMAIL PROTECTED] wrote:
Hi all, 

I am sucessfully running Tomcat server, now I want to
know that is there any way to get Tomcat server's
1. Server's Status
2. Start Time 
3. Server uptime
4. Current requests on server

Thanks in advance...

__
Do you Yahoo!?
New and Improved Yahoo! Mail - Send 10MB messages!
http://promotions.yahoo.com/new_mail 

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Tomcat Server Status

2004-08-31 Thread Ronald Klop
On Tue Aug 31 13:14:22 CEST 2004 Kashif Siddiqui [EMAIL PROTECTED] wrote:
Thank you very much for guidance,
but this page don't show StartTime/UpTime of Tomcat
Server...
http://localhost:/manager/html
Is there any way to get it.

I use a ServletContextListener for this. It has a 'static long startTime = 
System.currentTimeMillis();' or something like that. I can query this from a jsp or 
servlet.
Ronald.



Re: How do I get an intermediary proxy from caching?

2004-08-31 Thread Ronald Klop
Yes. To be precise: you have to set the headers before Tomcat flushes its outputbuffer 
for the first time. To be save, just set headers, than output html.
Ronald,
On Tue Aug 31 20:10:13 CEST 2004 [EMAIL PROTECTED] [EMAIL PROTECTED] wrote:
Must you do this as one of the first things you do, before you output any
html?
--
Christopher Cullum
[EMAIL PROTECTED]
John Gentilin said:
When I am battling against IE caching or proxy caching, I add the
following lines
to my response header. A bit brute force but it seems to work, althought
I think
it cause some issues when backing up on a form, forcing a reload.

response.setHeader(Cache-Control,
no-cache,max-age=0,must-revalidate);
response.setHeader(Pragma, no-cache);
response.setHeader(Expires, -1d);

[EMAIL PROTECTED] wrote:

Hello all,
I have taken a cursory look at the documentation for tomcat 5.x and I
could not see how to get intermediary proxy's from caching my web page.
I have the tags:
meta http-equiv=pragma content=no-cache
meta http-equiv=cache-control content=no-cache
META HTTP-EQUIV=Expires CONTENT=Wed, 01 Sep 2004 17:52:51 GMT

in my head section, but the proxy still caches my page. I read
somewhere to put the cache-control:no-cache in the http header of the
request, but I could not find how to do this in tomcat. Any help would
be appreciated.






- 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: AW: ThreadPool: Pool exhausted with 100 threads

2004-09-06 Thread Ronald Klop
On Mon Sep 06 00:40:14 CEST 2004 Matt Robinson [EMAIL PROTECTED] wrote:
Steffen,
Many thanks for the response. The reason we stuck with
3.2.4 was because of stability. However, as we have
become more successful our systems have been receiving
heavier loads and thus, the Threadpool exhausted
problem.
Regarding stability/reliability (uptime is a greater
concern for us than performance), would you recommend
5.0 over 4.x or vice versa? 

Also curious if anyone has experienced thread pool
problems (or successes) with medium to high load
systems under either 4.x or 5.0.
Thanks again,
Matt

How many threads do you have when it is exhausted and what is the error message you 
get?
We are running Tomcat 5 with about hundred threads quite ok here. Tomcat 5 is much 
more efficient, so it can help you to try it out.
Ronald.



Re: AW: ThreadPool: Pool exhausted with 100 threads

2004-09-06 Thread Ronald Klop
On Mon Sep 06 00:40:14 CEST 2004 Matt Robinson [EMAIL PROTECTED] wrote:
Steffen,
Many thanks for the response. The reason we stuck with
3.2.4 was because of stability. However, as we have
become more successful our systems have been receiving
heavier loads and thus, the Threadpool exhausted
problem.
Regarding stability/reliability (uptime is a greater
concern for us than performance), would you recommend
5.0 over 4.x or vice versa? 

Also curious if anyone has experienced thread pool
problems (or successes) with medium to high load
systems under either 4.x or 5.0.
Thanks again,
Matt
What OS are you running? Last week I tweaked glibc of debian 3.0 to support more 
threads, because the defaults are quite low for heavily threaded programs.
Ronald.


Re: AW: ThreadPool: Pool exhausted with 100 threads

2004-09-07 Thread Ronald Klop
So, this is an error from the ThreadPool and not from java or the OS. The errors I got we're errors from the OS because of a limited nr of threads per process. There areissues with the ThreadPool solved in both 4 and 5 (see changelogs), so maybe this will be solved for you also.
At my work I use a jsp which I will attach. It shows all running threads and threadgroups by there name. It gave me some usefull insight in the inner workings of Tomcat.
Ronald.

On Tue Sep 07 07:08:10 CEST 2004 Matt Robinson [EMAIL PROTECTED] wrote:
Ronald,The exact error message is "ThreadPool: Pool exhaustedwith 100 threads", so I assume we have 100 threadsrunning -- once this error message appears Tomcatstops responding until it is restarted. Is there asimple way to check # of threads in use by Tomcat atany given time?We are running Tomcat 3.2.4 and J2SE 1.4 on Windows2000. Based on yours and other feedback, we plan onupgrading to 4.x or 5.0 but not sure which is theright choice.Thanks,Matt--- Ronald Klop [EMAIL PROTECTED] wrote: On Mon Sep 06 00:40:14 CEST 2004 Matt Robinson [EMAIL PROTECTED] wrote:  Steffen,Many thanks for the response. The reason we stuck with  3.2.4 was because of stability. However, as we have  become more successful our systems have been receiving  heavier loads and thus, the Threadpool exhausted  problem.Regarding stability/reliability (uptime is a greater  concern for us than performance), would you recommend  5.0 over 4.x or vice versa? Also curious if anyone has experienced thread pool  problems (or successes) with medium to high load  systems under either 4.x or 5.0.Thanks again,  Matt How many threads do you have when it is exhausted and what is the error message you get? We are running Tomcat 5 with about hundred threads quite ok here. Tomcat 5 is much more efficient, so it can help you to try it out.  Ronald.   __Do you Yahoo!?Read only the mail you want - Yahoo! Mail SpamGuard.http://promotions.yahoo.com/new_mail -To unsubscribe, e-mail: [EMAIL PROTECTED]For additional commands, e-mail: [EMAIL PROTECTED]%@ page
info = $Id: threads.jsp,v 1.2 2003/05/26 19:24:55 ronald Exp $
import = 
java.util.Calendar,
java.util.TimeZone

%
%!
class Group {
JspWriter out;
Group(JspWriter out) {
this.out = out;
}
void print(ThreadGroup tg, String prefix) throws java.io.IOException {
int i;
out.println(prefix + G  + tg.getName());
ThreadGroup[] tga = new ThreadGroup[tg.activeGroupCount()];
int nr = tg.enumerate(tga, false);
for(i = 0; i  nr; i++) {
this.print(tga[i], prefix + \t);
}
Thread[] ta = new Thread[tg.activeCount()];
nr = tg.enumerate(ta, false);
String[] names = new String[nr];
for(i = 0; i  names.length; i++) {
names[i] = ta[i].getName();
}
java.util.Arrays.sort(names);
for(i = 0; i  nr; i++) {
out.println(prefix + T  + names[i]);
}
}
}
%
html
head
   %@ include file=/pub/exec/baseDHTML.jspf %
!-- %=getServletInfo()% --
titleThreads - %=request.getServerName()%/title
/head
body
%
java.util.Date now = 
Calendar.getInstance(TimeZone.getTimeZone(Europe/Amsterdam)).getTime();
%
Time: %=now.toString()%br/
pre
%
Thread current = Thread.currentThread();
ThreadGroup tg = current.getThreadGroup();
while(tg.getParent() != null) {
tg = tg.getParent();
}
Group g = new Group(out);
g.print(tg, );
%
/pre
/body
/html

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Re: AW: ThreadPool: Pool exhausted with 100 threads

2004-09-08 Thread Ronald Klop
Hi Matt,
Another option is this. If you do 'kill -QUIT process-id' on Linux or ctrl-break on 
Windows in the dosbox running Java (if this is how you run Tomcat) it will print all 
stacktraces of all threads. Very helpfull to track down lost Threads.
And another 'trick' I use is the following filter.
doFilter(request, response, chain) {
Thread currThr = Thread.currentThread();
 String oldName = currThr.getName();
try {
  currThr.setName(request.getRequestURI());
  chain.doFilter(request, response);
} finally {
  currThr.setName(oldName);
}
}
The jsp with the threadlist than displays the URL's which are being processed. Very 
helpfull. But as far as I now Tomcat 3 doesn't support filters.
Greetings,
Ronald.
On Tue Sep 07 23:18:39 CEST 2004 Matt Robinson [EMAIL PROTECTED] wrote:
Ronald, Thanks this is quite helpful - using your jsp
I can see where we hit 100 threads and Tomcat freezes.
As I monitor our systems the number of threads slowly
grows until 100 is reached. The threads I see when
monitoring (using your JSP page) are not closed --
instead they seem to hang out until the 100 mark is
reached (at which point we have to restart Tomcat).
In effort to avoid this, it looks like we'll be
switching to 5.0.28 after some initial testing. Any
further suggestions more than welcome
Thanks again,
Matt
--- Ronald Klop [EMAIL PROTECTED] wrote:
So, this is an error from the ThreadPool and not
from java or the OS. The errors I got we're errors
from the OS because of a limited nr of threads per
process. There are issues with the ThreadPool solved
in both 4 and 5 (see changelogs), so maybe this will
be solved for you also.
 
At my work I use a jsp which I will attach. It shows
all running threads and threadgroups by there name.
It gave me some usefull insight in the inner
workings of Tomcat.
 
Ronald.
 
 
 
On Tue Sep 07 07:08:10 CEST 2004 Matt Robinson
[EMAIL PROTECTED] wrote:
Ronald,
 
The exact error message is ThreadPool: Pool
exhausted
with 100 threads, so I assume we have 100 threads
running -- once this error message appears Tomcat
stops responding until it is restarted. Is there a
simple way to check # of threads in use by Tomcat
at
any given time?
 
We are running Tomcat 3.2.4 and J2SE 1.4 on
Windows
2000. Based on yours and other feedback, we plan
on
upgrading to 4.x or 5.0 but not sure which is the
right choice.
 
Thanks,
Matt
 
--- Ronald Klop [EMAIL PROTECTED]
wrote:
 
On Mon Sep 06 00:40:14 CEST 2004 Matt Robinson
[EMAIL PROTECTED] wrote:
Steffen,
 
Many thanks for the response. The reason we
stuck
with
3.2.4 was because of stability. However, as we
have
become more successful our systems have been
receiving
heavier loads and thus, the Threadpool exhausted
problem.
 
Regarding stability/reliability (uptime is a
greater
concern for us than performance), would you
recommend
5.0 over 4.x or vice versa? 
 
Also curious if anyone has experienced thread
pool
problems (or successes) with medium to high load
systems under either 4.x or 5.0.
 
Thanks again,
Matt
 
 
 
How many threads do you have when it is exhausted
and what is the error message you get?
We are running Tomcat 5 with about hundred
threads
quite ok here. Tomcat 5 is much more efficient,
so
it can help you to try it out.
 
Ronald.
 
 
 
 
 
 
 
__
Do you Yahoo!?
Read only the mail you want - Yahoo! Mail
SpamGuard.
http://promotions.yahoo.com/new_mail 
 


-
To unsubscribe, e-mail:
[EMAIL PROTECTED]
For additional commands, e-mail:
[EMAIL PROTECTED]
 
 
%@ page
info = $Id: threads.jsp,v 1.2 2003/05/26 19:24:55
ronald Exp $
import = 
java.util.Calendar,
java.util.TimeZone

%
%!
class Group {
JspWriter out;
Group(JspWriter out) {
this.out = out;
}
void print(ThreadGroup tg, String prefix) throws
java.io.IOException {
int i;
out.println(prefix + G  + tg.getName());
ThreadGroup[] tga = new
ThreadGroup[tg.activeGroupCount()];
int nr = tg.enumerate(tga, false);
for(i = 0; i  nr; i++) {
this.print(tga[i], prefix + \t);
}
Thread[] ta = new Thread[tg.activeCount()];
nr = tg.enumerate(ta, false);
String[] names = new String[nr];
for(i = 0; i  names.length; i++) {
names[i] = ta[i].getName();
}
java.util.Arrays.sort(names);
for(i = 0; i  nr; i++) {
out.println(prefix + T  + names[i]);
}
}
}
%
html
head
%@ include file=/pub/exec/baseDHTML.jspf %
!-- %=getServletInfo()% --
titleThreads -
%=request.getServerName()%/title
/head
body
%
java.util.Date now =

Calendar.getInstance(TimeZone.getTimeZone(Europe/Amsterdam)).getTime();
%
Time: %=now.toString()%br/
pre
%
Thread current = Thread.currentThread();
ThreadGroup tg = current.getThreadGroup();
while(tg.getParent() != null) {
tg = tg.getParent();
}
Group g = new Group(out);
g.print(tg, );
%
/pre
/body
/html
 

-
To unsubscribe, e-mail:
[EMAIL PROTECTED]
For additional commands, e-mail:
[EMAIL PROTECTED]


__
Do you Yahoo

Re: 'referer' header contains Servlet path, not referrer

2004-09-10 Thread Ronald Klop
You can send this back to the browser.
body onload='alert(you have an error.); history.go(-1);'/body
On Fri Sep 10 12:51:42 CEST 2004 Keith Hankin [EMAIL PROTECTED] wrote:

My code is in the Servlet, and I can't access Javascript within the Servlet.
- Original Message -
From: Tim Funk [EMAIL PROTECTED]
To: Tomcat Users List [EMAIL PROTECTED]
Sent: Friday, September 10, 2004 4:10 PM
Subject: Re: 'referer' header contains Servlet path, not referrer

javascript:history.go(-1) ?
-Tim
Keith Hankin wrote:
Here's the scenario: I am getting input data from the user and have
determined that the user has made an error. I want to redisplay the last
page so they can fix the errors.
- Original Message -
From: QM [EMAIL PROTECTED]
To: Tomcat Users List [EMAIL PROTECTED]
Sent: Thursday, September 09, 2004 6:50 PM
Subject: Re: 'referer' header contains Servlet path, not referrer

On Thu, Sep 09, 2004 at 03:16:19PM +0530, Keith Hankin wrote:
: I am trying to determine what JSP page sent me to my Servlet, so I use
request.getHeader(referer). Unfortunately, the String returned is the
Servlet itself and not the actual referer. This seems like a bug to me.
Is
there some way to get the actual referer?
The referer header isn't reliable. Browsers may refuse to send it,
for privacy reasons.
What's your high-level goal?
-
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]



unsetting characterEncoding?

2004-10-12 Thread Ronald Klop
Hello,
Is it possible to unset the character encoding for some requests.
I call setCharacterEncoding(windows-1252) for every request in a filter.
But now my image/jpeg servlets add charset to the content-type.
If I now call setCharacterEncoding(null) in my image-servlet it doesn't unset the 
charset.
How can I do this?
Ronald.
PS: I know it is not necessary, because the browser will ignore this parameter to content-type, but is just saves those extra bytes. :-)


Re: Multiple arguments in a GET URL

2004-10-04 Thread Ronald Klop
You should escape the value of mainFrame, so the webserver will not parse it in 
index.jsp.
Ronald.
On Fri Oct 01 19:34:04 CEST 2004 [EMAIL PROTECTED] [EMAIL PROTECTED] wrote:
I am attempting to redirect to a URL that is similar to the following

http://www.mysite.com/index.jsp?mainFrame=somePage.jsp?item1=info1
http://www.mysite.com/index.jsp?mainFrame=somePage.jsp?item1=info1item2=in
fo2 item2=info2

However, I can only do a request.getParameter on item1 in the somePage.jsp
JSP. When I attempt to do it for item2, it fails..

Any ideas? Workarounds?

Azam Khan





RE: Multiple arguments in a GET URL

2004-10-04 Thread Ronald Klop
You better escape the value than replacing one character. This doesn't solve your 
issue on the long run.
See java.net.URLEncoder.
String args = mainFrame= + URLEncoder(url, UTF-8);
Ronald.
On Mon Oct 04 04:34:05 CEST 2004 [EMAIL PROTECTED] [EMAIL PROTECTED] wrote:
Eric:
Thanks for your help. Now that I think about it, it appears that is what is
happening. I will modify the code tomorrow morning to pass the second
ampersand as an ASCII value. 

Thanks everyone for your input on this !!

Thanks,
Azam Khan
Network Data Support Center
Verizon Wireless
866-222-7114
http://ndsc.eng.vzwcorp.com
-Original Message-
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] 
Sent: Friday, October 01, 2004 7:59 PM
To: [EMAIL PROTECTED]
Cc: [EMAIL PROTECTED]
Subject: Re: Multiple arguments in a GET URL

On Fri, Oct 01, 2004 at 05:10:22PM -0400, [EMAIL PROTECTED]
wrote:
it sees hello as expected
 
-Original Message-
From: Caldarale, Charles R [mailto:[EMAIL PROTECTED] 

http://ndsc.eng.vzwcorp.com/index.jsp?mainFrame=blahblah.jsp?arg1=helloarg2
=helloagain
 
In this scenario, I am able to perform a request.getParameter 
on arg1 in blahblah.jsp but when I try to do it on arg2, I 
receive a null pointer exception.
 
For curiosity's sake, what value does blahblah.jsp see for arg1?

Oh, I bet I know what you're doing. In index.jsp you're probably
using
the value of mainFrame directly as the url to load in the frame. But the
value of the mainFrame arg is blahblah.jsp?arg1=hello, not just plain
blahblah.jsp. That's why you can get arg1. arg2 is just another
parameter being passed to index.jsp.
You need to either escape those 's so the whole thing after 
mainFrame= is the value of mainFrame, or index.jsp needs to explicitly
append any of _it's_ args (i.e. mainFrame and arg2) to the frame url.
(or rather, any that you think should be passed on)

eric
-
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]



Race condition in session handling?

2004-10-25 Thread Ronald Klop
Hello, I get this stacktrace when using Tomcat 5.0.25, Java 1.4.2 on Linux.
java.util.NoSuchElementException
java.util.HashMap$HashIterator.nextEntry(HashMap.java:785)
java.util.HashMap$KeyIterator.next(HashMap.java:818)
java.util.AbstractCollection.toArray(AbstractCollection.java:174)
org.apache.catalina.session.StandardSession.keys(StandardSession.java:1523)
org.apache.catalina.session.StandardSession.expire(StandardSession.java:706)
org.apache.catalina.session.StandardSession.expire(StandardSession.java:632)
org.apache.catalina.session.StandardSession.invalidate(StandardSession.java:1051)
org.apache.catalina.session.StandardSessionFacade.invalidate(StandardSessionFacade.java:149)
nl.base.servlets.Login.processRequest(Login.java:100)
nl.base.servlets.Login.doGet(Login.java:81)
nl.base.servlets.Login.doPost(Login.java:114)
javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
javax.servlet.http.HttpServlet.service(HttpServlet.java:810)
It is probably caused by my code in which the login screen and logout action are 
conflicting, but I would expect to get this exception from Tomcat.
Any thoughts?
Ronald.


Re: which Linux Platform is best for Tomcat?

2004-10-26 Thread Ronald Klop
My company is running a 2-node cluster of Tomcat 5.0.25 on Debian Woody (custom 
upgraded kernel 2.4 and 2.6) with about 70 requests/sec.
Recently we started upgrading some test machines to Debian Sarge, which still runs 
very well.
Ronald.
On Tue Oct 26 15:27:44 CEST 2004 sudip shrestha [EMAIL PROTECTED] wrote:
Hi!
We are going to use Tomcat as our J2EE Server for the next project. I was 
wondering if anybody knows of some sort of comparative study of performance 
of Tomcat on different Linux Distributions. Recently I have seen that 
people were posting problems about Debian (woody). We are thinking of 
Fedora Core 2. Any suggestions/comments are welcome.

Regards,
Sudip

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



voting for 5.0.29?

2004-10-27 Thread Ronald Klop
Sorry if I missed something, but what was the result of the vote if 5.0.29 is stable 
or beta?
Does somebody has a link to the mail thread?
Ronald.


proxy support and X-Forwarded-For

2004-10-28 Thread Ronald Klop
Hallo,
Does Tomcat support the headers: X-Forwarded-For, X-Forwarded-Host and 
X-Forwarded-Server when running behind a proxy?
And if not, would this be a nice feature?
I'm running Tomcat 5.0.25 behind Apache 1.3/mod_proxy and doesn't look like Tomcat 
uses these headers.
Any thoughts?
I'm willing to try to implement these if it is needed by more people.
Ronald.


Re: AW: proxy support and X-Forwarded-For

2004-10-28 Thread Ronald Klop
On Thu Oct 28 19:50:35 CEST 2004 Steffen Heil [EMAIL PROTECTED] wrote:
Hi
Does Tomcat support the headers: X-Forwarded-For, X-Forwarded-Host and
X-Forwarded-Server when running behind a proxy?
I'm running Tomcat 5.0.25 behind Apache 1.3/mod_proxy and doesn't look
like Tomcat uses these headers.
What would you expect tomcat to do when these headers are present?
Regards,
Steffen

X-Forwarded-For contains the IP address of the client, so Tomcat can return that in 
ServletRequest.getRemoteAddr() in stead of the IP of the proxy server.
I understand this is a security risk if you didn't close your firewall. It is possible to add an 
option trustProxy=true|false to the config.
X-Forwarded-Host and X-Forwarded-Server contain the server name from the request. This 
can override the setting proxyName.
I still have to find out the difference between X-Forwarded-Host and 
X-Forwarded-Server as Apache fills them with the same value in my case.
Ronald.


Re: Installing tomcat 5 on BSD 5

2004-02-13 Thread Ronald Klop
The native JDK 1.4 is doing very well (and is fast) on FreeBSD. If you have the 
time to compile it I would suggest you try that one.
I'm using it a lot, without problems.
See also the [EMAIL PROTECTED] for more info about this.

Greetings,

Ronald.

On Thu Feb 12 13:50:41 CET 2004 Thomas Cherry [EMAIL PROTECTED] wrote:



Do you know which versions of java are required for each of the
versions of Tomcat (3, 4, 5)? Specifically, which will run under
1.1.8? Upgrading my java is not a trivial task, I will have to compile
my own copy of jdk.
--
It is pointless to resist. - Darth Vader, Sith Lord
On Feb 12, 2004, at 7:43 AM, Arnab Chakravarty wrote:

Bad major version numbers are result of classes compiled on 2 different
version of jdk.
Please upgrade you jvm and then see if it helps (preferable jdk1.4 and
up).
Arnab C

-Original Message-
From: Thomas Cherry [mailto:[EMAIL PROTECTED]
Sent: Thursday, February 12, 2004 5:42 PM
To: Tomcat Users List
Subject: Installing tomcat 5 on BSD 5
I'm trying to install tomcat onto a new FreeBSD system but I am getting

an error when I try to start the server. After modifying
setclasspath.sh to output more information and to use classes.zip, I
ran catalina.sh and got the following output:
# ./catalina.sh run
Using CATALINA_BASE: /usr/local/jakarta-tomcat-5.0.18
Using CATALINA_HOME: /usr/local/jakarta-tomcat-5.0.18
Using CATALINA_TMPDIR: /usr/local/jakarta-tomcat-5.0.18/temp
Using JAVA_HOME: /usr/local/jdk1.1.8
Using CLASSPATH:
/usr/local/jdk1.1.8/lib/classes.zip:/usr/local/jakarta-tomcat-5.0.18/
bin/bootstrap.jar:/usr/local/jakarta-tomcat-5.0.18/bin/commons-logging-
api.jar
Error loading class org.apache.catalina.startup.Bootstrap: Bad major
version number
My java version is 1.1.8. Will Tomcat 5 run under this version of
java? (I'm starting to think no)
--
The ability to destroy a planet is insignificant next to the power of
the Force. -Darth Vader, Sith Lord.
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: [ANN] Apache Tomcat 5.0.19 Stable and Tomcat 4.1.30 Stable released

2004-02-23 Thread Ronald Klop
On Mon Feb 23 10:38:08 CET 2004 Remy Maucherat [EMAIL PROTECTED] wrote:

The Tomcat Team announces the immediate availability of Apache Tomcat
5.0.18 Stable and Tomcat 4.1.30 Stable.


I think you copy-and-pasted a little to much. The subject and body don't match 5.0.19 - 5.0.18. The website is wrong about this also.

Greetings,

Ronald.


RE: [ANN] Apache Tomcat 5.0.19 Stable and Tomcat 4.1.30 Stable released

2004-02-23 Thread Ronald Klop
On Mon Feb 23 14:44:30 CET 2004 Shapira, Yoav [EMAIL PROTECTED] wrote:

Howdy,

I think you copy-and-pasted a little to much. The subject and body
don't
match 5.0.19 - 5.0.18. The website is wrong about this also.
Where's the website wrong?

Yoav Shapira



 

http://jakarta.apache.org/site/news.html#20040223.1

But I see it's fixed already.

Greetings,

Ronald.


5.0.19 docs about new clustering config?

2004-03-02 Thread Ronald Klop
Hello,

Are there (up-to-date) docs about the new clustering config in 5.0.19?
Some attributes are not in the example config (like 'name') and the documents arn't 
very clear if it's still needed or not.
Greetings,

Ronald.


Re: Do servlet threads ever die?

2004-03-02 Thread Ronald Klop
On Tue Mar 02 04:02:30 CET 2004 Christopher Schultz [EMAIL PROTECTED] wrote:

Ken,

Problem: I call native code (Tcl) from my servlet. Tcl's thread model
forces me to run Tcl only on the thread that created the Tcl
interpreter. So now how do I cleanup these interpreters? The cleanup
code needs to be run on the creating thread.
Guh. I highly recommend against running native code from an app server.
There are lots of reasons I could enumerate if you ask. Number one
reason: crashed native code = crashed server. :(
Is there a way you can call the Tcl code through a socket or by invoking
another process and communicating with it via stdin/stdout? (see
java.lang.Process)
Do servlet threads ever die besides during shutdown? If not, I may have
no problem.
AFAIK, Tomcat never retires threads unless something horrible happens
(or tomcat is shutting down).
Can I register a listener to be invoked on the thread before it shuts
down?
I don't think you can do this to a thread. You might be able to hack
Tomcat's thread pool so that you can cleanup after a thread if it's
going to be retired. I don't have any good ideas.
Sorry I couldn't help more.

-chris

Hello,

I use a webstart app with JINI for these things. Very easy. I can start a server on 
any host by webstart and it automaticly connects to the webserver by JINI.
You can also create a Thread of your own in the Tomcat server, which you control 
yourself, but indeed. If you native code crashes, your server crashes.
Ronald.


Re: SystemThreadList.java update?

2005-02-01 Thread Ronald Klop
Hello,
I use the attached .jsp to view all the threads.
Ronald.
On Fri Jan 28 12:33:10 CET 2005 Tomcat Users List tomcat-user@jakarta.apache.org wrote:
There is a June 2002 mail thread that discusses "How to list all Threads in the JVM?". It includes a handy Java class that is supposed to return all sorts of information on these threads.But, the class does not seem to examine the entire ThreadGroup tree.The constructor creates an ArrayList of ThreadGroups along a tree branch from the current thread to the root, but other tree branches are ignored.Unfortunately, the mail thread ended without any further discussion.Is there some significance between this branch of the ThreadGroup tree and the way Tomcat creates ThreadGroups or is this a bug in the suggested code?Also getThreadCount() seems to return the number of ThreadGroups in the branch rather than the number of Threads in the JVM.Regards,Bob Feretichpackage com.mpi.chemi.portal.util;import java.util.ArrayList;import java.util.List;import org.apache.log4j.Logger;public class SystemThreadList{/*** The list of threads.*/private ArrayList _threads;/*** Constructor. Creates a list of all the* threads running in the JVM in the system.*/public SystemThreadList(){_threads = new ArrayList();ThreadGroup tg = Thread.currentThread().getThreadGroup();if(tg != null){_threads.add(tg);while(tg.getParent() != null){tg = tg.getParent();if(tg != null){_threads.add(tg);/*** Returns the thread count.** @return int*/public int getThreadCount(){if(_threads == null)return -1;elsereturn _threads.size();}/*** Returns the thread group at the given index.** @param index* @return ThreadGroup*/public ThreadGroup getThreadGroup(int index){if(getThreadCount()  1)return null;else if((index  0) || (index  (getThreadCount() - 1)))return null;elsereturn (ThreadGroup)_threads.get(index);}/*** Prints out the list of threads.*/public void printThreads(){System.out.println(toString());}/*** Returns a String representation of this* SystemThreadList.** @return String*/public String toString(){StringBuffer sb = new StringBuffer("[SystemThreadList:\n");if(getThreadCount()  1){sb.append(" No Threads ");}else{for(int i = 0; i  getThreadCount(); i++){sb.append(" ThreadGroup " + i + "= ");sb.append(getThreadGroup(i).toString());sb.append(", activeCount = " + getThreadGroup(i).activeCount());sb.append("\n");}}// Total active countsb.append(" totalActiveCount = " + getTotalActiveCount() + "\n");sb.append(" (End of SystemThreadList)]");return sb.toString();}/*** Returns the total active count: goes over* every group in the list, and sums their activeCount()* results.** @return int*/public int getTotalActiveCount(){if(getThreadCount()  1)return 0;else{int totalActiveCount = 0;ThreadGroup tg = null;for(int i = 0; i  getThreadCount(); i++){tg = getThreadGroup(i);totalActiveCount += tg.activeCount();}return totalActiveCount;}}/*** Returns the root thread group, i.e.* the one whose parent is null.** @return ThreadGroup*/public ThreadGroup getRootThreadGroup(){if(getThreadCount()  1)return null;else{ThreadGroup tg = null;for(int i = 0; i  getThreadCount(); i++){tg = getThreadGroup(i);if(tg.getParent() == null){return tg;}}// If we got here, we didn't find one, so return null.return null;}}/*** Gets all the threads.** @return Thread[]*/public Thread[] getAllThreads(){int estimatedCount = getTotalActiveCount();// Start with array twice size of estimated,// to be safe. Trim later.Thread[] estimatedThreads = new Thread[estimatedCount * 2];// Locate root groupThreadGroup rootGroup = getRootThreadGroup();if(rootGroup == null){return null;}int actualCount = rootGroup.enumerate(estimatedThreads, true);// Check that something was returnedif(actualCount  1)return null;// Copy into actualThreads of correct sizeThread[] actualThreads = new Thread[actualCount];for(int i = 0; i  actualThreads.length; i++){actualThreads[i] = estimatedThreads[i];}return actualThreads;}/*** Gets all the threads whose name contains the* given string. The search is CASE-SENSITIVE.** @param nameMatch* @return List*/public List getThreadsWithNameMatch(String nameMatch){Thread[] allThreads = getAllThreads();if((allThreads == null) || (allThreads.length  1)){return null;}else{ArrayList matchingThreads = new ArrayList();for(int i = 0; i  allThreads.length; i++){if(allThreads[i].getName().indexOf(nameMatch)  -1)matchingThreads.add(allThreads[i]);}if((matchingThreads == null) || (matchingThreads.size()  1))return null;elsereturn matchingThreads;}}/*** Tries to destory the root group.*/public void destroyRootThreadGroup(){ThreadGroup rootGroup = getRootThreadGroup();if(rootGroup == null){return;}else{rootGroup.destroy();}}/*** Main. Tests the functionality.** @param args*/public static void main(String[] args){System.out.println("SystemThreadList: main(): starting.");// Create listSystemThreadList stl = new SystemThreadList();// Print info

Fatal: Stack size too small. Use 'java -Xss' to increase default stack size.

2005-04-11 Thread Ronald Klop
Hello,
My Tomcat logs this in catalina.out.
Fatal: Stack size too small. Use 'java -Xss' to increase default stack size.
I don't see a stack trace, so I can't figure out what is really going wrong 
here.
My current setup is jdk 1.4.2_08 on linux 2.6.x with Tomcat 5.0.28. We are 
using these parameters to start Java/Tomcat: -Xmx1024m -Xms1024m 
-Djava.awt.headless=true -Dsun.net.inetaddr.ttl=60. Tomcat is clustered with 3 
nodes.
Is this a known problem for anybody? Does increasing -Xss solve the problem or 
does it only make it happen less often?
We are running a heavy webapp with 2500 users logged in for 8 hours a day (so 
sessions live long).
Ronald.


Re: Can a client recapture a session in Tomcat 4.1

2005-05-13 Thread Ronald Klop
Yes. You only have to sent the right cookie header to the server. And if the 
browser exits the right header info is lost.
So, if you create a browser which doesn't loose cookie info, you are done.
This has nothing to do with which server you are running. For php, asp or 
anything else it works the same.
Ronald.
On Thu May 12 16:57:29 CEST 2005 Tomcat Users List tomcat-user@jakarta.apache.org wrote:
Can a client recapture his Tomcat session after he
has accidentally closed the browser, provided that
the session object still exists on the server?
Would this be a browser-specific thing? After all,
I guess I'd need to tell the browser to persist
the session cookie or some such thing. Or would it
work browser-independently using URL-rewriting?
If there is such a mechanism, does it pose any
security concerns (e. g. through Tomcat reusing
a session-id for a totally different session?)
We're on Tomcat 4.1. Would the answer be any
different for Tomcat 5.0?
Thanks for any enlightenment or additional
pointers-. -- Sebastian
--
Sebastian Millies, IDS Scheer AG
Postfach 10 15 34, 66015 Saarbr?cken
Zi D1.16, [EMAIL PROTECTED]
fon +49-681-210-3221, fax +49-681-210-1311
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: 5.5 FreeBSD Port

2005-05-20 Thread Ronald Klop
You can try to mail the port maintainer of the tomcat5 port. See 
/usr/ports/www/jakarta-tomcat5/Makefile.
If you have issues about jdk 1.5 on bsd being flaky, please post them on [EMAIL 
PROTECTED]
Ronald.
On Fri May 20 11:06:03 CEST 2005 Tomcat Users List tomcat-user@jakarta.apache.org wrote:
Hi -
I was just wondering if anyone out there had installed 5.5 on FreeBSD? 
I've been using 5.0 on BSD, which was easy to install, as there is a 
portfile defined. Was wondering whether to wait for /try to hack my own 
portfile, or just install 5.5 manually (the instructions seem fairly 
straightforward). (and yes, I know jdk1.5 is a bit flaky on BSD, I'm 
going to use the linux 1.5jdk and see what happens... for development at 
least).

thanks
Tim
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Urgent: how to detect client has closed connection

2005-06-01 Thread Ronald Klop

What Writer are you using? If you do response.getWriter() you will get a 
PrintWriter and the docs tell you that PrintWriter doesn't throw exceptions, so 
your app keeps printing to the writer after an error. (A closed connection is 
an IOException.)
If you use the default out property of a jsp page you get a JspWriter which 
does throw exeptions on error.

Ronald.

On Tue May 31 19:42:30 CEST 2005 Tomcat Users List 
tomcat-user@jakarta.apache.org wrote:

Hey guys,

I have a problem right now. I wrote a Jsp page to keep sending data to 
client browser. However, no exception was thrown when I use out.print() to 
send something to client even after client has closed his web browser. My 
question is how can i know his browser is closed, so I can stop sending.
Also, from the tomcat logs, the reset by peer socket exception was thrown 
by Tomcat. however, seems i don't have a way to catch it.


Can anybody help me with this one... I will be really thankful to any help 
from you.


Thanks,
Luke

_
Express yourself instantly with MSN Messenger! Download today it's FREE! 
http://messenger.msn.click-url.com/go/onm00200471ave/direct/01/



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]





Re: Urgent: how to detect client has closed connection

2005-06-07 Thread Ronald Klop

Sorry,

But I have no more suggestions. I would have to debug it myself than and don't 
have the time for that. Maybe somebody else on the list can tell you more. 
Maybe posting some snippets of code helps.

Ronald.

On Thu Jun 02 22:25:12 CEST 2005 lapson lee [EMAIL PROTECTED] wrote:

Hey Ronald,

Thanks for your help. I checked the code. I use default out.. and it indeed 
was using javax.servlet.jsp.JspWriter, but it does not throw an IOException. 
Do you know why?


Thanks in advance...

Luke




From: Ronald Klop [EMAIL PROTECTED]
Reply-To: Tomcat Users List tomcat-user@jakarta.apache.org
To: Tomcat Users List tomcat-user@jakarta.apache.org
Subject: Re: Urgent: how to detect client has closed connection
Date: Wed, 1 Jun 2005 14:14:08 +0200 (CEST)

What Writer are you using? If you do response.getWriter() you will get a 
PrintWriter and the docs tell you that PrintWriter doesn't throw 
exceptions, so your app keeps printing to the writer after an error. (A 
closed connection is an IOException.)
If you use the default out property of a jsp page you get a JspWriter which 
does throw exeptions on error.


Ronald.

On Tue May 31 19:42:30 CEST 2005 Tomcat Users List 
tomcat-user@jakarta.apache.org wrote:

Hey guys,

I have a problem right now. I wrote a Jsp page to keep sending data to 
client browser. However, no exception was thrown when I use out.print() to 
send something to client even after client has closed his web browser. My 
question is how can i know his browser is closed, so I can stop sending.
Also, from the tomcat logs, the reset by peer socket exception was 
thrown by Tomcat. however, seems i don't have a way to catch it.


Can anybody help me with this one... I will be really thankful to any help 
from you.


Thanks,
Luke

_
Express yourself instantly with MSN Messenger! Download today it's FREE! 
http://messenger.msn.click-url.com/go/onm00200471ave/direct/01/



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



_
Don't just search. Find. Check out the new MSN Search! 
http://search.msn.com/






  1   2   >