make json parsing/generating work with old client
store redis connection in state