Package org.apache.jackrabbit.core

Examples of org.apache.jackrabbit.core.TransientRepository


        {
            this.homeDirectory = getFileURI(homeDirectory);
            java.io.File homeDir = new java.io.File(this.homeDirectory);
            this.configFile = getFileURI(configFile);
            java.io.File configXml = new java.io.File(this.configFile);
            this.repository = new TransientRepository( configXml.toString(), homeDir.toString() );
           
        }
        catch ( IOException e )
        {
            throw new MBeanException( e, "JackRabbit Repository creation failed. Home directory " + this.homeDirectory
View Full Code Here


            File configFile = new File(configFilePath);
            if (!configFile.exists()) {
                if (!configFilePath.startsWith("/")) configFilePath = "/" + configFilePath;
                configFile = new File("src/test/resources" + configFilePath);
            }
            repository = new TransientRepository(configFile, target);
        } else {
            repository = new TransientRepository(target);
        }
        setCredentials(defaultCredentials());
    }
View Full Code Here

                    if (repository instanceof JackrabbitRepository) {
                        JackrabbitRepository jr = (JackrabbitRepository)repository;
                        jr.shutdown();
                    }
                    if (repository instanceof TransientRepository) {
                        TransientRepository trans = (TransientRepository)repository;
                        deleteDirectory(trans.getHomeDir());
                    }
                } finally {
                    repository = null;
                }
            }
View Full Code Here

   */
  @BeforeClass
  public static void beforeAll() throws Exception, Throwable {
    System.out.println("JcrDigitalObjectManagerTests.beforeAll()");
    try {
      repository = new TransientRepository(JCR_CONFIG_PATH, JCR_DATA_PATH);
    } catch (RuntimeException e) {
      System.out.println("Caught RuntimeException in set up");
      System.out.println(e.getMessage());
      e.printStackTrace();
      throw e;
View Full Code Here

        // Set up the logger ...
        logger = Logger.getLogger(JackrabbitInMemoryTest.class);

        // Set up the transient repository ...
        logger.info(MockI18n.passthrough, "Creating test repository for stress test and logging in with user " + USERNAME);
        this.repository = new TransientRepository(REPOSITORY_CONFIG_PATH, REPOSITORY_DIRECTORY_PATH);

        SimpleCredentials creds = new SimpleCredentials(USERNAME, PASSWORD);
        session = this.repository.login(creds);
        assertNotNull(session);
    }
View Full Code Here

        // Set up Derby and the logger ...
        System.setProperty("derby.system.home", DERBY_SYSTEM_HOME);
        logger = Logger.getLogger(JackrabbitBasicFunctionTest.class);

        // Set up the transient repository ...
        this.repository = new TransientRepository(REPOSITORY_CONFIG_PATH, REPOSITORY_DIRECTORY_PATH);
    }
View Full Code Here

        System.setProperty("derby.system.home", DERBY_SYSTEM_HOME);
        logger = Logger.getLogger(JackrabbitDerbyStressTest.class);

        // Set up the transient repository ...
        logger.info(MockI18n.passthrough, "Creating test repository for stress test and logging in with user " + USERNAME);
        this.repository = new TransientRepository(REPOSITORY_CONFIG_PATH, REPOSITORY_DIRECTORY_PATH);

        SimpleCredentials creds = new SimpleCredentials(USERNAME, PASSWORD);
        session = this.repository.login(creds);
        assertNotNull(session);
    }
View Full Code Here

        // Set up the logger ...
        logger = Logger.getLogger(JackrabbitInMemoryTest.class);

        // Set up the transient repository ...
        logger.info(MockI18n.passthrough, "Creating test repository for stress test and logging in with user " + USERNAME);
        this.repository = new TransientRepository(REPOSITORY_CONFIG_PATH, REPOSITORY_DIRECTORY_PATH);

        SimpleCredentials creds = new SimpleCredentials(USERNAME, PASSWORD);
        session = this.repository.login(creds);
        assertNotNull(session);
    }
View Full Code Here

        // Set up Derby and the logger ...
        System.setProperty("derby.system.home", DERBY_SYSTEM_HOME);
        logger = Logger.getLogger(JackrabbitBasicFunctionTest.class);

        // Set up the transient repository ...
        this.repository = new TransientRepository(REPOSITORY_CONFIG_PATH, REPOSITORY_DIRECTORY_PATH);
    }
View Full Code Here

        System.setProperty("derby.system.home", DERBY_SYSTEM_HOME);
        logger = Logger.getLogger(JackrabbitDerbyStressTest.class);

        // Set up the transient repository ...
        logger.info(MockI18n.passthrough, "Creating test repository for stress test and logging in with user " + USERNAME);
        this.repository = new TransientRepository(REPOSITORY_CONFIG_PATH, REPOSITORY_DIRECTORY_PATH);

        SimpleCredentials creds = new SimpleCredentials(USERNAME, PASSWORD);
        session = this.repository.login(creds);
        assertNotNull(session);
    }
View Full Code Here

TOP

Related Classes of org.apache.jackrabbit.core.TransientRepository

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.