Skip to content

Bulk publishing leads to ElasticSearch Exception "action_request_validation_exception" for empty payload #405

@mariofischer

Description

@mariofischer

Problem: Publishing changes might lead to the following ElasticSearch Exception:

  [type] => action_request_validation_exception
  [reason] => Validation Failed: 1: no requests added;

This happens if the payload is empty (we don't why this is). In this case the check in Flowpack\ElasticSearch\ContentRepositoryAdaptor\Indexer\NodeIndexer is not sufficient:

            if (!isset($payload[$hash])) {
                continue;
            }

This can be circumvented by adding empty:

            if (!isset($payload[$hash]) || empty($payload[$hash])) {
                continue;
            }

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions