RepositoryConfig instance can not be reused once it has been passed to 
RepositoryImpl constructor
-------------------------------------------------------------------------------------------------

         Key: JCR-331
         URL: http://issues.apache.org/jira/browse/JCR-331
     Project: Jackrabbit
        Type: Improvement
  Components: config  
    Versions: 0.9    
 Environment: svn r382351
    Reporter: Stefan Guggisberg
    Priority: Minor
     Fix For: 1.0
 Attachments: reusable_config.patch

RepositoryConfig and other *Config classes maintain state apart from parsed 
configuration information;
specifically they instantiate FileSystem implementations based on their 
configurations. this makes it
for the config consumers very hard to control the lifecycle of such FileSystem 
instances as they need
to close the file systems on repository shutdown.

the following code illustrates the issue:

RepositoryConfig repConf = RepositoryConfig.create(configFile, repHomeDir);
RepositoryImpl rep = RepositoryImpl.create(repConf);
// ...
rep.shutdown();

rep = RepositoryImpl.create(repConf);   
// ==> repConfig (et al) contains references to FileSystem objects 
// that have been closed by previous rep.shutdown() call



-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira

Reply via email to