dynatrace-oss/terraform-provider-dynatrace

dynatrace_direct_shares (Resource) o-auth permissions

Opened this issue · 0 comments

Describe the bug
When rotating o-auth clients (as a security standard) previously created dashboards/documents can not be shared with the new o-auth client, nor can newly created dashboards be re-shared with the old o-auth client - the following error is seen. The client used to share the dashboards/documents initially is the only one which has the permissions to share again in the future. This will cause us an issue when we need to rotate the o-auth client as we will need to delete every dashboard/document from state, and then reshare with the new o-auth client. Wondering if this is a terraform issue or a dynatrace limitation.
https://registry.terraform.io/providers/dynatrace-oss/dynatrace/latest/docs/resources/direct_shares

This concerns new UI dashboards/documents, not classic dashboards FYI.

Screenshot 2024-12-23 at 10 09 07

To Reproduce
Steps to reproduce the behavior:

  1. Create a dashboard and share using an o-auth client
  2. create a new o-auth client
  3. try share the dashboard again (change the share, re-share)
  4. See error

Expected behavior
We want newly created o-auth clients to be able to share existing dashboards/documents.

Wondering if there is an API which creates the shares and doing it via that instead of through terraform, this would help prove weather it is dynatrace or terraform causing the issue. Thanks for looking in to this in advance 👍