Paul Krill
Editor at Large

Gradle 6.5 adds file system watching to improve build times

news
Jun 8, 20202 mins

Update to JVM-based build tool also features improved version dependency ordering

tools to build, develop or repair
Credit: phaisam2517 / Getty Images

Gradle 6.5, the latest version of the popular JVM-based build management tool, has been introduced with an experimental file system watching capability designed to improve build times.

With the opt-in file system watching enabled, Gradle 6.5 can keep what it has learned about the file system in memory between builds rather than polling the system on each build. This optimization substantially reduces the disk I/O necessary to determine changes since the previous build. Users can enable file system watching by using the parameter, --watch-fs on the command line.

File system watching will be enabled by default in a future Gradle release. The feature currently has some limitations including a lack of performance benefits for locations with symlinks and a lack of support for SUBST and network drives on Windows.

To switch to Gradle 6.5, developers can update their wrapper:

./gradlew wrapper --gradle-version=6.5

Other new capabilities in Gradle 6.5 include:

  • Improved version dependency ordering, addressing issues such as an algorithm that can lead to potentially confusing results. The improvement is an opt-in feature.
  • A security fix for CVE-2020-13165, which has impacted signed artifacts.
  • Documentation improvements, with samples covering use cases such as safely using credentials in a build and developing local changes in two independent projects with a composite build.
  • For plug-in authors, Gradle now supports using org.gradle.api.Provider when adding dependencies, which is useful for supplying different dependencies based on user-provided configuration.
  • For tool providers, IDEs now can use a new method from GradleConnector to asynchronously shut down Gradle daemons so they do not continue to use memory and other resources.

Gradle is perhaps best known as the official build tool for Android mobile applications, but it is a general purpose build tool that be used for projects based on JVM languages such as Java and Kotlin or non-JVM languages such as C++, Python, and Swift.

Paul Krill

Paul Krill is editor at large at InfoWorld. Paul has been covering computer technology as a news and feature reporter for more than 35 years, including 30 years at InfoWorld. He has specialized in coverage of software development tools and technologies since the 1990s, and he continues to lead InfoWorld’s news coverage of software development platforms including Java and .NET and programming languages including JavaScript, TypeScript, PHP, Python, Ruby, Rust, and Go. Long trusted as a reporter who prioritizes accuracy, integrity, and the best interests of readers, Paul is sought out by technology companies and industry organizations who want to reach InfoWorld’s audience of software developers and other information technology professionals. Paul has won a “Best Technology News Coverage” award from IDG.

More from this author