@Override public void dispatch(String[] originalArgs) { final CmdLineParser parser = new CmdLineParser(this); try { parser.parseArgument(originalArgs); if (displayHelp) { printUsage(parser, 0); } else if (displayVersion) { printVersion(); } else { startServer(originalArgs); } } catch (CmdLineException e) { // handling of wrong arguments if (LOGGER.isDebugEnabled()) { LOGGER.debug(e); } else { LOGGER.error(e.getMessage()); } printUsage(parser, 255); } catch (Exception e) { LOGGER.error("Error starting server", e); } }