Re: tomcats starting with 200 threads

2022-09-19 Thread Jonathan Yom-Tov
hi Christopher, Configuration follows: On Mon, Sep 19, 2022 at 7:45 PM Christopher Schultz < ch...@christopherschultz.net> wrote: > Jon, > > On 9/19/22 10:46, J

tomcats starting with 200 threads

2022-09-19 Thread Jonathan Yom-Tov
hi, Sometimes one of our production Tomcats will start with the maximum (200) number of threads in the https pool. That is, it doesn't start with some minimum and works its way up to the maximum, it immediately starts with the maximum. There's no reason for it since most of the threads stay idle t

Re: thread pool count never goes down

2021-12-23 Thread Jonathan Yom-Tov
Got it, thanks. Happy holidays ! On Thu, 23 Dec 2021, 17:02 Christopher Schultz, < ch...@christopherschultz.net> wrote: > Jon, > > On 12/21/21 04:55, Jonathan Yom-Tov wrote: > > When I look at the source (and docs) I can see that the > > StandardThreadExecutor, whic

Re: thread pool count never goes down

2021-12-21 Thread Jonathan Yom-Tov
connector pool does decrease sometimes. So I wonder what could be causing the executor to decide not to decrease the count in this specific instance? On Mon, Dec 20, 2021 at 9:47 PM Christopher Schultz < ch...@christopherschultz.net> wrote: > Jon, > > On 12/19/21 12:19, Jonatha

Re: thread pool count never goes down

2021-12-19 Thread Jonathan Yom-Tov
hi Chris, Sorry for the late reply, I didn't see your reply for some reason. Here's the relevant connector configuration: On Tue, Dec 7, 2021 at 10:28 PM Christopher Schultz < ch...@christopherschultz.net> wrote: > Jon, > > On 12/6/21 10:28, Jonathan Yom-Tov w

thread pool count never goes down

2021-12-06 Thread Jonathan Yom-Tov
hi, I have a single instance of Tomcat (version 9.0.54) in which the thread count on a connector thread pool doesn't reduce despite most of the threads (198/200) being idle. If I understand correctly the default idle time before a thread is reaped is 60 seconds, but this situation persists for hou

Re: Implementing Store and getting java.io.StreamCorruptedException

2020-05-26 Thread Jonathan Yom-Tov
tly. On Fri, May 22, 2020 at 6:02 PM Christopher Schultz < ch...@christopherschultz.net> wrote: > -BEGIN PGP SIGNED MESSAGE- > Hash: SHA256 > > Jonathan, > > On 5/20/20 10:55, Jonathan Yom-Tov wrote: > > I implemented my own Store which uses Redis to persist sess

Implementing Store and getting java.io.StreamCorruptedException

2020-05-20 Thread Jonathan Yom-Tov
I implemented my own Store which uses Redis to persist sessions (I'm using Jedis as the interface library). I copied most of the load()/save() code from FileStore. When my Store loads the session from Redis I consistently get java.io.StreamCorruptedException: Inconsistent vector internals. Any idea

Re: persistentmanager loads only part of session?

2020-05-18 Thread Jonathan Yom-Tov
PGP SIGNED MESSAGE- > Hash: SHA256 > > Jonathan, > > On 5/18/20 12:52, Jonathan Yom-Tov wrote: > > I see the persisted copy in the file and it has two keys, so I > > don't think that's it. It's probably some sort of parallelism issue > > since it happ

Re: persistentmanager loads only part of session?

2020-05-18 Thread Jonathan Yom-Tov
Mark Thomas, wrote: > On 18/05/2020 15:23, Jonathan Yom-Tov wrote: > > Here's my setup: I have two Tomcats using PersistentManager with > FileStore > > to store sessions on a NFS they both have access to. Inside the session > > there's an object which contains

persistentmanager loads only part of session?

2020-05-18 Thread Jonathan Yom-Tov
Here's my setup: I have two Tomcats using PersistentManager with FileStore to store sessions on a NFS they both have access to. Inside the session there's an object which contains a map. I also have a request listener that logs the contents of the map on every request. I kill one Tomcat and I can

Re: ClassNotFoundException when loading session from disk

2020-05-13 Thread Jonathan Yom-Tov
that (rather than in context.xml) solved the issue. On Tue, May 12, 2020 at 9:45 PM Mark Thomas wrote: > On 12/05/2020 18:38, Jonathan Yom-Tov wrote: > > I'm trying to use PersistentManager with FileStore to load sessions from > > disk. Serialization goes ok but when the

Re: seamless restart

2020-05-12 Thread Jonathan Yom-Tov
session to Redis and overwrite the session of the first request. I can't think of an easy way to get around this. On Tue, May 12, 2020 at 8:39 PM Mark Eggers wrote: > Jonathan, > > On 5/12/2020 8:20 AM, Jonathan Yom-Tov wrote: > > The problem is that my application is r

ClassNotFoundException when loading session from disk

2020-05-12 Thread Jonathan Yom-Tov
I'm trying to use PersistentManager with FileStore to load sessions from disk. Serialization goes ok but when the session is loaded I get an exception deserializing one of my application's classes. [2020-05-12 09:08:52] [SEVERE] Session: 6325A48BA1D2FC79105C7F4B0A76CB74.worker1; java.lang.ClassNot

Re: seamless restart

2020-05-12 Thread Jonathan Yom-Tov
ssions when the server goes down. But I still have to solve the issues I mentioned. On Tue, May 12, 2020 at 6:06 PM Christopher Schultz < ch...@christopherschultz.net> wrote: > -BEGIN PGP SIGNED MESSAGE- > Hash: SHA256 > > Jonathan, > > On 5/12/20 05:51, Jonathan Y

Re: how do I switch class loaders

2020-05-12 Thread Jonathan Yom-Tov
gt; > On 5/8/20 15:03, Jonathan Yom-Tov wrote: > > Got it! Using http://jhades.github.io/ it was quick and easy to > > find out that the offending class was indeed loaded from two > > different jar files. After I removed one of them casting worked > > with n

seamless restart

2020-05-12 Thread Jonathan Yom-Tov
I have an application which changes the state of user sessions in lots of places in the code. Is it possible to do a seamless switch of Tomcat servers, preserving all sessions? I know I can use PersistentManager to persist sessions and load them. I can think of two strategies: 1. Persist sessi

Re: how do I switch class loaders

2020-05-08 Thread Jonathan Yom-Tov
> To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org > For additional commands, e-mail: users-h...@tomcat.apache.org > > -- [image: SysAid Technologies] <http://www.sysaid.com/?utm_source=signature&utm_medium=email&utm_campaign=sysaid-logo> Jonathan Yom-T

Re: how do I switch class loaders

2020-05-08 Thread Jonathan Yom-Tov
ot; appended at the end.This is > an "anonymous inner class" [1] > > Cheers, > > Luis > > [1] > > https://stackoverflow.com/questions/11388840/java-compiled-classes-contain-dollar-signs > > > El vie., 8 may. 2020 a las 11:52, Jonathan Yom-Tov (< &g

Re: how do I switch class loaders

2020-05-08 Thread Jonathan Yom-Tov
isson-tomcat-9-3.12.2.jar] [Loaded org.redisson.tomcat.RedissonSessionManager$2 from file:/C:/dev/tomcat.9.0.19/lib/redisson-tomcat-9-3.12.2.jar] On Fri, May 8, 2020 at 11:04 AM Olaf Kock wrote: > > On 08.05.20 09:37, Jonathan Yom-Tov wrote: > > Thanks Mark. Just tried that. I put the re

