Program: 37772
Project: 37772
Buggy source:
private void handleRerouteRequest(CommandMessage message,Tuple tuple) throws IOException {
  FlowRerouteRequest request=(FlowRerouteRequest)message.getData();
  Flow requestedFlow=request.getPayload();
  final String flowId=requestedFlow.getFlowId();
  ImmutablePair<Flow,Flow> flow;
  logger.warn("String_Node_Str",message.getCorrelationId());
switch (request.getOperation()) {
case UPDATE:
    flow=flowCache.getFlow(flowId);
  try {
    logger.warn("String_Node_Str",flowId,flow.getLeft().getFlowPath());
    ImmutablePair<PathInfoData,PathInfoData> path=pathComputer.getPath(flow.getLeft(),Strategy.COST);
    logger.warn("String_Node_Str",flowId,path.getLeft());
    boolean isFoundNewPath=false;
    if (!path.getLeft().equals(flow.getLeft().getFlowPath()) || !isFlowActive(flow)) {
      isFoundNewPath=true;
      flow.getLeft().setState(FlowState.DOWN);
      flow.getRight().setState(FlowState.DOWN);
      flow=flowCache.updateFlow(flow.getLeft(),path);
      logger.warn("String_Node_Str",flow);
      FlowInfoData data=new FlowInfoData(flowId,flow,UPDATE,message.getCorrelationId());
      InfoMessage infoMessage=new InfoMessage(data,System.currentTimeMillis(),message.getCorrelationId());
      Values topology=new Values(MAPPER.writeValueAsString(infoMessage));
      outputCollector.emit(StreamType.UPDATE.toString(),tuple,topology);
    }
 else {
      logger.warn("String_Node_Str");
    }
    logger.debug("String_Node_Str",message.getCorrelationId());
    FlowRerouteResponse response=new FlowRerouteResponse(flow.left.getFlowPath(),isFoundNewPath);
    Values values=new Values(new InfoMessage(response,message.getTimestamp(),message.getCorrelationId(),Destination.NORTHBOUND));
    outputCollector.emit(StreamType.RESPONSE.toString(),tuple,values);
  }
 catch (  UnroutablePathException e) {
    logger.warn("String_Node_Str",flowId);
    flow.getLeft().setState(FlowState.DOWN);
    flow.getRight().setState(FlowState.DOWN);
    throw new MessageException(message.getCorrelationId(),System.currentTimeMillis(),ErrorType.UPDATE_FAILURE,"String_Node_Str","String_Node_Str");
  }
break;
case CREATE:
flow=flowCache.getFlow(flowId);
logger.warn("String_Node_Str",flow.getLeft().getFlowId(),FlowState.UP);
flow.getLeft().setState(FlowState.UP);
flow.getRight().setState(FlowState.UP);
break;
case DELETE:
flow=flowCache.getFlow(flowId);
logger.warn("String_Node_Str",flow.getLeft().getFlowId(),FlowState.DOWN);
flow.getLeft().setState(FlowState.DOWN);
flow.getRight().setState(FlowState.DOWN);
break;
default :
logger.warn("String_Node_Str",request.getOperation());
break;
}
}

Fixed version (ground truth):
private void handleRerouteRequest(CommandMessage message,Tuple tuple) throws IOException, RecoverableException {
  FlowRerouteRequest request=(FlowRerouteRequest)message.getData();
  Flow requestedFlow=request.getPayload();
  final String flowId=requestedFlow.getFlowId();
  ImmutablePair<Flow,Flow> flow;
  logger.warn("String_Node_Str",message.getCorrelationId());
switch (request.getOperation()) {
case UPDATE:
    flow=flowCache.getFlow(flowId);
  try {
    logger.warn("String_Node_Str",flowId,flow.getLeft().getFlowPath());
    ImmutablePair<PathInfoData,PathInfoData> path=pathComputer.getPath(flow.getLeft(),Strategy.COST);
    logger.warn("String_Node_Str",flowId,path.getLeft());
    boolean isFoundNewPath=false;
    if (!path.getLeft().equals(flow.getLeft().getFlowPath()) || !isFlowActive(flow)) {
      isFoundNewPath=true;
      flow.getLeft().setState(FlowState.DOWN);
      flow.getRight().setState(FlowState.DOWN);
      flow=flowCache.updateFlow(flow.getLeft(),path);
      logger.warn("String_Node_Str",flow);
      FlowInfoData data=new FlowInfoData(flowId,flow,UPDATE,message.getCorrelationId());
      InfoMessage infoMessage=new InfoMessage(data,System.currentTimeMillis(),message.getCorrelationId());
      Values topology=new Values(MAPPER.writeValueAsString(infoMessage));
      outputCollector.emit(StreamType.UPDATE.toString(),tuple,topology);
    }
 else {
      logger.warn("String_Node_Str");
    }
    logger.debug("String_Node_Str",message.getCorrelationId());
    FlowRerouteResponse response=new FlowRerouteResponse(flow.left.getFlowPath(),isFoundNewPath);
    Values values=new Values(new InfoMessage(response,message.getTimestamp(),message.getCorrelationId(),Destination.NORTHBOUND));
    outputCollector.emit(StreamType.RESPONSE.toString(),tuple,values);
  }
 catch (  UnroutablePathException e) {
    logger.warn("String_Node_Str",flowId);
    flow.getLeft().setState(FlowState.DOWN);
    flow.getRight().setState(FlowState.DOWN);
    throw new MessageException(message.getCorrelationId(),System.currentTimeMillis(),ErrorType.UPDATE_FAILURE,"String_Node_Str","String_Node_Str");
  }
break;
case CREATE:
flow=flowCache.getFlow(flowId);
logger.warn("String_Node_Str",flow.getLeft().getFlowId(),FlowState.UP);
flow.getLeft().setState(FlowState.UP);
flow.getRight().setState(FlowState.UP);
break;
case DELETE:
flow=flowCache.getFlow(flowId);
logger.warn("String_Node_Str",flow.getLeft().getFlowId(),FlowState.DOWN);
flow.getLeft().setState(FlowState.DOWN);
flow.getRight().setState(FlowState.DOWN);
break;
default :
logger.warn("String_Node_Str",request.getOperation());
break;
}
}