jDesktop application server is a JavaScript runtime built on Chrome’s V8 JavaScript engine. The application server is multi-threaded and uses event-driven, non-blocking I/O model that makes it lightweight and efficient for running separate isolates of javascript applications.

Application structure

jdesktop applications has a strict directory structure as follow:
| – /inc -> Additional includes for the application
|       | – config.js -> Main configuration file
| – /css -> Stylesheets for the client side of the application
|       | – client.css -> Stylesheet for the main window
| – /gui -> GUI designs for the client side of the application
|       | – client.json -> GUI for the main window
| – client.js -> Client side source code
| – server.jss -> Server side source  code

Applications’ path

Web applications created by jDesktop developer are stored at the folder: /var/www/html and can be access by a browser (after it is started) at http://[yourip]/[application name]/

Server configuration

The main configuration file for jDesktop application server can be found at /etc/jdesktop/jdesktop.conf

Starting and Stopping jDesktop server

To start the jDesktop server use the systemd’s start command. If you are running as a non-root user, you will have to use sudo since this will affect the state of the operating system:

To stop a running jDesktop server, you can use the stop command

Enabling and Disabling Services

The above commands are useful for starting or stopping jDesktop during the current session. To tell systemd to start jDesktop server automatically at boot, you must enable it.

To start the server at boot, use the enable command:

To disable the service from starting automatically, you can type:

Keep in mind that enabling a service does not start it in the current session. If you wish to start the service and enable it at boot, you will have to issue both the start and enable commands.

Checking jDesktop server status

To check the status of the server on your system, you can use the status command:

This will provide you with the server state.