Re: how do I switch class loaders

2020-05-08 Thread Jonathan Yom-Tov
Accessible(true); StandardSession stdSession = (StandardSession) facadeSessionField.get(session); return stdSession.getManager(); } On Thu, May 7, 2020 at 11:52 PM Mark Thomas wrote: > On 07/05/2020 21:36, Jonathan Yom-Tov wrote: > > My application uses Redisson (a client which persists

how do I switch class loaders

2020-05-07 Thread Jonathan Yom-Tov
My application uses Redisson (a client which persists the session to Redis). There are two Redisson jar files located in $CATALINA_HOME/lib, so if I understand the docs correctly they're loaded by the common class loader. I want to access the RedissonSessionManager class during a request. The prob

Re: Is it possible to programmatically compile jsp files?

2020-03-25 Thread Jonathan Yom-Tov
Sounds good. What would be the best way of evaluating the result so I can cache it? On Wed, Mar 25, 2020 at 4:03 PM Olaf Kock wrote: > > On 25.03.20 14:51, Jonathan Yom-Tov wrote: > > I think I phrased my question incorrectly. What I want to do is to cache > > the HTML resul

Re: Is it possible to programmatically compile jsp files?

2020-03-25 Thread Jonathan Yom-Tov
better way? On Tue, Mar 24, 2020 at 11:59 PM Christopher Schultz < ch...@christopherschultz.net> wrote: > -BEGIN PGP SIGNED MESSAGE- > Hash: SHA256 > > Jonathan, > > On 3/24/20 10:44, Jonathan Yom-Tov wrote: > > I have a set of jsp files. These jsps' compi

Is it possible to programmatically compile jsp files?

2020-03-24 Thread Jonathan Yom-Tov
I have a set of jsp files. These jsps' compilation result changes whenever a variable in my cache changes. I want to compile them whenever that variable changes so they're ready to serve without going through the normal pipeline. Is that possible?

Re: valve execution order

2020-03-23 Thread Jonathan Yom-Tov
; On 3/23/20 09:59, Mark Thomas wrote: > > On 23/03/2020 13:13, Jonathan Yom-Tov wrote: > >> I'm trying to create a valve which will prevent another valve > >> from working in case a particular request is made. Is there a way > >> to control the valve execution o

valve execution order

2020-03-23 Thread Jonathan Yom-Tov
I'm trying to create a valve which will prevent another valve from working in case a particular request is made. Is there a way to control the valve execution order so that I can inject my valve right before the valve I want to stop?

ajp port chosen at random

2020-02-19 Thread Jonathan Yom-Tov
hi, I'm configuring a two tomcat cluster with session replication and encountering a strange issue. One of the tomcats appears to choose the AJP connector port at random. The other tomcat obeys the port directive from its connector without a problem. This is doubly strange because the second tomca

Re: cloud cluster

2020-02-19 Thread Jonathan Yom-Tov
h: SHA256 > > Jon, > > On 2/16/20 10:06, Jonathan Yom-Tov wrote: > > What kind of configuration do people usually use when deploying on > > a public cloud (e.g. AWS)? An auto-scaling cluster with session > > replication? A auto-scaling cluster with all sessions stored

cloud cluster

2020-02-16 Thread Jonathan Yom-Tov
hi, What kind of configuration do people usually use when deploying on a public cloud (e.g. AWS)? An auto-scaling cluster with session replication? A auto-scaling cluster with all sessions stored in an external cache? Jon.