Package org.apache.cassandra.db

Examples of org.apache.cassandra.db.ReadCommand.createMessage()


    protected void makeDigestRequests(Iterable<InetAddress> endpoints)
    {
        ReadCommand digestCommand = command.copy();
        digestCommand.setDigestQuery(true);
        MessageOut<?> message = digestCommand.createMessage();
        for (InetAddress endpoint : endpoints)
        {
            if (isLocalRequest(endpoint))
            {
                logger.trace("reading digest locally");
View Full Code Here


                    retryCommand.setDigestQuery(true);
                }

                InetAddress extraReplica = Iterables.getLast(targetReplicas);
                logger.trace("speculating read retry on {}", extraReplica);
                MessagingService.instance().sendRR(retryCommand.createMessage(), extraReplica, handler);
                speculated = true;

                cfs.metric.speculativeRetries.inc();
            }
        }
View Full Code Here

            {
                logger.trace("reading digest from {}", digestPoint);
                // (We lazy-construct the digest Message object since it may not be necessary if we
                // are doing a local digest read, or no digest reads at all.)
                if (message == null)
                    message = digestCommand.createMessage();
                MessagingService.instance().sendRR(message, digestPoint, handler);
            }
        }
    }
View Full Code Here

                    scommand = command.copy();
                    scommand.setDigestQuery(true);
                }

                logger.trace("Speculating read retry on {}", endpoint);
                MessagingService.instance().sendRR(scommand.createMessage(), endpoint, handler);
                cfs.metric.speculativeRetry.inc();
            }
        }
    }
View Full Code Here

            if (handler.endpoints.size() <= limit)
                return;

            ReadCommand digestCommand = command.copy();
            digestCommand.setDigestQuery(true);
            MessageOut<?> message = digestCommand.createMessage();
            for (int i = limit; i < handler.endpoints.size(); i++)
            {
                // Send the message
                InetAddress endpoint = handler.endpoints.get(i);
                if (endpoint.equals(FBUtilities.getBroadcastAddress()))
View Full Code Here

    protected void makeDigestRequests(Iterable<InetAddress> endpoints)
    {
        ReadCommand digestCommand = command.copy();
        digestCommand.setDigestQuery(true);
        MessageOut<?> message = digestCommand.createMessage();
        for (InetAddress endpoint : endpoints)
        {
            if (isLocalRequest(endpoint))
            {
                logger.trace("reading digest locally");
View Full Code Here

                    retryCommand.setDigestQuery(true);
                }

                InetAddress extraReplica = Iterables.getLast(targetReplicas);
                logger.trace("speculating read retry on {}", extraReplica);
                MessagingService.instance().sendRR(retryCommand.createMessage(), extraReplica, handler);
                speculated = true;

                cfs.metric.speculativeRetries.inc();
            }
        }
View Full Code Here

    protected void makeDigestRequests(Iterable<InetAddress> endpoints)
    {
        ReadCommand digestCommand = command.copy();
        digestCommand.setDigestQuery(true);
        MessageOut<?> message = digestCommand.createMessage();
        for (InetAddress endpoint : endpoints)
        {
            if (isLocalRequest(endpoint))
            {
                logger.trace("reading digest locally");
View Full Code Here

                    retryCommand.setDigestQuery(true);
                }

                InetAddress extraReplica = Iterables.getLast(targetReplicas);
                logger.trace("speculating read retry on {}", extraReplica);
                MessagingService.instance().sendRR(retryCommand.createMessage(), extraReplica, handler);
                speculated = true;

                cfs.metric.speculativeRetries.inc();
            }
        }
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.