Some more background information on my environment:
I am currently running on Windows 10 and have Oracle JDK 8 installed as well as OpenJDK 11, 13 and 15
I haven't even started to look at Linux or osx yet (both of we we need to eventually support)
So, after a bit more digging, I see that JDKPathPanelHelper is using "Software\\JavaSoft\\Java Development Kit"
as a JDK_ROOT_KEY, this seems a bit dangerous/hit and miss as this is registry entry appears to be Oracle only,
none of my OpenJDK installations have attempted to set this registry entry (I see in the code that something
similar may be done for OSX!).
I suspect this to be the root cause of my problem as although my installer is running under JDK 11, because this
registry entry is set to JDK 8 the installation doesn't think that I am running the correct java version!
Would using system properties work instead (I haven't tested this) but, is something like jdk.module.main only
available if running with a JDK? I realise this only works for the running instance, but maybe running a quick
simple short java program via the java image in the selected JDK directory may achieve the same or a similar
result.
Finally, the JDKPathPanel has a field for the location of the JDK, by default, this gets populated with what looks
like to location of the installer jar, this may be better if populated with the value of the java.home system property
which whilst most likely incorrect may well be in a closer location to the desired JDK than the installers folder.