Getting Started‎ > ‎

BusLogicDemo installation


BusLogicDemo is a very simple, self-contained web application that demonstrates the use of declarative business logic. This page will walk you through the steps to install and run it.

Requirements


You will need Java 1.6 or later installed. Either the JRE (Java Runtime Environment) or the JDK (Java Developer's Kit) can be used. Please note that Java 1.5 and earlier versions will not work properly.

You will also need about 50MB of free disk space.

The application should otherwise run on any Java-compatible platform.

Download and installation


The application comes as an archive file that includes a copy of Apache Tomcat, and a self-contained database (Hypersonic SQL).

You can fetch a copy of the installation package:


Once you have downloaded the archive file, un-archive it, and you should see a directory named ABLDemo.



There is usually no configuration required. You are now ready to run the demo.

Starting the server


You'll first need to start the bundled server. This is a pre-configured version of Apache Tomcat, with all required software pre-installed.

On Windows


Execute the script RunDemoServer.cmd :


If your Java installation is not in the expected location, you may get an error message similar to:


In this case, you'll need to edit the script and set the JRE_HOME or JAVA_HOME environment variable to point to your Java installation.

On Unix/Linux/Mac

From a terminal window, execute the RunDemoServer.sh script:


On other platforms

For other platforms, you may need to create a script equivalent to these scripts.


Keep the server running


The script will not return until the server exits, therefore you should leave it running while you explore the demo. Any problems will be logged in that window.

Once you're done with the demo, you can stop the server by hitting ctrl-c in the terminal window.

Running the web application


To bring up the actual application, open your favorite web browser and connect to the following address:


If all went well, you should see something like the following:


If you see this, your demo is up! You can now proceed to edit the data, and see the business logic fire.


Troubleshooting


It is possible that the demo may not run as expected. In this section, we describe some common scenarios.

Java not found

This is a common problem on Windows. If neither JRE_HOME nor JAVA_HOME is defined as an environment variable, the startup script looks in the Windows registry and attempts to find the location of the JRE for Java 1.6 or Java 1.7. If it cannot find it, you will get an error similar to:



In this case, you can edit the RunDemoServer script, edit either variable, and set it properly.


Address already in use


If, when running the RunDemoServer script, you see an error similar to the following:

SEVERE: Failed to initialize end point associated with ProtocolHandler ["http-bio-9080"]
java.net.BindException: Address already in use <null>:9080
at org.apache.tomcat.util.net.JIoEndpoint.bind(JIoEndpoint.java:378)
at org.apache.tomcat.util.net.AbstractEndpoint.init(AbstractEndpoint.java:482)
at org.apache.coyote.AbstractProtocolHandler.init(AbstractProtocolHandler.java:354)

it means that (in this case) port 9080 is already in use on your machine. This often means that you are trying to run the demo twice at the same time (which cannot be done without some configuration editing).

Regardless, you will need to either free that port, or (perhaps more convenient) change the port used by the server. To do so, edit the file conf/server.xml and change the port in question to a number that is not already in use. For instance, if the problem is with port 9080, you might change:

    <Connector port="9080" protocol="HTTP/1.1" 
               connectionTimeout="20000" 
               redirectPort="9443" />

to

    <Connector port="7080" protocol="HTTP/1.1" 
               connectionTimeout="20000" 
               redirectPort="7443" />


Firewall/virus scanner problems


It is possible that you may encounter problems if some security software on your computer (like a firewall or virus protection) restricts the server. For instance, you might get a message like the following:


There are many different types of security software, both in the various versions of Windows, and from third-party vendors, and it is impossible to anticipate their reactions. Generally speaking, this demo does not require more privilege than any other typical Java application.

Comments