You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@commons.apache.org by "Sosnowski, Konrad" <ks...@chellomedia.com> on 2005/08/30 13:09:28 UTC
[commos chain] is commons chain config loading threadsafe?
Hello,
I'm under the impression that the way to load up the chain is:
ConfigParser parser = new ConfigParser();
parser.parse(configUrl);
Catalog catalog =
CatalogFactoryBase.getInstance().getCatalog();;
Context context = new ContextBase();
context.putAll(props);
Command command = catalog.getCommand(commandName);
I aim to construct chains within multiple threads, each using a separate XML
loaded via a separate ClassLoader. From what I've seen, the code above is
riddled with static factories and what goes with them - static maps. Am I
correct to assume the above code is NOT threadsafe? Is there a threadsafe
way of achieving my aim?
Regards,
Konrad