Add jdk.io.File.enableADS
to list of immutable system properties
#20721
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This commit adds
jdk.io.File.enableADS
to the list of immutable system properties, to enable the propertyto be passed on the command line, rather than set at runtime.
Relates: elastic/logstash#14075
Signed-off-by: Rob Bavey [email protected]
Fixes #?
Context
A recent update to the JDK, present in
11.0.15+10
,17.0.3+7
introduced functionalityto check the validity of Windows file paths, rejecting, for example, paths with a
:
present anywhere other than immediately following the drive letter. Unfortunately, this has the
side effect of throwing exceptions when attempting to write to the
NUL:
device.This validity check is gated behind a property
jdk.io.File.enableADS
, which is set tofalse
for11.0.15+10
,17.0.3+7
releases of the JDK (it will be set totrue
for the next set of JDK releases)This is causing our gradle jobs to fail, as the property is not set when the gradle daemon starts, as the
property is set after the test to determine the value is performed. This will fail for any Windows builds that
use the affected JDKs, and attempt to write to the
NUL:
deviceRelates: elastic/logstash#14075
Contributor Checklist
<subproject>/src/integTest
) to verify changes from a user perspective<subproject>/src/test
) to verify logic./gradlew sanityCheck
./gradlew <changed-subproject>:quickTest
Gradle Core Team Checklist