WIP: fix ttl

1. Implement a min-heap, which provide O(logN) insert and O(LogN) update. Use a look up hashmap to simplify the update operation.