@Override
        public char[] read() throws GuacamoleException {

            // Read instructions from queue before finally delegating to
            // underlying reader (received when FailoverGuacamoleSocket was
            // being constructed)
            if (!instructionQueue.isEmpty()) {
                GuacamoleInstruction instruction = instructionQueue.remove();
                return instruction.toString().toCharArray();
            }

            return getDelegateSocket().getReader().read();

        }
GuacamoleReader which reads instructions from the queue populated when
the FailoverGuacamoleSocket was constructed. Once the queue has been
emptied, reads are delegated directly to the reader of the wrapped
socket.
guacamole-common/src/main/java/org/apache/guacamole/protocol/FailoverGuacamoleSocket.java