Package org.apache.hedwig.exceptions.PubSubException

Examples of org.apache.hedwig.exceptions.PubSubException.UnexpectedConditionException


     * @throws UnexpectedConditionException
     *             If the lists are of unequal length
     */
    public static int compare(List<Long> l1, List<Long> l2) throws UnexpectedConditionException {
        if (l1.size() != l2.size()) {
            throw new UnexpectedConditionException("Seq-ids being compared have different sizes: " + l1.size()
                                                   + " and " + l2.size());
        }

        for (int i = 0; i < l1.size(); i++) {
            long v1 = l1.get(i);
View Full Code Here


            // The above are the only expected PubSubResponse messages received
            // from the server for the various client side requests made.
            logger.error("Response received from server is for an unhandled operation {}, txnId: {}.",
                         va(pubSubData.operationType, response.getTxnId()));
            pubSubData.getCallback().operationFailed(pubSubData.context,
                new UnexpectedConditionException("Can't find response handler for operation "
                                                 + pubSubData.operationType));
            return;
        }
        respHandler.handleResponse(response, pubSubData, ctx.getChannel());
    }
View Full Code Here

            InetSocketAddress host = NetUtils.getHostFromChannel(channel);
            hChannel = sChannelManager.getSubscriptionChannel(host);
            if (null == hChannel ||
                !channel.equals(hChannel.getChannel())) {
                PubSubException pse =
                    new UnexpectedConditionException("Failed to get subscription channel of " + host);
                pubSubData.getCallback().operationFailed(pubSubData.context, pse);
                return;
            }
        }
        super.handleResponse(response, pubSubData, channel);
View Full Code Here

TOP

Related Classes of org.apache.hedwig.exceptions.PubSubException.UnexpectedConditionException

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.