Add redis. And some change design.