make TTL work

fixes #1068 

It lacks tests, but is able to work well.
i wanna get some feedback for this implementation, and I am adding tests for it now.
We should be able to. but we cannot do it now... can we revisit this when we have the Node interface and ready to refactor the whole stuff?