@Override protected void finishedPayload(byte[] pl) throws IOException { if (responseOpaque == terminalOpaque) { for (OperationCallback cb : callbacks.values()) { cb.receivedStatus(STATUS_OK); cb.complete(); } transitionState(OperationState.COMPLETE); } else { OperationCallback cb = callbacks.remove(responseOpaque); assert cb != null : "No callback for " + responseOpaque; assert errorCode != 0 : "Got no error on a quiet mutation."; OperationStatus status = getStatusForErrorCode(errorCode, pl); assert status != null : "Got no status for a quiet mutation error"; cb.receivedStatus(status); cb.complete(); } resetInput(); }