Showing posts with label WebSphere Commerce;WebSphere Commerce Search;WebSphere Commerce Solr Configuration. Show all posts
Showing posts with label WebSphere Commerce;WebSphere Commerce Search;WebSphere Commerce Solr Configuration. Show all posts

Monday, January 5, 2015

WebSphere Commerce Search Server Web Content Access Control File in a Clustered Environment




The file that is used is in the following location:

/usr/IBM/WebSphere/AppServer/v70/profiles/"instance name"/config/cells/cell01/applications/Search.ear/deployments/Search/Search-Solr.war/WEB-INF/ibm-web-ext.xml

<?xml version="1.0" encoding="UTF-8"?>
<web-ext xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://websphere.ibm.com/xml/ns/javaee"
    xsi:schemaLocation="http://websphere.ibm.com/xml/ns/javaee http://websphere.ibm.com/xml/ns/javaee/ibm-web-ext_1_0.xsd" version="1.0">
  <jsp-attribute name="reloadEnabled" value="true"/>
  <jsp-attribute name="reloadInterval" value="10"/>
  <reload-interval value="3"/>
  <enable-directory-browsing value="false"/>
  <enable-file-serving value="true"/>
  <enable-reloading value="false"/>
  <enable-serving-servlets-by-class-name value="false"/>
  <context-root uri="/solr"/>

</web-ext>

Checking WebSphere Commerce Search Server Configuration

Sometimes there is a need to retrieve the search server configuration information from a live server to validate the search configurations, here is a class could be used to do that:

The information displayed is retrieved from the following configuration files:

In Search project:
xml/config/com.ibm.commerce.catalog.ext/wc-search.xml
xml/config/com.ibm.commerce.catalog/wc-search.xml

public class SearchServerConfigInfo {

    public static String getAllSearchServerConfigsInfo() {
        final SolrSearchConfigurationRegistry catalogReg = SolrSearchConfigurationRegistry
                .getInstance("com.ibm.commerce.catalog");
        final Field f;
        final StringBuilder result = new StringBuilder();
        try {
            f = SolrSearchConfigurationRegistry.class.getDeclaredField("imapSolrSearchServerConfigByCoreName");
            f.setAccessible(true);
            final Map<String, SolrSearchServerConfig> coreSearchServerConfigMap = (Map<String, SolrSearchServerConfig>) f
                    .get(catalogReg);
            final Set<String> coreNames = coreSearchServerConfigMap.keySet();
            SolrSearchServerConfig searchConf;
            result.append("\n=== === ===\nSearch Configuration:\n--- --- ---\n");
            for (String coreName : coreNames) {
                searchConf = catalogReg.getSolrSearchServerConfiguration(coreName);

                if (searchConf != null) {
                    result.append("coreName:").append(coreName).append('\n');
                    String corePath = catalogReg.getCorePath(coreName);
                    result.append("corePath:").append(corePath).append('\n');
                    String masterCatalog = catalogReg.getMasterCatalog(coreName);
                    result.append("masterCatalog:").append(masterCatalog).append('\n');
                    String languageId = catalogReg.getLanguageId(coreName);
                    result.append("languageId:").append(languageId).append('\n');
                    String name = searchConf.getName();
                    result.append("name:").append(name).append('\n');

                    Map<String, String> searchServerConfMap = searchConf.getConfigParameters();
                    Set keys = searchServerConfMap.keySet();
                    result.append("parameters:[");
                    for (Object keyObject : keys) {
                        String key = (String) keyObject;
                        result.append("key=").append(key).append(',');
                        String val = searchServerConfMap.get(key);
                        result.append("value=").append(val).append(';');
                    }
                    result.append("]\n");

                    boolean isEmbeddedServer = searchConf.isEmbeddedServer();
                    result.append("isEmbeddedServer:").append(isEmbeddedServer).append('\n');

                    SolrSearchServerConfig.CommonHttpServerConfig httpServerConf = searchConf
                            .getCommonHttpServerConfig();
                    String url = httpServerConf.getURL();
                    result.append("url:").append(url).append('\n');

                    String reference = httpServerConf.getReference();
                    result.append("reference").append(reference).append('\n');
                }
                result.append("--- --- ---\n");
            }
        } catch (Exception e) {
            StringWriter sw = new StringWriter();
            PrintWriter pw = new PrintWriter(sw);
            e.printStackTrace(pw);
            result.append("\nSearch configuration was not able to be retrieved. Exception stack trace:\n");
            result.append(sw.toString());
        }
        return result.toString();
    }
}



The result:

=== === ===
Search Configuration:
--- --- ---
coreName:MC_11101_CatalogEntry_Unstructured_en_US
corePath:/MC_11101/en_US/CatalogEntry/unstructured
masterCatalog:11101
languageId:-1
name:AdvancedConfiguration
parameters:[]
isEmbeddedServer:false
url:http://localhost:10080/solr
referencecom.ibm.commerce.foundation.server.services.search.url
--- --- ---
coreName:MC_11101_CatalogGroup_en_US
corePath:/MC_11101/en_US/CatalogGroup
masterCatalog:11101
languageId:-1
name:AdvancedConfiguration
parameters:[]
isEmbeddedServer:false
url:http://localhost:10080/solr
referencecom.ibm.commerce.foundation.server.services.search.url
--- --- ---
coreName:MC_11101_CatalogEntry_Inventory_generic
corePath:/MC_11101/generic/CatalogEntry/Inventory
masterCatalog:10751
languageId:-1
name:AdvancedConfiguration
parameters:[]
isEmbeddedServer:false
url:http://localhost:10080/solr
referencecom.ibm.commerce.foundation.server.services.search.url
--- --- ---
coreName:MC_11101_CatalogEntry_en_US
corePath:/MC_11101/en_US/CatalogEntry
masterCatalog:11101
languageId:-1
name:AdvancedConfiguration
parameters:[]
isEmbeddedServer:false
url:http://localhost:10080/solr
referencecom.ibm.commerce.foundation.server.services.search.url
--- --- ---

Retrieving Search Profiles from WebSphere Commerce Search Server

Sometimes there is a need to retrieve the search profile information from a live server to verify the search configurations, here is a class could be used to do that:

The information displayed is retrieved from the following configuration files:

In Search project:
xml/config/com.ibm.commerce.catalog.ext/wc-search.xml
xml/config/com.ibm.commerce.catalog/wc-search.xml

