How to deploy the Learning Dashboard - Learning-Dashboard/LD-learning-dashboard GitHub Wiki
The LEarning Dashboard is a web application developed in Java. Some data is stored in a PostgreSQL database and some in a MongoDB Database. It is composed by 4 components:
-
LD-learning-dasboard: Web application providing all the functionality to the final user.
-
LD-si_assessment-rest: RESTful service providing strategic indicators assessment using Bayesian Networks instead of an average.
-
LD-forecast-rest: RESTful service providing prediction and forecasting functionality.
The requisites to deploy Learning Dashboard are:
-
A web server, e.g. Tomcat.
-
Oracle Java JRE.
-
PostgreSQL, an open source object-relational database system.
-
MongoDB, a NoSQL database system.
-
R Server
-
Download and install R in the machine where the R server will be deployed. For Linux, version 3.4.4 is recommended, and for Windows, version 3.5.3. For Linux, the libraries libssl and libcurl may be needed to install the R packages, install the corresponding ones for your distro. For Windows, Rtools may be needed.
-
(Optional step) For Linux, the installation of the "prophet" package can be speeded up installing the "rstan" binaries beforehand. RStan on Linux ( Section "Installing from the repository")
-
-
PABRE-WS, deployed externally in the following endpoint. The code is available at https://github.com/OpenReqEU/requirement-patterns
The data is ingested and analysed by the following components
-
Source Data Connectors (LD-connect)
-
Data Analysis component (LD-eval)
The instructions included in this deployment guidelines explain how to deploy the dashboard using all the needed war files. The needed war files can be found in the installation package included in the Learning Dashboard releases or you can generate them by yourself following the How to make your own Learning Dashboard deployment.
In order to install the dashboard, you need to have the following files:
- LD-learning-dashboard.war
- LD-forescast-rest.war
- LD-si_assessment.war
- TimeSeriesFunctions.R
- Deploy LD-si_assessment.war in your Web Server
- Deploy LD-forescast-rest.war in your Web Server
- Copy TimeSeriesFunctions.R to an accesible folder (RSCRIPTS_FOLDER). You can use the APACHE version of the scripts (included in the installation package), including only one forecasting method, or use the GPL version of the scripts containing the complete set of forecasting methods, available in the forecast-RScript repository
- Configure forecasting, setting the correponding values in the following application.properties file:
Rserve.host=<RSERVER IP>
Rserve.port=<RSERVER PORT>
Rscripts.location=<RSCRIPT_FOLDER>/TimeSeriesFunctions.R
- Install the required R packages, from an R console, depending on the .R script file you have deployed:
- If you deployed the .R script file (APACHE version) included in the installation package:
install.packages("devtools")
library(devtools)
install_version("prophet", version="1.0")
install_version("Rserve", version="1.8-11")
install_version("mongolite", version="2.7.2")
- If you deployed the .R script file (GPL version) from LD-forecast-RScript repository:
install.packages("devtools")
library(devtools)
install_version("forecast", version="8.21")
install_version("prophet", version="1-.0")
install_version("Rserve", version="1.8-11")
install_version("mongolite", version="2.7.2")
install_version("forecastHybrid", version="5.0.19")
- If you deployed the .R script file (APACHE version) included in the installation package:
- The Rserve is already prepared to be run:
library(Rserve)
Rserve()
By default, Rserve will start the server listening on the 6311 port. You can change it if you prefer to use another port with the parameter “port” (and setting the corresponding one in the application property Rserve.port): Rserve(port=6312)
- Create a database in the PostgreSQL database system:
CREATE DATABASE postgres;
- Deploy the LD-learning-dashboard.war in your Web Server
- Configure the dashboard. Details about the dashboard configuration are in Configuration file
Check if you have the indexes for each product you have configured for the LD-eval.
Detailed information about the MongoDB indexes accessed by the dashboard in MongoDB Collections