private void startManagedConnectionFactory(ObjectName on, String connectionURL, String driverClass, String userName) throws Exception
private void startManagedConnectionFactory(ObjectName on) throws Exception
   private void startManagedConnectionFactory(ObjectName on,                                              String connectionURL,                                              String driverClass,                                              String userName) throws Exception   {      LocalManagedConnectionFactory mcf = new LocalManagedConnectionFactory();               if (hsql)      {         mcf.setConnectionURL("jdbc:hsqldb:mem:test");         mcf.setDriverClass("org.hsqldb.jdbcDriver");         mcf.setUserName("sa");      }      else      {         //mysql         mcf.setConnectionURL("jdbc:mysql://localhost:3306/messaging");         mcf.setDriverClass("com.mysql.jdbc.Driver");         mcf.setTransactionIsolation("TRANSACTION_READ_COMMITTED");         mcf.setUserName("root");       //  mcf.setPassword("disco2000");      }      ManagedConnectionFactoryJMXWrapper mbean = new ManagedConnectionFactoryJMXWrapper(mcf);      mbeanServer.registerMBean(mbean, on);      mbeanServer.invoke(on, "start", new Object[0], new String[0]);      log.debug("started " + on);   }