Reworked sessions and added Redis handler

Requires phpredis to be installed.