move rdb interface to a separate package
add curryhandler func to websocket package