Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[DOCS] Fix incorrect use of "updateable" flag in synonyms documentation #120866

Merged
merged 2 commits into from
Jan 28, 2025

Conversation

ganiamine
Copy link
Contributor

Fixes #120865

This PR fixes the incorrect use of the updateable flag in the Apply synonyms at index or search time documentation.

The previous example incorrectly added the updateable flag to the field mapping, which results in a mapper_parsing_exception. The corrected example applies the updateable flag to the token filter configuration instead.

Changes:
Updated the example code snippet as follows:

Before:

  "mappings": {
    "properties": {
      "title": {
        "type": "text",
        "search_analyzer": "my_analyzer",
        "updateable": true
      }
    }
  }

After:

{
  "mappings": {
    "properties": {
      "title": {
        "type": "text",
        "search_analyzer": "my_analyzer"
      }
    }
  },
  "settings": {
    "analysis": {
      "analyzer": {
        "my_analyzer": {
          "tokenizer": "whitespace",
          "filter": [
            "synonyms_filter"
          ]
        }
      },
      "filter": {
        "synonyms_filter": {
          "type": "synonym",
          "synonyms_path": "analysis/synonym-set.txt",
          "updateable": true
        }
      }
    }
  }
}

Copy link

cla-checker-service bot commented Jan 26, 2025

💚 CLA has been signed

Copy link
Contributor

Documentation preview:

@elasticsearchmachine elasticsearchmachine added v9.0.0 needs:triage Requires assignment of a team area label external-contributor Pull request authored by a developer outside the Elasticsearch team labels Jan 26, 2025
@gareth-ellis gareth-ellis added the >docs General docs changes label Jan 27, 2025
@elasticsearchmachine elasticsearchmachine added the Team:Docs Meta label for docs team label Jan 27, 2025
@elasticsearchmachine
Copy link
Collaborator

Pinging @elastic/es-docs (Team:Docs)

@elasticsearchmachine elasticsearchmachine removed the needs:triage Requires assignment of a team area label label Jan 27, 2025
@leemthompo leemthompo added auto-backport Automatically create backport pull requests when merged v8.16.0 v8.17.0 v8.18.0 labels Jan 28, 2025
@carlosdelest carlosdelest self-assigned this Jan 28, 2025
@carlosdelest
Copy link
Member

Hey @ganiamine, thanks for opening this PR!

This change LGTM, thanks for the catch 👍 . You will need to sign the CLA for your PR to be accepted, once you do that I'll make sure this is merged.

@ganiamine
Copy link
Contributor Author

Hello @carlosdelest,
I have already signed the CLA, but it seems the bot hasn't detected it yet.
Could someone assist me with this?

@leemthompo
Copy link
Contributor

run docs-build

@leemthompo
Copy link
Contributor

@elasticmachine test this

@leemthompo leemthompo merged commit 38ea49a into elastic:main Jan 28, 2025
7 checks passed
carlosdelest added a commit to carlosdelest/elasticsearch that referenced this pull request Jan 28, 2025
carlosdelest added a commit to carlosdelest/elasticsearch that referenced this pull request Jan 28, 2025
carlosdelest added a commit to carlosdelest/elasticsearch that referenced this pull request Jan 28, 2025
@elasticsearchmachine
Copy link
Collaborator

💚 Backport successful

Status Branch Result
8.16
8.17
8.x

elasticsearchmachine pushed a commit that referenced this pull request Jan 28, 2025
elasticsearchmachine pushed a commit that referenced this pull request Jan 28, 2025
elasticsearchmachine pushed a commit that referenced this pull request Jan 28, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
auto-backport Automatically create backport pull requests when merged >docs General docs changes external-contributor Pull request authored by a developer outside the Elasticsearch team Team:Docs Meta label for docs team v8.16.0 v8.17.0 v8.18.0 v9.0.0
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[DOCS] Incorrect use of updateable flag in Elasticsearch synonyms documentation
5 participants