Package org.eclipse.jgit.internal.storage.pack

Examples of org.eclipse.jgit.internal.storage.pack.PackWriter.release()


        try {
          writePack(objdb, pack, pw, pm);
          writeIndex(objdb, pack, pw);

          PackWriter.Statistics stats = pw.getStatistics();
          pw.release();
          pw = null;

          pack.setPackStats(stats);
          objdb.commitPack(Collections.singletonList(pack), toPrune());
          newPacks.add(pack);
View Full Code Here


          if (rollback)
            objdb.rollbackPack(Collections.singletonList(pack));
        }
      } finally {
        if (pw != null)
          pw.release();
      }
    } finally {
      rw = null;
      ctx.release();
    }
View Full Code Here

        } finally {
          out.close();
        }
        idx.setReadOnly();
      } finally {
        pw.release();
      }

      odb.openPack(pack);
      updateServerInfo();
      prunePacked(odb);
View Full Code Here

    packOS.close();
    File idxFile = new File(packdir, "pack-" + id + ".idx");
    FileOutputStream idxOS = new FileOutputStream(idxFile);
    pw.writeIndex(idxOS);
    idxOS.close();
    pw.release();
    return PackIndex.open(idxFile);
  }

  // TODO: testWritePackDeltasCycle()
  // TODO: testWritePackDeltasDepth()
View Full Code Here

      w.write('\n');
      w.flush();
      packWriter.writePack(monitor, monitor, os);
    } finally {
      packWriter.release();
    }
  }
}
View Full Code Here

      writer.setReuseValidatingObjects(false);
      writer.setDeltaBaseAsOffset(capableOfsDelta);
      writer.preparePack(monitor, newObjects, remoteObjects);
      writer.writePack(monitor, monitor, out);
    } finally {
      writer.release();
    }
    packTransferTime = writer.getStatistics().getTimeWriting();
  }

  private void readStatusReport(final Map<String, RemoteRefUpdate> refUpdates)
View Full Code Here

        msgOut.write(Constants.encode(msg));
        msgOut.flush();
      }

    } finally {
      pw.release();
    }

    if (sideband)
      pckOut.end();
View Full Code Here

        try {
          writePack(objdb, pack, pw, pm);
          writeIndex(objdb, pack, pw);

          PackWriter.Statistics stats = pw.getStatistics();
          pw.release();
          pw = null;

          pack.setPackStats(stats);
          objdb.commitPack(Collections.singletonList(pack), toPrune());
          newPacks.add(pack);
View Full Code Here

          if (rollback)
            objdb.rollbackPack(Collections.singletonList(pack));
        }
      } finally {
        if (pw != null)
          pw.release();
      }
    } finally {
      rw = null;
      ctx.release();
    }
View Full Code Here

          }
        }
      }
      return repo.getObjectDatabase().openPack(realPack);
    } finally {
      pw.release();
      if (tmpPack != null && tmpPack.exists())
        tmpPack.delete();
      for (File tmpExt : tmpExts.values()) {
        if (tmpExt.exists())
          tmpExt.delete();
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. 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.