Re: Different behavior between Tomcat service installation Tomcat console mode

2011-08-03 Thread Mladen Turk

On 08/03/2011 07:03 AM, Alexandre Terrasson wrote:

Hi, thanks guys,
2/ The Jar of my driver is located in the Tomcat lib folders. The driver is
not only a jar, I had to installed it as an odbc source, with some dll and
some entries in windows registry.


So you must ensure that LOCAL_SERVICE account has access both to the
registry and to the files in the folder where odbc .dlls are installed
Might even require modifying System Environment PATH

You can try running the service with Administrator account
or the one you are using wen running in console mode
(given that it has permission to 'Run As a Service') and
then search for the permission problems or missing variables
for the local service account.


Regards
--
^TM

-
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org



Sharing session between different webapps under same tomcat

2011-08-03 Thread Jany Jose
Hi,

We are using tomcat 6.0.26. For one use case we want to re-use the session
objects created in one web application in another web application which are
running under the same tomcat. Please let me know is it supported and if yes
how to achieve that.

Thanks
Jany


Re: Sharing session between different webapps under same tomcat

2011-08-03 Thread Mark Thomas
On 03/08/2011 07:23, Jany Jose wrote:
 Hi,
 
 We are using tomcat 6.0.26. For one use case we want to re-use the session
 objects created in one web application in another web application which are
 running under the same tomcat. Please let me know is it supported and if yes
 how to achieve that.

It is not supported.

Mark

-
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org



Re: Finding user name without authentication

2011-08-03 Thread Vibhor Kumar Agarwal



 Addendum :
 
 In the above, I was assuming
 a) that the webserver you are talking about is Tomcat
 b) that you mean a configuration where Tomcat is accessed directly by the
 user browser (as 
   opposed to a configuration where Tomcat is behind some other front-end
 system).
 
 In case (b), there are also methods to authenticate the user at the
 front-end level, and 
 pass this authentication to Tomcat inside each forwarded request.
 
 

Sorry folks for being late.
Could you please clarify the above options.

Scenario:
Tomcat is running on FreeBSD.
End user can use any browser  OS combination to access HTML pages hosted by
tomcat.
-- 
View this message in context: 
http://old.nabble.com/Finding-user-name-without-authentication-tp32146111p32184387.html
Sent from the Tomcat - User mailing list archive at Nabble.com.


-
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org



Re: Missing files for Apache and Log4J

2011-08-03 Thread A Df
Hello Mates:

I got the log file to work however, it does not have the date appended like the 
usual Tomcat Logs and does not creating a rolling daily file. I also wanted to 
have control over the usual logs that Tomcat produced so I combined your 
instructions with those from this other website at 
http://mrhaki.blogspot.com/2011/02/configure-log4j-on-tomcat.html to get the 
content for the properties file. However, the problems are:
* the log files do not have the .log extension so they do not show up 
file type as text document instead just a type as file

* the date is not being appended to the name
My code below is in the properties file in the Project default package folder 
as Mark Eggers suggested. I am not sure which property to modify to get the 
.log extension and the date appended.



#log4j.properties File

log4j.rootLogger=INFO, CATALINA, CONSOLE

#Tweet Tag Processor
log4j.logger.org.tweettagprocessorpackage=INFO, R

# Define all the appenders

# Configuration for a rolling log file.
log4j.appender.R=org.apache.log4j.DailyRollingFileAppender
# Edit the next line to point to your logs directory.
# The last part of the name is the log file name.
log4j.appender.R.file=${catalina.base}/logs/tagprocessor.
log4j.appender.R.encoding=UTF-8
# Roll-over the log once per day
log4j.appender.R.DatePattern='.'-MM-dd'.log'
# Print the date in ISO 8601 format
log4j.appender.R.layout=org.apache.log4j.PatternLayout
log4j.appender.R.layout.ConversionPattern=%d [%t] %-5p %c - %m%n
log4j.appender.R.append=true

log4j.appender.CATALINA=org.apache.log4j.DailyRollingFileAppender
log4j.appender.CATALINA.file=${catalina.base}/logs/catalina-my.
log4j.appender.CATALINA.encoding=UTF-8
# Roll-over the log once per day
log4j.appender.CATALINA.DatePattern='.'-MM-dd'.log'
log4j.appender.CATALINA.layout=org.apache.log4j.PatternLayout
log4j.appender.CATALINA.layout.ConversionPattern = %d [%t] %-5p %c - %m%n
log4j.appender.CATALINA.append=true

log4j.appender.LOCALHOST=org.apache.log4j.DailyRollingFileAppender
log4j.appender.LOCALHOST.file=${catalina.base}/logs/localhost-my.
log4j.appender.LOCALHOST.encoding=UTF-8
log4j.appender.LOCALHOST.DatePattern='.'-MM-dd'.log'
log4j.appender.LOCALHOSTlayout=org.apache.log4j.PatternLayout
log4j.appender.LOCALHOST.layout.ConversionPattern = %d [%t] %-5p %c - %m%n
log4j.appender.LOCALHOST.append=true

log4j.appender.MANAGER=org.apache.log4j.DailyRollingFileAppender
log4j.appender.MANAGER.file=${catalina.base}/logs/manager-my.
log4j.appender.MANAGER.encoding=UTF-8
log4j.appender.MANAGER.DatePattern='.'-MM-dd'.log'
log4j.appender.MANAGER.layout=org.apache.log4j.PatternLayout
log4j.appender.MANAGER.layout.ConversionPattern = %d [%t] %-5p %c - %m%n
log4j.appender.MANAGER.append=true

log4j.appender.HOST-MANAGER=org.apache.log4j.DailyRollingFileAppender
log4j.appender.HOST-MANAGER.file=${catalina.base}/logs/host-manager-my.
log4j.appender.HOST-MANAGER.encoding=UTF-8
log4j.appender.HOST-MANAGER.DatePattern='.'-MM-dd'.log'
log4j.appender.HOST-MANAGER.layout=org.apache.log4j.PatternLayout
log4j.appender.HOST-MANAGER.layout.ConversionPattern = %d [%t] %-5p %c - %m%n
log4j.appender.HOST-MANAGER.append=true

