Port 9090 is being used by Java

Hello fellow ShinyProxy users, I am fairly new to using ShinyProxy and after a few days’ tinkering I finally got the demo working on Ubuntu 20.04. However I came across an issue and hope someone know how to fix it. When I first tried to start ShinyProxy I got the “Port 8080 was already in use” error so I followed the FAQ and changed the port to be 9999. But then I got a “port 9090 was already in use” error. After some digging I found out port 9090 is being listened by Java. I managed to kill the process using this command
sudo kill -9 sudo lsof -t -i:9090
And then everything runs fine.

My question would be:
Why does this happen and how to avoid this extra step?

Here is more information about my system.
Ubuntu 20.04 LTS
ShinyProxy version: 2.5.0

openjdk version “1.8.0_292”
OpenJDK Runtime Environment (build 1.8.0_292-8u292-b10-0ubuntu1~20.04-b10)
OpenJDK 64-Bit Server VM (build 25.292-b10, mixed mode)

Client: Docker Engine - Community
Version: 20.10.6
API version: 1.41
Go version: go1.13.15
Git commit: 370c289
Built: Fri Apr 9 22:47:17 2021
OS/Arch: linux/amd64
Context: default
Experimental: true

Server: Docker Engine - Community
Version: 20.10.6
API version: 1.41 (minimum version 1.12)
Go version: go1.13.15
Git commit: 8728dd2
Built: Fri Apr 9 22:45:28 2021
OS/Arch: linux/amd64
Experimental: false
Version: 1.4.4
GitCommit: 05f951a3781f4f2c1911b05e61c160e9c30eaa8e
Version: 1.0.0-rc93
GitCommit: 12644e614e25b05da6fd08a38ffa0cfe1903fdec
Version: 0.19.0
GitCommit: de40ad0


Now looking back I could’ve just killed Java directly. Also Java is then restarted when I start ShinyProxy. It is just strange to me that ShinyProxy relies on Java but can’t start if Java is already running.