Hello all,

In an app we are doing, we use commons config to load properties and
use a threaded class to do the reload every few seconds. this is then
packaged as a part of a j2ee application. When application code is
referenced for the first time, a thread is started and this thread
checks for modifications at intervals. Though the J2EE spec does not
allow a developer to start threads, this seems to work well for me.

The other option would be create a java application class as the
configuration wrapper (containing a main method) and to start that
class as a "startup" class in the J2EE container.

Please share your views on this type of design.

Thanks
Eagle. 

On Apr 4, 2005 5:47 PM, WANG Qingtian <[EMAIL PROTECTED]> wrote:
> Hi,
> 
> Is the reload strategy implemented by creating a thread that
> periodically checks the time stamp of the configuration file? If so, how
> do I make sure that thread is started/stopped properly when I use it in
> a j2ee container? Like, will the thread be killed when I shut down the
> web/ejb container? What is the "best practice" of using "configuration"
> in a j2ee container?
> 
> Thanks a lot for your help!!!
> Qingtian
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> 
>

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to