| Commit message (Collapse) | Author | Age | Files | Lines |
... | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
Downstream validators complain about these docstrings missing.
Change-Id: I01c1f40eccc7294a613a75d245a6ca03e14a47e1
|
|\ \ \ \ \ |
|
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | | |
In exttst/ (external tests?) we have tests that compare results
with cgit, but they are not in any bazel rule.
Create bazel rules for the tests under exttst/ with a tag "ext". By
default, disable that tag when running tests, as these can be
slow/problematic due to their dependence to an external tool.
bazel test //org.eclipse.jgit.test:all runs the same tests than before..
bazel test --test_tag_filter=ext //org.eclipse.jgit.test:all runs only
these external tests.
Change-Id: I9231fad11ab5ef550bba2d5aaaef60f1bf2094fe
|
|\ \ \ \ \ \
| |_|/ / / /
|/| | | | | |
|
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | | |
FileSnapshot relies on File attributes (which can be retrieved by the
stat() function on Unix) to quickly determine if a File was modified
without reading file content or listing content of a directory.
On NFS this doesn't work reliably due to NFS client caching behavior.
Hence we introduced the option core.trustFolderStat to control if
FileSnapshot can trust File attributes to ensure we don't miss
modifications on NFS. Later more specific options for handling packed
and loose refs were added which also support another config value
AFTER_OPEN, in addition to ALWAYS and NEVER, which refreshes File
attributes by opening a FileInputStream on the file instead of reading
its content and then trusts the File attributes of the refreshed File.
We discussed in jgit-127 how to extend these options for other scenarios
where file attributes are used to detect modifications and came to the
conclusion to improve the existing trustXXX config options in the
following way:
- replace the not well defined "trustFolderStat" option by a general
option "trustStat" which allows to configure all these scenarios with a
single option
- introduce a new enum TrustStat and use it for all scenarios. It has
the values
- NEVER don't trust File attributes
- ALWAYS always trust File attributes
- AFTER_OPEN open a FileInputStream on the respective file or folder
to ensure its File attributes are refreshed and then trust the
refreshed File attributes
- INHERIT only used for specific options to signal it should inherit
its value from the "trustStat" option
- deprecate the old, now unused enums "TrustPackedRefsStat" and
"TrustLooseRefStat"
- deprecate "trustFolderStat", if set, translate it to the corresponding
value of the new option "trustStat"
- if both "trustFolderStat" and "trustStat" are configured the value
configured for "trustStat" takes precedence and "trustFolderStat" is
ignored
- add one specific option for each scenario which can override the
global setting
- add new options "trustLooseObjectStat" and "trustPackStat" which allow
to override the global setting for handling of loose objects and pack
files
- implement option AFTER_OPEN for "trustLooseObjectStat" and
"trustPackStat"
Bug: jgit-127
Change-Id: I662982258bc4494f146805875e52838394673c8f
|
|\| | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | | |
* changes:
Config: add getters for primitive types without default value
CommitConfig: fix potential NPE
|
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | | |
which return null if the option is not configured.
Change-Id: I0d444b396458f49712e35ef32427dc45ee3f8ec8
|
| |/ / / /
|/| | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
The multipack index can be build merging the individual pack indexes
and handling correctly the duplicates.
PackIndexMerger is a utility function that gathers n-indexes and
allows to iterate as one with the correct sha1 order. It also
precalculates some of the needed metadata (as count of objects without
duplicates, or if offsets go over 32 bits).
Change-Id: I515b70fffff4489d83834488daf975f85726ea96
|
|/ / / /
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
To build the multipack index, we will iterate over N indexes merging
the results in sha1 order. With the current MutableEntry API, we need
to create an instance of ObjectId to either compare and/or copy the
selected entry to the multi index iterator.
Allow MutableEntries to compare to each other without creating any new
object, and copy their object id directly to another MutableObjectId.
This allows to build other iterators with mutable entries that copy
the required memory (few ints) instead of creating short-lived instances
of ObjectId.
Change-Id: I0c0091420d7c0847c03afdc9e73b566bb4eeba40
|
|\| | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
* stable-7.1:
RevWalk: Add an isMergedIntoAnyCommit() method
Pack: separate an open/close accounting lock
http.server/BUILD: expose servlet resources as target
Change-Id: Ie53048a5154a4a40f7c0f9da3b8b829d305ab323
|
| |\| |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
* stable-7.0:
RevWalk: Add an isMergedIntoAnyCommit() method
Pack: separate an open/close accounting lock
http.server/BUILD: expose servlet resources as target
Change-Id: I25d3ffe86150d4d9e8a54634145cdbee34ea15fb
|
| | |\|
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
* stable-6.10:
RevWalk: Add an isMergedIntoAnyCommit() method
Pack: separate an open/close accounting lock
http.server/BUILD: expose servlet resources as target
Change-Id: Icda1b3dbc79c47d5dcc45932fe452fcf66e35657
|
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
RevWalk had a bulk isMergedIntoAny() method, however it worked only for
Refs. Add a similar method which works for RevCommits instead.
Unfortunately isMergedIntoAny() cannot be overloaded since java does not
include the generic types in Collections of method signatures, so the
method name needs to be more complicated to differentiate it from the
existing method.
Change-Id: I4f8f3a83058a186fafe3b37726e21c5074a6b8e1
Signed-off-by: Martin Fick <mfick@nvidia.com>
|
| | | |
| | | |
| | | |
| | | | |
Change-Id: I646edcba7809ab91d8e0a933796b4b5c81736232
|
| | | |
| | | |
| | | |
| | | |
| | | | |
Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
Change-Id: I4e4e203c0f6a2463adefd28d3965eaf44bd2e620
|
|\ \ \ \ |
|
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
Transitive dependency to org.apache.commons.lang3 was missing when
running tests in Eclipse.
Change-Id: I364fabc8b76f5401e400e1bf6dcb4fa400ee0494
|
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
The current implementation throws an exception when a submodule is
updated for which the 'gitdir' still exists but the 'worktree' is
missing. The current implementation tries to clone the submodule but
fails as the 'gitdir' is not empty.
The commit adds:
- a check if the 'gitdir' is empty
- if the 'gitdir' is not empty:
- create a new '.git' file linking to the existing 'gitdir'
- fetch the submodule
- checkout the submodule unconditionally (ignore any configured
update mode)
- if the submodule is cloned checkout the submodule unconditionally
(ignore any configured update mode)
This change mimics the behavior of cgit.
Bug: jgit-79
Change-Id: Iffc8659d2a04d866a43815c78c7760c0f3d82640
|
|\ \ \ \ \
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | | |
* changes:
RefDatabase#getReflogReader(String): use #exactRef to resolve refName
Deprecate Repository#getReflogReader methods
Add RefDatabase#getReflogReader methods
|
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | | |
Don't accept short ref names anymore which is more predictable.
Change-Id: I5e7323c610c68b25facd6f2286456716d8e6cf1a
|
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | | |
instead use Repository.getRefDatabase().getReflogReader().
Change-Id: I5e66a512c12e11d0ec3275fffde4adb8483430f2
|
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | | |
to fix broken abstraction in FileRepository#getReflogReader(String).
How to get a ReflogReader depends on the chosen RefDatabase
implementation, hence the #getReflogReader methods should be there.
This also fixes a bug in FileRepository#getReflogReader(Ref) which
didn't work if FileReftableDatabase was used as RefDatabase since it
always returned the implementation only suitable for RefDirectory.
Change-Id: I0859990f9390ab96596b6c344966c687dfbbf167
|
|/ / / / /
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
By instrumenting "LooseObjects#open" with print statements (since
debugging mocks doesn't work in Eclipse) I found that the constructor
"LooseObjects(Config, File)" which defaults "core.trustFolderStat" to
"true" isn't used when mocking LooseObjects. Hence
"core.trustFolderStat" is in fact "false" in the mocked LooseObjects
object.
Make this explicit by configuring "trustFolderStat=false" in a real
"LooseObjects" object and only mock its method "#getObjectLoader" using
a spy.
Change-Id: I2f870637db818c2e89c1c2a174bf78bd572a367a
|
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
The expected value is the first argument and the actual value the second
argument.
Change-Id: I8416cfeaa7a14d0b863658bf133473535647fc57
|
| | | | |
| | | | |
| | | | |
| | | | | |
Change-Id: Ic40473aecb23e22c755a9e041592886fb3c448f9
|
| | | | |
| | | | |
| | | | |
| | | | | |
Change-Id: I6cf6ed64b4029001cb5908338b60385804eb9997
|
| | | | |
| | | | |
| | | | |
| | | | | |
Change-Id: I600538d0ea7ec4377af331341b8e4e2d51a5a51d
|
| | | | |
| | | | |
| | | | |
| | | | | |
Change-Id: I63c37a0fb0f6070aba3947903e79d8ebc014f52d
|
| | | | |
| | | | |
| | | | |
| | | | | |
Change-Id: I8e1b82c76403493faa00ec1a30a6d57a695d8573
|
| | | | |
| | | | |
| | | | |
| | | | | |
Change-Id: Ib5e367c88662defc0471a0487a576bb4b750b778
|
| | | | |
| | | | |
| | | | |
| | | | | |
Change-Id: I9a3f558ff578266a34f45ebf3026c7a093dd6f3c
|
| | | | |
| | | | |
| | | | |
| | | | | |
Change-Id: Id0e61babb768d29d6317cc216eeaa5054e5fc869
|
| | | | |
| | | | |
| | | | |
| | | | | |
Change-Id: I00c63c928ad64a447ad101e01508d917de26bd71
|
| | | | |
| | | | |
| | | | |
| | | | | |
Change-Id: Ideb32d24c78aa8f42546d9098991257ab6f205c4
|
| | | | |
| | | | |
| | | | |
| | | | | |
Change-Id: Ie0b39e0c41bf2827af5f6282ea33ebd21afd47f6
|
| | | | |
| | | | |
| | | | |
| | | | | |
Change-Id: Ide7f67345fa9a63da16562eed76ca5b2a88b8f8a
|
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
We are moving away from java.util.Date to java.time APIs.
Change-Id: Ifad3fce57f4a742289a5a687a7cf8776fff6bf1c
|
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
We are moving away from the old java.util.Date API to the
java.time API.
Change-Id: I6d2ff9d0dfb81ca8385f8776e3fa73e090247b79
|
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
We are moving away from the old java.util.Date API to the
java.time API.
Change-Id: Ie645d7bf4e958f6602ec106e8c2296d675f62904
|
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
We are moving away from the old java.util.Date API to the
java.time API.
Change-Id: Iffcb6ff709cbc101e0700520b8312328ff70b2eb
|
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
We are moving away from the old java.util.Date API to the
java.time API.
Add GitTimeParser#parseInstant to support this.
Change-Id: I3baeafeda5b65421dc94c1045b0ba576d4f79662
|
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
We are moving away from the old java.util.Date API to the
java.time API.
Change-Id: I44947d26086396b0779ce6e1f9b9f30375032388
|
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
We are moving away of java.util.Date to the newers java.time
API. PersonIdent has deprecated old constructors with long/int for
time and tz and provides alternatives with Instant/ZoneId.
Use the new constructors in PersonIdent.
Change-Id: Ibb32f70818f44fdcc6875e6e706c4c56f85bbabd
|
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
Errorprone suggest to use the more modern java.time.Instant instead of
the older Date API.
Offer a variant of RelativeDateFormatter#format method for Instants.
Change-Id: I536230327ec7b617958191fbe36f98b1294f6d2e
|
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
Deprecate the methods using Date and offer the equivalent as Instant.
Keep an int with seconds as internal representation, as it seems more
efficient to compare than Instant.before/after.
Change-Id: Ie751ab5661c7dafaab58a16c219143b78092f84a
|
|\ \ \ \ \ |
|
| |\ \ \ \ \
| | |/ / / /
| |/| / / /
| | |/ / /
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
* stable-7.1:
FileSnapshot: fix warnings
Optionally.Hard: avoid Optional creation on every use,
Pack: fix threading bug getting idx
Fix potential NPE in TreeWalk#getFilterCommandDefinition
Advertise "agent" capability when using protocol v2
FileSnapshot: silence "Stale file handle" exceptions
Change-Id: I772dd3b3ce7f27e33c1879ce21ec024cc2f9c52a
|
| | |\| |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
* stable-7.0:
FileSnapshot: fix warnings
Optionally.Hard: avoid Optional creation on every use,
Pack: fix threading bug getting idx
Fix potential NPE in TreeWalk#getFilterCommandDefinition
Advertise "agent" capability when using protocol v2
FileSnapshot: silence "Stale file handle" exceptions
Change-Id: I4fdea7450f27eebfa7ae08002fd51e67b58bf6bb
|
| | | |\|
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
* stable-6.10:
FileSnapshot: fix warnings
Optionally.Hard: avoid Optional creation on every use,
Pack: fix threading bug getting idx
Fix potential NPE in TreeWalk#getFilterCommandDefinition
Advertise "agent" capability when using protocol v2
FileSnapshot: silence "Stale file handle" exceptions
Change-Id: Ibe8bf9ad43cb1e56a5a5e4f4d9d5818334b2550a
|
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
The "agent" capability was not advertised by the server when executing
git-upload-pack over protocol v2.
This, in turn, prevented the clients from advertising its client agent
too, as documented [1]:
"The client may optionally send its own agent string by including the
agent capability with a value Y (in the form agent=Y) in its request to
the server (but it MUST NOT do so if the server did not advertise the
agent capability)."
When using jgit with Gerrit this had the effect of preventing the
logging of the git client agent in the sshd_log.
[1] https://git-scm.com/docs/protocol-v2#_agent
Bug: jgit-118
Change-Id: Ifb6ea65fde020425920338f7dd9cc683fed6a4a4
|