add a basic test and support redis db
update docs and API