In Search-Rest project:
WEB-INF/config/com.ibm.commerce.rest-ext/wc-rest-resourceconfig.xml
WEB-INF/config/com.ibm.commerce.rest/wc-rest-resourceconfig.xml

public class SearchProfileInfo {
    public static String getAllProfilesInfo() {
        final ResourceConfigManager resourceConfigManager = ResourceConfigManager.getInstance();
        final Field aField;
        final Map<String, Map<String, Object>> coreResourceMap;
        final StringBuilder result = new StringBuilder();
        try {
            aField = ResourceConfigManager.class.getDeclaredField("searchProfileMappings");
            aField.setAccessible(true);
            coreResourceMap = (Map<String, Map<String, Object>>) aField.get(resourceConfigManager);
            final Set<String> coreNames = coreResourceMap.keySet();
            result.append("\n=== === ===\nSearch Profiles:\n--- --- ---\n");
            for (String coreName : coreNames) {
                Map<String, Object> resourceMap = coreResourceMap.get(coreName);
                Set<String> resourceUrls = resourceMap.keySet();
                for (String path : resourceUrls) {
                    String profileName = resourceConfigManager.getSearchProfile(coreName, path);
                    result.append("coreName:").append(coreName).append('\n');
                    result.append("urlPattern:").append(path).append('\n');
                    result.append("profileName:").append(profileName).append('\n');

                    SolrSearchProfileConfig profileConfig = SolrSearchConfigurationRegistry.getInstance()
                            .getSolrSearchProfileConfiguration(profileName);
                    result.append("profileDetails:").append(profileConfig.toString()).append('\n');
                }
                result.append("--- --- ---\n");
            }
        } catch (Exception e) {
            StringWriter sw = new StringWriter();
            PrintWriter pw = new PrintWriter(sw);
            e.printStackTrace(pw);
            result.append("\nSearch Profiles were not able to be retrieved. Exception stack trace:\n");
            result.append(sw.toString());
        }
        return result.toString();
    }
}

Result:

