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

[Backport 7.56.x] Fixed the heat endpoint for the Openstack Controller #18104

Merged
merged 1 commit into from
Jul 23, 2024

Conversation

datadog-agent-integrations-bot[bot]
Copy link
Contributor

Backport 5139e97 from #17996.


What does this PR do?

We noticed that the heat stacks weren't being discovered in the Openstack Controller integration:
2024-07-03 15:55:34 UTC | CORE | DEBUG | (pkg/collector/python/datadog_agent.go:133 in LogMessage) | - | (connectionpool.py:474) | [http://10.164.0.33:80](http://10.164.0.33/) "GET /heat-api/v1/***************************87d1e/v1/***************************87d1e/stacks HTTP/1.1" 404 154 2024-07-03 15:55:34 UTC | CORE | ERROR | (pkg/collector/python/datadog_agent.go:127 in LogMessage) | openstack_controller:92e51db26f99a1e5 | (component.py:79) | HTTPError: <Response [404]>

When reading the API documentation for heat (https://docs.openstack.org/api-ref/orchestration/v1/), there is no endpoint for /v1 or /v1/{tenant_id}.

So looking at how we get the endpoint in https://github.com/DataDog/integrations-core/blob/master/openstack_controller/datadog_checks/openstack_controller/api/api_rest.py#L34, either the project_id can be removed (causing /v1 to be made the endpoint) or the project_id can be kept (causing /v1/{tenant_id} to be the endpoint).

As such, a specific edge case needed to be added for generating the endpoint for the heat component.

Motivation

Additional Notes

Review checklist (to be filled by reviewers)

  • Feature or bugfix MUST have appropriate tests (unit, integration, e2e)
  • Changelog entries must be created for modifications to shipped code
  • Add the qa/skip-qa label if the PR doesn't need to be tested during QA.
  • If you need to backport this PR to another branch, you can add the backport/<branch-name> label to the PR and it will automatically open a backport PR once this one is merged

* fixing the heat endpoint

* added a changelog

* addressed comments

* addressed comments

* lint

(cherry picked from commit 5139e97)
@iliakur iliakur merged commit 5830561 into 7.56.x Jul 23, 2024
25 checks passed
@iliakur iliakur deleted the backport-17996-to-7.56.x branch July 23, 2024 12:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants