Skip to content

[BUG] Index being replaced when changes on Aliases #233

@TGcandeias

Description

@TGcandeias

What is the bug?

When updating, adding or removing a alias to an existing Index, terraform will replace the index, instead of performing an update in place.

How can one reproduce the bug?

  1. Create a index with 1 or more aliases using opensearch_index.index
resource "opensearch_index" "index" {
  name = "terraform-index"
  aliases = jsonencode(
    {
      log = {
        is_write_index = true
      }
    }
  )
  number_of_replicas = "0"
  number_of_shards   = "1"
  mappings = file("../.opensearch/testmapping.json")
}
  1. After it has been created update the definition and execute a new plan:

Image

What is the expected behavior?

It is expected for the index to be updated in place instead of being recreated.

What is your host/environment?

Terraform v1.10.3
on windows_amd64

  • provider registry.terraform.io/opensearch-project/opensearch v2.3.1

Do you have any screenshots?

Image

Do you have any additional context?

This was discussed in a previous issue(#85 (comment)), reported fixed on v2.3.1 but till manifests

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workinggood first issueGood for newcomers

    Type

    No type

    Projects

    Status

    🆕 New

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions