aset
Proposal Management System for Seismic Engineering
September 11, 2019

Introduction

This user manual is to help you maintain, update and use the relevant application easily and quickly. You’ll find detailed screenshots, explanations and instructions on how to manage it.

Version 1.0.0.Draft

aripd.com

Installation

Prerequisites

Install

Debian operating system is pre-installed. To update and upgrade it

1
2
3
4
# update the list of available packages and their versions, it does not install or upgrade any packages.
$ apt-get update
# install newer versions of the installed packages
$ apt-get upgrade

To install Java

1
2
3
4
# install jdk
$ apt-get install default-jdk
# check version
$ java -version

To download and install Glassfish application server

1
2
3
4
5
# Download Glassfish on Maven Central
$ wget https://repo1.maven.org/maven2/org/glassfish/main/distributions/glassfish/5.1.0/glassfish-5.1.0.zip
# Install unzip and then unzip Glassfish
$ apt-get install unzip
$ unzip glassfish-5.1.0.zip -d /opt

To install MySQL

1
2
3
4
5
6
# Install MySQL
$ apt-get install mysql-server
# Improve MySQL installation security
$ mysql_secure_installation
# check version
$ mysql --version

To download and install MySQL Connector/J

1
2
# Download MySQL Connector/J and copy it to Glassfish external libraries directory
$ wget https://repo1.maven.org/maven2/mysql/mysql-connector-java/8.0.21/mysql-connector-java-8.0.21.jar -P /opt/glassfish5/glassfish/domains/domain1/lib/

To install the application

1
2
3
4
5
6
7
8
# Clone the application
$ apt-get install git
$ git clone https://bitbucket.org/aripd/aset.git

# Compile the application
$ cd aset
$ apt-get install maven
$ mvn clean install

Setup

Set server time as GMT for the UK. Check out World Clock / Converter

To change time zone, run

1
$ dpkg-reconfigure tzdata

To change locale

1
$ nano /etc/locale.gen

Uncomment tr_TR.UTF-8 UTF-8 line, and run below to activate locale

1
$ locale-gen

Create MySQL database and user

1
2
3
4
5
$ mysql
mysql> CREATE DATABASE aset CHARACTER SET utf8 COLLATE utf8_general_ci;
mysql> CREATE USER aset@localhost IDENTIFIED BY 'P@ssword1';
mysql> GRANT ALL PRIVILEGES ON aset.* TO aset@localhost;
mysql> FLUSH PRIVILEGES;

Create MySQL tables if initial sql file is ready

1
$ mysql -u aset -p aset < /path/to/aset.sql

Drop MySQL tables if database is not empty

1
2
3
4
5
6
7
mysql> USE aset;
mysql> DROP TABLE IF EXIST products_recommendeds;
mysql> DROP TABLE IF EXIST FORMULAENTITY;
mysql> DROP TABLE IF EXIST PROPOSALITEMENTITY;
mysql> DROP TABLE IF EXIST PROPOSALENTITY;
mysql> DROP TABLE IF EXIST PRODUCTENTITY;
mysql> DROP TABLE IF EXIST USERENTITY;

Edit domain.xml to change port and application context root

1
$ nano /opt/glassfish5/glassfish/domains/domain1/config/domain.xml

Find http-listener-1 and change the value from 8080 to 80

1
<network-listener protocol="http-listener-1" port="8080"

Find context-root and change the value to “/aset” or “/”

1
<application context-root="/aset"

You can now start Glassfish

1
$ asadmin start-domain domain1

Define resources to Glassfish using asadmin tool

  • Create a JDBC resource with the specified JNDI name

    $ asadmin> help create-jdbc-resource for help

    1
    2
    
    $ asadmin> create-jdbc-resource --connectionpoolid aset_pool --enabled=true jdbc/aset
    Command create-jdbc-resource executed successfully.
  • Register a JDBC connection pool

    $ asadmin> help create-jdbc-connection-pool for help

    1
    2
    3
    4
    
    $ asadmin> create-jdbc-connection-pool
    --datasourceclassname com.mysql.jdbc.jdbc2.optional.MysqlXADataSource --restype javax.sql.XADataSource
    --property portNumber=3306:password=P@ssword1:user=aset:serverName=localhost:databaseName=aset:connectionAttributes=\;create\\=true aset_pool
    Command create-jdbc-connection-pool executed successfully.

Add the named authentication realm to Glassfish using asadmin tool

$ asadmin> help create-auth-realm for help

1
$ asadmin> create-auth-realm --classname com.sun.enterprise.security.auth.realm.jdbc.JDBCRealm --property jaas-context="jdbcRealm":datasource-jndi="jdbc/aset":user-table="USERENTITY":user-name-column="EMAIL":password-column="PASSWORD":group-table="USERENTITY":group-name-column="USERGROUP":digest-algorithm="none":digestrealm-password-enc-algorithm="none" "jdbcaset"

Support

Supporting Languages

Currently we support two languages. Default one is English GB. For further languages support please contact with us.

  • English GB (default)
  • Türkçe TR
  • Español ES
  • Français FR
  • Pусский RU

Technologies

Below are core technologies that we use for this project.

  • Operating System: Debian, CentOS
  • Development Platform: Java Enterprise Edition
  • User Interface Framework: Java Server Faces
  • Deployment Server: Oracle Glassfish
  • Database Compatibility: MySQL, MariaDB
  • Reporting Engine: JasperReports

Reports

TBD

Issues

We use Atlassian Bitbucket as our issue tracker, at:

https://bitbucket.org/aripd/aset/jira