HCL Commerce Developer

Missing db2jcc4.jar library when starting HCL Commerce Developer

When installing and starting HCL Commerce Developer for the first time, you can encounter a missing database Java archive file (.jar).

Problem

When installing and starting HCL Commerce Developer, you can encounter a missing database Java archive file (.jar). This occurs when starting the Search server. The cause of this issue is unknown, but is most likely related to incorrect prerequisite software installation order or incorrect prerequisite software installation files.

Solution

Manually add the missing Java archive, and recreate your search index.
  1. Stop all test servers that are running, and close Rational Application Developer.
  2. Find the missing Java archive file, db2jcc4.jar, and place it into the correct directory.
    1. Open the WCDE_installdir\lib\db2\java\ directory.
    2. Make a copy of the db2jcc4.jar Java archive.
    3. Place the copy into the WAS_installdir\Liberty\usr\shared\resources\ directory.
  3. Run the setdbtype utility to set the development environment database type. For more information about setting the database type, see Changing the development database type by using the setdbtype command.
    setdbtype.bat db2 WCDE_installdir\lib\db2 mall db2inst1 passw0rd wcs wcs1 localhost 50000
  4. Recreate the search index. For more information on building the search index, see Building the HCL Commerce Search index.

    Navigate to the following URL in your browser, or use the curl utility to rebuild the search index:

    https://localhost:3738/solr/MC_10001_CatalogEntry_en_US/select?q=*
    curl --user spiuser:passw0rd --insecure -X POST https://localhost:443/wcs/resources/admin/index/dataImport/build?masterCatalogId=10001
  5. Start and test your development environment.
    1. Open Rational Application Developer.
    2. Clean and publish the Test Server project. Ensure that it starts cleanly and that the database connects.
    3. Clean and start the Search server.
    4. Clean and start the Store server.
    5. Open the storefront to ensure all store functionality displays and functions.
      https://localhost:8443/shop/en/myesite

Result

Upon replacing the required library, all of the servers within your development environment and your test store function as expected.