If you have a large number of sites, setting multiItemTypeMembershipsEnabled to true makes it possible to store site membership information more efficiently.

For example, suppose you have created a storeConfiguration item type and a storeGroup item type. If multiItemTypeMembershipsEnabled is false and you have 1000 different stores in the store group storeGroupUS, the siteIds property of a product available at all of the stores in this store group would list all 1000 stores individually. A lookup query would need to check the database records of all 1000 stores to determine that the product is associated with each store.

However, if multiItemTypeMembershipsEnabled is true, a product available at all of the stores in storeGroupUS only needs to list that store group in its siteIds property instead of listing the individual store IDs. A lookup query could then perform a single check to determine if a given product is associated with all the stores in storeGroupUS.

For example, suppose you are in a store whose repository ID is store500, and you look up products whose displayName property contains the word “table.” The request goes through SiteContextPipeLineServlet, which detects that the SiteContext of the request is store500. SiteContextPipeLineServlet calls SiteContextManager, which invokes SiteMembershipManager to construct a membership list for the request.

SiteMembershipManager queries the Site Repository and determines that store500 is part of one store group, storeGroupUS. SiteMembershipManager also applies the prefixes specified in its prefixToItemDescriptorNameMap property to the Site Repository items it has found, and returns a membership list of [st:store500,stg:storeGroupUS]. The lookup query then uses this list in a filtering clause to restrict the results to products in store500 or storeGroupUS.


Copyright © 1997, 2016 Oracle and/or its affiliates. All rights reserved. Legal Notices