=== === ===
Search Profiles:
--- --- ---
coreName:sitecontent
urlPattern:categorySuggestions
profileName:IBM_findNavigationSuggestion_Categories
profileDetails:[name:IBM_findNavigationSuggestion_Categories, parent:null, index:CatalogGroup, parameters:{maxRows=500}, query:[inherits:true, parameters:{maxRows=500}, fields:{}, providers:[com.ibm.commerce.foundation.server.services.rest.search.expression.solr.SolrRESTSearchByStorePathExpressionProvider, com.ibm.commerce.foundation.server.services.rest.search.expression.solr.SolrRESTSearchByCatalogExpressionProvider, com.ibm.commerce.foundation.server.services.rest.search.expression.solr.SolrRESTSearchByPublishedEntryOnlyExpressionProvider, com.ibm.commerce.foundation.server.services.rest.search.expression.solr.SolrRESTSearchByCustomExpressionProvider], providers(disabled):null, preprocessors:null, preprocessors(disabled):null, postprocessors:[com.ibm.commerce.foundation.server.services.rest.search.postprocessor.solr.SolrRESTSearchCategorySuggestionQueryPostprocessor], postprocessors(disabled):null], result:[inherits:true, fields:{}, filters:null, filters(disabled):null], highlight:null, facet:null, sort:[inherits:true, parameters:{}, fields:{1=name_ntk_cs asc}], group:null, heroproduct:null, spell:null, mapping:null, suggestion:null]
coreName:sitecontent
urlPattern:store/{storeId}/sitecontent/webContentsBySearchTerm/{searchTerm}
profileName:IBM_findWebContentsBySearchTerm
profileDetails:[name:IBM_findWebContentsBySearchTerm, parent:null, index:UnstructuredContent, parameters:{limit=5, maxRows=100}, query:[inherits:true, parameters:{maxRows=100}, fields:{tika_content=, name=, longdesc=, shortdesc=}, providers:[com.ibm.commerce.foundation.server.services.rest.search.expression.solr.SolrRESTSearchTermAssociationExpressionProvider, com.ibm.commerce.foundation.server.services.rest.search.expression.solr.SolrRESTSearchByKeywordRelevancyExpressionProvider, com.ibm.commerce.foundation.server.services.rest.search.expression.solr.SolrRESTSearchByCustomExpressionProvider, com.ibm.commerce.foundation.server.services.rest.search.expression.solr.SolrRESTSearchWebContentStoreInfoExpressionProvider], providers(disabled):null, preprocessors:null, preprocessors(disabled):null, postprocessors:[com.ibm.commerce.foundation.server.services.rest.search.postprocessor.solr.SolrRESTMainWebContentViewResultQueryPostprocessor], postprocessors(disabled):null], result:[inherits:true, fields:{}, filters:null, filters(disabled):null], highlight:[inherits:true, pre:, post:, parameters:{}, fields:{}], facet:[inherits:true, min:null, limit:null, sort:null, parameters:{}, converters:{}, category:{}], sort:[inherits:false, parameters:{}, fields:{1=name_ntk_cs asc, 2=mimetype asc}], group:null, heroproduct:null, spell:[inherits:true, parameters:{limit=5}], mapping:[inherits:true, parameters:{}], suggestion:null]
coreName:sitecontent
urlPattern:store/{storeId}/sitecontent/categorySuggestions
profileName:IBM_findNavigationSuggestion_Categories
profileDetails:[name:IBM_findNavigationSuggestion_Categories, parent:null, index:CatalogGroup, parameters:{maxRows=500}, query:[inherits:true, parameters:{maxRows=500}, fields:{}, providers:[com.ibm.commerce.foundation.server.services.rest.search.expression.solr.SolrRESTSearchByStorePathExpressionProvider, com.ibm.commerce.foundation.server.services.rest.search.expression.solr.SolrRESTSearchByCatalogExpressionProvider, com.ibm.commerce.foundation.server.services.rest.search.expression.solr.SolrRESTSearchByPublishedEntryOnlyExpressionProvider, com.ibm.commerce.foundation.server.services.rest.search.expression.solr.SolrRESTSearchByCustomExpressionProvider], providers(disabled):null, preprocessors:null, preprocessors(disabled):null, postprocessors:[com.ibm.commerce.foundation.server.services.rest.search.postprocessor.solr.SolrRESTSearchCategorySuggestionQueryPostprocessor], postprocessors(disabled):null], result:[inherits:true, fields:{}, filters:null, filters(disabled):null], highlight:null, facet:null, sort:[inherits:true, parameters:{}, fields:{1=name_ntk_cs asc}], group:null, heroproduct:null, spell:null, mapping:null, suggestion:null]
coreName:sitecontent
urlPattern:webContentsBySearchTerm/{searchTerm}
profileName:IBM_findWebContentsBySearchTerm
profileDetails:[name:IBM_findWebContentsBySearchTerm, parent:null, index:UnstructuredContent, parameters:{limit=5, maxRows=100}, query:[inherits:true, parameters:{maxRows=100}, fields:{tika_content=, name=, longdesc=, shortdesc=}, providers:[com.ibm.commerce.foundation.server.services.rest.search.expression.solr.SolrRESTSearchTermAssociationExpressionProvider, com.ibm.commerce.foundation.server.services.rest.search.expression.solr.SolrRESTSearchByKeywordRelevancyExpressionProvider, com.ibm.commerce.foundation.server.services.rest.search.expression.solr.SolrRESTSearchByCustomExpressionProvider, com.ibm.commerce.foundation.server.services.rest.search.expression.solr.SolrRESTSearchWebContentStoreInfoExpressionProvider], providers(disabled):null, preprocessors:null, preprocessors(disabled):null, postprocessors:[com.ibm.commerce.foundation.server.services.rest.search.postprocessor.solr.SolrRESTMainWebContentViewResultQueryPostprocessor], postprocessors(disabled):null], result:[inherits:true, fields:{}, filters:null, filters(disabled):null], highlight:[inherits:true, pre:, post:, parameters:{}, fields:{}], facet:[inherits:true, min:null, limit:null, sort:null, parameters:{}, converters:{}, category:{}], sort:[inherits:false, parameters:{}, fields:{1=name_ntk_cs asc, 2=mimetype asc}], group:null, heroproduct:null, spell:[inherits:true, parameters:{limit=5}], mapping:[inherits:true, parameters:{}], suggestion:null]
coreName:sitecontent
urlPattern:store/{storeId}/sitecontent/brandSuggestions
profileName:IBM_findNavigationSuggestion_Brands
profileDetails:[name:IBM_findNavigationSuggestion_Brands, parent:null, index:CatalogEntry, parameters:{searchType=12, limit=100, minCount=1, maxRows=0, sort=index}, query:[inherits:true, parameters:{searchType=12, maxRows=0}, fields:{}, providers:[com.ibm.commerce.foundation.server.services.rest.search.expression.solr.SolrRESTSearchByCategoryExpressionProvider, com.ibm.commerce.foundation.server.services.rest.search.expression.solr.SolrRESTSearchByStorePathExpressionProvider, com.ibm.commerce.foundation.server.services.rest.search.expression.solr.SolrRESTSearchByPublishedEntryOnlyExpressionProvider, com.ibm.commerce.foundation.server.services.rest.search.expression.solr.SolrRESTSearchByCustomExpressionProvider, com.ibm.commerce.foundation.server.services.rest.search.expression.solr.SolrRESTSearchTypeExpressionProvider, com.ibm.commerce.foundation.server.services.rest.search.expression.solr.SolrRESTSearchProductEntitlementExpressionProvider], providers(disabled):null, preprocessors:null, preprocessors(disabled):null, postprocessors:[com.ibm.commerce.foundation.server.services.rest.search.postprocessor.solr.SolrRESTSearchBrandSuggestionQueryPostprocessor], postprocessors(disabled):null], result:null, highlight:null, facet:[inherits:true, min:null, limit:null, sort:null, parameters:{limit=100, minCount=1, sort=index}, converters:{}, category:{}], sort:null, group:null, heroproduct:null, spell:null, mapping:null, suggestion:null]
coreName:sitecontent
urlPattern:brandSuggestions
profileName:IBM_findNavigationSuggestion_Brands
profileDetails:[name:IBM_findNavigationSuggestion_Brands, parent:null, index:CatalogEntry, parameters:{searchType=12, limit=100, minCount=1, maxRows=0, sort=index}, query:[inherits:true, parameters:{searchType=12, maxRows=0}, fields:{}, providers:[com.ibm.commerce.foundation.server.services.rest.search.expression.solr.SolrRESTSearchByCategoryExpressionProvider, com.ibm.commerce.foundation.server.services.rest.search.expression.solr.SolrRESTSearchByStorePathExpressionProvider, com.ibm.commerce.foundation.server.services.rest.search.expression.solr.SolrRESTSearchByPublishedEntryOnlyExpressionProvider, com.ibm.commerce.foundation.server.services.rest.search.expression.solr.SolrRESTSearchByCustomExpressionProvider, com.ibm.commerce.foundation.server.services.rest.search.expression.solr.SolrRESTSearchTypeExpressionProvider, com.ibm.commerce.foundation.server.services.rest.search.expression.solr.SolrRESTSearchProductEntitlementExpressionProvider], providers(disabled):null, preprocessors:null, preprocessors(disabled):null, postprocessors:[com.ibm.commerce.foundation.server.services.rest.search.postprocessor.solr.SolrRESTSearchBrandSuggestionQueryPostprocessor], postprocessors(disabled):null], result:null, highlight:null, facet:[inherits:true, min:null, limit:null, sort:null, parameters:{limit=100, minCount=1, sort=index}, converters:{}, category:{}], sort:null, group:null, heroproduct:null, spell:null, mapping:null, suggestion:null]
--- --- ---
coreName:categoryview
urlPattern:store/{storeId}/categoryview/@top
profileName:IBM_findSubCategories
profileDetails:[name:IBM_findSubCategories, parent:null, index:CatalogGroup, parameters:{}, query:[inherits:true, parameters:{}, fields:{parentCatgroup_id_facet=}, providers:[com.ibm.commerce.foundation.server.services.rest.search.expression.solr.SolrRESTSearchCategoryEntitlementExpressionProvider, com.ibm.commerce.foundation.server.services.rest.search.expression.solr.SolrRESTSearchByStorePathExpressionProvider, com.ibm.commerce.foundation.server.services.rest.search.expression.solr.SolrRESTSearchShallowCategoryExpressionProvider, com.ibm.commerce.foundation.server.services.rest.search.expression.solr.SolrRESTSearchByPublishedEntryOnlyExpressionProvider, com.ibm.commerce.foundation.server.services.rest.search.expression.solr.SolrRESTSearchCategorySequencingExpressionProvider], providers(disabled):null, preprocessors:null, preprocessors(disabled):null, postprocessors:[com.ibm.commerce.foundation.server.services.rest.search.postprocessor.solr.SolrRESTSearchCategoryEntitlementQueryPostprocessor, com.ibm.commerce.foundation.server.services.rest.search.postprocessor.solr.SolrRESTSearchChildCategoryEntitlementQueryPostprocessor, com.ibm.commerce.foundation.server.services.rest.search.postprocessor.solr.SolrRESTMainCatalogGroupViewResultQueryPostprocessor], postprocessors(disabled):null], result:[inherits:true, fields:{}, filters:null, filters(disabled):null], highlight:null, facet:null, sort:null, group:null, heroproduct:null, spell:null, mapping:null, suggestion:null]
coreName:categoryview
urlPattern:byIds
profileName:IBM_findCategoryByUniqueIds
profileDetails:[name:IBM_findCategoryByUniqueIds, parent:null, index:CatalogGroup, parameters:{maxRows=500}, query:[inherits:true, parameters:{maxRows=500}, fields:{catgroup_id=}, providers:[com.ibm.commerce.foundation.server.services.rest.search.expression.solr.SolrRESTSearchCategoryEntitlementExpressionProvider, com.ibm.commerce.foundation.server.services.rest.search.expression.solr.SolrRESTSearchByCatalogExpressionProvider, com.ibm.commerce.foundation.server.services.rest.search.expression.solr.SolrRESTSearchByStorePathExpressionProvider, com.ibm.commerce.foundation.server.services.rest.search.expression.solr.SolrRESTSearchByIdentifierExpressionProvider, com.ibm.commerce.foundation.server.services.rest.search.expression.solr.SolrRESTSearchByPublishedEntryOnlyExpressionProvider], providers(disabled):null, preprocessors:null, preprocessors(disabled):null, postprocessors:[com.ibm.commerce.foundation.server.services.rest.search.postprocessor.solr.SolrRESTSearchChildCategoryEntitlementQueryPostprocessor, com.ibm.commerce.foundation.server.services.rest.search.postprocessor.solr.SolrRESTMainCatalogGroupViewResultQueryPostprocessor], postprocessors(disabled):null], result:[inherits:true, fields:{}, filters:null, filters(disabled):null], highlight:null, facet:null, sort:null, group:null, heroproduct:null, spell:null, mapping:null, suggestion:null]
coreName:categoryview
urlPattern:store/{storeId}/categoryview/byParentCategory/{parentCategoryId}
profileName:IBM_findSubCategories
profileDetails:[name:IBM_findSubCategories, parent:null, index:CatalogGroup, parameters:{}, query:[inherits:true, parameters:{}, fields:{parentCatgroup_id_facet=}, providers:[com.ibm.commerce.foundation.server.services.rest.search.expression.solr.SolrRESTSearchCategoryEntitlementExpressionProvider, com.ibm.commerce.foundation.server.services.rest.search.expression.solr.SolrRESTSearchByStorePathExpressionProvider, com.ibm.commerce.foundation.server.services.rest.search.expression.solr.SolrRESTSearchShallowCategoryExpressionProvider, com.ibm.commerce.foundation.server.services.rest.search.expression.solr.SolrRESTSearchByPublishedEntryOnlyExpressionProvider, com.ibm.commerce.foundation.server.services.rest.search.expression.solr.SolrRESTSearchCategorySequencingExpressionProvider], providers(disabled):null, preprocessors:null, preprocessors(disabled):null, postprocessors:[com.ibm.commerce.foundation.server.services.rest.search.postprocessor.solr.SolrRESTSearchCategoryEntitlementQueryPostprocessor, com.ibm.commerce.foundation.server.services.rest.search.postprocessor.solr.SolrRESTSearchChildCategoryEntitlementQueryPostprocessor, com.ibm.commerce.foundation.server.services.rest.search.postprocessor.solr.SolrRESTMainCatalogGroupViewResultQueryPostprocessor], postprocessors(disabled):null], result:[inherits:true, fields:{}, filters:null, filters(disabled):null], highlight:null, facet:null, sort:null, group:null, heroproduct:null, spell:null, mapping:null, suggestion:null]
coreName:categoryview
urlPattern:@top
profileName:IBM_findSubCategories
profileDetails:[name:IBM_findSubCategories, parent:null, index:CatalogGroup, parameters:{}, query:[inherits:true, parameters:{}, fields:{parentCatgroup_id_facet=}, providers:[com.ibm.commerce.foundation.server.services.rest.search.expression.solr.SolrRESTSearchCategoryEntitlementExpressionProvider, com.ibm.commerce.foundation.server.services.rest.search.expression.solr.SolrRESTSearchByStorePathExpressionProvider, com.ibm.commerce.foundation.server.services.rest.search.expression.solr.SolrRESTSearchShallowCategoryExpressionProvider, com.ibm.commerce.foundation.server.services.rest.search.expression.solr.SolrRESTSearchByPublishedEntryOnlyExpressionProvider, com.ibm.commerce.foundation.server.services.rest.search.expression.solr.SolrRESTSearchCategorySequencingExpressionProvider], providers(disabled):null, preprocessors:null, preprocessors(disabled):null, postprocessors:[com.ibm.commerce.foundation.server.services.rest.search.postprocessor.solr.SolrRESTSearchCategoryEntitlementQueryPostprocessor, com.ibm.commerce.foundation.server.services.rest.search.postprocessor.solr.SolrRESTSearchChildCategoryEntitlementQueryPostprocessor, com.ibm.commerce.foundation.server.services.rest.search.postprocessor.solr.SolrRESTMainCatalogGroupViewResultQueryPostprocessor], postprocessors(disabled):null], result:[inherits:true, fields:{}, filters:null, filters(disabled):null], highlight:null, facet:null, sort:null, group:null, heroproduct:null, spell:null, mapping:null, suggestion:null]
coreName:categoryview
urlPattern:store/{storeId}/categoryview/byIds
profileName:IBM_findCategoryByUniqueIds
profileDetails:[name:IBM_findCategoryByUniqueIds, parent:null, index:CatalogGroup, parameters:{maxRows=500}, query:[inherits:true, parameters:{maxRows=500}, fields:{catgroup_id=}, providers:[com.ibm.commerce.foundation.server.services.rest.search.expression.solr.SolrRESTSearchCategoryEntitlementExpressionProvider, com.ibm.commerce.foundation.server.services.rest.search.expression.solr.SolrRESTSearchByCatalogExpressionProvider, com.ibm.commerce.foundation.server.services.rest.search.expression.solr.SolrRESTSearchByStorePathExpressionProvider, com.ibm.commerce.foundation.server.services.rest.search.expression.solr.SolrRESTSearchByIdentifierExpressionProvider, com.ibm.commerce.foundation.server.services.rest.search.expression.solr.SolrRESTSearchByPublishedEntryOnlyExpressionProvider], providers(disabled):null, preprocessors:null, preprocessors(disabled):null, postprocessors:[com.ibm.commerce.foundation.server.services.rest.search.postprocessor.solr.SolrRESTSearchChildCategoryEntitlementQueryPostprocessor, com.ibm.commerce.foundation.server.services.rest.search.postprocessor.solr.SolrRESTMainCatalogGroupViewResultQueryPostprocessor], postprocessors(disabled):null], result:[inherits:true, fields:{}, filters:null, filters(disabled):null], highlight:null, facet:null, sort:null, group:null, heroproduct:null, spell:null, mapping:null, suggestion:null]
coreName:categoryview
urlPattern:byId/{categoryId}
profileName:IBM_findCategoryByUniqueIds
profileDetails:[name:IBM_findCategoryByUniqueIds, parent:null, index:CatalogGroup, parameters:{maxRows=500}, query:[inherits:true, parameters:{maxRows=500}, fields:{catgroup_id=}, providers:[com.ibm.commerce.foundation.server.services.rest.search.expression.solr.SolrRESTSearchCategoryEntitlementExpressionProvider, com.ibm.commerce.foundation.server.services.rest.search.expression.solr.SolrRESTSearchByCatalogExpressionProvider, com.ibm.commerce.foundation.server.services.rest.search.expression.solr.SolrRESTSearchByStorePathExpressionProvider, com.ibm.commerce.foundation.server.services.rest.search.expression.solr.SolrRESTSearchByIdentifierExpressionProvider, com.ibm.commerce.foundation.server.services.rest.search.expression.solr.SolrRESTSearchByPublishedEntryOnlyExpressionProvider], providers(disabled):null, preprocessors:null, preprocessors(disabled):null, postprocessors:[com.ibm.commerce.foundation.server.services.rest.search.postprocessor.solr.SolrRESTSearchChildCategoryEntitlementQueryPostprocessor, com.ibm.commerce.foundation.server.services.rest.search.postprocessor.solr.SolrRESTMainCatalogGroupViewResultQueryPostprocessor], postprocessors(disabled):null], result:[inherits:true, fields:{}, filters:null, filters(disabled):null], highlight:null, facet:null, sort:null, group:null, heroproduct:null, spell:null, mapping:null, suggestion:null]
coreName:categoryview
urlPattern:store/{storeId}/categoryview/{categoryIdentifier}
profileName:IBM_findCategoryByIdentifier
profileDetails:[name:IBM_findCategoryByIdentifier, parent:null, index:CatalogGroup, parameters:{}, query:[inherits:true, parameters:{}, fields:{identifier_ntk=}, providers:[com.ibm.commerce.foundation.server.services.rest.search.expression.solr.SolrRESTSearchCategoryEntitlementExpressionProvider, com.ibm.commerce.foundation.server.services.rest.search.expression.solr.SolrRESTSearchByCatalogExpressionProvider, com.ibm.commerce.foundation.server.services.rest.search.expression.solr.SolrRESTSearchByStorePathExpressionProvider, com.ibm.commerce.foundation.server.services.rest.search.expression.solr.SolrRESTSearchByIdentifierExpressionProvider, com.ibm.commerce.foundation.server.services.rest.search.expression.solr.SolrRESTSearchByPublishedEntryOnlyExpressionProvider], providers(disabled):null, preprocessors:null, preprocessors(disabled):null, postprocessors:[com.ibm.commerce.foundation.server.services.rest.search.postprocessor.solr.SolrRESTSearchChildCategoryEntitlementQueryPostprocessor, com.ibm.commerce.foundation.server.services.rest.search.postprocessor.solr.SolrRESTMainCatalogGroupViewResultQueryPostprocessor], postprocessors(disabled):null], result:[inherits:true, fields:{}, filters:null, filters(disabled):null], highlight:null, facet:null, sort:null, group:null, heroproduct:null, spell:null, mapping:null, suggestion:null]
coreName:categoryview
urlPattern:store/{storeId}/categoryview/byId/{categoryId}
profileName:IBM_findCategoryByUniqueIds
profileDetails:[name:IBM_findCategoryByUniqueIds, parent:null, index:CatalogGroup, parameters:{maxRows=500}, query:[inherits:true, parameters:{maxRows=500}, fields:{catgroup_id=}, providers:[com.ibm.commerce.foundation.server.services.rest.search.expression.solr.SolrRESTSearchCategoryEntitlementExpressionProvider, com.ibm.commerce.foundation.server.services.rest.search.expression.solr.SolrRESTSearchByCatalogExpressionProvider, com.ibm.commerce.foundation.server.services.rest.search.expression.solr.SolrRESTSearchByStorePathExpressionProvider, com.ibm.commerce.foundation.server.services.rest.search.expression.solr.SolrRESTSearchByIdentifierExpressionProvider, com.ibm.commerce.foundation.server.services.rest.search.expression.solr.SolrRESTSearchByPublishedEntryOnlyExpressionProvider], providers(disabled):null, preprocessors:null, preprocessors(disabled):null, postprocessors:[com.ibm.commerce.foundation.server.services.rest.search.postprocessor.solr.SolrRESTSearchChildCategoryEntitlementQueryPostprocessor, com.ibm.commerce.foundation.server.services.rest.search.postprocessor.solr.SolrRESTMainCatalogGroupViewResultQueryPostprocessor], postprocessors(disabled):null], result:[inherits:true, fields:{}, filters:null, filters(disabled):null], highlight:null, facet:null, sort:null, group:null, heroproduct:null, spell:null, mapping:null, suggestion:null]
coreName:categoryview
urlPattern:{categoryIdentifier}
profileName:IBM_findCategoryByIdentifier
profileDetails:[name:IBM_findCategoryByIdentifier, parent:null, index:CatalogGroup, parameters:{}, query:[inherits:true, parameters:{}, fields:{identifier_ntk=}, providers:[com.ibm.commerce.foundation.server.services.rest.search.expression.solr.SolrRESTSearchCategoryEntitlementExpressionProvider, com.ibm.commerce.foundation.server.services.rest.search.expression.solr.SolrRESTSearchByCatalogExpressionProvider, com.ibm.commerce.foundation.server.services.rest.search.expression.solr.SolrRESTSearchByStorePathExpressionProvider, com.ibm.commerce.foundation.server.services.rest.search.expression.solr.SolrRESTSearchByIdentifierExpressionProvider, com.ibm.commerce.foundation.server.services.rest.search.expression.solr.SolrRESTSearchByPublishedEntryOnlyExpressionProvider], providers(disabled):null, preprocessors:null, preprocessors(disabled):null, postprocessors:[com.ibm.commerce.foundation.server.services.rest.search.postprocessor.solr.SolrRESTSearchChildCategoryEntitlementQueryPostprocessor, com.ibm.commerce.foundation.server.services.rest.search.postprocessor.solr.SolrRESTMainCatalogGroupViewResultQueryPostprocessor], postprocessors(disabled):null], result:[inherits:true, fields:{}, filters:null, filters(disabled):null], highlight:null, facet:null, sort:null, group:null, heroproduct:null, spell:null, mapping:null, suggestion:null]
coreName:categoryview
urlPattern:byParentCategory/{parentCategoryId}
profileName:IBM_findSubCategories
profileDetails:[name:IBM_findSubCategories, parent:null, index:CatalogGroup, parameters:{}, query:[inherits:true, parameters:{}, fields:{parentCatgroup_id_facet=}, providers:[com.ibm.commerce.foundation.server.services.rest.search.expression.solr.SolrRESTSearchCategoryEntitlementExpressionProvider, com.ibm.commerce.foundation.server.services.rest.search.expression.solr.SolrRESTSearchByStorePathExpressionProvider, com.ibm.commerce.foundation.server.services.rest.search.expression.solr.SolrRESTSearchShallowCategoryExpressionProvider, com.ibm.commerce.foundation.server.services.rest.search.expression.solr.SolrRESTSearchByPublishedEntryOnlyExpressionProvider, com.ibm.commerce.foundation.server.services.rest.search.expression.solr.SolrRESTSearchCategorySequencingExpressionProvider], providers(disabled):null, preprocessors:null, preprocessors(disabled):null, postprocessors:[com.ibm.commerce.foundation.server.services.rest.search.postprocessor.solr.SolrRESTSearchCategoryEntitlementQueryPostprocessor, com.ibm.commerce.foundation.server.services.rest.search.postprocessor.solr.SolrRESTSearchChildCategoryEntitlementQueryPostprocessor, com.ibm.commerce.foundation.server.services.rest.search.postprocessor.solr.SolrRESTMainCatalogGroupViewResultQueryPostprocessor], postprocessors(disabled):null], result:[inherits:true, fields:{}, filters:null, filters(disabled):null], highlight:null, facet:null, sort:null, group:null, heroproduct:null, spell:null, mapping:null, suggestion:null]
--- --- ---
...

Tuesday, December 30, 2014

Debugging Catalog Filtering with Contracts

If the catalog filter does not work as expected, do the following checks:

Turn on the logs on the class SolrRESTSearchProductEntiltementExpressionProvider and check what the getExpression method returns:

Check if the expected expression has been created:

select EXPRESSION_ID, TRADING_ID, CATFILTER_ID, MEMBER_ID, cast(QUERY as varchar(1000)) from EXPRESSION

Check what contract ids are returned from the following queries:

Active reseller contracts belong to user_id, org_id or default
SELECT T.trading_id, T.account_id, T.starttime, T.endtime FROM PARTICIPNT P, TRADING T, STORECNTR S WHERE T.trading_id = P.trading_id and T.trading_id = S.contract_id 
and S.store_id =?store_id?  and P.partrole_id = 2 and P.termcond_id is null and (P.member_id = ?member_id? or P.member_id = ?org_id? or P.member_id is null) and T.state = 1 
and T.markfordelete = 0 

Active reseller contracts belong to all ancestor org of this org
SELECT T.trading_id, T.account_id, T.starttime,  T.endtime FROM PARTICIPNT P, TRADING T, STORECNTR S, mbrrel M WHERE T.trading_id = P.trading_id and T.trading_id = S.contract_id and S.store_id = ?store_id? and P.partrole_id = 2 and P.termcond_id is null and P.member_id = M.ancestor_id and M.descendant_id = ?org_id? and T.state = 1 and T.markfordelete = 0 

