Skip to content

Re-indexing space kills full text search index in opensearch #3295

Description

@schweigisito

Describe the bug

Full text search (FTS) doesn't work anymore once a re-index of a space has been triggered. Used search backend is opensearch in a opencloud k8s deployment.

Behaviour is not reproducible in a docker environment using "bleve".

Steps to reproduce

  1. Create a file e.g. testfilereindexissue.txt with the conent Search string for testing: 30e589bce5dc36dce2c7aa1e239932f4
  2. Save file
  3. Search for 30e589bce5dc36dce2c7aa1e239932f4 within the OC WebUI search
    => Search result shows the created file
  4. Execute curl command angainst the opensearch api:

curl -H 'Content-Type: application/json' -s http://opencloud-opensearch-cluster-master.opensearch.svc.cluster.local:9200/opencloud-resource/_search -d '{"query": {"query_string": {"query": "30e589bce5dc36dce2c7aa1e239932f4"}}}

=> opensearch api return the indexed entry

  1. Run opencloud search index --all-spaces --force-rescan --insecure (on opencloud-api pod)
  2. Search again via UI:

=> no search result

  1. Execute curl command again

=> no result from opensearch api

  1. Edit previously created test file by adding anything and save

=> file gets re-indexed and both UI and opensearch api correctly answer the search query

Expected behavior

FTS must not get broken after re-indexing

Actual behavior

See above

Setup

Standard OpenCloud helmfile deployment in k3s single node cluster with empty spaces but the single testfile.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    Projects

    Status
    Qualification

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions