You are here

Semester Progress (Part 1)

The blog may have been a little neglected these past few weeks, but great process has been made. I will split up the work into several topics which will be the subjects of the next few posts.

First, the database for the foods had to be updated with actual food information. To accomplish this, a parser was built that scrapes data from online restaurant databases in order to populate a database for our use. Although the parser needs to be tweaked and configured for each restaurant, this greatly simplifies the process of adding restaurants to the application. And since the restaurants exist on a server independent of the app, it enables restaurants to be added at any time without updates having to be made to the app. Among other things, this enables the user testing to get under way even without a completely populated database.

The database also handles a lot of calculations for us. For example, it takes care of classifying the foods into different nutritional categories, since it already has access to the nutritional information.

The database also allows for string searching of restaurants -- a function was added to the database that calculates the Levenshtein distance between two strings. Thus, when asking the database for a restaurant based on user input, we can also display restaurants that have a short Levenshtein distance from whatever the user typed in.

The database is not exposed to the public, as that is obviously a security risk. The only interface to the database are servlets of my creation that return predefined queries -- this way, there is no risk of the database being compromised.