Relation between an index and an index pattern

Versions (relevant - Opensearch Dashboard 2.19.2)
I have an issue with alias in opensearch dashboard.
I have an index pattern that use only one index .
I have created an alias in the index, but it doesn’t appear in the index pattern.
Do you have an idea why ?

@mtayebi I think you are mixing up the different concepts when it comes to index, index pattern and alias.

  • An index is a collection of documents with similar structure, like a table in a database.
  • An index pattern is a wildcard-based string (e.g., logs-*) used in OpenSearch Dashboards to query and visualize data from one or more indices.
  • An alias is a virtual name pointing to one or more indices, allowing you to manage multiple indices as if they were one for read/write operations

In OSD you can view the alias in “Aliases” tab under “Index Management”.

Perhaps if you describe the actual issue you are seeing when using aliases, the community will be able to assist you better.

My issue is with alias field . I had added manually a alias field in the index but when i make a refresh of the index pattern it doesn’t appear.

@mtayebi I see what you mean now, you added alias field to an existing index. When you are in OpenSearch Dashboards, in “Dashboard Management” → “Index Patterns” and you select the relevant pattern, There is a button at the top right to “Refresh field list”. Have you tried this option?

Hello @Anthony, yes multiple times yes, and waited for more than two days. (the index is small, less than 1M documents, and we write on it one times per days).

After looking deeper with the web console, i see the field in the http response, But it doesn’t appear in the index-pattern view, when i search by his name it does’nt appear nothing but i see 1/n, so he see him but don’t show him.

@mtayebi I am unable to reproduce running OS 2.19.2.

If I add alias to existing index using below for example:

PUT names/_mapping
{
  "properties": {
    "name": {
      "type": "alias",
      "path": "full_name"
    }
  }
}

This appears in the index patterns UI after refresh.

Which way did you add the alias?