Package gridool.directory.helpers

Examples of gridool.directory.helpers.GridNodeValueCollector


            if(rlock.tryLock()) {
                localExecResources.add(new Pair<String, Lock>(path, rlock));
            } else {
                totalLocked++;
                final byte[] k = StringUtils.getBytes(path);
                final GridNodeValueCollector collector = new GridNodeValueCollector(_excludeNodeList);
                try {
                    directory.exactSearch(k, collector);
                } catch (DbException e) {
                    String errmsg = "Exception caused while lookup: " + path;
                    LOG.error(errmsg, e);
                    throw new GridException(errmsg, e);
                }
                final List<GridNode> replicatedNodes = collector.getMatched();
                if(replicatedNodes == null || replicatedNodes.isEmpty()) {
                    throw new GridException("No replicated document found for path: " + path);
                }
                // TODO Select a node that least recently used for write requests.
                GridNode node = nodeSelector.selectNode(replicatedNodes, config);
View Full Code Here

TOP

Related Classes of gridool.directory.helpers.GridNodeValueCollector

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.