Class CacheKeyGeneratorImpl
java.lang.Object
de.hybris.platform.sap.productconfig.services.cache.impl.CacheKeyGeneratorImpl
- All Implemented Interfaces:
CacheKeyGenerator
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected static final Stringprotected static final Stringprotected static final Stringprotected static final Stringprotected static final Stringprotected static final Stringprotected static final Stringprotected static final Stringprotected static final Stringprotected static final Stringprotected static final Stringprotected static final String -
Constructor Summary
ConstructorsConstructorDescriptionCacheKeyGeneratorImpl(ProductConfigurationUserIdProvider userIdProvider, SessionService sessionService, CommonI18NService i18nService) -
Method Summary
Modifier and TypeMethodDescriptioncreateAnalyticsDataCacheKey(String configId) Creates a cache key for the analytics data cache regioncreateAnalyticsDataCacheKey(String configId, Map<String, String> ctxtAttributes) Creates a cache key for the analytics data cache regionprotected ProductConfigurationCacheKeycreateCacheKey(String configId, String typeCode) protected ProductConfigurationCacheKeyprotected ProductConfigurationCacheKeycreateCacheKeyWithoutUserKey(String productCode, String typeCode) createClassificationSystemCPQAttributesCacheKey(String productCode) Creates a cache key for the classification system CPQ attributes cache regioncreateConfigCacheKey(String configId) Creates a cache key for the configuration cache regioncreateConfigCacheKey(String configId, Map<String, String> ctxtAttributes) Creates a cache key for the configuration cache regioncreatePriceSummaryCacheKey(String configId) Creates cache key for price summary and uses the currency code from the commerce currency model to distinguish different currenciescreatePriceSummaryCacheKey(String configId, Map<String, String> ctxtAttributes) Creates a cache key for the price summary cache regionprotected Stringprotected CommonI18NServiceprotected SessionServiceprotected Stringprotected ProductConfigurationUserIdProviderprotected booleanvoidpopulateCacheKeyContextAttributes(Map<String, String> ctxtAttributes) Populates the map with all cache key components that depend on the current sessionContext, so a cache key for a given configId can re-created independently of the current session/thread context.prepareBasicCacheKeyMap(String configId) prepareBasicCacheKeyMap(String configId, Map<String, String> ctxtAttributes)
-
Field Details
-
NO_ACTIVE_TENANT
- See Also:
-
KEY_CONFIG_ID
- See Also:
-
KEY_PRODUCT_CODE
- See Also:
-
KEY_IS_SESSION_BOUND_TO_CONFIG
- See Also:
-
KEY_USER_ID
- See Also:
-
KEY_CURRENCY
- See Also:
-
TYPECODE_ANALYTICS_DATA
- See Also:
-
TYPECODE_PRICE_SUMMARY
- See Also:
-
TYPECODE_CONFIG
- See Also:
-
TYPECODE_CLASSIFICATION_SYSTEM_CPQ_ATTRIBUTES
- See Also:
-
KEY_TENANT_ID
- See Also:
-
KEY_IS_ANONYMOUS
- See Also:
-
-
Constructor Details
-
CacheKeyGeneratorImpl
public CacheKeyGeneratorImpl(ProductConfigurationUserIdProvider userIdProvider, SessionService sessionService, CommonI18NService i18nService)
-
-
Method Details
-
populateCacheKeyContextAttributes
Description copied from interface:CacheKeyGeneratorPopulates the map with all cache key components that depend on the current sessionContext, so a cache key for a given configId can re-created independently of the current session/thread context.- Specified by:
populateCacheKeyContextAttributesin interfaceCacheKeyGenerator- Parameters:
ctxtAttributes- context attribute map to populate
-
createPriceSummaryCacheKey
Creates cache key for price summary and uses the currency code from the commerce currency model to distinguish different currencies- Specified by:
createPriceSummaryCacheKeyin interfaceCacheKeyGenerator- Parameters:
configId- configuration id- Returns:
- the created cache key
-
createPriceSummaryCacheKey
public ProductConfigurationCacheKey createPriceSummaryCacheKey(String configId, Map<String, String> ctxtAttributes) Description copied from interface:CacheKeyGeneratorCreates a cache key for the price summary cache region- Specified by:
createPriceSummaryCacheKeyin interfaceCacheKeyGenerator- Parameters:
configId- configuration idctxtAttributes- context attributes- Returns:
- the created cache key
-
createAnalyticsDataCacheKey
Description copied from interface:CacheKeyGeneratorCreates a cache key for the analytics data cache region- Specified by:
createAnalyticsDataCacheKeyin interfaceCacheKeyGenerator- Parameters:
configId- configuration id- Returns:
- the created cache key
-
createAnalyticsDataCacheKey
public ProductConfigurationCacheKey createAnalyticsDataCacheKey(String configId, Map<String, String> ctxtAttributes) Description copied from interface:CacheKeyGeneratorCreates a cache key for the analytics data cache region- Specified by:
createAnalyticsDataCacheKeyin interfaceCacheKeyGenerator- Parameters:
configId- configuration idctxtAttributes- context attributes- Returns:
- the created cache key
-
createConfigCacheKey
Description copied from interface:CacheKeyGeneratorCreates a cache key for the configuration cache region- Specified by:
createConfigCacheKeyin interfaceCacheKeyGenerator- Parameters:
configId- configuration id- Returns:
- the created cache key
-
createConfigCacheKey
public ProductConfigurationCacheKey createConfigCacheKey(String configId, Map<String, String> ctxtAttributes) Description copied from interface:CacheKeyGeneratorCreates a cache key for the configuration cache region- Specified by:
createConfigCacheKeyin interfaceCacheKeyGenerator- Parameters:
configId- configuration idctxtAttributes- context attributes- Returns:
- the created cache key
-
createClassificationSystemCPQAttributesCacheKey
public ProductConfigurationCacheKey createClassificationSystemCPQAttributesCacheKey(String productCode) Description copied from interface:CacheKeyGeneratorCreates a cache key for the classification system CPQ attributes cache region- Specified by:
createClassificationSystemCPQAttributesCacheKeyin interfaceCacheKeyGenerator- Returns:
- the created cache key
-
createCacheKey
-
createCacheKey
-
prepareBasicCacheKeyMap
-
prepareBasicCacheKeyMap
-
getCurrencyIso
-
createCacheKeyWithoutUserKey
protected ProductConfigurationCacheKey createCacheKeyWithoutUserKey(String productCode, String typeCode) -
getTenantId
-
getUserIdProvider
-
getSessionService
-
isSessionBoundToConfiguration
protected boolean isSessionBoundToConfiguration() -
getI18NService
-