Configuring Cache Level Events
NCache event notifications let you design applications that react to various cache events. These notifications are disabled by default to save precious CPU and network resources. Events are fired upon addition, update and removal of an object or when cache is cleared. These notifications are off by default but can be turned on, for Clustered or Local Caches, as follows:
Using NCache Manager
Click on the cache name in Cache Explorer to open cache settings.
Go to the Options tab.
Check Item add notification, Item remove notification and Item update notification check boxes.
Right click on the cache in Cache Explorer and select Apply Configuration option.
Manually Editing NCache Configuration
For Community Edition, you can manually edit config.ncconf located at %NCHOME%/config.
Make sure Cache Host Process is stopped before making any configuration changes. If it is not stopped and the changes are made, kill the Cache Host process and then start it.
- Specify cache-level notifications through config.ncconf by specifying the
<cache-notifications>tag under the
<cache-settings ...> <logging enable-logs="True" trace-errors="True" trace-notices="False" trace-warnings="False" trace-debug="False" log-path=""/> </cache-settings>
- Once changes are made, start the Cache Host process.