Features
- PackObjectSizeIndex: Introduce an interface for the Object-size index. This index returns the inflated size of an object. Not all objects are indexed (to limit memory usage). This implementation indexes only blobs (no trees, nor
commits) *above* certain size threshold (configurable). - PackIndex: expose the position of an object-id in the index via #findPosition(object-id)
- Add pack options to preserve and prune old pack files
- pack.preserveOldPacks
- pack.prunePreserved - 573390 UploadPack: support allow-any-sha1-in-want option. When both uploadPack.allowFilter and uploadPack.allowAnySHA1InWant are true, jgit supports partial clone.
- UploadPack: advertise object-info command if enabled
- 475615 [pgm] Fetch-CLI: add support for shallow clone/fetch
- Acquire file lock "gc.pid" before running gc to prevent concurrent gc on the same repository
- BatchingProgressMonitor: expose time spent per task. Display elapsed time per task if enabled via API or if system property or environment variable GIT_TRACE_PERFORMANCE is set to "true".
- 576165 Add TernarySearchTree to be used to implement a ref cache
574368 Commit graph support
- Add Commit Graph stats fields into DfsReaderIoStats
- RevWalk: integrate commit-graph with commit parsing
- GC: disable writing commit-graph for shallow repos
- CommitGraph: teach ObjectReader to get commit-graph
- CommitGraph: add commit-graph for FileObjectDatabase
- GC: Write commit-graph files when gc
- CommitGraph: add core.commitGraph config
- CommitGraph: implement commit-graph read
- CommitGraph: implement commit-graph writer
- DfsPackFile/DfsGC: Write commit graphs and expose in pack
Incompatible changes
- Replace config option pull.rebase=preserve by pull.rebase=merges. This follows native git which removed the "preserve" option in git 2.34.
Performance Improvements
- Add option to perform PackedBatchRefUpdate without locking loose refs
- Shortcut during git fetch for avoiding looping through all local refs for refs pointing to non-commit objects
- Allow the exclusions of refs prefixes from bitmap index generation
- 581267 PackWriterBitmapPreparer: do not include annotated tags in bitmap
- Speedup jgit GC when listing objects referenced from reflogs
- Cache trustFolderStat/trustPackedRefsStat value per-instance. Instead of re-reading the config every time the methods using these values were called, cache the config value at the time of instance construction.
- Introduce core.trustPackedRefsStat config. Currently, we always read packed-refs file when 'trustFolderStat' is false. Introduce a new config 'trustPackedRefsStat' which takes precedence over 'trustFolderStat' when reading packed refs. When repositories are stored on NFS and option 'trustFolderStat=false' was used now 'trustPackedRefsStat=after_open' can be used to get some performance improvement as it refreshes the file attributes of packed-refs (at least on some NFS clients) before considering it.
- Gc#deleteOrphans: avoid dependence on PackExt alphabetical ordering
Bug Fixes
- [sshd] Fix calculation of timeout in AbstractClientProxyConnector
- UploadPack: consume delimiter in object-info command causing "PackProtocolException: unexpected <empty string>"
- FetchCommand: fix fetchSubmodules to work on a Ref to a blob
- BatchingProgressMonitor: avoid int overflow when computing percentage
- 581317 Refresh 'objects' dir and retry if a loose object is not found. A new loose object may not be immediately visible on a NFS client if it was created on another client. Refreshing the 'objects' dir and trying again can help work around the NFS behavior.
- 581234 PatchApplier: fix handling of last newline in text patch
- 535919 Fix crashes on rare combination of file names
Build and Release Engineering
- Update Orbit to R20230302014618 for 2023-03
Update
- com.google.gson to 2.10.1.v20230109-0753
- org.apache.commons.compress to 1.22.0.v20221207-1049
- org.apache.httpcomponents.httpclient to 4.5.14.v20221207-1049
- org.apache.httpcomponents.httpcore to 4.4.16.v20221207-1049
- jetty to 10.0.13
Upgrade maven plugins
- build-helper-maven-plugin to 3.3.0
- eclipse-jarsigner-plugin to 1.3.5
- jacoco-maven-plugin to 0.8.8
- japicmp to 0.17.1
- maven-antrun-plugin to 3.1.0
- maven-clean-plugin to 3.2.0
- maven-compiler-plugin to 3.10.1
- maven-dependency-plugin to 3.5.0
- maven-deploy-plugin to 3.0.0
- maven-enforcer-plugin to 3.1.0
- maven-install-plugin to 3.1.0
- maven-jar-plugin to 3.3.0
- maven-javadoc-plugin to 3.4.1
- maven-jxr-plugin to 3.3.0
- maven-pmd-plugin to 3.20.0
- maven-project-info-reports-plugin to 3.4.2
- maven-resources-plugin to 3.3.0
- maven-shade-plugin to 3.4.1
- maven-site-plugin to 4.0.0-M4
- maven-surefire-plugin to 3.0.0-M8
- spotbugs-maven-plugin to 4.7.3.0
- spring-boot-maven-plugin to 2.7.7