Configuring your HCL Commerce Developer Legacy environment for use with the Solr-based search solution
After installation, your HCL Commerce Developer Legacy environment is configured by default for use with the newer Elasticsearch-based search solution that was introduced in HCL Commerce Version 9.1. Complete the following steps to revert your Developer Legacy environment to maintain or develop sites that use the Solr-based search solution.
Procedure
-
Start HCL Commerce Developer.
Navigate to the WCDE_installdir/bin/ directory and run the following command in a command prompt.
.\StartWCtoolkit.bat
-
From within Rational Application Developer, start the servers in the following order.
- WebSphere Commerce test server
- Search server
- Store server
-
Build the Solr search index for the Aurora sample store.
- Start the search index build. This command is assuming the default spiuser and
password, as well as the default master
catalog.
Note the job status ID that is returned, for use in the next step.curl --user spiuser:passw0rd --insecure -X POST https://localhost:443/wcs/resources/admin/index/dataImport/build?masterCatalogId=10001
- Observe the status of the search index build. Use the status ID that was returned in 3.a.
curl --user spiuser:passw0rd --insecure -X GET https://localhost:443/wcs/resources/admin/index/dataImport/status?jobStatusId=1502
For more detailed information about how to build the Solr search index, see Building the HCL Commerce Search index.
- Start the search index build. This command is assuming the default spiuser and
password, as well as the default master
catalog.
- Optional:
If you are running an Aurora-based storefront with Solr-based search and you are not
using contract-based pricing, you must complete the following to ensure that prices are
reflected in the storefront.
-
Update the Store server JNDI and Transaction server
JNDI settings to point to your Solr-based Search server.
- Open the Store server WebSphere Application Server V8.5.5 Liberty configuration file located at Liberty_installdir\usr\servers\crsServer\configDropins\overrides\jndi.xml for editing.
- Add or update the following entries with the Search server
hostname and port
number.
<jndiEntry jndiName="com.ibm.commerce.foundation.server.services.search.hostname" value="localhost"/> <jndiEntry jndiName="com.ibm.commerce.foundation.server.services.search.port" value="3738"/> <jndiEntry jndiName="com.ibm.commerce.foundation.server.services.search.preview.port" value="3738"/>
- Save and close the file.
- Open the Transaction server WebSphere Application Server configuration file located at WCDE_installdir\wasprofile\config\cells\localhost\nodes\localhost\servers\server1\namebindings.xml for editing.
- Update the following
entries.
<namebindings:StringNameSpaceBinding xmi:id="StringNameSpaceBinding_1566569392360" name="com.ibm.commerce.foundation.server.services.search.port" nameInNameSpace="com.ibm.commerce.foundation.server.services.search.port" stringToBind="3738"/> <namebindings:StringNameSpaceBinding xmi:id="StringNameSpaceBinding_1566569392372" name="com.ibm.commerce.foundation.server.services.search.hostname" nameInNameSpace="com.ibm.commerce.foundation.server.services.search.hostname" stringToBind="localhost"/> <namebindings:StringNameSpaceBinding xmi:id="StringNameSpaceBinding_1566569392380" name="com.ibm.commerce.foundation.server.services.search.preview.port" nameInNameSpace="com.ibm.commerce.foundation.server.services.search.preview.port" stringToBind="3738"/> <namebindings:StringNameSpaceBinding xmi:id="StringNameSpaceBinding_1566569392392" name="com.ibm.commerce.foundation.server.services.search.url" nameInNameSpace="com.ibm.commerce.foundation.server.services.search.url" stringToBind="https://localhost:3738/solr"/> <namebindings:StringNameSpaceBinding xmi:id="StringNameSpaceBinding_1592048347443" name="com.hcl.commerce.search.elasticsearch" nameInNameSpace="com.hcl.commerce.search.elasticsearch" stringToBind="false"/>
- Save and close the file.
- Optional:
Disable Redis.
Note: If you intend to install the HCL Commerce Cache Manager application (
cache-app
) to control your HCL Cache, leave Redis enabled. For detailed instructions, see step #7.- Open the
WCDE_installdir\setup\hcl-cache\cache_cfg-ext.yaml
configuration file for editing.
If this file does not exist, create it using WCDE_installdir\setup\hcl-cache\cache_cfg.yaml as a template.
- Set the Redis enabled property to
false.
redis: enabled: false yamlConfig: "WCDE_installdir/setup/hcl-cache/redis/singleserver/redis_cfg.yaml"
- Save and close the file.
- Open the
WCDE_installdir\setup\hcl-cache\cache_cfg-ext.yaml
configuration file for editing.
- Optional: Enable the HCL Commerce Cache Manager application.