How can I reindex artifacts that have already been indexed?

By default, Xray creates a property in Artifactory about its indexing state for each artifact. For example,

key" : "xray.20dfffd5-b60a-4002-6eb8-75db29960095.index.status",

    "value" : "Indexed"

Once the property is set as indexed, Xray will not perform indexing again. If you have a need to reindex the artifacts that have already been indexed, you will need to first configure Artifactory to for reindexing.

1. To enable the reindexing, add following flag to $CLUSTER_HOME/ha-etc/ file (or $ARTIFACTORY_HOME/etc/ if you are not using High Availability).


2. Artifactory nodes need to be restarted in order for the change to get applied.

3. Afterward, you may go to Xray => Admin => Artifactory => Click on the Instance ID => then move your mouse over to the end of the Index Status to click on "Index Now"

4. You may watch the progress of the indexing by refreshing the Index Status by clicking on "Recalculate" or by reading the indexing log at ~/.jfrog/xray/xray/log/xray_indexer.log

5. After it is reindexed, you may turn the parameter back to off by setting artifactory.xray.force.reindex=false , which is a default value. Then restart Artifactory.