How to use cache in openmrs

How can I use Cache in my module. I need to cache some data for later use, How do setup any of ehcache or caffeine on my openmrs module

Do you find this helpful?

I saw this link before, but for some unknown reason it did not work for me, I will still debug it to see were the error is coming from.