code: public Either<String, Either<Mapper4All, JSONArray>> fireQuery(String jsonQuery, Map<String, String> reqHeaders, boolean requiresMapping) {
          CloseableHttpResponse resp = null;
          String respStr;
          String url = format(brokerUrl, brokerHost, brokerPort);
          try {
              resp = postJson(url, jsonQuery, reqHeaders);
              respStr = IOUtils.toString(resp.getEntity().getContent());
          } catch (IOException ex) {
              return new Left<>(format("Http %s, faced exception %s\n", resp, ex));        
          } finally {
              returnClient(resp);
          }
          JSONArray possibleResArray = null;
          try {
              possibleResArray = new JSONArray(respStr);
          } catch (JSONException je) {
              return new Left<>(format("Recieved data %s not in json format. \n", respStr));
          }
          if (requiresMapping) {
              return new Right<String, Either<Mapper4All, JSONArray>>(new Left<Mapper4All, JSONArray>(new Mapper4All(possibleResArray)));
          }
          return new Right<String, Either<Mapper4All, JSONArray>>(new Right<Mapper4All, JSONArray>(possibleResArray));
      }
docs: For firing simple queries(i.e non join queries).
  
  @param jsonQuery
  @param reqHeaders
  @param requiresMapping
  @return