How to run apps in the Swirlds browser

Install Java and Swirlds

The Swirlds browser needs both the Java runtime and the Swirlds SDK to be installed. This can be done by following the instructions for either installing with Maven. To simply run the apps without creating new apps, there is no need to install Eclipse or Maven. It is sufficient to just follow the installation instructions for the Java SDK and the JCE security policy file.

The browser is the file swirlds.jar. Both swirlds.jar and the data directory should be in the same directory, along with an optional config.txt file. The subdirectory data/apps will contain all of the apps that the browser can run, each in its own .jar file.

Prepare for random numbers

The Swirlds browser uses the same encryption technology that is used by a web browser when it goes to a secure HTTPS:// website. In both cases, there is a need to get random numbers from the operating system. This works fine for most operating systems, such as Windows, MacOS, and Linux. However, some operating systems may need to be configured to generate good random numbers. If the Swirld browser seems to freeze when launched, it may need extra software to be installed to help the operating system collect entropy (randomness). If that case, download whatever utilities are appropriate for the particular operating system, such as those for Debian or Raspbian

Run the Swirlds browser

Double click on the swirlds.jar file to run an app. (On a Mac, the first time you run it, you may need to right click on it and choose OPEN). You can also run it from the command line by going into the swirlds directory and typing:

java -jar swirlds.jar
Future versions of the browser will have a window interface to let the user launch apps and connect to existing networks. The current version supports another method for controlling it, the config.txt file. The config.txt file that comes with the SDK has comments in it explaining how to control which app will run, and how to pass it parameters. It can also control how many instances will run, and which computers they will run on. It can even run multiple instances on the same machine, communicating with each other through TCP/IP as if they were on different machines.

Use the SDK to develop and run new apps

After downloading and installing the SDK as above, developers can write new apps that run in the Swirlds browser.

Back