Package com.sun.sgs.impl.service.nodemap.affinity

Examples of com.sun.sgs.impl.service.nodemap.affinity.AffinityGroupFinderFailedException


        synchronized (runningLock) {
            while (running) {
                try {
                    runningLock.wait();
                } catch (InterruptedException e) {
                    throw new AffinityGroupFinderFailedException(
                               "Interrupted while waiting for current run", e);
                }
            }
            running = true;
        }
View Full Code Here


            runningLock.notifyAll();
        }
        stats.failedCountInc();
        stats.setNumGroups(0);
        if (runException == null) {
            runException = new AffinityGroupFinderFailedException(msg);
        }
    }
View Full Code Here

    /** {@inheritDoc} */
    public void readyToBegin(long nodeId, boolean failed) throws IOException {
        if (failed) {
            String msg = "node " + nodeId + " reports failure preparing";
            if (runException == null) {
                runException = new AffinityGroupFinderFailedException(msg);
            }
            logger.log(Level.INFO, "node {0} reports failure", nodeId);
            runFailed = true;
        }
        maybeCountDown(nodeId);
View Full Code Here

    {
        if (failed) {
            String msg = "node " + nodeId +
                         " reports failure in iteration " + iteration;
            if (runException == null) {
                runException = new AffinityGroupFinderFailedException(msg);
            }
            logger.log(Level.INFO, "node {0} reports failure", nodeId);
            runFailed = true;
        }
        if (iteration != currentIteration) {
            String msg = "node " + nodeId +
                         " reports unexpected iteration " + iteration;
            if (runException == null) {
                runException = new AffinityGroupFinderFailedException(msg);
            }
            logger.log(Level.INFO, "unexpected iteration: {0} on node {1}, " +
                    "expected {2}, marking run failed",
                    iteration, nodeId, currentIteration);
            runFailed = true;
View Full Code Here

                if (!ok) {
                    String msg = "node " + nodeId +
                                 " could not be contacted to prepare " + runNum;
                    if (runException == null) {
                        runException =
                                new AffinityGroupFinderFailedException(msg);
                    }
                    runFailed = true;
                    maybeCountDown(nodeId);
                    // If we cannot reach the proxy after retries, we need
                    // to remove it from the
                    // clientProxyMap.
                    removeNode(nodeId);
                }
            } catch (Exception e) {
                String msg = "node " + nodeId +
                             " exception while preparing " + runNum;
                if (runException == null) {
                    runException =
                            new AffinityGroupFinderFailedException(msg, e);
                }
                logger.logThrow(Level.INFO, e,
                    "exception from node {0} while preparing",
                    nodeId);
                runFailed = true;
View Full Code Here

                        String msg = "node " + nodeId +
                                     " could not be contacted for iteration " +
                                     currentIteration;
                        if (runException == null) {
                            runException =
                                    new AffinityGroupFinderFailedException(msg);
                        }
                        runFailed = true;
                        maybeCountDown(nodeId);
                        // If we cannot reach the proxy after retries, we need
                        // to remove it from the
                        // clientProxyMap.
                        removeNode(nodeId);
                    }
                } catch (Exception e) {
                    String msg = "node " + nodeId +
                                 " exception for iteration " +
                                 currentIteration;
                    if (runException == null) {
                        runException =
                                new AffinityGroupFinderFailedException(msg, e);
                    }
                    logger.logThrow(Level.INFO, e,
                        "exception from node {0} while running " +
                        "iteration {1}",
                        nodeId, currentIteration);
View Full Code Here

            boolean ok = latch.await(TIMEOUT, TimeUnit.MINUTES);
            if (!ok) {
                // We timed out on the latch, invalidating this run.
                String msg = "Latch timed out";
                if (runException == null) {
                    runException = new AffinityGroupFinderFailedException(msg);
                }
                runFailed = true;
            }
        } catch (InterruptedException ex) {
            String msg = "Latch timed interrupted";
            if (runException == null) {
                runException = new AffinityGroupFinderFailedException(msg, ex);
            }
            runFailed = true;
        }
    }
View Full Code Here

TOP

Related Classes of com.sun.sgs.impl.service.nodemap.affinity.AffinityGroupFinderFailedException

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.