RE: PermGen space [ot]

2007-02-16 Thread Caldarale, Charles R
> From: Leon Rosenberg [mailto:[EMAIL PROTECTED] > Subject: Re: PermGen space [ot] > > but if the factory is a pure static utility, calling > ASingleton myCopy = ASingletonFactory.getASingleton(); > will leave no references to the factory class :-) Unless the factory

Re: PermGen space [ot]

2007-02-16 Thread Leon Rosenberg
On 2/16/07, Caldarale, Charles R <[EMAIL PROTECTED]> wrote: > From: Leon Rosenberg [mailto:[EMAIL PROTECTED] > As soon as the factory class is released nothing references > the singleton impl object and it can be released. Agreed - the trick is avoiding the direct reference to the factory class.

RE: PermGen space [ot]

2007-02-16 Thread Caldarale, Charles R
> From: Leon Rosenberg [mailto:[EMAIL PROTECTED] > Subject: Re: PermGen space [ot] > > But as long as the factory itself isn't linked by an attribute which > is inside the impl, the factory class can be released. Not if there's a direct reference to the factory class

Re: PermGen space [ot]

2007-02-16 Thread Leon Rosenberg
.5 i actually experienced oome on redeploy with code without any issues mentioned by your article. After we removed singleton dependency it went away. regards Leon On 2/16/07, Caldarale, Charles R <[EMAIL PROTECTED]> wrote: > From: Leon Rosenberg [mailto:[EMAIL PROTECTED] > Subjec

RE: PermGen space [ot]

2007-02-16 Thread Caldarale, Charles R
> From: Leon Rosenberg [mailto:[EMAIL PROTECTED] > Subject: Re: PermGen space [ot] > > public class ASingletonFactory{ > private static ASingletonImpl instance = new ASingletonImpl(); > public static AsingletonImpl getInstance(){ >return instance; >

RE: PermGen space [ot]

2007-02-16 Thread Mike Quilleash
uses and a better explanation of the problem. Cheers. Mike. -Original Message- From: Leon Rosenberg [mailto:[EMAIL PROTECTED] Sent: 16 February 2007 16:40 To: Tomcat Users List Subject: Re: PermGen space [ot] separate the singleton itself and the factory. in the previous example: pu

Re: PermGen space [ot]

2007-02-16 Thread Leon Rosenberg
separate the singleton itself and the factory. in the previous example: public class ASingletonFactory{ private static ASingletonImpl instance = new ASingletonImpl(); public static AsingletonImpl getInstance(){ return instance; } } public class ASingletonImpl{ ASingletonImpl()

RE: PermGen space [ot]

2007-02-16 Thread Jason Pyeron
So how should one write their singleton? -=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=- - - - Jason Pyeron PD Inc. http://www.pdinc.us - - Sr. Consultant10 West 24th Street #