db kv job storage refactor