Re: DataSourceRealm says Name jdbc is not bound in this Context

2005-02-07 Thread Dan Washusen
Dominik, that worked!  Champion!!!

My revised context.xml looks like this:
Context path=/mind
docBase=D:/Development/Projects/mind/src/webapp debug=99
reloadable=true
Resource name=jdbc/MindDB auth=Container 
type=javax.sql.DataSource
maxActive=100 maxIdle=30 maxWait=1
username=mind password=*** 
driverClassName=org.postgresql.Driver
url=jdbc:postgresql://localhost/mind/

Realm className=org.apache.catalina.realm.DataSourceRealm debug=99
dataSourceName=jdbc/MindDB localDataSource=true
userTable=mind_user userNameCol=alias userCredCol=password
userRoleTable=mind_user_role roleNameCol=name/
/Context


On Mon, 07 Feb 2005 08:57:08 +0100, Dominik Drzewiecki [EMAIL PROTECTED] 
wrote:
 Dan Washusen [EMAIL PROTECTED] wrote:
  Hi Sven,
  I can access the data source from within my code using the name
  java:/comp/env/jdbc/MindDB and everything works great.  It's just
  that the Realm can't... I have found a few other posts to this list
  with the same problem and one of the email suggested that the Realm is
  configured before the DataSource causing an error to be thrown during
  realm initialisation (as the DataSource is missing).
 
  It looks like the solution is to move the DataSource configuration
  to the Global configuration area or to use the JBDCRealm.
 
 It is not necessary to make the datasource global. Try adding
 localDataSource=true to your context Realm definition.
 Having consulted the docs for 4.1.x, 5.0.x and 5.5.x, t seems that this
 flag is only allowed in the latest version of tomcat. There's a chance
 though that it has been backported without having the docs updated.
 
 HTH,
 /dd
 
 


-- 
Jar-Jar makes the Ewoks look like f*%#ing Shaft! -  Tim Bisley

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



Re: [SOLVED] Form Auth + xml users database

2005-02-07 Thread Omar Adobati
Thx for ur answers, I have reied what you say about the second
question, but it's do not work. This is how I have changed my
context.xml file:
===
?xml version='1.0' encoding='utf-8'?
Context privileged=true swallowOutput=true
workDir=work\Catalina\photoalbum\ path=/ cacheTTL=0
cachingAllowed=false displayName=bannerEmbedded beta docBase=.
cacheMaxSize=0 reloadable=true
  Realm className=org.apache.catalina.realm.UserDatabaseRealm
resourceName=PhotoAlbum/
  Valve className=org.apache.catalina.valves.AccessLogValve
directory=logs/photoalbum/ fileDateFormat=-MM-dd suffix=.txt
prefix=photoalbum_access_log./
  !--ResourceLink name=PhotoAlbum global=PhotoAlbum
type=org.apache.catalina.UserDatabase/--
  Resource type=org.apache.catalina.UserDatabase description=User
database that can be updated and saved auth=Container
name=PhotoAlbum/
ResourceParams name=PhotoAlbum
parameter
  namefactory/name
  valueorg.apache.catalina.users.MemoryUserDatabaseFactory/value
/parameter
parameter
  namepathname/name
  valueconf/Catalina/photoalbum.localhost/photoalbum-users.xml/value
/parameter
  /ResourceParams  
/Context
===

I have removed the ResourceParams from the server.xml file and move it
into the context.xml but in the log I can read this errors messages:
1) javax.naming.NameNotFoundException: Name PhotoAlbum is not bound in
this Context
2) GRAVE: Catalina.start: 
LifecycleException:  No UserDatabase component found under key PhotoAlbum
3) 2005-02-07 09:55:30 UserDatabaseRealm[photoalbum.localhost]:
Exception looking up UserDatabase under key PhotoAlbum
javax.naming.NameNotFoundException: Name PhotoAlbum is not bound in this Context

do u know why? I have I have give you all the elements you need to help me.


On Sun, 06 Feb 2005 22:21:21 +0100, Mario Winterer
[EMAIL PROTECTED] wrote:
 Hi!
 
 I'm happy you could solve your problem now! Seems the reason was the
 missing Realm-definition in your context.xml.
 
 To Question 1)
 Tomcat offers a separate JNDI-namespace for each web application (so if
 you have 4 web applications you will have 4 namespaces). These
 namespaces are configured in the context-elements of the corresponsing
 web-applications. To define resources, you have to nest a
 Resource-element in your context-element (which should be in
 context.xml).
 A resource that is defined in the namespace of a web application cannot
 be seen by other web applications (because the namespaces are separated
 from each other).
 Sometimes, a resource may be required by more than one web application.
 To avoid configuring this resource several times - once per context -
 tomcat offers another namespace that is global and exists only once per
 tomcat instance. If you define a resource there, you can use it in each
 web application, that is allowed to use it.
 So how can you allow a web application to use a global resource? Simply
 link the global resource into the local JNDI-namespace of the
 web-application! This can be done by nesting a ResourceLink element in
 the context element of the web-application that should be allowed to
 use the resource. When defining a ResourceLink-element, you must
 specify, which global resource you want to link into the namespace
 (attribut global), which type the resource is that you want to link
 (attribut type), and which name it should have in the local namespace
 (attribut name) - this name can be equal to the global name.
 
 So the server.xml and context.xml hierarchy could look like the
 following (sorry for the text-art - use a fixed width font for best
 results):
 
 +- Server
   |
   +- GlobalNamingResources
   |  +- Resource GlobResA
   |  +- Resource GlobResB
   |
   +- Service
  +- Engine
 +- Realm X
 +- Host www.A.org
 |  +- Context /A1 (defined in context.xml)
 |  |  +- ResourceLink to GlobResA, name: LocResA
 |  |
 |  +- Context /A2 (defined in context.xml)
 |  |  +- ResourceLink to GlobResA, name: LocResA
 |  |  +- ResourceLink to GlobResB, name: LocResB
 |  |
 |  +- Context /A3 (defined in context.xml)
 | +- Resource, name LocalResA
 |
 +- Host www.B.org
+- Context /B1
|  +- ResourceLink to GlobResA, name: LocResA
|
+- Context /B2
   +- ResourceLink to GlobResB, name: LocResB
 
 Question 2) If you do not want to change server.xml (e.g. because you
 want to deploy your application to a foreign server and you cannot
 modify server.xml there), you could define a local JNDI-Resource in the
 context-element of your web-application instead of the
 GlobalNamingResource (simply move the resource-definition from
 GlobalNamingResource into your context-element). If you do this, of
 course you do not need the ResourceLink any more!
 So you do not have to touch server.xml because all configurations can be
 done inside context.xml which is in the meta-inf directory of your web
 

outOfMemory exception under high load

2005-02-07 Thread Michael Cornell
Hi,

Hi,

I am experiencing a problem many others seem to have had before, but
have found no answers.  I am running Tomcat 5.0.25 using jdk 1.4.2_06
hotspot vm on RedHat Linux ES with 4G Ram and twin Intel procs.

When load-testing, under high stress I receive the error below and the
thread dies.

04-Feb-2005 13:39:24 org.apache.coyote.tomcat5.CoyoteAdapter service
SEVERE: An exception or error occurred in the container during the
request processing
java.lang.OutOfMemoryError
at java.util.zip.ZipFile.open(Native Method)
at java.util.zip.ZipFile.init(ZipFile.java:112)
at java.util.jar.JarFile.init(JarFile.java:127)
..

