Source:
public final void onMessage(final SocketSession conn, final Request req) { if (req.getRequestType() == Request.MessageType.TIME) { final Request rsp = TimeManager.decodeRequest(req); if (rsp != null) { send(conn, rsp); } return; } if (req.getRequestType() == Request.MessageType.SUBMISSION) { if (req.getResponseText().equals("student")) { final MultiConnectionState state = getConnectionToId().get(conn); LOG.info("Parsing as an experiment"); SrlExperiment student = null; try { student = SrlExperiment.parseFrom(req.getOtherData()); } catch (InvalidProtocolBufferException e1) { conn.send(createExceptionRequest(e1, req)); LOG.info(LoggingConstants.EXCEPTION_MESSAGE, e1); return; } ((AnswerConnectionState) state).addPendingExperiment( req.getSessionInfo(), student); LOG.info("Student exp {}", student); try { getConnectionManager().send(req, req.getSessionInfo() + "+" + state.getKey(), SubmissionClientWebSocket.class); } catch (ConnectionException e1) { conn.send(createExceptionRequest(e1, req)); LOG.info(LoggingConstants.EXCEPTION_MESSAGE, e1); } final Request.Builder builder = Request.newBuilder(); builder.setRequestType(MessageType.DATA_REQUEST); builder.setSessionInfo(req.getSessionInfo() + "+" + state.getKey()); final ItemRequest.Builder itemRequest = ItemRequest.newBuilder(); itemRequest.setQuery(ItemQuery.SOLUTION); itemRequest.addItemId(student.getProblemId()); } else { try { getConnectionManager().send(req, req.getSessionInfo(), SubmissionClientWebSocket.class); } catch (ConnectionException e) { conn.send(createExceptionRequest(e, req)); LOG.info(LoggingConstants.EXCEPTION_MESSAGE, e); } } } }

Target:
public final void onMessage(final SocketSession conn, final Request req) { if (req.getRequestType() == Request.MessageType.TIME) { final Request rsp = TimeManager.decodeRequest(req); if (rsp != null) { send(conn, rsp); } return; } if (req.getRequestType() == Request.MessageType.SUBMISSION) { if (req.getResponseText().equals("student")) { final MultiConnectionState state = getConnectionToId().get(conn); LOG.info("Parsing as an experiment"); SrlExperiment student = null; try { student = SrlExperiment.parseFrom(req.getOtherData()); } catch (InvalidProtocolBufferException e1) { conn.send(createExceptionRequest(e1, req)); LOG.error(LoggingConstants.EXCEPTION_MESSAGE, e1); return; } ((AnswerConnectionState) state).addPendingExperiment( req.getSessionInfo(), student); LOG.info("Student experiment {}", student); try { getConnectionManager().send(req, req.getSessionInfo() + "+" + state.getKey(), SubmissionClientWebSocket.class); } catch (ConnectionException e1) { conn.send(createExceptionRequest(e1, req)); LOG.error(LoggingConstants.EXCEPTION_MESSAGE, e1); } final Request.Builder builder = Request.newBuilder(); builder.setRequestType(MessageType.DATA_REQUEST); builder.setSessionInfo(req.getSessionInfo() + "+" + state.getKey()); final ItemRequest.Builder itemRequest = ItemRequest.newBuilder(); itemRequest.setQuery(ItemQuery.SOLUTION); itemRequest.addItemId(student.getProblemId()); } else { try { getConnectionManager().send(req, req.getSessionInfo(), SubmissionClientWebSocket.class); } catch (ConnectionException e) { conn.send(createExceptionRequest(e, req)); LOG.error(LoggingConstants.EXCEPTION_MESSAGE, e); } } } }