Example #1
0
  /** {@inheritDoc} */
  @Override
  public void start(BenchmarkConfiguration cfg) throws Exception {
    IgniteBenchmarkArguments args = new IgniteBenchmarkArguments();

    BenchmarkUtils.jcommander(cfg.commandLineArguments(), args, "<ignite-node>");

    IgniteConfiguration c = loadConfiguration(args.configuration());

    assert c != null;

    // Server node doesn't contains cache configuration. Driver will create dynamic cache.
    c.setCacheConfiguration();

    TransactionConfiguration tc = c.getTransactionConfiguration();

    tc.setDefaultTxConcurrency(args.txConcurrency());
    tc.setDefaultTxIsolation(args.txIsolation());

    TcpCommunicationSpi commSpi = (TcpCommunicationSpi) c.getCommunicationSpi();

    if (commSpi == null) commSpi = new TcpCommunicationSpi();

    c.setCommunicationSpi(commSpi);

    ignite = Ignition.start(c);
  }
Example #2
0
 /** {@inheritDoc} */
 @Override
 public void stop() throws Exception {
   Ignition.stopAll(true);
 }