Active reseller contracts belong to the member group of this user
SELECT T.trading_id, T.account_id,  T.starttime, T.endtime FROM PARTICIPNT P, TRADING T, STORECNTR S, mbrgrpmbr M WHERE T.trading_id = P.trading_id and T.trading_id = S.contract_id and S.store_id = ?store_id? and P.partrole_id = 2 and P.termcond_id is null and P.member_id = M.mbrgrp_id and M.member_id = ?member_id? and M.exclude='0' and T.state = 1 and T.markfordelete = 0 

Check the following tables with more details:

select * from CONTRACT;
select * from TRADING;
select * from CATFILTER;
select * from PRODUCTSET;
select * from PRSETCEREL;

Check if the productset temporary table is correctly populated by the di-preprocess script:

SELECT * FROM TI_PRODUCTSET_0 where catentry_id in (?)

SELECT PRSETCEREL.CATENTRY_ID, PRODUCTSET.PRODUCTSET_ID  
FROM PRSETCEREL, PRODUCTSET, TI_CATENTRY_0  CE
WHERE PRODUCTSET.PRODUCTSET_ID = PRSETCEREL.PRODUCTSET_ID  
AND PRODUCTSET.MARKFORDELETE = 0  
AND PRSETCEREL.CATENTRY_ID=CE.CATENTRY_ID
ORDER BY CATENTRY_ID