I have adjusted the vm parameters to the below ( the perm space does not
get full and the Xint to not use the optimised settings..
-server -Xms1G -Xmx1G -Xmn384m -XX:SurvivorRatio=7 -XX:PermSize=64m
-XX:MaxPermSize=128m -Xint

In addition I have added the  reloading=false and development=false in
conf/web.xml.  as per instruction from this thread:
http://www.junlu.com/msg/78566.html

My connector is configured thus:
   Connector
   port=80
   maxThreads=1000
   minSpareThreads=1000
   maxSpareThreads=1000
   enableLookups=false
   redirectPort=8443
   acceptCount=3000
   debug=0
   connectionTimeout=2
   disableUploadTimeout=true /


However all of this is to no avail, and under high stress (80+
concurrent requests, tomcat dies and terminates the thread dumping a
hs_pid12345.log with  the above message

Is this a known hotspot 1.4.x problem (some threads have hinted at
this), or does someone have a solution for this??

Thanks,

M

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



JNDI without edit server.xml

2005-02-07 Thread Davide Gurgone
Hi all,
I've got a problem.
I'm using tomcat 5.0 with Oracle 9.2i. Now I want to upgrade tomcat to 
the newest version, but the same configuration doesn't work again.

I used this solution for tomcat 5.0, because I don't whant to write 
anithing on tomcat server.xml file.

To configure and use it I created ONLY this xml and put it on 
$TOMCAT_HOME/conf/catalina/localhost/strutsProva.xml file.

Context displayName=Everithing managing system
docBase=D:\dev\strutsProva path=/strutsProva reloadable=true
  Resource name=jdbc/strutsProva auth=Container
  type=javax.sql.DataSource /
ResourceParams name=jdbc/strutsProva
  parameter
namedriverClassName/name
valueoracle.jdbc.OracleDriver/value
  /parameter
  parameter
nameurl/name
valuejdbc:oracle:thin:@localhost:1521:sweet/value
  /parameter
  parameter
nameusername/name
valuedasit/value
  /parameter
  parameter
namepassword/name
valuedasilab/value
  /parameter
  parameter
namemaxActive/name
value1/value
  /parameter
  parameter
namemaxWait/name
value5000/value
  /parameter
  parameter
namemaxIdle/name
value2/value
  /parameter
/ResourceParams
/Context
Anybody knows how to configure a jndi service on tomcat, without write 
anithing on server.xml file? I have to leave it clean 'cause I don't 
know who will install my application.

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


Re: outOfMemory exception under high load

2005-02-07 Thread reynir
how much memory is your process using when it crashes ?
-r
Michael Cornell wrote:
Hi,
Hi,
I am experiencing a problem many others seem to have had before, but
have found no answers.  I am running Tomcat 5.0.25 using jdk 1.4.2_06
hotspot vm on RedHat Linux ES with 4G Ram and twin Intel procs.
When load-testing, under high stress I receive the error below and the
thread dies.
04-Feb-2005 13:39:24 org.apache.coyote.tomcat5.CoyoteAdapter service
SEVERE: An exception or error occurred in the container during the
request processing
java.lang.OutOfMemoryError
   at java.util.zip.ZipFile.open(Native Method)
   at java.util.zip.ZipFile.init(ZipFile.java:112)
   at java.util.jar.JarFile.init(JarFile.java:127)
..
I have adjusted the vm parameters to the below ( the perm space does not
get full and the Xint to not use the optimised settings..
-server -Xms1G -Xmx1G -Xmn384m -XX:SurvivorRatio=7 -XX:PermSize=64m
-XX:MaxPermSize=128m -Xint
In addition I have added the  reloading=false and development=false in
conf/web.xml.  as per instruction from this thread:
http://www.junlu.com/msg/78566.html
My connector is configured thus:
  Connector
  port=80
  maxThreads=1000
  minSpareThreads=1000
  maxSpareThreads=1000
  enableLookups=false
  redirectPort=8443
  acceptCount=3000
  debug=0
  connectionTimeout=2
  disableUploadTimeout=true /
However all of this is to no avail, and under high stress (80+
concurrent requests, tomcat dies and terminates the thread dumping a
hs_pid12345.log with  the above message
Is this a known hotspot 1.4.x problem (some threads have hinted at
this), or does someone have a solution for this??
Thanks,
M
-
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: outOfMemory exception under high load

2005-02-07 Thread Michael Cornell
Not exactly sure but by running vmstat, it look like I am nearing the 2G
limit .. maybe about 1.8G consumed..

/m

reynir wrote:

 how much memory is your process using when it crashes ?
 -r


 Michael Cornell wrote:

 Hi,

 Hi,

 I am experiencing a problem many others seem to have had before, but
 have found no answers.  I am running Tomcat 5.0.25 using jdk 1.4.2_06
 hotspot vm on RedHat Linux ES with 4G Ram and twin Intel procs.

 When load-testing, under high stress I receive the error below and the
 thread dies.

 04-Feb-2005 13:39:24 org.apache.coyote.tomcat5.CoyoteAdapter service
 SEVERE: An exception or error occurred in the container during the
 request processing
 java.lang.OutOfMemoryError
at java.util.zip.ZipFile.open(Native Method)
at java.util.zip.ZipFile.init(ZipFile.java:112)
at java.util.jar.JarFile.init(JarFile.java:127)
 ..

 I have adjusted the vm parameters to the below ( the perm space does not
 get full and the Xint to not use the optimised settings..
 -server -Xms1G -Xmx1G -Xmn384m -XX:SurvivorRatio=7 -XX:PermSize=64m
 -XX:MaxPermSize=128m -Xint

 In addition I have added the  reloading=false and development=false in
 conf/web.xml.  as per instruction from this thread:
 http://www.junlu.com/msg/78566.html

 My connector is configured thus:
   Connector
   port=80
   maxThreads=1000
   minSpareThreads=1000
   maxSpareThreads=1000
   enableLookups=false
   redirectPort=8443
   acceptCount=3000
   debug=0
   connectionTimeout=2
   disableUploadTimeout=true /


 However all of this is to no avail, and under high stress (80+
 concurrent requests, tomcat dies and terminates the thread dumping a
 hs_pid12345.log with  the above message

 Is this a known hotspot 1.4.x problem (some threads have hinted at
 this), or does someone have a solution for this??

 Thanks,

 M

 -
 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: outOfMemory exception under high load

2005-02-07 Thread reynir
well, your -Xmx1G set's the limit for memory usage at 1 gig.  ?
-server -Xms1G -Xmx1G -Xmn384m -XX:SurvivorRatio=7 -XX:PermSize=64m 
-XX:MaxPermSize=128m -Xint

you might want to set that a little higher.
Michael Cornell wrote:
Not exactly sure but by running vmstat, it look like I am nearing the 2G
limit .. maybe about 1.8G consumed..
/m
reynir wrote:
 

how much memory is your process using when it crashes ?
-r
Michael Cornell wrote:
   

Hi,
Hi,
I am experiencing a problem many others seem to have had before, but
have found no answers.  I am running Tomcat 5.0.25 using jdk 1.4.2_06
hotspot vm on RedHat Linux ES with 4G Ram and twin Intel procs.
When load-testing, under high stress I receive the error below and the
thread dies.
04-Feb-2005 13:39:24 org.apache.coyote.tomcat5.CoyoteAdapter service
SEVERE: An exception or error occurred in the container during the
request processing
java.lang.OutOfMemoryError
  at java.util.zip.ZipFile.open(Native Method)
  at java.util.zip.ZipFile.init(ZipFile.java:112)
  at java.util.jar.JarFile.init(JarFile.java:127)
..
I have adjusted the vm parameters to the below ( the perm space does not
get full and the Xint to not use the optimised settings..
-server -Xms1G -Xmx1G -Xmn384m -XX:SurvivorRatio=7 -XX:PermSize=64m
-XX:MaxPermSize=128m -Xint
In addition I have added the  reloading=false and development=false in
conf/web.xml.  as per instruction from this thread:
http://www.junlu.com/msg/78566.html
My connector is configured thus:
 Connector
 port=80
 maxThreads=1000
 minSpareThreads=1000
 maxSpareThreads=1000
 enableLookups=false
 redirectPort=8443
 acceptCount=3000
 debug=0
 connectionTimeout=2
 disableUploadTimeout=true /
However all of this is to no avail, and under high stress (80+
concurrent requests, tomcat dies and terminates the thread dumping a
hs_pid12345.log with  the above message
Is this a known hotspot 1.4.x problem (some threads have hinted at
this), or does someone have a solution for this??
Thanks,
M
-
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: outOfMemory exception under high load

2005-02-07 Thread Michael Cornell

Sorry, that was a copy and paste typo :(  Its set at 2G (4G for the
whole machine)
/m

reynir wrote:

 well, your -Xmx1G set's the limit for memory usage at 1 gig.  ?
 -server -Xms1G -Xmx1G -Xmn384m -XX:SurvivorRatio=7 -XX:PermSize=64m
 -XX:MaxPermSize=128m -Xint

 you might want to set that a little higher.


 Michael Cornell wrote:

 Not exactly sure but by running vmstat, it look like I am nearing the 2G
 limit .. maybe about 1.8G consumed..

 /m

 reynir wrote:

  

 how much memory is your process using when it crashes ?
 -r


 Michael Cornell wrote:

   

 Hi,

 Hi,

 I am experiencing a problem many others seem to have had before, but
 have found no answers.  I am running Tomcat 5.0.25 using jdk 1.4.2_06
 hotspot vm on RedHat Linux ES with 4G Ram and twin Intel procs.

 When load-testing, under high stress I receive the error below and the
 thread dies.

 04-Feb-2005 13:39:24 org.apache.coyote.tomcat5.CoyoteAdapter service
 SEVERE: An exception or error occurred in the container during the
 request processing
 java.lang.OutOfMemoryError
   at java.util.zip.ZipFile.open(Native Method)
   at java.util.zip.ZipFile.init(ZipFile.java:112)
   at java.util.jar.JarFile.init(JarFile.java:127)
 ..

 I have adjusted the vm parameters to the below ( the perm space
 does not
 get full and the Xint to not use the optimised settings..
 -server -Xms1G -Xmx1G -Xmn384m -XX:SurvivorRatio=7 -XX:PermSize=64m
 -XX:MaxPermSize=128m -Xint

 In addition I have added the  reloading=false and
 development=false in
 conf/web.xml.  as per instruction from this thread:
 http://www.junlu.com/msg/78566.html

 My connector is configured thus:
  Connector
  port=80
  maxThreads=1000
  minSpareThreads=1000
  maxSpareThreads=1000
  enableLookups=false
  redirectPort=8443
  acceptCount=3000
  debug=0
  connectionTimeout=2
  disableUploadTimeout=true /


 However all of this is to no avail, and under high stress (80+
 concurrent requests, tomcat dies and terminates the thread dumping a
 hs_pid12345.log with  the above message

 Is this a known hotspot 1.4.x problem (some threads have hinted at
 this), or does someone have a solution for this??

 Thanks,

 M

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




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



RE: Restart-On-Failure for Tomcat?

2005-02-07 Thread James Richardson



 -Original Message-
 From: Trond G. Ziarkowski [mailto:[EMAIL PROTECTED]
 Sent: 07 February 2005 07:57
 To: tomcat-user@jakarta.apache.org
 Subject: Re: Restart-On-Failure for Tomcat?
 
 Hi!
 
 Someone mentioned on this list a while ago that Java Service Wrapper is
 capable of doing this. Haven't tested it myself but you can check it out
 at http://wrapper.tanukisoftware.org/
 
 Trond
 

Alternatively, you might consider writing a persistent jini wrapper around
tomcat.

This would also allow you to autodiscover tomcat instances, and be alerted
on state changes etc.

It would be a bit of coding though

James
 

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



Re: outOfMemory exception under high load

2005-02-07 Thread reynir
If I remember it correctly Xmn384m defines the next step in increasing 
the allocated memory. there for if you have 1800m used and the max is at 
2g, taking a step of almost 400m may not work.

Why are you setting these paremeters :
-Xmn384m 
-XX:SurvivorRatio=7 
-XX:PermSize=64m
-XX:MaxPermSize=128m 
-Xint

I usually only set the -Xmx and -server
Your problem might also be kernel based problem, you might need a kernel 
update, but I'm not a specialist on that subject. I only know that there 
are some limitations in some linux setups on how much memory it can make 
use of, but I think the limit lies around 4gigs. but that dependes on 
which kernel you are using etc.



Michael Cornell wrote:
Sorry, that was a copy and paste typo :(  Its set at 2G (4G for the
whole machine)
/m
reynir wrote:
 

well, your -Xmx1G set's the limit for memory usage at 1 gig.  ?
-server -Xms1G -Xmx1G -Xmn384m -XX:SurvivorRatio=7 -XX:PermSize=64m
-XX:MaxPermSize=128m -Xint
you might want to set that a little higher.
Michael Cornell wrote:
   

Not exactly sure but by running vmstat, it look like I am nearing the 2G
limit .. maybe about 1.8G consumed..
/m
reynir wrote:

 

how much memory is your process using when it crashes ?
-r
Michael Cornell wrote:
 

   

Hi,
Hi,
I am experiencing a problem many others seem to have had before, but
have found no answers.  I am running Tomcat 5.0.25 using jdk 1.4.2_06
hotspot vm on RedHat Linux ES with 4G Ram and twin Intel procs.
When load-testing, under high stress I receive the error below and the
thread dies.
04-Feb-2005 13:39:24 org.apache.coyote.tomcat5.CoyoteAdapter service
SEVERE: An exception or error occurred in the container during the
request processing
java.lang.OutOfMemoryError
 at java.util.zip.ZipFile.open(Native Method)
 at java.util.zip.ZipFile.init(ZipFile.java:112)
 at java.util.jar.JarFile.init(JarFile.java:127)
..
I have adjusted the vm parameters to the below ( the perm space
does not
get full and the Xint to not use the optimised settings..
-server -Xms1G -Xmx1G -Xmn384m -XX:SurvivorRatio=7 -XX:PermSize=64m
-XX:MaxPermSize=128m -Xint
In addition I have added the  reloading=false and
development=false in
conf/web.xml.  as per instruction from this thread:
http://www.junlu.com/msg/78566.html
My connector is configured thus:
Connector
port=80
maxThreads=1000
minSpareThreads=1000
maxSpareThreads=1000
enableLookups=false
redirectPort=8443
acceptCount=3000
debug=0
connectionTimeout=2
disableUploadTimeout=true /
However all of this is to no avail, and under high stress (80+
concurrent requests, tomcat dies and terminates the thread dumping a
hs_pid12345.log with  the above message
Is this a known hotspot 1.4.x problem (some threads have hinted at
this), or does someone have a solution for this??
Thanks,
M
-
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]

   

-
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: outOfMemory exception under high load

2005-02-07 Thread Dale, Matt

It could be your permanent generation that is running out of space. Get a hold 
of jvmstat to determine if this is the case.

Ta
Matt

-Original Message-
From: Michael Cornell [mailto:[EMAIL PROTECTED]
Sent: 07 February 2005 11:31
To: Tomcat Users List
Subject: Re: outOfMemory exception under high load



Sorry, that was a copy and paste typo :(  Its set at 2G (4G for the
whole machine)
/m

reynir wrote:

 well, your -Xmx1G set's the limit for memory usage at 1 gig.  ?
 -server -Xms1G -Xmx1G -Xmn384m -XX:SurvivorRatio=7 -XX:PermSize=64m
 -XX:MaxPermSize=128m -Xint

 you might want to set that a little higher.


 Michael Cornell wrote:

 Not exactly sure but by running vmstat, it look like I am nearing the 2G
 limit .. maybe about 1.8G consumed..

 /m

 reynir wrote:

  

 how much memory is your process using when it crashes ?
 -r


 Michael Cornell wrote:

   

 Hi,

 Hi,

 I am experiencing a problem many others seem to have had before, but
 have found no answers.  I am running Tomcat 5.0.25 using jdk 1.4.2_06
 hotspot vm on RedHat Linux ES with 4G Ram and twin Intel procs.

 When load-testing, under high stress I receive the error below and the
 thread dies.

 04-Feb-2005 13:39:24 org.apache.coyote.tomcat5.CoyoteAdapter service
 SEVERE: An exception or error occurred in the container during the
 request processing
 java.lang.OutOfMemoryError
   at java.util.zip.ZipFile.open(Native Method)
   at java.util.zip.ZipFile.init(ZipFile.java:112)
   at java.util.jar.JarFile.init(JarFile.java:127)
 ..

 I have adjusted the vm parameters to the below ( the perm space
 does not
 get full and the Xint to not use the optimised settings..
 -server -Xms1G -Xmx1G -Xmn384m -XX:SurvivorRatio=7 -XX:PermSize=64m
 -XX:MaxPermSize=128m -Xint

 In addition I have added the  reloading=false and
 development=false in
 conf/web.xml.  as per instruction from this thread:
 http://www.junlu.com/msg/78566.html

 My connector is configured thus:
  Connector
  port=80
  maxThreads=1000
  minSpareThreads=1000
  maxSpareThreads=1000
  enableLookups=false
  redirectPort=8443
  acceptCount=3000
  debug=0
  connectionTimeout=2
  disableUploadTimeout=true /


 However all of this is to no avail, and under high stress (80+
 concurrent requests, tomcat dies and terminates the thread dumping a
 hs_pid12345.log with  the above message

 Is this a known hotspot 1.4.x problem (some threads have hinted at
 this), or does someone have a solution for this??

 Thanks,

 M

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




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

Any opinions expressed in this E-mail may be those of the individual and not 
necessarily the company. This E-mail and any files transmitted with it are 
confidential and solely for the use of the intended recipient. If you are not 
the intended recipient or the person responsible for delivering to the intended 
recipient, be advised that you have received this E-mail in error and that any 
use or copying is strictly prohibited. If you have received this E-mail in 
error please notify the beCogent postmaster at [EMAIL PROTECTED]
Unless expressly stated, opinions in this email are those of the individual 
sender and not beCogent Ltd. You must take full responsibility for virus 
checking this email and any attachments.
Please note that the content of this email or any of its attachments may 
contain data that falls within the scope of the Data Protection Acts and that 
you must ensure that any handling or processing of such data by you is fully 
compliant with the terms and provisions of the Data Protection Act 1984 and 
1998.


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

Re: outOfMemory exception under high load

2005-02-07 Thread Michael Cornell
Hi,

RE Matt:
//
I am already running visualgc (jvmstat) on it... the behavior is just
that the heap fills up (no gc) and then at about 80% full it just bombs
out.  Perm Gen is only 20% full and none of the others are used..

RE reynir:
Why are you setting these paremeters :
-Xmn384m -XX:SurvivorRatio=7 -XX:PermSize=64m
-XX:MaxPermSize=128m -Xint

I usually only set the -Xmx and -server
//
The Permsize params have been put in in case that was the problem
(running out of perm space) and the -Xint as this makes it run without
any optimisations (I believe) ie all interpreted.
Xmn  is the New Generation= (eden) + (from + to) and survivor ratio is
just that.. the ratio of eden - survivors
I can see no reason why these should mess anything up sufficiently to
produce this error.




Dale, Matt wrote:

It could be your permanent generation that is running out of space. Get a hold 
of jvmstat to determine if this is the case.

Ta
Matt

-Original Message-
From: Michael Cornell [mailto:[EMAIL PROTECTED]
Sent: 07 February 2005 11:31
To: Tomcat Users List
Subject: Re: outOfMemory exception under high load



Sorry, that was a copy and paste typo :(  Its set at 2G (4G for the
whole machine)
/m

reynir wrote:

  

well, your -Xmx1G set's the limit for memory usage at 1 gig.  ?
-server -Xms1G -Xmx1G -Xmn384m -XX:SurvivorRatio=7 -XX:PermSize=64m
-XX:MaxPermSize=128m -Xint

you might want to set that a little higher.


Michael Cornell wrote:



Not exactly sure but by running vmstat, it look like I am nearing the 2G
limit .. maybe about 1.8G consumed..

/m

reynir wrote:

 

  

how much memory is your process using when it crashes ?
-r


Michael Cornell wrote:

  



Hi,

Hi,

I am experiencing a problem many others seem to have had before, but
have found no answers.  I am running Tomcat 5.0.25 using jdk 1.4.2_06
hotspot vm on RedHat Linux ES with 4G Ram and twin Intel procs.

When load-testing, under high stress I receive the error below and the
thread dies.

04-Feb-2005 13:39:24 org.apache.coyote.tomcat5.CoyoteAdapter service
SEVERE: An exception or error occurred in the container during the
request processing
java.lang.OutOfMemoryError
  at java.util.zip.ZipFile.open(Native Method)
  at java.util.zip.ZipFile.init(ZipFile.java:112)
  at java.util.jar.JarFile.init(JarFile.java:127)
..

I have adjusted the vm parameters to the below ( the perm space
does not
get full and the Xint to not use the optimised settings..
-server -Xms1G -Xmx1G -Xmn384m -XX:SurvivorRatio=7 -XX:PermSize=64m
-XX:MaxPermSize=128m -Xint

In addition I have added the  reloading=false and
development=false in
conf/web.xml.  as per instruction from this thread:
http://www.junlu.com/msg/78566.html

My connector is configured thus:
 Connector
 port=80
 maxThreads=1000
 minSpareThreads=1000
 maxSpareThreads=1000
 enableLookups=false
 redirectPort=8443
 acceptCount=3000
 debug=0
 connectionTimeout=2
 disableUploadTimeout=true /


However all of this is to no avail, and under high stress (80+
concurrent requests, tomcat dies and terminates the thread dumping a
hs_pid12345.log with  the above message

Is this a known hotspot 1.4.x problem (some threads have hinted at
this), or does someone have a solution for this??

Thanks,

M

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






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

  



Any opinions expressed in this E-mail may be those of the individual and not 
necessarily the company. This E-mail and any files transmitted with it are 
confidential and solely for the use of the intended recipient. If you are not 
the intended recipient or the person responsible for delivering to the 
intended recipient, be advised that you have received this E-mail in error and 
that any use or copying is strictly prohibited. If you have received this 
E-mail in error please notify the beCogent postmaster at [EMAIL PROTECTED]
Unless expressly stated, opinions in this email are those of the individual 
sender and not beCogent Ltd. You must 

Can not get roles to resolve in LDAP Realm

2005-02-07 Thread Paul Worrall
Hi,

 

I have really tried to get to the bottom of this without resorting to
the list but this should work but it doesn't.

 

Tomcat v 5.5.4

OpenLDAP 

 

I have the Realm configured in server.xml as:

 

Realm className=org.apache.catalina.realm.JNDIRealm

connectionURL=ldap://localhost:389;

userPattern=uid={0},ou=iuap,dc=becta,dc=org

userRoleName=memberOf

/

 

Entry in LDAP

# User1 entry with TOMCAT roles 'admin' and 'manager'

dn: uid=user1,ou=iuap,dc=becta,dc=org

objectClass: iuapPerson

sn: user1

cn: super user1

uid: user1

mail: [EMAIL PROTECTED]

userPassword: secret

memberOf: admin

memberOf: manager

 

 

Produces the following in the logs when I try it against the manager
application:

Security checking request GET /manager/html

Checking constraint 'SecurityConstraint[HTMLManger and Manager command]'
against GET /html -- true

Calling hasUserDataPermission()

User data constraint has no restrictions

Calling authenticate()

retrieving values for attribute memberOf

validating credentials by binding as the user

binding as uid=user1,ou=iuap,dc=becta,dc=org

Username user1 successfully authenticated

getRoles(uid=user1,ou=iuap,dc=becta,dc=org)

Authenticated 'user1' with type 'BASIC'

Calling accessControl()

Checking roles GenericPrincipal[user1()]

*Username user1 does NOT have role manager

No role found:  manager

Failed accessControl() test

 

*As you can see the roles are not being picked up.

 

 

Any ideas?

 

TIA 

 

 

Regards

 

 

Paul Worrall

Portal Technology and Innovation

BECTA

 



**
This email and any files transmitted with it are confidential and
intended solely for the use of the individual or entity to whom they
are addressed. If you have received this email in error please notify
the system manager.
This footnote also confirms that this email message has been swept by
MIMEsweeper for the presence of computer viruses.
www.mimesweeper.com
**



Uppercase index.jsp problem with mod_jk 1.2.8 ?

2005-02-07 Thread Andre Schild
Hello,

we actually use mod_jk 1.2.5 with apache 2.0.52 under win32.
We tried to upgrade to mod_jk 1.2.8, but we get a problem with it.

When specifying a URL like http://www.client.com then
the request is forwarded to tomcat, but tomcat is asked for
the file Index.jsp, where on disk only a index.jsp exists.

So it looks like mod_jk always looks for a uppercase index file.

When we specify http://www.client.com/index.jsp then everything
works fine...

In the apache config we have this:

DirectoryIndex index.jsp Index.jsp index.html Index.html default.html
Default.html

In the tomcat config we have this:

welcome-file-list
welcome-fileindex.html/welcome-file
welcome-fileindex.htm/welcome-file
welcome-fileindex.jsp/welcome-file
/welcome-file-list



If I change the DirectoryIndex to be:

DirectoryIndex index.jsp index.html default.html

Then everything works fine. (But of course the Uppercase index files won't
be served any more)


André


aarboard ag - internet - networks - databases
Egliweg 10 - CH-2560 Nidau - Switzerland
Phone +41 32 332 97 14 Fax +41 32 332 97 15
Mail: [EMAIL PROTECTED]  


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



RE: outOfMemory exception under high load

2005-02-07 Thread Dale, Matt

In that case then it sounds like either a memory leak or you just don't have 
enough memory to support your application. Do you have large objects in your 
sessions?

I'd get a profilier and find out what objects are in your heap when you get the 
exceptions and it should lead you to the root cause of your problem.

Ta
Matt

-Original Message-
From: Michael Cornell [mailto:[EMAIL PROTECTED]
Sent: 07 February 2005 12:01
To: Tomcat Users List
Subject: Re: outOfMemory exception under high load


Hi,

RE Matt:
//
I am already running visualgc (jvmstat) on it... the behavior is just
that the heap fills up (no gc) and then at about 80% full it just bombs
out.  Perm Gen is only 20% full and none of the others are used..

RE reynir:
Why are you setting these paremeters :
-Xmn384m -XX:SurvivorRatio=7 -XX:PermSize=64m
-XX:MaxPermSize=128m -Xint

I usually only set the -Xmx and -server
//
The Permsize params have been put in in case that was the problem
(running out of perm space) and the -Xint as this makes it run without
any optimisations (I believe) ie all interpreted.
Xmn  is the New Generation= (eden) + (from + to) and survivor ratio is
just that.. the ratio of eden - survivors
I can see no reason why these should mess anything up sufficiently to
produce this error.




Dale, Matt wrote:

It could be your permanent generation that is running out of space. Get a hold 
of jvmstat to determine if this is the case.

Ta
Matt

-Original Message-
From: Michael Cornell [mailto:[EMAIL PROTECTED]
Sent: 07 February 2005 11:31
To: Tomcat Users List
Subject: Re: outOfMemory exception under high load



Sorry, that was a copy and paste typo :(  Its set at 2G (4G for the
whole machine)
/m

reynir wrote:

  

well, your -Xmx1G set's the limit for memory usage at 1 gig.  ?
-server -Xms1G -Xmx1G -Xmn384m -XX:SurvivorRatio=7 -XX:PermSize=64m
-XX:MaxPermSize=128m -Xint

you might want to set that a little higher.


Michael Cornell wrote:



Not exactly sure but by running vmstat, it look like I am nearing the 2G
limit .. maybe about 1.8G consumed..

/m

reynir wrote:

 

  

how much memory is your process using when it crashes ?
-r


Michael Cornell wrote:

  



Hi,

Hi,

I am experiencing a problem many others seem to have had before, but
have found no answers.  I am running Tomcat 5.0.25 using jdk 1.4.2_06
hotspot vm on RedHat Linux ES with 4G Ram and twin Intel procs.

When load-testing, under high stress I receive the error below and the
thread dies.

04-Feb-2005 13:39:24 org.apache.coyote.tomcat5.CoyoteAdapter service
SEVERE: An exception or error occurred in the container during the
request processing
java.lang.OutOfMemoryError
  at java.util.zip.ZipFile.open(Native Method)
  at java.util.zip.ZipFile.init(ZipFile.java:112)
  at java.util.jar.JarFile.init(JarFile.java:127)
..

I have adjusted the vm parameters to the below ( the perm space
does not
get full and the Xint to not use the optimised settings..
-server -Xms1G -Xmx1G -Xmn384m -XX:SurvivorRatio=7 -XX:PermSize=64m
-XX:MaxPermSize=128m -Xint

In addition I have added the  reloading=false and
development=false in
conf/web.xml.  as per instruction from this thread:
http://www.junlu.com/msg/78566.html

My connector is configured thus:
 Connector
 port=80
 maxThreads=1000
 minSpareThreads=1000
 maxSpareThreads=1000
 enableLookups=false
 redirectPort=8443
 acceptCount=3000
 debug=0
 connectionTimeout=2
 disableUploadTimeout=true /


However all of this is to no avail, and under high stress (80+
concurrent requests, tomcat dies and terminates the thread dumping a
hs_pid12345.log with  the above message

Is this a known hotspot 1.4.x problem (some threads have hinted at
this), or does someone have a solution for this??

Thanks,

M

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






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

  



Any opinions expressed in this E-mail may be those of the individual and not 
necessarily the company. This E-mail and any files transmitted with 

Re: JNDI without edit server.xml

2005-02-07 Thread fstmncn
you should edit context.xml under META-INF in your
web-application.
HTH,
Fausto.

--- Davide Gurgone [EMAIL PROTECTED] wrote:

 Hi all,
 I've got a problem.
 I'm using tomcat 5.0 with Oracle 9.2i. Now I want to
 upgrade tomcat to 
 the newest version, but the same configuration
 doesn't work again.
 
 I used this solution for tomcat 5.0, because I don't
 whant to write 
 anithing on tomcat server.xml file.
 
 To configure and use it I created ONLY this xml and
 put it on 
 $TOMCAT_HOME/conf/catalina/localhost/strutsProva.xml
 file.
 
 Context displayName=Everithing managing system
  docBase=D:\dev\strutsProva
 path=/strutsProva reloadable=true
Resource name=jdbc/strutsProva
 auth=Container
type=javax.sql.DataSource /
  ResourceParams name=jdbc/strutsProva
parameter
   namedriverClassName/name
   valueoracle.jdbc.OracleDriver/value
/parameter
parameter
   nameurl/name
 

valuejdbc:oracle:thin:@localhost:1521:sweet/value
/parameter
parameter
   nameusername/name
   valuedasit/value
/parameter
parameter
   namepassword/name
   valuedasilab/value
/parameter
parameter
   namemaxActive/name
   value1/value
/parameter
parameter
   namemaxWait/name
   value5000/value
/parameter
parameter
   namemaxIdle/name
   value2/value
/parameter
  /ResourceParams
 /Context
 
 Anybody knows how to configure a jndi service on
 tomcat, without write 
 anithing on server.xml file? I have to leave it
 clean 'cause I don't 
 know who will install my application.
 
 Thanks all,
 
 Davide
 
 

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


=
[--°--]



__ 
Do you Yahoo!? 
The all-new My Yahoo! - What will yours do?
http://my.yahoo.com 

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



Re: JNDI without edit server.xml

2005-02-07 Thread Davide Gurgone
fstmncn wrote:
you should edit context.xml under META-INF in your
web-application.
HTH,
Fausto.
Hi Fausto,
Thank you for the response,
I try your solution, but I think I wrong something, 'cause the problem 
is the same:
INFO: HTMLManager: list: Listing contexts for virtual host 'localhost'
org.apache.tomcat.dbcp.dbcp.SQLNestedException: Cannot create JDBC 
driver of class '' for connect URL 'null'
at 
org.apache.tomcat.dbcp.dbcp.BasicDataSource.createDataSource(BasicDataSource.java:780)
.

In order I delete the strutsProva.xml from
  $TOMCAT_HOME/conf/Catalina/localhost
and I put the same content in a new $WEB_APP/META-INF/context.xml file.
Finally I deployed the application from the tomcat manager, adding the 
Directory URL and the Context Path.

I think Tomcat doesn't read the file!
How can I say to Tomcat the file location?
Have you got any other suggests?

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


Class loader and garbage collector

2005-02-07 Thread Roberto Cosenza
I've seen that Spring defines a
*org.springframework.web.util.IntrospectorCleanupListener *
which flushes the bean introspector which may hold cached references to 
classes to be garbage collected.

In tomcat 5.5.7, using jconsole, I've seen that using the 
IntrospectorCleanupListener is not enough. The number of loaded classes 
keep increasing when reloading a webapp.
The jconsole only shows the number of loaded classes.
Is there any way to see which classes are still referenced so that I can 
further investigate the problem?
/roberto

--
Roberto Cosenza
Infoflex Connect AB, Sweden
Tel: +46-(0)8-55576860, Fax: +46-(0)8-55576861
--
Nordic Messaging Technologies is a trademark of Infoflex Connect.
Please visit www.nordicmessaging.se for more information about our
carrier-grade messaging products.

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


How to get english messages on a German Windows-XP?

2005-02-07 Thread Zsolt Koppany
Hi,

This is probably a java and not a tc question, but I would like to know how
to get English java error messages when I start tc on a German windows XP
box.

Zsolt




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



Re: JNDI without edit server.xml

2005-02-07 Thread fstmncn
It looks like it can't find the db driver.
Try putting it under WeB-INF\lib if you haven't done
it yet.
Moreover be sure to have the references in the web.xml
of your application. These are mine, for example:

  !-- references to JNDI resources --
  !-- database --
  resource-ref
res-ref-namejdbc/ddb/res-ref-name
res-typejavax.sql.DataSource/res-type
res-authContainer/res-auth
  /resource-ref
  !-- javamail --
  resource-ref
res-ref-namemail/dmail/res-ref-name
res-typejavax.mail.Session/res-type
res-authContainer/res-auth
  /resource-ref

F.

--- Davide Gurgone [EMAIL PROTECTED] wrote:

 fstmncn wrote:
  you should edit context.xml under META-INF in your
  web-application.
  HTH,
  Fausto.
 
 Hi Fausto,
 Thank you for the response,
 
 I try your solution, but I think I wrong something,
 'cause the problem 
 is the same:
 INFO: HTMLManager: list: Listing contexts for
 virtual host 'localhost'
 org.apache.tomcat.dbcp.dbcp.SQLNestedException:
 Cannot create JDBC 
 driver of class '' for connect URL 'null'
  at 

org.apache.tomcat.dbcp.dbcp.BasicDataSource.createDataSource(BasicDataSource.java:780)
 .
 
 In order I delete the strutsProva.xml from
$TOMCAT_HOME/conf/Catalina/localhost
 and I put the same content in a new
 $WEB_APP/META-INF/context.xml file.
 Finally I deployed the application from the tomcat
 manager, adding the 
 Directory URL and the Context Path.
 
 I think Tomcat doesn't read the file!
 How can I say to Tomcat the file location?
 
 Have you got any other suggests?
 
 
 

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


=
[--°--]



__ 
Do you Yahoo!? 
Meet the all-new My Yahoo! - Try it today! 
http://my.yahoo.com 
 


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



class not found when starting manager on solaris 9

2005-02-07 Thread Jens Joachim
Hi all!

I am running tomcat 5.5.4 with JDK 1.4.2 on a x86 Linux system. I am using a
CATALINA_BASE different from CATALINA_HOME. Everything works fine, including
the Tomcat Web Application Manager. But running the same on a SPARC with
Solaris 9 brings up the following error message when trying to start the
manager app:

** begin of browser output
***
HTTP Status 500 -




type Exception report

message

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

exception

javax.servlet.ServletException: Error allocating a servlet instance

org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase
.java:482)

org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105
)
 org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:526)
 org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148)
 org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:825)

org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.processConne
ction(Http11Protocol.java:731)

org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.jav
a:526)

org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWo
rkerThread.java:80)

org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.jav
a:684)
 java.lang.Thread.run(Thread.java:534)


root cause

java.lang.NoClassDefFoundError: org/apache/catalina/ContainerServlet
 java.lang.ClassLoader.defineClass0(Native Method)
 java.lang.ClassLoader.defineClass(ClassLoader.java:539)
 java.security.SecureClassLoader.defineClass(SecureClassLoader.java:123)

org.apache.catalina.loader.WebappClassLoader.findClassInternal(WebappClassLo
ader.java:1626)

org.apache.catalina.loader.WebappClassLoader.findClass(WebappClassLoader.jav
a:850)

org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.jav
a:1299)

org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.jav
a:1181)
 java.lang.ClassLoader.loadClassInternal(ClassLoader.java:302)
 java.lang.ClassLoader.defineClass0(Native Method)
 java.lang.ClassLoader.defineClass(ClassLoader.java:539)
 java.security.SecureClassLoader.defineClass(SecureClassLoader.java:123)

org.apache.catalina.loader.WebappClassLoader.findClassInternal(WebappClassLo
ader.java:1626)

org.apache.catalina.loader.WebappClassLoader.findClass(WebappClassLoader.jav
a:850)

org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.jav
a:1299)

org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.jav
a:1181)

org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase
.java:482)

org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105
)
 org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:526)
 org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148)
 org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:825)

org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.processConne
ction(Http11Protocol.java:731)

org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.jav
a:526)

org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWo
rkerThread.java:80)

org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.jav
a:684)
 java.lang.Thread.run(Thread.java:534)


note The full stack trace of the root cause is available in the Apache
Tomcat/5.5.4 logs.





Apache Tomcat/5.5.4
 end of browser output
***

The content of the tomcat log file looks like this:

** begin of tomcat log file
*
16 Dec 2004 17:12:51.145 ERROR main
org.apache.catalina.core.ContainerBase.[Catalina].[localhost].[/manager] -
Error loading WebappClassLoader

  delegate: false

  repositories:

-- Parent Classloader:

[EMAIL PROTECTED]

 org.apache.catalina.servlets.DefaultServlet
java.lang.ClassNotFoundException:
org.apache.catalina.servlets.DefaultServlet
 at
org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.jav
a:1332)
 at
org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.jav
a:1181)
 at
org.apache.catalina.core.StandardWrapper.loadServlet(StandardWrapper.java:98
8)
 at org.apache.catalina.core.StandardWrapper.load(StandardWrapper.java:886)
 at
org.apache.catalina.core.StandardContext.loadOnStartup(StandardContext.java:
3817)
 at
org.apache.catalina.core.StandardContext.start(StandardContext.java:4079)
 at
org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:7
55)
 at 

**CONFIDENTIAL** Configuring Log4j in webapps

2005-02-07 Thread Ethan Cabiac
Hi everyone,

 I don't know if this is a Log4j problem or a Tomcat related issue but I
am posting here first because I already subscribe to this mailing list ;).
I have two (theoretically) identical Tomcat webservers (Tomcat 5.0), one on
my local WinXP machine for dev/testing and one on the company's Win 2003
Server machine for production.  When I setup my log4j files in my webapps I
use:

 log4j.appender.A1.File=../logs/mywebapplog.log

On my test machine this will work perfectly and even create the log file on
Tomcat startup if it does not exist. On my production database it will not
work if I use relative path, I actually have to specify
C:/path_to_logs/mywebapplog.log and if the file is not there already then
Tomcat complains on startup and no log gets written for the webapp.  Like I
said, the two Tomcats are supposed to be identical, but maybe there is a
configuration discrepancy I missed, or maybe this is a Log4j thing? Any help
is appreciated.

-Ethan Cabiac


--
This message (including any attachments) contains confidential information
intended for a specific individual and purpose, and is protected by law. 

 If you are the intended recipient, this message is CONFIDENTIAL as per 
Contract.
 This message should not be disseminated to 3rd parties without prior 
written
 approval or consent from a Director of TRAX. Violation of Contract Terms 
constitute
 a breach and be cause for termination.

 If you are NOT the intended recipient, you should delete this message and 
are hereby 
 notified that any disclosure, copying, or distribution of this message, or
 the taking of any action based on it, is strictly prohibited.

Version control in WebDAV component of Tomcat

2005-02-07 Thread Wong Onn Chee
Hi,
I am new to the latest version of Tomcat 5.5.
I know that it has a bundled WebDAV component, but I can't get the 
version control feature working.
Does any one know how I can do it?

Many thanks in advance.
Regards
Onn Chee
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


Re: order of creation of JNDI datasource from context.xml and Filter.init() using it

2005-02-07 Thread Wouter Boers
The easiest way to add a JNDI datasource is to install the webadmin
and define the datasource not as a global JNDI but 'local' to the
context. This can easily be achieved with the admin application.

I have seen this problem where I defined the global datasource in TC
5.5 and it was not visible via a JNDI lookup. Either you have to do a
lot more configuration or it is a bug. I haven't gotten arround to
investigate this further :(

Wouter

On Sat, 05 Feb 2005 22:17:54 +0100, Mario Winterer
[EMAIL PROTECTED] wrote:
 Hi Jeroen!
 
 Two weeks ago I (almost) exactly did what you want to do - make
 hibernate use a JNDI-DataSource defined as a GlobalNamingResource! The
 differences: My database is Oracle and I didn't configure hibernate
 directly because I use the spring-framework in between.
 I experienced problems similar than yours, but after cleaning out some
 old stuff it worked! Unfortunately, I do not know, what exactly the
 problem was, but I can give you some hints that may help you!
 
 Assuming you use Tomcat 5.5, do the following
 1) Skip the factory-attribute in your Resource-definition! It is not
 required because tomcat has a built-in connection pool and automatically
 uses it for JNDI-DataSources.
 2) Define your JNDI-DataSource in the GlobalNamingContext
 3) The resourcelink-element in meta-inf/context.xml must specify the
 name of the global resource (attribute global) AND the name, the
 resource should have when linked into the lokal JNDI-context (attribute
 name). This (internal) name must match the name specified in your
 hibernate config! I guess that's what you got wrong!
 
 Your code:
 ResourceLink name=My Database global=jdbc/mydb
 type=javax.sql.Datasource /
 (You specified My Database as internal JNDI-name, but jdbc/mydb in
 hibernate.cfg.xml!!!)
 
 Better:
 ResourceLink name=jdbc/mydb global=jdbc/mydb
 type=javax.sql.Datasource /
 (That matches the name you used in your hibernate.cfg.xml:
 java:env/jdbc/mydb)
 
 4) Remove the context-definition file in conf/Engine/host. At
 deployment time, tomcat copies the context.xml file from the
 meta-inf-directory of your web-application into the
 conf/Engine/host-directory (and renames it to avoid conflicts).
 5) The PostgreSQL-driver must be in common/lib. Make sure it is NOT in
 WEB-INF/lib too!
 
 As I've said in top 3, I think the chief cause of your problem is the
 resourcelink-element!
 (Apart from that: I've seen you wrote your own HibernateSessionFilter. I
 also did that first, but then I decided to use the
 OpenSessionInViewFilter from the spring-framework instead. It works
 great! I'm sure your filter-implementation is not the cause of your
 problems, but maybe the spring-framework is interesting to you!)
 
 Best regards,
   Tex
 
 Jeroen Kransen schrieb:
 
  Hello,
 
  My problem is so basic that I have no doubt other people have
  experienced it. Still, I can't find any solutions on the web.
 
  I want Tomcat to provide my webapp with DataSources through JNDI. I want
  Hibernate to use these DataSources. Nothing exciting so far. I
  configured the BasicDataSourceFactory in the META-INF/context.xml like
  this:
 
 Resource name=jdbc/mydb
 auth=Container
 driverClassName=org.postgresql.Driver
 factory=org.apache.commons.dbcp.BasicDataSourceFactory
 username=*
 password=*
 type=javax.sql.Datasource
 url=jdbc:postgresql://localhost:5432/mywebapp
 scope=Shareable
 maxActive=10
 maxIdle=100
 maxWait=3000
 /
 
  In the web.xml I put:
 
 filter
 filter-nameHibernateSessionFilter/filter-name
 
  filter-classnl.kransen.mywebapp.context.HibernateSessionFilter/filter-class
 
 /filter
 filter-mapping
 filter-nameHibernateSessionFilter/filter-name
 url-pattern/*/url-pattern
 /filter-mapping
  ...
 resource-ref
 descriptionMy database/description
 res-ref-namejdbc/mydb/res-ref-name
 res-typejavax.sql.DataSource/res-type
 res-authContainer/res-auth
 /resource-ref
 
  In the hibernate.cfg.xml I make a JNDI reference to the datasource:
 
  hibernate-configuration
 session-factory
 property
  name=connection.datasourcejava:comp/env/jdbc/mydb/property
 property
  name=dialectnet.sf.hibernate.dialect.PostgreSQLDialect/property
 property name=show_sqltrue/property
 
 mapping resource=hibernate-mappings/Aap.hbm.xml /
 mapping resource=hibernate-mappings/Noot.hbm.xml /
 mapping resource=hibernate-mappings/Mies.hbm.xml /
 /session-factory
  /hibernate-configuration
 
  Now I created a HibernateSessionFilter that will filter any request to
  the webapp and provide it with a Hibernate Session. In the init() the
  Hibernate SessionFactory is configured by doing a lookup on JNDI for a
  DataSource.
 
  My problem is that Hibernate can't find the JNDI datasource:
 
  17:44:14,745 INFO  

Re: Version control in WebDAV component of Tomcat

2005-02-07 Thread Remy Maucherat
On Mon, 07 Feb 2005 22:25:20 +0800, Wong Onn Chee [EMAIL PROTECTED] wrote:
 Hi,
 
 I am new to the latest version of Tomcat 5.5.
 I know that it has a bundled WebDAV component, but I can't get the
 version control feature working.
 Does any one know how I can do it?

If you mean Delta V, then there's no support for that, and you should
look into using Slide instead.

The Tomcat WebDAV servlet supports WebDAV level 1, with partial level
2 support (some complex locking operations are not supported).

-- 
x
Rémy Maucherat
Developer  Consultant
JBoss Group (Europe) SàRL
x

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



Version control in WebDAV component of Tomcat

2005-02-07 Thread Andrew Paliga
Return Receipt
   
   Your   Version control in WebDAV component of Tomcat
   document:   
   
   wasAndrew Paliga/Toronto/IBM
   received
   by: 
   
   at:02/07/2005 09:29:52  
   





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



Re: virtualhost and deployment applications

2005-02-07 Thread Carlos Gabriel Arce
Thanks for your answer. I'll show you my server.xml conf:
...
  Host name=domain1.com debug=9 appbase=WWW/domain1.com 
unpackWARS=true
autoDeploy=true
xmlValidation=false
xmlNamespaceAware=false

Context path= docBase=WWW/domain1.com debug=9 
reloadable=true/
Context path=/manager docBase=WWW/domain1.com/manager 
privileged=true debug=2/
Logger className=org.apache.catalina.logger.FileLogger 
directory=logs prefix=domain1.com_log.
 suffix=.txt timestamp=true/
  /Host
  Host name=domain2.com debug=2 appbase=WWW/domain2.com 
unpackWARs=true autoDeploy=true xmlValidation=false 
xmlNamespaceAware=false
Context path= docBase=WWW/domain2.com debug=0 
reloadable=true/
Context path=/manager docBase=WWW/domain2.com/manager 
debug=0 privileged=true/
Logger className=org.apache.catalina.logger.FileLogger 
directory=logs prefix=domain2.com_log. suffix=.txt timestamp=true/
  /Host

...
my tomcat is installed in the dir /usr/local/jakarta_5. When I deploy a 
war using the manager web app : http://domain1.com/manager the war is 
copied in the dir /usr/local/jakarta_5 instead WWW/domain1.com, and 
therefore is deployed in the domain2.com too.



Atentamente:
Ing. Carlos Gabriel Arce
Administrador del Hosting
TELESAT S.A
Cisco CCNA 10677416
Pbx. 57-2 - 644 0400
Fax. 57-2 - 644 0507
Cali, Colombia
http://www.telesat.com.co

Quien no ha afrontado la adversidad
no conoce su propia fuerza.
Benjamin Jonson.




La información adjunta en este mensaje es de uso exclusivo de la/s 
persona(s) o entidad/es a la que está dirigida y puede incluir 
información confidencial, personal y/o material protegido legalmente. La 
recepción de este mensaje por cualquier otra persona distinta de los 
destinatarios a los que está dirigido, no implica renuncia alguna al 
privilegio o derecho de confidencialidad. Se prohíbe el análisis, la 
retransmisión, divulgación o cualquier otro uso, o acción relacionada 
con esta información que fuera llevada a cabo por personas distintas del 
destinatario al cual la información está dirigida. Si recibe esta 
información por error, comuníquese con el remitente y proceda a borrarla 
de inmediato de todos los equipos de cómputo donde pueda quedar 
almacenada. Telesat entiende que el destinatario de este  mensaje ha 
tomado todas las medidas técnicamente recomendables y apropiadas para 
evitar la contaminación por virus. Telesat S.A. no se hace responsable 
por la eventual transmisión de virus o programas dañinos por este medio, 
ni acepta responsabilidad alguna por eventuales daños o alteraciones 
derivados de la recepción o uso del presente mensaje. Las opiniones, 
conclusiones y otra información contenida en este correo no relacionadas 
con el negocio oficial de Telesat S.A. deben entenderse como personales 
y de ninguna manera son avaladas por la Compañía. Agradecemos su atención.

Mario Winterer escribió:
Hi!
I think, there's something wrong with your context-definition or 
server.xml. Make sure each of your hosts have a webapplication base 
directory for their own!!! Do not use one single webapps-directory for 
all of your hosts!

My directory structure looks as follows:
somewhere/Tomcat/hosts/host/web-application
Inside server.xml, where the hosts are defined, each host's 
appBase-attribute points to the correspoding host-directory.

Apart from that: If your tomcat's auto-deploy feature is activated, you 
can deploy a web-application by simply copying the war file into your 
webapps-directory (or any other directory that you specified in 
server.xml).

Best regards,
 Tex
Carlos Gabriel Arce wrote:
But when I deploy a local .war in the administration page 
www.domain1.com/manager/html

this war gets replicated in other virtualhosts.

Mario Winterer escribió:
Of course!
That's Tomcat's default behaviour - and in fact, it is difficult to 
make it behave different!
Have a look at server.xml of your tomcat's default installation (you 
need a host-element for each virtual host). More information can be 
found at 
http://jakarta.apache.org/tomcat/tomcat-5.5-doc/config/index.html.

Best regards,
 Tex
Carlos Gabriel Arce schrieb:
 Good Day
I have a question. Is possible deploy an application per 
virtualhost, where the deployed applications per virtualhost 
could'nt see them each other?

Thanks in advance.

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

Tomcat 5.5 cvs

2005-02-07 Thread Phillip Qin
What is the cvs repository for tomcat 5.5 source? I can find tomcat-5 but I
am not sure whether that is the right one.



Regards,
 
 
PQ
 
Going to war for peace is like having sex for virginity


jaas with wlclient.jar returns no principals

2005-02-07 Thread CMcDonald
We are developing a j2ee app using tomcat for the web container and 
weblogic for the ejb container. 
We are using jaas for authentication with weblogic. 
When our war is deployed on tomcat, using the wlclient.jar,  the jaas 
authentication returns no principals with the subject.  When we deploy our 
war on weblogic (or test a jaas client using weblogic.jar), the jaas 
authentication returns principlas.

What can we do to make the jaas authentication with a war deployed on 
tomcat work with weblogic?


Using WLClient.jar:
Subject is: Subject:
Private Credential: 
[EMAIL PROTECTED]
Private Credential: SubjectProxy[23994289]

Size of Principals: 0
Principals: 

Using Weblogic.jar:
Subject is: Subject:
Principal: mjLDAP
Private Credential: 
[EMAIL PROTECTED]
Private Credential: 
[EMAIL PROTECTED]

Size of Principals: 1
Principals: 
mjLDAP

RE: Tomcat 5.5 cvs

2005-02-07 Thread Allistair Crossley
Hi,

jakarta-tomcat-catalina 

http://jakarta.apache.org/site/cvsindex.html

Cheers

 -Original Message-
 From: Phillip Qin [mailto:[EMAIL PROTECTED]
 Sent: 07 February 2005 15:18
 To: 'tomcat-user@jakarta.apache.org'
 Subject: Tomcat 5.5 cvs
 
 
 What is the cvs repository for tomcat 5.5 source? I can find 
 tomcat-5 but I
 am not sure whether that is the right one.
 
 
 
 Regards,
  
  
 PQ
  
 Going to war for peace is like having sex for virginity
 


FONT SIZE=1 FACE=VERDANA,ARIAL COLOR=BLUE 
---
QAS Ltd.
Developers of QuickAddress Software
a href=http://www.qas.com;www.qas.com/a
Registered in England: No 2582055
Registered in Australia: No 082 851 474
---
/FONT


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



OT: Version control tool

2005-02-07 Thread John Najarian
Does anyone know a good version control tool for code management that is free?

Also, a bug tracking application would be nice also.

These need to be run on Windows.

Thanks

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



RE: Version control tool

2005-02-07 Thread Allistair Crossley
Hi,

WinCVS
BugZilla

Cheers.

 -Original Message-
 From: John Najarian [mailto:[EMAIL PROTECTED]
 Sent: 07 February 2005 15:25
 To: Tomcat Users List
 Subject: OT: Version control tool
 
 
 Does anyone know a good version control tool for code 
 management that is free?
 
 Also, a bug tracking application would be nice also.
 
 These need to be run on Windows.
 
 Thanks
 
 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]
 
 


FONT SIZE=1 FACE=VERDANA,ARIAL COLOR=BLUE 
---
QAS Ltd.
Developers of QuickAddress Software
a href=http://www.qas.com;www.qas.com/a
Registered in England: No 2582055
Registered in Australia: No 082 851 474
---
/FONT


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



RE: Version control tool

2005-02-07 Thread Dale, Matt

Eclipse

-Original Message-
From: John Najarian [mailto:[EMAIL PROTECTED]
Sent: 07 February 2005 15:25
To: Tomcat Users List
Subject: OT: Version control tool


Does anyone know a good version control tool for code management that is free?

Also, a bug tracking application would be nice also.

These need to be run on Windows.

Thanks

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

Any opinions expressed in this E-mail may be those of the individual and not 
necessarily the company. This E-mail and any files transmitted with it are 
confidential and solely for the use of the intended recipient. If you are not 
the intended recipient or the person responsible for delivering to the intended 
recipient, be advised that you have received this E-mail in error and that any 
use or copying is strictly prohibited. If you have received this E-mail in 
error please notify the beCogent postmaster at [EMAIL PROTECTED]
Unless expressly stated, opinions in this email are those of the individual 
sender and not beCogent Ltd. You must take full responsibility for virus 
checking this email and any attachments.
Please note that the content of this email or any of its attachments may 
contain data that falls within the scope of the Data Protection Acts and that 
you must ensure that any handling or processing of such data by you is fully 
compliant with the terms and provisions of the Data Protection Act 1984 and 
1998.


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

Re: Version control tool

2005-02-07 Thread epyonne
VCS is open source and is very good. Do a search on sourceforge.net.

Thanks.


- Original Message - 
From: John Najarian [EMAIL PROTECTED]
To: Tomcat Users List tomcat-user@jakarta.apache.org
Sent: Monday, February 07, 2005 09:24 AM
Subject: OT: Version control tool


 Does anyone know a good version control tool for code management that is
free?

 Also, a bug tracking application would be nice also.

 These need to be run on Windows.

 Thanks

 -
 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: Version control tool

2005-02-07 Thread Larry Meadors
Eclipse?!

For version control, go with CVS or subversion. Most apache projects
these days are going to subversion. It integrates very nicely with
Windows.

For bug tracking, I have yet to find a free bug tracking too that does
not suck. If there is anyway, drop the $1200 and get JIRA. IMO, it is
FAR better than bugzilla...yes, even $1200 better.

Larry


On Mon, 7 Feb 2005 15:27:48 -, Dale, Matt [EMAIL PROTECTED] wrote:
 
 Eclipse
 
 -Original Message-
 From: John Najarian [mailto:[EMAIL PROTECTED]
 Sent: 07 February 2005 15:25
 To: Tomcat Users List
 Subject: OT: Version control tool
 
 Does anyone know a good version control tool for code management that is free?
 
 Also, a bug tracking application would be nice also.
 
 These need to be run on Windows.
 
 Thanks
 
 -
 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: Updating running WARs?

2005-02-07 Thread Mitchell K. McCuiston
Try configuring your app context inside of the META-INF/context.xml inside
of your war instead of your server.xml.  I had the same problem and this
seemed to fix it.

-Original Message-
From: David Wood [mailto:[EMAIL PROTECTED]
Sent: Friday, February 04, 2005 3:15 PM
To: tomcat-user@jakarta.apache.org
Subject: Updating running WARs?


What's the right way to update a running WAR in Tomcat 5.5?

Is there anything resembling the manager's reload feature for WARs? Or
are we forced to remove the context via the manager and then re-add a new
context back in? (Or restart Tomcat?)

I've been searching through documentation for the manager, and then
looking a bit at the source code, and it seems like it's impossible to
reload a context unless it's exploded.




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



RE: Version control tool

2005-02-07 Thread Dale, Matt

www.eclipse.org

You still need a CVS server but it is very good for managing source code as it 
is a nicely featured CVS client.

-Original Message-
From: Larry Meadors [mailto:[EMAIL PROTECTED]
Sent: 07 February 2005 15:38
To: Tomcat Users List
Subject: Re: Version control tool


Eclipse?!

For version control, go with CVS or subversion. Most apache projects
these days are going to subversion. It integrates very nicely with
Windows.

For bug tracking, I have yet to find a free bug tracking too that does
not suck. If there is anyway, drop the $1200 and get JIRA. IMO, it is
FAR better than bugzilla...yes, even $1200 better.

Larry


On Mon, 7 Feb 2005 15:27:48 -, Dale, Matt [EMAIL PROTECTED] wrote:
 
 Eclipse
 
 -Original Message-
 From: John Najarian [mailto:[EMAIL PROTECTED]
 Sent: 07 February 2005 15:25
 To: Tomcat Users List
 Subject: OT: Version control tool
 
 Does anyone know a good version control tool for code management that is free?
 
 Also, a bug tracking application would be nice also.
 
 These need to be run on Windows.
 
 Thanks
 
 -
 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]

Any opinions expressed in this E-mail may be those of the individual and not 
necessarily the company. This E-mail and any files transmitted with it are 
confidential and solely for the use of the intended recipient. If you are not 
the intended recipient or the person responsible for delivering to the intended 
recipient, be advised that you have received this E-mail in error and that any 
use or copying is strictly prohibited. If you have received this E-mail in 
error please notify the beCogent postmaster at [EMAIL PROTECTED]
Unless expressly stated, opinions in this email are those of the individual 
sender and not beCogent Ltd. You must take full responsibility for virus 
checking this email and any attachments.
Please note that the content of this email or any of its attachments may 
contain data that falls within the scope of the Data Protection Acts and that 
you must ensure that any handling or processing of such data by you is fully 
compliant with the terms and provisions of the Data Protection Act 1984 and 
1998.


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

jsp version of session variable access. Pointer to syntax wanted.

2005-02-07 Thread Pawson, David
Looking for the syntax to gain access to a session variable
in a jsp page, rather than converting it to java.

HttpSession session=request.getSession();
String s = (String)session.getAttribute(sessionData.FILECOUNT);

I'm not using the xml syntax (as yet).
tomcat 5028.

any pointers appreciated please.

Regards DaveP.

 snip here *

-- 
DISCLAIMER:

NOTICE: The information contained in this email and any attachments is 
confidential and may be privileged.  If you are not the intended 
recipient you should not use, disclose, distribute or copy any of the 
content of it or of any attachment; you are requested to notify the 
sender immediately of your receipt of the email and then to delete it 
and any attachments from your system.

RNIB endeavours to ensure that emails and any attachments generated by
its staff are free from viruses or other contaminants.  However, it 
cannot accept any responsibility for any  such which are transmitted.
We therefore recommend you scan all attachments.

Please note that the statements and views expressed in this email and 
any attachments are those of the author and do not necessarily represent
those of RNIB.

RNIB Registered Charity Number: 226227

Website: http://www.rnib.org.uk




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



RE: Version control tool

2005-02-07 Thread John Najarian
Thanks Matt, I should have said I don't want to limit this to Java.

-Original Message-
From: Dale, Matt [EMAIL PROTECTED]
Sent: Feb 7, 2005 10:27 AM
To: Tomcat Users List tomcat-user@jakarta.apache.org, 
John Najarian [EMAIL PROTECTED]
Subject: RE: Version control tool


Eclipse

-Original Message-
From: John Najarian [mailto:[EMAIL PROTECTED]
Sent: 07 February 2005 15:25
To: Tomcat Users List
Subject: OT: Version control tool


Does anyone know a good version control tool for code management that is free?

Also, a bug tracking application would be nice also.

These need to be run on Windows.

Thanks

-
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 version of session variable access. Pointer to syntax wanted.

2005-02-07 Thread fstmncn
you can use expression language:
e.g.:

${sessionData.FILECOUNT}

--- Pawson, David [EMAIL PROTECTED] wrote:

 Looking for the syntax to gain access to a session
 variable
 in a jsp page, rather than converting it to java.
 
 HttpSession session=request.getSession();
 String s =
 (String)session.getAttribute(sessionData.FILECOUNT);
 
 I'm not using the xml syntax (as yet).
 tomcat 5028.
 
 any pointers appreciated please.
 
 Regards DaveP.
 
  snip here *
 
 -- 
 DISCLAIMER:
 
 NOTICE: The information contained in this email and
 any attachments is 
 confidential and may be privileged.  If you are not
 the intended 
 recipient you should not use, disclose, distribute
 or copy any of the 
 content of it or of any attachment; you are
 requested to notify the 
 sender immediately of your receipt of the email and
 then to delete it 
 and any attachments from your system.
 
 RNIB endeavours to ensure that emails and any
 attachments generated by
 its staff are free from viruses or other
 contaminants.  However, it 
 cannot accept any responsibility for any  such which
 are transmitted.
 We therefore recommend you scan all attachments.
 
 Please note that the statements and views expressed
 in this email and 
 any attachments are those of the author and do not
 necessarily represent
 those of RNIB.
 
 RNIB Registered Charity Number: 226227
 
 Website: http://www.rnib.org.uk
 
 
 
 

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


=
[--°--]



__ 
Do you Yahoo!? 
The all-new My Yahoo! - Get yours free! 
http://my.yahoo.com 
 


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



Re: Version control tool

2005-02-07 Thread Dov Rosenberg
CVS is the old school source code versioning tool. We recently converted to
Subversion (http://subversion.tigris.org) - it has most of the good CVS
functionality without the CVS weirdness.

It also integrates with Eclipse


-- 
Dov Rosenberg
Conviveon Corporation
http://www.conviveon.com




On 2/7/05 10:46 AM, John Najarian [EMAIL PROTECTED] wrote:

 Thanks Matt, I should have said I don't want to limit this to Java.
 
 -Original Message-
 From: Dale, Matt [EMAIL PROTECTED]
 Sent: Feb 7, 2005 10:27 AM
 To: Tomcat Users List tomcat-user@jakarta.apache.org,
 John Najarian [EMAIL PROTECTED]
 Subject: RE: Version control tool
 
 
 Eclipse
 
 -Original Message-
 From: John Najarian [mailto:[EMAIL PROTECTED]
 Sent: 07 February 2005 15:25
 To: Tomcat Users List
 Subject: OT: Version control tool
 
 
 Does anyone know a good version control tool for code management that is free?
 
 Also, a bug tracking application would be nice also.
 
 These need to be run on Windows.
 
 Thanks
 
 -
 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: isUserInRole

2005-02-07 Thread Denny Lee
Hello Joby,
My problem is not getting user name and logging in but
rather I can't get the user's role using the function
isUserInRole().  For whatever reason isUserInRole
always returns a false.  I tried
isUserInRole(admin), isUserInRole(Administrarors),
isUserInRole(Users) but I get false for all of them.
 

I am trying to restrict some web pages  to only allow
administrator access.  I can't put the user name and
role in an xml file or using a database because of my
company's security policy.  I have to get the data
from NTLM. 

Thanks again for your help.


Forwarded Message
Subject:RE: isUserInRole
Date:   Mon, 7 Feb 2005 08:46:40 +0530
From:   [EMAIL PROTECTED]
To: tomcat-user@jakarta.apache.org

Plain Text Attachment [ Download File | Save to my
Yahoo! Briefcase ]


Hi Denny,

To get user name... do as follows...
%@ page import=java.security.Principal %
And use in ur code as...
% Principal p = request.getUserPrincipal();
 out.println(p.getName()); %
will print the name of the current user...



Joby Joseph
Wipro Technologies
Plot No.72, KEONICS Electronics City,
Hosur Main Road,
Bangalore- 560 100. India
Tel:+91-80-28520408; 5122  Extn:82332
www.wipro.com

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



Re: **CONFIDENTIAL** Configuring Log4j in webapps

2005-02-07 Thread Parsons Technical Services
Sounds like a rights issue on the server. Make sure that the user that 
tomcat is running with has the needed rights on the directory.

If it is running as a service, you can still have a rights problem.
If at some point in the path you do not have the proper rights, it can 
prevent the use of relative paths.

How are you starting Tomcat? Service or user?
Doug
- Original Message - 
From: Ethan Cabiac [EMAIL PROTECTED]
To: tomcat-user@jakarta.apache.org
Sent: Monday, February 07, 2005 9:23 AM
Subject: **CONFIDENTIAL** Configuring Log4j in webapps


Hi everyone,
I don't know if this is a Log4j problem or a Tomcat related issue but 
I
am posting here first because I already subscribe to this mailing list ;).
I have two (theoretically) identical Tomcat webservers (Tomcat 5.0), one 
on
my local WinXP machine for dev/testing and one on the company's Win 2003
Server machine for production.  When I setup my log4j files in my webapps 
I
use:

log4j.appender.A1.File=../logs/mywebapplog.log
On my test machine this will work perfectly and even create the log file 
on
Tomcat startup if it does not exist. On my production database it will not
work if I use relative path, I actually have to specify
C:/path_to_logs/mywebapplog.log and if the file is not there already then
Tomcat complains on startup and no log gets written for the webapp.  Like 
I
said, the two Tomcats are supposed to be identical, but maybe there is a
configuration discrepancy I missed, or maybe this is a Log4j thing? Any 
help
is appreciated.

-Ethan Cabiac
--
This message (including any attachments) contains confidential information
intended for a specific individual and purpose, and is protected by law.
If you are the intended recipient, this message is CONFIDENTIAL as per 
Contract.
This message should not be disseminated to 3rd parties without prior 
written
approval or consent from a Director of TRAX. Violation of Contract 
Terms constitute
a breach and be cause for termination.

If you are NOT the intended recipient, you should delete this message 
and are hereby
notified that any disclosure, copying, or distribution of this 
message, or
the taking of any action based on it, is strictly prohibited. 

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


Re: jsp version of session variable access. Pointer to syntax wanted.

2005-02-07 Thread Tim Funk
Via EL: (assuming sessionData.FILECOUNT = mySessionVariableName)
${sessionContext.mySessionVariableName}
Via snippet:
%=session.getAttribute(sessionData.FILECOUNT)%
In a jsp - the session variable is given to you as implicit variable.
-Tim
Pawson, David wrote:
Looking for the syntax to gain access to a session variable
in a jsp page, rather than converting it to java.
HttpSession session=request.getSession();
String s = (String)session.getAttribute(sessionData.FILECOUNT);
I'm not using the xml syntax (as yet).
tomcat 5028.
any pointers appreciated please.
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


Status of Bug 24970

2005-02-07 Thread Rob Tomlin
Hi,
I'm running tomcat 5.0.28 and have been hit by bug 24970:
http://issues.apache.org/bugzilla/show_bug.cgi?id=24970
I've looked at the source for Response.java and the commit comments seem to 
suggest this bug keeps being fixed and reintroduced. I'm a little confused 
about which version I can expect this bug to actually be fixed in...or if is 
fixed at all...or if it will be fixed...

1. Can someone confirm which version of Tomcat this bug is fixed in. If its 
shown in the bug page I can't see it...

2. Is there a work around other than patching a jar?
Thanks
Rob Tomlin
_
Want to block unwanted pop-ups? Download the free MSN Toolbar now!  
http://toolbar.msn.co.uk/

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


Re: Status of Bug 24970

2005-02-07 Thread Markus Schönhaber
Rob Tomlin wrote:
http://issues.apache.org/bugzilla/show_bug.cgi?id=24970
I've looked at the source for Response.java and the commit comments seem 
to suggest this bug keeps being fixed and reintroduced. I'm a little 
confused about which version I can expect this bug to actually be fixed 
in...or if is fixed at all...or if it will be fixed...

Well, the bug status is marked as RESOLVED with the resolution WONTFIX.
1. Can someone confirm which version of Tomcat this bug is fixed in. If 
its shown in the bug page I can't see it...

2. Is there a work around other than patching a jar?
As I understand the bugzilla comments it boils down to: don't use a JSP, 
use a servlet, and don't use a Writer in this servlet but an OutputStream.

http://issues.apache.org/bugzilla/show_bug.cgi?id=24970#c25
Regards
  mks
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


Re: Status of Bug 24970

2005-02-07 Thread Markus Schönhaber
Markus Schönhaber wrote:
As I understand the bugzilla comments it boils down to: don't use a JSP, 
use a servlet, and don't use a Writer in this servlet but an OutputStream.

http://issues.apache.org/bugzilla/show_bug.cgi?id=24970#c25
Well, writing a filter that removes the ;charset=... part from
Content-type: application/pdf header might work as a quick hack. But I
wouldn't call this a solution.
Regards
  mks
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


Re: **CONFIDENTIAL** Configuring Log4j in webapps

2005-02-07 Thread Jacob Kjome

A rights problem is posssible, but unlikely given that the OS is some version of
Windows.  However, if the server that isn't working is running as a service,
the default location for a relatively defined log file would be in
C:\winnt\System32, which means your log file would be at
C:\winnt\logs\mywebapplog.log (assuming the FileAppender would create the
logs directory if it didn't exist already (I don't think it does).  The
reason it would work when running Tomcat's startup.bat file is that VM would
have been started up in CATALINA_HOME\bin, so the location of the relatively
defined log file would actually end up in CATALINA_HOME\logs.  Make sense? 
Relatively defined paths will be relative to the directory where the VM started
from.  Services start from C:\winnt\System32 by default.

This can be solved in one of two ways...

1.  Use ${catalina.home}/logs/mywebapp.log.  Tomcat generates this system
property upon startup, and you can reference it in your config file

2.  Tomcat's service can change the location of where the VM is started from. 
Just double click on tomcat5w.exe to see all the options.  Change the startup
location to wherever CATALINA_HOME\bin is to normalize it with starting Tomcat
using CATALINA_HOME\bin\startup.bat


Jake

Quoting Parsons Technical Services [EMAIL PROTECTED]:

 Sounds like a rights issue on the server. Make sure that the user that
 tomcat is running with has the needed rights on the directory.

 If it is running as a service, you can still have a rights problem.

 If at some point in the path you do not have the proper rights, it can
 prevent the use of relative paths.

 How are you starting Tomcat? Service or user?

 Doug


 - Original Message -
 From: Ethan Cabiac [EMAIL PROTECTED]
 To: tomcat-user@jakarta.apache.org
 Sent: Monday, February 07, 2005 9:23 AM
 Subject: **CONFIDENTIAL** Configuring Log4j in webapps


  Hi everyone,
 
  I don't know if this is a Log4j problem or a Tomcat related issue but
  I
  am posting here first because I already subscribe to this mailing list ;).
  I have two (theoretically) identical Tomcat webservers (Tomcat 5.0), one
  on
  my local WinXP machine for dev/testing and one on the company's Win 2003
  Server machine for production.  When I setup my log4j files in my webapps
  I
  use:
 
  log4j.appender.A1.File=../logs/mywebapplog.log
 
  On my test machine this will work perfectly and even create the log file
  on
  Tomcat startup if it does not exist. On my production database it will not
  work if I use relative path, I actually have to specify
  C:/path_to_logs/mywebapplog.log and if the file is not there already then
  Tomcat complains on startup and no log gets written for the webapp.  Like
  I
  said, the two Tomcats are supposed to be identical, but maybe there is a
  configuration discrepancy I missed, or maybe this is a Log4j thing? Any
  help
  is appreciated.
 
  -Ethan Cabiac
 
 
 
 --
  This message (including any attachments) contains confidential information
  intended for a specific individual and purpose, and is protected by law.
 
  If you are the intended recipient, this message is CONFIDENTIAL as per
  Contract.
  This message should not be disseminated to 3rd parties without prior
  written
  approval or consent from a Director of TRAX. Violation of Contract
  Terms constitute
  a breach and be cause for termination.
 
  If you are NOT the intended recipient, you should delete this message
  and are hereby
  notified that any disclosure, copying, or distribution of this
  message, or
  the taking of any action based on it, is strictly prohibited.



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





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



Re: How to get english messages on a German Windows-XP?

2005-02-07 Thread Mario Winterer
I think Java uses the Locale from your operating system.
So to switch to english, you should either:
+ switch the locale of your operating system
+ tell Java to use another locale via system.properties at tomcat 
startup (jvm-property):

-Duser.language=language-code -Duser.country=country-code 
-Duser.variant=variant

e.g.: -Duser.language=en -Duser.country=US
Best regards,
 Tex
Zsolt Koppany schrieb:
Hi,
This is probably a java and not a tc question, but I would like to know how
to get English java error messages when I start tc on a German windows XP
box.
Zsolt

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


JTDS help

2005-02-07 Thread Charles P. Killmer
I am trying to get Tomcat talking to my database quickly.  This code
takes about 2-3 seconds to load.  Anyone got any idea's why?  Or if you
run this in your environment, how well does it run?
 
%@ page language=java import=java.sql.*%
%
Connection conn =
DriverManager.getConnection(jdbc:jtds:sqlserver://*.*.*.*:1433/dbname;u
ser=**;password=***);
 
Statement stmt = conn.createStatement(ResultSet.TYPE_FORWARD_ONLY,
ResultSet.CONCUR_READ_ONLY);
ResultSet rs;
 
rs = stmt.executeQuery(SELECT * FROM accounts);
 
out.println(table);
String name;
String ID;
while (rs.next()) {
   name = rs.getString(Name);
   ID = rs.getString(ID);
   out.println(trtd + ID + /tdtd+name+/td/tr );
}
 
out.println( /table );
 
conn.close();
%
 
This is just a JSP script, nothing is compiled.  I know it is better to
compile, but I am trying to chase down this DB slowness first.
 
Charles Killmer
Netgain Technology
[EMAIL PROTECTED]
Office: (320) 251-4700 ext 107
 


MemoryError: PermGen space after several redeployments

2005-02-07 Thread Matthew Patton
Hi,
	I am using Tomcat 5.5.4 on Linux.  I am new to Tomcat and have a 
simple web application which I have been developing and testing in Tomcat. 
When I deploy, I create the war file, and copy it to Tomcat's webapps 
directory, at which point Tomcat automatically detects the new war file 
and deploys the web app.
	However, after a dozen or so redeployments, I get the following in 
the midst of the deployment:

MemoryError: PermGen space
java.lang.OutOfMemoryError: PermGen space
When I stop Tomcat and start it up again, it works fine until I have 
redeployed a dozen times, at which point I get the same error.  Why is 
this happening?  Am I not redeploying properly?  It seems like a memory 
lead in Tomcat's deployer.

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


RE: JTDS help

2005-02-07 Thread Allistair Crossley
Hi,

There's no real reason relating to Tomcat or jTDS that this would run slow. You 
are more likely to find answers with your hardware, network latency, database 
load or row size and other environmental factors.

Allistair.

 -Original Message-
 From: Charles P. Killmer [mailto:[EMAIL PROTECTED]
 Sent: 07 February 2005 17:34
 To: Tomcat Users List
 Subject: JTDS help
 
 
 I am trying to get Tomcat talking to my database quickly.  This code
 takes about 2-3 seconds to load.  Anyone got any idea's why?  
 Or if you
 run this in your environment, how well does it run?
  
 %@ page language=java import=java.sql.*%
 %
 Connection conn =
 DriverManager.getConnection(jdbc:jtds:sqlserver://*.*.*.*:143
 3/dbname;u
 ser=**;password=***);
  
 Statement stmt = conn.createStatement(ResultSet.TYPE_FORWARD_ONLY,
 ResultSet.CONCUR_READ_ONLY);
 ResultSet rs;
  
 rs = stmt.executeQuery(SELECT * FROM accounts);
  
 out.println(table);
 String name;
 String ID;
 while (rs.next()) {
name = rs.getString(Name);
ID = rs.getString(ID);
out.println(trtd + ID + /tdtd+name+/td/tr );
 }
  
 out.println( /table );
  
 conn.close();
 %
  
 This is just a JSP script, nothing is compiled.  I know it is 
 better to
 compile, but I am trying to chase down this DB slowness first.
  
 Charles Killmer
 Netgain Technology
 [EMAIL PROTECTED]
 Office: (320) 251-4700 ext 107
  
 


FONT SIZE=1 FACE=VERDANA,ARIAL COLOR=BLUE 
---
QAS Ltd.
Developers of QuickAddress Software
a href=http://www.qas.com;www.qas.com/a
Registered in England: No 2582055
Registered in Australia: No 082 851 474
---
/FONT


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



RE: JTDS help

2005-02-07 Thread Charles P. Killmer
Network results
Ping statistics for *.*.*.*:
Packets: Sent = 140, Received = 140, Lost = 0 (0% loss),
Approximate round trip times in milli-seconds:
Minimum = 0ms, Maximum = 0ms, Average = 0ms 

Query Analyzer returns 85 rows in 0 seconds.  I modified it to only
return Name and ID and it still runs slow.  So it cant be row size,
network latency, hardware should be ruled out by the fact that it runs
super fast through query analyzer, and PHP and ASP.NET.  Its only when I
write the code in JSP for Tomcat that it slows down.

Charles


-Original Message-
From: Allistair Crossley [mailto:[EMAIL PROTECTED] 
Sent: Monday, February 07, 2005 11:37 AM
To: Tomcat Users List
Subject: RE: JTDS help

Hi,

There's no real reason relating to Tomcat or jTDS that this would run
slow. You are more likely to find answers with your hardware, network
latency, database load or row size and other environmental factors.

Allistair.

 -Original Message-
 From: Charles P. Killmer [mailto:[EMAIL PROTECTED]
 Sent: 07 February 2005 17:34
 To: Tomcat Users List
 Subject: JTDS help
 
 
 I am trying to get Tomcat talking to my database quickly.  This code
 takes about 2-3 seconds to load.  Anyone got any idea's why?  
 Or if you
 run this in your environment, how well does it run?
  
 %@ page language=java import=java.sql.*%
 %
 Connection conn =
 DriverManager.getConnection(jdbc:jtds:sqlserver://*.*.*.*:143
 3/dbname;u
 ser=**;password=***);
  
 Statement stmt = conn.createStatement(ResultSet.TYPE_FORWARD_ONLY,
 ResultSet.CONCUR_READ_ONLY);
 ResultSet rs;
  
 rs = stmt.executeQuery(SELECT * FROM accounts);
  
 out.println(table);
 String name;
 String ID;
 while (rs.next()) {
name = rs.getString(Name);
ID = rs.getString(ID);
out.println(trtd + ID + /tdtd+name+/td/tr );
 }
  
 out.println( /table );
  
 conn.close();
 %
  
 This is just a JSP script, nothing is compiled.  I know it is 
 better to
 compile, but I am trying to chase down this DB slowness first.
  
 Charles Killmer
 Netgain Technology
 [EMAIL PROTECTED]
 Office: (320) 251-4700 ext 107
  
 


FONT SIZE=1 FACE=VERDANA,ARIAL COLOR=BLUE 
---
QAS Ltd.
Developers of QuickAddress Software
a href=http://www.qas.com;www.qas.com/a
Registered in England: No 2582055
Registered in Australia: No 082 851 474
---
/FONT


-
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: JTDS help

2005-02-07 Thread Mario Winterer
I think the main time is spent on opening the database connection!
So you better use connection pooling - then this expensive operation is 
just execute once (or at least not so often)
Have a look at the Tomcat documentation (Section on JNDI-DataSources)

Tex
Charles P. Killmer wrote:
I am trying to get Tomcat talking to my database quickly.  This code
takes about 2-3 seconds to load.  Anyone got any idea's why?  Or if you
run this in your environment, how well does it run?
%@ page language=java import=java.sql.*%
%
Connection conn =
DriverManager.getConnection(jdbc:jtds:sqlserver://*.*.*.*:1433/dbname;u
ser=**;password=***);
Statement stmt = conn.createStatement(ResultSet.TYPE_FORWARD_ONLY,
ResultSet.CONCUR_READ_ONLY);
ResultSet rs;
rs = stmt.executeQuery(SELECT * FROM accounts);
out.println(table);
String name;
String ID;
while (rs.next()) {
  name = rs.getString(Name);
  ID = rs.getString(ID);
  out.println(trtd + ID + /tdtd+name+/td/tr );
}
out.println( /table );
conn.close();
%
This is just a JSP script, nothing is compiled.  I know it is better to
compile, but I am trying to chase down this DB slowness first.
Charles Killmer
Netgain Technology
[EMAIL PROTECTED]
Office: (320) 251-4700 ext 107
 


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


Solaris 10 Tomcat 5.5.7

2005-02-07 Thread Chad Kellerman
Tomcat Users,
   I thought I would test out Tomcat 5.5.7 on a Solaris 10 (Ultra 60) so see 
how it performs.

Here is what I did.

edited /etc/profile
JAVA_HOME=/usr/java
export JAVA_HOME

exploded the tar ball in /opt/
then created a link to jakarta.XX.XX name tomcat

I started tomcat, it started but there are messages in the catalina.out file 
that don't make sense.

catalina.out
SEVERE: Exception starting filter Compression Filter
java.lang.ClassNotFoundException: compressionFilters.CompressionFilter

Then I tried to go to the example pages on http://localhost:8080/jsp-examples/
and recieved an error.

Feb 7, 2005 11:12:09 AM org.apache.catalina.core.StandardWrapperValve invoke
SEVERE: Allocate exception for servlet 
org.apache.jsp.jsp2.el.basic_002darithmetic_jsp
javax.servlet.ServletException: Wrapper cannot find servlet class 
org.apache.jsp.jsp2.el.basic_002darithmetic_jsp or a class it depends on

I have java 1.5.0_01 and Tomcat 5.5 installed on a Fedora server and 
everything works fine, but the java on the SOlaris server seems to mess 
things up a bit.

Anyone else see this?  Anyone else have a fix?


Thanks,
Chad



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



RE: tomcat CPU utilization pegged...total CPU only 50%

2005-02-07 Thread Kevin Williams
Ok,

Thanks all for the help.  I further optimized the environment while
troubleshooting.  In case anyone else is in a similar issue, I'll list
the solution that worked for me--turn off hyperthreading.  The two Xeon
CPU's are hyperthreaded to represent 4 CPU's on the machine.  I'm not
sure exactly how tomcat/java interact with this, but it was not
favorable.  A coworker mentioned that the windows performance monitor
often records total CPU utilization incorrectly due to the logical split
of the CPU's acting as 4 instead of 2.  Disabling the hyperthreading in
the system bios shot the CPU utilization up to 70%-90% (I imagine the
other 10% of CPU is being reserved by other applications).

Thanks again for the help,

Kevin Williams


-Original Message-
From: news [mailto:[EMAIL PROTECTED] On Behalf Of Vic
Sent: Thursday, February 03, 2005 9:09 PM
To: tomcat-user@jakarta.apache.org
Subject: Re: tomcat CPU utilization pegged...total CPU only 50%
[bcc][faked-from][bayes]
Importance: Low

You could be DB bound or LAN bound.
What is the switch telling you LAN utilization is?
What is the DB stress test telling you?
.V

Kevin Williams wrote:

Hello,

 

I am trying to performance test an application running Tomcat with
Apache w/SSL (connected using mod_proxy).  The OS is Windows Server
2003.

 

The test I am running is simulating a user logging into the application
(using JMeter for the testing framework).  Increasing the number of
users from 1, 2, 3, 4,5 the total CPU utilization jumps considerably.
After 5 users the CPU utilization hits 50% for a second and then
drops...When simulating 10 users, the CPU hits50% for a few seconds and
drops back down, the more users, the longer the CPU is pegged at 50%.
My question is why is tomcat only using 50% of the CPU?  Seeing the CPU
grow significantly with each user, and then peg out for longer periods
of time with an increased user load indicates that the CPU is the choke
point.  Using performance monitor, the Tomcat % Processor Time pegs out
at 100% for the duration that total CPU utilization is at 50%.  Is
there
a configuration option that I am unaware of to allow tomcat to use more
CPU?

 

Thanks in advance!

 

Kevin


  



-- 
Forums, Boards, Blogs and News in RiA http://www.boardVU.com


-
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: outOfMemory exception under high load

2005-02-07 Thread David Wood
Once you rule out your heap and perm generation, you can look at thread 
stacks.

Under high loads, you create a lot of threads. There are variations 
depending on the host OS and VM, but in a 32-bit operating system with 
thread stacks in the 1-4 MB range and a big heap, you can easily run out 
of virtual address space. In addition, I'm not sure if there aren't some 
cases where thread stacks are allocated reserved, which means you could 
also get an OOME from not having enough swap space.

If you think this might be it, try tuning your thread pools (lower the max 
pool size), lowering perm gen size, heap size, switching to 64-bit, adding 
swap...

Dale, Matt [EMAIL PROTECTED] wrote on 02/07/2005 07:34:36 AM:

 
 In that case then it sounds like either a memory leak or you just 
 don't have enough memory to support your application. Do you have 
 large objects in your sessions?
 
 I'd get a profilier and find out what objects are in your heap when 
 you get the exceptions and it should lead you to the root cause of 
 your problem.
 
 Ta
 Matt
 
 -Original Message-
 From: Michael Cornell [mailto:[EMAIL PROTECTED]
 Sent: 07 February 2005 12:01
 To: Tomcat Users List
 Subject: Re: outOfMemory exception under high load
 
 
 Hi,
 
 RE Matt:
 //
 I am already running visualgc (jvmstat) on it... the behavior is just
 that the heap fills up (no gc) and then at about 80% full it just bombs
 out.  Perm Gen is only 20% full and none of the others are used..
 
 RE reynir:
 Why are you setting these paremeters :
 -Xmn384m -XX:SurvivorRatio=7 -XX:PermSize=64m
 -XX:MaxPermSize=128m -Xint
 
 I usually only set the -Xmx and -server
 //
 The Permsize params have been put in in case that was the problem
 (running out of perm space) and the -Xint as this makes it run without
 any optimisations (I believe) ie all interpreted.
 Xmn  is the New Generation= (eden) + (from + to) and survivor ratio is
 just that.. the ratio of eden - survivors
 I can see no reason why these should mess anything up sufficiently to
 produce this error.
 
 
 
 
 Dale, Matt wrote:
 
 It could be your permanent generation that is running out of space.
 Get a hold of jvmstat to determine if this is the case.
 
 Ta
 Matt
 
 -Original Message-
 From: Michael Cornell [mailto:[EMAIL PROTECTED]
 Sent: 07 February 2005 11:31
 To: Tomcat Users List
 Subject: Re: outOfMemory exception under high load
 
 
 
 Sorry, that was a copy and paste typo :(  Its set at 2G (4G for the
 whole machine)
 /m
 
 reynir wrote:
 
  
 
 well, your -Xmx1G set's the limit for memory usage at 1 gig.  ?
 -server -Xms1G -Xmx1G -Xmn384m -XX:SurvivorRatio=7 -XX:PermSize=64m
 -XX:MaxPermSize=128m -Xint
 
 you might want to set that a little higher.
 
 
 Michael Cornell wrote:
 
  
 
 Not exactly sure but by running vmstat, it look like I am nearing the 
2G
 limit .. maybe about 1.8G consumed..
 
 /m
 
 reynir wrote:
 
  
 
  
 
 how much memory is your process using when it crashes ?
 -r
 
 
 Michael Cornell wrote:
 
  
 
  
 
 Hi,
 
 Hi,
 
 I am experiencing a problem many others seem to have had before, 
but
 have found no answers.  I am running Tomcat 5.0.25 using jdk 
1.4.2_06
 hotspot vm on RedHat Linux ES with 4G Ram and twin Intel procs.
 
 When load-testing, under high stress I receive the error below and 
the
 thread dies.
 
 04-Feb-2005 13:39:24 org.apache.coyote.tomcat5.CoyoteAdapter 
service
 SEVERE: An exception or error occurred in the container during the
 request processing
 java.lang.OutOfMemoryError
   at java.util.zip.ZipFile.open(Native Method)
   at java.util.zip.ZipFile.init(ZipFile.java:112)
   at java.util.jar.JarFile.init(JarFile.java:127)
 ..
 
 I have adjusted the vm parameters to the below ( the perm space
 does not
 get full and the Xint to not use the optimised settings..
 -server -Xms1G -Xmx1G -Xmn384m -XX:SurvivorRatio=7 -XX:PermSize=64m
 -XX:MaxPermSize=128m -Xint
 
 In addition I have added the  reloading=false and
 development=false in
 conf/web.xml.  as per instruction from this thread:
 http://www.junlu.com/msg/78566.html
 
 My connector is configured thus:
  Connector
  port=80
  maxThreads=1000
  minSpareThreads=1000
  maxSpareThreads=1000
  enableLookups=false
  redirectPort=8443
  acceptCount=3000
  debug=0
  connectionTimeout=2
  disableUploadTimeout=true /
 
 
 However all of this is to no avail, and under high stress (80+
 concurrent requests, tomcat dies and terminates the thread dumping 
a
 hs_pid12345.log with  the above message
 
 Is this a known hotspot 1.4.x problem (some threads have hinted at
 this), or does someone have a solution for this??
 
 Thanks,
 
 M
 
 
-
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: 
[EMAIL PROTECTED]
 
 
 
  
  
 
 

exception logging in tomcat 5.5

2005-02-07 Thread Christian Sell
Hello,

I just installed Tomcat 5.5.7 and ran my first webapp. I was rather disturbed
that exception information only appeared on the default error page, but nowhere
in the logs! In fact, in the out-of-the-box install, there were no logs written
at all!

I went through the docs and found a description of a rather complicated
configuration process that would supposedly bring back the normal log (it
involves copying 2 jar files and creating and copying one property file to the
tomcat/common directory).
However, since the docs say that stack trace info is written to stdout only, my
hopes are not high for success with this - I thought I would rather go ask
here. As I said, uncaught exceptions thrown from within my webapp (different
places, e.g. a servlet filter) are not written to stdout (if that is what I see
on the console). They only appear on the exception page - which is the one
place where I dont need them on the long run.

Can anyone help? Why has this been done?

thanks,
Christian

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



RE: Updating running WARs?

2005-02-07 Thread David Wood
I'm sorry, I'm confused. Once you created a context.xml in your WARs, what 
were your steps to update a running application? 

Mitchell K. McCuiston [EMAIL PROTECTED] wrote on 02/07/2005 
10:40:18 AM:

 Try configuring your app context inside of the META-INF/context.xml 
inside
 of your war instead of your server.xml.  I had the same problem and this
 seemed to fix it.
 
 -Original Message-
 From: David Wood [mailto:[EMAIL PROTECTED]
 Sent: Friday, February 04, 2005 3:15 PM
 To: tomcat-user@jakarta.apache.org
 Subject: Updating running WARs?
 
 
 What's the right way to update a running WAR in Tomcat 5.5?
 
 Is there anything resembling the manager's reload feature for WARs? Or
 are we forced to remove the context via the manager and then re-add a 
new
 context back in? (Or restart Tomcat?)
 
 I've been searching through documentation for the manager, and then
 looking a bit at the source code, and it seems like it's impossible to
 reload a context unless it's exploded.
 
 
 


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



Re: Solaris 10 Tomcat 5.5.7

2005-02-07 Thread Remy Maucherat
On Mon, 7 Feb 2005 12:55:56 -0500, Chad Kellerman
[EMAIL PROTECTED] wrote:
 Tomcat Users,
I thought I would test out Tomcat 5.5.7 on a Solaris 10 (Ultra 60) so see
 how it performs.
 
 Here is what I did.
 
 edited /etc/profile
 JAVA_HOME=/usr/java
 export JAVA_HOME
 
 exploded the tar ball in /opt/
 then created a link to jakarta.XX.XX name tomcat
 
 I started tomcat, it started but there are messages in the catalina.out file
 that don't make sense.
 
 catalina.out
 SEVERE: Exception starting filter Compression Filter
 java.lang.ClassNotFoundException: compressionFilters.CompressionFilter
 
 Then I tried to go to the example pages on http://localhost:8080/jsp-examples/
 and recieved an error.
 
 Feb 7, 2005 11:12:09 AM org.apache.catalina.core.StandardWrapperValve invoke
 SEVERE: Allocate exception for servlet
 org.apache.jsp.jsp2.el.basic_002darithmetic_jsp
 javax.servlet.ServletException: Wrapper cannot find servlet class
 org.apache.jsp.jsp2.el.basic_002darithmetic_jsp or a class it depends on
 
 I have java 1.5.0_01 and Tomcat 5.5 installed on a Fedora server and
 everything works fine, but the java on the SOlaris server seems to mess
 things up a bit.
 
 Anyone else see this?  Anyone else have a fix?

Did you use GNU TAR to extract the .tar.gz ?

-- 
x
Rémy Maucherat
Developer  Consultant
JBoss Group (Europe) SàRL
x

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



Re: JTDS help

2005-02-07 Thread David Smith
Ok.  You're doing this in a jsp.  That means Tomcat is:
1) Compiling your jsp to a servlet class.
2) Building a connection from scratch as opposed to picking up a pooled 
connection
3) Running the query.

Of these, the first one is the most expensive operation followed by 
two.  If you want fast, try
doing this with a pooled connection and from compiled servlet code.

--David
Charles P. Killmer wrote:
Network results
Ping statistics for *.*.*.*:
   Packets: Sent = 140, Received = 140, Lost = 0 (0% loss),
Approximate round trip times in milli-seconds:
   Minimum = 0ms, Maximum = 0ms, Average = 0ms 

Query Analyzer returns 85 rows in 0 seconds.  I modified it to only
return Name and ID and it still runs slow.  So it cant be row size,
network latency, hardware should be ruled out by the fact that it runs
super fast through query analyzer, and PHP and ASP.NET.  Its only when I
write the code in JSP for Tomcat that it slows down.
Charles
-Original Message-
From: Allistair Crossley [mailto:[EMAIL PROTECTED] 
Sent: Monday, February 07, 2005 11:37 AM
To: Tomcat Users List
Subject: RE: JTDS help

Hi,
There's no real reason relating to Tomcat or jTDS that this would run
slow. You are more likely to find answers with your hardware, network
latency, database load or row size and other environmental factors.
Allistair.
 

-Original Message-
From: Charles P. Killmer [mailto:[EMAIL PROTECTED]
Sent: 07 February 2005 17:34
To: Tomcat Users List
Subject: JTDS help
I am trying to get Tomcat talking to my database quickly.  This code
takes about 2-3 seconds to load.  Anyone got any idea's why?  
Or if you
run this in your environment, how well does it run?

%@ page language=java import=java.sql.*%
%
Connection conn =
DriverManager.getConnection(jdbc:jtds:sqlserver://*.*.*.*:143
3/dbname;u
ser=**;password=***);
Statement stmt = conn.createStatement(ResultSet.TYPE_FORWARD_ONLY,
ResultSet.CONCUR_READ_ONLY);
ResultSet rs;
rs = stmt.executeQuery(SELECT * FROM accounts);
out.println(table);
String name;
String ID;
while (rs.next()) {
  name = rs.getString(Name);
  ID = rs.getString(ID);
  out.println(trtd + ID + /tdtd+name+/td/tr );
}
out.println( /table );
conn.close();
%
This is just a JSP script, nothing is compiled.  I know it is 
better to
compile, but I am trying to chase down this DB slowness first.

Charles Killmer
Netgain Technology
[EMAIL PROTECTED]
Office: (320) 251-4700 ext 107
   


FONT SIZE=1 FACE=VERDANA,ARIAL COLOR=BLUE 
---
QAS Ltd.
Developers of QuickAddress Software
a href=http://www.qas.com;www.qas.com/a
Registered in England: No 2582055
Registered in Australia: No 082 851 474
---
/FONT

-
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: exception logging in tomcat 5.5

2005-02-07 Thread David Smith
Standard out in tomcat is usually redirected to a file 'catalina.out' in 
the logs directory of tomcat.

--David
Christian Sell wrote:
Hello,
I just installed Tomcat 5.5.7 and ran my first webapp. I was rather disturbed
that exception information only appeared on the default error page, but nowhere
in the logs! In fact, in the out-of-the-box install, there were no logs written
at all!
I went through the docs and found a description of a rather complicated
configuration process that would supposedly bring back the normal log (it
involves copying 2 jar files and creating and copying one property file to the
tomcat/common directory).
However, since the docs say that stack trace info is written to stdout only, my
hopes are not high for success with this - I thought I would rather go ask
here. As I said, uncaught exceptions thrown from within my webapp (different
places, e.g. a servlet filter) are not written to stdout (if that is what I see
on the console). They only appear on the exception page - which is the one
place where I dont need them on the long run.
Can anyone help? Why has this been done?
thanks,
Christian
-
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]


[OT] - distribution graph of tomcat results

2005-02-07 Thread Peter Lin
I generated a combined graph of the response time for tomcat 5.5.4 in
client mode.

http://cvs.apache.org/~woolfel/combined_graph.png


thought some people might find it interesting. the graphs were
generated by Jmeter.


peter

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



IE converts file.jpg to file_jpg when saving

2005-02-07 Thread Brad Hafichuk
This problem has been bugging me for at least 6 months. I finally noticed
that IE6 is converting the dot (.) in file.jpg to an underscore (_).

Has anyone experienced this very odd behaviour before?

 

I should point out that I am sending the file back to the client via a
servlet, the process being.

 

Load file into memory (as bytes) and close fileinputstream

Get mimetype of file

Set responses mimetype

Set response content-disposition (header) to attachment and
filename=file.jpg

Get response OutputStream

Write loaded file (bytes) to outputstream

Flush and close outputstream

 

I can post the exact code if needed. I'm running Tomcat 4.1.30.

 

Cheers,

Brad

 



Re: Memory leak in tomcat 5.0.28

2005-02-07 Thread Trond G. Ziarkowski
Thank you Robert!!
Just wanna say thanks alot for sharing all your findings with the rest 
of us. I start my tomcat 5.0.28 server with -ms252m -mx512m and it was 
running for about 3-4 days before i got the OutOfMemoryError. Since i 
removed the swallowOutput from my context, my server has'nt been over 
200m of used memory for 5 days!!

Once again thank you for finding this leak.
Regards
Trond
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


RE: How to get english messages on a German Windows-XP?

2005-02-07 Thread Zsolt Koppany
Thank you for this interesting info but in javadoc for jvm-1.4.2 I found
only the follow system properties:


user.name   User's account name
user.home   User's home directory
user.dirUser's current working directory


Zsolt

 -Original Message-
 From: Mario Winterer [mailto:[EMAIL PROTECTED]
 Sent: Monday, February 07, 2005 6:30 PM
 To: Tomcat Users List
 Subject: Re: How to get english messages on a German Windows-XP?
 
 I think Java uses the Locale from your operating system.
 So to switch to english, you should either:
 + switch the locale of your operating system
 + tell Java to use another locale via system.properties at tomcat
 startup (jvm-property):
 
 -Duser.language=language-code -Duser.country=country-code
 -Duser.variant=variant
 
 e.g.: -Duser.language=en -Duser.country=US
 
 Best regards,
   Tex
 
 Zsolt Koppany schrieb:
 
 Hi,
 
 This is probably a java and not a tc question, but I would like to know
 how
 to get English java error messages when I start tc on a German windows XP
 box.
 
 Zsolt
 
 
 
 
 -
 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: JTDS help

2005-02-07 Thread Mario Winterer
I do not think, jsp compilation is the problem - well, the first request 
will last long, but after the jsp is compiled, subsequent calls will not 
be remarkable slower than executing pure compiled servlet code.
(Charles, I hope you did not measure the time for the first request only 
- which indeed includes compilation time, but for subsequent calls too).
So to me opening the connection is the major problem. Because the code 
itself contains html-output, I think using jsp is quite ok.
The code would be much cleaner, if Charles used the JSTL tag-library:

%@ page language=java%
%@ taglib prefix=c uri=http://java.sun.com/jstl/core; %
%@ taglib prefix=sql uri=http://java.sun.com/jstl/sql; %
sql:query sql=SELECT * FROM accounts var=accounts 
dataSource=jndi/myDataSource/
table
c:forEach var=acc items=${accounts}
tr
tdc:out value=${acc.ID}//td
tdc:out value=${acc.Name}//td
/tr
/c:forEach
/table

Best regards,
Tex
David Smith wrote:
Ok. You're doing this in a jsp. That means Tomcat is:
1) Compiling your jsp to a servlet class.
2) Building a connection from scratch as opposed to picking up a 
pooled connection
3) Running the query.

Of these, the first one is the most expensive operation followed by 
two. If you want fast, try
doing this with a pooled connection and from compiled servlet code.

--David
Charles P. Killmer wrote:
Network results
Ping statistics for *.*.*.*:
Packets: Sent = 140, Received = 140, Lost = 0 (0% loss),
Approximate round trip times in milli-seconds:
Minimum = 0ms, Maximum = 0ms, Average = 0ms
Query Analyzer returns 85 rows in 0 seconds. I modified it to only
return Name and ID and it still runs slow. So it cant be row size,
network latency, hardware should be ruled out by the fact that it runs
super fast through query analyzer, and PHP and ASP.NET. Its only when I
write the code in JSP for Tomcat that it slows down.
Charles
-Original Message-
From: Allistair Crossley [mailto:[EMAIL PROTECTED] Sent: 
Monday, February 07, 2005 11:37 AM
To: Tomcat Users List
Subject: RE: JTDS help

Hi,
There's no real reason relating to Tomcat or jTDS that this would run
slow. You are more likely to find answers with your hardware, network
latency, database load or row size and other environmental factors.
Allistair.

-Original Message-
From: Charles P. Killmer [mailto:[EMAIL PROTECTED]
Sent: 07 February 2005 17:34
To: Tomcat Users List
Subject: JTDS help
I am trying to get Tomcat talking to my database quickly. This code
takes about 2-3 seconds to load. Anyone got any idea's why? Or if you
run this in your environment, how well does it run?
%@ page language=java import=java.sql.*%
%
Connection conn =
DriverManager.getConnection(jdbc:jtds:sqlserver://*.*.*.*:143
3/dbname;u
ser=**;password=***);
Statement stmt = conn.createStatement(ResultSet.TYPE_FORWARD_ONLY,
ResultSet.CONCUR_READ_ONLY);
ResultSet rs;
rs = stmt.executeQuery(SELECT * FROM accounts);
out.println(table);
String name;
String ID;
while (rs.next()) {
name = rs.getString(Name);
ID = rs.getString(ID);
out.println(trtd + ID + /tdtd+name+/td/tr );
}
out.println( /table );
conn.close();
%
This is just a JSP script, nothing is compiled. I know it is better to
compile, but I am trying to chase down this DB slowness first.
Charles Killmer
Netgain Technology
[EMAIL PROTECTED]
Office: (320) 251-4700 ext 107


FONT SIZE=1 FACE=VERDANA,ARIAL COLOR=BLUE 
---
QAS Ltd.
Developers of QuickAddress Software
a href=http://www.qas.com;www.qas.com/a
Registered in England: No 2582055
Registered in Australia: No 082 851 474
---
/FONT

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


Where is jmx.jar

2005-02-07 Thread Phillip Qin
I am trying to build tomcat 5.5 manager app. Where can I find jmx.jar? It
used to be in ${catalina.home}/bin.




Regards,
 
 
PQ
 
Going to war for peace is like having sex for virginity


Re: How to get english messages on a German Windows-XP?

2005-02-07 Thread Mario Winterer
This system properties do not exist per default (that's why you have to 
set them if you want to change the default behaviour).
See also: 
http://java.sun.com/j2se/corejava/intl/reference/faqs/index.html#set-default-locale

 Tex
Zsolt Koppany wrote:
Thank you for this interesting info but in javadoc for jvm-1.4.2 I found
only the follow system properties:
user.name   User's account name
user.home   User's home directory
user.dirUser's current working directory
Zsolt
 

-Original Message-
From: Mario Winterer [mailto:[EMAIL PROTECTED]
Sent: Monday, February 07, 2005 6:30 PM
To: Tomcat Users List
Subject: Re: How to get english messages on a German Windows-XP?
I think Java uses the Locale from your operating system.
So to switch to english, you should either:
+ switch the locale of your operating system
+ tell Java to use another locale via system.properties at tomcat
startup (jvm-property):
-Duser.language=language-code -Duser.country=country-code
-Duser.variant=variant
e.g.: -Duser.language=en -Duser.country=US
Best regards,
 Tex
Zsolt Koppany schrieb:
   

Hi,
This is probably a java and not a tc question, but I would like to know
 

how
   

to get English java error messages when I start tc on a German windows XP
box.
Zsolt

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


FW: IE converts file.jpg to file_jpg when saving

2005-02-07 Thread Brad Hafichuk
Update.

I've found something interesting out.

If I attempt to download a file (say,
http://www.example.com/mywebapp/images/x.jpg) without any security
constraint in the web.xml file, I can correctly get the filename to show up
in the save as drop down for both IE and Mozilla (right-click on picture,
save as...).

If I use a security constraint;

  security-constraint
web-resource-collection
  web-resource-nameMywebapp/web-resource-name
  url-pattern/images/x.jpg/url-pattern
  http-methodGET/http-method
/web-resource-collection
auth-constraint
  role-nameuser/role-name
/auth-constraint
user-data-constraint
  transport-guaranteeNONE/transport-guarantee
/user-data-constraint
  /security-constraint

then right-click on the image, IE will display the image as untitled.bmp,
even though the image IS being displayed in the browser.

Why would the change in the security policy cause this to happen? Am I
setting the security-constraint correctly?

Thanks for any help you guys can offer.

Cheers,
Brad

-Original Message-
From: Brad Hafichuk [mailto:[EMAIL PROTECTED] 
Sent: February 7, 2005 1:08 PM
To: 'Tomcat Users List'
Subject: IE converts file.jpg to file_jpg when saving

This problem has been bugging me for at least 6 months. I finally noticed
that IE6 is converting the dot (.) in file.jpg to an underscore (_).

Has anyone experienced this very odd behaviour before?

 

I should point out that I am sending the file back to the client via a
servlet, the process being.

 

Load file into memory (as bytes) and close fileinputstream

Get mimetype of file

Set responses mimetype

Set response content-disposition (header) to attachment and
filename=file.jpg

Get response OutputStream

Write loaded file (bytes) to outputstream

Flush and close outputstream

 

I can post the exact code if needed. I'm running Tomcat 4.1.30.

 

Cheers,

Brad

 




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



RE: outOfMemory exception under high load

2005-02-07 Thread George Sexton
I would suggest running findbugs:

http://findbugs.sourceforge.net/

It has found issues in application code for other people on the list.


George Sexton
MH Software, Inc.
http://www.mhsoftware.com/
Voice: 303 438 9585
  

 -Original Message-
 From: Michael Cornell [mailto:[EMAIL PROTECTED] 
 Sent: Monday, February 07, 2005 3:37 AM
 To: Tomcat-User
 Subject: outOfMemory exception under high load
 
 Hi,
 
 Hi,
 
 I am experiencing a problem many others seem to have had before, but
 have found no answers.  I am running Tomcat 5.0.25 using jdk 1.4.2_06
 hotspot vm on RedHat Linux ES with 4G Ram and twin Intel procs.
 
 When load-testing, under high stress I receive the error below and the
 thread dies.
 
 04-Feb-2005 13:39:24 org.apache.coyote.tomcat5.CoyoteAdapter service
 SEVERE: An exception or error occurred in the container during the
 request processing
 java.lang.OutOfMemoryError
 at java.util.zip.ZipFile.open(Native Method)
 at java.util.zip.ZipFile.init(ZipFile.java:112)
 at java.util.jar.JarFile.init(JarFile.java:127)
 ..
 
 I have adjusted the vm parameters to the below ( the perm 
 space does not
 get full and the Xint to not use the optimised settings..
 -server -Xms1G -Xmx1G -Xmn384m -XX:SurvivorRatio=7 -XX:PermSize=64m
 -XX:MaxPermSize=128m -Xint
 
 In addition I have added the  reloading=false and 
 development=false in
 conf/web.xml.  as per instruction from this thread:
 http://www.junlu.com/msg/78566.html
 
 My connector is configured thus:
Connector
port=80
maxThreads=1000
minSpareThreads=1000
maxSpareThreads=1000
enableLookups=false
redirectPort=8443
acceptCount=3000
debug=0
connectionTimeout=2
disableUploadTimeout=true /
 
 
 However all of this is to no avail, and under high stress (80+
 concurrent requests, tomcat dies and terminates the thread dumping a
 hs_pid12345.log with  the above message
 
 Is this a known hotspot 1.4.x problem (some threads have hinted at
 this), or does someone have a solution for this??
 
 Thanks,
 
 M
 
 -
 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: Solaris 10 Tomcat 5.5.7

2005-02-07 Thread Chad Kellerman
On Monday February 7 2005 1:54 pm, Remy Maucherat wrote:
 On Mon, 7 Feb 2005 12:55:56 -0500, Chad Kellerman

 [EMAIL PROTECTED] wrote:
  Tomcat Users,
 I thought I would test out Tomcat 5.5.7 on a Solaris 10 (Ultra 60) so
  see how it performs.
 
  Here is what I did.
 
  edited /etc/profile
  JAVA_HOME=/usr/java
  export JAVA_HOME
 
  exploded the tar ball in /opt/
  then created a link to jakarta.XX.XX name tomcat
 
  I started tomcat, it started but there are messages in the catalina.out
  file that don't make sense.
 
  catalina.out
  SEVERE: Exception starting filter Compression Filter
  java.lang.ClassNotFoundException: compressionFilters.CompressionFilter
 
  Then I tried to go to the example pages on
  http://localhost:8080/jsp-examples/ and recieved an error.
 
  Feb 7, 2005 11:12:09 AM org.apache.catalina.core.StandardWrapperValve
  invoke SEVERE: Allocate exception for servlet
  org.apache.jsp.jsp2.el.basic_002darithmetic_jsp
  javax.servlet.ServletException: Wrapper cannot find servlet class
  org.apache.jsp.jsp2.el.basic_002darithmetic_jsp or a class it depends on
 
  I have java 1.5.0_01 and Tomcat 5.5 installed on a Fedora server and
  everything works fine, but the java on the SOlaris server seems to mess
  things up a bit.
 
  Anyone else see this?  Anyone else have a fix?

 Did you use GNU TAR to extract the .tar.gz ?

I used /usr/sfw/bin/gtar  but I guess that's still buggy.  I grabbed the zip 
file and it worked like a charm.

thanks for the help.

Chad


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



Re: Where is jmx.jar

2005-02-07 Thread Mario Winterer
JMX is now part of J2SE 5.0.
Best regards,
 Tex
Phillip Qin wrote:
I am trying to build tomcat 5.5 manager app. Where can I find jmx.jar? It
used to be in ${catalina.home}/bin.

Regards,
PQ
Going to war for peace is like having sex for virginity
 


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


RE: Where is jmx.jar

2005-02-07 Thread Phillip Qin


-Original Message-
From: Mario Winterer [mailto:[EMAIL PROTECTED] 
Sent: February 7, 2005 4:46 PM
To: Tomcat Users List
Subject: Re: Where is jmx.jar


JMX is now part of J2SE 5.0.

Best regards,
  Tex


Phillip Qin wrote:

I am trying to build tomcat 5.5 manager app. Where can I find jmx.jar? 
It used to be in ${catalina.home}/bin.




Regards,
 
 
PQ
 
Going to war for peace is like having sex for virginity

  



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


!DSPAM:4207e1a6319161133743922!


Re: Where is jmx.jar

2005-02-07 Thread sven morales
Hi,
   You need to download
jakarta-tomcat-5.5.7.compat.tar.gz if you plan to run
Tomcat 5.5.7 with jdk 1.4.x jre.  Untar it in same
directory as the Tomcat5.5.7 and those jar files
needed will be installed in its normal places.

aka_sergio

--- Phillip Qin [EMAIL PROTECTED] wrote:

 I am trying to build tomcat 5.5 manager app. Where
 can I find jmx.jar? It
 used to be in ${catalina.home}/bin.
 
 
 
 
 Regards,
  
  
 PQ
  
 Going to war for peace is like having sex for
 virginity
 




__ 
Do you Yahoo!? 
Yahoo! Mail - now with 250MB free storage. Learn more.
http://info.mail.yahoo.com/mail_250

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



RE: JTDS help

2005-02-07 Thread Charles P. Killmer
When I strip the code to simply this,

%@ page language=java import=java.sql.*%
%
Connection conn =
DriverManager.getConnection(jdbc:jtds:sqlserver://*.*.*.*:1433/dbname;u
ser=*;password=**);
conn.close();
%

It still runs slowly.  And yes it is multiple refreshes.  

I have tried to use connection pooling but have not been able to get it
working yet.  Also the thing that I run into with connection pooling the
inability to use the SQL Statement of select @@IDENTITY from table.
With connection pooling, you run the risk of getting the ID for a record
that someone else inserted with the same connection.

If connection pooling is the only option, I can work around that issue.
But it seems that if PHP, ASP, ASP.NET... Can access the database just
fine without connection pooling, JSP should be able to as well.

Any thoughts?
Thanks for all your input.
Charles

-Original Message-
From: Mario Winterer [mailto:[EMAIL PROTECTED] 
Sent: Monday, February 07, 2005 2:43 PM
To: Tomcat Users List
Subject: Re: JTDS help

I do not think, jsp compilation is the problem - well, the first request
will last long, but after the jsp is compiled, subsequent calls will not
be remarkable slower than executing pure compiled servlet code.
(Charles, I hope you did not measure the time for the first request only
- which indeed includes compilation time, but for subsequent calls too).
So to me opening the connection is the major problem. Because the code
itself contains html-output, I think using jsp is quite ok.
The code would be much cleaner, if Charles used the JSTL tag-library:

%@ page language=java%
%@ taglib prefix=c uri=http://java.sun.com/jstl/core; % %@ taglib
prefix=sql uri=http://java.sun.com/jstl/sql; % sql:query
sql=SELECT * FROM accounts var=accounts 
dataSource=jndi/myDataSource/
table
c:forEach var=acc items=${accounts} tr tdc:out
value=${acc.ID}//td tdc:out value=${acc.Name}//td /tr
/c:forEach /table

Best regards,
Tex

David Smith wrote:

 Ok. You're doing this in a jsp. That means Tomcat is:

 1) Compiling your jsp to a servlet class.
 2) Building a connection from scratch as opposed to picking up a 
 pooled connection
 3) Running the query.

 Of these, the first one is the most expensive operation followed by 
 two. If you want fast, try doing this with a pooled connection and 
 from compiled servlet code.

 --David

 Charles P. Killmer wrote:

 Network results
 Ping statistics for *.*.*.*:
 Packets: Sent = 140, Received = 140, Lost = 0 (0% loss), Approximate 
 round trip times in milli-seconds:
 Minimum = 0ms, Maximum = 0ms, Average = 0ms Query Analyzer returns 85

 rows in 0 seconds. I modified it to only return Name and ID and it 
 still runs slow. So it cant be row size, network latency, hardware 
 should be ruled out by the fact that it runs super fast through query

 analyzer, and PHP and ASP.NET. Its only when I write the code in JSP 
 for Tomcat that it slows down.

 Charles


 -Original Message-
 From: Allistair Crossley [mailto:[EMAIL PROTECTED] Sent: 
 Monday, February 07, 2005 11:37 AM
 To: Tomcat Users List
 Subject: RE: JTDS help

 Hi,

 There's no real reason relating to Tomcat or jTDS that this would run

 slow. You are more likely to find answers with your hardware, network

 latency, database load or row size and other environmental factors.

 Allistair.



 -Original Message-
 From: Charles P. Killmer [mailto:[EMAIL PROTECTED]
 Sent: 07 February 2005 17:34
 To: Tomcat Users List
 Subject: JTDS help


 I am trying to get Tomcat talking to my database quickly. This code 
 takes about 2-3 seconds to load. Anyone got any idea's why? Or if 
 you run this in your environment, how well does it run?

 %@ page language=java import=java.sql.*% % Connection conn =
 DriverManager.getConnection(jdbc:jtds:sqlserver://*.*.*.*:143
 3/dbname;u
 ser=**;password=***);

 Statement stmt = conn.createStatement(ResultSet.TYPE_FORWARD_ONLY,
 ResultSet.CONCUR_READ_ONLY);
 ResultSet rs;

 rs = stmt.executeQuery(SELECT * FROM accounts);

 out.println(table);
 String name;
 String ID;
 while (rs.next()) {
 name = rs.getString(Name);
 ID = rs.getString(ID);
 out.println(trtd + ID + /tdtd+name+/td/tr ); }

 out.println( /table );

 conn.close();
 %

 This is just a JSP script, nothing is compiled. I know it is better 
 to compile, but I am trying to chase down this DB slowness first.

 Charles Killmer
 Netgain Technology
 [EMAIL PROTECTED]
 Office: (320) 251-4700 ext 107





 FONT SIZE=1 FACE=VERDANA,ARIAL COLOR=BLUE
 ---
 QAS Ltd.
 Developers of QuickAddress Software
 a href=http://www.qas.com;www.qas.com/a
 Registered in England: No 2582055
 Registered in Australia: No 082 851 474
 ---
 /FONT


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


 

Java.lang.ClassNotFoundException: listeners.ContextListener

2005-02-07 Thread Harry Douglass, Jr.
Need some addition help!

Unfortunately, I am still getting this error even with adding this tag to my
web.xml file:

listener
  listener-classlisteners.ContextListener/listener-class
/listener

I verified that I am using the correct DTD schema:
!DOCTYPE web-app
  PUBLIC -//Sun Microsystems, Inc.//DTD Web Application 2.3//EN
  http://java.sun.com/dtd/web-app_2_3.dtd;

But, I am still getting this application error right when it is deploying my
project on the server container:

INFO: Deploying web application archive myLogin.war
Feb 6, 2005 1:13:17 PM org.apache.catalina.core.ApplicationContext log
SEVERE: Error configuring application listener of class
listeners.ContextListener
java.lang.ClassNotFoundException: listeners.ContextListener
Feb 6, 2005 1:13:17 PM org.apache.catalina.core.StandardContext
listenerStart
SEVERE: Skipped installing application listeners due to previous error(s)
Feb 6, 2005 1:13:17 PM org.apache.catalina.core.StandardContext start
SEVERE: Error listenerStart
Feb 6, 2005 1:13:17 PM org.apache.catalina.core.StandardContext start
SEVERE: Context startup failed due to previous errors
Feb 6, 2005 1:13:17 PM org.apache.catalina.core.ApplicationContext log

Any more suggestions?

Thanks,
Harry

Hi There,

The web.xml will have the following xml tag tag in it

listener
listener-classclasspath/listener-class
/listener

It sounds like the class file referenced by this tag does not exist or that
the class path is wrong.

Thanks

Pete

-Original Message-
From: Harry Douglass, Jr. [mailto:[EMAIL PROTECTED]
Sent: 05 February 2005 22:57
To: tomcat-user@jakarta.apache.org
Subject: Java.lang.ClassNotFoundException: listeners.ContextListener


Hello,



When my Tomcat 5 server is started, it gets a SEVERE error in the output
which states:



SEVERE:  Error configuring application listener of class
listeners.ContextListener

Java.lang.ClassNotFoundException:  listeners.ContextListener



SEVERE: Error configuring application listener of class
listerners.SessionListener

 Java.lang.ClassNotFoundException:  listeners.SessionListener



SEVERE: Skipped installing application listeners due to previous error(s).





Can anyone help with why this is occurring everytime I start the Tomcat 5
server.



Thanks in advance,



Harry





-
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: Version control tool

2005-02-07 Thread Graham Reeds
John Najarian wrote:
Does anyone know a good version control tool for code management that is free?
Also, a bug tracking application would be nice also.
These need to be run on Windows.
Thanks
Subversion?
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


Stopping infinite loops

2005-02-07 Thread Garthfield Carter
I run a server with Tomcat 5.0.27. A user managed to bring the server to
a grinding halt for 6 hours after he created a servlet with an infinite
loop, the piece of code that contained the infinite loop had a MySQL
connect statement which added to the problem greatly.

I've searched extensively for various answers in how to limit the damage
of infinite loops in Java but have drawn blanks. The memory allocated to
the JVMs is set to a maximum of 24MB per account. This had little effect
in keeping the damage down. Any pointers would be greatly appreciated.
I've toyed with the idea of using ulimit on CPU time but then Tomcat
wouldn't die depending on what time limit I set. You can't specify child
process ulimits unfortunately.

I'm hoping there's some admin settings perhaps I can use with Tomcat
itself or in the JVM.

Garthfield


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



Re: Java.lang.ClassNotFoundException: listeners.ContextListener

2005-02-07 Thread sven morales
Hi,
   Do you have this class located in your  
appname/WEB-INF/classes/listeners/  ?  If not, do you
have it located in the appname/WEB-INF/lib/*.jar  ? 
Basically I think it is looking for your
listener.ContextListener class.  I would expand your
war file and search for this class, then make sure it
is put located in the right directory.
   This is the only web applications not launching
right and the rest is working okay? So limit your
search right around your war file.

aka_sergio


--- Harry Douglass, Jr. [EMAIL PROTECTED]
wrote:

 Need some addition help!
 
 Unfortunately, I am still getting this error even
 with adding this tag to my
 web.xml file:
 
 listener
  

listener-classlisteners.ContextListener/listener-class
 /listener
 
 I verified that I am using the correct DTD schema:
 !DOCTYPE web-app
   PUBLIC -//Sun Microsystems, Inc.//DTD Web
 Application 2.3//EN
   http://java.sun.com/dtd/web-app_2_3.dtd;
 
 But, I am still getting this application error right
 when it is deploying my
 project on the server container:
 
 INFO: Deploying web application archive myLogin.war
 Feb 6, 2005 1:13:17 PM
 org.apache.catalina.core.ApplicationContext log
 SEVERE: Error configuring application listener of
 class
 listeners.ContextListener
 java.lang.ClassNotFoundException:
 listeners.ContextListener
 Feb 6, 2005 1:13:17 PM
 org.apache.catalina.core.StandardContext
 listenerStart
 SEVERE: Skipped installing application listeners due
 to previous error(s)
 Feb 6, 2005 1:13:17 PM
 org.apache.catalina.core.StandardContext start
 SEVERE: Error listenerStart
 Feb 6, 2005 1:13:17 PM
 org.apache.catalina.core.StandardContext start
 SEVERE: Context startup failed due to previous
 errors
 Feb 6, 2005 1:13:17 PM
 org.apache.catalina.core.ApplicationContext log
 
 Any more suggestions?
 
 Thanks,
 Harry
 
 Hi There,
 
   The web.xml will have the following xml tag tag in
 it
 
 listener
   listener-classclasspath/listener-class
 /listener
 
 It sounds like the class file referenced by this tag
 does not exist or that
 the class path is wrong.
 
 Thanks
 
 Pete
 
 -Original Message-
 From: Harry Douglass, Jr.
 [mailto:[EMAIL PROTECTED]
 Sent: 05 February 2005 22:57
 To: tomcat-user@jakarta.apache.org
 Subject: Java.lang.ClassNotFoundException:
 listeners.ContextListener
 
 
 Hello,
 
 
 
 When my Tomcat 5 server is started, it gets a SEVERE
 error in the output
 which states:
 
 
 
 SEVERE:  Error configuring application listener of
 class
 listeners.ContextListener
 
 Java.lang.ClassNotFoundException: 
 listeners.ContextListener
 
 
 
 SEVERE: Error configuring application listener of
 class
 listerners.SessionListener
 
  Java.lang.ClassNotFoundException: 
 listeners.SessionListener
 
 
 
 SEVERE: Skipped installing application listeners due
 to previous error(s).
 
 
 
 
 
 Can anyone help with why this is occurring everytime
 I start the Tomcat 5
 server.
 
 
 
 Thanks in advance,
 
 
 
 Harry
 
 
 
 
 

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

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




__ 
Do you Yahoo!? 
Read only the mail you want - Yahoo! Mail SpamGuard. 
http://promotions.yahoo.com/new_mail 

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



RE: Updating running WARs?

2005-02-07 Thread Mitchell K. McCuiston
I use the Tomcat Deployer.  If you're not familiar with Tomcat Deployer
you'll be able to find information here.
http://jakarta.apache.org/tomcat/tomcat-5.0-doc/deployer-howto.html

In a nutshell, it's a collection of ant (ant.apache.org) tasks that will
deploy a war to a remote tomcat server.  But I had some JNDI issues unless
my context was defined inside the META-INF/context.xml file I spoke of.

-Original Message-
From: David Wood [mailto:[EMAIL PROTECTED]
Sent: Monday, February 07, 2005 12:51 PM
To: tomcat-user@jakarta.apache.org
Subject: RE: Updating running WARs?


I'm sorry, I'm confused. Once you created a context.xml in your WARs, what
were your steps to update a running application?

Mitchell K. McCuiston [EMAIL PROTECTED] wrote on 02/07/2005
10:40:18 AM:

 Try configuring your app context inside of the META-INF/context.xml
inside
 of your war instead of your server.xml.  I had the same problem and this
 seemed to fix it.

 -Original Message-
 From: David Wood [mailto:[EMAIL PROTECTED]
 Sent: Friday, February 04, 2005 3:15 PM
 To: tomcat-user@jakarta.apache.org
 Subject: Updating running WARs?


 What's the right way to update a running WAR in Tomcat 5.5?

 Is there anything resembling the manager's reload feature for WARs? Or
 are we forced to remove the context via the manager and then re-add a
new
 context back in? (Or restart Tomcat?)

 I've been searching through documentation for the manager, and then
 looking a bit at the source code, and it seems like it's impossible to
 reload a context unless it's exploded.








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



Apache/2.0.52 (Win32) + mod_jk/1.2.8 + Tomcat 5.5.7

2005-02-07 Thread Bernard
I'm trying to connect Apache 2.0.52 with Tomcat 5.0.28 using the
mod_jk connector, to no avail.

First, before all the details, I could not find the built-in
facilities on either Apache mod_jk and Tomcat connector sides to
debug/verify the ajp13 connection. I am sure I overlooked these and
would be grateful for hints.


So I test with the SnoopServlet example via Tomcat's invoker.

The servlet works fine through Tomcat's own http server on port 8080.

Apache runs fine at the same time on port 80 but the servlet doesn't:

http://localhost/servlet/SnoopServlet

Not Found

The requested URL /servlet/SnoopServlet was not found on this server.
Apache/2.0.52 (Win32) mod_jk/1.2.8 Server at localhost Port 80

mod_jk.log gives some details as below but how can I know whether
mapping succeeded or failed?


[Mon Feb 07 22:23:50 2005] [-8276887:-8386719] [debug]
map_uri_to_worker::jk_uri_worker_map.c (700): Attempting to map URI
'/servlet/SnoopServlet' from 3 maps
[Mon Feb 07 22:23:50 2005] [-8276887:-8386719] [debug]
map_uri_to_worker::jk_uri_worker_map.c (718): Attempting to map
context URI '/servlet/'
[Mon Feb 07 22:23:50 2005] [-8276887:-8386719] [debug]
map_uri_to_worker::jk_uri_worker_map.c (718): Attempting to map
context URI '/*/zgb/'
[Mon Feb 07 22:23:50 2005] [-8276887:-8386719] [debug]
map_uri_to_worker::jk_uri_worker_map.c (718): Attempting to map
context URI '/*/zsp/'


In server.xml I have (nothing changed):

Connector port=8009 enableLookups=false redirectPort=8443
protocol=AJP/1.3 /


In workers.properties I have:

ps=\
worker.list=ajp13
worker.ajp13.port=8009
worker.ajp13.host=localhost
worker.ajp13.type=ajp13

Any help would be appreciated. I am desparate.

P.S. I don't have a personal firewall that could complicate things.


Thanks,

Bernard


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



Re: Apache/2.0.52 (Win32) + mod_jk/1.2.8 + Tomcat 5.5.7

2005-02-07 Thread dshort
Move mod_jk.so to your Apache\modules directory.

Add the following code to the bottom of your Apache httpd.conf file.

LoadModule jk_module modules/mod_jk.so 
Alias /context C:/Tomcat/webapps/context/htdocs
JkWorkersFile C:/Apache2/conf/workers.properties 
JkLogFile C:/Apache2/logs/mod_jk.log 
JkLogLevel info
#JkLogLevel debug 
JkLogStampFormat [%a %b %d %H:%M:%S %Y]  
JkOptions +ForwardKeySize +ForwardURICompat -ForwardDirectories 
JkRequestLogFormat %w %V %T 
JkMount /context/servlet/* worker
JkMount /context/*.jsp worker

Where context is your application context root.

- Original Message -
From: Bernard [EMAIL PROTECTED]
Date: Monday, February 7, 2005 3:25 pm
Subject: Apache/2.0.52 (Win32) + mod_jk/1.2.8 + Tomcat 5.5.7

 I'm trying to connect Apache 2.0.52 with Tomcat 5.0.28 using the
 mod_jk connector, to no avail.
 
 First, before all the details, I could not find the built-in
 facilities on either Apache mod_jk and Tomcat connector sides to
 debug/verify the ajp13 connection. I am sure I overlooked these and
 would be grateful for hints.
 
 
 So I test with the SnoopServlet example via Tomcat's invoker.
 
 The servlet works fine through Tomcat's own http server on port 8080.
 
 Apache runs fine at the same time on port 80 but the servlet doesn't:
 
 http://localhost/servlet/SnoopServlet
 
 Not Found
 
 The requested URL /servlet/SnoopServlet was not found on this server.
 Apache/2.0.52 (Win32) mod_jk/1.2.8 Server at localhost Port 80
 
 mod_jk.log gives some details as below but how can I know whether
 mapping succeeded or failed?
 
 
 [Mon Feb 07 22:23:50 2005] [-8276887:-8386719] [debug]
 map_uri_to_worker::jk_uri_worker_map.c (700): Attempting to map URI
 '/servlet/SnoopServlet' from 3 maps
 [Mon Feb 07 22:23:50 2005] [-8276887:-8386719] [debug]
 map_uri_to_worker::jk_uri_worker_map.c (718): Attempting to map
 context URI '/servlet/'
 [Mon Feb 07 22:23:50 2005] [-8276887:-8386719] [debug]
 map_uri_to_worker::jk_uri_worker_map.c (718): Attempting to map
 context URI '/*/zgb/'
 [Mon Feb 07 22:23:50 2005] [-8276887:-8386719] [debug]
 map_uri_to_worker::jk_uri_worker_map.c (718): Attempting to map
 context URI '/*/zsp/'
 
 
 In server.xml I have (nothing changed):
 
 Connector port=8009 enableLookups=false redirectPort=8443
 protocol=AJP/1.3 /
 
 
 In workers.properties I have:
 
 ps=\
 worker.list=ajp13
 worker.ajp13.port=8009
 worker.ajp13.host=localhost
 worker.ajp13.type=ajp13
 
 Any help would be appreciated. I am desparate.
 
 P.S. I don't have a personal firewall that could complicate things.
 
 
 Thanks,
 
 Bernard
 
 
 ---
 --
 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: JTDS help

