Reindexing data after a major version Solr upgrade
After a major version upgrade to Solr, Apache strongly recommends that the data in Solr is reindexed. If you are upgrading a deployment of i2 Analyze from version 4.4.2 or earlier, the Solr indexing service is upgraded to version 9 from version 8.
While the data is being reindexed the system is offline. In systems where there is a lot of data, this can take some time. During the upgrade process, the instructions direct you to run the toolkit command that reindexes your data. Alternatively you can reindex the data at another time the suits your organization to reduce downtime during the upgrade procedure or when there is less load on the database.
If you do not reindex your data now, you will have to do so if i2 Analyze adopts the next major version of Solr. Until then, i2 will provide support for indexing issues that can be reproduced on Solr 9.
During the upgrade
To reduce the downtime of the system, during the upgrade you can recreate the transient Solr collections. These collections retain data for a short amount of time, which means they can be recreated quickly with no data in them. The transient collections are; highlight, vq, recordshare, and daod.
After you upgrade Solr, run the following toolkit task from the Liberty server to upgrade the transient Solr collections:
setup -t upgradeTransientIndexes --hostname liberty.hostname
Where liberty.hostname is the hostname of the Liberty server where you are running the command, and matches the value for the host-name attribute of the <application> element in the topology.xml file.
After you have upgraded the transient Solr collections, continue with the rest of the upgrade procedure:
After the upgrade is complete, you can return to upgrade the rest of the collections at a more suitable time.
After the upgrade
After the upgrade is complete, you can recreate and reindex the non-transient Solr collections at times that suit you. The process is more involved to reduce the total downtime of the system.
You do not have to complete the process for all indexes at the same time. Upgrading the match index does not require any downtime.
If your system is deployed on multiple servers, run the upgrade tasks from the Liberty server.
Upgrading the chart collection
Before you upgrade the collection, stop Liberty by running the following command on the Liberty server:
setup -t stopLiberty
To upgrade the chart collection, run the following command on the Liberty server:
setup -t upgradeChartIndex --hostname liberty.hostname
Where liberty.hostname is the hostname of the Liberty server where you are running the command, and matches the value for the host-name attribute of the <application> element in the topology.xml file.
After you upgrade the collection, restart Liberty by running the following command on the Liberty server:
setup -t startLiberty
When you start i2 Analyze, the data in any upgraded collection is reindexed.
Upgrading the match index
To upgrade the match index, you can build a standby match index and instruct the system to use that index after it has been built.
To upgrade the match collection, run the following command on the Liberty server:
setup -t upgradeMatchIndex --hostname liberty.hostname
Where liberty.hostname is the hostname of the Liberty server where you are running the command, and matches the value for the host-name attribute of the <application> element in the topology.xml file.
After the upgrade of the match index is complete, instruct the system to use the new index by running the following command:
setup -t switchStandbyMatchIndexToLive
Upgrading the main collection
Before you upgrade the collection you must stop Liberty. To stop Liberty, run the following command on the Liberty server:
setup -t stopLiberty
Before you upgrade the collection, stop Liberty by running the following command on the Liberty server:
setup -t upgradeMainIndex --hostname liberty.hostname
Where liberty.hostname is the hostname of the Liberty server where you are running the command, and matches the value for the host-name attribute of the <application> element in the topology.xml file.
After you upgrade the collection, start i2 Analyze:
setup -t startLiberty
When you start i2 Analyze, the data in any upgraded collection is reindexed.