You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

Support LFS protocol and a file system based LFS storage Implement LfsProtocolServlet handling the "Git LFS v1 Batch API" protocol [1]. Add a simple file system based LFS content store and the debug-lfs-store command to simplify testing. Introduce a LargeFileRepository interface to enable additional storage implementation while reusing the same protocol implementation. At the client side we have to configure the lfs.url, specify that we use the batch API and we don't use authentication: [lfs] url = http://host:port/lfs batch = true [lfs "http://host:port/lfs"] access = none the git-lfs client appends the "objects/batch" to the lfs.url. Hard code an Authorization header in the FileLfsRepository.getAction because then git-lfs client will skip asking for credentials. It will just forward the Authorization header from the response to the download/upload request. The FileLfsServlet supports file content storage for "Large File Storage" (LFS) server as defined by the Github LFS API [2]. - upload and download of large files is probably network bound hence use an asynchronous servlet for good scalability - simple object storage in file system with 2 level fan-out - use LockFile to protect writing large objects against multiple concurrent uploads of the same object - to prevent corrupt uploads the uploaded file is rejected if its hash doesn't match id given in URL The debug-lfs-store command is used to run the LfsProtocolServlet and, optionally, the FileLfsServlet which makes it easier to setup a local test server. [1] https://github.com/github/git-lfs/blob/master/docs/api/http-v1-batch.md [2] https://github.com/github/git-lfs/tree/master/docs/api Bug: 472961 Change-Id: I7378da5575159d2195138d799704880c5c82d5f3 Signed-off-by: Matthias Sohn <matthias.sohn@sap.com> Signed-off-by: Sasa Zivkov <sasa.zivkov@sap.com>
преди 8 години
Merge branch 'stable-5.1' into stable-5.2 * stable-5.1: Fix OpenSshConfigTest#config FileSnapshot: fix bug with timestamp thresholding In LockFile#waitForStatChange wait in units of file time resolution Cache FileStoreAttributeCache per directory Fix FileSnapshot#save(long) and FileSnapshot#save(Instant) Persist minimal racy threshold and allow manual configuration Measure minimum racy interval to auto-configure FileSnapshot Reuse FileUtils to recursively delete files created by tests Fix FileAttributeCache.toString() Add test for racy git detection in FileSnapshot Repeat RefDirectoryTest.testGetRef_DiscoversModifiedLoose 100 times Fix org.eclipse.jdt.core.prefs of org.eclipse.jgit.junit Add missing javadoc in org.eclipse.jgit.junit Enhance RepeatRule to report number of failures at the end Fix FileSnapshotTests for filesystem with high timestamp resolution Retry deleting test files in FileBasedConfigTest Measure filesystem timestamp resolution already in test setup Refactor FileSnapshotTest to use NIO APIs Measure stored timestamp resolution instead of time to touch file Handle CancellationException in FileStoreAttributeCache Fix FileSnapshot#saveNoConfig Use Instant for smudge time in DirCache and DirCacheEntry Use Instant instead of milliseconds for filesystem timestamp handling Workaround SecurityException in FS#getFsTimestampResolution Fix NPE in FS$FileStoreAttributeCache.getFsTimestampResolution FS: ignore AccessDeniedException when measuring timestamp resolution Add debug trace for FileSnapshot Use FileChannel.open to touch file and set mtime to now Persist filesystem timestamp resolution and allow manual configuration Increase bazel timeout for long running tests Bazel: Fix lint warning flagged by buildifier Update bazlets to latest version Bazel: Add missing dependencies for ArchiveCommandTest Bazel: Remove FileTreeIteratorWithTimeControl from BUILD file Add support for nanoseconds and microseconds for Config#getTimeUnit Optionally measure filesystem timestamp resolution asynchronously Delete unused FileTreeIteratorWithTimeControl FileSnapshot#equals: consider UNKNOWN_SIZE Timeout measuring file timestamp resolution after 2 seconds Fix RacyGitTests#testRacyGitDetection Change RacyGitTests to create a racy git situation in a stable way Deprecate Constants.CHARACTER_ENCODING in favor of StandardCharsets.UTF_8 Fix non-deterministic hash of archives created by ArchiveCommand Update Maven plugins ecj, plexus, error-prone Update Maven plugins and cleanup Maven warnings Make inner classes static where possible Fix API problem filters Change-Id: Ia57385b2a60f48a5317c8d723721c235d7043a84 Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
преди 4 години
Added read/write support for pack bitmap index. A pack bitmap index is an additional index of compressed bitmaps of the object graph. Furthermore, a logical API of the index functionality is included, as it is expected to be used by the PackWriter. Compressed bitmaps are created using the javaewah library, which is a word-aligned compressed variant of the Java bitset class based on run-length encoding. The library only works with positive integer values. Thus, the maximum number of ObjectIds in a pack file that this index can currently support is limited to Integer.MAX_VALUE. Every ObjectId is given an integer mapping. The integer is the position of the ObjectId in the complete ObjectId list, sorted by offset, for the pack file. That integer is what the bitmaps use to reference the ObjectId. Currently, the new index format can only be used with pack files that contain a complete closure of the object graph e.g. the result of a garbage collection. The index file includes four bitmaps for the Git object types i.e. commits, trees, blobs, and tags. In addition, a collection of bitmaps keyed by an ObjectId is also included. The bitmap for each entry in the collection represents the full closure of ObjectIds reachable from the keyed ObjectId (including the keyed ObjectId itself). The bitmaps are further compressed by XORing the current bitmaps against prior bitmaps in the index, and selecting the smallest representation. The XOR'd bitmap and offset from the current entry to the position of the bitmap to XOR against is the actual representation of the entry in the index file. Each entry contains one byte, which is currently used to note whether the bitmap should be blindly reused. Change-Id: Id328724bf6b4c8366a088233098c18643edcf40f
преди 11 години
123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164
  1. Manifest-Version: 1.0
  2. Bundle-ManifestVersion: 2
  3. Bundle-Name: %plugin_name
  4. Automatic-Module-Name: org.eclipse.jgit
  5. Bundle-SymbolicName: org.eclipse.jgit
  6. Bundle-Version: 5.2.3.qualifier
  7. Bundle-Localization: plugin
  8. Bundle-Vendor: %provider_name
  9. Bundle-ActivationPolicy: lazy
  10. Export-Package: org.eclipse.jgit.annotations;version="5.2.3",
  11. org.eclipse.jgit.api;version="5.2.3";
  12. uses:="org.eclipse.jgit.revwalk,
  13. org.eclipse.jgit.treewalk.filter,
  14. org.eclipse.jgit.diff,
  15. org.eclipse.jgit.util,
  16. org.eclipse.jgit.notes,
  17. org.eclipse.jgit.dircache,
  18. org.eclipse.jgit.api.errors,
  19. org.eclipse.jgit.lib,
  20. org.eclipse.jgit.treewalk,
  21. org.eclipse.jgit.blame,
  22. org.eclipse.jgit.submodule,
  23. org.eclipse.jgit.transport,
  24. org.eclipse.jgit.merge",
  25. org.eclipse.jgit.api.errors;version="5.2.3";uses:="org.eclipse.jgit.lib,org.eclipse.jgit.errors",
  26. org.eclipse.jgit.attributes;version="5.2.3",
  27. org.eclipse.jgit.blame;version="5.2.3";
  28. uses:="org.eclipse.jgit.lib,
  29. org.eclipse.jgit.revwalk,
  30. org.eclipse.jgit.treewalk.filter,
  31. org.eclipse.jgit.diff",
  32. org.eclipse.jgit.diff;version="5.2.3";
  33. uses:="org.eclipse.jgit.patch,
  34. org.eclipse.jgit.lib,
  35. org.eclipse.jgit.treewalk,
  36. org.eclipse.jgit.revwalk,
  37. org.eclipse.jgit.treewalk.filter,
  38. org.eclipse.jgit.util",
  39. org.eclipse.jgit.dircache;version="5.2.3";
  40. uses:="org.eclipse.jgit.lib,
  41. org.eclipse.jgit.treewalk,
  42. org.eclipse.jgit.util,
  43. org.eclipse.jgit.events,
  44. org.eclipse.jgit.attributes",
  45. org.eclipse.jgit.errors;version="5.2.3";
  46. uses:="org.eclipse.jgit.lib,
  47. org.eclipse.jgit.internal.storage.pack,
  48. org.eclipse.jgit.transport,
  49. org.eclipse.jgit.dircache",
  50. org.eclipse.jgit.events;version="5.2.3";uses:="org.eclipse.jgit.lib",
  51. org.eclipse.jgit.fnmatch;version="5.2.3",
  52. org.eclipse.jgit.gitrepo;version="5.2.3";
  53. uses:="org.eclipse.jgit.api,
  54. org.eclipse.jgit.lib,
  55. org.eclipse.jgit.revwalk,
  56. org.xml.sax.helpers,
  57. org.xml.sax",
  58. org.eclipse.jgit.gitrepo.internal;version="5.2.3";x-internal:=true,
  59. org.eclipse.jgit.hooks;version="5.2.3";uses:="org.eclipse.jgit.lib",
  60. org.eclipse.jgit.ignore;version="5.2.3",
  61. org.eclipse.jgit.ignore.internal;version="5.2.3";x-friends:="org.eclipse.jgit.test",
  62. org.eclipse.jgit.internal;version="5.2.3";x-friends:="org.eclipse.jgit.test,org.eclipse.jgit.http.test",
  63. org.eclipse.jgit.internal.fsck;version="5.2.3";x-friends:="org.eclipse.jgit.test",
  64. org.eclipse.jgit.internal.ketch;version="5.2.3";x-friends:="org.eclipse.jgit.junit,org.eclipse.jgit.test,org.eclipse.jgit.pgm",
  65. org.eclipse.jgit.internal.revwalk;version="5.2.3";x-internal:=true,
  66. org.eclipse.jgit.internal.storage.dfs;version="5.2.3";
  67. x-friends:="org.eclipse.jgit.test,
  68. org.eclipse.jgit.http.server,
  69. org.eclipse.jgit.http.test,
  70. org.eclipse.jgit.lfs.test",
  71. org.eclipse.jgit.internal.storage.file;version="5.2.3";
  72. x-friends:="org.eclipse.jgit.test,
  73. org.eclipse.jgit.junit,
  74. org.eclipse.jgit.junit.http,
  75. org.eclipse.jgit.http.server,
  76. org.eclipse.jgit.lfs,
  77. org.eclipse.jgit.pgm,
  78. org.eclipse.jgit.pgm.test,
  79. org.eclipse.jgit.ssh.apache",
  80. org.eclipse.jgit.internal.storage.io;version="5.2.3";x-friends:="org.eclipse.jgit.junit,org.eclipse.jgit.test,org.eclipse.jgit.pgm",
  81. org.eclipse.jgit.internal.storage.pack;version="5.2.3";x-friends:="org.eclipse.jgit.junit,org.eclipse.jgit.test,org.eclipse.jgit.pgm",
  82. org.eclipse.jgit.internal.storage.reftable;version="5.2.3";
  83. x-friends:="org.eclipse.jgit.http.test,
  84. org.eclipse.jgit.junit,
  85. org.eclipse.jgit.test,
  86. org.eclipse.jgit.pgm",
  87. org.eclipse.jgit.internal.storage.reftree;version="5.2.3";x-friends:="org.eclipse.jgit.junit,org.eclipse.jgit.test,org.eclipse.jgit.pgm",
  88. org.eclipse.jgit.internal.submodule;version="5.2.3";x-internal:=true,
  89. org.eclipse.jgit.internal.transport.parser;version="5.2.3";x-friends:="org.eclipse.jgit.test,org.eclipse.jgit.http.server",
  90. org.eclipse.jgit.internal.transport.ssh;version="5.2.3";x-friends:="org.eclipse.jgit.ssh.apache",
  91. org.eclipse.jgit.lib;version="5.2.3";
  92. uses:="org.eclipse.jgit.revwalk,
  93. org.eclipse.jgit.treewalk.filter,
  94. org.eclipse.jgit.util,
  95. org.eclipse.jgit.events,
  96. org.eclipse.jgit.dircache,
  97. org.eclipse.jgit.internal.storage.file,
  98. org.eclipse.jgit.treewalk,
  99. org.eclipse.jgit.transport,
  100. org.eclipse.jgit.submodule",
  101. org.eclipse.jgit.lib.internal;version="5.2.3";x-internal:=true,
  102. org.eclipse.jgit.merge;version="5.2.3";
  103. uses:="org.eclipse.jgit.lib,
  104. org.eclipse.jgit.treewalk,
  105. org.eclipse.jgit.revwalk,
  106. org.eclipse.jgit.diff,
  107. org.eclipse.jgit.dircache,
  108. org.eclipse.jgit.api",
  109. org.eclipse.jgit.nls;version="5.2.3",
  110. org.eclipse.jgit.notes;version="5.2.3";
  111. uses:="org.eclipse.jgit.lib,
  112. org.eclipse.jgit.treewalk,
  113. org.eclipse.jgit.revwalk,
  114. org.eclipse.jgit.merge",
  115. org.eclipse.jgit.patch;version="5.2.3";uses:="org.eclipse.jgit.lib,org.eclipse.jgit.diff",
  116. org.eclipse.jgit.revplot;version="5.2.3";uses:="org.eclipse.jgit.lib,org.eclipse.jgit.revwalk",
  117. org.eclipse.jgit.revwalk;version="5.2.3";
  118. uses:="org.eclipse.jgit.lib,
  119. org.eclipse.jgit.treewalk,
  120. org.eclipse.jgit.treewalk.filter,
  121. org.eclipse.jgit.diff,
  122. org.eclipse.jgit.revwalk.filter",
  123. org.eclipse.jgit.revwalk.filter;version="5.2.3";uses:="org.eclipse.jgit.revwalk,org.eclipse.jgit.lib,org.eclipse.jgit.util",
  124. org.eclipse.jgit.storage.file;version="5.2.3";uses:="org.eclipse.jgit.lib,org.eclipse.jgit.util",
  125. org.eclipse.jgit.storage.pack;version="5.2.3";uses:="org.eclipse.jgit.lib",
  126. org.eclipse.jgit.submodule;version="5.2.3";uses:="org.eclipse.jgit.lib,org.eclipse.jgit.treewalk.filter,org.eclipse.jgit.treewalk",
  127. org.eclipse.jgit.transport;version="5.2.3";
  128. uses:="org.eclipse.jgit.transport.resolver,
  129. org.eclipse.jgit.revwalk,
  130. org.eclipse.jgit.internal.storage.pack,
  131. com.jcraft.jsch,
  132. org.eclipse.jgit.util,
  133. org.eclipse.jgit.util.io,
  134. org.eclipse.jgit.internal.storage.file,
  135. org.eclipse.jgit.lib,
  136. org.eclipse.jgit.transport.http,
  137. org.eclipse.jgit.errors,
  138. org.eclipse.jgit.storage.pack",
  139. org.eclipse.jgit.transport.http;version="5.2.3";uses:="javax.net.ssl",
  140. org.eclipse.jgit.transport.resolver;version="5.2.3";uses:="org.eclipse.jgit.lib,org.eclipse.jgit.transport",
  141. org.eclipse.jgit.treewalk;version="5.2.3";
  142. uses:="org.eclipse.jgit.lib,
  143. org.eclipse.jgit.revwalk,
  144. org.eclipse.jgit.attributes,
  145. org.eclipse.jgit.treewalk.filter,
  146. org.eclipse.jgit.util,
  147. org.eclipse.jgit.dircache",
  148. org.eclipse.jgit.treewalk.filter;version="5.2.3";uses:="org.eclipse.jgit.treewalk",
  149. org.eclipse.jgit.util;version="5.2.3";
  150. uses:="org.eclipse.jgit.lib,
  151. org.eclipse.jgit.transport.http,
  152. org.eclipse.jgit.storage.file,
  153. org.ietf.jgss",
  154. org.eclipse.jgit.util.io;version="5.2.3",
  155. org.eclipse.jgit.util.sha1;version="5.2.3",
  156. org.eclipse.jgit.util.time;version="5.2.3"
  157. Bundle-RequiredExecutionEnvironment: JavaSE-1.8
  158. Import-Package: com.googlecode.javaewah;version="[1.1.6,2.0.0)",
  159. com.jcraft.jsch;version="[0.1.37,0.2.0)",
  160. javax.crypto,
  161. javax.net.ssl,
  162. org.slf4j;version="[1.7.0,2.0.0)",
  163. org.xml.sax,
  164. org.xml.sax.helpers