(#3228) - refactor idb