terraform-ibm-modules / terraform-ibm-observability-instances

Deploys services for Log Analysis, Activity Tracker, Monitoring, and Cloud Logs
Apache License 2.0
2 stars 2 forks source link

fix: fix cycle error #577

Closed ocofaigh closed 3 weeks ago

ocofaigh commented 3 weeks ago

Description

In https://github.com/terraform-ibm-modules/terraform-ibm-observability-instances/pull/576 I added some logic to the outputs in the root level module for log analysis, however there was a knock on affect which was causing a cycle error:

Cycle: provider[\"registry.terraform.io/logdna/logdna\"].ld, module.observability_instances.module.log_analysis.logdna_archive.archive_config, module.observability_instances.module.log_analysis (close), module.observability_instances.output.log_analysis_resource_key (expand)

I was able to reproduce in the examples, and have updated the conditional logic in the outputs to fix the issue

Release required?

Release notes content

Run the pipeline

If the CI pipeline doesn't run when you create the PR, the PR requires a user with GitHub collaborators access to run the pipeline.

Run the CI pipeline when the PR is ready for review and you expect tests to pass. Add a comment to the PR with the following text:

/run pipeline

Checklist for reviewers

For mergers

ocofaigh commented 3 weeks ago

/run pipeline

ocofaigh commented 3 weeks ago

/run pipeline

ocofaigh commented 3 weeks ago

/run pipeline

ocofaigh commented 3 weeks ago

The upgrade test is failing on below since I updated the test to use a prefix in the EN integration name (as it was giving a name clash error). This is an expected update and skipping upgrade test will have no impact on the module itself.

2024-09-30T09:19:36.3977504Z            Messages:       Resource(s) identified to be updated 
2024-09-30T09:19:36.3978207Z                            Name: en_integration
2024-09-30T09:19:36.3979337Z                            Address: module.observability_instances.module.cloud_logs[0].ibm_logs_outgoing_webhook.en_integration["0"]
2024-09-30T09:19:36.3980471Z                            Actions: [update]
2024-09-30T09:19:36.3981015Z                            DIFF:
2024-09-30T09:19:36.3981487Z                              Before: 
2024-09-30T09:19:36.3982204Z                                {"name":"cloud-logs-eu-de-en-integration-0"}
2024-09-30T09:19:36.3982875Z                              After: 
2024-09-30T09:19:36.3983523Z                                {"name":"obs-upg-nmqlcy-en"}
ocofaigh commented 3 weeks ago

/run pipeline

terraform-ibm-modules-ops commented 3 weeks ago

:tada: This PR is included in version 2.19.1 :tada:

The release is available on GitHub release

Your semantic-release bot :package::rocket: