DEV Community

Discussion on: Yet another ode to Vert.x, or how to write a performance-wise expiring map in less than 100 lines of code.

Collapse
 
agafox profile image
Oleg Agafonov

Thank you for a good hint. Unfortunately it won't work in our case because our entries are not ordered. Also there are more complicated scenarios I haven't shown in this post.

Like when we aggregate SIP transaction the expiration time will be different depending on the transaction's state: github.com/sip3io/sip3-salto-ce/bl...

That's why we use a method called touch to update the entry expiration slot. And it's not really possible to implement with LinkedHashMap only: github.com/sip3io/sip3-commons/blo...