log4j.appender.CONSOLE=org.apache.log4j.ConsoleAppender
log4j.appender.CONSOLE.encoding=UTF-8
log4j.appender.CONSOLE.layout=org.apache.log4j.PatternLayout
log4j.appender.CONSOLE.layout.ConversionPattern = %d [%t] %-5p %c - %m%n

# Configure which loggers log to which appenders
log4j.logger.org.apache.catalina.core.ContainerBase.[Catalina].[localhost]=INFO,
 LOCALHOST
log4j.logger.org.apache.catalina.core.ContainerBase.[Catalina].[localhost].[/manager]=\
  INFO, MANAGER
log4j.logger.org.apache.catalina.core.ContainerBase.[Catalina].[localhost].[/host-manager]=\
  INFO, HOST-MANAGER

  



Cheers,
A Df

From: Mark Eggers its_toas...@yahoo.com

To: Tomcat Users List users@tomcat.apache.org; A Df 
abbey_dragonfor...@yahoo.com
Sent: Friday, 29 July 2011, 19:04
Subject: Re: Missing files for Apache and Log4J

 From: A Df abbey_dragonfor...@yahoo.com

 Dear All:
 
 I have created a Java web application and I want to have logging to ensure 
 that 
 the appropriate messages are stored in log files instead of to standard 
 output. 
 I found a link at http://tomcat.apache.org/tomcat-6.0-doc/logging.html and 
 was 
 following the instruction but I am unclear for these steps. My details are:
 
     * Apache Tomcat 6.0.26
     * Log 4j 1.2.16
 
 The instructions specify
 
     * Build or download the additional logging components.
 I am new to logging, so I am not sure what other extra are needed!
 
     * Replace $CATALINA_HOME/bin/tomcat-juli.jar with 
 output/extras/tomcat-juli.jar.
 Does this mean that I move the jar from that location and create the folders 
 to 
 put it in another location to have :C:\Program Files\Apache Software 
 Foundation\Apache Tomcat 6.0.26\output\extras?
 
 
     * Place output/extras/tomcat-juli-adapters.jar in $CATALINA_HOME/lib.I 
 cannot 

RE: Stuck at making jsvc while installing tomcat

2011-08-03 Thread Caldarale, Charles R
 From: Mladen Turk [mailto:mt...@apache.org] 
 Subject: Re: Stuck at making jsvc while installing tomcat

  Similar errors continues to the end. I thought it might be 
  some problem with my gcc compiler.

 Fix your compiler, and yes, please don't ask how, cause you
 won't get the answer here.

  --with-java-home=/usr/lib/jvm/java-1.4.2-gcj-1.4.2.0/jre

And while you're at it, throw away the toy JVM you have and install a real one 
(e.g., 1.6* from Oracle).  gcj is inappropriate for any production use.

 - 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: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org



Tomcat not releasing threads on Solaris 10

2011-08-03 Thread Dante Bell

Hi,

I hope this is going to the right people. Sorry that I don't have the
version numbers except that they are on Apache pre-fork 1.2.

In their stress test, tomcat is not killing/reclaiming threads fast
enough and eventually (after 3 hours) it runs out of threads and locks
up. OS is Solaris 10u9 SPARC and hardware is actually oversized imho.

Here is their startup:

Connector port=8019 request.TomcatAuthentication=false
protocol=AJP/1.3 redirectPort=8445 maxThreads=1000
minSpareThreads=100 maxSpareThreads=250 /

connection pool size set to 1

and

cache_timeout is 10 seconds

What other things should we be looking at?

Danté


-
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org

RE: Tomcat not releasing threads on Solaris 10

2011-08-03 Thread Caldarale, Charles R
 From: Dante Bell [mailto:dantepasqu...@cocoanet.us] 
 Subject: Tomcat not releasing threads on Solaris 10

 In their stress test, tomcat is not killing/reclaiming threads fast
 enough and eventually (after 3 hours) it runs out of threads

Tomcat does not create arbitrary, temporary threads, nor does it kill any below 
the configured limit in the Connector elements.  Odds are this is a webapp 
problem, failing to manage threads it creates.  Take a JVM thread dump, and 
find out just what the threads are.

http://wiki.apache.org/tomcat/HowTo#How_do_I_obtain_a_thread_dump_of_my_running_webapp_.3F

And do find out what versions of things you're running.

 - 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: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org



RE: AJP-APR failures on Tomcat 7.0.16 with ISAPI Redirector 1.2.32

2011-08-03 Thread eurotrans-Verlag

 -Original Message-
 From: Christopher Schultz [mailto:ch...@christopherschultz.net]
 Sent: Tuesday, July 26, 2011 6:15 PM
 To: Tomcat Users List
 Subject: Re: AJP-APR failures on Tomcat 7.0.16 with ISAPI Redirector
 1.2.32
 
 You should also null-out the reference to Tomcat's output stream.
 
 This would allow you to leak your own decorator objects but not
 interfere with Tomcat's ability to do it's own object management.
 
 Such a class would definitely be useful to post on the Wiki.
 

Hi Christopher,

thanks for your reply (and sorry for the delay).


What would be the best place to post such a class (plus the information about 
the ImageIO) on the Tomcat Wiki / is there any guide how to write articles 
there?


Thanks!

Konstantin Preißer


-
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org



Re: Tomcat not releasing threads on Solaris 10

2011-08-03 Thread Dante Bell
I do have a stack dump, but don't have enough experience to understand
it. Seems that all threads are waiting:

 java.lang.Thread.State: WAITING (on object monitor)

Size of compressed stack dump is 20k. Is that OK to attach so someone
can help look at it?

Danté



