security constraints in tomcat 4.1.30

2005-06-03 Thread Angela Stempfel

Hello all

I have a problem concerning Tomcat 4.1.30. In web.xml i defined several 
security constraint. First of all I protected the whole application and 
then I excluded the directories with images and css files. Furthermore I 
defined some roles.


pre
security-constraint
display-nameTCE GUI/display-name
web-resource-collection
web-resource-nameWEBGui Area/web-resource-name
!-- Define the context-relative URL(s) to be protected 
--
url-pattern/*/url-pattern
/web-resource-collection
auth-constraint
!-- Anyone with one of the listed roles may access this 
area --
role-name*/role-name
/auth-constraint
/security-constraint

security-constraint
web-resource-collection
web-resource-nameImages and CSS Not 
Protected/web-resource-name
url-pattern/images/*/url-pattern
url-pattern/css/*/url-pattern
http-methodGET/http-method
http-methodHEAD/http-method
/web-resource-collection
/security-constraint

security-constraint
display-nameDSLAM Configuration/display-name
web-resource-collection
web-resource-name
Access to DSLAM Configuration
/web-resource-name
url-pattern/DslamConfig/*/url-pattern
/web-resource-collection
auth-constraint
role-namedslamConfig/role-name
/auth-constraint
/security-constraint
login-config
auth-methodFORM/auth-method
form-login-config
form-login-page/login.jsp/form-login-page
form-error-page/login-error.jsp/form-error-page
/form-login-config
/login-config

security-role
role-namedslamConfig/role-name
/security-role
/pre

So my problem is that this works fine with Tomcat 5.0 but not with 
Tomcat 4.1.30. If I go to the login page, the stylesheet and images are 
not found when running the Application with version 4.1.30. Also the 
Security Constraints are not working correctly, this means that a user 
that hasn't the role dslamConfig is able to enter the following URL: 
/DslamConfig/*


Has anyone some ideas?

Thanks a lot
Angela

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



Multiple source directories for one webapp

2005-06-03 Thread Laurent Brucher
Hi all,

I guess this is not really new, but I haven't seen any concrete solution nor
much discussion about it.

So here's the problem:
one webapp composed of multiple pieces (jsp, html, css, etc.) located at
various locations on the filesystem.

I know, this goes against the servlet spec. but I've had a need for this
many times by now, especially under
development (our projects are broken down into various modules, each
contributing to creating a final webapp).
For production, an ant task will do the job putting all the pieces correctly
together. Under development,
I find it unpractical to run an ant task every time a jsp has been modified.

We started looking into replacing the resource context with a modified
version of the FileDirContext, with
good results so far. This modified version acts as a directory mapper and,
given a requested resource, provides
its correct location on the filesystem.

Before continuing further in that direction, I was wondering whether there
may be alternatives solutions
to the problem, and also what you guys think about all this?

Thanks,
Laurent.


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



OT Friday - Random sorting

2005-06-03 Thread Mark Benussi
Hello.

 

I am trying to write a comparator that randomly sorts a collection.

 

I have something like this:

 

new Comparator() {

  

  /**

   * @see java.util.Comparator#compare(java.lang.Object,
java.lang.Object)

   */

  public int compare(Object object1, Object object2) {



long time = new Date().getTime();

 

Random random1 = new Random(time);

Integer x1 = new Integer(random1.nextInt());

random1.setSeed(++time);

Integer x2 = new Integer(random1.nextInt());



return x1.compareTo(x2);

  }

}

 

But sadly to no avail.

 

Has anyone done this before or have any suggestions.



Re: OT Friday - Random sorting

2005-06-03 Thread Rafał Krupiński

Mark Benussi wrote:


Hello.
I am trying to write a comparator that randomly sorts a collection.
I have something like this:

new Comparator() {
  /**

   * @see java.util.Comparator#compare(java.lang.Object,
java.lang.Object)

   */

  public int compare(Object object1, Object object2) {
long time = new Date().getTime();
Random random1 = new Random(time);
Integer x1 = new Integer(random1.nextInt());
random1.setSeed(++time);
Integer x2 = new Integer(random1.nextInt());
return x1.compareTo(x2);
  }
}

But sadly to no avail.
Has anyone done this before or have any suggestions.


try this:

new Comparator(){
Random r=new Random();//automatic seed

public int compare(Object object1, Object object2){
return r.nextInt();
}
public boolean equals(Object obj){return this==obj;}
}

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



Logging the HTTP headers

2005-06-03 Thread cristi

Hello all

Is there any posibility of logging the HTTP headers ?

Thx.
Cristi



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



RE: OT Friday - Random sorting

2005-06-03 Thread Mark Benussi
Thanks very much

