3 ms·
So in short, the opposite of a Bloom filter is a hash-map where, if you add two items that have the same hash, the second one replaces the first instead of them
by Rangi42 11y ago
So in short, the opposite of a Bloom filter is a hash-map where, if you add two items that have the same hash, the second one replaces the first instead of them both being stored in a linked-list bucket.
> The old id at that index is compared to the new id just added. If they differ, containsAndAdd returns false and the process should write the event. If the ids are the same, containsAndAdd returns true and the process can safely drop the event on the ground. Occasionally, two byte arrays may hash to the same index. When this happens, containsAndAdd will return false and a duplicate write will be emitted. However, since duplicate items come close together in time, this is relatively rare.
- deleted 11y ago[deleted]
- adrianN 11y agoSo the opposite of a bloom filter is a cache with a random replacement strategy. For some applications they work okay, [1], but for other applications they're worse than FIFO, [2]. [1] http://arxiv.org/abs/1202.4880 http://arxiv.org/abs/1202.4880 [2] http://www.ece.uah.edu/~milenka/docs/milenkovic_acmse04r.pdf http://www.ece.uah.edu/~milenka/docs/milenkovic_acmse04r.pdf