Added redis option and cleaned up.