-Original Message-
From: Rafal Krupinski [mailto:[EMAIL PROTECTED] 
Sent: 03 June 2005 09:06
To: Tomcat Users List
Subject: Re: OT Friday - Random sorting

Mark Benussi wrote:

 Hello.
 I am trying to write a comparator that randomly sorts a collection.
 I have something like this:
 
 new Comparator() {
   /**
 
* @see java.util.Comparator#compare(java.lang.Object,
 java.lang.Object)
 
*/
 
   public int compare(Object object1, Object object2) {
 long time = new Date().getTime();
 Random random1 = new Random(time);
 Integer x1 = new Integer(random1.nextInt());
 random1.setSeed(++time);
 Integer x2 = new Integer(random1.nextInt());
 return x1.compareTo(x2);
   }
 }
 
 But sadly to no avail.
 Has anyone done this before or have any suggestions.

try this:

new Comparator(){
Random r=new Random();//automatic seed

public int compare(Object object1, Object object2){
return r.nextInt();
}
public boolean equals(Object obj){return this==obj;}
}

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



AW: Logging the HTTP headers

2005-06-03 Thread Bernhard Slominski
Hi Cristi,

they are in the Apache Logfile anyway, why do you want to log them again?

Bernhard

 -Ursprüngliche Nachricht-
 Von: cristi [mailto:[EMAIL PROTECTED]
 Gesendet: Donnerstag, 2. Juni 2005 10:04
 An: Tomcat Users List
 Betreff: Logging the HTTP headers
 
 
 Hello all
 
 Is there any posibility of logging the HTTP headers ?
 
 Thx.
 Cristi
 
 
 
 -
 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]



NotifyUtil::java.net.ConnectException: Connection refused: connect

2005-06-03 Thread Otgonbayar
My application works fine but following log is streaming.
I don't know the reason, what should I do?
Thanks
Otgo

NotifyUtil::java.net.ConnectException: Connection refused: connect
at java.net.PlainSocketImpl.socketConnect(Native Method)
at java.net.PlainSocketImpl.doConnect(Unknown Source)
at java.net.PlainSocketImpl.connectToAddress(Unknown Source)
at java.net.PlainSocketImpl.connect(Unknown Source)
at java.net.Socket.connect(Unknown Source)
at java.net.Socket.connect(Unknown Source)
at sun.net.NetworkClient.doConnect(Unknown Source)
at sun.net.www.http.HttpClient.openServer(Unknown Source)
at sun.net.www.http.HttpClient.openServer(Unknown Source)
at sun.net.www.http.HttpClient.init(Unknown Source)
at sun.net.www.http.HttpClient.init(Unknown Source)
at sun.net.www.http.HttpClient.New(Unknown Source)
at sun.net.www.http.HttpClient.New(Unknown Source)
at sun.net.www.http.HttpClient.New(Unknown Source)
at sun.net.www.protocol.http.HttpURLConnection.plainConnect(Unknown
Source)
at sun.net.www.protocol.http.HttpURLConnection.connect(Unknown
Source)
at
sun.net.www.protocol.http.HttpURLConnection.getOutputStream(Unknown Source)
at
org.netbeans.modules.web.monitor.server.NotifyUtil$RecordSender.run(NotifyUt
il.java:237)



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



NotifyUtil::java.net.ConnectException: Connection refused: connect

2005-06-03 Thread Otgonbayar
My application works fine but following log is streaming.
I don't know the reason, what should I do?
Thanks
Otgo

NotifyUtil::java.net.ConnectException: Connection refused: connect
at java.net.PlainSocketImpl.socketConnect(Native Method)
at java.net.PlainSocketImpl.doConnect(Unknown Source)
at java.net.PlainSocketImpl.connectToAddress(Unknown Source)
at java.net.PlainSocketImpl.connect(Unknown Source)
at java.net.Socket.connect(Unknown Source)
at java.net.Socket.connect(Unknown Source)
at sun.net.NetworkClient.doConnect(Unknown Source)
at sun.net.www.http.HttpClient.openServer(Unknown Source)
at sun.net.www.http.HttpClient.openServer(Unknown Source)
at sun.net.www.http.HttpClient.init(Unknown Source)
at sun.net.www.http.HttpClient.init(Unknown Source)
at sun.net.www.http.HttpClient.New(Unknown Source)
at sun.net.www.http.HttpClient.New(Unknown Source)
at sun.net.www.http.HttpClient.New(Unknown Source)
at sun.net.www.protocol.http.HttpURLConnection.plainConnect(Unknown
Source)
at sun.net.www.protocol.http.HttpURLConnection.connect(Unknown
Source)
at
sun.net.www.protocol.http.HttpURLConnection.getOutputStream(Unknown Source)
at
org.netbeans.modules.web.monitor.server.NotifyUtil$RecordSender.run(NotifyUt
il.java:237)



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



Re: Logging the HTTP headers

2005-06-03 Thread Markus Schönhaber
Am Donnerstag, 2. Juni 2005 10:03 schrieb cristi:
 Hello all

 Is there any posibility of logging the HTTP headers ?

http://jakarta.apache.org/tomcat/tomcat-5.5-doc/config/valve.html#Request%20Dumper%20Valve

Regards
  mks

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



Re: Context at Host Level

2005-06-03 Thread Andrés Glez.

Exactly what i was looking for. Thanks!

- Original Message - 
From: Mark Thomas [EMAIL PROTECTED]

To: Tomcat Users List tomcat-user@jakarta.apache.org
Sent: Thursday, June 02, 2005 9:03 PM
Subject: Re: Context at Host Level



Andrés Glez. wrote:


there is no ContainerListener or something like that?



Look at http://jakarta.apache.org/tomcat/tomcat-5.5-doc/config/engine.html 
and

http://jakarta.apache.org/tomcat/tomcat-5.5-doc/config/host.html

You need to seach for lifecycle listener. Not part of the spec but might 
help you.


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



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



Re: OT Friday - Random sorting

2005-06-03 Thread Holger Klawitter
Mark Benussi wrote:

 Hello.
 
  
 
 I am trying to write a comparator that randomly sorts a collection.
 
  
 
 I have something like this:
 
  
 
 new Comparator() {
 
   
 
   /**
 
* @see java.util.Comparator#compare(java.lang.Object,
 java.lang.Object)
 
*/
 
   public int compare(Object object1, Object object2) {
 
 
 
 long time = new Date().getTime();
 
  
 
 Random random1 = new Random(time);
 
 Integer x1 = new Integer(random1.nextInt());
 
 random1.setSeed(++time);
 
 Integer x2 = new Integer(random1.nextInt());
 
 
 
 return x1.compareTo(x2);
 
   }
 
 }
 
  
 
 But sadly to no avail.
 
  
 
 Has anyone done this before or have any suggestions.

I'd just use java.util.Collections.shuffle().

-- 
With Kind Regards / Mit freundlichem Gruß
  Holger Klawitter (listen at klawitter dot de)


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



Re: Logging the HTTP headers

2005-06-03 Thread Anto Paul
On 6/3/05, Markus Schönhaber [EMAIL PROTECTED] wrote:
 Am Donnerstag, 2. Juni 2005 10:03 schrieb cristi:
  Hello all
 
  Is there any posibility of logging the HTTP headers ?
 
 http://jakarta.apache.org/tomcat/tomcat-5.5-doc/config/valve.html#Request%20Dumper%20Valve

 
What about a Filter ?

-- 
rgds
Anto Paul

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



Re: AW: Logging the HTTP headers

2005-06-03 Thread Jon Wingfield

You can also just watch these on the fly with browser plug-ins:
IE: google for ieHTTPHeaders
Mozilla/FireFox: http://livehttpheaders.mozdev.org/index.html

Both have been very useful to us.

Jon

Bernhard Slominski wrote:


Hi Cristi,

they are in the Apache Logfile anyway, why do you want to log them again?

Bernhard



-Ursprüngliche Nachricht-
Von: cristi [mailto:[EMAIL PROTECTED]
Gesendet: Donnerstag, 2. Juni 2005 10:04
An: Tomcat Users List
Betreff: Logging the HTTP headers


Hello all

Is there any posibility of logging the HTTP headers ?

Thx.
Cristi



-
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: Logging the HTTP headers

2005-06-03 Thread Markus Schönhaber
Am Freitag, 3. Juni 2005 11:46 schrieb Anto Paul:
 On 6/3/05, Markus Schönhaber [EMAIL PROTECTED] wrote:
  Am Donnerstag, 2. Juni 2005 10:03 schrieb cristi:
   Hello all
  
   Is there any posibility of logging the HTTP headers ?
 
  http://jakarta.apache.org/tomcat/tomcat-5.5-doc/config/valve.html#Request
 %20Dumper%20Valve

 What about a Filter ?

Yeah, what about it?

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



Re: AW: Logging the HTTP headers

2005-06-03 Thread cristi


thank you all of you.

cristi



You can also just watch these on the fly with browser plug-ins:
IE: google for ieHTTPHeaders
Mozilla/FireFox: http://livehttpheaders.mozdev.org/index.html


Hello all

Is there any posibility of logging the HTTP headers ?

Thx.
Cristi



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




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






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




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



RE: OT Friday - Random sorting

2005-06-03 Thread Mark Benussi
Even better, thank you!

-Original Message-
From: news [mailto:[EMAIL PROTECTED] On Behalf Of Holger Klawitter
Sent: 03 June 2005 09:06
To: tomcat-user@jakarta.apache.org
Cc: user@excalibur.apache.org
Subject: Re: OT Friday - Random sorting

Mark Benussi wrote:

 Hello.
 
  
 
 I am trying to write a comparator that randomly sorts a collection.
 
  
 
 I have something like this:
 
  
 
 new Comparator() {
 
   
 
   /**
 
* @see java.util.Comparator#compare(java.lang.Object,
 java.lang.Object)
 
*/
 
   public int compare(Object object1, Object object2) {
 
 
 
 long time = new Date().getTime();
 
  
 
 Random random1 = new Random(time);
 
 Integer x1 = new Integer(random1.nextInt());
 
 random1.setSeed(++time);
 
 Integer x2 = new Integer(random1.nextInt());
 
 
 
 return x1.compareTo(x2);
 
   }
 
 }
 
  
 
 But sadly to no avail.
 
  
 
 Has anyone done this before or have any suggestions.

I'd just use java.util.Collections.shuffle().

-- 
With Kind Regards / Mit freundlichem Gruß
  Holger Klawitter (listen at klawitter dot de)


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


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



Re: Tomcat service terminated unexpectedly

2005-06-03 Thread Ivy Chen
which log file I can check the error message?
I had check all files in %TOMCAT_HOME%\logs ,but can't any helpful message.
The another process --pc Anywhere host Service on the machine have same
issue.

Ivy

- Original Message - 
From: Parsons Technical Services [EMAIL PROTECTED]
To: Tomcat Users List tomcat-user@jakarta.apache.org
Sent: Thursday, June 02, 2005 10:35 AM
Subject: Re: Tomcat service terminated unexpectedly


 What is in the logs?

 Did it start this at some point or has it been happening all along?

 Consider updating you JDK. You may even try 1.5 as it is faster.

 Check you debug settings and turn them up.

 Look in the logs for the last connection/request to see what was being
asked
 for. If needed set up the logger for this.

 Are any other services on the machine having issues?

 What is the shortest and longest time between crashes?

 What is your user load?

 Sorry I have no clear answers, only question. There can be so many things
 affecting you it can be somewhat difficult to pin it down.

 Doug


 - Original Message - 
 From: ivy chen [EMAIL PROTECTED]
 To: Tomcat Users List tomcat-user@jakarta.apache.org
 Sent: Wednesday, June 01, 2005 9:36 PM
 Subject: Tomcat service terminated unexpectedly


 Hi,All
 I am running Tomcat 4.1.12 , in a W2K Box (tomcat 4.1.12+ java 1.4.1_02+
W2K
 SP4, ).

 Tomcat is running as a service and time to time (random) it crashes with
the
 following message:

 The Apache Tomcat 4.1 service terminated unexpectedly. It has done this 1
 time(s). The following corrective action will be taken in 6
 milliseconds: Restart the service.

 The source of this message is Service Control Manager and the Event id is
 7031.

 Are there anyone encounter this case, any have any advice?

 B.R.
 Ivy






 -
 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: Number of running threads

2005-06-03 Thread neil.shadrach
Caldarale, Charles R [mailto:[EMAIL PROTECTED] 

 [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]
 
 Why only two rather than maxThreads?

How many separate clients are you using to test this with? Browsers
typically honor the HTTP RFC recommendation of no more that two
concurrent requests to a given host at a time.

Perfect answer!
I was using mainly one, sometimes two.
I just wrote a script to retrieve the pages and sure enough I got a more
sensible level of activity.
Thanks for that - I was looking in completely the wrong place.

Regards

Neil Shadrach

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



Tomcat 5.5 in dos window

2005-06-03 Thread Søren Blidorf
Hi.

Is it possible to start tomcat 5.5 i a dos window instead of as a
service?

I need it to monitor System.err.println()

Soren, DK
Nolas Consulting




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



Tomcat 5.0 Windows NSI Build with custom webapps

2005-06-03 Thread Jean-Philippe Encausse


Hi,

How can I make a Windows Tomcat 5.0 Installer
with custom configuration and webapp bundled ?

Best Regards
--
Jean-Philippe Encausse - RD Jalios SA
[EMAIL PROTECTED] - http://www.encausse.com - http://www.jalias.com
ICQ: 109796741 - AOL: NextOne - MSN: [EMAIL PROTECTED]
Mob: +33 6 80 75 71 09 Office: +33 1 39 23 92 83 Home: +33 1 39 18 90 15
Do it Once, Use it Twice ~ Do it Twice, Make It Once


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



Re: Tomcat 5.5 in dos window

2005-06-03 Thread Jason Bainbridge
On 6/3/05, Søren Blidorf [EMAIL PROTECTED] wrote:
 Hi.
 
 Is it possible to start tomcat 5.5 i a dos window instead of as a
 service?

Download the Zip archive instead of the installer and that will have a
startup.bat that you can use just for that purpose, no idea why they
stopped including the bat files in the installer...

Regards,
-- 
Jason Bainbridge
http://kde.org - [EMAIL PROTECTED]
Personal Site - http://jasonbainbridge.com

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



Tomcat 5.5.x EL (Expression Language) issue

2005-06-03 Thread Woodchuck
hihi all,

i am upgrading a webapp from TC 4.1.24 to TC 5.5.9 and discovered what
seems to be an EL related issue.

my webapp uses:
  - JSTL 1.0
  - web.xml with version 2.3 dtd (ie. EL turned OFF by default)
  - Struts 1.1

the piece of code with the issue is with the logic:iterate tag
basically as follows:

logic:iterate name=myObj property=foo.bar id=fb indexId=idx
 ...
/logic

in TC 4.1.24 the above works fine, but in TC 5.5.9 i get the following
error:

javax.servlet.jsp.JspException: No getter method for property foo.bar
of bean myObj

i'm not sure but i believe what is happening is that the
logic:iterate tag is looking literally for the method getFoo.bar() in
myObj instead of doing myObj.getFoo().getBar()

any ideas?

please and thanks!
woodchuck



__ 
Discover Yahoo! 
Find restaurants, movies, travel and more fun for the weekend. Check it out! 
http://discover.yahoo.com/weekend.html 


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



Re: Multiple source directories for one webapp

2005-06-03 Thread Marius Scurtescu

Laurent Brucher wrote:

Hi all,

I guess this is not really new, but I haven't seen any concrete solution nor
much discussion about it.

So here's the problem:
one webapp composed of multiple pieces (jsp, html, css, etc.) located at
various locations on the filesystem.

I know, this goes against the servlet spec. but I've had a need for this
many times by now, especially under
development (our projects are broken down into various modules, each
contributing to creating a final webapp).
For production, an ant task will do the job putting all the pieces correctly
together. Under development,
I find it unpractical to run an ant task every time a jsp has been modified.

We started looking into replacing the resource context with a modified
version of the FileDirContext, with
good results so far. This modified version acts as a directory mapper and,
given a requested resource, provides
its correct location on the filesystem.

Before continuing further in that direction, I was wondering whether there
may be alternatives solutions
to the problem, and also what you guys think about all this?


It all depends on what OS and what editor you use. Under Unix using 
symbolic links could be a solution.


I am not familiar with rsync, but you could use a tool like that to keep 
two folders in sync. It should be possible to setup a process that is 
watching your working folder and every time a file changes to copy it 
over to the deployed web app folder.


I had a similar problem a while back (Windows/IDEA) and I ended up using 
a plugin that will copy the JSP file to the right location when hitting 
 a special key. I found this plugin to be very effective.




Thanks,
Laurent.


Marius


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



RE: servlet request time out ?!

2005-06-03 Thread Angelov, Rossen
I tried adding it to my .../WEB-INF/web.xml
web-app

  session-config
session-timeout45/session-timeout
  /session-config

  ...
/web-app

but I started getting errors when tomcat is deploying the context:

Jun 3, 2005 11:51:20 AM org.apache.commons.digester.Digester error
SEVERE: Parse Error at line 28 column 11: The content of element type
web-app must match
(icon?,display-name?,description?,distributable?,context-param*,filter*,fil
ter-mapping*,listener*,servlet*,servlet-mapping*,session-config?,mime-mappin
g*,welcome-file-list?,error-page*,taglib*,resource-env-ref*,resource-ref*,se
curity-constraint*,login-config?,security-role*,env-entry*,ejb-ref*,ejb-loca
l-ref*).
org.xml.sax.SAXParseException: The content of element type web-app must
match
(icon?,display-name?,description?,distributable?,context-param*,filter*,fil
ter-mapping*,listener*,servlet*,servlet-mapping*,session-config?,mime-mappin
g*,welcome-file-list?,error-page*,taglib*,resource-env-ref*,resource-ref*,se
curity-constraint*,login-config?,security-role*,env-entry*,ejb-ref*,ejb-loca
l-ref*).

It looks like an XML error, but I don't see where is the problem.
Removing the above 3 lines gets rid of the errors

Ross
-Original Message-
From: J. Alejandro Zepeda Cortés [mailto:[EMAIL PROTECTED]
Sent: Thursday, June 02, 2005 11:10 AM
To: Tomcat Users List
Subject: Re: servlet request time out ?!


Maybe the setting in your web.xml is not enough for your request?

session-config
  session-timeout45/session-timeout!-- 30 minutes by default--
/session-config

- Original Message -
From: Angelov, Rossen [EMAIL PROTECTED]
To: 'Tomcat Users List' tomcat-user@jakarta.apache.org
Sent: Thursday, June 02, 2005 11:34 AM
Subject: RE: servlet request time out ?!


 I would like to bring that issue up again as I haven't resolved it yet and
 haven't found what's causing it.

 Any help and ideas are welcome!

 Thanks,
 Ross

 -Original Message-
 From: Angelov, Rossen
 Sent: Thursday, May 26, 2005 1:33 PM
 To: 'Tomcat Users List'
 Subject: servlet request time out ?!


 Hi,
 Does anybody know about a time out on a servlet request with Tomcat 5?

 The problem is that I have a request that takes about 30 minutes but the
 browser keeps waiting for the response forever. I tried different browsers
 but it's the same behavior.

 I put debug statements in the doPost method and it's finishing correctly.
 The last debug statement is printed out but the browser is still waiting
for
 the response.

 Ross

 This communication is intended solely for the addressee and is
 confidential and not for third party unauthorized distribution.



 This communication is intended solely for the addressee and is
 confidential and not for third party unauthorized distribution.





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

This communication is intended solely for the addressee and is
confidential and not for third party unauthorized distribution.



Tomcat 5.X Cocoon

2005-06-03 Thread Omar Adobati
Good Morning to all,
  I need to know if anyone can run cocoon on Tomcat 5.x.
Reading on the official site of cocoon it seems to not be possible to
run cocoon on Tomcat 5.x. This came from the fact that I cant find an
help in how to do this on the site.

Does anyone can help me?

-- 
Omar Adobati

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



tomcat-error

2005-06-03 Thread Christian Stalp
Hello together,
I have a problem, concerning the normal call of the Tomcat-Startpage. Each 
time I call the localhost:8180 ( 8180 is my port for tomcat, debian-tomcat )  
I get this weired output on my Browser. I don't understand this, the servelt 
were not compiled in runtime like a PHP or Perl-script!?!

This is it:

[quote]
HTTP Status 500 -

type Exception report

message

description The server encountered an internal error () that prevented it from 
fulfilling this request.

exception

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:85)
 at 
org.apache.jasper.compiler.ErrorDispatcher.javacError(ErrorDispatcher.java:248)
 at org.apache.jasper.compiler.Compiler.generateClass(Compiler.java:315)
 at org.apache.jasper.compiler.Compiler.compile(Compiler.java:328)
 at 
org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.java:427)
 at 
org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:142)
 at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:240)
 at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:187)
 at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
 at 
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:200)
 at org.apache.catalina.core.ApplicationFilterChain.access$000
