Using Windows 7, 64 bit - Java 8, 111 - LibreOffice 5.2.2.2 - BASE does not work with this latest version of Java though the same version of Java does work with LibreOfficeBase 5.1.5.2 portable - Previous version of Java did work with LO 5.2.2.2
I wonder if this incompatibility between latest LibO and latest Java is a LibO bug or a Java bug.
@dheif : have you tried installing a 64bit JDK instead of a JRE ? Setting to NEEDINFO, please set back to UNCONFIRMED once you have tried with a 64bit JDK
Created attachment 128276 [details] SolarMutex not locked assertion error Reproduced with 5.2.2.2 and 5.3 master build / Windows 7. Both LO and Java 8u112 are 32-bit. Java appears in Options - LibreOffice - Advanced, but when a database is opened, and Tables view is selected, Base gives an error that JRE needs to be installed. A possibly different issue: In 5.3 master debug build, opening a database results in a "SolarMutex not locked" assertion error (see attached image).
status NEW since confirmation in comment 3
If there's a regression, it's not on LO's side, handling Java update version numbers > 99 has only been fixed a few months ago (see "depends on" bug report).
The assertion failed error is unrelated, and now has its own bug report: bug 103515.
Weird things are happening in jfw_findAndSelectJRE(...) (jvmfwk\source\framework.cxx). So it goes through the vendors defined in javavendors.xml, and gets info for the installed Java version that's from that specific vendor: http://opengrok.libreoffice.org/xref/core/jvmfwk/plugins/sunmajor/pluginlib/sunjavaplugin.cxx#323 In my case it finds two entries for vendor "Sun Microsystems Inc." (JDK+JRE), but the vendor in the returned info says "Oracle Corporation", so they're thrown away. Then in the next iteration, when Java installations are queried for vendor "Oracle Corporation", nothing is returned.
@Stephan : any idea ?
(In reply to dheif from comment #0) > - BASE does not work with this latest version of Java though the same > version of Java does work with LibreOfficeBase 5.1.5.2 portable what is the exact problem? (In reply to Aron Budea from comment #3) > Java appears in Options - LibreOffice - Advanced, but when a database is > opened, and Tables view is selected, Base gives an error that JRE needs to > be installed. If you then go to the Advanced options page and select one of the listed Java installations (assuming none was previously selected), does Base work afterwards?
Created attachment 128293 [details] View of JDK installed screen I don't have the foggiest idea as to why the JDK installation shows up twice.
(In reply to Alex Thurgood from comment #2) > @dheif : have you tried installing a 64bit JDK instead of a JRE ? > > Setting to NEEDINFO, please set back to UNCONFIRMED once you have tried with > a 64bit JDK Hello Alex, After installing JDK 64 bit, version 8 111, LOBase 5.2.2.2 worked though it did NOT work with JRE 32 bit(same version). The JRE 32 bit(same version) DID work with LOBase 5.1.5 (portable). I have an attachment located in the queue (I don't know how to keep it with this reply) which shows that the JDK version shows up twice when checked via tools, options, advanced, Java Options. It shows up as version 1.8.0_111. Hope this information helps in tracking down the problem.
Dheif, you see two Java installations because you have JDK and JRE installed, and each has its runtime environment. This is not an issue. Stephan: Indeed, I checked now, and could get Java 8u112 to work after selecting Java, probably restart was needed. I didn't test in detail, but went back to 8u92 to test wit that. Results with 8u92 (all in Windows 7, with cleared profile): -5.2.0.4, 5.2.2.2, 5.3 alpha1: After opening a database and switching to Tables view, there's the error: "LibreOffice requires a Java runtime environment (JRE) to perform this task. The selected JRE is defective. Please select another version or install a new JRE and select it under Tools - Options - LibreOffice - Advanced." (then another that connection to the data source could not be established) Upon second start there's no error when opening a database. Even if the first start was only the Start Center and nothing Base-related, there's no error upon second start. -5.1.5.2: No error message upon opening a database with a clean profile. Debugging revealed that for this Java version (8u92) on the first attempt jfw_startVM(...) call returns with JFW_E_VM_CREATION_FAILED: http://opengrok.libreoffice.org/xref/core/stoc/source/javavm/javavm.cxx#758 So this issue seems to be different than with the newer Java version (code doesn't even go to the same place in sunjavaplugin.cxx as in the other case). It's also a regression. Priority is low. Next step: upgrade to Java 8u112 again, and test in detail with that.
With Java 8u112 the error doesn't go away with a restart, but indeed goes away if a Java version is selected in Java Options (which doesn't happen automatically, while it does with 8u92). The message in this case: "LibreOfficeDev requires a Java runtime environment (JRE) to perform this task. Please install a JRE and restart LibreOfficeDev." Issue goes back to 5.0.0.5, while JRE is automatically selected in 4.4.0.3, so indeed this is a regression (and bug 101057 didn't affect all OSes). Since, though it has to be selected manually (the warning message is confusing), Java ultimately seems to work, reducing importance. Dheif: LibreOffice and JRE/JDK has to be either both 64-bit or 32-bit. If they are mixed 64/32-bit, then LibreOffice won't see Java, that is normal.
(In reply to dheif from comment #11) > After installing JDK 64 bit, version 8 111, LOBase 5.2.2.2 worked though it > did NOT work with JRE 32 bit(same version). The JRE 32 bit(same version) DID > work with LOBase 5.1.5 (portable). The (32 vs. 64) bit-ness of LO and Java need to match, see bug 37089.
(In reply to Aron Budea from comment #13) > Issue goes back to 5.0.0.5, while JRE is automatically selected in 4.4.0.3, > so indeed this is a regression (and bug 101057 didn't affect all OSes). You mean, starting each time with a fresh UserInstall, LO 5.0.0.5 and later do not automatically select 8u112, and LO 4.4.0.3 does? (That would confuse me, as my understanding is that, while it did't necessarily lead to crashes on all platforms, bug 101057 meant that LO did't detect Java versions with a three-digit update number (as in "8u112") on any platform, and that bug fix wasn't backported to anything prior to LO 5.1.5.)
(In reply to Stephan Bergmann from comment #15) > You mean, starting each time with a fresh UserInstall, LO 5.0.0.5 and later > do not automatically select 8u112, and LO 4.4.0.3 does? Yes, exactly. It seems bug 101057 doesn't cause any issues in this case, the cause is something else.
(In reply to Aron Budea from comment #16) > (In reply to Stephan Bergmann from comment #15) > > You mean, starting each time with a fresh UserInstall, LO 5.0.0.5 and later > > do not automatically select 8u112, and LO 4.4.0.3 does? > > Yes, exactly. > It seems bug 101057 doesn't cause any issues in this case, the cause is > something else. Indeed, I had misinterpreted effects of bug 101057. The cause for this bug is <https://cgit.freedesktop.org/libreoffice/core/commit/?id=5e9a2e9b0f33ab50aa3a84728db75383aede19d9> "Check each potential JRE location only once" (which first appeared in LO 5.0.0).
Stephan Bergmann committed a patch related to this issue. It has been pushed to "master": http://cgit.freedesktop.org/libreoffice/core/commit/?id=36f637f7f21906fa3f37223e69b044db52036fb1 tdf#103507 quickfix: Automatic selection of Oracle Java runtime on Windows It will be available in 5.3.0. The patch should be included in the daily builds available at http://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More information about daily builds can be found at: http://wiki.documentfoundation.org/Testing_Daily_Builds Affected users are encouraged to test the fix and report feedback.
...though I have no idea why this issue should be specific to "u111/112", and not also hit with older Oracle Java runtimes
...oh, and thanks for the excellent analysis, Aron :)
Stephan Bergmann committed a patch related to this issue. It has been pushed to "libreoffice-5-2-3": http://cgit.freedesktop.org/libreoffice/core/commit/?id=fe5d367fae1323416e03d1b618ba2af64e237e8c&h=libreoffice-5-2-3 tdf#103507 quickfix: Automatic selection of Oracle Java runtime on Windows It will be available in 5.2.3. The patch should be included in the daily builds available at http://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More information about daily builds can be found at: http://wiki.documentfoundation.org/Testing_Daily_Builds Affected users are encouraged to test the fix and report feedback.
Stephan Bergmann committed a patch related to this issue. It has been pushed to "libreoffice-5-2": http://cgit.freedesktop.org/libreoffice/core/commit/?id=541febffd9d6f367e23081a1f0d095f232325014&h=libreoffice-5-2 tdf#103507 quickfix: Automatic selection of Oracle Java runtime on Windows It will be available in 5.2.4. The patch should be included in the daily builds available at http://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More information about daily builds can be found at: http://wiki.documentfoundation.org/Testing_Daily_Builds Affected users are encouraged to test the fix and report feedback.
Thanks for the fix, Stephan. I tested and verified it working in 5.2.3.3 x86 / Java 8u112 x86 / Windows 7. Now the fix brought forth the issue described in comment 12, for which I opened bug 103570, but that's really a low/trivial category bug, as it only comes up after the very first opening of a database table with an empty profile (or where Java hasn't been initialized, yet). Dheif, if you think there's still an independent issue related to Base and Java, please open another bug report on it.
(turns out macOS had the same issue; to be addressed for LO 5.2.4 with <https://gerrit.libreoffice.org/#/c/30475/> "quickfix: Automatic selection of Oracle Java runtime on macOS")