/** {@inheritDoc} */
  @Override
  protected GridConfiguration getConfiguration(String gridName) throws Exception {
    GridConfiguration cfg = super.getConfiguration(gridName);

    cfg.setCacheConfiguration(
        cacheConfiguration(META_CACHE_NAME), cacheConfiguration(DATA_CACHE_NAME));

    GridTcpDiscoverySpi discoSpi = new GridTcpDiscoverySpi();

    discoSpi.setIpFinder(IP_FINDER);

    cfg.setDiscoverySpi(discoSpi);

    GridGgfsConfiguration ggfsCfg = new GridGgfsConfiguration();

    ggfsCfg.setMetaCacheName(META_CACHE_NAME);
    ggfsCfg.setDataCacheName(DATA_CACHE_NAME);
    ggfsCfg.setName("ggfs");
    ggfsCfg.setBlockSize(CFG_BLOCK_SIZE);
    ggfsCfg.setFragmentizerEnabled(true);

    cfg.setGgfsConfiguration(ggfsCfg);

    return cfg;
  }
  /** {@inheritDoc} */
  @Override
  protected GridConfiguration getConfiguration(String gridName) throws Exception {
    GridConfiguration c = super.getConfiguration(gridName);

    GridTcpDiscoverySpi discoSpi = new GridTcpDiscoverySpi();

    discoSpi.setIpFinder(new GridTcpDiscoveryVmIpFinder(true));

    c.setDiscoverySpi(discoSpi);

    c.setExecutorService(
        new ThreadPoolExecutor(
            SPLIT_COUNT,
            SPLIT_COUNT,
            0,
            TimeUnit.MILLISECONDS,
            new LinkedBlockingQueue<Runnable>()));

    c.setExecutorServiceShutdown(true);

    return c;
  }