adding on_cache_flush event
Merge pull request #1693 from goutnet/add-on_cache_flush-event

adding on_cache_flush event