示例#1
0
    @Override
    public void cacheFileAvailable(PnfsId pnfsId, Throwable t) {
      try {
        if (_callback != null) {
          _callback.cacheFileAvailable(pnfsId, t);
        }
        removeCompanion(getId());

        /* In case of a successfull transfer, there is no
         * reason to keep other companions on the same file
         * around.
         */
        if (t == null) {
          cancelCompanions(pnfsId, "Replica already exists");
        }
      } catch (InterruptedException e) {
        // Ignored, typically happens at cell shutdown
      }
    }