@marmbrus I thought about it, but thats tricky. Here the values are weak refs. So with a reference queue you can get which values were out of scope but not sure how to get the corresponding keys. And we need the keys to cleanup.