class RepositoryFactoryBean extends org.springframework.extensions.jcr.RepositoryFactoryBean {

    protected void resolveConfigurationResource() throws Exception {
        // read the configuration object
        if (repositoryConfig != null)
            return;

        if (this.configuration == null) {
            if (LOG.isDebugEnabled())
                LOG.debug("no configuration resource specified, using the default one:" + DEFAULT_CONF_FILE);
            configuration = new ClassPathResource(DEFAULT_CONF_FILE);
        }

        if (homeDir == null) {
            if (LOG.isDebugEnabled())
                LOG.debug("no repository home dir specified, using the default one:" + DEFAULT_REP_DIR);
            homeDir = new FileSystemResource(DEFAULT_REP_DIR);
        }

        repositoryConfig = RepositoryConfig.create(new InputSource(configuration.getInputStream()), homeDir.getFile().getAbsolutePath());
    }

}