added caching support [untested]