Check if the product is properly indexed:

select * from TI_CATENTRY_0 where catentry_id in (1000005836, 1000005837)

SELECT DISTINCT CATENTRY.CATENTRY_ID, CATENTRY.CATENTTYPE_ID FROM CATENTRY, CATGPENREL WHERE CATENTRY.MARKFORDELETE=0 AND CATENTRY.CATENTRY_ID=CATGPENREL.CATENTRY_ID AND CATGPENREL.CATALOG_ID=11101 order by catentry.catentry_id;

Check if the query populated the PRODUCTSET with the expected productset id:

SELECT 
CATENTRY.CATENTRY_ID,CATENTRY.MEMBER_ID,CATENTRY.CATENTTYPE_ID,CATENTRY.PARTNUMBER,CATENTRY.MFPARTNUMBER,
CATENTRY.MFNAME, CATENTRY.BUYABLE, CATENTRY.STARTDATE, CATENTRY.ENDDATE,STORECENT.STOREENT_ID,
CATENTDESC.NAME,CATENTDESC.SHORTDESCRIPTION,CATENTDESC.LONGDESCRIPTION,CATENTDESC.THUMBNAIL,CATENTDESC.FULLIMAGE,
CATENTDESC.KEYWORD, CATENTDESC.PUBLISHED,CATENTSUBS.SUBSCPTYPE_ID,CATENTSUBS.DISALLOW_REC_ORDER,
TI_APGROUP.CATGROUPS APCATGROUP,
TI_APGROUP.CATPATHS APCATPATH,
TI_DPGROUP.CATGROUP DPCATGROUP,
TI_PRODUCTSET.PRODUCTSET,
TI_OFFERPRICE.PRICE_USD, TI_OFFERPRICE.PRICE_EUR, TI_OFFERPRICE.PRICE_CAD, TI_OFFERPRICE.PRICE_CNY,
TI_OFFERPRICE.PRICE_JPY, TI_OFFERPRICE.PRICE_KRW, TI_OFFERPRICE.PRICE_BRL, TI_OFFERPRICE.PRICE_TWD,
TI_OFFERPRICE.PRICE_PLN, TI_OFFERPRICE.PRICE_RUB, TI_OFFERPRICE.PRICE_RON, TI_OFFERPRICE.PRICE_EGP,
TI_OFFERPRICE.PRICE_GBP, TI_OFFERPRICE.PRICE_TRY, TI_OFFERPRICE.PRICE_ILS,
TI_LISTPRICE.LISTPRICE_USD, TI_LISTPRICE.LISTPRICE_EUR, TI_LISTPRICE.LISTPRICE_CAD, TI_LISTPRICE.LISTPRICE_CNY,
TI_LISTPRICE.LISTPRICE_JPY, TI_LISTPRICE.LISTPRICE_KRW, TI_LISTPRICE.LISTPRICE_BRL, TI_LISTPRICE.LISTPRICE_TWD,
TI_LISTPRICE.LISTPRICE_PLN, TI_LISTPRICE.LISTPRICE_RUB, TI_LISTPRICE.LISTPRICE_RON, TI_LISTPRICE.LISTPRICE_EGP,
TI_LISTPRICE.LISTPRICE_GBP, TI_LISTPRICE.LISTPRICE_TRY, TI_LISTPRICE.LISTPRICE_ILS,
TI_ADATTR.ATTRIBUTES CATENTRY_ATTRIBUTES,
TI_DPCATENTRY.CATENTRY_PARENT,
TI_GROUPING.GROUPING,
TI_COMPONENTS.COMPONENTS CATENTRY_COMPONENTS,
TI_DCCATENTRY.CATENTRY_CHILD,
TI_CATALOG.CATALOG PARENT_CATALOG_ID,
TI_CATGPENREL.SEQUENCE CATENTRY_SEQUENCE,
TI_ENTGRPPATH.ENTGRPPATH,
TI_SEOURL.SEO_TOKEN,
TI_CATENTDESCOVR.NAME_OVR, TI_CATENTDESCOVR.SHORTDESC_OVR, TI_CATENTDESCOVR.KEYWORD_OVR, TI_CATENTDESCOVR.PUBLISHED_OVR,
TI_DPGRPNAME.CATGRPNAME CATGRPNAME,
TI_CASTB1.CAS_F1 CAS_F1ATTR, TI_CASTB1.CAS_F2 CAS_F2ATTR, TI_CASTB1.CAS_F3 CAS_F3ATTR,TI_CASTB1.CAS_F4 CAS_F4ATTR,TI_CASTB1.CAS_F5 CAS_F5ATTR,
TI_CASTB1.CAS_F6 CAS_F6ATTR,TI_CASTB1.CAS_F7 CAS_F7ATTR, TI_CASTB1.CAS_F8 CAS_F8ATTR,TI_CASTB1.CAS_F9 CAS_F9ATTR,TI_CASTB1.CAS_F10 CAS_F10ATTR,
TI_CASTB1.CAS_F11 CAS_F11ATTR,TI_CASTB1.CAS_F12 CAS_F12ATTR,TI_CASTB1.CAS_F13 CAS_F13ATTR,TI_CASTB1.CAS_F14 CAS_F14ATTR,TI_CASTB1.CAS_F15 CAS_F15ATTR,
TI_CASTB1.CAS_F16 CAS_F16ATTR,TI_CASTB1.CAS_F17 CAS_F17ATTR, TI_CASTB1.CAS_F18 CAS_F18ATTR,TI_CASTB1.CAS_F19 CAS_F19ATTR,TI_CASTB1.CAS_F20 CAS_F20ATTR,
TI_CASTB1.CAS_F21 CAS_F21ATTR,TI_CASTB1.CAS_F22 CAS_F22ATTR,TI_CASTB1.CAS_F23 CAS_F23ATTR,TI_CASTB1.CAS_F24 CAS_F24ATTR,TI_CASTB1.CAS_F25  CAS_F25ATTR,
TI_CASTB1.CAS_F26  CAS_F26ATTR,TI_CASTB1.CAS_F27  CAS_F27ATTR,TI_CASTB1.CAS_F28  CAS_F28ATTR,TI_CASTB1.CAS_F29  CAS_F29ATTR,TI_CASTB1.CAS_F30  CAS_F30ATTR,
TI_CAITB1.CAI_F1, TI_CAITB1.CAI_F2, TI_CAITB1.CAI_F3, TI_CAITB1.CAI_F4, TI_CAITB1.CAI_F5, TI_CAITB1.CAI_F6, TI_CAITB1.CAI_F7, TI_CAITB1.CAI_F8, TI_CAITB1.CAI_F9, TI_CAITB1.CAI_F10,
TI_CAFTB1.CAF_F1, TI_CAFTB1.CAF_F2, TI_CAFTB1.CAF_F3, TI_CAFTB1.CAF_F4, TI_CAFTB1.CAF_F5, TI_CAFTB1.CAF_F6, TI_CAFTB1.CAF_F7, TI_CAFTB1.CAF_F8, TI_CAFTB1.CAF_F9, TI_CAFTB1.CAF_F10,
TI_ATTR.ATTRS ATTRS,
TI_ATTR.ATTRI ATTRI,
TI_ATTR.ATTRF ATTRF,
TI_ATTR.SRCHS SRCHS,
TI_ATTR.SRCHI SRCHI,
TI_ATTR.SRCHF SRCHF,
XCATENTRYWC.DISPPRICEINCARTONLY,
XCATENTRYWC.SEARCHABLE,
XCATENTRYOMSDESC.BVRATING,
XCATENTRYOMSDESC.BVNUMBEROFRATING,
XSEARCHABLEPRODUCTS.IN_STOCK,
XSEARCHABLEPRODUCTS.FSA,
XSEARCHABLEPRODUCTS.PURCHASABLE,
CATENTDESC.AUXDESCRIPTION1,
CATENTDESC.AUXDESCRIPTION2
FROM CATENTRY
INNER JOIN TI_CATENTRY_0 TI_CATENTRY ON (CATENTRY.CATENTRY_ID=TI_CATENTRY.CATENTRY_ID)
LEFT OUTER JOIN STORECENT ON (CATENTRY.CATENTRY_ID=STORECENT.CATENTRY_ID)
LEFT OUTER JOIN CATENTDESC ON (CATENTDESC.CATENTRY_ID=CATENTRY.CATENTRY_ID AND CATENTDESC.LANGUAGE_ID=-1)
LEFT OUTER JOIN CATENTSUBS ON (CATENTSUBS.CATENTRY_ID=CATENTRY.CATENTRY_ID)
LEFT OUTER JOIN TI_DPGROUP_0 TI_DPGROUP ON (CATENTRY.CATENTRY_ID=TI_DPGROUP.CATENTRY_ID)
LEFT OUTER JOIN TI_DPGRPNAME_0_1 TI_DPGRPNAME ON (CATENTRY.CATENTRY_ID=TI_DPGRPNAME.CATENTRY_ID)
LEFT OUTER JOIN TI_APGROUP_0 TI_APGROUP ON (CATENTRY.CATENTRY_ID=TI_APGROUP.CATENTRY_ID)
LEFT OUTER JOIN TI_PRODUCTSET_0 TI_PRODUCTSET ON (CATENTRY.CATENTRY_ID=TI_PRODUCTSET.CATENTRY_ID)
LEFT OUTER JOIN TI_OFFERPRICE_0 TI_OFFERPRICE ON (CATENTRY.CATENTRY_ID=TI_OFFERPRICE.CATENTRY_ID)
LEFT OUTER JOIN TI_LISTPRICE_0 TI_LISTPRICE ON (CATENTRY.CATENTRY_ID=TI_LISTPRICE.CATENTRY_ID)
LEFT OUTER JOIN TI_DPCATENTRY_0 TI_DPCATENTRY ON (CATENTRY.CATENTRY_ID=TI_DPCATENTRY.CATENTRY_ID)
LEFT OUTER JOIN TI_GROUPING_0 TI_GROUPING ON (CATENTRY.CATENTRY_ID=TI_GROUPING.CATENTRY_ID)
LEFT OUTER JOIN TI_COMPONENTS_0 TI_COMPONENTS ON (CATENTRY.CATENTRY_ID=TI_COMPONENTS.CATENTRY_ID)
LEFT OUTER JOIN TI_DCCATENTRY_0 TI_DCCATENTRY ON (CATENTRY.CATENTRY_ID=TI_DCCATENTRY.CATENTRY_ID)
LEFT OUTER JOIN TI_CATALOG_0 TI_CATALOG ON (CATENTRY.CATENTRY_ID=TI_CATALOG.CATENTRY_ID)
LEFT OUTER JOIN TI_CATGPENREL_0 TI_CATGPENREL ON (CATENTRY.CATENTRY_ID=TI_CATGPENREL.CATENTRY_ID)
LEFT OUTER JOIN TI_ENTGRPPATH_0 TI_ENTGRPPATH ON (CATENTRY.CATENTRY_ID=TI_ENTGRPPATH.CATENTRY_ID)
LEFT OUTER JOIN TI_SEOURL_0_1 TI_SEOURL ON (CATENTRY.CATENTRY_ID=TI_SEOURL.CATENTRY_ID)
LEFT OUTER JOIN TI_CEDSOVR_0_1 TI_CATENTDESCOVR ON (CATENTRY.CATENTRY_ID=TI_CATENTDESCOVR.CATENTRY_ID)
LEFT OUTER JOIN TI_CASTB1_0_1 TI_CASTB1 ON (CATENTRY.CATENTRY_ID=TI_CASTB1.CATENTRY_ID)
LEFT OUTER JOIN TI_CAITB1_0_1 TI_CAITB1 ON (CATENTRY.CATENTRY_ID=TI_CAITB1.CATENTRY_ID)
LEFT OUTER JOIN TI_CAFTB1_0_1 TI_CAFTB1 ON (CATENTRY.CATENTRY_ID=TI_CAFTB1.CATENTRY_ID)
LEFT OUTER JOIN TI_ATTR_0_1 TI_ATTR ON (CATENTRY.CATENTRY_ID=TI_ATTR.CATENTRY_ID)
LEFT OUTER JOIN TI_ADATTR_0_1 TI_ADATTR ON (CATENTRY.CATENTRY_ID=TI_ADATTR.CATENTRY_ID)
LEFT OUTER JOIN XCATENTRYWC ON (CATENTRY.CATENTRY_ID=XCATENTRYWC.CATENTRY_ID)
LEFT OUTER JOIN XCATENTRYOMSDESC ON (CATENTRY.CATENTRY_ID=XCATENTRYOMSDESC.CATENTRY_ID)
LEFT OUTER JOIN XSEARCHABLEPRODUCTS ON (CATENTRY.CATENTRY_ID=XSEARCHABLEPRODUCTS.CATENTRY_ID)
WHERE  CATENTRY.CATENTTYPE_ID in ('ProductBean', 'ItemBean', 'PackageBean')

Check the Search ProductView Service accepts contract id and checkEntitlement flag properly:

http://localhost:80/search/resources/store/10001/productview/bySearchTerm/american?catalogId=20001&langId=-1&currency=USD&responseFormat=json&pageSize=12&pageNumber=1&profileName=findProductsBySearchTerm&checkEntitlement=true&contractId=30001&priceMode=mixed

Friday, December 19, 2014

RAD 8 Ant not start error

RAD 8 Ant not start error

The error message: 
Could not find the main class: =. Program will exit.

Solution:
Right click build.xml file, follow
Run As -> 2 Ant Build... (not the first choice 1 Ant Build)
Choose the JRE tab
In Runtime JRE: section, choose Run in the same JRE as the workspace