This code looks suspect. I am not sure that after it is run, dc ==
Configuration.getSharedConfiguration(). Can you do something like this
instead:
DefaultConfiguration dc = new DefaultConfiguration(configuration);
dc.addClassPath(classPath);
Configuration.initializeSharedConfiguration(dc);
Andrus
On Jul 31, 2008, at 1:13 PM, Chris Gamache wrote:
> if (!initialized) {
> DefaultConfiguration dc = new DefaultConfiguration(configuration);
> dc.addClassPath(classPath);
> boolean cayenneNotInitialized = false;
> try {
> Configuration conf = Configuration.getSharedConfiguration();
> } catch (Exception e) {
> cayenneNotInitialized = true;
> }
>
> if (cayenneNotInitialized) {
> dc.initializeSharedConfiguration(dc);
> } else {
> try{
> dc.initialize();
> }catch(Exception e){
> throw new ConfigurationException();
> }
> }
This archive was generated by hypermail 2.0.0 : Fri Aug 01 2008 - 17:23:40 EDT