On 08/03/2011 08:44 AM, Caldarale, Charles R wrote:
 From: Dante Bell [mailto:dantepasqu...@cocoanet.us] 
 Subject: Tomcat not releasing threads on Solaris 10
 In their stress test, tomcat is not killing/reclaiming threads fast
 enough and eventually (after 3 hours) it runs out of threads
 Tomcat does not create arbitrary, temporary threads, nor does it kill any 
 below the configured limit in the Connector elements.  Odds are this is a 
 webapp problem, failing to manage threads it creates.  Take a JVM thread 
 dump, and find out just what the threads are.

 http://wiki.apache.org/tomcat/HowTo#How_do_I_obtain_a_thread_dump_of_my_running_webapp_.3F

 And do find out what versions of things you're running.

  - 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: users-unsubscr...@tomcat.apache.org
 For additional commands, e-mail: users-h...@tomcat.apache.org


-
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org



RE: Tomcat not releasing threads on Solaris 10

2011-08-03 Thread Caldarale, Charles R
 From: Dante Bell [mailto:dantepasqu...@cocoanet.us] 
 Subject: Re: Tomcat not releasing threads on Solaris 10

 Seems that all threads are waiting:
 java.lang.Thread.State: WAITING (on object monitor)

It's the rest of the trace for each thread that would be interesting.

 Size of compressed stack dump is 20k. Is that OK to attach 
 so someone can help look at it?

No, the list server strips attachments.  Post it on some publicly accessible 
web site and send us the link.

Also post your server.xml, preferably with comments removed and passwords 
obfuscated.

(And find out what version of Tomcat and JVM you're using.)

 - 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: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org



Parallel Deployment

2011-08-03 Thread Adrian Stabiszewski
Hi!

I find the new Tomcat 7 feature Parallel Deployment very interesting.
Unfortunately IMHO it is more complicated than it could be.

As I understand it, you have to add the version number after two hashes
(##). The version will then be compared as a String.
This scheme doesn't fit with my versioning system which uses Maven as build
system which uses a hyphen as version separator. 
Is there some Interface in Tomcat I could implement to integrate my version
scheme? Some ContextVersionComparator?

The second issue is about the ROOT or default context. AFAIK right now it is
not possible to deploy a WAR file with an arbitrary file name as the ROOT
context. Yes, I know you can create a ROOT.xml in conf/[Engine]/[Host] and
point to your WAR file via docBase, but this not practical if the WAR file
contains a version number.
And for the parallel deployment feature I would have to create a new
ROOT##version.xml for each version. I think this extra work is not
necessary. 

For an ideal world I have two proposals ;)

1. Allow setting the context name in the META-INF/context.xml of the WAR
file. 
Something like

Context path=/Context

(which is forbidden atm) would deploy the WAR as a ROOT context. 
Of course, if more than one WAR file wants to use the same context name the
deployment should fail.
This would allow to deploy the following files as ROOT context with
different versions:

myproject##001.war
myproject##002.war

2. Allow setting a WAR base in the conf/[Engine]/[Host]/contextname.xml
file. This is a different approach. This would allow to have one
contextname.xml for all versions. 
The WAR base attribute would simply point to the directory and the base name
of the war file. In the example about this would simply be myproject:

Context warBase=/warfiles/myproject/Context

Tomcat could search all WAR files in the warfiles folder starting with
myproject and ending with .war. 

I think the smoothest solution would be if I could take the build artifact
from maven release plugin and copy it directly into the deployment directory
;) And to add some sugar on top, tomcat would even delete the old versions
of the deployments once no sessions are connected with them.

Is this something that would be possible for tomcat? How can I help?

Regards,
Adrian.







-
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org



Re: Parallel Deployment

2011-08-03 Thread Mark Thomas
On 03/08/2011 16:11, Adrian Stabiszewski wrote:
 Hi!
 
 I find the new Tomcat 7 feature Parallel Deployment very interesting.
 Unfortunately IMHO it is more complicated than it could be.
 
 As I understand it, you have to add the version number after two hashes
 (##). The version will then be compared as a String.
 This scheme doesn't fit with my versioning system which uses Maven as build
 system which uses a hyphen as version separator. 
 Is there some Interface in Tomcat I could implement to integrate my version
 scheme? Some ContextVersionComparator?

Do you want to change the ## separator or just how the comparison is
done? The first is very unlikely to happen. There aren't that many
characters that can be used safely.

The second might be possible but not per web application as the version
determination happens much earlier in the process.

 The second issue is about the ROOT or default context. AFAIK right now it is
 not possible to deploy a WAR file with an arbitrary file name as the ROOT
 context. Yes, I know you can create a ROOT.xml in conf/[Engine]/[Host] and
 point to your WAR file via docBase, but this not practical if the WAR file
 contains a version number.
 And for the parallel deployment feature I would have to create a new
 ROOT##version.xml for each version. I think this extra work is not
 necessary. 
 
 For an ideal world I have two proposals ;)
 
 1. Allow setting the context name in the META-INF/context.xml of the WAR
 file. 
 Something like
 
 Context path=/Context
 
 (which is forbidden atm) would deploy the WAR as a ROOT context. 

Very unlikely to change due to the complications it causes with
automated deployment. Come up with a solution that allows this without
breaking auto-deployment or making the code horribly complex then things
get rather more likely.

 Of course, if more than one WAR file wants to use the same context name the
 deployment should fail.
 This would allow to deploy the following files as ROOT context with
 different versions:
 
 myproject##001.war
 myproject##002.war
 
 2. Allow setting a WAR base in the conf/[Engine]/[Host]/contextname.xml
 file. This is a different approach. This would allow to have one
 contextname.xml for all versions. 
 The WAR base attribute would simply point to the directory and the base name
 of the war file. In the example about this would simply be myproject:
 
 Context warBase=/warfiles/myproject/Context
 
 Tomcat could search all WAR files in the warfiles folder starting with
 myproject and ending with .war.

