canonical / canonical/cos-proxy-operator

Add end-to-end test

Open
#218 0 comments 0 reactions 0 assignees View on GitHub
Status: Triage Type: Enhancement
Dominant language
Python
Stars
3
Forks
12
PR merge metrics
No merged PRs in 30d

Description

### Enhancement Proposal

We need to capture the topological complexity of production deployments of cos-proxy, without the scale complexity.

For example, an integration test could deploy the following:

```mermaid
graph TD

subgraph "Machine 0"

subgraph "Subordinates 0"
otelcol/0
end

cos-proxy/0 ---|cos-agent| otelcol/0

end

subgraph "Machine 1"

subgraph "Subordinates 1"
nrpe/0
telegraf/0
end

ubuntu/0 ---|general-info| nrpe/0
ubuntu/0 ---|juju-info| telegraf/0
nrpe/0 ---|monitors| cos-proxy/0
telegraf/0 ---|prometheus-client| cos-proxy/0
telegraf/0 ---|prometheus-rules| cos-proxy/0
end

subgraph "Machine 2"

subgraph "Subordinates 2"
nrpe/1
telegraf/1
end

ubuntu/1 ---|general-info| nrpe/1
ubuntu/1 ---|juju-info| telegraf/1
nrpe/1 ---|monitors| cos-proxy/0
telegraf/1 ---|prometheus-client| cos-proxy/0
telegraf/1 ---|prometheus-rules| cos-proxy/0
end

subgraph "COS"
prometheus-a/0
prometheus-b/0
end

cos-proxy/0 ---|downstream-prometheus-scrape| prometheus-a/0
otelcol/0 ---|send-remote-write| prometheus-b/0
```

and make assertions on the `/api/v1/targets` and `/api/v1/labels` of prometheus.

Should also clean up [`tests/manual`](https://github.com/canonical/cos-proxy-operator/tree/main/tests/manual) as part of this issue.

Refs:
- https://github.com/canonical/cos-lite-bundle/pull/68

Contributor guide

No contributing guide indexed for this repository

Research direction

Review the proposed multi-machine topology and the existing tests/manual directory first. Build an end-to-end deployment matching the issue's relationships, then inspect Prometheus through /api/v1/targets and /api/v1/labels. Done means the integration assertions cover the deployment and tests/manual has been cleaned up.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
devops, testing-qa
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.