Currently, there is no active website showing the Bioinformatics study computers' activity. Previously a website existed that showed which computers where online or offline, but since a while it stopped working and its replacement could have some extra features. That's why our team of student developers where tasked to provide exactly that. The advantage of such website is giving a quick overview what computers can be logged into using either ssh or in the classroom by students and teachers alike, without having to manually find out by trial and error.
To realize this, a web.xml is needed with requests, which are links that inquire data e.g. computer workload from a server. Then these queries are fetched by the XmlWebListener and a list of these request is passed to the RequestListener. The RequestListener then starts making requests using the MakeRequest class. Once, those are made the extracted data is assigned to a structured Workstation class. Finally, we convert that structure to JSON type objects.
Then from the back-end these objects can be fetched by the middleware which is AJAX in JavaScript. This data is then connected to a configure JSON file, which is used for creating a computer grid or classroom map that can be inserted into the front-end; the HTML pages.
The website contains two main functions:
- A status page (/home) that displays all workstations. Filtering, show additional information, hiding offline workstations is available here.
- A map page (/map) that can display a map of workstations for each room separately
The project was made by third year bioinformatics students. The task was to create a functional status page for the bioinformatics department.
This website is easy to use and most features speak for themselves. The main page (/home) contains the main functionality of the website. Every workstation from a configuration file is visible. For every workstation, additional information can be shown by pressing a button "show status".
The map page (/map) displays a map of workstations for a given room. The map page can be reached using the navbar navigation. Simply press the button of the room you want to see the map from.
At the top of the main page, you can find a selection of four workstation that can be used to connect to. These workstation are sorted by:
- Status
- Load
- Memory
- Temperature
The main purpose of the SSH Suggestions is to quickly provide information about which workstation is best to use to connect
By pressing the button "show me " you can get aditional information about the workstation.
- Luka Stein - l.t.stein@st.hanze.nl
- Sibren Reekers - s.h.b.reekers@st.hanze.nl
- Mark Van de Streek - m.van.de.streek@st.hanze.nl
The project is mosty relying on a configuration file. Inside this configuration file, every workstation from the department is storerd inside a room list. Additionally, every room contains a matrix where the map of the room is defined.
For example, look at configuration for room H188A below:
"H188A": { "pc" : [ "nuc504.bin.bioinf.nl", "nuc505.bin.bioinf.nl", "nuc503.bin.bioinf.nl", "nuc502.bin.bioinf.nl", "nuc501.bin.bioinf.nl" ], "classRoomMatrix": [ ["nuc504", "null", "null"], ["nuc503", "nuc502", "nuc505"], ["nuc501", "null", "null"] ]
As you can see, first there is a list of worksations inside the rooms. And then a matrix containing the map.
The "null" inside the matrix means there is no workstaion at that place in the room.
Every room has the main projecting worksation (i.e., the teacher pc) at the top of the matrix. This way, every map can be readed in the same way.
Beacuase we use a configuration file, it is very easy to move a workstation. The steps for moving a workstaion:
- Remove the workstation from the "pc" list
- Remove the workstation from the classRoomMatrix
However, a number of things must be met:
- Make sure the classRoomMatrix does not contain a workstation that does not exist. This is the same for the "pc" list.
- After moving a workstation, make sure the matrix dimensions are still the same. For example, you are moving a workstation that contains originally 6 rows with every row having 6 columns. After moving a workstation (removing), one row has 5 columns. Fill this gap with "null" to meet the conditions again.
- It is possible to edit the dimensions of a classRoomMatrix, but make sure every row has the same amount of columns with no gaps.
Below is the main project tree
src/
└── main
├── java
│ └── nl
│ └── bioinf
│ └── shbreekers
│ ├── config
│ │ ├── WebConfig.java
│ │ └── XmlWebListener.java
│ ├── model
│ │ ├── MakeRequests.java
│ │ ├── ParseJsonRequests.java
│ │ └── Workstation.java
│ └── servlets
│ ├── AboutServlet.java
│ ├── MainServlet.java
│ ├── MapServlet.java
│ └── RequestListener.java
└── webapp
├── data
│ └── config.json
├── images
│ ├── favoicon_round.png
│ └── HanzeLogo.jpeg
├── js
│ ├── CreateMapOfRooms.js
│ ├── createScrollButton.js
│ ├── createSuggestionsCards.js
│ ├── createWorkStationCards.js
│ ├── main.js
│ └── requests.js
├── style
│ ├── sidebar.css
│ └── viewport.css
└── WEB-INF
├── templates
│ ├── About.html
│ ├── index.html
│ ├── Map.html
│ ├── Sidebar.html
│ └── template.html
└── web.xml
16 directories, 26 files
The design of the status page changed a couple of times. Below are some examples of the first versions.