BugRat Report #729 has been filed.

2001-01-10 Thread BugRat Mail System

Bug report #729 has just been filed.

You can view the report at the following URL:

   http://znutar.cortexity.com/BugRatViewer/ShowReport/729

REPORT #729 Details.

Project: Tomcat
Category: Bug Report
SubCategory: New Bug Report
Class: webbug
State: received
Priority: high
Severity: serious
Confidence: public
Environment: 
   Release: tomcat version 3.1
   JVM Release: jdk1.2.2
   Operating System: window2000
   OS Release: version 5.2195
   Platform: window

Synopsis: 
Tomcat make illegal operation and close itself suddenly

Description:
This situation is that my project require to make 4 modules that are jsp, servlet, 
javabean and library modules. The relation of  them are that

jsp - javabean - library
   jsp - servlet - library

This library module are responsible for all database related functions, and other 
modules only get , transform and send data to library.

About my database related source codes use only basic syntax
such as

   ...
   Class.forName(DRIVER);
   conn = DriverManager.getConnection(url);
   stmt = conn.createStatement();
   rst = stmt.executeQuery(sql);
   ...

   - DRIVER = sun.jdbc.odbc.JdbcOdbcDriver
   - url = jdbc:odbc:[my DSN name]

I found that when I view JSP page or make servlet  request  through web browser. Many  
times tomcat program make illegal operation and then window200 terminate it suddenly.
I don't know what are cause. I try to check this situation by
creating new servlet source code whose functions only sequentially select data from 
3-5 tables in one database. The result is that I still found this illegal operation.

My test servlet source code is that 

  ... CODE HEADER ...
   try {
   Class.forName(DRIVER);
   } catch (Exception e) {}

  String sql = "select * from table_a";
   try {
   conn = DriverManager.getConnection(url);
   stmt = conn.createStatement();
   rst = stmt.executeQuery(sql);
   } catch (Exception e) {}
   
   sql = "select * from table_b";
   try {
   conn = DriverManager.getConnection(url);
   stmt = conn.createStatement();
   rst = stmt.executeQuery(sql);
   } catch (Exception 

   sql = "select * from table_c";
   try {
   conn = DriverManager.getConnection(url);
   stmt = conn.createStatement();
   rst = stmt.executeQuery(sql);
   } catch (Exception 

   ... CODE TAIL ...


Title: 
BugRat Report #
729





BugRat Report #
729




Project:
Tomcat


Release:
tomcat version 3.1




Category:
Bug Report


SubCategory:
New Bug Report




Class:
webbug


State:
received




Priority:
high


Severity:
serious




Confidence:
public





Submitter:
Anan T.L. ([EMAIL PROTECTED])

Date Submitted:
Jan 10 2001, 03:59:19 CST

Responsible:
Z_Tomcat Alias ([EMAIL PROTECTED])


Synopsis:

Tomcat make illegal operation and close itself suddenly


 Environment: (jvm, os, osrel, platform)

jdk1.2.2, window2000, version 5.2195, window



Additional Environment Description:





Report Description:

This situation is that my project require to make 4 modules that are jsp, servlet, javabean and library modules. The relation of  them are that

jsp <-> javabean <-> library
   jsp <-> servlet <-> library

This library module are responsible for all database related functions, and other modules only get , transform and send data to library.

About my database related source codes use only basic syntax
such as

   ...
   Class.forName(DRIVER);
   conn = DriverManager.getConnection(url);
   stmt = conn.createStatement();
   rst = stmt.executeQuery(sql);
   ...

   -> DRIVER = sun.jdbc.odbc.JdbcOdbcDriver
   -> url = jdbc:odbc:[my DSN name]

I found that when I view JSP page or make servlet  request  through web browser. Many  times tomcat program make illegal operation and then window200 terminate it suddenly.
I don't know what are cause. I try to check this situation by
creating new servlet source code whose functions only sequentially select data from 3-5 tables in one database. The result is that I still found this illegal operation.

My test servlet source code is that 

  ... CODE HEADER ...
   try {
   Class.forName(DRIVER);
   } catch (Exception e) {}

  String sql = "select * from table_a";
   try {
   conn = DriverManager.getConnection(url);
   stmt = conn.createStatement();
   rst = stmt.executeQuery(sql);
   } catch (Exception e) {}
   
   sql = "select * from table_b";
   try {
   conn = DriverManager.getConnection(url);
   stmt = conn.createStatement();
   rst = stmt.executeQuery(sql);
   } catch (Exception 

   sql = "select * from table_c";
   try {
   conn = DriverManager.getConnection(url);
   stmt = conn.createStatement();
   rst = stmt.executeQuery(sql);
   } catch (Exception 

   ... CODE TAIL ...




View this report online...






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


participating in tomcat development

2001-01-10 Thread GoldenDawn Fan

Hi, I'd very much like to participate in developing
tomcat.  Where should I start?  Can someone please et
me know?  

Thanks.


__
Do You Yahoo!?
Yahoo! Photos - Share your holiday photos online!
http://photos.yahoo.com/

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




Re: participating in tomcat development

2001-01-10 Thread Peter Donald

Hi there,

At 03:39  10/1/01 -0800, GoldenDawn Fan wrote:
Hi, I'd very much like to participate in developing
tomcat.  Where should I start?  Can someone please et
me know?  

The best way is to start reading the mailing list, fiddling with code and
asking questions. When you think you understand it enough to change things
then find an itch and scratch it ;) ie Add a new feature, remove a bug,
refactor code etc something that you are interested in. Keep in touch with
mailing list just to make sure no one else is working on same bit of code
and eventually when it gets into a workable state submit it as patches
(detailed on the jakarta.apache.org web-pages). Make sure you have fun thou ;)

Cheers,

Pete

*-*
| "Faced with the choice between changing one's mind, |
| and proving that there is no need to do so - almost |
| everyone gets busy on the proof."   |
|  - John Kenneth Galbraith   |
*-*


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




ANN: TomcatX 1.0

2001-01-10 Thread Richard Laing

TomcatX 1.0

A simple MacOS X GUI front-end for the Apache Tomcat servlet/JSP engine.

This release is simple, small and should work with any tomcat version,
although it has only been tested with tomcat 3.2.1.

The release can be found at:

http://homepage.mac.com/rlaing/FileSharing.html

Please use tar -xvzf tomcat.tar.gz  to decompress the application.

Report any problems or suggestions to [EMAIL PROTECTED]


Enjoy!
Richard Laing


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




BugRat Report #733 has been filed.

2001-01-10 Thread BugRat Mail System

Bug report #733 has just been filed.

You can view the report at the following URL:

   http://znutar.cortexity.com/BugRatViewer/ShowReport/733

REPORT #733 Details.

Project: Tomcat
Category: Feature Requests
SubCategory: New Feature
Class: swbug
State: received
Priority: medium
Severity: non-critical
Confidence: public
Environment: 
   Release: Jakarta 3.2
   JVM Release: n/a
   Operating System: Windows 2000
   OS Release: 5.00.2195
   Platform: Compaq

Synopsis: 
Welcome-file tag fails

Description:
Unable to change the default page for a web site.

I added the following lines to web.xml
  welcome-file-list
welcome-filetechsupp.html/welcome-file
  /welcome-file-list

I then restart tomcat and apache and loaded my web browers using URL = 
"http://localhost/tech". I get a directory list displayed in the web browers.

If I select the file techsupp.html the file is loaded and display.

I search the each file in jakarata/conf directory for the techsupp.html and did not 
find any occurs of this file being references.

I then found in context.java where tomcat was building a list of welcome files using 
addWelcomeFile method of the context object. But did not find any object calling 
getWelcomeFiles method of the context object.



Title: 
BugRat Report #
733





BugRat Report #
733




Project:
Tomcat


Release:
Jakarta 3.2




Category:
Feature Requests


SubCategory:
New Feature




Class:
swbug


State:
received




Priority:
medium


Severity:
non-critical




Confidence:
public





Submitter:
John Korpal ([EMAIL PROTECTED])

Date Submitted:
Jan 10 2001, 11:27:51 CST

Responsible:
Z_Tomcat Alias ([EMAIL PROTECTED])


Synopsis:

Welcome-file tag fails


 Environment: (jvm, os, osrel, platform)

n/a, Windows 2000, 5.00.2195, Compaq



Additional Environment Description:





Report Description:

Unable to change the default page for a web site.

I added the following lines to web.xml
  
techsupp.html
  

I then restart tomcat and apache and loaded my web browers using URL = "http://localhost/tech". I get a directory list displayed in the web browers.

If I select the file techsupp.html the file is loaded and display.

I search the each file in jakarata/conf directory for the techsupp.html and did not find any occurs of this file being references.

I then found in context.java where tomcat was building a list of welcome files using addWelcomeFile method of the context object. But did not find any object calling getWelcomeFiles method of the context object.





Workaround:

null



View this report online...






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


BugRat Report #734 has been filed.

2001-01-10 Thread BugRat Mail System

Bug report #734 has just been filed.

You can view the report at the following URL:

   http://znutar.cortexity.com/BugRatViewer/ShowReport/734

REPORT #734 Details.

Project: Catalina
Category: Bug Report
SubCategory: New Bug Report
Class: swbug
State: received
Priority: high
Severity: critical
Confidence: public
Environment: 
   Release: 4.0 beta1
   JVM Release: 1.1.3
   Operating System: NT
   OS Release: 2000
   Platform: Intel

Synopsis: 
ClassLoaded  Verifier error (follow up Bugs 604 and 688)

Description:




javax.servlet.ServletException: Error instantiating servlet class servletOper
at org.apache.catalina.core.StandardWrapper.load(StandardWrapper.java:747)
at org.apache.catalina.core.StandardWrapper.allocate(StandardWrapper.java:544)
at 
org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDispatcher.java:552)
at 
org.apache.catalina.core.ApplicationDispatcher.doForward(ApplicationDispatcher.java:321)
at 
org.apache.catalina.core.ApplicationDispatcher.forward(ApplicationDispatcher.java:236)
at 
org.apache.catalina.servlets.InvokerServlet.serveRequest(InvokerServlet.java:386)
at org.apache.catalina.servlets.InvokerServlet.doGet(InvokerServlet.java:144)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:740)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)



