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

[Bug]: Operator test should rely on Deployments not counting pods #4426

Closed
4 tasks done
sxd opened this issue May 3, 2024 · 0 comments · Fixed by #4427
Closed
4 tasks done

[Bug]: Operator test should rely on Deployments not counting pods #4426

sxd opened this issue May 3, 2024 · 0 comments · Fixed by #4427
Assignees
Labels
bug 🐛 Something isn't working

Comments

@sxd
Copy link
Member

sxd commented May 3, 2024

Is there an existing issue already for this bug?

  • I have searched for an existing issue, and could not find anything. I believe this is a new bug.

I have read the troubleshooting guide

  • I have read the troubleshooting guide and I think this is a new bug.

I am running a supported version of CloudNativePG

  • I have read the troubleshooting guide and I think this is a new bug.

Contact Details

No response

Version

1.23.0

What version of Kubernetes are you using?

1.30 (unsuppprted)

What is your Kubernetes environment?

Self-managed: kind (evaluation)

How did you install the operator?

YAML manifest

What happened?

Currently the test rely on counting pods inside the operator namespace, the problem here is when we have more than one pod in the same namespace, like pyroscope pod, these test fails

Cluster resource

No response

Relevant log output

No response

Code of Conduct

  • I agree to follow this project's Code of Conduct
@sxd sxd added the triage Pending triage label May 3, 2024
@sxd sxd assigned gbartolini and sxd and unassigned gbartolini May 3, 2024
@sxd sxd added bug 🐛 Something isn't working and removed triage Pending triage labels May 3, 2024
sxd added a commit that referenced this issue May 3, 2024
Using the Deployment object from the Kubernetes environment we can get
all the information for the deployment more accurated than just listing
and couting pods, which it's an issue when you have another pod in the
same namespace.

Closes #4426

Signed-off-by: Jonathan Gonzalez V. <jonathan.gonzalez@enterprisedb.com>
sxd added a commit that referenced this issue May 3, 2024
Using the Deployment object from the Kubernetes environment we can get
all the information for the deployment more accurated than just listing
and couting pods, which it's an issue when you have another pod in the
same namespace.

Closes #4426

Signed-off-by: Jonathan Gonzalez V. <jonathan.gonzalez@enterprisedb.com>
sxd added a commit that referenced this issue May 3, 2024
Using the Deployment object from the Kubernetes environment we can get
all the information for the deployment more accurated than just listing
and couting pods, which it's an issue when you have another pod in the
same namespace.

Closes #4426

Signed-off-by: Jonathan Gonzalez V. <jonathan.gonzalez@enterprisedb.com>
jsilvela pushed a commit that referenced this issue May 7, 2024
Using the Deployment object from the Kubernetes environment we can get
all the information for the deployment more accurated than just listing
and couting pods, which it's an issue when you have another pod in the
same namespace.

Closes #4426

Signed-off-by: Jonathan Gonzalez V. <jonathan.gonzalez@enterprisedb.com>
litaocdl pushed a commit that referenced this issue May 9, 2024
Using the Deployment object from the Kubernetes environment we can get
all the information for the deployment more accurated than just listing
and couting pods, which it's an issue when you have another pod in the
same namespace.

Closes #4426

Signed-off-by: Jonathan Gonzalez V. <jonathan.gonzalez@enterprisedb.com>
leonardoce pushed a commit that referenced this issue May 15, 2024
Using the Deployment object from the Kubernetes environment we can get
all the information for the deployment more accurated than just listing
and couting pods, which it's an issue when you have another pod in the
same namespace.

Closes #4426

Signed-off-by: Jonathan Gonzalez V. <jonathan.gonzalez@enterprisedb.com>
sxd added a commit that referenced this issue May 15, 2024
Using the Deployment object from the Kubernetes environment we can get
all the information for the deployment more accurated than just listing
and couting pods, which it's an issue when you have another pod in the
same namespace.

Closes #4426

Signed-off-by: Jonathan Gonzalez V. <jonathan.gonzalez@enterprisedb.com>
Signed-off-by: Jonathan Gonzalez V <jonathan.gonzalez@enterprisedb.com>
leonardoce pushed a commit that referenced this issue May 15, 2024
Using the Deployment object from the Kubernetes environment we can get
all the information for the deployment more accurated than just listing
and couting pods, which it's an issue when you have another pod in the
same namespace.

Closes #4426

Signed-off-by: Jonathan Gonzalez V. <jonathan.gonzalez@enterprisedb.com>
Signed-off-by: Jonathan Gonzalez V <jonathan.gonzalez@enterprisedb.com>
leonardoce pushed a commit that referenced this issue May 15, 2024
This patch makes the E2e tests get the number of operator Pods by
looking into the Deployment resource instead of counting the listed
Pods.

The E2e tests will now work when more than one operator is deployed
in the same namespace, i.e. when operators are deployed with OLM.

Closes #4426

Signed-off-by: Jonathan Gonzalez V. <jonathan.gonzalez@enterprisedb.com>
Signed-off-by: Jaime Silvela <jaime.silvela@enterprisedb.com>
Co-authored-by: Jaime Silvela <jaime.silvela@enterprisedb.com>
cnpg-bot pushed a commit that referenced this issue May 15, 2024
This patch makes the E2e tests get the number of operator Pods by
looking into the Deployment resource instead of counting the listed
Pods.

The E2e tests will now work when more than one operator is deployed
in the same namespace, i.e. when operators are deployed with OLM.

Closes #4426

Signed-off-by: Jonathan Gonzalez V. <jonathan.gonzalez@enterprisedb.com>
Signed-off-by: Jaime Silvela <jaime.silvela@enterprisedb.com>
Co-authored-by: Jaime Silvela <jaime.silvela@enterprisedb.com>
(cherry picked from commit 32528f4)
cnpg-bot pushed a commit that referenced this issue May 15, 2024
This patch makes the E2e tests get the number of operator Pods by
looking into the Deployment resource instead of counting the listed
Pods.

The E2e tests will now work when more than one operator is deployed
in the same namespace, i.e. when operators are deployed with OLM.

Closes #4426

Signed-off-by: Jonathan Gonzalez V. <jonathan.gonzalez@enterprisedb.com>
Signed-off-by: Jaime Silvela <jaime.silvela@enterprisedb.com>
Co-authored-by: Jaime Silvela <jaime.silvela@enterprisedb.com>
(cherry picked from commit 32528f4)
cnpg-bot pushed a commit that referenced this issue May 15, 2024
This patch makes the E2e tests get the number of operator Pods by
looking into the Deployment resource instead of counting the listed
Pods.

The E2e tests will now work when more than one operator is deployed
in the same namespace, i.e. when operators are deployed with OLM.

Closes #4426

Signed-off-by: Jonathan Gonzalez V. <jonathan.gonzalez@enterprisedb.com>
Signed-off-by: Jaime Silvela <jaime.silvela@enterprisedb.com>
Co-authored-by: Jaime Silvela <jaime.silvela@enterprisedb.com>
(cherry picked from commit 32528f4)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug 🐛 Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants