Trouble with setting up Java modules in Apache NetBeans 20 Flatpak Installation, on Linux Mint 21.3 Virginia #7139
-
Hi there! I installed Apache NetBeans 20 using the Linux Mint MATE software manager. Initially, I created a simple "Hello world" project for testing purposes, and it worked fine. However, when I attempted to open a Maven project obtained from a GitLab repository, NetBeans started downloading the Maven Central Repository Index from its official source (https://repo.maven.apache.org/maven2/.i ... y-index.gz). Although the download took a reasonable amount of time, considering the size of the file (around 2 GB), it took two hours to extract its content. During this process, I noticed via htop that NetBeans was utilizing over 100% of CPU usage. Consequently, I stopped the process (never completed) and closed the IDE. At that point, Maven and Tomcat were not installed on my system. I require both to properly run my projects. I attempted to uninstall NetBeans 20 using Flatpak and install NetBeans 21 from the .deb package downloaded from the official Apache NetBeans site. Unfortunately, the results were worse, as I couldn't even open a NetBeans project, as the IDE froze upon the attempt. Subsequently, I reverted to the NetBeans 20 Flatpak installation and attempted to configure the "Maven Home" to my local Maven installation via the options window. However, NetBeans did not display "/etc/maven" or "/usr/share/maven" when browsing for the home directory. Also, it shows me an "/app" directory, which doesn't really exist in my filesystem. I'm unsure where NetBeans is obtaining this directory from. I think it may be a virtual one created by the IDE, or by Flatpak: Additionally, there is no "/.m2" folder in my home directory (and I understand that it should). I can see those mentioned folders in my filesystem in the browser: I don't know which one should be the Maven home directory, but NetBeans doesn't recognize me any of both. I downloaded the repository index (.gz file) via my browser, but I'm unable to set up NetBeans to work with my native Maven installation. Furthermore, it does not recognize the OpenJDK 22 I installed via apt. Any ideas on what might be happening? I feel like there are many things I am overlooking. Thank you very much! Leandro |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 2 replies
-
Beta Was this translation helpful? Give feedback.
I solved this issue myself by following these steps:
Uninstalled both my Flatpak installation of Apache NetBeans 20 and my installation of NetBeans 21 from the ".deb" package.
Installed Apache NetBeans 20 from a ".deb" package downloaded from the official webpage.
In the terminal, ran the following command: "sudo update-alternatives --config java". Then, selected "/usr/lib/jvm/java-11-openjdk-amd64/bin/java" from the displayed options in the menu.
Ran the command "java --version" in the terminal to verify if the previous step worked properly. Confirming that the default Java version in my system was indeed the one I had selected.
Ran the command "whereis java" to see the directo…