Fix caching of discovered instances