menth0l has asked for the wisdom of the Perl Monks concerning the following question:
2) use non-shared singleton object per each thread and add custom signal handler that would reload configuration data. When main thread would found that config was chaged it would send this signal to all workers. But! for N workers this process would execute N times just to fetch the same content (then parse and validate it)...use MyConfig; # this instance is common for all threads MyConfig::instance()->getVal(...);
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Configuration in threaded app
by Corion (Patriarch) on Aug 23, 2011 at 12:57 UTC | |
by Anonymous Monk on Aug 23, 2011 at 13:11 UTC | |
by Corion (Patriarch) on Aug 23, 2011 at 13:17 UTC | |
|
Re: Configuration in threaded app
by BrowserUk (Patriarch) on Aug 23, 2011 at 13:32 UTC | |
|
Re: Configuration in threaded app
by zentara (Cardinal) on Aug 23, 2011 at 13:21 UTC | |
|
Re: Configuration in threaded app
by locked_user sundialsvc4 (Abbot) on Aug 23, 2011 at 14:41 UTC |