Configure Conflict Resolver
There are situations when a bridge tries to replicate an operation for a key that already exists in the cache. Conflict Resolver is introduced to resolve the conflict between existing operations and operation replicated from bridge to the cache. It decides which key to apply on the cache depending upon defined rules. By default, the decision will be made on Time Based rule, which keeps the latest key on a cache. Users can also define their own rules for conflict resolver.
Make sure you have implemented IBridgeConflictResolver interface to configure it on cache.
Using NCache Web Manager
Launch NCache Web Manager by browsing to http://localhost:8251 (Windows) or
<server-ip>:8251(Windows + Linux).
In the left navigation bar, click on clustered caches or Local Caches based on your requirement. Against the cache name click on View Details.
Make sure that the cache is stopped.
- In the new window opened, go to the Advanced Settings tab and from the left bar, click on Conflict Resolver.
- It will open a window with conflict resolver options. Check the Enable Conflict Resolver checkbox in order to enable conflict resolver.
- After enabling, click on the ... button and select the assembly in which conflict resolver is implemented.
- Select the assembly and the name of the selected assembly will appear in the Assembly Name textbox along with all the classes which have implemented the
IBridgeConflictResolverinterface. Select the required class.
- Enter the parameters if your implemented class requires any and then click +.
- Click the Deploy Conflict Resolver button, select your assembly in which you have implemented
IBridgeConflictResolverinterface and click on the Open button in Open dialog.
- Click on Save Changes once all the changes are made and you have deployed the assemblies.