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

Assigned Pod add/update events don't requeue Pods without PodAffinity #122626

Open
Tracked by #122597
sanposhiho opened this issue Jan 7, 2024 · 4 comments · May be fixed by #122627
Open
Tracked by #122597

Assigned Pod add/update events don't requeue Pods without PodAffinity #122626

sanposhiho opened this issue Jan 7, 2024 · 4 comments · May be fixed by #122627
Assignees
Labels
kind/bug Categorizes issue or PR as related to a bug. needs-triage Indicates an issue or PR lacks a `triage/foo` label and requires one. sig/scheduling Categorizes an issue or PR as relevant to SIG Scheduling.

Comments

@sanposhiho
Copy link
Member

sanposhiho commented Jan 7, 2024

What happened?

/sig scheduling
/kind bug

When assigned Pods are created/updated, cluster events (Pod/Add or Pod/Update) should be delivered for all plugins that subscribe those events. But, actually getUnschedulablePodsWithMatchingAffinityTerm pre-filters Pods to receive those events based on Pods' affinity and pod.Status.Resize. - meaning only PodAffinity/NodeResourceFit receive them actually.

The problem here is similar to #110175 - in in-tree plugins, PodAffinity, PodTopologySpread and NodeResourceFit subscribe Pod add and/or update events. And, Pods rejected by PodTopologySpread will never be requeued to activeQ by Pod-related events. The same happens for custom plugins registering pod add and/or update events.

What did you expect to happen?

All Pods will get chances to get back to activeQ by Pod-related events.

How can we reproduce it (as minimally and precisely as possible)?

Run ↓ in https://github.com/sanposhiho/kubernetes/tree/pod-bug-repro.

 make test-integration WHAT=./test/integration/scheduler KUBE_TEST_ARGS="-run=^TestCoreResourceEnqueue$" 

Anything else we need to know?

No response

Kubernetes version

master

Cloud provider

OS version

# On Linux:
$ cat /etc/os-release
# paste output here
$ uname -a
# paste output here

# On Windows:
C:\> wmic os get Caption, Version, BuildNumber, OSArchitecture
# paste output here

Install tools

Container runtime (CRI) and version (if applicable)

Related plugins (CNI, CSI, ...) and versions (if applicable)

@sanposhiho sanposhiho added the kind/bug Categorizes issue or PR as related to a bug. label Jan 7, 2024
@k8s-ci-robot k8s-ci-robot added the sig/scheduling Categorizes an issue or PR as relevant to SIG Scheduling. label Jan 7, 2024
@k8s-ci-robot
Copy link
Contributor

This issue is currently awaiting triage.

If a SIG or subproject determines this is a relevant issue, they will accept it by applying the triage/accepted label and provide further guidance.

The triage/accepted label can be added by org members by writing /triage accepted in a comment.

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

@k8s-ci-robot k8s-ci-robot added the needs-triage Indicates an issue or PR lacks a `triage/foo` label and requires one. label Jan 7, 2024
@sanposhiho sanposhiho changed the title Assigned Pod related events don't arrive Pods with PodTopologySpread Assigned Pod related events don't requeue Pods without any PodAffinity Jan 7, 2024
@sanposhiho
Copy link
Member Author

/assign

@sanposhiho sanposhiho changed the title Assigned Pod related events don't requeue Pods without any PodAffinity Assigned Pod related events don't requeue Pods without PodAffinity Jan 7, 2024
@sanposhiho sanposhiho changed the title Assigned Pod related events don't requeue Pods without PodAffinity Assigned Pod add/update events don't requeue Pods without PodAffinity Jan 7, 2024
@k8s-triage-robot
Copy link

The Kubernetes project currently lacks enough contributors to adequately respond to all issues.

This bot triages un-triaged issues according to the following rules:

  • After 90d of inactivity, lifecycle/stale is applied
  • After 30d of inactivity since lifecycle/stale was applied, lifecycle/rotten is applied
  • After 30d of inactivity since lifecycle/rotten was applied, the issue is closed

You can:

  • Mark this issue as fresh with /remove-lifecycle stale
  • Close this issue with /close
  • Offer to help out with Issue Triage

Please send feedback to sig-contributor-experience at kubernetes/community.

/lifecycle stale

@k8s-ci-robot k8s-ci-robot added the lifecycle/stale Denotes an issue or PR has remained open with no activity and has become stale. label Apr 6, 2024
@sanposhiho
Copy link
Member Author

/remove-lifecycle stale

@k8s-ci-robot k8s-ci-robot removed the lifecycle/stale Denotes an issue or PR has remained open with no activity and has become stale. label Apr 7, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind/bug Categorizes issue or PR as related to a bug. needs-triage Indicates an issue or PR lacks a `triage/foo` label and requires one. sig/scheduling Categorizes an issue or PR as relevant to SIG Scheduling.
Projects
None yet
3 participants