def each
      @lock.synchronize do
        @items.each do |id, ref|
          begin
            yield id, ref.__getobj__
          rescue WeakRef::RefError
          end
        end
      end
    end
def each
      @lock.synchronize do
        @items.each do |id, ref|
          begin
            yield id, ref.__getobj__
          rescue WeakRef::RefError
          end
        end
      end
    end
Iterates over registered and alive items