3 Replies Latest reply on Nov 12, 2019 8:54 PM by thatJeffSmith-Oracle

    A Tale: SQL Developer 19.2 on Ubuntu 18.04 with OpenJDK 11 and OpenJFX 11

    Mark Williams

      tl;dr – SQL Developer 19.2 ships with JFX files and there may be a conflict if (possibly) older JFX files are already installed on the system.

       

      Apologies if this is covered somewhere else already... my searching didn't find it if so.

       

      As part of a recent exercise wherein I wanted to explore using Ubuntu 18.04 LTS on my desktop I ran into some issues with SQL Developer 19.2 and JFX.

       

      This manifested itself primarily in the Welcome page appearing completely blank and no errors being reported.

       

      Some key items:

       

      • SQL Developer 19.2.0.206.2117 (yes, I know there is a slightly newer release as of today but I was lazy and did not test, nor did I test older version)

       

      • Ubuntu 18.04 Long Term Support on bare metal machine (i.e., not a VM).

       

      • Used the Synaptic Package Manager for the package installations.

       

      • Installed OpenJDK (version 11) packages:

      openjdk-11-jdk

      openjdk-11-jdk-headless

      openjdk-11-jre

      openjdk-11-jre-headless

       

      • Installed OpenJFX (version 11) packages:

      libopenjfx-java

      libopenjfx-jni

      openjfx

      openjfx-source

       

      After installing what I thought were the needed packages (especially OpenJFX since JFX is no longer part of the JDK) I executed sqldeveloper.sh from the location where I had unzipped it. When the Welcome page displayed it was completely blank. No errors were reported – just a big white blob of space where the Welcome page content should be.

       

      But, even though it displayed as completely blank, moving the mouse around areas where I knew content to be (such as the recent connections list) caused the mouse to change to the “hover link” pointer. So, I clicked and, ah ha!, a connection and its corresponding worksheet opened. Clearly this was not a case of the Welcome page not being able to open but a case of improper display.

       

      After a bit of messing around I decided to use strace on a session and I could see that the OpenJFX shared libraries were being loaded from the install location from the above installation step (for example, among several):

       

      /usr/lib/x86_64-linux-gnu/jni/libjfxmedia.so

       

      This seemed correct and expected. It is, after all, where portions of the OpenJFX were installed.

       

      After more messing around and head scratching, as a test I removed all of the OpenJFX packages (but not OpenJDK) and started SQL Developer again expecting to see an error dialog related to JFX not being found. To my surprise SQL Developer opened with no errors and the Welcome page was correctly displayed. Huh? That was totally unexpected. I had just removed JFX which is a requirement for the Welcome page.

       

      I then ran another strace session with SQL Developer and I could see in the strace output that SQL Developer had created a new directory:

       

      /home/markwill/.openjfx/cache/12

       

      I've never seen that before. But, not only that, the directory was populated with the various JFX shared libraries.

       

      Some additional investigation revealed that SQL Developer 19.2 now ships with JFX libraries in the following location:

       

      <install location>/sqldeveloper/modules/javafx

       

      As part of the startup process for displaying the Welcome page (and possibly other things too) it appears that SQL Developer now creates this directory underneath the user's home directory and populates it with the required JFX files (if it doesn't already exist).

       

      Given the directory name, it seems that these files are JFX version 12 files, though the SQL Developer release notes indicate JDK 11 is needed. So, it seems possibly suspect that JDK version 11 is needed but JFX version 12 files are shipped. I don't know for certain if that is an issue. I do know that I installed OpenJDK and OpenJFX version 11. Also, it seems that since JDK 12 was not a long term support release that the version 12 JFX files are no longer readily available.

       

      SQL Developer Release Notes (here, as of today, for reference): https://www.oracle.com/technetwork/developer-tools/sql-developer/downloads/sqldev-relnotes-192-5592849.html

       

      What I suspect happened in my initial tests is that since I installed OpenJFX version 11 (as it is the long term support version and matched the OpenJDK version) that there was a run time conflict with the files SQL Developer was expecting (as it ships with and installed under my home directory what appear to be JFX version 12 files – i.e., newer version files).

       

      Has anyone else experienced this sort of issue? Also able to resolve it by removing JFX version 11 files? Have I done something daft here that I missed?

       

      Regards,

      Mark

       

      EDIT1: Fixed a typo and I ran my test on Windows 10 as well. Largely the same behavior. However, two differences:

      • The IndexPreferencesTask doesn't seem to stop.
      • I got the following dialog upon startup:

      • Oracle IDE 19.2.0.206.2117