On Wed, 8 Oct 2025 02:58:37 GMT, Alexey Semenyuk <[email protected]> wrote:
>> I just fix it. Let me know what you think. I can revert my last commit. > > It fixes one specific issue that just popped up. There may be more, but > jpackage tests don't trap "null"-s in log messages emitted by > OverridableResource. > > The change to OverridableResource is wrong for a few reasons: > - It unconditionally writes a log message; log messages in > OverridableResource are created only when the destination file or output > stream is not `null`. This change contradicts logging in OverridableResource. > - It assumes that the set of resource sources is fixed. This assumption is > wrong. It is possible to configure the order and the set of resource sources, > see `OverridableResource.setSourceOrder()`. The log: [23:04:58.315] Building PKG package for SimplePackageTest. [23:04:58.364] No default package resource postinstall [PKG postinstall script] (add postinstall to the resource-dir to customize). [23:04:58.364] No default package resource preinstall [PKG preinstall script] (add preinstall to the resource-dir to customize). [23:04:58.400] Using default package resource background_pkg.png [pkg background image] (add SimplePackageTest-background.png to the resource-dir to customize). [23:04:58.401] Using default package resource background_pkg.png [pkg background image] (add SimplePackageTest-background-darkAqua.png to the resource-dir to customize). [23:04:58.403] Using default package resource ApplicationRuntime-Info.plist.template [Embedded Java Runtime Info.plist] (add Runtime-Info.plist to the resource-dir to customize). [23:04:58.407] Using default package resource JavaApp.icns [icon] (add SimplePackageTest.icns to the resource-dir to customize). [23:04:58.413] Preparing Info.plist: /var/folders/sp/mfz276114fq67h52dbd7vhb80000gn/T/jdk.jpackage2112168794503985414/image/SimplePackageTest.app/Contents/Info.plist. [23:04:58.417] Using default package resource Info-lite.plist.template [Application Info.plist] (add Info.plist to the resource-dir to customize). ... [23:04:58.620] Preparing distribution.dist: /var/folders/sp/mfz276114fq67h52dbd7vhb80000gn/T/jdk.jpackage2112168794503985414/config/distribution.dist. [23:04:58.630] No default package resource postinstall [PKG postinstall script] (add postinstall to the resource-dir to customize). [23:04:58.630] No default package resource preinstall [PKG preinstall script] (add preinstall to the resource-dir to customize). [23:04:58.633] No default package resource postinstall [PKG postinstall script] (add postinstall to the resource-dir to customize). [23:04:58.634] No default package resource preinstall [PKG preinstall script] (add preinstall to the resource-dir to customize). ... [23:04:58.836] No default package resource SimplePackageTest-post-image.sh [script to run after application image is populated] (add SimplePackageTest-post-image.sh to the resource-dir to customize). [23:04:58.837] No default package resource postinstall [PKG postinstall script] (add postinstall to the resource-dir to customize). [23:04:58.837] No default package resource preinstall [PKG preinstall script] (add preinstall to the resource-dir to customize). ... [23:04:58.912] No default package resource postinstall [PKG postinstall script] (add postinstall to the resource-dir to customize). [23:04:58.912] No default package resource preinstall [PKG preinstall script] (add preinstall to the resource-dir to customize). Zillion or duplicated log messages. Can you see them? ------------- PR Review Comment: https://git.openjdk.org/jdk/pull/25510#discussion_r2412390541
