RFR: 8287971: Throw exception for missing values in .jpackage.xml
Alexey Semenyuk
asemenyuk at openjdk.java.net
Tue Jun 14 18:31:37 UTC 2022
On Mon, 13 Jun 2022 17:01:48 GMT, Alexander Matveev <almatvee at openjdk.org> wrote:
> - Error will be thrown if app image is generated with another JDK version or has malformed .jpackage.xml.
> - Re-fixed as Alexey suggested in https://github.com/openjdk/jdk/pull/9098.
test/jdk/tools/jpackage/helpers/jdk/jpackage/test/TKit.java line 272:
> 270: ));
> 271: }
> 272:
1. This is jpackage specific, so it should belong to JPackageCommand class.
2. Please use proper XML API to create XML output.
3. Having `<app-version>1.0</app-version>` in .jpackage.xml file will make `AppImageFile.isValid()` return `false` and `AppImageFile.load()` to throw exception. This seems to be equivalent to not having .jpackage.xml file in app image at all raising a question if this new function is needed at all.
-------------
PR: https://git.openjdk.org/jdk19/pull/9
More information about the core-libs-dev
mailing list