/**
   * Dummy Main method
   *
   * @param args
   */
  public static void main(String[] args) {
    InternalLoggerFactory.setDefaultFactory(new WaarpSlf4JLoggerFactory(null));
    if (logger == null) {
      logger = WaarpInternalLoggerFactory.getLogger(AbstractBusinessRequest.class);
    }
    if (!getParams(args)) {
      logger.error("Wrong initialization");
      if (DbConstant.admin != null && DbConstant.admin.isConnected) {
        DbConstant.admin.close();
      }
      ChannelUtils.stopLogger();
      System.exit(2);
    }

    Configuration.configuration.pipelineInit();
    NetworkTransaction networkTransaction = new NetworkTransaction();
    R66Future future = new R66Future(true);

    logger.info("Start Test of Transaction");
    long time1 = System.currentTimeMillis();

    @SuppressWarnings("unused")
    BusinessRequestPacket packet = new BusinessRequestPacket(classname + " " + classarg, 0);
    // XXX FIXME this has to be adapted
    /*
     * AbstractBusinessRequest transaction = new AbstractBusinessRequest(
     * AbstractBusinessRequest.class, future, rhost, networkTransaction, packet);
     * transaction.run(); future.awaitUninterruptibly();
     */
    long time2 = System.currentTimeMillis();
    logger.debug("Finish Business Request: " + future.isSuccess());
    long delay = time2 - time1;
    if (future.isSuccess()) {
      logger.info(
          "Business Request in status:\nSUCCESS"
              + "\n    <REMOTE>"
              + rhost
              + "</REMOTE>"
              + "\n    delay: "
              + delay);
    } else {
      logger.info(
          "Business Request in status:\nFAILURE"
              + "\n    <REMOTE>"
              + rhost
              + "</REMOTE>"
              + "\n    <ERROR>"
              + future.getCause()
              + "</ERROR>"
              + "\n    delay: "
              + delay);
      networkTransaction.closeAll();
      System.exit(ErrorCode.Unknown.ordinal());
    }
    networkTransaction.closeAll();
  }