With Drupal 7 I am using a SOLR search index. The index covers a particular content type. I have a view which uses the search facets and displays a paged list of items in the index.
My problem comes with deletion.
When I delete a node that content type I execute the following code via Workflow rules:
// Mark node as dirty $search_api_track_item_change('node', array($node->nid)); // Load the index application $index = search_api_index_load('index_name'); // Re-index now. search_api_index_items($index);
After a while the node is removed from the index.
However before that happens the view displays an empty entry for the deleted node, the view also includes the deleted node in the count of available items.
How do I notify the search facets/view to filter out the deleted node??