Skip to main content
summaryrefslogtreecommitdiffstats
AgeCommit message (Collapse)AuthorFilesLines
2019-08-08Merge branch 'stable-5.1' into stable-5.2Matthias Sohn1-1/+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>
2019-08-06Persist minimal racy threshold and allow manual configurationMatthias Sohn1-1/+1
To enable persisting the minimal racy threshold per FileStore add a new config option to the user global git configuration: - Config section is "filesystem" - Config subsection is concatenation of - Java vendor (system property "java.vendor") - Java version (system property "java.version") - FileStore's name, on Windows we use the attribute volume:vsn instead since the name is not necessarily unique. - separated by '|' e.g. "AdoptOpenJDK|1.8.0_212-b03|/dev/disk1s1" The same prefix is used as for filesystem timestamp resolution, so both values are stored in the same config section - The config key for minmal racy threshold is "minRacyThreshold" as a time value, supported time units are those supported by DefaultTypedConfigGetter#getTimeUnit - measure for 3 seconds to limit runtime which depends on hardware, OS and Java version being used If the minimal racy threshold is configured for a given FileStore the configured value is used instead of measuring it. When the minimal racy threshold was measured it is persisted in the user global git configuration. Rename FileStoreAttributeCache to FileStoreAttributes since this class is now declared public in order to enable exposing all attributes in one object. Example: [filesystem "AdoptOpenJDK|11.0.3|/dev/disk1s1"] timestampResolution = 7000 nanoseconds minRacyThreshold = 3440 microseconds Change-Id: I22195e488453aae8d011b0a8e3276fe3d99deaea Signed-off-by: Matthias Sohn <matthias.sohn@sap.com> Also-By: Marc Strapetz <marc.strapetz@syntevo.com>
2019-08-06Measure minimum racy interval to auto-configure FileSnapshotMatthias Sohn1-1/+1
By running FileSnapshotTest#detectFileModified we found that the sum of measured filesystem timestamp resolution and measured clock resolution may yield a too small interval after a file has been modified which we need to consider racily clean. In our tests we didn't find this behavior on all systems we tested on, e.g. on MacOS using APFS and Java 8 and 11 this effect was not observed. On Linux (SLES 15, kernel 4.12.14-150.22-default) we collected the following test results using Java 8 and 11: In 23-98% of 10000 test runs (depending on filesystem type and Java version) the test failed, which means the effective interval which needs to be considered racily clean after a file was modified is larger than the measured file timestamp resolution. "delta" is the observed interval after a file has been modified but FileSnapshot did not yet detect the modification: "resolution" is the measured sum of file timestamp resolution and clock resolution seen in Java. Java version filesystem failures resolution min delta max delta 1.8.0_212-b04 btrfs 98.6% 1 ms 3.6 ms 6.6 ms 1.8.0_212-b04 ext4 82.6% 3 ms 1.1 ms 4.1 ms 1.8.0_212-b04 xfs 23.8% 4 ms 3.7 ms 3.9 ms 1.8.0_212-b04 zfs 23.1% 3 ms 4.8 ms 5.0 ms 11.0.3+7 btrfs 98.1% 3 us 0.7 ms 4.7 ms 11.0.3+7 ext4 98.1% 6 us 0.7 ms 4.7 ms 11.0.3+7 xfs 98.5% 7 us 0.1 ms 8.0 ms 11.0.3+7 zfs 98.4% 7 us 0.7 ms 5.2 ms Mac OS 1.8.0_212 APFS 0% 1 s 11.0.3+7 APFS 0% 6 us The observed delta is not distributed according to a normal gaussian distribution but rather random in the observed range between "min delta" and "max delta". Run this test after measuring file timestamp resolution in FS.FileAttributeCache to auto-configure JGit since it's unclear what mechanism is causing this effect. In FileSnapshot#isRacyClean use the maximum of the measured timestamp resolution and the measured "delta" as explained above to decide if a given FileSnapshot is to be considered racily clean. Add a 30% safety margin to ensure we are on the safe side. Change-Id: I1c8bb59f6486f174b7bbdc63072777ddbe06694d Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
2019-07-19Measure filesystem timestamp resolution already in test setupMatthias Sohn1-1/+2
This helps to avoid some time critical tests can't prepare the test fixture intended since measuring timestamp resolution takes time. Change-Id: Ib34023e682a106070ca97e98ef16789a4dfb97b4 Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
2019-06-05Prepare 5.1.9-SNAPSHOT buildsMatthias Sohn2-6/+6
Change-Id: I60571e4e0bea04bb2c25ef3d0332a9ab6895db06 Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
2019-06-05JGit v5.1.8.201906050907-rv5.1.8.201906050907-rMatthias Sohn2-2/+2
Change-Id: Iae0ffe161df2ca8a800d21688d6b7d7419dfb640 Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
2019-05-29Tune max heap size for testsMatthias Sohn1-1/+1
This is an attempt to fix crashes observed on the new Jenkins infrastructure running on Kubernetes [1]. Increase it to 512m for - org.eclipse.jgit.ant.test - org.eclipse.jgit.http.test - org.eclipse.jgit.lfs.server.test - org.eclipse.jgit.lfs.test - org.eclipse.jgit.pgm.test Decrease it to 768m for - org.eclipse.jgit.test [1] e.g. https://ci-staging.eclipse.org/jgit/job/stable/job/jgit.gerrit/16074/console Change-Id: Id074ed0f7bcb8a13da649a547342af2a08439d9f Signed-off-by: Matthias Sohn <matthias.sohn@sap.com> (cherry picked from commit e19e859977525c2a39aaa928dfdef20e5fab7e3c)
2019-04-23Prepare 5.2.3-SNAPSHOT buildsMatthias Sohn2-6/+6
Change-Id: I6ae3db901d986467128326073d4ba70406ae8385 Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
2019-04-23JGit v5.2.2.201904231744-rv5.2.2.201904231744-rMatthias Sohn2-2/+2
Change-Id: I4ed2aff28bff702a8c1b42814acb04c7ef9025a7 Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
2019-04-20Prepare 5.1.8-SNAPSHOT buildsMatthias Sohn2-6/+6
Change-Id: I331bbaefd42ef94673ae8565c9b2b3af9eadfda0 Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
2019-04-20JGit v5.1.7.201904200442-rv5.1.7.201904200442-rMatthias Sohn2-2/+2
Change-Id: Ifaa3a88c5e117912a8c691b8b8369dd9a17faebb Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
2019-03-13Prepare 5.1.7-SNAPSHOT buildsMatthias Sohn2-6/+6
Change-Id: Ica716b2ad18f8390e75466430ef81c86ea06f004 Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
2019-03-13JGit v5.1.6.201903130242-rv5.1.6.201903130242-rMatthias Sohn2-2/+2
Change-Id: Iaf5e451f72dc8512afee99a9f3fb91aa348e3cf5 Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
2018-12-27Prepare 5.2.2-SNAPSHOT buildsMatthias Sohn2-6/+6
Change-Id: I9487f6a59ed684ad13bcfbff7d6c730ae4f37030 Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
2018-12-27JGit v5.2.1.201812262042-rv5.2.1.201812262042-rMatthias Sohn2-2/+2
Change-Id: Idfefc54e898f364407a931b787a26db2489b031c Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
2018-12-27Prepare 5.1.6-SNAPSHOT buildsMatthias Sohn2-6/+6
Change-Id: If3313d602aa57cfa031ba2c9ec03bd51b464dc19 Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
2018-12-27JGit v5.1.5.201812261915-rv5.1.5.201812261915-rMatthias Sohn2-2/+2
Change-Id: I249a440d1ca1c997343da942ae55fcb27a645b92 Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
2018-12-25Prepare 5.1.5-SNAPSHOT buildsMatthias Sohn2-6/+6
Change-Id: I3eeb24b01a4f955e7e933238defb42635ebfec7d Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
2018-12-25JGit v5.1.4.201812251853-rv5.1.4.201812251853-rMatthias Sohn2-2/+2
Change-Id: I30ba167bcd8144074553d7446a45fa6be19584fe Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
2018-12-07Prepare 5.2.1-SNAPSHOT buildsMatthias Sohn2-6/+6
Change-Id: I68d9f5b1c8ca8e8eada9143093dc4fa82519edd8 Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
2018-12-06JGit v5.2.0.201812061821-rv5.2.0.201812061821-rMatthias Sohn2-2/+2
Change-Id: I8528c913ad1a820ee9a2fa6be1c9125b518caefe Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
2018-11-30Prepare 5.2.0-SNAPSHOT buildsMatthias Sohn2-2/+2
Change-Id: I18646aaeee51047b234b758dcc1c2f89fd01b2f8 Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
2018-11-28JGit v5.2.0.201811281532-m3v5.2.0.201811281532-m3Matthias Sohn2-2/+2
Change-Id: I79988b473d67e565d8f6bcac40ee9a14b26c9e60 Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
2018-10-20Prepare 5.1.4-SNAPSHOT buildsMatthias Sohn2-6/+6
Change-Id: Iee86860f3b4eb9f4af818c60342fd29465c0474c Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
2018-10-20JGit v5.1.3.201810200350-rv5.1.3.201810200350-rMatthias Sohn2-2/+2
Change-Id: Ib2c5a79d4fdf77680b7b65652fc3659527df27ad Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
2018-10-17Configure classpath for separate test sources in EclipseMichael Keppler1-1/+5
Eclipse Photon supports separating sources and test sources. There are no functional changes in the IDE, except for test source folders having a different icon color. Users of different IDEs than Eclipse are not affected, since the attribute on the classpath entries will be ignored by their IDE. Bug: 539933 Change-Id: Iac6dcdf0c0730ca775bae90df6a685303dc95380 Signed-off-by: Michael Keppler <Michael.Keppler@gmx.de> Signed-off-by: David Pursehouse <david.pursehouse@gmail.com>
2018-10-17Disable Eclipse warning about unrecognized @SuppressWarnings valueDavid Pursehouse1-1/+1
The code base has several @SuppressWarnings annotations to suppress warnings raised by Error Prone, but those are not recognized by Eclipse and there is currently no way to tell it about them [1]. Suppress them for now. [1] https://bugs.eclipse.org/bugs/show_bug.cgi?id=392045 Change-Id: I3de7cfa8ad4370ca5be71e1303879c73ab6829c1 Signed-off-by: David Pursehouse <david.pursehouse@gmail.com>
2018-10-06Prepare 5.1.3-SNAPSHOT buildsMatthias Sohn2-6/+6
Change-Id: I75c1a01885115fc709ab37f181234264c3f7423a Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
2018-10-06JGit v5.1.2.201810061102-rv5.1.2.201810061102-rMatthias Sohn2-2/+2
Change-Id: Id34e4ae12a796460862edc37c5eb072314199bf4 Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
2018-09-23Fix Mylyn commit message templateMichael Keppler1-1/+1
The commit message template contains a superfluous blank at the end of the first line, which is deleted by this change. This is only relevant for jgit contributors using Eclipse, not for jgit users. Change-Id: I462deb49c26fb64b3dc2d1d75f1e40ef302b0fc9 Signed-off-by: Michael Keppler <Michael.Keppler@gmx.de>
2018-09-18Prepare 5.1.2-SNAPSHOT buildsMatthias Sohn2-6/+6
Change-Id: I095d246e27de747a234bc058725454c222be51ce Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
2018-09-18JGit v5.1.1.201809181055-rv5.1.1.201809181055-rMatthias Sohn2-2/+2
Change-Id: I2366444fca125139eadb6d513be721167a266d70 Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
2018-09-11Prepare 5.1.1-SNAPSHOT buildsMatthias Sohn2-6/+6
Change-Id: Ie220dd95fae18f894e2a04a5ae6d29a1e5a6d76b Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
2018-09-11JGit v5.1.0.201809111528-rv5.1.0.201809111528-rMatthias Sohn2-2/+2
Change-Id: I583bf7d60bccc876156be1f605bfda32b89cd08b Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
2018-09-06Prepare 5.2.0-SNAPSHOT buildsMatthias Sohn2-6/+6
Change-Id: If8e8ca20e745901a5e0239c16cb4acc7934b4ec8 Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
2018-09-05Prepare 5.1.0-SNAPSHOT buildsMatthias Sohn2-2/+2
Change-Id: I3d06c5237edae54b09f465f415f5a308b5e7ceff Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
2018-09-05JGit v5.1.0.201809051400-rc1v5.1.0.201809051400-rc1Matthias Sohn2-2/+2
Change-Id: I0b53f95ee51d94da8b029c9bb10eb854ff9dd4f6 Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
2018-08-29Prepare 5.1.0-SNAPSHOT buildsMatthias Sohn2-2/+2
Change-Id: If57fcce14f5ba3ef2a2602515e2f89b8f22a742b Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
2018-08-28JGit v5.1.0.201808281540-m3v5.1.0.201808281540-m3Matthias Sohn2-2/+2
Change-Id: Ie86c46a828b55a2235056b9a5bc2c6c450b95ed0 Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
2018-05-23Prepare 5.1.0-SNAPSHOT buildsMatthias Sohn2-6/+6
Change-Id: I8523a993ae1f7b62573d7547273bc1356bf64fa7 Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
2018-03-08Prepare 5.0.0-SNAPSHOT buildsMatthias Sohn2-6/+6
Change-Id: I2d2f50ed8a12f310e7cac68eed5536bd460c403f Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
2018-03-08Prepare 4.11.1-SNAPSHOT buildsMatthias Sohn2-6/+6
Change-Id: Id9aa6b7e8f56de5183b6cd57ef0e790ec9debd4d Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
2018-03-08JGit v4.11.0.201803080745-rv4.11.0.201803080745-rMatthias Sohn2-2/+2
Change-Id: Ie24a33bc8a24c30db06fe7b175f405efb95776ec Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
2018-03-03Enable warning for resources not managed by try-with-resourceDavid Pursehouse1-1/+1
Change-Id: Iefe97de6bdb62af558f1b0e77c9205a9186f9b4c Signed-off-by: David Pursehouse <david.pursehouse@gmail.com>
2017-12-31Prepare 4.11.0-SNAPSHOT buildsMatthias Sohn2-6/+6
Change-Id: I5d5e2befcf530d93457d44684bd9e4fc2392e5eb Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
2017-12-23Add header Automatic-Module-Name for Java 9Karsten Thoms1-0/+1
Bug: 529075 Change-Id: I4532ce2c80eb91531d46026676502d636ccda706 Signed-off-by: Karsten Thoms <karsten.thoms@itemis.de> Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
2017-12-08Specify consistent version range for junit in OSGi manifestsDavid Pursehouse1-1/+1
There are several different version ranges specified in the various manifest files. Align them all to the same range: [4.12,5.0.0) Change-Id: I02205b8b8546c9f53ed431b5fd9abf6ddcda4423 Signed-off-by: David Pursehouse <david.pursehouse@gmail.com>
2017-11-24Merge branch 'stable-4.9'Matthias Sohn1-1/+11
* stable-4.9: Ignore warning for minor version change without API change Silence boxing warning Prepare 4.5.5-SNAPSHOT builds JGit v4.5.4.201711221230-r Fix LockFile semantics when running on NFS Honor trustFolderStats also when reading packed-refs Prepare 4.5.4-SNAPSHOT builds JGit v4.5.3.201708160445-r Change-Id: Icc33d2e36f140e8714fce088379673a8834ae9de
2017-11-24Ignore warning for minor version change without API changeMatthias Sohn1-1/+11
- this is a new warning option in Eclipse 4.7 and higher - we always change version of all bundles in a release to keep release engineering simple Change-Id: Ic7523d77b67b2802f1bab3bc70af250d712a034f Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
2017-10-08Prepare 4.10.0-SNAPSHOT buildsMatthias Sohn2-6/+6
Change-Id: I5ca462d1db18a2c5c9382cfb9c83972510fa2b88 Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>

Back to the top