Uses ajax to handle (possibly) long queries on historical data
with the aim of improving user experience.
The user is notified when a query is taking too long so that
he/she can get feedback of what is going on.
Interface flows are now stored using integer interface ids rather
than interface names. This speeds up queries.
A migration code has also been introduced so that old MySQL table
format is migrated and old data does not get lost.
This also fixes#460