Skip to content

dynatrace_aws_credentials fails on update (could not map json) #362

@mattBaumBeneva

Description

@mattBaumBeneva

Describe the bug
It appears a bug was introduced to the aws_credentials resource starting with version 1.46.
When applying the configuration, even without modifications, the provider seems to reorder/delete-and-recreate the supporting services.

This results in failure with the following message:

11:18:48  │ Error: Could not map JSON at 'supportingServicesToMonitor[0].monitoredMetrics[0].statistic' near line 1 column 316
11:18:48  │ 
11:18:48  │   with module.AWS-test.dynatrace_aws_credentials.creds[0],
11:18:48  │   on ../../src/modules/blueprints/AWS/main.tf line 25, in resource "dynatrace_aws_credentials" "creds":
11:18:48  │   25: resource "dynatrace_aws_credentials" "creds" {

To Reproduce
Steps to reproduce the behavior:

  1. Apply dynatrace_aws_credentials with supporting services
  2. Apply configuration again
  3. See error

Expected behavior
This ressource should only be modified when necessary and should never produce inappropriate JSON.

Additional context
We have been able to confirm that this issue no longer occurs when rolling back from versions 1.47.x or 1.46.x to 1.45.0.
The issue seems to have been introduced with 1.46.x.

Metadata

Metadata

Labels

bugSomething isn't working

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions