Package proj.zoie.api

Examples of proj.zoie.api.Zoie


    DirectoryManager dirMgr = new DefaultDirectoryManager(dest, DIRECTORY_MODE.MMAP);
    Zoie<R, D> zoie = new ZoieSystem(dirMgr, _interpreter, _decorator, _zoieConfig);
    if (_running) zoie.start();

    if (_zoieOne != null) {
      final Zoie toBeShutdown = _zoieOne;
      _zoieOne = zoie;

      Timer cleanupTimer = new Timer();

      cleanupTimer.schedule(new TimerTask() {
        @Override
        public void run() {
          synchronized (_activeReaders) {
            for (ZoieRef z : _activeReaders.values()) {
              if (z.zoie == toBeShutdown) {
                log.info("Waiting for active readers...");
                return;
              }
            }
          }
          log.info("Shuting down old zoie...");
          toBeShutdown.shutdown();
          cancel();
        }
      }, 8000, 8000);
    }
View Full Code Here


  @Override
  public void returnIndexReaders(List<ZoieMultiReader<R>> readers) {
    if (readers != null) {
      Map<Zoie<R, D>, List<ZoieMultiReader<R>>> destMap = new HashMap<Zoie<R, D>, List<ZoieMultiReader<R>>>();
      for (ZoieMultiReader<R> r : readers) {
        Zoie zoie = _zoieTwo;

        synchronized (_activeReaders) {
          ZoieRef zoieRef = _activeReaders.get(r);

          if (zoieRef != null) {
View Full Code Here

TOP

Related Classes of proj.zoie.api.Zoie

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.