***


Root Cause:
java.lang.VerifyError: (class: leon/view/web/LyServlet, method: applyXSLSheet 
signature: 
(Ljava/io/StringWriter;Ljava/io/Writer;Ljava/lang/String;Lleon/misc/LyEnvironment;)V) 
Incompatible argument to function
at java.lang.Class.newInstance0(Native Method)
at java.lang.Class.newInstance(Class.java:237)
at org.apache.catalina.core.StandardWrapper.load(StandardWrapper.java:740)
at org.apache.catalina.core.StandardWrapper.allocate(StandardWrapper.java:544)
at 
org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDispatcher.java:552)
at 
org.apache.catalina.core.ApplicationDispatcher.doForward(ApplicationDispatcher.java:321)
at 
org.apache.catalina.core.ApplicationDispatcher.forward(ApplicationDispatcher.java:236)
at 
org.apache.catalina.servlets.InvokerServlet.serveRequest(InvokerServlet.java:386)
at org.apache.catalina.servlets.InvokerServlet.doGet(InvokerServlet.java:144)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:740)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
at 
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:215)
at 
org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:251)
at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:977)
at 
org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:196)
at org.apache.catalina.valves.ValveBase.invokeNext(ValveBase.java:242)
at 
org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:464)







Title: 
BugRat Report #
734





BugRat Report #
734




Project:
Catalina


Release:
4.0 beta1




Category:
Bug Report


SubCategory:
New Bug Report




Class:
swbug


State:
received




Priority:
high


Severity:
critical




Confidence:
public





Submitter:
_Anonymous ([EMAIL PROTECTED])

Date Submitted:
Jan 10 2001, 11:29:38 CST

Responsible:
Z_Tomcat Alias ([EMAIL PROTECTED])


Synopsis:

ClassLoaded & Verifier error (follow up Bugs 604 and 688)


 Environment: (jvm, os, osrel, platform)

1.1.3, NT, 2000, Intel



Additional Environment Description:





Report Description:





javax.servlet.ServletException: Error instantiating servlet class servletOper
	at org.apache.catalina.core.StandardWrapper.load(StandardWrapper.java:747)
	at org.apache.catalina.core.StandardWrapper.allocate(StandardWrapper.java:544)
	at org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDispatcher.java:552)
	at org.apache.catalina.core.ApplicationDispatcher.doForward(ApplicationDispatcher.java:321)
	at org.apache.catalina.core.ApplicationDispatcher.forward(ApplicationDispatcher.java:236)
	at org.apache.catalina.servlets.InvokerServlet.serveRequest(InvokerServlet.java:386)
	at org..apache.catalina.servlets.InvokerServlet.doGet(InvokerServlet.java:144)
	at javax.servlet.http.HttpServlet.service(HttpServlet.java:740)
	at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)



***


Root Cause:
java.lang.VerifyError: (class: leon/view/web/LyServlet, method: applyXSLSheet signature: (Ljava/io/StringWriter;Ljava/io/Writer;Ljava/lang/String;Lleon/misc/LyEnvironment;)V) Incompatible argument to function
	at java.lang.Class.newInstance0(Native Method)
	at java.lang.Class.newInstance(Class.java:237)
	at org.apache.catalina.core.StandardWrapper.load(StandardWrapper.java:740)
	at 

BUG: weird nullpointer exception

2001-01-10 Thread Filip Hanik


- Original Message -
From: "Filip Hanik" [EMAIL PROTECTED]
To: [EMAIL PROTECTED]; [EMAIL PROTECTED]
Sent: Tuesday, January 09, 2001 11:13 PM
Subject: BUG?: weird nullpointer exception


 This is why this happens, I figured it out, but I believe it is a bug.

 if you add in "activation.jar" in the WEB-INF/lib directory. the files
will
 not get loaded properly by the AdaptiveClassLoader

 hence, when you try to execute a servlet in that context the
 AdaptiveClassLoader.repository variable is null.
 since I was under the impression that you should be able to put any jar
 files under WEB-INF/lib I would consider this a bug.

 *I'm proud* I figured this out after f***ing around with the source code
for
 a while.

 Filip

 - Original Message -
 From: "Filip Hanik" [EMAIL PROTECTED]
 To: [EMAIL PROTECTED]
 Sent: Tuesday, January 09, 2001 9:47 PM
 Subject: weird nullpointer exception


  Location: /rtx/GreeterBob
  Internal Servlet Error:
 
  java.lang.NullPointerException
   at
 

org.apache.tomcat.loader.AdaptiveClassLoader.loadClass(AdaptiveClassLoader.j
  ava:471)
   at
 

org.apache.tomcat.loader.AdaptiveServletLoader.loadClass(AdaptiveServletLoad
  er.java:174)
   at
 
org.apache.tomcat.core.ServletWrapper.loadServlet(ServletWrapper.java:265)
   at org.apache.tomcat.core.ServletWrapper.init(ServletWrapper.java:289)
   at org.apache.tomcat.core.Handler.service(Handler.java:254)
   at
org.apache.tomcat.core.ServletWrapper.service(ServletWrapper.java:372)
   at
 

org.apache.tomcat.core.ContextManager.internalService(ContextManager.java:79
  7)
   at
org.apache.tomcat.core.ContextManager.service(ContextManager.java:743)
   at
 

org.apache.tomcat.service.http.HttpConnectionHandler.processConnection(HttpC
  onnectionHandler.java:210)
   at
 
org.apache.tomcat.service.TcpWorkerThread.runIt(PoolTcpEndpoint.java:416)
   at
 
