public void execute(Runnable command) { wrapped.execute(command); } }
public void execute(Runnable command) { wrapped.execute(command); } }
public void execute(Runnable command) { wrapped.execute(command); } }
public void apply(IMutation mutation, Iterable<InetAddress> targets, AbstractWriteResponseHandler<IMutation> responseHandler, String localDataCenter, ConsistencyLevel consistencyLevel) { StageManager.getStage(Stage.COUNTER_MUTATION) .execute(counterWriteTask(mutation, targets, responseHandler, localDataCenter)); } };
public void apply(IMutation mutation, Iterable<InetAddress> targets, AbstractWriteResponseHandler<IMutation> responseHandler, String localDataCenter, ConsistencyLevel consistencyLevel) { StageManager.getStage(Stage.COUNTER_MUTATION) .execute(counterWriteTask(mutation, targets, responseHandler, localDataCenter)); } };
public void apply(IMutation mutation, Iterable<InetAddress> targets, AbstractWriteResponseHandler<IMutation> responseHandler, String localDataCenter, ConsistencyLevel consistencyLevel) { StageManager.getStage(Stage.COUNTER_MUTATION) .execute(counterWriteTask(mutation, targets, responseHandler, localDataCenter)); } };
/** * Called from {@link org.apache.cassandra.net.OutboundTcpConnection} for non-local traces (traces * that are not initiated by local node == coordinator). */ public void trace(final ByteBuffer sessionId, final String message, final int ttl) { final String threadName = Thread.currentThread().getName(); StageManager.getStage(Stage.TRACING).execute(new WrappedRunnable() { public void runMayThrow() { TraceStateImpl.mutateWithCatch(TraceKeyspace.makeEventMutation(sessionId, message, -1, threadName, ttl)); } }); } }
/** * Called from {@link org.apache.cassandra.net.OutboundTcpConnection} for non-local traces (traces * that are not initiated by local node == coordinator). */ public void trace(final ByteBuffer sessionId, final String message, final int ttl) { final String threadName = Thread.currentThread().getName(); StageManager.getStage(Stage.TRACING).execute(new WrappedRunnable() { public void runMayThrow() { TraceStateImpl.mutateWithCatch(TraceKeyspace.makeEventMutation(sessionId, message, -1, threadName, ttl)); } }); } }
/** * Called from {@link org.apache.cassandra.net.OutboundTcpConnection} for non-local traces (traces * that are not initiated by local node == coordinator). */ public void trace(final ByteBuffer sessionId, final String message, final int ttl) { final String threadName = Thread.currentThread().getName(); StageManager.getStage(Stage.TRACING).execute(new WrappedRunnable() { public void runMayThrow() { TraceStateImpl.mutateWithCatch(TraceKeyspace.makeEventMutation(sessionId, message, -1, threadName, ttl)); } }); } }
public void response(MessageIn<ReadResponse> message) { repairResolver.preprocess(message); if (received.incrementAndGet() == blockfor) { StageManager.getStage(Stage.READ_REPAIR).execute(new WrappedRunnable() { protected void runMayThrow() { repairResolver.compareResponses(); } }); } }
public void response(MessageIn<ReadResponse> message) { repairResolver.preprocess(message); if (received.incrementAndGet() == blockfor) { StageManager.getStage(Stage.READ_REPAIR).execute(new WrappedRunnable() { protected void runMayThrow() { repairResolver.compareResponses(); } }); } }
public void response(MessageIn<ReadResponse> message) { repairResolver.preprocess(message); if (received.incrementAndGet() == blockfor) { StageManager.getStage(Stage.READ_REPAIR).execute(new WrappedRunnable() { protected void runMayThrow() { repairResolver.compareResponses(); } }); } }
/** * Registers the newly created tree for rendezvous in Stage.ANTIENTROPY. */ public void complete() { completeTree(); StageManager.getStage(Stage.ANTI_ENTROPY).execute(this); if (logger.isDebugEnabled()) { // log distribution of rows in tree logger.debug("Validated {} partitions for {}. Partitions per leaf are:", validated, desc.sessionId); trees.logRowCountPerLeaf(logger); logger.debug("Validated {} partitions for {}. Partition sizes are:", validated, desc.sessionId); trees.logRowSizePerLeaf(logger); } }
/** * Registers the newly created tree for rendezvous in Stage.ANTIENTROPY. */ public void complete() { completeTree(); StageManager.getStage(Stage.ANTI_ENTROPY).execute(this); if (logger.isDebugEnabled()) { // log distribution of rows in tree logger.debug("Validated {} partitions for {}. Partitions per leaf are:", validated, desc.sessionId); trees.logRowCountPerLeaf(logger); logger.debug("Validated {} partitions for {}. Partition sizes are:", validated, desc.sessionId); trees.logRowSizePerLeaf(logger); } }
/** * Registers the newly created tree for rendezvous in Stage.ANTIENTROPY. */ public void complete() { completeTree(); StageManager.getStage(Stage.ANTI_ENTROPY).execute(this); if (logger.isDebugEnabled()) { // log distribution of rows in tree logger.debug("Validated {} partitions for {}. Partitions per leaf are:", validated, desc.sessionId); trees.logRowCountPerLeaf(logger); logger.debug("Validated {} partitions for {}. Partition sizes are:", validated, desc.sessionId); trees.logRowSizePerLeaf(logger); } }
public void response(MessageIn<ReadResponse> message) { resolver.preprocess(message); int n = waitingFor(message.from) ? recievedUpdater.incrementAndGet(this) : received; if (n >= blockfor && resolver.isDataPresent()) { condition.signalAll(); // kick off a background digest comparison if this is a result that (may have) arrived after // the original resolve that get() kicks off as soon as the condition is signaled if (blockfor < endpoints.size() && n == endpoints.size()) { TraceState traceState = Tracing.instance.get(); if (traceState != null) traceState.trace("Initiating read-repair"); StageManager.getStage(Stage.READ_REPAIR).execute(new AsyncRepairRunner(traceState, queryStartNanoTime)); } } }
public void response(MessageIn<ReadResponse> message) { resolver.preprocess(message); int n = waitingFor(message.from) ? recievedUpdater.incrementAndGet(this) : received; if (n >= blockfor && resolver.isDataPresent()) { condition.signalAll(); // kick off a background digest comparison if this is a result that (may have) arrived after // the original resolve that get() kicks off as soon as the condition is signaled if (blockfor < endpoints.size() && n == endpoints.size()) { TraceState traceState = Tracing.instance.get(); if (traceState != null) traceState.trace("Initiating read-repair"); StageManager.getStage(Stage.READ_REPAIR).execute(new AsyncRepairRunner(traceState, queryStartNanoTime)); } } }
public void receive(MessageIn message, int id) { TraceState state = Tracing.instance.initializeFromMessage(message); if (state != null) state.trace("{} message received from {}", message.verb, message.from); // message sinks are a testing hook for (IMessageSink ms : messageSinks) if (!ms.allowIncomingMessage(message, id)) return; Runnable runnable = new MessageDeliveryTask(message, id); LocalAwareExecutorService stage = StageManager.getStage(message.getMessageType()); assert stage != null : "No stage for message type " + message.verb; stage.execute(runnable, ExecutorLocals.create(state)); }
public void receive(MessageIn message, int id) { TraceState state = Tracing.instance.initializeFromMessage(message); if (state != null) state.trace("{} message received from {}", message.verb, message.from); // message sinks are a testing hook for (IMessageSink ms : messageSinks) if (!ms.allowIncomingMessage(message, id)) return; Runnable runnable = new MessageDeliveryTask(message, id); LocalAwareExecutorService stage = StageManager.getStage(message.getMessageType()); assert stage != null : "No stage for message type " + message.verb; stage.execute(runnable, ExecutorLocals.create(state)); }
public void receive(MessageIn message, int id) { TraceState state = Tracing.instance.initializeFromMessage(message); if (state != null) state.trace("{} message received from {}", message.verb, message.from); // message sinks are a testing hook for (IMessageSink ms : messageSinks) if (!ms.allowIncomingMessage(message, id)) return; Runnable runnable = new MessageDeliveryTask(message, id); LocalAwareExecutorService stage = StageManager.getStage(message.getMessageType()); assert stage != null : "No stage for message type " + message.verb; stage.execute(runnable, ExecutorLocals.create(state)); }