redis implementation of run queries