org.apache.tomcat.util.ThreadPool$ControlRunnable.run(ThreadPool.java:498)
   at java.lang.Thread.run(Thread.java:484)
 
  Any idea what this happens?
 
  Filip
 
  - Original Message -
  From: Debra Mendelson, CCE
  To: [EMAIL PROTECTED]
  Sent: Wednesday, January 10, 2001 12:39 AM
  Subject: Re: converting mod_jserv to mod_jk
 
 
  Got it working!!!  My correct
  tomcat-apache.conf:
  LoadModulejk_module  libexec/mod_jk.so
  JkWorkersFile /app/conf/workers.properties
  JkLogFile /app/logs/mod_jk.log
  JkLogLevelerror
 
  JkMount /servlet1/* servlet1
  JkMount /servlet2/* servlet2
  JkMount /servlet3/* servlet3
  JkMount /servlet4/* servlet4
 
  The asterisk was missing and important.
 
  I think the difference between one worker and many is a matter of
function
  not style.
 
  In our case we want to have only 1 http server because we want to
purchase
  only one SSL certificate (and other reasons).  Behind that https server
we
  want to run several independent servlet engines.  I think the
  workers.properties is 1:1 with the httpd.conf file and thus needs to
cover
  all the servlet engines behind the server.
 
  Thanks again for the hints and the discussion points.
  - Original Message -
  From: Ed Gomolka
  To: [EMAIL PROTECTED]
  Sent: Tuesday, January 09, 2001 1:46 PM
  Subject: RE: converting mod_jserv to mod_jk
 
 
  Your code appears to be missing a lot of the context information that is
  automatically generated in mod_jk.conf-auto.
  I would recommend that you forget about tomcat-apache.conf, and focus on
  modifying mod_jk.conf-auto.
  Also, did you make the startup.sh, shutdown.sh and server.xml changes to
  support the different Tomcat instances
  under mod_jk?
 
 
  Beyond that, I can't really say anything. I created individual
  workers.properties files whre you used one, but that should be more of
  a style issue than anything else.
 
 
  -Original Message-
  From: Debra Mendelson, CCE [mailto:[EMAIL PROTECTED]]
  Sent: Tuesday, January 09, 2001 5:47 PM
  To: [EMAIL PROTECTED]
  Subject: Re: converting mod_jserv to mod_jk
 
 
  Thanks for the advice based on this and rereading the howto I came up
with
  the following that still doesn't work.  Any ideas?:
 
  tomcat-apache.conf:
  LoadModulejk_module  libexec/mod_jk.so
  JkWorkersFile /app/conf/workers.properties
  JkLogFile /app/logs/mod_jk.log
  JkLogLevelerror
 
  JkMount /servlet1 servlet1
  JkMount /servlet2 servlet2
  JkMount /servlet3 servlet3
  JkMount /servlet4 servlet4
 
  /app/conf/workers.properties
  worker.list=servlet1, servlet2, servlet3, servlet4
  worker.servlet1.port=8009
  worker.servlet1.host=localhost
  worker.servlet1.type=ajp12
 
  worker.servlet2.port=8017
  worker.servlet2.host=localhost
  worker.servlet2.type=ajp12
 
  worker.servlet3.port=8012
  worker.servlet3.host=localhost
  worker.servlet3.type=ajp12
 
  worker.servlet4.port=8013
  worker.servlet4.host=localhost
  worker.servlet4.type=ajp12
 
  - Original Message 

Security

2001-01-10 Thread Jim Urban

I tried sending this to the user mailing list two days in a row and got no
answer, so I am now asking the development community for help.

I am running Tomcat with Apache on NT.  I have a servlet context which
contains three servlets and their supporting classes.  I now need to limit
access to the servlets to different groups of users.  How do I set this up?
Can someone please send me a sample of "security-constraint" section (is
this where it gets done?) of a web.xml file?


Jim Urban
Project Manager
Netsteps Inc.
Suite 505E
1 Pierce Pl.
Itasca, IL  60143
Voice:  (630) 250-3045 x2164
Fax:  (630) 250-3046


 winmail.dat

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


BugRat Report #735 has been filed.

2001-01-10 Thread BugRat Mail System

Bug report #735 has just been filed.

You can view the report at the following URL:

   http://znutar.cortexity.com/BugRatViewer/ShowReport/735

REPORT #735 Details.

Project: Tomcat
Category: Bug Report
SubCategory: New Bug Report
Class: swbug
State: received
Priority: high
Severity: critical
Confidence: public
Environment: 
   Release: tomcat 3.1
   JVM Release: 1.2.2
   Operating System: NT
   OS Release: 4
   Platform: tomcat and apache

Synopsis: 
JSP includes

Description:
JSP includes don't work. 
This --- jsp:include page="whatever.jsp"/
produces this
Internal Servlet Error:

org.apache.jasper.JasperException: Invalid jsp:include tag
at org.apache.jasper.compiler.IncludeGenerator.(IncludeGenerator.java:95)
at 
org.apache.jasper.compiler.JspParseEventListener.handleInclude(JspParseEventListener.java:834)
at 
org.apache.jasper.compiler.DelegatingListener.handleInclude(DelegatingListener.java:185)
at org.apache.jasper.compiler.Parser$Include.accept(Parser.java, Compiled Code)
at org.apache.jasper.compiler.Parser.parse(Parser.java, Compiled Code)
at org.apache.jasper.compiler.Parser.parse(Parser.java:1038)
at org.apache.jasper.compiler.Parser.parse(Parser.java:1034)
at org.apache.jasper.compiler.Compiler.compile(Compiler.java, Compiled Code)
at org.apache.jasper.runtime.JspServlet.loadJSP(JspServlet.java:413)
at 
org.apache.jasper.runtime.JspServlet$JspServletWrapper.loadIfNecessary(JspServlet.java:149)
at 
org.apache.jasper.runtime.JspServlet$JspServletWrapper.service(JspServlet.java:161)
at org.apache.jasper.runtime.JspServlet.serviceJspFile(JspServlet.java:261)
at org.apache.jasper.runtime.JspServlet.service(JspServlet.java, Compiled Code)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
at org.apache.tomcat.core.ServletWrapper.handleRequest(ServletWrapper.java, 
Compiled Code)
at org.apache.tomcat.core.ContextManager.service(ContextManager.java:559)
at 
org.apache.tomcat.service.connector.Ajp12ConnectionHandler.processConnection(Ajp12ConnectionHandler.java:156)
at org.apache.tomcat.service.TcpWorkerThread.run(PoolTcpEndpoint.java, 
Compiled Code)
at org.apache.tomcat.util.ThreadPool$ControlRunnable.run(ThreadPool.java, 
Compiled Code)
at java.lang.Thread.run(Thread.java:479)



Title: 
BugRat Report #
735





BugRat Report #
735




Project:
Tomcat


Release:
tomcat 3.1




Category:
Bug Report


SubCategory:
New Bug Report




Class:
swbug


State:
received




Priority:
high


Severity:
critical




Confidence:
public





Submitter:
_Anonymous ([EMAIL PROTECTED])

Date Submitted:
Jan 10 2001, 12:04:22 CST

Responsible:
Z_Tomcat Alias ([EMAIL PROTECTED])


Synopsis:

JSP includes


 Environment: (jvm, os, osrel, platform)

1.2.2, NT, 4, tomcat and apache



Additional Environment Description:





Report Description:

JSP includes don't work. 
This --- 
produces this
Internal Servlet Error:

org.apache.jasper.JasperException: Invalid jsp:include tag
	at org.apache.jasper.compiler.IncludeGenerator.(IncludeGenerator.java:95)
	at org.apache.jasper.compiler.JspParseEventListener.handleInclude(JspParseEventListener.java:834)
	at org.apache.jasper.compiler.DelegatingListener.handleInclude(DelegatingListener.java:185)
	at org.apache.jasper.compiler.Parser$Include.accept(Parser.java, Compiled Code)
	at org.apache.jasper.compiler.Parser.parse(Parser.java, Compiled Code)
	at org.apache.jasper.compiler.Parser.parse(Parser.java:1038)
	at org.apache.jasper.compiler.Parser.parse(Parser.java:1034)
	at org.apache.jasper.compiler.Compiler.compile(Compiler.java, Compiled Code)
	at org.apache.jasper.runtime.JspServlet.loadJSP(JspServlet.java:413)
	at org.apache.jasper.runtime.JspServlet$JspServletWrapper.loadIfNecessary(JspServlet.java:149)
	at org.apache.jasper.runtime.JspServlet$JspServletWrapper.service(JspServlet.java:161)
	at org.apache.jasper.runtime.JspServlet.serviceJspFile(JspServlet.java:261)
	at org.apache.jasper.runtime.JspServlet.service(JspServlet.java, Compiled Code)
	at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
	at org.apache.tomcat.core.ServletWrapper.handleRequest(ServletWrapper.java, Compiled Code)
	at org.apache.tomcat.core.ContextManager.service(ContextManager.java:559)
	at org.apache.tomcat.service.connector.Ajp12ConnectionHandler.processConnection(Ajp12ConnectionHandler.java:156)
	at org.apache.tomcat.service.TcpWorkerThread.run(PoolTcpEndpoint.java, Compiled Code)
	at org.apache.tomcat.util.ThreadPool$ControlRunnable.run(ThreadPool.java, Compiled Code)
	at java.lang.Thread.run(Thread.java:479)





How To Reproduce:

null



View this report online...






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


RE: acive session count?

2001-01-10 Thread cmanolache

Hi,

 Solution: Dan Milstein is adding my patch to mod_jk. It forces an instance
 of Tomcat in the load balance list to reject new connections, but continue
 to service existing sessions. (by setting worker.name.active=0, and
 restarting my apaches) 

Question: can this be done _without_ restarting apache ? 

I was thinking about the whole "configuration/reconfiguration/signales" mechanism,
and IMHO there is a simpler solution: instead of using signals and AJP13
extensions, it may be better to just use plain HTTP and normal
servlets/apache handlers. 

Creating a simple /jk_admin is not difficult ( a simple handler that will
accept an authenticated HTTP request and alter the configuration ). That
will allow run-time addition of apps and workers without restarting
apache. 

For tomcat side, few extra servlets on the admin app will be much easier
and safer to develop than changing the protocols or other internals ( and
will probably be more re-usable ). 

In general, using common servlets / handlers is much easier, will allow
more people to contribute and can be done independently ( without change
in the main distribution, so without too much to worry about tomcat
release cycle or featurism ).

( For apache/server side - while changing mod_jk and adding /jk_admin
inside it may look simple, we can also create a new module and then use it
to manage jk - this will keep the mod_jk code simple ).

Costin

P.S. I'm working on the bug reported by Larry ( encoding ) - I want to
resolve it in a good way, but as I read more the hardest it becomes. If
anyone has any experience with encoding/charsets/non-ascii URLs/ JIS
/localization - I need help on this one.

It seems that it is perfectly reasonable for a japanese/etc user to
type his name in a form, and the URL will be generated with SJIS-encoded
chars ( GET case ). I found some pages on the internet - but most of them
are discussing the problem, and it seems nobody knows any good solution. 

( the original problem - keeping the escaped URL and using it for the
methods that return escaped paths - is simple. The main problem is what to
do when un-escaped paths are needed and when serving files with non-ASCII
chars in the name - and even more, how to do that in a way that is
consistent with Apache,IIS,NES,AOL behavior. I found an interesting
reference at http://www.arsdigita.com/asj/multilingual, and few RFCs, but 
it's still far from what I need )






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




Bug # 733

2001-01-10 Thread John . Korpal



The attached file contains a solution to the bug I reported today. The basic
solution is the tomcat needed to add a "DirectoryIndex" line to each
"Directory"  tag with a list of welcome file included on this line. Again the
attached file contain changes to ApacheConfig.java file that fixes this problem.

John

(See attached file: ApacheConfig.java)

 ApacheConfig.java

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


mod_jk and acl

2001-01-10 Thread GOMEZ Henri

Hi,

What's the status of ACL to mod_jk ?

I take a look at what to do on tc 3.3 to restrict
connections to tomcat with rules  la hosts.allow/hosts.deny
but didn't know if Dan or Costin does something like this ?

I could send some code if nothing is done yet...

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




[PATCH] bind to ip

2001-01-10 Thread Thomas Butter

Sorry, I accidently send this to the user list before.



The current org.apache.catalina.connector.http.HttpConnector doesn't 
bind to a single ip if the hostname of the machine doesn't have a A 
record for the IP.

This breaks most Virtualserver enviroments that want to run different 
server (for example apache and tomcat) on the same machine.

The patch should solve this problem.


-- 
Thomas Butter [EMAIL PROTECTED]  ICQ: 891617

"Unix IS user friendly, it is just selective about who his friends are."


--- HttpConnector.java.orig Wed Jan 10 23:17:51 2001
+++ HttpConnector.java  Wed Jan 10 23:20:16 2001
@@ -734,17 +734,12 @@
}
 
// Open a server socket on the specified address
-   InetAddress[] addresses =
-   InetAddress.getAllByName(InetAddress.getLocalHost().getHostName());
-   int i;
-   for (i = 0; i  addresses.length; i++) {
-   if (addresses[i].getHostAddress().equals(address))
-   break;
-   }
-   if (i  addresses.length) {
+   try
+   {
+   InetAddress is=InetAddress.getByName(address);
log(sm.getString("httpConnector.anAddress", address));
 return (factory.createSocket(port, acceptCount, addresses[i]));
-   } else {
+   } catch(Exception e) {
log(sm.getString("httpConnector.noAddress", address));
 return (factory.createSocket(port, acceptCount));
}



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


cvs commit: jakarta-tomcat/src/shell tomcat.sh

2001-01-10 Thread glenn

glenn   01/01/10 14:55:49

  Modified:src/shell Tag: tomcat_32 tomcat.sh
  Log:
  Fixed startup with -security
  
  Revision  ChangesPath
  No   revision
  
  
  No   revision
  
  
  1.17.2.2  +3 -1  jakarta-tomcat/src/shell/tomcat.sh
  
  Index: tomcat.sh
  ===
  RCS file: /home/cvs/jakarta-tomcat/src/shell/tomcat.sh,v
  retrieving revision 1.17.2.1
  retrieving revision 1.17.2.2
  diff -u -r1.17.2.1 -r1.17.2.2
  --- tomcat.sh 2000/11/17 22:05:50 1.17.2.1
  +++ tomcat.sh 2001/01/10 22:55:48 1.17.2.2
  @@ -1,6 +1,6 @@
   #!/bin/sh
   #
  -# $Id: tomcat.sh,v 1.17.2.1 2000/11/17 22:05:50 glenn Exp $
  +# $Id: tomcat.sh,v 1.17.2.2 2001/01/10 22:55:48 glenn Exp $
   
   # Shell script to start and stop the server
   
  @@ -122,6 +122,7 @@
 shift 
 echo Using classpath: ${CLASSPATH}
 if [ "$1" = "-security" ] ; then
  +shift
   echo Starting with a SecurityManager
   $JAVACMD $TOMCAT_OPTS -Djava.security.manager 
-Djava.security.policy==${TOMCAT_HOME}/conf/tomcat.policy -Dtomcat.home=${TOMCAT_HOME} 
 org.apache.tomcat.startup.Tomcat "$@" 
 else
  @@ -139,6 +140,7 @@
 shift 
 echo Using classpath: ${CLASSPATH}
 if [ "$1" = "-security" ] ; then
  +shift
   echo Starting with a SecurityManager
   $JAVACMD $TOMCAT_OPTS -Djava.security.manager 
-Djava.security.policy==${TOMCAT_HOME}/conf/tomcat.policy -Dtomcat.home=${TOMCAT_HOME} 
org.apache.tomcat.startup.Tomcat "$@"
 else
  
  
  

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




BugRat Report #418 was closed (apparently by: Justyna Horwat)

2001-01-10 Thread BugRat Mail System

Report #418 was closed by Person #0

   Synopsis: Problem with include directive

 (logged in as: Justyna Horwat)

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




BugRat Report #420 was closed (apparently by: Justyna Horwat)

2001-01-10 Thread BugRat Mail System

Report #420 was closed by Person #0

   Synopsis: More information for bug 418

 (logged in as: Justyna Horwat)

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




BugRat Report #523 was closed (apparently by: Justyna Horwat)

2001-01-10 Thread BugRat Mail System

Report #523 was closed by Person #0

   Synopsis: Platform Portability Issue

 (logged in as: Justyna Horwat)

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




possible problems in org.apache.catalina.connector.http.SocketInputStream

2001-01-10 Thread Thomas Butter

SocketInputStream extends java.io.BufferedInputStream and uses the 
protected fields buf, pos and count.

As far as I can see there are several problems with some uses of pos:
First of all the use of buf and pos are not defined by the api, so it is 
theoretical implementation dependent.

Furthermore there are some problems even if the buf and pos are used in 
the original way:

For example if in line 257:   
   requestLine.uri[readCount] = (char) buf[pos];
   readCount++;
   pos++;

buf[pos] is undefined the last fill called by the last read() only got 
one byte (which was enough for the last read()).

There are several situations in the class where this problem could happen.

I think this class should be rewritten using PushbackInputStream (or 
better using a new PushbackInputStream(new BufferInputStream(in))).

I would volunteer rewriting this class if you agree with my assumptions.



-- 
Thomas Butter [EMAIL PROTECTED]  ICQ: 891617

"Unix IS user friendly, it is just selective about who his friends are."


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




Re: possible problems in org.apache.catalina.connector.http.SocketInputStream

2001-01-10 Thread Remy Maucherat

Quoting Thomas Butter [EMAIL PROTECTED]:

 For example if in line 257:   
requestLine.uri[readCount] = (char) buf[pos];
readCount++;
pos++;
 
 buf[pos] is undefined the last fill called by the last read() only got 
 one byte (which was enough for the last read()).

Yes, but (pos = count) should be true then (on the next loop iteration), so it 
should attempt to read again from the input stream (right ?). I tested that 
stream with very small buffers (a 4 bytes internal buffer), so the situation 
you described must have happened at some point during my testing.

 I would volunteer rewriting this class if you agree with my
 assumptions.

If extending BIS is indeed a problem, I would vote +1 in duplicating the BIS 
code into SocketInputStream, and -1 for layering another IS (for performance 
reasons).

Remy

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




Re: mod_jk and acl

2001-01-10 Thread Dan Milstein

I haven't had a chance to work on this yet, and I don't think I'll have an opportunity 
soon, so if you want to send some code along, that would be great.

-Dan

GOMEZ Henri wrote:
 
 Hi,
 
 What's the status of ACL to mod_jk ?
 
 I take a look at what to do on tc 3.3 to restrict
 connections to tomcat with rules  la hosts.allow/hosts.deny
 but didn't know if Dan or Costin does something like this ?
 
 I could send some code if nothing is done yet...
 
 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, email: [EMAIL PROTECTED]

-- 

Dan Milstein // [EMAIL PROTECTED]

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




Re: participating in tomcat development

2001-01-10 Thread GoldenDawn Fan

Hi, is there a pre-set spec??  And where can I get
source code...?

Thanks!

--- Peter Donald [EMAIL PROTECTED] wrote:
 Hi there,
 
 At 03:39  10/1/01 -0800, GoldenDawn Fan wrote:
 Hi, I'd very much like to participate in developing
 tomcat.  Where should I start?  Can someone please
 et
 me know?  
 
 The best way is to start reading the mailing list,
 fiddling with code and
 asking questions. When you think you understand it
 enough to change things
 then find an itch and scratch it ;) ie Add a new
 feature, remove a bug,
 refactor code etc something that you are interested
 in. Keep in touch with
 mailing list just to make sure no one else is
 working on same bit of code
 and eventually when it gets into a workable state
 submit it as patches
 (detailed on the jakarta.apache.org web-pages). Make
 sure you have fun thou ;)
 
 Cheers,
 
 Pete
 

*-*
 | "Faced with the choice between changing one's
 mind, |
 | and proving that there is no need to do so -
 almost |
 | everyone gets busy on the proof." 
  |
 |  - John Kenneth Galbraith 
  |

*-*
 
 

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


__
Do You Yahoo!?
Yahoo! Photos - Share your holiday photos online!
http://photos.yahoo.com/

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




Re: participating in tomcat development

2001-01-10 Thread Peter Donald

At 06:11  10/1/01 -0800, GoldenDawn Fan wrote:
Hi, is there a pre-set spec??  And where can I get
source code...?

Source code via CVS - detaiks at http://jakarta.apache.org/site/cvsindex.html

You should also browse

http://jakarta.apache.org/site/guidelines.html
http://jakarta.apache.org/site/library.html
Cheers,

Pete

*-*
| "Faced with the choice between changing one's mind, |
| and proving that there is no need to do so - almost |
| everyone gets busy on the proof."   |
|  - John Kenneth Galbraith   |
*-*


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




cvs commit: jakarta-tomcat/src/share/org/apache/tomcat/modules/server Ajp13.java

2001-01-10 Thread danmil

danmil  01/01/10 18:34:20

  Modified:src/share/org/apache/tomcat/modules/server Ajp13.java
  Log:
 - Fixed the problems with multipart form encodings.  Bug Reports #536 +
   #542 and a bunch of others.  File upload is now working.
  
 - In doRead(), replaced byte-by-byte copy with System.arraycopy().
  
 - Clarified Ajp13 protocol: if the container tries to read
   past the end of the input stream, the server sends an empty packet back.
  
  Revision  ChangesPath
  1.8   +78 -28
jakarta-tomcat/src/share/org/apache/tomcat/modules/server/Ajp13.java
  
  Index: Ajp13.java
  ===
  RCS file: 
/home/cvs/jakarta-tomcat/src/share/org/apache/tomcat/modules/server/Ajp13.java,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -r1.7 -r1.8
  --- Ajp13.java2000/12/26 23:35:34 1.7
  +++ Ajp13.java2001/01/11 02:34:20 1.8
  @@ -184,6 +184,9 @@
   
   public void recycle() 
   {
  +  // This is a touch cargo-cultish, but I think wise.
  +  blen = 0; 
  +  pos = 0;
   }
   
   /**
  @@ -257,7 +260,7 @@
   req.serverName().setString( msg.getString());
   req.setServerPort(  msg.getInt());
   
  - isSSL = (msg.getByte() != 0);
  + isSSL = msg.getBool();
   
// Decode headers
MimeHeaders headers = req.getMimeHeaders();
  @@ -358,6 +361,7 @@
}

blen = msg.peekInt();
  + pos = 0;
msg.getBytes(bodyBuff);
}
   
  @@ -374,7 +378,9 @@
   public int doRead() throws IOException 
   {
   if(pos = blen) {
  -refillReadBuffer();
  +if( ! refillReadBuffer()) {
  + return -1;
  + }
   }
   return bodyBuff[pos++];
   }
  @@ -386,30 +392,61 @@
* @param off The offset in the buffer at which to start filling.
* @param len The number of bytes to copy into the buffer.
*
  - * @return The number of bytes actually copied into the buffer.
  + * @return The number of bytes actually copied into the buffer, or -1
  + * if the end of the stream has been reached.
*
* @see Ajp13Request#doRead
*/
   public int doRead(byte[] b, int off, int len) throws IOException 
   {
  -// XXX Rewrite to use System.arrayCopy (please!)
  -for(int i = off ; i  (len + off) ; i++) {
  -int a = doRead();
  -if(-1 == a) {
  -return i-off;
  -}
  -b[i] = (byte)a;
  -}
  -
  -return len;
  + if(pos = blen) {
  + if( ! refillReadBuffer()) {
  + return -1;
  + }
  + }
  +
  + if(pos + len = blen) { // Fear the off by one error
  + // Sanity check b.length  off + len?
  + System.arraycopy(bodyBuff, pos, b, off, len);
  + pos += len;
  + return len;
  + }
  +
  + // Not enough data (blen  pos + len)
  + int toCopy = len;
  + while(toCopy  0) {
  + int bytesRemaining = blen - pos;
  + if(bytesRemaining  0) 
  + bytesRemaining = 0;
  + int c = bytesRemaining  toCopy ? bytesRemaining : toCopy;
  +
  + System.arraycopy(bodyBuff, pos, b, off, c);
  +
  + toCopy-= c;
  +
  + off   += c;
  + pos   += c; // In case we exactly consume the buffer
  +
  + if(toCopy  0) 
  + if( ! refillReadBuffer()) { // Resets blen and pos
  + break;
  + }
  + }
  +
  + return len - toCopy;
   }
   
   /**
* Get more request body data from the web server and store it in the 
* internal buffer.
  + *
  + * @return true if there is more data, false if not.
*/
  -private void refillReadBuffer() throws IOException 
  +private boolean refillReadBuffer() throws IOException 
   {
  + // If the server returns an empty packet, assume that that end of
  + // the stream has been reached (yuck -- fix protocol??).
  +
// Why not use outBuf??
inBuf.reset();
inBuf.appendByte(JK_AJP13_GET_BODY_CHUNK);
  @@ -424,6 +461,8 @@
blen = inBuf.peekInt();
pos = 0;
inBuf.getBytes(bodyBuff);
  +
  + return (blen  0);
   }
   
   //  Servlet Output Support =
  @@ -442,18 +481,18 @@
   outBuf.appendInt(status);
   outBuf.appendString(""); // Http Status Message -- broken.
   
  -outBuf.appendInt(headers.size());
  + int numHeaders = headers.size();
  +outBuf.appendInt(numHeaders);
   
  -Enumeration e = headers.names();
  -while(e.hasMoreElements()) {
  -String headerName = (String)e.nextElement();
  -int sc = 

Re: acive session count?

2001-01-10 Thread Dan Milstein

Costin,

Hmmm.  On the one hand, I very much like your idea of a) moving these admin-type 
functions out of the mod_jk code and into a handler and b) not requiring a restart of 
the web server.