That might work. I can't see any obvious pitfalls at this point. It
would need to support WARs as well as directories (if you can support
one, supporting the other shouldn't be too hard).

 I think the smoothest solution would be if I could take the build artifact
 from maven release plugin and copy it directly into the deployment directory
 ;) And to add some sugar on top, tomcat would even delete the old versions
 of the deployments once no sessions are connected with them.

That should be do-able. The behaviour would (obviously) need to be
configurable.

 Is this something that would be possible for tomcat?

Potentially.

 How can I help?

Write some patches that implement these features. I'd suggest starting
with the auto-undeploy of old versions as I think it is less
controversial. Setting up a build environment for Tomcat trunk should be
fairly simple. Just ask questions here if you get stuck.

Mark

-
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org



AW: Parallel Deployment

2011-08-03 Thread Adrian Stabiszewski
  As I understand it, you have to add the version number after two
  hashes (##). The version will then be compared as a String.
  This scheme doesn't fit with my versioning system which uses Maven as
  build system which uses a hyphen as version separator.
  Is there some Interface in Tomcat I could implement to integrate my
  version scheme? Some ContextVersionComparator?
 
 Do you want to change the ## separator or just how the comparison is done?
 The first is very unlikely to happen. There aren't that many characters
that
 can be used safely.
 
 The second might be possible but not per web application as the version
 determination happens much earlier in the process.

Actually I would like to change both, the separator and the comparator. If
it would be possible to extract the logic which decides the version and
which compares the version into an interface, then I think it would be easy
define your own versioning scheme. When I think about it, I would only need
to change the ContextVersionExtrator.  The class would take the filename
and create a context name and a version number of it. 
For example, if my war filename is myproject-1.5 it would return
myproject and convert the version to some safe string like 105 to be
able to handle versions like 1.10 which would become 110.


  1. Allow setting the context name in the META-INF/context.xml of the
  WAR file.
  Something like
 
  Context path=/Context
 
  (which is forbidden atm) would deploy the WAR as a ROOT context.
 
 Very unlikely to change due to the complications it causes with automated
 deployment. Come up with a solution that allows this without breaking
auto-
 deployment or making the code horribly complex then things get rather
 more likely.

To be honest I favored this solution. Now I would even suggest to add the
version as an attribute of the Context tag like:

Context path= version=1.05/Context

This would reduce the need for safe characters in the filename.

When you say if causes complications with automated deployment, what do you
mean by that? Does this happen when Tomcat finds a new WAR File in its
appBase?
Don't you think that Tomcat relies too much on filenames when it comes to
context names? I think it is good to have some convention over
configuration, but I'm missing the configuration options here.

Regards,
Adrian.




-
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org



Re: Missing files for Apache and Log4J

2011-08-03 Thread Mark Eggers
- Original Message -

 From: A Df abbey_dragonfor...@yahoo.com
 To: Tomcat Users List users@tomcat.apache.org; Mark Eggers 
 its_toas...@yahoo.com
 Cc: 
 Sent: Wednesday, August 3, 2011 3:17 AM
 Subject: Re: Missing files for Apache and Log4J
 
 Hello Mates:
 
 I got the log file to work however, it does not have the date appended like 
 the 
 usual Tomcat Logs and does not creating a rolling daily file. I also wanted 
 to 
 have control over the usual logs that Tomcat produced so I combined your 
 instructions with those from this other website at 
 http://mrhaki.blogspot.com/2011/02/configure-log4j-on-tomcat.html to get the 
 content for the properties file. However, the problems are:
     * the log files do not have the .log extension so they do not show up 
 file 
 type as text document instead just a type as file
 
     * the date is not being appended to the name
 My code below is in the properties file in the Project default package folder 
 as 
 Mark Eggers suggested. I am not sure which property to modify to get the .log 
 extension and the date appended.
 
 
 
 #log4j.properties File
 
 log4j.rootLogger=INFO, CATALINA, CONSOLE
 
 #Tweet Tag Processor
 log4j.logger.org.tweettagprocessorpackage=INFO, R
 
 # Define all the appenders
 
 # Configuration for a rolling log file.
 log4j.appender.R=org.apache.log4j.DailyRollingFileAppender
 # Edit the next line to point to your logs directory.
 # The last part of the name is the log file name.
 log4j.appender.R.file=${catalina.base}/logs/tagprocessor.
 log4j.appender.R.encoding=UTF-8
 # Roll-over the log once per day
 log4j.appender.R.DatePattern='.'-MM-dd'.log'
 # Print the date in ISO 8601 format
 log4j.appender.R.layout=org.apache.log4j.PatternLayout
 log4j.appender.R.layout.ConversionPattern=%d [%t] %-5p %c - %m%n
 log4j.appender.R.append=true
 
 log4j.appender.CATALINA=org.apache.log4j.DailyRollingFileAppender
 log4j.appender.CATALINA.file=${catalina.base}/logs/catalina-my.
 log4j.appender.CATALINA.encoding=UTF-8
 # Roll-over the log once per day
 log4j.appender.CATALINA.DatePattern='.'-MM-dd'.log'
 log4j.appender.CATALINA.layout=org.apache.log4j.PatternLayout
 log4j.appender.CATALINA.layout.ConversionPattern = %d [%t] %-5p %c - %m%n
 log4j.appender.CATALINA.append=true
 
 log4j.appender.LOCALHOST=org.apache.log4j.DailyRollingFileAppender
 log4j.appender.LOCALHOST.file=${catalina.base}/logs/localhost-my.
 log4j.appender.LOCALHOST.encoding=UTF-8
 log4j.appender.LOCALHOST.DatePattern='.'-MM-dd'.log'
 log4j.appender.LOCALHOSTlayout=org.apache.log4j.PatternLayout
 log4j.appender.LOCALHOST.layout.ConversionPattern = %d [%t] %-5p %c - %m%n
 log4j.appender.LOCALHOST.append=true
 
 log4j.appender.MANAGER=org.apache.log4j.DailyRollingFileAppender
 log4j.appender.MANAGER.file=${catalina.base}/logs/manager-my.
 log4j.appender.MANAGER.encoding=UTF-8
 log4j.appender.MANAGER.DatePattern='.'-MM-dd'.log'
 log4j.appender.MANAGER.layout=org.apache.log4j.PatternLayout
 log4j.appender.MANAGER.layout.ConversionPattern = %d [%t] %-5p %c - %m%n
 log4j.appender.MANAGER.append=true
 
 log4j.appender.HOST-MANAGER=org.apache.log4j.DailyRollingFileAppender
 log4j.appender.HOST-MANAGER.file=${catalina.base}/logs/host-manager-my.
 log4j.appender.HOST-MANAGER.encoding=UTF-8
 log4j.appender.HOST-MANAGER.DatePattern='.'-MM-dd'.log'
 log4j.appender.HOST-MANAGER.layout=org.apache.log4j.PatternLayout
 log4j.appender.HOST-MANAGER.layout.ConversionPattern = %d [%t] %-5p %c - %m%n
 log4j.appender.HOST-MANAGER.append=true
 
 log4j.appender.CONSOLE=org.apache.log4j.ConsoleAppender
 log4j.appender.CONSOLE.encoding=UTF-8
 log4j.appender.CONSOLE.layout=org.apache.log4j.PatternLayout
 log4j.appender.CONSOLE.layout.ConversionPattern = %d [%t] %-5p %c - %m%n
 
 # Configure which loggers log to which appenders
 log4j.logger.org.apache.catalina.core.ContainerBase.[Catalina].[localhost]=INFO,
  
 LOCALHOST
 log4j.logger.org.apache.catalina.core.ContainerBase.[Catalina].[localhost].[/manager]=\
   INFO, MANAGER
 log4j.logger.org.apache.catalina.core.ContainerBase.[Catalina].[localhost].[/host-manager]=\
   INFO, HOST-MANAGER


. . . . lots of stuff deleted . . . .

In general:

Do not mix application logging and Tomcat logging in the same
properties file. Follow Chris's excellent comments and the
instructions at:

http://tomcat.apache.org/tomcat-6.0-doc/logging.html

to enable Tomcat to use log4j. Unfortunately I didn't keep Chris's mail 
message, but you should be able to find it in the archives.

Configure Tomcat logging in $CATALINA_BASE/conf/logging.properties and
your application logging in
$CATALINA_BASE/webapps/AppName/WEB-INF/classes/log4j.properties

On file naming:

From the javadoc for DailyRollingFileAppender:

For example, if the File option is set to /foo/bar.log and the
DatePattern set to '.'-MM-dd, on 2001-02-16 at midnight, the
logging file /foo/bar.log will be copied to /foo/bar.log.2001-02-16
and logging for 2001-02-17 will continue in /foo/bar.log 

Re: AW: Parallel Deployment

2011-08-03 Thread Mark Thomas
On 03/08/2011 19:29, Adrian Stabiszewski wrote:
 As I understand it, you have to add the version number after two
 hashes (##). The version will then be compared as a String.
 This scheme doesn't fit with my versioning system which uses Maven as
 build system which uses a hyphen as version separator.
 Is there some Interface in Tomcat I could implement to integrate my
 version scheme? Some ContextVersionComparator?

 Do you want to change the ## separator or just how the comparison is done?
 The first is very unlikely to happen. There aren't that many characters
 that
 can be used safely.

 The second might be possible but not per web application as the version
 determination happens much earlier in the process.
 
 Actually I would like to change both, the separator and the comparator. If
 it would be possible to extract the logic which decides the version and
 which compares the version into an interface, then I think it would be easy
 define your own versioning scheme. When I think about it, I would only need
 to change the ContextVersionExtrator.  The class would take the filename
 and create a context name and a version number of it. 
 For example, if my war filename is myproject-1.5 it would return
 myproject and convert the version to some safe string like 105 to be
 able to handle versions like 1.10 which would become 110.

Hmm. You should get the extension point in if the code isn't too ugly (I
know I wrote the parallel deployment code but I haven't looked at it in
almost a year and I don't recall exactly where that is extracted) but
you certainly won't get that behaviour by default since /myproject-1.5
is a perfectly valid context path.

 1. Allow setting the context name in the META-INF/context.xml of the
 WAR file.
 Something like

 Context path=/Context

 (which is forbidden atm) would deploy the WAR as a ROOT context.

 Very unlikely to change due to the complications it causes with automated
 deployment. Come up with a solution that allows this without breaking
 auto-
 deployment or making the code horribly complex then things get rather
 more likely.
 
 To be honest I favored this solution. Now I would even suggest to add the
 version as an attribute of the Context tag like:
 
 Context path= version=1.05/Context
 
 This would reduce the need for safe characters in the filename.
 
 When you say if causes complications with automated deployment, what do you
 mean by that? Does this happen when Tomcat finds a new WAR File in its
 appBase?

Yes. Details in the Context and Host docs.

 Don't you think that Tomcat relies too much on filenames when it comes to
 context names?

No. The switch over to using just the file name was to avoid a host of
problems around automated deployment associated with the approach that
you are currently suggesting. The problem was mainly one of complexity.
Dealing with all the various edge cases and conflicts got to the point
where a simpler solution was required. The file name approach has been
refined slightly (mainly around the extraction or not of context.xml
files) but the fundamental basis has remained unchanged since it was
first implemented and we haven't yet found a use case it can't meet.
Some folks don't like the configuration required for their particular
use case but that is a different issue. Alternative suggestions are
welcome but they are going to have to stand up to scrutiny.

 I think it is good to have some convention over
 configuration, but I'm missing the configuration options here.

I haven't seen you describe anything you can't do with the current
scheme so far, just some things you would prefer to configure
differently. If you can find a way to do what you want that doesn't
cause a bunch of problems elsewhere (either for other users or in
maintenance) then patches to achieve those changes are likely to find
their way into the code base.

As an aside, the only thing I am aware of you can't do with the current
scheme is have a context path of /ROOT and you can do that if you
define the context in server.xml.

Mark

-
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org



Re: Problem with threads in stage Service (Tomcat 7.0.14)

2011-08-03 Thread Alejandro Henao González
Thanks to all. The problem was the static hashmap. I removed the static keyword 
to the variable and problem solved.

- Mensaje original -

De: Christopher Schultz ch...@christopherschultz.net
Para: Tomcat Users List users@tomcat.apache.org
Enviados: Lunes, 1 de Agosto 2011 20:11:27
Asunto: Re: Problem with threads in stage Service (Tomcat 7.0.14)

-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

Alejandro,

On 7/29/2011 11:55 AM, Alejandro Henao González wrote:
 public class HTMLEncoder { private static Map mapChar2HTMLEntity;

 private final static char [] characters = {
 'á','ú','ó','é','í','ñ','Á','Ú','Ó','É','Í','°','ü' }; private final
 static String[] entities = {
 aacute;,uacute;,oacute;,eacute;,iacute;,ntilde;,Aacute;,Uacute;,Oacute;,Eacute;,Iacute;,deg;,uuml;
 };

 public HTMLEncoder() { mapChar2HTMLEntity= new HashMap(); int
 longueur = characters.length;

 for (int i = 0; i  longueur; i++) mapChar2HTMLEntity.put(new
 Character(characters[i]), entities[i]); }

So you have Character - String (entity reference). Your Map is not
synchronized, but it doesn't have to be: you are only calling get() on
it so there shouldn't be any synchronization issues here.

 public String encode(String s) { int longueur = s.length(); final
 StringBuffer sb = new StringBuffer(longueur * 2);

Big buffer every time?

 char ch;

 for (int i =0; i  longueur ; ++i) { ch = s.charAt(i);

 if ((ch = 63  ch = 90) || (ch = 97  ch = 122)) sb.append(ch);
 else { String ss = (String)mapChar2HTMLEntity.get(new
 Character(ch));

New Character object every time? Mmm. You might want to choose a more
optimized storage system so you don't have to create a new object every
time.

 if(ss==null) sb.append(ch); else sb.append(ss); } } return
 sb.toString(); }

Aside from any other strange issues you are having, you might be wasting
a lot of time (and invoking a lot of GC) by creating a large
StringBuffer for every invocation. You might want some more complicated
logic to determine if you even need to create such a buffer.

Honestly, I don't see much wrong with this class. I don't see any use of
System.gc and I don't see any connection reset. Was there a post that I
missed?

- -chris
-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.10 (MingW32)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/

iEYEARECAAYFAk43Tr4ACgkQ9CaO5/Lv0PBk4QCglB4MNYVbEvwsqZFwiOYupAUv
J84AnRAnw2o6PwTRiaNnNFc9iyNq0pUS
=UWQu
-END PGP SIGNATURE-

-
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org




Log ownership when running Tomcat using jsvc

2011-08-03 Thread Jorge Medina
I run Tomcat in a Solaris 10 SPARC machine using jsvc through a init script.

jsvc is started by root, but I specify the -user option to change to
the application user.
I use the option -outfile and  -errfile to specify where to direct
stdout and stderr, catalina.out and catalina.err in my
environment.

I am getting the following log files:

# ls -l
-rw---   1 root root   0 Aug  3 15:23 admin.2011-08-03.log
-rw---   1 root root7606 Aug  3 15:26 catalina.2011-08-03.log
-rw---   1 root root   0 Aug  3 15:23 catalina.err
-rw---   1 root root   0 Aug  3 15:23 catalina.out
-rw---   1 root root   0 Aug  3 15:23
host-manager.2011-08-03.log
-rw---   1 root root 126 Aug  3 15:27 localhost.2011-08-03.log
-rw---   1 root root   0 Aug  3 15:23 manager.2011-08-03.log
-rw-rw-r--   1 application   svcjava93760 Aug  3 15:27 servicelog

As expected, catalina.out and catalina.err are owned by root. I
minimize any output to these files.
Also as I expected, the logs of my webapp (servicelog) is owned by
the  application user and it is created with permissions 664 (since
I specify the umask 002)

But, why are the other logs produced by Tomcat owned by root ? Isn't
the whole JVM changing to the application user?
Is there a way to have these logs also owned by application user
whenever they get created?

The only difference I am aware of is that Tomcat (catalina), the
manager and host-manager webapps use JULI, while my web app uses
Log4j.

Is JULI running before jsvc switches to the application user?


-Jorge

-
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org



Re: Log ownership when running Tomcat using jsvc

2011-08-03 Thread Jorge Medina
Just in case is needed

I use Tomcat 6.0.32 and jsvc 1.0.5 running under Java 1.6.0_24


On Wed, Aug 3, 2011 at 4:11 PM, Jorge Medina
cerebrotecnolog...@gmail.com wrote:
 I run Tomcat in a Solaris 10 SPARC machine using jsvc through a init script.

 jsvc is started by root, but I specify the -user option to change to
 the application user.
 I use the option -outfile and  -errfile to specify where to direct
 stdout and stderr, catalina.out and catalina.err in my
 environment.

 I am getting the following log files:

 # ls -l
 -rw---   1 root root   0 Aug  3 15:23 admin.2011-08-03.log
 -rw---   1 root root7606 Aug  3 15:26 catalina.2011-08-03.log
 -rw---   1 root root   0 Aug  3 15:23 catalina.err
 -rw---   1 root root   0 Aug  3 15:23 catalina.out
 -rw---   1 root root   0 Aug  3 15:23
 host-manager.2011-08-03.log
 -rw---   1 root root 126 Aug  3 15:27 localhost.2011-08-03.log
 -rw---   1 root root   0 Aug  3 15:23 manager.2011-08-03.log
 -rw-rw-r--   1 application   svcjava93760 Aug  3 15:27 servicelog

 As expected, catalina.out and catalina.err are owned by root. I
 minimize any output to these files.
 Also as I expected, the logs of my webapp (servicelog) is owned by
 the  application user and it is created with permissions 664 (since
 I specify the umask 002)

 But, why are the other logs produced by Tomcat owned by root ? Isn't
 the whole JVM changing to the application user?
 Is there a way to have these logs also owned by application user
 whenever they get created?

 The only difference I am aware of is that Tomcat (catalina), the
 manager and host-manager webapps use JULI, while my web app uses
 Log4j.

 Is JULI running before jsvc switches to the application user?


 -Jorge


-
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org



Re: Tomcat not releasing threads on Solaris 10

2011-08-03 Thread Dante Bell
I put the cleansed information on my blog (which got totally messed up
with the latest WP upgrade, but that's a different issue!!)

Click on this url for config files and for the thread dump:
http://wp.me/plPvN-ai

I've check bugzilla and this issue seems to be different to the other
bugs when there was a thread issue.

Thanks!

On 08/03/2011 10:44 AM, Caldarale, Charles R wrote:
 From: Dante Bell [mailto:dantepasqu...@cocoanet.us] 
 Subject: Re: Tomcat not releasing threads on Solaris 10
 Seems that all threads are waiting:
 java.lang.Thread.State: WAITING (on object monitor)
 It's the rest of the trace for each thread that would be interesting.

 Size of compressed stack dump is 20k. Is that OK to attach 
 so someone can help look at it?
 No, the list server strips attachments.  Post it on some publicly accessible 
 web site and send us the link.

 Also post your server.xml, preferably with comments removed and passwords 
 obfuscated.

 (And find out what version of Tomcat and JVM you're using.)

  - 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: users-unsubscr...@tomcat.apache.org
 For additional commands, e-mail: users-h...@tomcat.apache.org


-
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org



Re: Tomcat not releasing threads on Solaris 10

2011-08-03 Thread Igor Cicimov
Maybe try to use cachesize ajp13 property in worker.properties together
with cache_timeout to limit the apache thread count towards tomcat.
 If cachesize is not set, the connection cache support is disabled.
So sounds like cache_timeout doesn't have any effect if cachesize isn't set.

Igor

On Thu, Aug 4, 2011 at 11:58 AM, Dante Bell dantepasqu...@cocoanet.uswrote:

 I put the cleansed information on my blog (which got totally messed up
 with the latest WP upgrade, but that's a different issue!!)

 Click on this url for config files and for the thread dump:
 http://wp.me/plPvN-ai

 I've check bugzilla and this issue seems to be different to the other
 bugs when there was a thread issue.

 Thanks!

 On 08/03/2011 10:44 AM, Caldarale, Charles R wrote:
  From: Dante Bell [mailto:dantepasqu...@cocoanet.us]
  Subject: Re: Tomcat not releasing threads on Solaris 10
  Seems that all threads are waiting:
  java.lang.Thread.State: WAITING (on object monitor)
  It's the rest of the trace for each thread that would be interesting.
 
  Size of compressed stack dump is 20k. Is that OK to attach
  so someone can help look at it?
  No, the list server strips attachments.  Post it on some publicly
 accessible web site and send us the link.
 
  Also post your server.xml, preferably with comments removed and passwords
 obfuscated.
 
  (And find out what version of Tomcat and JVM you're using.)
 
   - 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: users-unsubscr...@tomcat.apache.org
  For additional commands, e-mail: users-h...@tomcat.apache.org
 

 -
 To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
 For additional commands, e-mail: users-h...@tomcat.apache.org




503 error - service not available

2011-08-03 Thread Dave Filchak


Not sure what happened here. The app was working just fine until today. 
I am getting a 503 Service temporarily unavailable error when trying to 
connect to a tomcat site using Apache as the front end and mod_jk 
connectors. I have verified that tomcat is running on the correct ports 
using:netstat -atp | grep java. I see no errors in the message logs ( we 
are on CentOS by the way ) but I do see:


|[Wed Aug 03 18:49:24 2011] [15605:1199618400] [info] 
ajp_service::jk_ajp_common.c (2540): (exodus) sending request to tomcat failed 
(recoverable), because of error during request sending (attempt=2)
[Wed Aug 03 18:49:24 2011] [15605:1199618400] [error] 
ajp_service::jk_ajp_common.c (2559): (exodus) connecting to tomcat failed.
[Wed Aug 03 18:49:24 2011] exodus www.exodusdecoded.com 0.198512
[Wed Aug 03 18:49:24 2011] [15605:1199618400] [info] jk_handler::mod_jk.c 
(2618): Service error=-3 for worker=exodus
[Wed Aug 03 18:50:46 2011] [15851:1189128544] [info] 
jk_open_socket::jk_connect.c (622): connect to 174.122.30.18:8010 failed 
(errno=111)
[Wed Aug 03 18:50:46 2011] [15851:1189128544] [info] 
ajp_connect_to_endpoint::jk_ajp_common.c (959): Failed opening socket to 
(174.122.30.18:8010) (errno=111)
[Wed Aug 03 18:50:46 2011] [15851:1189128544] [error] 
ajp_send_request::jk_ajp_common.c (1585): (exodus) connecting to backend 
failed. Tomcat is probably not started or is listening on the wrong port 
(errno=111)
[Wed Aug 03 18:50:46 2011] [15851:1189128544] [info] 
ajp_service::jk_ajp_common.c (2540): (exodus) sending request to tomcat failed 
(recoverable), because of error during request sending (attempt=1)
[Wed Aug 03 18:50:46 2011] [15851:1189128544] [info] 
jk_open_socket::jk_connect.c (622): connect to 174.122.30.18:8010 failed 
(errno=111)
[Wed Aug 03 18:50:46 2011] [15851:1189128544] [info] 
ajp_connect_to_endpoint::jk_ajp_common.c (959): Failed opening socket to 
(174.122.30.18:8010) (errno=111)
[Wed Aug 03 18:50:46 2011] [15851:1189128544] [error] 
ajp_send_request::jk_ajp_common.c (1585): (exodus) connecting to backend 
failed. Tomcat is probably not started or is listening on the wrong port 
(errno=111)
[Wed Aug 03 18:50:46 2011] [15851:1189128544] [info] 
ajp_service::jk_ajp_common.c (2540): (exodus) sending request to tomcat failed 
(recoverable), because of error during request sending (attempt=2)
[Wed Aug 03 18:50:46 2011] [15851:1189128544] [error] 
ajp_service::jk_ajp_common.c (2559): (exodus) connecting to tomcat failed.
[Wed Aug 03 18:50:46 2011] exodus www.exodusdecoded.com 0.197989
[Wed Aug 03 18:50:46 2011] [15851:1189128544] [info] jk_handler::mod_jk.c 
(2618): Service error=-3 for worker=exodus

|

in the mod_jk.log file. Apache is running. I am stumped but really need 
to get this back running if anyone out there is more experienced at 
tomcat and apache connectors than I am, which wouldn't take much ;-)


Cheers,

Dave



Re: 503 error - service not available

2011-08-03 Thread Igor Cicimov
Obviously apache can't connect to tomcat. Any firewall/load balancer changes
maybe done last night between apache and tomcat? Can you access tomcat apps
bypassing apache? Can you telnet to tomcat server on the tomcat port from
the apache? Any errors in the tomcat log? Have you tried restarting tomcat?


Igor

On Thu, Aug 4, 2011 at 12:28 PM, Dave Filchak sub...@zuka.net wrote:


 Not sure what happened here. The app was working just fine until today. I
 am getting a 503 Service temporarily unavailable error when trying to
 connect to a tomcat site using Apache as the front end and mod_jk
 connectors. I have verified that tomcat is running on the correct ports
 using:netstat -atp | grep java. I see no errors in the message logs ( we are
 on CentOS by the way ) but I do see:

 |[Wed Aug 03 18:49:24 2011] [15605:1199618400] [info]
 ajp_service::jk_ajp_common.c (2540): (exodus) sending request to tomcat
 failed (recoverable), because of error during request sending (attempt=2)
 [Wed Aug 03 18:49:24 2011] [15605:1199618400] [error]
 ajp_service::jk_ajp_common.c (2559): (exodus) connecting to tomcat failed.
 [Wed Aug 03 18:49:24 2011] exodus www.exodusdecoded.com 0.198512
 [Wed Aug 03 18:49:24 2011] [15605:1199618400] [info] jk_handler::mod_jk.c
 (2618): Service error=-3 for worker=exodus
 [Wed Aug 03 18:50:46 2011] [15851:1189128544] [info]
 jk_open_socket::jk_connect.c (622): connect to 174.122.30.18:8010 failed
 (errno=111)
 [Wed Aug 03 18:50:46 2011] [15851:1189128544] [info]
 ajp_connect_to_endpoint::jk_**ajp_common.c (959): Failed opening socket to
 (174.122.30.18:8010) (errno=111)
 [Wed Aug 03 18:50:46 2011] [15851:1189128544] [error]
 ajp_send_request::jk_ajp_**common.c (1585): (exodus) connecting to backend
 failed. Tomcat is probably not started or is listening on the wrong port
 (errno=111)
 [Wed Aug 03 18:50:46 2011] [15851:1189128544] [info]
 ajp_service::jk_ajp_common.c (2540): (exodus) sending request to tomcat
 failed (recoverable), because of error during request sending (attempt=1)
 [Wed Aug 03 18:50:46 2011] [15851:1189128544] [info]
 jk_open_socket::jk_connect.c (622): connect to 174.122.30.18:8010 failed
 (errno=111)
 [Wed Aug 03 18:50:46 2011] [15851:1189128544] [info]
 ajp_connect_to_endpoint::jk_**ajp_common.c (959): Failed opening socket to
 (174.122.30.18:8010) (errno=111)
 [Wed Aug 03 18:50:46 2011] [15851:1189128544] [error]
 ajp_send_request::jk_ajp_**common.c (1585): (exodus) connecting to backend
 failed. Tomcat is probably not started or is listening on the wrong port
 (errno=111)
 [Wed Aug 03 18:50:46 2011] [15851:1189128544] [info]
 ajp_service::jk_ajp_common.c (2540): (exodus) sending request to tomcat
 failed (recoverable), because of error during request sending (attempt=2)
 [Wed Aug 03 18:50:46 2011] [15851:1189128544] [error]
 ajp_service::jk_ajp_common.c (2559): (exodus) connecting to tomcat failed.
 [Wed Aug 03 18:50:46 2011] exodus www.exodusdecoded.com 0.197989
 [Wed Aug 03 18:50:46 2011] [15851:1189128544] [info] jk_handler::mod_jk.c
 (2618): Service error=-3 for worker=exodus

 |

 in the mod_jk.log file. Apache is running. I am stumped but really need to
 get this back running if anyone out there is more experienced at tomcat and
 apache connectors than I am, which wouldn't take much ;-)

 Cheers,

 Dave




Re: Sharing session between different webapps under same tomcat

2011-08-03 Thread Ron McNulty

Hi Jany

I think it is possible to share sessions across contexts. Portal 
applications need to do this. Try 
http://jee-bpel-soa.blogspot.com/2009/06/session-sharing-in-apache-tomcat.html


Regards

Ron

- Original Message - 
From: Jany Jose jany.j...@gmail.com

To: Tomcat Users List users@tomcat.apache.org
Sent: Wednesday, August 03, 2011 6:23 PM
Subject: Sharing session between different webapps under same tomcat



Hi,

We are using tomcat 6.0.26. For one use case we want to re-use the session
objects created in one web application in another web application which 
are
running under the same tomcat. Please let me know is it supported and if 
yes

how to achieve that.

Thanks
Jany




-
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org