Indexing
...
Attributes
Discovery

Update

4min

Attribute update does not send any data to Klevu.

Its only purpose is to update the attributes in klevu_indexing_attribute database table and calculate their next_action

Attribute Update triggers Attribute Discovery for a selection of entity IDs. Various plugins and observers trigger an attribute update, e.g. when an attribute is saved.

Attribute update will:

  • add any missing attributes and determine if those attributes are indexable.
  • set any of the passed attribute IDs which are no longer indexable, but were previously registered, to have a next_action of Delete.
  • set any of the passed attribute IDs that have become indexable to have a next_action of Add.
  • set the next_action for the passed attribute IDs to Update if they are indexable.

Attribute update will NOT:

  • send any data to Klevu.

Attribute update is triggered:

  • via plugins
  • via observers
  • via CLI

\Klevu\Indexing\Service\AttributeUpdateOrchestratorService responsible for attribute update. All the above methods of triggering attribute update use this service.

CLI

klevu:indexing:attribute-update

The update can also be triggered via CLI and has 1 required parameter and 2 optional parameters

  • attribute-ids - comma-separated list of attribute IDs to update
  • api-keys - [optional] comma-separated list of API keys to update
  • attribute-types - [optional] comma-separated list of attribute types to update, options:
    • KLEVU_PRODUCT
    • KELVU_CATEGORY

e.g

Shell