Package org.exist.storage

Examples of org.exist.storage.DBBroker.sync()


                return false;
            }
            broker.saveCollection(txn, coll);
            transact.commit(txn);
            broker.flush();
            broker.sync(Sync.MINOR_SYNC);
            return true;
        } catch (final Exception e) {
            transact.abort(txn);
            LOG.debug(e.getMessage(), e);
            throw new RemoteException(e.getMessage());
View Full Code Here


    @Override
    public boolean sync() {
        DBBroker broker = null;
        try {
            broker = factory.getBrokerPool().get(factory.getBrokerPool().getSecurityManager().getSystemSubject());
            broker.sync(Sync.MAJOR_SYNC);
        } catch (final EXistException e) {
          LOG.warn(e.getMessage(), e);
        } finally {
            factory.getBrokerPool().release(broker);
        }
View Full Code Here

      final Subject preserveSubject = pool.getSubject();
        DBBroker broker = null;
        try {
            broker = pool.get(user);
            broker.reindexCollection(parent.getCollection().getURI());
            broker.sync(Sync.MAJOR_SYNC);
        } catch (final PermissionDeniedException e) {
            throw new XMLDBException(ErrorCodes.PERMISSION_DENIED, e.getMessage(), e);
        } catch (final EXistException e) {
            throw new XMLDBException(ErrorCodes.VENDOR_ERROR, e.getMessage(), e);
        } finally {
View Full Code Here

       final Subject preserveSubject = pool.getSubject();
        DBBroker broker = null;
        try {
            broker = pool.get(user);
            broker.reindexCollection(collectionPath);
            broker.sync(Sync.MAJOR_SYNC);
        } catch (final PermissionDeniedException e) {
            throw new XMLDBException(ErrorCodes.PERMISSION_DENIED, e.getMessage(), e);
        } catch (final EXistException e) {
            throw new XMLDBException(ErrorCodes.VENDOR_ERROR, e.getMessage(), e);
        } finally {
View Full Code Here

        if (needsSync) {
            final Subject subject = brokerPool.getSubject();
            DBBroker broker = null;
            try {
                broker = brokerPool.get(user);
                broker.sync(Sync.MAJOR_SYNC);
            } catch(final EXistException e) {
                throw new XMLDBException(ErrorCodes.UNKNOWN_ERROR, e.getMessage(), e);
            } finally {
                brokerPool.release(broker);
                brokerPool.setSubject(subject);
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.