(ApplicationFilterChain.java:51)
 at 
org.apache.catalina.core.ApplicationFilterChain$1.run(ApplicationFilterChain.java:129)
 at java.security.AccessController.doPrivileged(Native Method)
 at 
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:125)
 at 
org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:209)
 at 
org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:596)
 at 
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:433)
 at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:948)
 at 
org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:144)
 at 
org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:596)
 at 
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:433)
 at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:948)
 at org.apache.catalina.core.StandardContext.invoke(StandardContext.java:2358)
 at 
org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:133)
 at 
org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:596)
 at 
org.apache.catalina.valves.ErrorDispatcherValve.invoke(ErrorDispatcherValve.java:118)
 at 
org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:594)
 at 
org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:116)
 at 
org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:594)
 at 
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:433)
 at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:948)
 at 
org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:127)
 at 
org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:596)
 at 
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:433)
 at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:948)
 at org.apache.coyote.tomcat4.CoyoteAdapter.service(CoyoteAdapter.java:152)
 at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:799)
 at 
org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.processConnection(Http11Protocol.java:705)
 at org.apache.tomcat.util.net.TcpWorkerThread.runIt(PoolTcpEndpoint.java:577)
 at 
org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:683)
 at java.lang.Thread.run(Thread.java:534)

Apache Tomcat/4.1

[/quote]
Can anybody help me?

Thank you

Gruss Christian

-- 
Christian Stalp
Institut für Medizinische Biometrie, Epidemiologie und Informatik
Johannes-Gutenberg-Universität Mainz
Tel.: 06131 / 17-3107
E-Mail: [EMAIL PROTECTED]

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



Eclipse/Error listenerStart problem need Class Loader Configuration Dumper

2005-06-03 Thread tomcat-users . list

I would like to dump the configuration of a specific instance of a class
loader form within tomcat.  For some reason when I run TC standalone my
listener works no problem, the class loader can find my class from
within my webapp directory.  However when its run under Eclipse it can
not, I notice that Eclipse does not create/copy a
conf/catalina.properties file.

The problem exhibits itself as a ClassNotFoundException throw because
the class loader can not find my Listener class, but when TC is running
standalone it can be found and the only copy exists within the
WEB-INF/classes directory of my webapp.

So my next step to tracking down this problem is to somehow dump the
configuration status of the loader variable within this snipper from
5.5.9.  So that I can identify incorrect CLASSPATH setup or priorities
between to two runtime tomcat setups.

Maybe such verbose dumping code could be included within tomcat and used
to emit a CLASSPATH walk for any ClassNotFoundExceptions thrown, this
really basic error must cause developers many hours of head scratching
when it would be nice if the error message indicated all the paths where
it looked and did not find a matching class.  So at least you know where
it looked.

 From 5.5.9:
./jakarta-tomcat-catalina/catalina/src/share/org/apache/catalina/core/StandardContext.java:3602

