Class DeleteProductRelationshipEntitiesHandler

java.lang.Object
com.broadleafcommerce.catalog.messaging.DeleteProductRelationshipEntitiesHandler
All Implemented Interfaces:
com.broadleafcommerce.common.messaging.PersistenceHandler

@Deprecated(since="2.1.0", forRemoval=true) @DataRouteByExample(Product.class) public class DeleteProductRelationshipEntitiesHandler extends Object implements com.broadleafcommerce.common.messaging.PersistenceHandler
Deprecated, for removal: This API element is subject to removal in a future version.
since 2.1.0, in favor of CatalogEntityDeletedEventListener
Deletes the product relationship entities when a Product is deleted in production, by default this includes:
Author:
Sunny Yu
  • Constructor Summary

    Constructors
    Constructor
    Description
    DeleteProductRelationshipEntitiesHandler(CategoryProductService<CategoryProduct> categoryProductService, VariantService<Variant> variantService, ProductTagService<ProductTag> productTagService, PromotionalProductService<PromotionalProduct> promotionalProductService, ProductAssetService<ProductAsset> productAssetService, com.broadleafcommerce.translation.service.TranslationEntityService<com.broadleafcommerce.translation.domain.Translation> translationService, com.broadleafcommerce.data.tracking.core.web.ContextRequestConverter contextRequestConverter, com.broadleafcommerce.common.jpa.RepositoryEntityTypeManager typeManager, ProductRepository<JpaProduct> productRepository, com.broadleafcommerce.common.extension.TypeFactory typeFactory, com.fasterxml.jackson.databind.ObjectMapper objectMapper)
    Deprecated, for removal: This API element is subject to removal in a future version.
     
  • Method Summary

    Modifier and Type
    Method
    Description
    protected com.broadleafcommerce.data.tracking.core.context.ContextInfo
    buildMatchingContextInfo(@NonNull com.fasterxml.jackson.databind.JsonNode entityJson)
    Deprecated, for removal: This API element is subject to removal in a future version.
     
    protected com.broadleafcommerce.data.tracking.core.context.ContextRequest
    buildMatchingContextRequest(@NonNull com.fasterxml.jackson.databind.JsonNode entityJson)
    Deprecated, for removal: This API element is subject to removal in a future version.
     
    Deprecated, for removal: This API element is subject to removal in a future version.
     
    protected com.broadleafcommerce.data.tracking.core.web.ContextRequestConverter
    Deprecated, for removal: This API element is subject to removal in a future version.
     
    com.fasterxml.jackson.databind.ObjectMapper
    Deprecated, for removal: This API element is subject to removal in a future version.
     
    Deprecated, for removal: This API element is subject to removal in a future version.
     
    protected String
    Deprecated, for removal: This API element is subject to removal in a future version.
     
    Deprecated, for removal: This API element is subject to removal in a future version.
     
    Deprecated, for removal: This API element is subject to removal in a future version.
     
    Deprecated, for removal: This API element is subject to removal in a future version.
     
    Deprecated, for removal: This API element is subject to removal in a future version.
     
    protected com.broadleafcommerce.translation.service.TranslationEntityService<com.broadleafcommerce.translation.domain.Translation>
    Deprecated, for removal: This API element is subject to removal in a future version.
     
    protected com.broadleafcommerce.common.extension.TypeFactory
    Deprecated, for removal: This API element is subject to removal in a future version.
     
    protected com.broadleafcommerce.common.jpa.RepositoryEntityTypeManager
    Deprecated, for removal: This API element is subject to removal in a future version.
     
    Deprecated, for removal: This API element is subject to removal in a future version.
     
    void
    hook(String entityJson)
    Deprecated, for removal: This API element is subject to removal in a future version.
     
    protected boolean
    isDelete(com.fasterxml.jackson.databind.JsonNode tracking)
    Deprecated, for removal: This API element is subject to removal in a future version.
     
    void
    processStateChange(com.fasterxml.jackson.databind.JsonNode entityJson)
    Deprecated, for removal: This API element is subject to removal in a future version.
     

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

    Methods inherited from interface com.broadleafcommerce.common.messaging.PersistenceHandler

    handle, isValidType, validate
  • Constructor Details

    • DeleteProductRelationshipEntitiesHandler

      public DeleteProductRelationshipEntitiesHandler(CategoryProductService<CategoryProduct> categoryProductService, VariantService<Variant> variantService, ProductTagService<ProductTag> productTagService, PromotionalProductService<PromotionalProduct> promotionalProductService, ProductAssetService<ProductAsset> productAssetService, com.broadleafcommerce.translation.service.TranslationEntityService<com.broadleafcommerce.translation.domain.Translation> translationService, com.broadleafcommerce.data.tracking.core.web.ContextRequestConverter contextRequestConverter, com.broadleafcommerce.common.jpa.RepositoryEntityTypeManager typeManager, ProductRepository<JpaProduct> productRepository, com.broadleafcommerce.common.extension.TypeFactory typeFactory, com.fasterxml.jackson.databind.ObjectMapper objectMapper)
      Deprecated, for removal: This API element is subject to removal in a future version.
  • Method Details

    • hook

      @StreamListener("persistenceInputDeleteProductRelatedEntities") public void hook(String entityJson)
      Deprecated, for removal: This API element is subject to removal in a future version.
      Specified by:
      hook in interface com.broadleafcommerce.common.messaging.PersistenceHandler
    • processStateChange

      @SuppressNotification("SINGLE_INDEX_REQUEST") public void processStateChange(com.fasterxml.jackson.databind.JsonNode entityJson)
      Deprecated, for removal: This API element is subject to removal in a future version.
      Specified by:
      processStateChange in interface com.broadleafcommerce.common.messaging.PersistenceHandler
    • getSupportedSimpleTypeNames

      public String[] getSupportedSimpleTypeNames()
      Deprecated, for removal: This API element is subject to removal in a future version.
      Specified by:
      getSupportedSimpleTypeNames in interface com.broadleafcommerce.common.messaging.PersistenceHandler
    • isDelete

      protected boolean isDelete(com.fasterxml.jackson.databind.JsonNode tracking)
      Deprecated, for removal: This API element is subject to removal in a future version.
    • buildMatchingContextInfo

      protected com.broadleafcommerce.data.tracking.core.context.ContextInfo buildMatchingContextInfo(@NonNull @NonNull com.fasterxml.jackson.databind.JsonNode entityJson) throws com.fasterxml.jackson.core.JsonProcessingException
      Deprecated, for removal: This API element is subject to removal in a future version.
      Throws:
      com.fasterxml.jackson.core.JsonProcessingException
    • buildMatchingContextRequest

      protected com.broadleafcommerce.data.tracking.core.context.ContextRequest buildMatchingContextRequest(@NonNull @NonNull com.fasterxml.jackson.databind.JsonNode entityJson)
      Deprecated, for removal: This API element is subject to removal in a future version.
    • getProductEntityType

      protected String getProductEntityType()
      Deprecated, for removal: This API element is subject to removal in a future version.
    • getCategoryProductService

      protected CategoryProductService<CategoryProduct> getCategoryProductService()
      Deprecated, for removal: This API element is subject to removal in a future version.
    • getVariantService

      protected VariantService<Variant> getVariantService()
      Deprecated, for removal: This API element is subject to removal in a future version.
    • getProductTagService

      protected ProductTagService<ProductTag> getProductTagService()
      Deprecated, for removal: This API element is subject to removal in a future version.
    • getPromotionalProductService

      protected PromotionalProductService<PromotionalProduct> getPromotionalProductService()
      Deprecated, for removal: This API element is subject to removal in a future version.
    • getProductAssetService

      protected ProductAssetService<ProductAsset> getProductAssetService()
      Deprecated, for removal: This API element is subject to removal in a future version.
    • getTranslationService

      protected com.broadleafcommerce.translation.service.TranslationEntityService<com.broadleafcommerce.translation.domain.Translation> getTranslationService()
      Deprecated, for removal: This API element is subject to removal in a future version.
    • getContextRequestConverter

      @NonNull protected com.broadleafcommerce.data.tracking.core.web.ContextRequestConverter getContextRequestConverter()
      Deprecated, for removal: This API element is subject to removal in a future version.
    • getTypeManager

      protected com.broadleafcommerce.common.jpa.RepositoryEntityTypeManager getTypeManager()
      Deprecated, for removal: This API element is subject to removal in a future version.
    • getProductRepository

      protected ProductRepository<JpaProduct> getProductRepository()
      Deprecated, for removal: This API element is subject to removal in a future version.
    • getTypeFactory

      protected com.broadleafcommerce.common.extension.TypeFactory getTypeFactory()
      Deprecated, for removal: This API element is subject to removal in a future version.
    • getObjectMapper

      public com.fasterxml.jackson.databind.ObjectMapper getObjectMapper()
      Deprecated, for removal: This API element is subject to removal in a future version.
      Specified by:
      getObjectMapper in interface com.broadleafcommerce.common.messaging.PersistenceHandler