On the other hand:

 1) Michael's code doesn't actually modify the Ajp13 protocol -- it adds a new 
configuration option to mod_jk.conf, which alters how the web server behaves.  So it's 
not adding any complexity to the protocol.

 2) An admin handler would have to be controlling the behavior of the web server.  
Since one of the strengths of the mod_jk C code is that it works with many servers, 
any handler which ran in the web server's space would have to be written for a variety 
of servers.  The configuration code which Michael modified is cross-platform, so this 
is not an issue.

 3) Although I, too, fear creeping featurism, I think this function (having the load 
balancer stop sending new sessions to a container instance) is actually an important 
piece of what a load balancer does.

 4) My instinct is that requiring a restart is probably not a tremendously evil thing.

I'm inclined to commit his patch on the 3.3 branch -- I don't think it belongs on 3.2, 
because it's not really a bug fix.

What do you think?

-Dan

[EMAIL PROTECTED] wrote:
 
 Hi,
 
  Solution: Dan Milstein is adding my patch to mod_jk. It forces an instance
  of Tomcat in the load balance list to reject new connections, but continue
  to service existing sessions. (by setting worker.name.active=0, and
  restarting my apaches)
 
 Question: can this be done _without_ restarting apache ?
 
 I was thinking about the whole "configuration/reconfiguration/signales" mechanism,
 and IMHO there is a simpler solution: instead of using signals and AJP13
 extensions, it may be better to just use plain HTTP and normal
 servlets/apache handlers.
 
 Creating a simple /jk_admin is not difficult ( a simple handler that will
 accept an authenticated HTTP request and alter the configuration ). That
 will allow run-time addition of apps and workers without restarting
 apache.
 
 For tomcat side, few extra servlets on the admin app will be much easier
 and safer to develop than changing the protocols or other internals ( and
 will probably be more re-usable ).
 
 In general, using common servlets / handlers is much easier, will allow
 more people to contribute and can be done independently ( without change
 in the main distribution, so without too much to worry about tomcat
 release cycle or featurism ).
 
 ( For apache/server side - while changing mod_jk and adding /jk_admin
 inside it may look simple, we can also create a new module and then use it
 to manage jk - this will keep the mod_jk code simple ).
 
 Costin
 
