Sunil Kuchipudi wrote:

> Rick,
> In the deployment descriptor (e.g WebLogic for instance)  can I specify
> something like below to limit the number of beans in the  pool to 1.  Will
> this not work ?. I am not sure if this part of the EJB 1.1 spec.

It's not part of the spec, since the spec doesn't force the container to use any
particular pooling or caching technique.
And, in the case of Weblogic, it won't work, because I've found that the minimum
numbers of beans in cache can't be set to anything less than 8 (if it's set to
one, it won't be respected: the number will grow to 8). Don't ask me why.

JB.

> Will have
> to verify this.
>
>     <MAX_BEANS_IN_FREE_POOL>1</MAX_BEANS_IN_FREE_POOL>
>     <MAX_BEANS_IN_CACHE>1</MAX_BEANS_IN_CACHE>
> Thanks.
> -Sunil .K
>
> ----- Original Message -----
> From: Rickard �berg <[EMAIL PROTECTED]>
> To: <[EMAIL PROTECTED]>
> Sent: Wednesday, May 31, 2000 8:33 AM
> Subject: Re: Singleton design/implementation techniques
>
> > > Sunil Kuchipudi wrote:
> > > >
> > > > Based on this premise, I do not understand why some ppl are looking to
> > > > implement the singleton pattern. Please enlighten me if I am missing
> > > > anything here.
> > >
> > > For caching read-only or read-mostly data in stateless session beans
> where you
> > > don't want multiple copies of your cached data.
> >
> > <vendor>
> > The jBoss EJB container allows one to use stateless session beans for
> > this. A special instance pool which guarantees that only one instance of
> > the bean is created can be used for exactly this purpose. This allows
> > one to do singletons as an EJB, which brings all the other benefits of
> > EJB, and also helps keep the application EJB only.
> > </vendor>
> >
> > /Rickard
> >
> > --
> > Rickard �berg
> >
> > @home: +46 13 177937
> > Email: [EMAIL PROTECTED]
> > http://www.telkel.com
> > http://www.jboss.org
> > http://www.dreambean.com
> >
> >
> ===========================================================================
> > To unsubscribe, send email to [EMAIL PROTECTED] and include in the
> body
> > of the message "signoff EJB-INTEREST".  For general help, send email to
> > [EMAIL PROTECTED] and include in the body of the message "help".
> >
>
> ===========================================================================
> To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
> of the message "signoff EJB-INTEREST".  For general help, send email to
> [EMAIL PROTECTED] and include in the body of the message "help".

--
Jean-Baptiste Nizet
[EMAIL PROTECTED]

R&D Engineer, S1 Belgium
Kleine Kloosterstraat, 23
B-1932 Sint-Stevens Woluwe
+32 2 200 45 42

===========================================================================
To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
of the message "signoff EJB-INTEREST".  For general help, send email to
[EMAIL PROTECTED] and include in the body of the message "help".

Reply via email to