This project is maintained by infsci2711
ssh YOURUSERNAME@IP
sudo apt-get install maven
sudo apt-get install git
sudo apt-get install openjdk-7-jdk
sudo apt-get install mysql-server
sudo apt-get install nginx
cd /opt
sudo mkdir project
cd project
sudo mkdir deployed
cd deployed
sudo mkdir upload
cd /opt/project
sudo git clone https://github.com/infsci2711/MultiDBs-Utils.git
sudo git clone https://github.com/infsci2711/MultiDBs-FilesAPIs2DBs-Server.git
sudo git clone https://github.com/infsci2711/MultiDBs-FilesAPIs2DBs-WebClient.git
cd /usr/share/nginx
sudo rm -R html
sudo ln -sv /opt/project/MultiDBs-FilesAPIs2DBs-WebClient/WebContent html
var restBaseUrl = "http://52.0.4.98:7654/";
cd /etc/mysql
vi my.cnf
change the #bind-address to 0.0.0.0
cd /opt/project/MultiDBs-FilesAPIs2DBs-Server
sh startup.sh
sh mvnInstall.sh
Generally, our project has three parts, the front end, Dataverse interface and the back end.
The front end is basicly a html page. The html page allows user to upload a SPSS file by form or request a SPSS file from Dataverse. The front end will post the uploaded file to Ubuntu server.
When the user request a file from the Dataverse, our API will post the name of the requested dataset to the Dataverse. Dataverse will generate a URL as a return that our API can use RESTful to get the meta data of the requested dataset. The meta data we needed is the ID of the dataset. Our API will read the ID and make a new request to the Dataverse using this ID. By submittin this ID, Dataverse will return the desired file to our API and the API will uploaded the file to the Ubuntu server to wait for next command.
The back end is the file handling part. Firstly, the SPSS reader in the back end will parse the file to an arraylist and recognize the form name, row name and the column name. In order to make sure all data is store correctly, we store all data as string. Our file reader will re-build the dataset that putting every data in right format. And the API will patch up a SQL to create a new table and record the data in our database in Ubuntu server base on the disposed data.
Due to limitation of time, our project only have handle SPSS file at this time. But it has the potential of reading all file types and store the data to the database.
Any other group which need convert a SPSS file to readable data in server can use our API. Or any user wants to request data from Dataverse is highly recommanded to use our API.
To start our project, developers need an account of Ubuntu server and knowledge of request to RESTful web service that can communicate with Dataverse.
Any updates in our project need to use the mvnInstall.sh script in the MultiDBsFilesAPIs2DBsServerAPI/target. Just simply cd to the location and use sh mvnInshall.sh command to run the script. From the fresh installation, user need to run the startup.sh script in the same directory to initialize the Ubuntu server.