-- 

Dan Milstein // [EMAIL PROTECTED]

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




cvs commit: jakarta-tomcat-4.0/catalina/src/share/org/apache/catalina/session StandardSession.java

2001-01-10 Thread craigmcc

craigmcc01/01/10 19:06:02

  Modified:catalina/src/share/org/apache/catalina/session
StandardSession.java
  Log:
  Backport the debugging detail change from 4.1.
  
  Revision  ChangesPath
  1.10  +26 -4 
jakarta-tomcat-4.0/catalina/src/share/org/apache/catalina/session/StandardSession.java
  
  Index: StandardSession.java
  ===
  RCS file: 
/home/cvs/jakarta-tomcat-4.0/catalina/src/share/org/apache/catalina/session/StandardSession.java,v
  retrieving revision 1.9
  retrieving revision 1.10
  diff -u -r1.9 -r1.10
  --- StandardSession.java  2001/01/03 00:17:08 1.9
  +++ StandardSession.java  2001/01/11 03:06:02 1.10
  @@ -1,7 +1,7 @@
   /*
  - * $Header: 
/home/cvs/jakarta-tomcat-4.0/catalina/src/share/org/apache/catalina/session/StandardSession.java,v
 1.9 2001/01/03 00:17:08 craigmcc Exp $
  - * $Revision: 1.9 $
  - * $Date: 2001/01/03 00:17:08 $
  + * $Header: 
/home/cvs/jakarta-tomcat-4.0/catalina/src/share/org/apache/catalina/session/StandardSession.java,v
 1.10 2001/01/11 03:06:02 craigmcc Exp $
  + * $Revision: 1.10 $
  + * $Date: 2001/01/11 03:06:02 $
*
* 
*
  @@ -109,7 +109,7 @@
* @author Craig R. McClanahan
* @author Sean Legassick
* @author a href="mailto:[EMAIL PROTECTED]"Jon S. Stevens/a
  - * @version $Revision: 1.9 $ $Date: 2001/01/03 00:17:08 $
  + * @version $Revision: 1.10 $ $Date: 2001/01/11 03:06:02 $
*/
   
   final class StandardSession
  @@ -128,6 +128,8 @@
   
