CWXFS1003E: Cannot determine core name based on the search profile – WebSphere Commerce V7 with FEP

We have just come across this error while working with a store migration based on Aurora, and its all because IBM moved data locations in files, and did not make it obvious this has been done with FEP6 for V7 of WebSphere Commerce

We had been building our new store on Aurora FEP5 we had migrated up from Version 6 of WebSphere Commerce and then have been working on replacing the current store model (consumerdirect) with the Aurora and SOLR based store model.  You will find that as you work with SOLR the wc-search.xml file will be something you use if you want to make any changes to your SOLR configuration, such as indexing new fields.  To do this there are two files

The main IBM file wc-search.xml in WC/xml/config/ catalog-fep

And your extension file wc-search.xml in WC/xml/config/ catalog-ext

Now we had started our configuration with exactly the same master catalogue that Aurora uses and in FEP5 in the main IBM wc-search.xml file they hold the information on the SOLR Cores that will be created for search.  This is used by the setupSearchIndex.bat command when it runs to create your entries under <path_to_dev_workspace>/search/solr/home that are used as the Cores that SOLR runs against.

The file entries that were there in FEP5 in the catalog-fep version, we were fine using them because our data lived in Master Catalogue 10001.  So we had not even really thought about them.

SOLR Core Configuration Entries in the IBM wc-search.xml file

SOLR Core Configuration Entries in the IBM wc-search.xml file

Now what happened when we updated to FEP6 is that the IBM wc-search.xml file then had those entries removed. And because we have realised that its always worth running the SetupSearchIndex.bat command after installing any fixes on SOLR or feature packs we now got this error when the script ran.

CWXFS1003E: Cannot determine core name based on the search profile

That was strange because everything had been working OK, until the feature pack.  And the features had installed fine.  We noticed then that the entry in wc-search.xml now looked like this

IBM wc-search.xml after FEP6

IBM wc-search.xml after FEP6

So this was the reason the command was failing no Cores were now defined but where had they gone, and why would IBM make this change?  Luckily we had another environment (it’s always a good idea to create a clean workspace when a feature pack comes out) we went and checked the files on there and in the catalog-ext version of wc-search.xml we found the cores defined.

We copied the entries across into the ext file for our new store thinking that would solve it but instead we now got this error on startup in systemout.log, which caused the environment to fail when starting

Caused by: CWXFR0031E: Failed to read the file “wc-search.xml” due to “cvc-complex-type.2.4.a: Invalid content was found starting with element ‘_config:cores’. One of ‘{““:profile, ““:queryMapping}’ is expected.”.

What we found was that we needed to copy in the config server section as well, as the error was indicating that we did not have the server configuration.  The reason for that is the server name=”myservername” section.  This is used by the Cores if you look at these files in your environment you may see one or more of these server configurations, they dictate how the commands such as preprocess will connect to the server and are required in the file for the XML to be valid when the application starts up.  If you do have more the one the cores themselves will tell you which serverName they are using so it’s easy to spot.

Complete list of entries from wc-server.xml in catalog-ext

Complete list of entries from wc-server.xml in catalog-ext


Leave a Reply

Your email address will not be published. Required fields are marked *