How do I refresh only the search index for some entity types, and keep the reindex fast?

Question

Search results show outdated values for some entity types, while the profiles themselves are correct. Or a Reindex Data task is taking much longer than expected. How can I rebuild only the search index for those entity types, as quickly as possible?

Answer

Run one Reindex Data task with updateEntities=false, limited to the entity types you need, in distributed mode. By default (updateEntities=true), the task also updates history, match tables, and the analytics layer. With updateEntities=false, it updates only the search (Elasticsearch) data, which reduces the work the task does.

POST https://<environment>.reltio.com/reltio/api/<tenantId>/reindex?entityType=HCP,HCO&updateEntities=false&forceIndexing=true&forceIgnoreInStreaming=true&distributed=true&taskPartsCount=<parts>
Authorization: Bearer <access_token>

Send the request without a body. A body with entity URIs limits the task to those entities.

What each parameter does

  • entityType: limits the task to the listed entity types. Separate several types with commas, so one task covers all of them.
  • updateEntities=false: refreshes search data only. The task doesn't rematch, or update history or analytics. If the match tables also need refreshing, run the Rebuild Match Table task separately.
  • forceIndexing=true: reindexes every object of the listed types, even objects that haven't changed since the last index update. Use it when the profiles are correct but haven't been updated since search went out of date, for example after a survivorship change.
  • forceIgnoreInStreaming=true: events that the task produces aren't sent to your external streaming queues.
  • distributed=true and taskPartsCount: run the task as parallel sub-tasks. taskPartsCount is the upper limit (default 2); the platform starts only as many parts as it needs. Don't run other tenant-wide tasks at the same time.

When to reindex the whole tenant instead

For the configuration changes listed in the Reindex Data Task documentation, such as a change to an existing attribute's type, reindex the whole tenant with enableSeparateIndexing=true. Don't combine it with entityType or a list of entities. The task builds a new index and then reindexes potential matches into it, and search keeps using the current index until the new one replaces it. In both cases, don't update the tenant's business configuration while the task runs.

 

Was this article helpful?
0 out of 0 found this helpful

Comments

0 comments

Article is closed for comments.