Trac Hov Database Documentation
The Hov Database handles data collected from a custom Java Midlet that has been installed on numerous Palm Pilots. The data collected on the Palm Pilots is imported into an SQL database which is used to drive the Hov website. From this website users can access the collected data in varying levels of detail.
Data Collection
Traffic observers use Palm Pilots loaded with custom data collection software. The software is written in Java and is targeted for the MIDP platform allowing it to be run on any number of handheld devices. Once data is collected, the palm pilots are synched with a computer running a special HotSync conduit, and then the data is imported into the SQL database.
Data Storage
Although almost any database could be used to store the HOV data, MySQL was chosen since it is free, easy to install, relatively fast, and excellently documented. Since all interaction with the database is done through Java's JDBC API, a different database could be switched in if needed with only a few modifications to the SQL queries used.
The database is structured to facilitate easy data manipulation and to be flexible for future changes in the HOV project. Seperate tables are used to store information about traffic corridors, collection sites, and the specific points at these sites where data is collected.
For a complete description of the Hov SQL Database Structure click here.
Data Processing and Display
Since the data is all stored in an SQL database, SQL queries are used to process the data for reports. These queries and there results are handled by dynamic web pages built using Java Server Pages (JSP). Tomcat was chosen to serve the JSP pages since it is widely adopted and the official reference implementation for the Java Servlets and Java Server Pages. Various JSP Taglibraries such as the Request Tag Library and the Java Standard Tag Library were used to ease page development.
Each resluting webpage is written in standards compliant xhtml, and is
styled with Cascading Style Sheets. The default stylesheet provides
styling suitable for standard web browsers, however other stylesheets
can be included in the css_include fragment to allow
alternate themes, styles for users requiring assistive technologies such
as screen readers, and special styling for printed pages. These pages use
an freely available icon set named Crystal in various places.
Data Validation and Filtering
When the data is inserted into the data base, it must be validated. Once validated, it may be used for calculations in the summary and report pages.
During the data validation process, one may modify the collection session information to correct common mistakes made by the traffic observers such as:
- Incorrect session start times
- Incorrect location information
- Empty or nearly empty sessions
Database Administration
Along with validating data, there is also an extensive administrative system designed to alow any person with administrative access and a web broswer to update data concering the database such as:
- Corridor, Site, and Collection Point information
- Vehicle Load Information
- Site news, updates, and alerts
Database Security
All pages which could issue changes to the database are placed behind a secure Realm with access restricted by Tomcat. This can later be expanded to alow finer grain access for any data, or reports that should have limited access.