public boolean listenerStart() {

if (log.isDebugEnabled())
log.debug(Configuring application event listeners);

// Instantiate the required listeners
ClassLoader loader = getLoader().getClassLoader();
String listeners[] = findApplicationListeners();
Object results[] = new Object[listeners.length];
boolean ok = true;
for (int i = 0; i  results.length; i++) {
if (getLogger().isDebugEnabled())
getLogger().debug( Configuring event listener class ' +
listeners[i] + ');
try {
Class clazz = loader.loadClass(listeners[i]);
results[i] = clazz.newInstance();
} catch (Throwable t) {
getLogger().error
(sm.getString(standardContext.applicationListener,
  listeners[i]), t);
ok = false;
}
}
if (!ok) {

getLogger().error(sm.getString(standardContext.applicationSkipped));
return (false);
}



--
Darryl L. Miles

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



Re: Tomcat 5.X Cocoon

2005-06-03 Thread Jason Bainbridge
On 6/3/05, Omar Adobati [EMAIL PROTECTED] wrote:
 Good Morning to all,
   I need to know if anyone can run cocoon on Tomcat 5.x.
 Reading on the official site of cocoon it seems to not be possible to
 run cocoon on Tomcat 5.x. This came from the fact that I cant find an
 help in how to do this on the site.
 
 Does anyone can help me?

First Google result for Tomcat 5.5 cocoon is:
http://www.devx.com/opensource/Article/27102/1954?pf=true

Regards,
-- 
Jason Bainbridge
http://kde.org - [EMAIL PROTECTED]
Personal Site - http://jasonbainbridge.com

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



RE: Tomcat service terminated unexpectedly

2005-06-03 Thread Sir John Nueva
How much memory do you have in w2k.
One time this thing happen to my tomcat but my guess is the ODBC
driver. I have a shared foxpro table in use by other application
and i have a webapp that access the foxpro table - suddenly shutdown
my tomcat service.

If you can not find any information in the log file try checking for any
conflict like port, etc.. in your w2k. If you can check the event log of w2k
you might find a clue.

Cheers,
John

-Original Message-
From: Ivy Chen [mailto:[EMAIL PROTECTED]
Sent: Friday, June 03, 2005 7:29 PM
To: Tomcat Users List
Subject: Re: Tomcat service terminated unexpectedly


which log file I can check the error message?
I had check all files in %TOMCAT_HOME%\logs ,but can't any helpful message.
The another process --pc Anywhere host Service on the machine have same
issue.

Ivy

- Original Message -
From: Parsons Technical Services [EMAIL PROTECTED]
To: Tomcat Users List tomcat-user@jakarta.apache.org
Sent: Thursday, June 02, 2005 10:35 AM
Subject: Re: Tomcat service terminated unexpectedly


 What is in the logs?

 Did it start this at some point or has it been happening all along?

 Consider updating you JDK. You may even try 1.5 as it is faster.

 Check you debug settings and turn them up.

 Look in the logs for the last connection/request to see what was being
asked
 for. If needed set up the logger for this.

 Are any other services on the machine having issues?

 What is the shortest and longest time between crashes?

 What is your user load?

 Sorry I have no clear answers, only question. There can be so many things
 affecting you it can be somewhat difficult to pin it down.

 Doug


 - Original Message -
 From: ivy chen [EMAIL PROTECTED]
 To: Tomcat Users List tomcat-user@jakarta.apache.org
 Sent: Wednesday, June 01, 2005 9:36 PM
 Subject: Tomcat service terminated unexpectedly


 Hi,All
 I am running Tomcat 4.1.12 , in a W2K Box (tomcat 4.1.12+ java 1.4.1_02+
W2K
 SP4, ).

 Tomcat is running as a service and time to time (random) it crashes with
the
 following message:

 The Apache Tomcat 4.1 service terminated unexpectedly. It has done this 1
 time(s). The following corrective action will be taken in 6
 milliseconds: Restart the service.

 The source of this message is Service Control Manager and the Event id is
 7031.

 Are there anyone encounter this case, any have any advice?

 B.R.
 Ivy






 -
 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: Tomcat + HP-UX = NoSuchMethodError java.lang.String.contains(Ljava/lang/String;)

2005-06-03 Thread Wendy Smoak
From: QM [EMAIL PROTECTED]

 On Thu, Jun 02, 2005 at 05:37:23PM -0700, Wendy Smoak wrote:
 :  Any idea why String.contains(String) wouldn't work within Tomcat 4.1
on
 :  HP-UX and Java 1.5?

 Doesn't Tomcat 4.1 even support JDK 1.5?

Tomcat 4.1 works fine under JDK 1.5 on Windows 2000... I see that Tomcat 5.5
requires Java 1.5 by default, but that's the only restriction I've seen.

 Are you using 1.5 to build, run, or both?

Both... but Sun's version on Windows to build, and HP's on HP-UX to run.

-- 
Wendy Smoak


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



why is hostnameverifier() necessary?

2005-06-03 Thread joelsherriff
This is an SSL HostnameVerifier() question.  I _believe_ I have my client and 
server certificates configured properly and, up to now, I have been accessing 
my server via ip address and using the ip address as the CN in the server cert. 
 So I assumed that the problems I was having on the client side when connecting 
to the server, which required using a HostnameVerifier(), were due to the 
default rules for URL hostname verification failing, whatever they are, quoted 
from the javax.net.ssl.HostnameVerifier doc.  I assumed it was failing because 
I was connecting using the IP address and that that, for whatever reason, 
didn't pass the default rules.

But...now I've modified my server cert to contain the correct domain name, the 
same domain name I'm connecting to, and I'm still getting an HTTPS hostname 
wrong:  should be ... error.  If I use a hostname verifier callback in order 
to make it work, it tells me that the hostname it's looking for and the 
hostname in the cert are exactly the same!  So why is my hostnameverifier 
necessary?

Hope someone can shine a light on this...

Thanks

JS

RE: WebappClassLoader - don't understand what's happening

2005-06-03 Thread Herrmann, Sascha \(GE Healthcare\)
Well, it seems that the shared classes in shared\lib really are responsible
for this. I tried to move those in the WEB-INF\lib directories. There are a 
couple of new problems to work out, nothing serious, but the problem with the 
shared classes
vanished.

Thanks again for your assistance.

 did lose my mind in the maze of classloading several time.

I know what you mean :o)

Sascha


 -Original Message-
 From: delbd [mailto:[EMAIL PROTECTED] 
 Sent: Thursday, June 02, 2005 4:02 PM
 To: Tomcat Users List
 Subject: Re: WebappClassLoader - don't understand what's happening
 
 Le Jeudi 2 Juin 2005 14:50, Herrmann, Sascha (GE Healthcare) a écrit :
   Any library having static methods like 
 SomeLibraryClass.setXYZ(xyz); 
   SomeLibraryClass.getXYZ(xyz);
 
  Wow, wow, wow  . You mean any class that has static 
 methods gets 
  shared?? Any class that calls static methods? Could you 
 explain that a 
  bit further, please?
 
 
 No, i mean a shared class which has static methods could 
 potentially serves as a bridge for objects between web 
 applications :) I forgot the 'shared' in the sentence 'Any 
 shared library having static methods', sorry ;)
 
   so i doubt usefull informations comes from it.
 
  It works for all the other methods I put this code in. It 
 seems that 
  Tomcat assigns the CL to thread when it's fetched from the pool.
 
 Possible, might have a sense in terms of security.
 
 
  It's definitely the case. We have a static log variable in the 
  classes. It holds the log4j logger reference. All the debug output 
  from the class goes into the log file of the application 
 that started 
  first (the one that loaded the class). Even the output when 
 I use the 
  app that was started second. That's how I noticed in the 
 first place.
 
 
 is log4j a shared lib? if this is the case, might explain why 
 all logs are in one common file (see log4j explanations for 
 details, it's stated log4j should be put in WEB-INF/lib and 
 nowhere else to prevent problems in J2EE environnement). In 
 your case, this simply mean the config is shared, like is the 
 log4j libraries. 
 Don't mis this point: static Logger 
 Logger.getLogger(SomeClass.class), does not mean the logger 
 is 'the one for the class' but this mean the Logger is 'the 
 one having the name some.package.SomeClass' this difference 
 is subtle but has lots of implications when several different 
 classes with excaclty the same name and package are using a 
 common Log4j library.
 
  Are you familiar with the classloading stuff?
 
 
 did lose my mind in the maze of classloading several time.
 
  I was wondering ... when the WebappClassLoader doesn't find 
 the class 
  in its path, and then delegates the loading to the shared 
 classloader 
  ... and when then the shared classloader loads the class  who 
  resolves the dependecies of this loaded class? Does the 
  WebappClassLoader get a shot first, or is it still the 
 shared classloader?
 
 when the shared class loader loads a class in the delegation 
 model, it assigns itself to the class.getClassLoader(). That 
 is any other class further loaded by object of the first 
 class will be loaded using the shared classloader. 
 This is the excpected behaviour. So in your question, the 
 answer is no the WebappClassLoader is not given a chance to 
 resolve as shared classloader does not know it's childrens
 
 
  What if the shared classloader loads a class, and then 
 cannot resolve 
  a referenced class (because it's in one of the app's WEB-INF\lib 
  directories)
 
 the sharedclassloader is unable to load anything in 
 WEB-INF/lib, because it doesn't know about it.
 So in your case, it will ask it's parent (probably the JVM 
 classLoader) which will throw a ClassNotFoundException
 
 
  ... how does he determine which child WebappClassLoader he 
 is to use? 
  And who is registered in the JVM then as initiating classloader?
 
 The delegation model goes down - top (from the calling class' 
 classloader to the root classloader), it nevers goes back 
 down later. A class instanciated by the shared classloader, 
 is *never* able to load any class from a WEB-INF/lib using 
 Class.forName()
 
 
  I am asking because we have classes in our shared\lib 
 directory. Those 
  classes use a factory pattern to instantiate classes (that 
 can be in 
  the WEB-INF\lib dirs). Now, I wonder how these classes are loaded, 
  that the factory class in shared\lib needs?
 
 Sorry but if factories are in shared/lib, they are unable to 
 load anything from WEB-INF/lib  with one exception, if 
 they are passed as argument the classloader of the 
 WEB-INF/lib to use, they can use it to instanciate the class. 
 But this is not a suggested way to write factories.
 However, a better behaviour would anyway be to put those 
 factories in WEB-INF/lib insteed of shared/lib
 
 
  Or am I thinking in the wrong direction? Does the WebappClassLoader 
  always try first?
 
  Damn, I wish I would know this 

What is wrong with my TC cofiguration?

2005-06-03 Thread Vernon
I keep getting the following repeating error message
in my log file:

2005-06-03 09:54:54,500 DEBUG
[org.apache.catalina.session.ManagerBase] - Start
expire sessions StandardManager at 1117817694500
sessioncount 4
2005-06-03 09:54:54,500 DEBUG
[org.apache.catalina.session.ManagerBase] - End expire
sessions StandardManager processingTime 0 expired
sessions: 0

This pair of message repeats every minute. I don't do
anything special. MY application is totally
misbehaving. What is wrong here?

TC version is 5.5.9. JVM 1.5.03.

Thannks very much for your inputs.




__ 
Discover Yahoo! 
Have fun online with music videos, cool games, IM and more. Check it out! 
http://discover.yahoo.com/online.html

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



Re: servlet request time out ?!

2005-06-03 Thread Jason Bainbridge
On 6/3/05, Angelov, Rossen [EMAIL PROTECTED] wrote:
 I tried adding it to my .../WEB-INF/web.xml
 web-app
 
   session-config
 session-timeout45/session-timeout
   /session-config
 
   ...
 /web-app
 
 but I started getting errors when tomcat is deploying the context:
 
 Jun 3, 2005 11:51:20 AM org.apache.commons.digester.Digester error
 SEVERE: Parse Error at line 28 column 11: The content of element type
 web-app must match
 (icon?,display-name?,description?,distributable?,context-param*,filter*,fil
 ter-mapping*,listener*,servlet*,servlet-mapping*,session-config?,mime-mappin
 g*,welcome-file-list?,error-page*,taglib*,resource-env-ref*,resource-ref*,se
 curity-constraint*,login-config?,security-role*,env-entry*,ejb-ref*,ejb-loca
 l-ref*).
 org.xml.sax.SAXParseException: The content of element type web-app must
 match
 (icon?,display-name?,description?,distributable?,context-param*,filter*,fil
 ter-mapping*,listener*,servlet*,servlet-mapping*,session-config?,mime-mappin
 g*,welcome-file-list?,error-page*,taglib*,resource-env-ref*,resource-ref*,se
 curity-constraint*,login-config?,security-role*,env-entry*,ejb-ref*,ejb-loca
 l-ref*).

The session-config details need to go after the servlet-mapping's and
before the mime-mapping's in your web.xml, that is what that error is
saying, the DTD expects the elements to be in a certain order and your
order isn't correct.

Regards,
-- 
Jason Bainbridge
http://kde.org - [EMAIL PROTECTED]
Personal Site - http://jasonbainbridge.com

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



Could not find a worker error

2005-06-03 Thread Michael Thompson
I am trying to configure mod_jk 1.2.11 to work with apache httpd 2.0.54
and tomcat 5.5 and having difficulties.  It seems the worker is not
configured correctly.  

The jk_mod log shows the following error:
[Fri Jun 03 10:33:37 2005] [info]  jk_handler::mod_jk.c (1976): Could
not find a worker for worker name=live

My workers.properties file:
workers.tomcat_home=/usr/local/tomcat_live
workers.java_home=/usr/java14_64
ps=/
#
worker.list=live
worker.live.type=ajp13
worker.live.port=8109
worker.live.host=localhost

My jk config in httpd.conf:
LoadModule jk_module modules/mod_jk.so
JkWorkersFile   /usr/local/apache2/conf/workers.properties
JkLogFile   /usr/local/apache2/logs/mod_jk.log
JkLogLevel  info
JkMount /servlet/*  live
Alias /servlet /usr/local/tomcat_live/webapps/ROOT/WEB-INF/lib

My server.xml:
Server port=8105 shutdown=SHUTDOWN

  GlobalNamingResources
!-- Used by Manager webapp --
Resource name=UserDatabase auth=Container
  type=org.apache.catalina.UserDatabase
   description=User database that can be updated and saved
  
factory=org.apache.catalina.users.MemoryUserDatabaseFactory
  pathname=conf/tomcat-users.xml /
  /GlobalNamingResources

  Service name=Catalina
Connector port=8180 /

!-- This is here for compatibility only, not required --
Connector port=8109 protocol=AJP/1.3 /

Engine name=Catalina defaultHost=localhost
  Realm className=org.apache.catalina.realm.UserDatabaseRealm
 resourceName=UserDatabase /
  Host name=localhost appBase=webapps /
/Engine

  /Service


!-- Define a non-SSL Coyote HTTP/1.1 Connector on port 8080(or 9090)
--   
Connector port=8180
   maxThreads=150 minSpareThreads=25
maxSpareThreads=75
   enableLookups=false redirectPort=8143
acceptCount=100
   debug=0 connectionTimeout=2
   disableUploadTimeout=true /
!-- Note : To disable connection timeouts, set connectionTimeout
value
 to 0 --

!-- Note : To use gzip compression you could set the following
properti
es :

   compression=on
   compressionMinSize=2048
   noCompressionUserAgents=gozilla, traviata
   compressableMimeType=text/html,text/xml
--

!-- Define a SSL Coyote HTTP/1.1 Connector on port 8443  (9443)--

!--
Connector port=8143
   maxThreads=150 minSpareThreads=25
maxSpareThreads=75
   enableLookups=false disableUploadTimeout=true
   acceptCount=100 debug=0 scheme=https
secure=true
   clientAuth=false sslProtocol=TLS /
--

!-- Define a Coyote/JK2 AJP 1.3 Connector on port 8009 --
Connector port=8109
   enableLookups=false redirectPort=8143 debug=0
   protocol=AJP/1.3 /
/Server

Can anyone point me in the right direction?  

Thank you very much for any help you can give.  
Michael Thompson

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



RE: servlet request time out ?!

2005-06-03 Thread Angelov, Rossen
Jason, thanks for pointing out the order in web.xml matters.

Placing the session-config lines after the mappings resolved the problem
with the XML exception, but another exception started appearing in the log:

Jun 3, 2005 2:17:59 PM org.apache.coyote.tomcat5.CoyoteAdapter service
SEVERE: An exception or error occurred in the container during the request
processing
java.lang.ArrayIndexOutOfBoundsException: 0
at
org.apache.coyote.tomcat5.CoyoteAdapter.normalize(CoyoteAdapter.java:483)
at
org.apache.coyote.tomcat5.CoyoteAdapter.postParseRequest(CoyoteAdapter.java:
239)
at
org.apache.coyote.tomcat5.CoyoteAdapter.service(CoyoteAdapter.java:158)
at
org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:799)
at
org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.processConne
ction(Http11Protocol.java:705)
at
org.apache.tomcat.util.net.TcpWorkerThread.runIt(PoolTcpEndpoint.java:577)
at
org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.jav
a:683)
at java.lang.Thread.run(Thread.java:534)

Do you know what might be causing it and if the exception can be related to
setting the session-config option?

Ross

-Original Message-
From: Jason Bainbridge [mailto:[EMAIL PROTECTED]
Sent: Friday, June 03, 2005 11:12 AM
To: Tomcat Users List
Subject: Re: servlet request time out ?!


On 6/3/05, Angelov, Rossen [EMAIL PROTECTED] wrote:
 I tried adding it to my .../WEB-INF/web.xml
 web-app
 
   session-config
 session-timeout45/session-timeout
   /session-config
 
   ...
 /web-app
 
 but I started getting errors when tomcat is deploying the context:
 
 Jun 3, 2005 11:51:20 AM org.apache.commons.digester.Digester error
 SEVERE: Parse Error at line 28 column 11: The content of element type
 web-app must match

(icon?,display-name?,description?,distributable?,context-param*,filter*,fil

ter-mapping*,listener*,servlet*,servlet-mapping*,session-config?,mime-mappin

g*,welcome-file-list?,error-page*,taglib*,resource-env-ref*,resource-ref*,se

curity-constraint*,login-config?,security-role*,env-entry*,ejb-ref*,ejb-loca
 l-ref*).
 org.xml.sax.SAXParseException: The content of element type web-app must
 match

(icon?,display-name?,description?,distributable?,context-param*,filter*,fil

ter-mapping*,listener*,servlet*,servlet-mapping*,session-config?,mime-mappin

g*,welcome-file-list?,error-page*,taglib*,resource-env-ref*,resource-ref*,se

curity-constraint*,login-config?,security-role*,env-entry*,ejb-ref*,ejb-loca
 l-ref*).

The session-config details need to go after the servlet-mapping's and
before the mime-mapping's in your web.xml, that is what that error is
saying, the DTD expects the elements to be in a certain order and your
order isn't correct.

Regards,
-- 
Jason Bainbridge
http://kde.org - [EMAIL PROTECTED]
Personal Site - http://jasonbainbridge.com

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


This communication is intended solely for the addressee and is
confidential and not for third party unauthorized distribution.



Confusion Land

2005-06-03 Thread Thomas Polliard
So I am running Tomcat 5.5.9
I have a jsp page that imports com.polliard.db.RaidDB;
It also has a line that invokes a new instance of this class
RaidDB rdb = new RaidDB();

The code works on Jetty but when used with Tomcat I am getting the error
RaidDB cannot be resolved or is not a type.  

Any Ideas???

The class is located in the WEB-INF/classes/com/polliard/db/RaidDB directory
under the deployed application.

Any help would be great.
 --
Thomas Polliard
Sr. Systems Administrator, AOL
[EMAIL PROTECTED]


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



Re: Confusion Land

2005-06-03 Thread Scott Dudley


Unless I misunderstood, RaidDB.class should be located in directory 
WEB-INF/classes/com/polliard/db and not 
WEB-INF/classes/com/polliard/db/RaidDB.


Thomas Polliard wrote:


So I am running Tomcat 5.5.9
I have a jsp page that imports com.polliard.db.RaidDB;
It also has a line that invokes a new instance of this class
RaidDB rdb = new RaidDB();

The code works on Jetty but when used with Tomcat I am getting the error
RaidDB cannot be resolved or is not a type.  


Any Ideas???

The class is located in the WEB-INF/classes/com/polliard/db/RaidDB directory
under the deployed application.

Any help would be great.
--
Thomas Polliard
Sr. Systems Administrator, AOL
[EMAIL PROTECTED]


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

 



--

Regards,

Scott Dudley


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



RE: Confusion Land

2005-06-03 Thread Thomas Polliard
It is located there.  Sorry the location is as you wrote. I was unclear.
WEB-INF/classes/com/polliard/db/ Contains RaidDB.class

Thanks 


 --
Thomas Polliard
Sr. Systems Administrator, AOL
[EMAIL PROTECTED]
-Original Message-
From: Scott Dudley [mailto:[EMAIL PROTECTED] 
Sent: Friday, June 03, 2005 2:52 PM
To: Tomcat Users List
Subject: Re: Confusion Land


Unless I misunderstood, RaidDB.class should be located in directory
WEB-INF/classes/com/polliard/db and not
WEB-INF/classes/com/polliard/db/RaidDB.

Thomas Polliard wrote:

So I am running Tomcat 5.5.9
I have a jsp page that imports com.polliard.db.RaidDB; It also has a 
line that invokes a new instance of this class RaidDB rdb = new 
RaidDB();

The code works on Jetty but when used with Tomcat I am getting the 
error RaidDB cannot be resolved or is not a type.

Any Ideas???

The class is located in the WEB-INF/classes/com/polliard/db/RaidDB 
directory under the deployed application.

Any help would be great.
 --
Thomas Polliard
Sr. Systems Administrator, AOL
[EMAIL PROTECTED]


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

  


-- 

Regards,

Scott Dudley


-
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: Confusion Land

2005-06-03 Thread Thomas Polliard
 From the deployed location of Raid

./login.jsp
./menu.jsp
./index.jsp.old
./WEB-INF
./WEB-INF/classes
./WEB-INF/classes/com
./WEB-INF/classes/com/polliard
./WEB-INF/classes/com/polliard/db
./WEB-INF/classes/com/polliard/db/RaidDB.class
./WEB-INF/lib
./WEB-INF/lib/postgresql-jdbc.jar
./index.jsp
./images
./images/space.gif
./raid.css
./header.jsp

 --
Thomas Polliard
Sr. Systems Administrator, AOL
[EMAIL PROTECTED]
-Original Message-
From: Thomas Polliard [mailto:[EMAIL PROTECTED] 
Sent: Friday, June 03, 2005 2:55 PM
To: 'Tomcat Users List'
Subject: RE: Confusion Land

It is located there.  Sorry the location is as you wrote. I was unclear.
WEB-INF/classes/com/polliard/db/ Contains RaidDB.class

Thanks 


 --
Thomas Polliard
Sr. Systems Administrator, AOL
[EMAIL PROTECTED]
-Original Message-
From: Scott Dudley [mailto:[EMAIL PROTECTED]
Sent: Friday, June 03, 2005 2:52 PM
To: Tomcat Users List
Subject: Re: Confusion Land


Unless I misunderstood, RaidDB.class should be located in directory
WEB-INF/classes/com/polliard/db and not
WEB-INF/classes/com/polliard/db/RaidDB.

Thomas Polliard wrote:

So I am running Tomcat 5.5.9
I have a jsp page that imports com.polliard.db.RaidDB; It also has a 
line that invokes a new instance of this class RaidDB rdb = new 
RaidDB();

The code works on Jetty but when used with Tomcat I am getting the 
error RaidDB cannot be resolved or is not a type.

Any Ideas???

The class is located in the WEB-INF/classes/com/polliard/db/RaidDB 
directory under the deployed application.

Any help would be great.
 --
Thomas Polliard
Sr. Systems Administrator, AOL
[EMAIL PROTECTED]


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

  


-- 

Regards,

Scott Dudley


-
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: Confusion Land

2005-06-03 Thread Mark Thomas

Thomas Polliard wrote:

So I am running Tomcat 5.5.9
I have a jsp page that imports com.polliard.db.RaidDB;
It also has a line that invokes a new instance of this class
RaidDB rdb = new RaidDB();

The code works on Jetty but when used with Tomcat I am getting the error
RaidDB cannot be resolved or is not a type.  


Any Ideas???

The class is located in the WEB-INF/classes/com/polliard/db/RaidDB directory
under the deployed application.

Shouldn't it be in the WEB-INF/classes/com/polliard/db directory?

Mark

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



Re: Confusion Land

2005-06-03 Thread Tim Diggins

Have you tried reloading the webapp / restarting tomcat?

If you're new to tomcat, then I suggest you give a few more details of 
where the webapp is, and where the jsp page is, and/or how you deployed 
the web-app, just in case these give a clue.




Thomas Polliard wrote:

It is located there.  Sorry the location is as you wrote. I was unclear.
WEB-INF/classes/com/polliard/db/ Contains RaidDB.class

Thanks 



 --
Thomas Polliard
Sr. Systems Administrator, AOL
[EMAIL PROTECTED]
-Original Message-
From: Scott Dudley [mailto:[EMAIL PROTECTED] 
Sent: Friday, June 03, 2005 2:52 PM

To: Tomcat Users List
Subject: Re: Confusion Land


Unless I misunderstood, RaidDB.class should be located in directory
WEB-INF/classes/com/polliard/db and not
WEB-INF/classes/com/polliard/db/RaidDB.

Thomas Polliard wrote:



So I am running Tomcat 5.5.9
I have a jsp page that imports com.polliard.db.RaidDB; It also has a 
line that invokes a new instance of this class RaidDB rdb = new 
RaidDB();


The code works on Jetty but when used with Tomcat I am getting the 
error RaidDB cannot be resolved or is not a type.


Any Ideas???

The class is located in the WEB-INF/classes/com/polliard/db/RaidDB 
directory under the deployed application.


Any help would be great.
--
Thomas Polliard
Sr. Systems Administrator, AOL
[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: security constraints in tomcat 4.1.30

2005-06-03 Thread Mark Thomas

Angela Stempfel wrote:

Hello all

I have a problem concerning Tomcat 4.1.30. In web.xml i defined several 
security constraint. First of all I protected the whole application and 
then I excluded the directories with images and css files. Furthermore I 
defined some roles.


snip

So my problem is that this works fine with Tomcat 5.0 but not with 
Tomcat 4.1.30. If I go to the login page, the stylesheet and images are 
not found when running the Application with version 4.1.30. Also the 
Security Constraints are not working correctly, this means that a user 
that hasn't the role dslamConfig is able to enter the following URL: 
/DslamConfig/*


Has anyone some ideas?


You need to read section SRV.12.8 of both the servlet 2.3 spec and the 
servlet 2.4 spec. The way constraints are handled has changed. For example,

spec-quote version=2.3
If the authorization constraint defines no roles, no user is allowed 
access to the portion of the web application defined by the security

constraint.
/spec-quote

compared to

spec-quote version=2.4
If no authorization constraint applies to a request, the container must 
accept the request without requiring user authentication.

/spec-quote

There is a fair amount of ambiguity in this area of the 2.3 spec, which 
is why it changed so much in 2.4


You should also be aware of 
http://issues.apache.org/bugzilla/show_bug.cgi?id=15570


Mark

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



Problem posting a large request that requires authentication and is forwarded through the NSAPI redirector

2005-06-03 Thread Kevin Convy \(Contractor\)
For the following configuration:
 
Sun ONE / iPlanet 6.0sp5 
NSAPI redirector from jakarta-tomcat-connectors-1.2.8
Tomcat 5.5 (embedded in JBoss 4.0.2)
 
All of the requests that get forwarded over the redirector require
authentication. The configuration works fine if the request body is less
than ~150k or if I include the http authorization header in the initial
request. However, if  I attempt to post a request over 150k and don't
include the authorization header (which forces the authentication
challenge) I get an Error writing to server on the client.
 
If I look at the nsapi redirector log I see that Tomcat does not read
the entire request before issuing the challenge, though I don't know if
it should:
 
[Fri Jun 03 10:21:24 2005] [715:0] [debug] service::jk_lb_worker.c
(482): service worker=worker3 jvm_route=worker3 rc=1
[Fri Jun 03 10:21:24 2005] [715:0] [debug]
ajp_marshal_into_msgb::jk_ajp_common.c (551): ajp marshaling done
[Fri Jun 03 10:21:24 2005] [715:0] [debug] ajp_service::jk_ajp_common.c
(1594): processing with 3 retries
[Fri Jun 03 10:21:24 2005] [715:0] [debug]
ajp_connection_tcp_send_message::jk_ajp_common.c (883): sending to ajp13
pos=4 len=254 max=8192 
[Fri Jun 03 10:21:24 2005] [715:0] [debug]
ajp_send_request::jk_ajp_common.c (1199): request body to send 180594 -
request body to resend 0
[Fri Jun 03 10:21:24 2005] [715:0] [debug]
ajp_connection_tcp_send_message::jk_ajp_common.c (883): sending to ajp13
pos=4 len=8192 max=8192 
[Fri Jun 03 10:21:24 2005] [715:0] [debug]
ajp_connection_tcp_get_message::jk_ajp_common.c (1007): received from
ajp13 pos=0 len=126 max=8192 
[Fri Jun 03 10:21:24 2005] [715:0] [debug]
ajp_unmarshal_response::jk_ajp_common.c (606): status = 401
[Fri Jun 03 10:21:24 2005] [715:0] [debug]
ajp_unmarshal_response::jk_ajp_common.c (613): Number of headers is = 3
[Fri Jun 03 10:21:24 2005] [715:0] [debug]
ajp_unmarshal_response::jk_ajp_common.c (669): Header[0]
[WWW-Authenticate] = [Basic realm=Salton]
[Fri Jun 03 10:21:24 2005] [715:0] [debug]
ajp_unmarshal_response::jk_ajp_common.c (669): Header[1] [Content-Type]
= [text/html;charset=utf-8]
[Fri Jun 03 10:21:24 2005] [715:0] [debug]
ajp_unmarshal_response::jk_ajp_common.c (669): Header[2]
[Content-Length] = [952]
[Fri Jun 03 10:21:24 2005] [715:0] [debug]
ajp_connection_tcp_get_message::jk_ajp_common.c (1007): received from
ajp13 pos=0 len=956 max=8192 
[Fri Jun 03 10:21:24 2005] [715:0] [debug]
ajp_connection_tcp_get_message::jk_ajp_common.c (1007): received from
ajp13 pos=0 len=2 max=8192 
[Fri Jun 03 10:21:24 2005] [715:0] [debug] ajp_done::jk_ajp_common.c
(1942): recycling connection cache slot=0

If I post the request directly to Tomcat (not over AJP through the
redirector) then it also works fine.
 
Has anyone run into this issue?
 
Any information would be appreciated.
 
Thanks,
  
Kevin Convy
Icebox LLC


help for ClassNotFoundException

2005-06-03 Thread MEHMOOD, QAISER
Hi ,

 

 

 

   Under tomcat I am integrating the uPortal and running one portlet
application in a web context.

 

   I put my own classes under the WEB-INF/classes directory and also put
jar files in 

 

   WEB-INF/lib directory , but I am getting the error :

 

   ClassNotFoundException ,

 

   When I put these jar files in tomcat/common/lib directory , its
working fine. Can anyone tell me

 

   That how and where I can specify for a web application under one
context that where are the jar

 

And class files.

 

Qaiser Mehmood



JSP too big to compile?

2005-06-03 Thread David Wall
We have a web page that contains many business documents laid out one 
after the other so a user can just click print and have all of them 
print together (with a stylesheet that starts each contract on its own 
printed page). 

But we seem to be having an error that the generated servlet code is too 
big because of service method's try block is too long.


Is there anything I can tweak to allow this to be bigger for the java 
compiler, or is this just a limit of Java in general?


Thanks,
David


Generated servlet error:
   [javac] Compiling 1 source file
   [javac] 
/home/tomcat/jakarta-tomcat-4.1.30/work/Standalone/localhost/app/application_jsp.java:8946: 
compiler message file broken: 
key=compiler.err.compiler.err.limit.code.too.large.for.try.stmt 
arguments=null, null, null, null, null, null, null

   [javac] } catch (Throwable t) {
   [javac]   ^
   [javac] 
/home/tomcat/jakarta-tomcat-4.1.30/work/Standalone/localhost/app/application_jsp.java:1118: 
compiler message file broken: 
key=compiler.err.compiler.err.limit.code.too.large.for.try.stmt 
arguments=null, null, null, null, null, null, null

   [javac] try {
   [javac] ^


RE: JSP too big to compile?

2005-06-03 Thread Pascal Gehl
It's a global java limitation.
You'are limited to around 10 000 lines of code in a try catch block.

Try to use dynamic includes instead of static includes. 


Pascal Gehl

-Original Message-
From: David Wall [mailto:[EMAIL PROTECTED] 
Sent: Friday, June 03, 2005 16:31
To: tomcat-user@jakarta.apache.org
Subject: JSP too big to compile?

We have a web page that contains many business documents laid out one after
the other so a user can just click print and have all of them print together
(with a stylesheet that starts each contract on its own printed page). 

But we seem to be having an error that the generated servlet code is too big
because of service method's try block is too long.

Is there anything I can tweak to allow this to be bigger for the java
compiler, or is this just a limit of Java in general?

Thanks,
David


Generated servlet error:
[javac] Compiling 1 source file
[javac]
/home/tomcat/jakarta-tomcat-4.1.30/work/Standalone/localhost/app/application
_jsp.java:8946: 
compiler message file broken: 
key=compiler.err.compiler.err.limit.code.too.large.for.try.stmt
arguments=null, null, null, null, null, null, null
[javac] } catch (Throwable t) {
[javac]   ^
[javac]
/home/tomcat/jakarta-tomcat-4.1.30/work/Standalone/localhost/app/application
_jsp.java:1118: 
compiler message file broken: 
key=compiler.err.compiler.err.limit.code.too.large.for.try.stmt
arguments=null, null, null, null, null, null, null
[javac] try {
[javac] ^

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



Re: JSP too big to compile?

2005-06-03 Thread Joe Plautz
You are actually limited by Java. I can't recall the actual size off 
hand, but a method can only be so big.


From what I remember, it has something to do with server side includes 
vs jsp includes. We ended up doing some pretty nasty stuff by 
conditionally doing a server side include. I can't really remember much 
more than that it was several years ago.


David Wall wrote:
We have a web page that contains many business documents laid out one 
after the other so a user can just click print and have all of them 
print together (with a stylesheet that starts each contract on its own 
printed page).
But we seem to be having an error that the generated servlet code is too 
big because of service method's try block is too long.


Is there anything I can tweak to allow this to be bigger for the java 
compiler, or is this just a limit of Java in general?


Thanks,
David


Generated servlet error:
   [javac] Compiling 1 source file
   [javac] 
/home/tomcat/jakarta-tomcat-4.1.30/work/Standalone/localhost/app/application_jsp.java:8946: 
compiler message file broken: 
key=compiler.err.compiler.err.limit.code.too.large.for.try.stmt 
arguments=null, null, null, null, null, null, null

   [javac] } catch (Throwable t) {
   [javac]   ^
   [javac] 
/home/tomcat/jakarta-tomcat-4.1.30/work/Standalone/localhost/app/application_jsp.java:1118: 
compiler message file broken: 
key=compiler.err.compiler.err.limit.code.too.large.for.try.stmt 
arguments=null, null, null, null, null, null, null

   [javac] try {
   [javac] ^



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



Re: JSP too big to compile?

2005-06-03 Thread David Wall
The jsp:include is coming very close for us, but we're doing some tricks 
on these JSP pages that are causing us a problem with this approach. 

In the main JSP, we are creating a class inside that has the data 
elements for that page as well as a bunch of custom routines that act on 
the bean data.  In this case, we use a construct like:


%!
public class BeanData
{
   public String field1;
   public String field2;
   public void method1()
   {  }
}

void doSomething(BeanData bean)
{}
%

This has worked well.  Normally, we'd create a regular bean and use 
jsp:useBean to access it, but we did this so we could just upload the 
JSP and the bean would go together for ease of update without 
restarting, etc.  These JSP pages are bit special in that they are 
customer-defined pages that need to be changeable without having to 
upload a new JAR/WAR/.class file and have the application reload. 

Of course, a jsp:include page cannot access the BeanData defined in the 
other page because the BeanData class is nested inside the servlet class 
created from the JSP (even if we pass it as a parameter, the receiving 
end will get a security access exception).


First, is there a better way for a JSP to define a class that could be 
accessed outside of it rather than using the %! % mechanism to declare 
the code?  If not, are there any thoughts on how to pass such a private 
bean instance to the jsp:include page so it can also use it?


Thanks,
David



Pascal Gehl wrote:


It's a global java limitation.
You'are limited to around 10 000 lines of code in a try catch block.

Try to use dynamic includes instead of static includes. 



Pascal Gehl

-Original Message-
From: David Wall [mailto:[EMAIL PROTECTED] 
Sent: Friday, June 03, 2005 16:31

To: tomcat-user@jakarta.apache.org
Subject: JSP too big to compile?

We have a web page that contains many business documents laid out one after
the other so a user can just click print and have all of them print together
(with a stylesheet that starts each contract on its own printed page). 


But we seem to be having an error that the generated servlet code is too big
because of service method's try block is too long.

Is there anything I can tweak to allow this to be bigger for the java
compiler, or is this just a limit of Java in general?

Thanks,
David


Generated servlet error:
   [javac] Compiling 1 source file
   [javac]
/home/tomcat/jakarta-tomcat-4.1.30/work/Standalone/localhost/app/application
_jsp.java:8946: 
compiler message file broken: 
key=compiler.err.compiler.err.limit.code.too.large.for.try.stmt

arguments=null, null, null, null, null, null, null
   [javac] } catch (Throwable t) {
   [javac]   ^
   [javac]
/home/tomcat/jakarta-tomcat-4.1.30/work/Standalone/localhost/app/application
_jsp.java:1118: 
compiler message file broken: 
key=compiler.err.compiler.err.limit.code.too.large.for.try.stmt

arguments=null, null, null, null, null, null, null
   [javac] try {
   [javac] ^

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

 



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



Re: tomcat 5.5.9 does not read context.xml

2005-06-03 Thread teknokrat

Steve Kirk wrote:

yes context.xml is fine in META-INF.  in fact it is preferred over having it
in server.xml.  your alternative is to put it in
conf/enginename/hostname/yourwebappname.xml (which is in fact what TC will
do for you when it unpacks the war).

I don't know that you can have the context path name different to the war
file.  I'm not 100% sure, but can't see how to do it.  in fact I can see it
being a source of potential confusion.  can you explain why you want to do
that?


OK, I am totally confused. Is or is it not best practice to provide a 
context.xml in META-INF. I thought this was required for hot 
deployment 
to work. If I want my context path to have a different name to my war 
file, how do I achieve this?


thank you



Well, I have to deal with some legacy apps. I wanted to have a more 
consistent naming scheme but I obviously have to keep the context path 
the same as before. Its no big thing, I was just suprised that context 
paths wern't decoupled from the name of the war.


On another note, i find that deployment and undeployment on tomcat 5.5.9 
  is very problematic. After half a dozen redeployments or so I find 
that tomcat does not fully unpack the war and leaves the directory 
incomplete. After that, you can't redeploy or undeploy the app, at least 
the directory doesn't get deleted.



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



RE: Multiple source directories for one webapp

2005-06-03 Thread Laurent Brucher
 It all depends on what OS and what editor you use. Under Unix using 
 symbolic links could be a solution.
 
 I am not familiar with rsync, but you could use a tool like 
 that to keep 
 two folders in sync. It should be possible to setup a process that is 
 watching your working folder and every time a file changes to copy it 
 over to the deployed web app folder.

I'm running Windows, so no synlinks.
I'm using Eclipse, which is capable of copying files to a given folder, but
cannot do that across Eclipse projects, and that's what I need to do.
Finally, I'm using tomcat 5.5.

I'm not familiar with IDEA, but I'd rather avoid having to actually do
something
such as pressing a key. I guess I'm looking for a solution that ideally
requires as little
external tool as possible...


Thanks for the info anyway,
Laurent.


 
 I had a similar problem a while back (Windows/IDEA) and I 
 ended up using 
 a plugin that will copy the JSP file to the right location 
 when hitting 
   a special key. I found this plugin to be very effective.
 
  
  Thanks,
  Laurent.
 
 Marius
 
 
 -
 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: JSP too big to compile?

2005-06-03 Thread Maarten Janssen
you can us includes and then delete the compiled file in the work directory.
So split page up by using %@ include file=checklogin.jsp %
for each block of general code coded in a include jsp. After upload delete
the file in the work directory, so compilation is done at runtime of tomcat.
And its working..for me it do.

Maarten

-Oorspronkelijk bericht-
Van: David Wall [mailto:[EMAIL PROTECTED]
Verzonden: zaterdag 4 juni 2005 0:18
Aan: Tomcat Users List
Onderwerp: Re: JSP too big to compile?


The jsp:include is coming very close for us, but we're doing some tricks
on these JSP pages that are causing us a problem with this approach.

In the main JSP, we are creating a class inside that has the data
elements for that page as well as a bunch of custom routines that act on
the bean data.  In this case, we use a construct like:

%!
public class BeanData
{
public String field1;
public String field2;
public void method1()
{  }
}

void doSomething(BeanData bean)
{}
%

This has worked well.  Normally, we'd create a regular bean and use
jsp:useBean to access it, but we did this so we could just upload the
JSP and the bean would go together for ease of update without
restarting, etc.  These JSP pages are bit special in that they are
customer-defined pages that need to be changeable without having to
upload a new JAR/WAR/.class file and have the application reload.

Of course, a jsp:include page cannot access the BeanData defined in the
other page because the BeanData class is nested inside the servlet class
created from the JSP (even if we pass it as a parameter, the receiving
end will get a security access exception).

First, is there a better way for a JSP to define a class that could be
accessed outside of it rather than using the %! % mechanism to declare
the code?  If not, are there any thoughts on how to pass such a private
bean instance to the jsp:include page so it can also use it?

Thanks,
David



Pascal Gehl wrote:

It's a global java limitation.
You'are limited to around 10 000 lines of code in a try catch block.

Try to use dynamic includes instead of static includes.


Pascal Gehl

-Original Message-
From: David Wall [mailto:[EMAIL PROTECTED]
Sent: Friday, June 03, 2005 16:31
To: tomcat-user@jakarta.apache.org
Subject: JSP too big to compile?

We have a web page that contains many business documents laid out one after
the other so a user can just click print and have all of them print
together
(with a stylesheet that starts each contract on its own printed page).

But we seem to be having an error that the generated servlet code is too
big
because of service method's try block is too long.

Is there anything I can tweak to allow this to be bigger for the java
compiler, or is this just a limit of Java in general?

Thanks,
David


Generated servlet error:
[javac] Compiling 1 source file
[javac]
/home/tomcat/jakarta-tomcat-4.1.30/work/Standalone/localhost/app/applicatio
n
_jsp.java:8946:
compiler message file broken:
key=compiler.err.compiler.err.limit.code.too.large.for.try.stmt
arguments=null, null, null, null, null, null, null
[javac] } catch (Throwable t) {
[javac]   ^
[javac]
/home/tomcat/jakarta-tomcat-4.1.30/work/Standalone/localhost/app/applicatio
n
_jsp.java:1118:
compiler message file broken:
key=compiler.err.compiler.err.limit.code.too.large.for.try.stmt
arguments=null, null, null, null, null, null, null
[javac] try {
[javac] ^

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

--
No virus found in this incoming message.
Checked by AVG Anti-Virus.
Version: 7.0.322 / Virus Database: 267.5.1 - Release Date: 2-6-2005

--
No virus found in this outgoing message.
Checked by AVG Anti-Virus.
Version: 7.0.322 / Virus Database: 267.5.1 - Release Date: 2-6-2005


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



What is wrong with my TC cofiguration?

2005-06-03 Thread Vernon
I keep getting the following repeating error message
in my log file:

2005-06-03 09:54:54,500 DEBUG
[org.apache.catalina.session.ManagerBase] - Start
expire sessions StandardManager at 1117817694500
sessioncount 4
2005-06-03 09:54:54,500 DEBUG
[org.apache.catalina.session.ManagerBase] - End expire
sessions StandardManager processingTime 0 expired
sessions: 0

This pair of message repeats every minute. I don't do
anything special. MY application is totally
misbehaving. What is wrong here?

TC version is 5.5.9. JVM 1.5.03.

Thannks very much for your inputs.



__ 
Discover Yahoo! 
Have fun online with music videos, cool games, IM and more. Check it out! 
http://discover.yahoo.com/online.html

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



(Windows) Tomcat process is using 100% CPU when running a SQL command

2005-06-03 Thread Robson dos Santos Franca

Hello

We're using Tomcat 5.5.9 + Sun Java 1.5.0_03 + Oracle 9i in our Intranet 
application.


Everything looks fine... unless we run a SELECT statement into Tomcat.
Without the 'ORDER BY' clause, no problem.
With 'ORDER BY', Tomcat runs at 100%.
JDBC library file: ojdbc14.jar

JDBC URL : jdbc:oracle:oci8:@ ...

Any ideas?

Thanks in advance

Robson Franca


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



RE: (Windows) Tomcat process is using 100% CPU when running a SQL command

2005-06-03 Thread Sir John Nueva
Hi Rodson,
Check your JDBC Driver documentation may be it has a bug
when use in Sun Java 1.5.0_03. Check for the latest version.
This look like a problem in the translation of SQL statement.

Cheers,
John

-Original Message-
From: Robson dos Santos Franca [mailto:[EMAIL PROTECTED]
Sent: Saturday, June 04, 2005 9:00 AM
To: tomcat-user@jakarta.apache.org
Subject: (Windows) Tomcat process is using 100% CPU when running a SQL
command


Hello

We're using Tomcat 5.5.9 + Sun Java 1.5.0_03 + Oracle 9i in our Intranet 
application.

Everything looks fine... unless we run a SELECT statement into Tomcat.
Without the 'ORDER BY' clause, no problem.
With 'ORDER BY', Tomcat runs at 100%.
JDBC library file: ojdbc14.jar

JDBC URL : jdbc:oracle:oci8:@ ...

Any ideas?

Thanks in advance

Robson Franca


-
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: (Windows) Tomcat process is using 100% CPU when running a SQL command

2005-06-03 Thread Robson dos Santos Franca

Hi Sir John,

We updated JDBC drivers (at Oracle Website) and it just have worked! 
Thanks a lot!


Robson

Sir John Nueva wrote:


Hi Rodson,
Check your JDBC Driver documentation may be it has a bug
when use in Sun Java 1.5.0_03. Check for the latest version.
This look like a problem in the translation of SQL statement.

Cheers,
John

-Original Message-
From: Robson dos Santos Franca [mailto:[EMAIL PROTECTED]
Sent: Saturday, June 04, 2005 9:00 AM
To: tomcat-user@jakarta.apache.org
Subject: (Windows) Tomcat process is using 100% CPU when running a SQL
command


Hello

We're using Tomcat 5.5.9 + Sun Java 1.5.0_03 + Oracle 9i in our Intranet 
application.


Everything looks fine... unless we run a SELECT statement into Tomcat.
Without the 'ORDER BY' clause, no problem.
With 'ORDER BY', Tomcat runs at 100%.
JDBC library file: ojdbc14.jar

JDBC URL : jdbc:oracle:oci8:@ ...

Any ideas?

Thanks in advance

Robson Franca


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



Tomcat/mod_jk rpm for FC3

2005-06-03 Thread mbneto
Hi,

I am looking for rpms for tomcat/mod_jk that work with FC3.   Any tips ?

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



Re: security constraints in tomcat 4.1.30

2005-06-03 Thread Bill Barker
Along with what Mark said, you should know that TC 4.1.30 stops checking 
after the *first* matching constraint (so in your case, the '/*' always 
wins).  Try reversing the order of your constraints in web.xml.

As Mark mentioned, this has changed in TC 5.x, and your web.xml should work 
as written.

Angela Stempfel [EMAIL PROTECTED] wrote in message 
news:[EMAIL PROTECTED]
 Hello all

 I have a problem concerning Tomcat 4.1.30. In web.xml i defined several 
 security constraint. First of all I protected the whole application and 
 then I excluded the directories with images and css files. Furthermore I 
 defined some roles.

 pre
 security-constraint
 display-nameTCE GUI/display-name
 web-resource-collection
 web-resource-nameWEBGui Area/web-resource-name
 !-- Define the context-relative URL(s) to be protected --
 url-pattern/*/url-pattern
 /web-resource-collection
 auth-constraint
 !-- Anyone with one of the listed roles may access this area --
 role-name*/role-name
 /auth-constraint
 /security-constraint

 security-constraint
 web-resource-collection
 web-resource-nameImages and CSS Not Protected/web-resource-name
 url-pattern/images/*/url-pattern
 url-pattern/css/*/url-pattern
 http-methodGET/http-method
 http-methodHEAD/http-method
 /web-resource-collection
 /security-constraint

 security-constraint
 display-nameDSLAM Configuration/display-name
 web-resource-collection
 web-resource-name
 Access to DSLAM Configuration
 /web-resource-name
 url-pattern/DslamConfig/*/url-pattern
 /web-resource-collection
 auth-constraint
 role-namedslamConfig/role-name
 /auth-constraint
 /security-constraint
 login-config
 auth-methodFORM/auth-method
 form-login-config
 form-login-page/login.jsp/form-login-page
 form-error-page/login-error.jsp/form-error-page
 /form-login-config
 /login-config

 security-role
 role-namedslamConfig/role-name
 /security-role
 /pre

 So my problem is that this works fine with Tomcat 5.0 but not with Tomcat 
 4.1.30. If I go to the login page, the stylesheet and images are not found 
 when running the Application with version 4.1.30. Also the Security 
 Constraints are not working correctly, this means that a user that hasn't 
 the role dslamConfig is able to enter the following URL: /DslamConfig/*

 Has anyone some ideas?

 Thanks a lot
 Angela 




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



RE: Tomcat/mod_jk rpm for FC3

2005-06-03 Thread faisal
believe me man u'd much rather build it for fc3 instead of looking for rpm.
i looked for rpm myself for a day or two without much luck and then built
it. it only took one and half hour for me to figure out how to build it.

-Original Message-
From: mbneto [mailto:[EMAIL PROTECTED]
Sent: Saturday, June 04, 2005 7:07 AM
To: Tomcat Users List
Subject: Tomcat/mod_jk rpm for FC3


Hi,

I am looking for rpms for tomcat/mod_jk that work with FC3.   Any tips ?

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