Interface ImportBatchIndexableTypeMapping

All Known Implementing Classes:
CustomerImportBatchIndexableTypeMapping, ProductImportBatchIndexableTypeMapping

public interface ImportBatchIndexableTypeMapping
Provides a mechanism to determine the batch indexable type that should be used when emitting BatchIndexRequests for an import.

The expectation is for consumers to define different ImportBatchIndexableTypeMapping beans to provide the batch indexable type for each kind of import that needs to support this behavior. This is leveraged by DefaultIndexNotificationService, where the first bean to provide a value will be used.

See Also:
  • Method Summary

    Modifier and Type
    Method
    Description
    Given an import entity, return the batch indexable type that should be used for it (if applicable).
  • Method Details

    • getBatchIndexableType

      @Nullable String getBatchIndexableType(Import importEntity)
      Given an import entity, return the batch indexable type that should be used for it (if applicable).

      Typically, most implementations will just determine the indexable type by examining Import.getType().

      Parameters:
      importEntity - the import entity for which to determine the batch indexable type
      Returns:
      the determined batch indexable type for this import entity. In cases where the implementation does not support or cannot determine the batch indexable type for the import, null will be returned.
      See Also:
      • BatchIndexableType