You are currently browsing legacy 4.0 version of documentation. Click here to switch to the newest 5.0 version.
Operations: How to Check if an Index has Changed
IndexHasChangedOperation will let you check if the given index definition differs from the one on a server. This might be useful when you want to check the prior index deployment, if the index will be overwritten, and if indexing data will be lost.
public IndexHasChangedOperation(IndexDefinition definition)
|true||if an index does not exist on a server|
|true||if an index definition does not match the one from the indexDef parameter|
|false||if there are no differences between an index definition on the server and the one from the indexDef parameter|
bool ordersIndexHasChanged = store.Maintenance.Send(new IndexHasChangedOperation(ordersIndexDefinition));