Package org.apache.jackrabbit.oak.jcr

Examples of org.apache.jackrabbit.oak.jcr.Jcr.createRepository()


        } else {
            securityProvider = new SecurityProviderImpl();
        }
        Jcr jcr = new Jcr();
        jcr.with(securityProvider);
        repo = jcr.createRepository();
        adminSession = repo.login(new SimpleCredentials(UserConstants.DEFAULT_ADMIN_ID, UserConstants.DEFAULT_ADMIN_ID.toCharArray()));

        target = adminSession.getRootNode().addNode("nodeName1");
        target.addMixin("rep:AccessControllable");
        adminSession.save();
View Full Code Here


        // lucene specific
        jcr.with(new LuceneInitializerHelper("lucene").async());
        jcr.with(new LuceneIndexProvider());
        jcr.with(new LuceneIndexEditorProvider());

        repository = jcr.createRepository();
    }

    protected Session createAdminSession() throws RepositoryException {
        return repository.login(new SimpleCredentials("admin", "admin"
                .toCharArray()));
View Full Code Here

        } else {
            securityProvider = new SecurityProviderImpl();
        }
        Jcr jcr = new Jcr();
        jcr.with(securityProvider);
        repo = jcr.createRepository();
        adminSession = repo.login(new SimpleCredentials(UserConstants.DEFAULT_ADMIN_ID, UserConstants.DEFAULT_ADMIN_ID.toCharArray()));

        if (!(adminSession instanceof JackrabbitSession)) {
            throw new NotExecutableException();
        }
View Full Code Here

        }

        NodeStore target = new KernelNodeStore(new MicroKernelImpl());
        RepositoryUpgrade.copy(source, target);
        Jcr jcr = new Jcr(new Oak(target));
        verifyTargetContent(jcr.createRepository());
    }

    private void createSourceContent(Repository repository) throws Exception {
        Session session = repository.login(CREDENTIALS);
        try {
View Full Code Here

            ServletHolder holder =
                    new ServletHolder(new OakServlet(repository));
            context.addServlet(holder, path + "/*");

            final Repository jcrRepository = jcr.createRepository();

            ServletHolder webdav =
                    new ServletHolder(new SimpleWebdavServlet() {
                        @Override
                        public Repository getRepository() {
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. 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.