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

feat: add dbaas logs opensearch alias and index resources #742

Merged
merged 1 commit into from
Oct 18, 2024

Conversation

marie-j
Copy link
Contributor

@marie-j marie-j commented Oct 9, 2024

Description

  • Add Dbaas logs Output opensearch alias resource
  • Add Dbaas logs Output opensearch index resource

Type of change

Please delete options that are not relevant.

  • New feature (non-breaking change which adds functionality)

How Has This Been Tested?

Please describe the tests that you ran to verify your changes. Provide instructions so we can reproduce. Please also list any relevant details for your test configuration

  • Test A: make testacc TESTARGS="-parallel=1 -run DbaasLogs"

Test Configuration:

  • Terraform version: terraform version: Terraform vx.y.z
  • Existing HCL configuration you used:
resource "ovh_dbaas_logs_output_opensearch_alias" "alias" {
 service_name = "ldp-xxx"
 description = "aa"
 suffix        = "aa"
}

resource "ovh_dbaas_logs_output_opensearch_index" "index" {
  service_name = "ldp-xxx"
  description = "aa"
  suffix        = "aa"
  nb_shard = 1
}

Checklist:

  • My code follows the style guidelines of this project
  • I have performed a self-review of my code
  • I have commented my code, particularly in hard-to-understand areas
  • I have made corresponding changes to the documentation
  • My changes generate no new warnings or issues
  • I have added acceptance tests that prove my fix is effective or that my feature works
  • New and existing acceptance tests pass locally with my changes
  • I ran succesfully go mod vendor if I added or modify go.mod file


d.SetId(*id)

indexes := d.Get("indexes").([]interface{})
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
indexes := d.Get("indexes").([]interface{})
indexes := d.Get("indexes").([]string)

and envoid the next index.(string)?

Copy link
Contributor Author

@marie-j marie-j Oct 9, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

panic: interface conversion: interface {} is []interface {}, not []string

I suppose this is due to this declaration e7dbabe#diff-c62ab4e0d2d514494a5e0c1f4e955ccdf85a59d2fcd1b2b59ca14f7e32b8e79dR88 which declares property as an []interface{}

@marie-j marie-j force-pushed the dev/mjones/dbaaslogs-alias branch from e7dbabe to 5d477cf Compare October 9, 2024 10:24
@marie-j marie-j force-pushed the dev/mjones/dbaaslogs-alias branch from 5d477cf to 4fab6ac Compare October 11, 2024 09:43
@marie-j marie-j force-pushed the dev/mjones/dbaaslogs-alias branch from 4fab6ac to 09edc50 Compare October 16, 2024 08:33
@amstuta amstuta merged commit 4c2b0ff into master Oct 18, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants