Package org.jamesii.core.data.resilience.plugintype

Examples of org.jamesii.core.data.resilience.plugintype.DataResilienceFactory


      this.server = (MasterServer) server;
      this.servername = SimSystem.getUniqueName();

      // default values used...a server.getDataStorageValues() is better
      try {
        DataResilienceFactory factory =
            SimSystem.getRegistry().getFactory(
                AbstractDataResilienceFactory.class, null);

        ParameterBlock parameter = new ParameterBlock();
        parameter.addSubBlock(DataResilienceFactory.USER, "root");
        parameter.addSubBlock(DataResilienceFactory.PASSWORD, "");
        parameter.addSubBlock(DataResilienceFactory.DRIVER, "com.mysql.jdbc.Driver");
        parameter.addSubBlock(DataResilienceFactory.DATABASEURL,
            "jdbc:mysql://localhost/test");
        setDataStorage(factory.create(parameter, SimSystem.getRegistry().createContext()));
      } catch (Exception ex) {
        SimSystem.report(Level.SEVERE,
            "It was not possible to establish the Resilience data connection! "
                + "Will continue without resilience support!", ex);
      }
View Full Code Here

TOP

Related Classes of org.jamesii.core.data.resilience.plugintype.DataResilienceFactory

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.