2005-02-07 Thread Hari Saptoadi
i think using JDBC data source would be better solution for your problem ,
so the con pooling maintenance by the container
and you don't have to worry about the riskCMIIW

- Original Message -
From: Charles P. Killmer [EMAIL PROTECTED]
To: Tomcat Users List tomcat-user@jakarta.apache.org
Sent: Tuesday, February 08, 2005 5:41 AM
Subject: RE: JTDS help


 When I strip the code to simply this,

 %@ page language=java import=java.sql.*%
 %
 Connection conn =
 DriverManager.getConnection(jdbc:jtds:sqlserver://*.*.*.*:1433/dbname;u
 ser=*;password=**);
 conn.close();
 %

 It still runs slowly.  And yes it is multiple refreshes.

 I have tried to use connection pooling but have not been able to get it
 working yet.  Also the thing that I run into with connection pooling the
 inability to use the SQL Statement of select @@IDENTITY from table.
 With connection pooling, you run the risk of getting the ID for a record
 that someone else inserted with the same connection.

 If connection pooling is the only option, I can work around that issue.
 But it seems that if PHP, ASP, ASP.NET... Can access the database just
 fine without connection pooling, JSP should be able to as well.

 Any thoughts?
 Thanks for all your input.
 Charles

 -Original Message-
 From: Mario Winterer [mailto:[EMAIL PROTECTED]
 Sent: Monday, February 07, 2005 2:43 PM
 To: Tomcat Users List
 Subject: Re: JTDS help

 I do not think, jsp compilation is the problem - well, the first request
 will last long, but after the jsp is compiled, subsequent calls will not
 be remarkable slower than executing pure compiled servlet code.
 (Charles, I hope you did not measure the time for the first request only
 - which indeed includes compilation time, but for subsequent calls too).
 So to me opening the connection is the major problem. Because the code
 itself contains html-output, I think using jsp is quite ok.
 The code would be much cleaner, if Charles used the JSTL tag-library:

 %@ page language=java%
 %@ taglib prefix=c uri=http://java.sun.com/jstl/core; % %@ taglib
 prefix=sql uri=http://java.sun.com/jstl/sql; % sql:query
 sql=SELECT * FROM accounts var=accounts
 dataSource=jndi/myDataSource/
 table
 c:forEach var=acc items=${accounts} tr tdc:out
 value=${acc.ID}//td tdc:out value=${acc.Name}//td /tr
 /c:forEach /table

 Best regards,
 Tex

 David Smith wrote:

  Ok. You're doing this in a jsp. That means Tomcat is:
 
  1) Compiling your jsp to a servlet class.
  2) Building a connection from scratch as opposed to picking up a
  pooled connection
  3) Running the query.
 
  Of these, the first one is the most expensive operation followed by
  two. If you want fast, try doing this with a pooled connection and
  from compiled servlet code.
 
  --David
 
  Charles P. Killmer wrote:
 
  Network results
  Ping statistics for *.*.*.*:
  Packets: Sent = 140, Received = 140, Lost = 0 (0% loss), Approximate
  round trip times in milli-seconds:
  Minimum = 0ms, Maximum = 0ms, Average = 0ms Query Analyzer returns 85

  rows in 0 seconds. I modified it to only return Name and ID and it
  still runs slow. So it cant be row size, network latency, hardware
  should be ruled out by the fact that it runs super fast through query

  analyzer, and PHP and ASP.NET. Its only when I write the code in JSP
  for Tomcat that it slows down.
 
  Charles
 
 
  -Original Message-
  From: Allistair Crossley [mailto:[EMAIL PROTECTED] Sent:
  Monday, February 07, 2005 11:37 AM
  To: Tomcat Users List
  Subject: RE: JTDS help
 
  Hi,
 
  There's no real reason relating to Tomcat or jTDS that this would run

  slow. You are more likely to find answers with your hardware, network

  latency, database load or row size and other environmental factors.
 
  Allistair.
 
 
 
  -Original Message-
  From: Charles P. Killmer [mailto:[EMAIL PROTECTED]
  Sent: 07 February 2005 17:34
  To: Tomcat Users List
  Subject: JTDS help
 
 
  I am trying to get Tomcat talking to my database quickly. This code
  takes about 2-3 seconds to load. Anyone got any idea's why? Or if
  you run this in your environment, how well does it run?
 
  %@ page language=java import=java.sql.*% % Connection conn =
  DriverManager.getConnection(jdbc:jtds:sqlserver://*.*.*.*:143
  3/dbname;u
  ser=**;password=***);
 
  Statement stmt = conn.createStatement(ResultSet.TYPE_FORWARD_ONLY,
  ResultSet.CONCUR_READ_ONLY);
  ResultSet rs;
 
  rs = stmt.executeQuery(SELECT * FROM accounts);
 
  out.println(table);
  String name;
  String ID;
  while (rs.next()) {
  name = rs.getString(Name);
  ID = rs.getString(ID);
  out.println(trtd + ID + /tdtd+name+/td/tr ); }
 
  out.println( /table );
 
  conn.close();
  %
 
  This is just a JSP script, nothing is compiled. I know it is better
  to compile, but I am trying to chase down this DB slowness first.
 
  Charles Killmer
  Netgain Technology
  [EMAIL PROTECTED]
  Office: (320) 251-4700 ext 107
 
 
 
 
 
  FONT SIZE=1 FACE=VERDANA,ARIAL 

jk connector build problem

2005-02-07 Thread Thor Muller
I think others have had this problem but I can't find an answer that
helps me. I have a fresh install of redhat9 and I've installed Apache
2.053, PHP 4.3.1 and Tomcat 5.5, all without a hitch. Now I'm trying
to compile the mod_jk.so and it gives me the following error. Any
answers would be very much appreciated.

---

# make
Making all in common
make[1]: Entering directory
`/usr/src/jakarta-tomcat-connectors-1.2.8-src/jk/native/common'
make[1]: Nothing to be done for `all'.
make[1]: Leaving directory
`/usr/src/jakarta-tomcat-connectors-1.2.8-src/jk/native/common'
Making all in apache-2.0
make[1]: Entering directory
`/usr/src/jakarta-tomcat-connectors-1.2.8-src/jk/native/apache-2.0'
/bin/sh /usr/local/apache/build/libtool --silent --mode=install cp
mod_jk.la `pwd`/mod_jk.so
libtool: install: warning: remember to run `libtool --finish
/usr/local/apache/modules'
make[1]: Leaving directory
`/usr/src/jakarta-tomcat-connectors-1.2.8-src/jk/native/apache-2.0'
make[1]: Entering directory
`/usr/src/jakarta-tomcat-connectors-1.2.8-src/jk/native'
make[1]: Nothing to be done for `all-am'.
make[1]: Leaving directory
`/usr/src/jakarta-tomcat-connectors-1.2.8-src/jk/native'
target=all; \
list='common apache-2.0'; \
for i in $list; do \
echo Making $target in $i; \
if test $i != .; then \
   (cd $i  make $target) || exit 1; \
fi; \
done;
Making all in common
make[1]: Entering directory
`/usr/src/jakarta-tomcat-connectors-1.2.8-src/jk/native/common'
make[1]: Nothing to be done for `all'.
make[1]: Leaving directory
`/usr/src/jakarta-tomcat-connectors-1.2.8-src/jk/native/common'
Making all in apache-2.0
make[1]: Entering directory
`/usr/src/jakarta-tomcat-connectors-1.2.8-src/jk/native/apache-2.0'
/bin/sh /usr/local/apache/build/libtool --silent --mode=install cp
mod_jk.la `pwd`/mod_jk.so
libtool: install: warning: remember to run `libtool --finish
/usr/local/apache/modules'
make[1]: Leaving directory
`/usr/src/jakarta-tomcat-connectors-1.2.8-src/jk/native/apache-2.0'
[EMAIL PROTECTED] native]# make install
Making install in common
make[1]: Entering directory
`/usr/src/jakarta-tomcat-connectors-1.2.8-src/jk/native/common'
make[1]: Nothing to be done for `install'.
make[1]: Leaving directory
`/usr/src/jakarta-tomcat-connectors-1.2.8-src/jk/native/common'
Making install in apache-2.0
make[1]: Entering directory
`/usr/src/jakarta-tomcat-connectors-1.2.8-src/jk/native/apache-2.0'

Installing files to Apache Modules Directory...
/usr/local/apache/bin/apxs -i mod_jk.la
/usr/local/apache/build/instdso.sh
SH_LIBTOOL='/usr/local/apache/build/libtool' mod_jk.la
/usr/local/apache/modules
/usr/local/apache/build/libtool --mode=install cp mod_jk.la
/usr/local/apache/modules/
cp .libs/mod_jk.lai /usr/local/apache/modules/mod_jk.la
cp .libs/mod_jk.a /usr/local/apache/modules/mod_jk.a
ranlib /usr/local/apache/modules/mod_jk.a
chmod 644 /usr/local/apache/modules/mod_jk.a
PATH=$PATH:/sbin ldconfig -n /usr/local/apache/modules
--
Libraries have been installed in:
   /usr/local/apache/modules

If you ever happen to want to link against installed libraries
in a given directory, LIBDIR, you must either use libtool, and
specify the full pathname of the library, or use the `-LLIBDIR'
flag during linking and do at least one of the following:
   - add LIBDIR to the `LD_LIBRARY_PATH' environment variable
 during execution
   - add LIBDIR to the `LD_RUN_PATH' environment variable
 during linking
   - use the `-Wl,--rpath -Wl,LIBDIR' linker flag
   - have your system administrator add LIBDIR to `/etc/ld.so.conf'

See any operating system documentation about shared libraries for
more information, such as the ld(1) and ld.so(8) manual pages.
--
Warning!  dlname not found in /usr/local/apache/modules/mod_jk.la.
Assuming installing a .so rather than a libtool archive.
chmod 755 /usr/local/apache/modules/mod_jk.so
chmod: failed to get attributes of
`/usr/local/apache/modules/mod_jk.so': No such file or directory
apxs:Error: Command failed with rc=65536
.
make[1]: *** [install_dynamic] Error 1
make[1]: Leaving directory
`/usr/src/jakarta-tomcat-connectors-1.2.8-src/jk/native/apache-2.0'
make: *** [install-recursive] Error 1

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



Disable directory redirect?

2005-02-07 Thread Oliver Hutchison
In Tomcat 5.5.7 is there a way to disable the automatic redirect that
happens when a request matches a directory except for the trailing
slash? e.g. On my server the request /boards get redirected to
/boards/ as there is a boards directory on the server.
 
The strange thing is the redirect seem to happen before any filters or
servlet are allowed to process the request. This is really annoying as I
have a filter that is expecting to see the /boards request not the
redirected /boards/ request. This feels like a bug to me. Shouldn't
the redirect be initiated by the default servlet after any user
servlet/filters have processed the request?
 
There is a bug report for this but the comments are not helpful and it
seems to be related to the 5.0 code base.
http://issues.apache.org/bugzilla/show_bug.cgi?id=32424
 
Oliver
 
 
 
 
 


Re: Disable directory redirect?

2005-02-07 Thread Garthfield Carter
In Apache you fix this problem by altering the: UseCanonicalName in
httpd.conf, I forget whether it should be on or off. If you're using
an Apache front-end to Tomcat then you can stop it there.

On Tue, 2005-02-08 at 13:54 +1100, Oliver Hutchison wrote:
 In Tomcat 5.5.7 is there a way to disable the automatic redirect that
 happens when a request matches a directory except for the trailing
 slash? e.g. On my server the request /boards get redirected to
 /boards/ as there is a boards directory on the server.
  
 The strange thing is the redirect seem to happen before any filters or
 servlet are allowed to process the request. This is really annoying as I
 have a filter that is expecting to see the /boards request not the
 redirected /boards/ request. This feels like a bug to me. Shouldn't
 the redirect be initiated by the default servlet after any user
 servlet/filters have processed the request?
  
 There is a bug report for this but the comments are not helpful and it
 seems to be related to the 5.0 code base.
 http://issues.apache.org/bugzilla/show_bug.cgi?id=32424
  
 Oliver
  
 
 
 
 


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



RE: Disable directory redirect?

2005-02-07 Thread Oliver Hutchison
Thanks but I'm not using Apache as a front-end and the problem is with
some custom processing that Tomcat is doing before any of the standard
processing so I'm not sure using Apache would help in any case.

Ollie

 -Original Message-
 From: Garthfield Carter [mailto:[EMAIL PROTECTED] 
 Sent: Tuesday, 8 February 2005 1:59 PM
 To: Tomcat Users List
 Subject: Re: Disable directory redirect?
 
 In Apache you fix this problem by altering the: 
 UseCanonicalName in httpd.conf, I forget whether it should be 
 on or off. If you're using an Apache front-end to Tomcat 
 then you can stop it there.
 
 On Tue, 2005-02-08 at 13:54 +1100, Oliver Hutchison wrote:
  In Tomcat 5.5.7 is there a way to disable the automatic 
 redirect that 
  happens when a request matches a directory except for the trailing 
  slash? e.g. On my server the request /boards get redirected to 
  /boards/ as there is a boards directory on the server.
   
  The strange thing is the redirect seem to happen before any 
 filters or 
  servlet are allowed to process the request. This is really 
 annoying as 
  I have a filter that is expecting to see the /boards 
 request not the 
  redirected /boards/ request. This feels like a bug to me. 
 Shouldn't 
  the redirect be initiated by the default servlet after any user 
  servlet/filters have processed the request?
   
  There is a bug report for this but the comments are not 
 helpful and it 
  seems to be related to the 5.0 code base.
  http://issues.apache.org/bugzilla/show_bug.cgi?id=32424
   
  Oliver
   
  
  
  
  
 
 
 -
 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: isUserInRole

2005-02-07 Thread joby.joseph1

Hi Denny,

I don't hav much idea abt NTLM, still...

Hav u stored roles and the associated users in that file.

Hav u specified that file as the file which contains user details in
server.xml file...

Check those things...





Joby Joseph

Wipro Technologies

Plot No.72, KEONICS Electronics City,
Hosur Main Road,
Bangalore- 560 100. India
Tel:+91-80-28520408; 5122  Extn:82332

www.wipro.com



-Original Message-
From: Denny Lee [mailto:[EMAIL PROTECTED]
Sent: Monday, February 07, 2005 9:40 PM
To: tomcat-user@jakarta.apache.org
Subject: RE: isUserInRole

Hello Joby,
My problem is not getting user name and logging in but
rather I can't get the user's role using the function
isUserInRole().  For whatever reason isUserInRole
always returns a false.  I tried
isUserInRole(admin), isUserInRole(Administrarors),
isUserInRole(Users) but I get false for all of them.
 

I am trying to restrict some web pages  to only allow
administrator access.  I can't put the user name and
role in an xml file or using a database because of my
company's security policy.  I have to get the data
from NTLM.

Thanks again for your help.


Forwarded Message
Subject:RE: isUserInRole
Date:   Mon, 7 Feb 2005 08:46:40 +0530
From:   [EMAIL PROTECTED]
To: tomcat-user@jakarta.apache.org

Plain Text Attachment [ Download File | Save to my
Yahoo! Briefcase ]



Hi Denny,

To get user name... do as follows...
%@ page import=java.security.Principal %
And use in ur code as...
% Principal p = request.getUserPrincipal();
 out.println(p.getName()); %
will print the name of the current user...



Joby Joseph
Wipro Technologies
Plot No.72, KEONICS Electronics City,
Hosur Main Road,
Bangalore- 560 100. India
Tel:+91-80-28520408; 5122  Extn:82332
www.wipro.com

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





Confidentiality Notice

The information contained in this electronic message and any attachments to 
this message are intended
for the exclusive use of the addressee(s) and may contain confidential or 
privileged information. If
you are not the intended recipient, please notify the sender at Wipro or [EMAIL 
PROTECTED] immediately
and destroy all copies of this message and any attachments.

predlude coda

2005-02-07 Thread VTR Ravi Kumar
I am not able to use this .
I have the following in my web.xml
- # jsp-config
- # jsp-property-group
 descriptionSpecial property group for JSP Configuration JSP 
example./description
 display-nameJSPConfiguration/display-name
 url-pattern/login.jsp/url-pattern
 el-ignoredtrue/el-ignored
 page-encodingISO-8859-1/page-encoding
 scripting-invalidtrue/scripting-invalid
 include-preludeprelude.jspf/include-prelude
 include-codacoda.jspf/include-coda
 /jsp-property-group
 /jsp-config

and have copied the prelude.jspf and coda.jspf
I get to see nothing in the login.jsp
Any help in this regard will be greatly welcomed...
VTR Ravi Kumar

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


RE: outOfMemory exception under high load

2005-02-07 Thread Caldarale, Charles R
 From: Dale, Matt [mailto:[EMAIL PROTECTED]
 Subject: RE: outOfMemory exception under high load
 
 It could be your permanent generation that is running out of 
 space. Get a hold of jvmstat to determine if this is the case.

Another possibility is that you're exceeding your limit on the number of open 
files.  Exceeding any underlying OS limit is usually translated to an 
OutOfMemory exception by the JVM.

 - Chuck


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

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



J2SE 5.0 redirects applets to java.com

2005-02-07 Thread David W. Brown
Hello Tomcat users and gurus (Dev too). I have been using Tomcat and some 
version of jdk for several years. Tomcat is my servlet server of choice mostly 
on Linux systems when my employers allow such things. I recently downloaded the 
lastest (yesterday) binary for Windows XP. Seeing that the new Tomcat will only 
run under the new J2SE 5.0 I downloaded and installed: jdk1.5.0_01 executable. 
After installation the old familiar Tomcat page came up as usual at: 
http://localhost:8080. What happened next is for my part inexplicable. I lost 
all ability to run any type of applet except for: file://someapplet.html. Any 
applets using: HTTP:// where redirected to: http://java.com with the new Java 
Logo animated sunburst in the middle of the webpage. All applets regardless of 
source: local or public IP where re-directed to: http://java.com. The remedy 
was to uninstall J2SE 5.0. Needless to say I am severely hampered by not being 
able to run Tomcat because of a wayward jdk. I have sent this problem to 
java.com contact email but so-far ignored by java.com. If anyone has any 
comments, suggestions, remedies, rants or raves please reply.

David Brown
IT/COMMO
KBR - USMI
KIRKUK AB
281-669-1655x102

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



RE: tomcat CPU utilization pegged...total CPU only 50%

2005-02-07 Thread Caldarale, Charles R
 From: Kevin Williams [mailto:[EMAIL PROTECTED]
 Subject: RE: tomcat CPU utilization pegged...total CPU only 50%
 
 The two Xeon CPU's are hyperthreaded to represent 4 CPU's 
 on the machine.  I'm not sure exactly how tomcat/java 
 interact with this, but it was not favorable.

Other than for determining the number of threads to use for parallel GC, the 
JVM does not care how many CPUs there are.  I don't know what Windows returns 
for the number of CPUs installed when hyperthreading is enabled, but you can 
determine that with the Runtime.availableProcessors() method.

You really should be measuring performance by some measurement of actual 
workload completed, not CPU utilization.  Turning off hyperthreading may 
actually reduce your overall throughput.  (Then again, it might make it better 
- very application dependent.)

 - Chuck


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

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



Re: jk connector build problem

2005-02-07 Thread Mladen Turk
Thor Muller wrote:
I think others have had this problem but I can't find an answer that
helps me. I have a fresh install of redhat9 and I've installed Apache
2.053, PHP 4.3.1 and Tomcat 5.5, all without a hitch. Now I'm trying
to compile the mod_jk.so and it gives me the following error. Any
answers would be very much appreciated.
---
# make
Making all in common
make[1]: Entering directory
`/usr/src/jakarta-tomcat-connectors-1.2.8-src/jk/native/common'
make[1]: Nothing to be done for `all'.
How did you run ./configure?
Mladen.
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


Re: J2SE 5.0 redirects applets to java.com

2005-02-07 Thread Parsons Technical Services
Which version of Tomcat did you download?
If 5.0.x , it will run on 1.4.x jdk.
If 5.5.x, it will run on 1.5 (or 5.0) JRE  and with the compat patch it will 
also run on jdk 1.4.x

I think the new 1.5 java has an update feature and some other things??? 
built into it that has it phone home. The applet should still run. I have 
see the new logo on my desktop and applets run fine.

You may try to block the app from getting to the Internet with a firewall.
The 1.5 adds a Java setting console to Control Panel. It allows you to turn 
off updates and make other changes.

Doug
- Original Message - 
From: David W. Brown [EMAIL PROTECTED]
To: tomcat-user@jakarta.apache.org
Sent: Tuesday, February 08, 2005 12:47 AM
Subject: J2SE 5.0 redirects applets to java.com


Hello Tomcat users and gurus (Dev too). I have been using Tomcat and some 
version of jdk for several years. Tomcat is my servlet server of choice 
mostly on Linux systems when my employers allow such things. I recently 
downloaded the lastest (yesterday) binary for Windows XP. Seeing that the 
new Tomcat will only run under the new J2SE 5.0 I downloaded and 
installed: jdk1.5.0_01 executable. After installation the old familiar 
Tomcat page came up as usual at: http://localhost:8080. What happened next 
is for my part inexplicable. I lost all ability to run any type of applet 
except for: file://someapplet.html. Any applets using: HTTP:// where 
redirected to: http://java.com with the new Java Logo animated sunburst in 
the middle of the webpage. All applets regardless of source: local or 
public IP where re-directed to: http://java.com. The remedy was to 
uninstall J2SE 5.0. Needless to say I am severely hampered by not being 
able to run Tomcat because of a wayward jdk. I have sent this problem to 
java.com contact email but so-far ignored by java.com. If anyone has any 
comments, suggestions, remedies, rants or raves please reply.

David Brown
IT/COMMO
KBR - USMI
KIRKUK AB
281-669-1655x102
-
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]