adding small changes to amplify, to support, the cache parameter. cacheOptions, that would be available inside cache function resolve.