super();
this.manager = manager;
  +if (manager instanceof StandardManager)
  +this.debug = ((StandardManager) manager).getDebug();
   
   }
   
  @@ -165,6 +167,13 @@
   
   
   /**
  + * The debugging detail level for this component.  NOTE:  This value
  + * is not included in the serialized version of this object.
  + */
  +private transient int debug = 0;
  +
  +
  +/**
* We are currently processing a session expiration, so bypass
* certain IllegalStateException tests.  NOTE:  This value is not
* included in the serialized version of this object.
  @@ -1037,6 +1046,8 @@
thisAccessedTime = ((Long) stream.readObject()).longValue();
principal = null;   // Transient only
   setId((String) stream.readObject());
  +if (debug = 2)
  +log("readObject() loading session " + id);
   
// Deserialize the attribute count and attribute values
if (attributes == null)
  @@ -1049,6 +1060,9 @@
Object value = (Object) stream.readObject();
if ((value instanceof String)  (value.equals(NOT_SERIALIZED)))
continue;
  +if (debug = 2)
  +log("  loading attribute '" + name +
  +"' with value '" + value + "'");
   setAttribute(name, value);
}
   isValid = isValidSave;
  @@ -1085,6 +1099,8 @@
stream.writeObject(new Boolean(isValid));
stream.writeObject(new Long(thisAccessedTime));
stream.writeObject(id);
  +if (debug = 2)
  +log("writeObject() storing session " + id);
   
// Accumulate the names of serializable and non-serializable attributes
String keys[] = keys();
  @@ -1112,10 +1128,16 @@
stream.writeObject((String) saveNames.get(i));
try {
stream.writeObject(saveValues.get(i));
  +if (debug = 2)
  +log("  storing attribute '" + saveNames.get(i) +
  +"' with value '" + saveValues.get(i) + "'");
} catch (NotSerializableException e) {
log(sm.getString("standardSession.notSerializable",
 saveNames.get(i), id));
stream.writeObject(NOT_SERIALIZED);
  +if (debug = 2)
  +log("  storing attribute '" + saveNames.get(i) +
  +"' with value NOT_SERIALIZED");
unbinds.add(saveNames.get(i));
}
}
  
  
  

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




cvs commit: jakarta-tomcat/src/native/jk jk_lb_worker.c

2001-01-10 Thread danmil

danmil  01/01/10 19:07:12

  Modified:src/native/jk Tag: tomcat_32 jk_lb_worker.c
  Log:
  Fixed bug with how the load balancer reads the session id out of the cookie.
  
  PR #603.
  
  Revision  ChangesPath
  No   revision
  
  
  No   revision
  
  
  1.2.2.1   +2 -2  jakarta-tomcat/src/native/jk/Attic/jk_lb_worker.c
  
  Index: jk_lb_worker.c
  ===
  RCS file: /home/cvs/jakarta-tomcat/src/native/jk/Attic/jk_lb_worker.c,v
  retrieving revision 1.2
  retrieving revision 1.2.2.1
  diff -u -r1.2 -r1.2.2.1
  --- jk_lb_worker.c2000/05/29 12:53:24 1.2
  +++ jk_lb_worker.c2001/01/11 03:07:11 1.2.2.1
  @@ -58,7 +58,7 @@
*  several workers.   *
* Author:  Gal Shachor [EMAIL PROTECTED]   *
* Based on:   *
  - * Version: $Revision: 1.2 $   *
  + * Version: $Revision: 1.2.2.1 $   *
***/
   
   #include "jk_pool.h"
  @@ -166,7 +166,7 @@
   char *id_end;
   id_start = jk_pool_strdup(s-pool, id_start);
   if(id_end = strchr(id_start, ';')) {
  -id_end = NULL;
  +*id_end = '\0';
   }
   return id_start;
   }
  
  
  

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




cvs commit: jakarta-tomcat/src/native/mod_jk/common jk_lb_worker.c

2001-01-10 Thread danmil

danmil  01/01/10 19:14:46

  Modified:src/native/mod_jk/common jk_lb_worker.c
  Log:
  *Actually* fixing the bug in PR #603 -- the last commit fixed another bug (by 
accident)
  
  Revision  ChangesPath
  1.4   +2 -2  jakarta-tomcat/src/native/mod_jk/common/jk_lb_worker.c
  
  Index: jk_lb_worker.c
  ===
  RCS file: /home/cvs/jakarta-tomcat/src/native/mod_jk/common/jk_lb_worker.c,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -r1.3 -r1.4
  --- jk_lb_worker.c2001/01/11 03:10:30 1.3
  +++ jk_lb_worker.c2001/01/11 03:14:45 1.4
  @@ -58,7 +58,7 @@
*  several workers.   *
* Author:  Gal Shachor [EMAIL PROTECTED]   *
* Based on:   *
  - * Version: $Revision: 1.3 $   *
  + * Version: $Revision: 1.4 $   *
***/
   
   #include "jk_pool.h"
  @@ -166,7 +166,7 @@
   char *id_end;
   id_start = jk_pool_strdup(s-pool, id_start);
   if(id_end = strchr(id_start, ';')) {
  -id_end = NULL;
  +*id_end = '\0';
   }
   return id_start;
   }
  
  
  

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




