Added Redis integration and a few fixes