]> source.dussan.org Git - jgit.git/commitdiff
Merge branch 'stable-6.5' into stable-6.6 29/204929/1
authorMatthias Sohn <matthias.sohn@sap.com>
Fri, 13 Oct 2023 06:46:11 +0000 (08:46 +0200)
committerMatthias Sohn <matthias.sohn@sap.com>
Fri, 13 Oct 2023 06:50:48 +0000 (08:50 +0200)
* stable-6.5:
  PackConfig: fix @since tags
  Remove unused API problem filters
  Add support for git config repack.packKeptObjects
  Do not exclude objects in locked packs from bitmap processing

Change-Id: I7272a22451c0de6b4770767e7bb4e24c81518c20

1  2 
Documentation/config-options.md
org.eclipse.jgit.pgm/resources/org/eclipse/jgit/pgm/internal/CLIText.properties
org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/file/GC.java
org.eclipse.jgit/src/org/eclipse/jgit/lib/ConfigConstants.java
org.eclipse.jgit/src/org/eclipse/jgit/storage/pack/PackConfig.java

Simple merge
index b0b1d4ff2d61e664d7077ac6b900314da8056508,a8180d1d8d5a4602623f43171ffa40a32a979ff0..be87e07f2294e5ed055e3914554461239ac2d5aa
@@@ -27,10 -27,7 +27,11 @@@ import static org.eclipse.jgit.lib.Conf
  import static org.eclipse.jgit.lib.ConfigConstants.CONFIG_KEY_DELTA_COMPRESSION;
  import static org.eclipse.jgit.lib.ConfigConstants.CONFIG_KEY_DEPTH;
  import static org.eclipse.jgit.lib.ConfigConstants.CONFIG_KEY_INDEXVERSION;
 +import static org.eclipse.jgit.lib.ConfigConstants.CONFIG_KEY_MIN_BYTES_OBJ_SIZE_INDEX;
  import static org.eclipse.jgit.lib.ConfigConstants.CONFIG_KEY_MIN_SIZE_PREVENT_RACYPACK;
++import static org.eclipse.jgit.lib.ConfigConstants.CONFIG_KEY_PACK_KEPT_OBJECTS;
 +import static org.eclipse.jgit.lib.ConfigConstants.CONFIG_KEY_PRESERVE_OLD_PACKS;
 +import static org.eclipse.jgit.lib.ConfigConstants.CONFIG_KEY_PRUNE_PRESERVED;
  import static org.eclipse.jgit.lib.ConfigConstants.CONFIG_KEY_REUSE_DELTAS;
  import static org.eclipse.jgit.lib.ConfigConstants.CONFIG_KEY_REUSE_OBJECTS;
  import static org.eclipse.jgit.lib.ConfigConstants.CONFIG_KEY_SEARCH_FOR_REUSE_TIMEOUT;
@@@ -39,8 -36,12 +40,9 @@@ import static org.eclipse.jgit.lib.Conf
  import static org.eclipse.jgit.lib.ConfigConstants.CONFIG_KEY_WAIT_PREVENT_RACYPACK;
  import static org.eclipse.jgit.lib.ConfigConstants.CONFIG_KEY_WINDOW;
  import static org.eclipse.jgit.lib.ConfigConstants.CONFIG_KEY_WINDOW_MEMORY;
 -import static org.eclipse.jgit.lib.ConfigConstants.CONFIG_KEY_MIN_BYTES_OBJ_SIZE_INDEX;
 +import static org.eclipse.jgit.lib.ConfigConstants.CONFIG_KEY_WRITE_REVERSE_INDEX;
  import static org.eclipse.jgit.lib.ConfigConstants.CONFIG_PACK_SECTION;
 -import static org.eclipse.jgit.lib.ConfigConstants.CONFIG_KEY_PACK_KEPT_OBJECTS;
 -import static org.eclipse.jgit.lib.ConfigConstants.CONFIG_KEY_PRESERVE_OLD_PACKS;
 -import static org.eclipse.jgit.lib.ConfigConstants.CONFIG_KEY_PRUNE_PRESERVED;
+ import static org.eclipse.jgit.lib.ConfigConstants.CONFIG_REPACK_SECTION;
  
  import java.time.Duration;
  import java.util.concurrent.Executor;
@@@ -301,10 -304,10 +313,12 @@@ public class PackConfig 
  
        private int indexVersion = DEFAULT_INDEX_VERSION;
  
 +      private boolean writeReverseIndex = DEFAULT_WRITE_REVERSE_INDEX;
 +
        private boolean buildBitmaps = DEFAULT_BUILD_BITMAPS;
  
+       private boolean packKeptObjects = DEFAULT_PACK_KEPT_OBJECTS;
        private int bitmapContiguousCommitCount = DEFAULT_BITMAP_CONTIGUOUS_COMMIT_COUNT;
  
        private int bitmapRecentCommitCount = DEFAULT_BITMAP_RECENT_COMMIT_COUNT;
                this.threads = cfg.threads;
                this.executor = cfg.executor;
                this.indexVersion = cfg.indexVersion;
 +              this.writeReverseIndex = cfg.writeReverseIndex;
                this.buildBitmaps = cfg.buildBitmaps;
+               this.packKeptObjects = cfg.packKeptObjects;
                this.bitmapContiguousCommitCount = cfg.bitmapContiguousCommitCount;
                this.bitmapRecentCommitCount = cfg.bitmapRecentCommitCount;
                this.bitmapRecentCommitSpan = cfg.bitmapRecentCommitSpan;
                setSinglePack(rc.getBoolean(CONFIG_PACK_SECTION,
                                CONFIG_KEY_SINGLE_PACK,
                                getSinglePack()));
-               setBuildBitmaps(rc.getBoolean(CONFIG_PACK_SECTION,
-                               CONFIG_KEY_BUILD_BITMAPS, isBuildBitmaps()));
 +              setWriteReverseIndex(rc.getBoolean(CONFIG_PACK_SECTION,
 +                              CONFIG_KEY_WRITE_REVERSE_INDEX, isWriteReverseIndex()));
+               boolean buildBitmapsFromConfig = rc.getBoolean(CONFIG_PACK_SECTION,
+                               CONFIG_KEY_BUILD_BITMAPS, isBuildBitmaps());
+               setBuildBitmaps(buildBitmapsFromConfig);
+               setPackKeptObjects(rc.getBoolean(CONFIG_REPACK_SECTION,
+                               CONFIG_KEY_PACK_KEPT_OBJECTS,
+                               buildBitmapsFromConfig || isPackKeptObjects()));
                setBitmapContiguousCommitCount(rc.getInt(CONFIG_PACK_SECTION,
                                CONFIG_KEY_BITMAP_CONTIGUOUS_COMMIT_COUNT,
                                getBitmapContiguousCommitCount()));