Re: classloader status?

2001-01-10 Thread Craig R. McClanahan

OK, I've been playing with the scenario below ... and as far as I can tell,
session reloading works correctly.  To aid in experimentation, I've added some
instrumentation so that you can log debugging detail messages related to it.  The
attached log file is what I get when executing your steps below against Scarab
with the following server.xml entry:

Context path="/scarab" docBase="scarab" debug="0"
 reloadable="true"
  Logger className="org.apache.catalina.logger.FileLogger"
 prefix="scarab_log." suffix=".txt"
  timestamp="true"/
  Manager debug="99"/
/Context

As you can see from the log, the session attribute "turbine.user" is saved and
then reloaded, but nothing else.  What else would you expect to see here?

Craig


Jon Stevens wrote:

 Hi Craig, any status?

 Maybe you can point me at the right place to look?

 thanks,

 -jon

 --
 From: Jon Stevens [EMAIL PROTECTED]
 Reply-To: [EMAIL PROTECTED]
 Date: Fri, 05 Jan 2001 21:37:41 -0800
 To: [EMAIL PROTECTED]
 Subject: Re: cvs commit: jakarta-tomcat-4.0/webapps/ROOT index.html

 on 1/5/2001 8:52 PM, "Craig R. McClanahan" [EMAIL PROTECTED]
 wrote:

  That is not a provably correct assertion, given that it works on every test
  case
  I have concocted so far.
 
  Even if there is something in Turbine that makes it not work, that can be
  dealt
  with subsequent to b1.  It's not like this is the last release or anything
  :-).

 Ok, I have found like 4 bugs in as many days and you still don't believe me
 on these things. :-)

 here we go again:

 #1. check out scarab
 #2. build it; start tomcat
 #3. goto: http://localhost:8080/scarab/servlet/scarab/template/Register.vm
 #4. hit "Register"
 #5. edit scarab/target/webapps/scarab/templates/Register.vm
 Add anywhere in the template:
 $data.getUser().setTemp("foo", "bar")

 #6. hit "Register"
 #7. touch
 scarab/target/webapps/scarab/WEB-INF/classes/org/tigris/scarab/actions/*.cla
 ss
 #7. change the above line to:
 $data.getUser().getTemp("foo")
 #8. hit "Register"

 Notice that you see the data you entered in #7. That is because Velocity
 wasn't able to introspect and find a result for "foo" because it doesn't
 exist in the session any longer.

 $data.getUser() returns an object that has been placed into the HttpSession

 This isn't Turbine that is broken as this same stuff worked fine in JServ
 and Tomcat 3.x. It is definitely Catalina.

 love,

 -jon

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

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


2001-01-10 18:50:49 StandardLoader[/scarab]: Reloading checks are enabled for this 
Context
2001-01-10 18:50:49 Manager[/scarab]: Starting
2001-01-10 18:50:49 Manager[/scarab]: Force random number initialization starting
2001-01-10 18:50:49 Manager[/scarab]: Seeding random number generator class 
java.security.SecureRandom
2001-01-10 18:50:49 Manager[/scarab]: Seeding of random number generator has been 
completed
2001-01-10 18:50:49 Manager[/scarab]: Getting message digest component for algorithm 
MD5
2001-01-10 18:50:49 Manager[/scarab]: Completed getting message digest component
2001-01-10 18:50:49 Manager[/scarab]: Force random number initialization completed
2001-01-10 18:50:50 ContextConfig[/scarab]: Added certificates - request attribute 
Valve
2001-01-10 18:50:50 ContextConfig[/scarab]: Configured an authenticator for method 
BASIC
2001-01-10 18:50:51 Manager[/scarab]: Loading persisted sessions
2001-01-10 18:50:51 Manager[/scarab]: Loading persisted sessions from SESSIONS.ser
2001-01-10 18:50:51 Manager[/scarab]: No persisted data file found
2001-01-10 18:50:51 StandardWrapper[/scarab:default]: Loading container servlet default
2001-01-10 18:50:51 default: init
2001-01-10 18:50:51 StandardWrapper[/scarab:invoker]: Loading container servlet invoker
2001-01-10 18:50:51 invoker: init
2001-01-10 18:50:51 jsp: init
2001-01-10 18:51:35 scarab: init
2001-01-10 18:51:37 scarab: Turbine: init() Ready to Rumble!
2001-01-10 18:51:37 scarab: Turbine: doGet() Start Initializing Services!
2001-01-10 18:51:37 scarab: Turbine: doGet() Finish Initializing Services!
2001-01-10 18:56:08 StandardContext[/scarab]: Reloading this Context has started
2001-01-10 18:56:08 scarab: Turbine: Done shutting down!
2001-01-10 18:56:08 Manager[/scarab]: Unloading persisted sessions
2001-01-10 18:56:08 Manager[/scarab]: Saving persisted sessions to SESSIONS.ser
2001-01-10 18:56:08 Manager[/scarab]: Unloading 1 sessions
2001-01-10 18:56:08 Manager[/scarab]: writeObject() storing session 
F51410925838E0F5666257A405E4A200
2001-01-10 18:56:08 Manager[/scarab]:   storing attribute 'turbine.user' with value 
'org.apache.turbine.om.security.TurbineUser@8ebd435b'
2001-01-10 

Re: AccessLogValve Patch

2001-01-10 Thread Jason Brittain


In the message I just wrote:

 
 --- AccessLogValve.java Wed Jan 10 15:16:10 2001
 +++ AccessLogValve.java-new Wed Jan 10 15:15:50 2001
 @@ -61,6 +61,7 @@
  package org.apache.catalina.valves;
  
  
 +import java.io.BufferedWriter;
  import java.io.File;
  import java.io.FileWriter;
  import java.io.IOException;


Oops!  I forgot to remove the BufferedWriter import before I made
the patch..  Please remove that line.  Thanks!

-- 
Jason Brittain
Software Engineer, Olliance Inc.http://www.Olliance.com
Current Maintainer, Locomotive Project  http://www.Locomotive.org


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




An alternative to JSP

2001-01-10 Thread Brad Cox

I've uploaded an early rough draft of a pair of articles that boils 
down to a critique of the JSP approach plus source code for a quite 
different approach. I'd be very interested in feedback... of the 
constructive variety, of course ;)

The articles are at http://virtualschool.edu/wap
-- 
---
Dr. Brad Cox; [EMAIL PROTECTED]
Phone: 703 361 4751 Fax: 703 995 0422 Cellular: 703 919-9623
http://superdistributed.com: A new paradigm for a new millinneum
PGP Signature: E194 C6E5 92D8 B8FB 20E8  8667 929A 95A0 FCB6 7C62

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




cvs commit: jakarta-tomcat-4.1/catalina/src/share/org/apache/catalina/valves AccessLogValve.java

2001-01-10 Thread remm

remm01/01/10 19:50:39

  Modified:catalina/src/share/org/apache/catalina/valves
AccessLogValve.java
  Log:
  - Fix potential incorrenctly named log files.
Patch submitted by Jason Brittain [EMAIL PROTECTED]
  
  Revision  ChangesPath
  1.3   +10 -7 
jakarta-tomcat-4.1/catalina/src/share/org/apache/catalina/valves/AccessLogValve.java
  
  Index: AccessLogValve.java
  ===
  RCS file: 
/home/cvs/jakarta-tomcat-4.1/catalina/src/share/org/apache/catalina/valves/AccessLogValve.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -r1.2 -r1.3
  --- AccessLogValve.java   2000/11/30 01:55:31 1.2
  +++ AccessLogValve.java   2001/01/11 03:50:39 1.3
  @@ -125,7 +125,7 @@
*
* @author Craig R. McClanahan
* @author Jason Brittain
  - * @version $Revision: 1.2 $ $Date: 2000/11/30 01:55:31 $
  + * @version $Revision: 1.3 $ $Date: 2001/01/11 03:50:39 $
*/
   
   public final class AccessLogValve
  @@ -493,7 +493,7 @@
   /**
* Close the currently open log file (if any)
*/
  -private void close() {
  +private synchronized void close() {
   
if (writer == null)
return;
  @@ -516,9 +516,10 @@
   public void log(String message, Date date) {
   
   // Only do a logfile switch check once a second, max.
  -if ((System.currentTimeMillis() - currentDate.getTime())  1000) {
  +long systime = System.currentTimeMillis();
  +if ((systime - currentDate.getTime())  1000) {
   // We need a new currentDate
  -currentDate = new Date();
  +currentDate = new Date(systime);
   
   // Check for a change of date
   String tsDate = dateFormatter.format(currentDate);
  @@ -563,7 +564,7 @@
   /**
* Open the new log file for the date specified by codedateStamp/code.
*/
  -private void open() {
  +private synchronized void open() {
   
// Create the directory if necessary
File dir = new File(directory);
  @@ -698,8 +699,9 @@
   private Date getDate() {
   
   // Only create a new Date once per second, max.
  -if ((System.currentTimeMillis() - currentDate.getTime())  1000) {
  -currentDate = new Date();
  +long systime = System.currentTimeMillis();
  +if ((systime - currentDate.getTime())  1000) {
  +currentDate = new Date(systime);
   }
   
   return currentDate;
  @@ -770,6 +772,7 @@
   timeFormatter = new SimpleDateFormat("kk:mm:ss");
   timeFormatter.setTimeZone(tz);
   currentDate = new Date();
  +dateStamp = dateFormatter.format(currentDate);
   
   open();
   
  
  
  

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




Re: possible problems in org.apache.catalina.connector.http.SocketInputStream

2001-01-10 Thread Remy Maucherat

Quoting Thomas Butter [EMAIL PROTECTED]:

I think the problem won't be triggered by a small buffer,
but by tcp packet that ends 1 byte after the current buffer.
If the next packet didn't arrive when fill() is triggered
the next time then pos==0 and count==1, the read then does a
pos++.

Here's the code :

while (!space) {
// if the buffer is full, extend it
if (readCount = maxRead) {
if ((2 * maxRead) = HttpRequestLine.MAX_METHOD_SIZE) {
char[] newBuffer = new char[2 * maxRead];
System.arraycopy(requestLine.method, 0, newBuffer, 0,
 maxRead);
requestLine.method = newBuffer;
maxRead = requestLine.method.length;
} else {
throw new IOException
(sm.getString("requestStream.readline.toolong"));
}
}
// We're at the end of the internal buffer
if (pos = count) {
int val = read();
if (val == -1) {
throw new IOException
(sm.getString("requestStream.readline.error"));
}
pos = 0;
readStart = 0;
}
if (buf[pos] == SP) {
space = true;
}
requestLine.method[readCount] = (char) buf[pos];
readCount++;
pos++;
}

After reading 1 char in fill() and putting it in the method buffer,
readCount and pos are incremented, so we have pos = 1, count = 1, and
readCount = 1.
Next loop iteration (assuming the method buffer does not need to be grown :
(pos = count) will be true, since 1 = 1, which will call another read.
Since we're at the end of the stream, we get the exception (which is correct
since the status line was wrong).
If the last character read was a space, then the loop will exit (and we
won't read an undefined character).

 You will then read the char at buf[1] which still
is the char from the last buffer (and so quite undefined).

I can't see why. Is my interpretation on what will happen at the next
iteration wrong ?

 You are right. It is quite easy to reimplement a BIS.

Especially since we don't care about marking here.

Remy

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




Re: An alternative to JSP

2001-01-10 Thread Jon Stevens

on 1/10/01 7:52 PM, "Brad Cox" [EMAIL PROTECTED] wrote:

 I've uploaded an early rough draft of a pair of articles that boils
 down to a critique of the JSP approach plus source code for a quite
 different approach. I'd be very interested in feedback... of the
 constructive variety, of course ;)
 
 The articles are at http://virtualschool.edu/wap
 -- 
 ---
 Dr. Brad Cox; [EMAIL PROTECTED]
 Phone: 703 361 4751 Fax: 703 995 0422 Cellular: 703 919-9623
 http://superdistributed.com: A new paradigm for a new millinneum
 PGP Signature: E194 C6E5 92D8 B8FB 20E8  8667 929A 95A0 FCB6 7C62

MLS? Preprocess code? WHAT?

Have you even looked at what we are doing in Turbine/Velocity land?

Also, let me also refer you to:

http://java.apache.org/turbine/pullmodel.html

-jon


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




BugRat Report #737 has been filed.

2001-01-10 Thread BugRat Mail System

Bug report #737 has just been filed.

You can view the report at the following URL:

   http://znutar.cortexity.com/BugRatViewer/ShowReport/737

REPORT #737 Details.

Project: Tomcat
Category: Bug Report
SubCategory: New Bug Report
Class: swbug
State: received
Priority: medium
Severity: serious
Confidence: public
Environment: 
   Release: tomcat3.2.1
   JVM Release: jdk1.3
   Operating System: Windows -NT
   OS Release: 4
   Platform: NT

Synopsis: 
Unable to Unwrap the WAR file if placed in different context. And not reading the 
web.xml file.

Description:
I have installed tomcat in D:\jakarta-tomcat3.2.1
I am running this in stand alone mode  it is working fine.
But if I add a new Context in a diffrent drive f:\webapps\mycontext in server.xml 
file, it is not unwraping the .war file. If I mannually unwrap  copy the contents it 
is recognizing the index.html. But not reading the web.xml file  failling to load the 
servlet. Same .war if I put in D:\jakarta-tomcat3.2.1\webapps\mycontext it is 
unwrapping  working fine.

NOTE: D:\  F:\ are partitions on my hard disk.(Not network drives)

Title: 
BugRat Report #
737





BugRat Report #
737




Project:
Tomcat


Release:
tomcat3.2.1




Category:
Bug Report


SubCategory:
New Bug Report




Class:
swbug


State:
received




Priority:
medium


Severity:
serious




Confidence:
public





Submitter:
_Anonymous ([EMAIL PROTECTED])

Date Submitted:
Jan 11 2001, 12:38:09 CST

Responsible:
Z_Tomcat Alias ([EMAIL PROTECTED])


Synopsis:

Unable to Unwrap the WAR file if placed in different context. And not reading the web.xml file.


 Environment: (jvm, os, osrel, platform)

jdk1.3, Windows -NT, 4, NT



Additional Environment Description:





Report Description:

I have installed tomcat in D:\jakarta-tomcat3.2.1
I am running this in stand alone mode & it is working fine.
But if I add a new Context in a diffrent drive f:\webapps\mycontext in server.xml file, it is not unwraping the .war file. If I mannually unwrap & copy the contents it is recognizing the index.html. But not reading the web.xml file & failling to load the servlet. Same .war if I put in D:\jakarta-tomcat3.2.1\webapps\mycontext it is unwrapping & working fine.

NOTE: D:\ & F:\ are partitions on my hard disk.(Not network drives)



How To Reproduce:

null



View this report online...






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


BugRat Report #738 has been filed.

2001-01-10 Thread BugRat Mail System

Bug report #738 has just been filed.

You can view the report at the following URL:

   http://znutar.cortexity.com/BugRatViewer/ShowReport/738

REPORT #738 Details.

Project: Tomcat
Category: Bug Report
SubCategory: New Bug Report
Class: swbug
State: received
Priority: high
Severity: critical
Confidence: public
Environment: 
   Release: 4.0 b1
   JVM Release: 1.3
   Operating System: NT
   OS Release: 4
   Platform: Windows

Synopsis: 
JSP tags names must be valid variable names

Description:
On Tomcat 4.0b1 it appears that tag names must be valid Java variable names.
So a tag cannot be named like:
  mytags:set-counter1/mytags:set-counter

Exception reported:
org.apache.jasper.JasperException: Unable to compile class for 
JSP..\work\localhost\lh-app\_0002fToc_0002ejspToc_jsp_0.java:126:
Invalid expression statement.
  _jspx_th_get-folder-attribute_0.setPageContext(pageContext);




Title: 
BugRat Report #
738





BugRat Report #
738




Project:
Tomcat


Release:
4.0 b1




Category:
Bug Report


SubCategory:
New Bug Report




Class:
swbug


State:
received




Priority:
high


Severity:
critical




Confidence:
public





Submitter:
_Anonymous ([EMAIL PROTECTED])

Date Submitted:
Jan 11 2001, 01:06:19 CST

Responsible:
Z_Tomcat Alias ([EMAIL PROTECTED])


Synopsis:

JSP tags names must be valid variable names


 Environment: (jvm, os, osrel, platform)

1.3, NT, 4, Windows



Additional Environment Description:

Tomcat 40b1
Windows NT 4



Report Description:

On Tomcat 4.0b1 it appears that tag names must be valid Java variable names.
So a tag cannot be named like:
  1

Exception reported:
org.apache.jasper.JasperException: Unable to compile class for JSP..\work\localhost\lh-app\_0002fToc_0002ejspToc_jsp_0.java:126:
Invalid expression statement.
  _jspx_th_get-folder-attribute_0.setPageContext(pageContext);






View this report online...






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