Examples of BTreePathStorage


Examples of org.chaidb.db.helper.cache.storage.BTreePathStorage

    public String getBTreeMapFileName() {
        return DefaultLogFile.getInstance().getLogFilePath() + IDBIndex.BTREE_NAME_INDEX;
    }

    private BTreePathStorage initIdStorage(String path) throws ChaiDBException {
        BTreePathStorage ids = new BTreePathStorage(path + File.separator + IDBIndex.BTREE_NAME_INDEX);

        try {
            ids.init();
        } catch (SecondaryStorageException e) {
            logger.fatal(new Throwable("Init id Storage failed on path " + path));
            throw new ChaiDBException(ErrorCode.RUNTIME_IO_ERROR, e);
        }
View Full Code Here

Examples of org.chaidb.db.helper.cache.storage.BTreePathStorage

                //in reporting server mode, treeId > BTREEID_BASE
                int server = (treeId / BTREEID_BASE);
                int trueId = treeId % BTREEID_BASE;

                String name = org.chaidb.db.helper.DbConstants.REPORTING_SERVER_PREFIX + server;
                BTreePathStorage ids;

                if ((ids = (BTreePathStorage) idStorageList.get(name)) == null) {
                    ids = initIdStorage(DbEnvironment.getDataHome() + name + File.separator + "datalog");
                    idStorageList.put(name, ids);
                }

                rName = ids.retrieve(trueId);
                logger.debug("treeId:" + treeId + " name:" + rName);

                return DbEnvironment.getDataHome() + name + File.separator + rName;
            } else {
                if (idStorage == null) {
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.