I have a question along these lines.  If I have an EJB helper class for static
final member properties which are initialized at system startup, these
properties seldom change, but they do change.  Is there a way to update those
properties (ie destroy the class) without restarting the system?  Or do I have
to declare them not final?

Gene Chuang wrote:

> Hm, I was under the impression java:com/env values better served as static
> "constants", good mostly for deployment-time initializations.  If you want
> to communicate values amongst beans during runtime, perhaps JMS, MessageBean
> or a db table for your GlobalProperties will suit you better?
>
> Gene
>
> -----Original Message-----
> From: A mailing list for Enterprise JavaBeans development
> [mailto:[EMAIL PROTECTED]]On Behalf Of Jean-Baptiste Nizet
> Sent: Wednesday, July 26, 2000 3:32 AM
> To: [EMAIL PROTECTED]
> Subject: java:comp/env context
>
> I'd like to make a GlobalProperties stateless session bean. This session
> bean
> would make some global settings available for all the other components, and
> these settings could be modified at runtime. The kind of properties I'd like
> to
> put there is, for example, a logging level.
>
> The simplest thing to do is to use the java:comp/env naming context of this
> bean
> to store the properties. This will obviously work for read-only properties.
> But
> can I be sure that the bean will be able to bind or rebind some values in
> this
> context? And if it is able to do it, can I be sure that all the other
> instances
> of the bean will automatically see these new values, or is the container
> allowed
> to give each instance its own copy of the settings?
>
> I tried it with IAS, and it seems to work well, but I wonder about other
> servers.
>
> Thanks.
> JB.
>
> --
> 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".
>
> ===========================================================================
> 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".

--
--------------------------------------
Leonard Thomas
Software Engineer
RHINO Systems Inc.
RDBMS and Internet development
www.rhinosystemsinc.com
--------------------------------------
******Free reminder service at *******
******  www.thoughtshot.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".

Reply via email to