Persist sessions

QBWC currently doesn't work with multiprocesses servers, like apache+passenger, because some information is saved in class variables.

I have refactored so information is saved in DB, using ActiveRecord. Maybe something in memory such as redis or memcached is faster, and session usually doesn't need to persist when server is restarted, but I'm using only DB ATM. Code is ready to add other ways to persist and choose one with a config option.