docs: private static String serializeResponse(ResponseHeader header, Response response) throws JsonGenerationException, JsonMappingException, IOException{
          ResponsePair p = new ResponsePair();
          p.setResponseHeader(header);
          if(response == null){
              p.setType(null);
          }else{
              p.setType(response.getClass());
          }
          p.setResponse(toJsonStr(response));
          return toJsonStr(p);
      }