Revise memory cache surface area, add trigger APIs, update samples.