-
Notifications
You must be signed in to change notification settings - Fork 2
System setup
After building the the project, and thereby building the client jar and server ear archives, the next task is to setup and run the lending system.
The lending system requires a database to store all known games, identity cards, envelopes and current lending information.
For this database we recommend a MySQL database.
After creating a new database you can setup the required table with the generated database creation script found in the project folder lending-database/target/generated-schema/create.sql
.
After creating a database, for the lending system to store its data, the next step is to download and install the application server WildFly 11. WildFly will be responsible for running the server parts of the lending system.
After setting up a WildFly installation and creating a new database, the next step is to setup a datasource, which is required for the lending system to communicate with the database.
To run the lending system a mysql database is recommended, therefore before the lending system can be installed on the application server, a mysql database connector needs to be installed. The easiest way to install a database connector is through a deployment.
After installing a mysql database connector, a datasource needs to be configured.
To do this you log in to the web console of WildFly.
There please select Configuration -> Subsystems -> Datasources -> Non-XA -> Add
.
Afterwards you need to specify the details of the new datasource.
When specifying the datasource details it's important to set the JNDI
to java:jboss/datasources/ausleihe
.
After creating a new datasource it's time to deploy the server ear for the lending system.
This ear archive contains the server functionality of the lending system, including two rest APIs used to communicate with the lending desktop clients and the administration web clients.
The to be deployed ear archive can be found at lending-ear/target/Ausleihe Spielekreis.ear
.
With the deployment the lending server will automatically begin operating.
After installing and running the lending server, the next step is to distribute and configure the lending client.
The lending client can be found at lending-client/target/Ausleihe Spielekreis-jar-with-dependencies.jar
.
This file needs to be distributed to all lending terminals, from which identity cards should be issued and games borrowed.
For the lending clients to know where the lending server is located, it requires a configuration file.
An initial version of the configuration file can be generated with the command java -jar [Ausleihe Spielekreis-jar-with-dependencies.jar] -c
.
Afterwards you need to open the generated configuration file and correct the settings, then you can start the clients.