Commit Graph

3400 Commits

Author SHA1 Message Date
Kevin Hannon 3d08c10c8a fix PodLogsQuerySplitStream if feature is enabled and using defaults 2024-11-08 22:32:30 -05:00
Jefftree 0ce7b688a6 v1alpha2 LeaseCandidate API 2024-11-08 02:27:19 +00:00
Kubernetes Prow Robot 4cf2818f96
Merge pull request #128240 from LionelJouin/KEP-4817
DRA: Implementation of ResourceClaim.Status.Devices (KEP-4817)
2024-11-08 02:21:24 +00:00
Abu Kashem b6773f1589
api: add a new field to meta/v1 DeleteOptions
- add a new boolean field
  IgnoreStoreReadErrorWithClusterBreakingPotential to meta/v1 DeleteOptions

- add validation for the new delete option
add validation for the new field in the delete options
ignoreStoreReadErrorWithClusterBreakingPotential

- prevent the pod eviction handler from issuing an unsafe pod delete
prevent the pod eviction handler from enabling the
'ignoreStoreReadErrorWithClusterBreakingPotential' delete option
2024-11-07 15:12:56 -05:00
Kubernetes Prow Robot 9660e5c4cd
Merge pull request #127360 from knight42/feat/split-stdout-stderr-server-side
API: add a new `Stream` field to `PodLogOptions`
2024-11-07 19:44:45 +00:00
Lionel Jouin 43d23b8994 [KEP-4817] Use structured.MakeDeviceID
Signed-off-by: Lionel Jouin <lionel.jouin@est.tech>
2024-11-07 09:59:56 +01:00
Lionel Jouin a062f91106 [KEP-4817] Fixes based on review
* Rename HWAddress to HardwareAddress
* Fix condition validation
* Remove feature gate validation
* Fix drop field on disabled feature gate

Signed-off-by: Lionel Jouin <lionel.jouin@est.tech>
2024-11-07 09:59:56 +01:00
Lionel Jouin c59359289f [KEP-4817] Drop deallocated devices from resourceclaim.status.devices
Signed-off-by: Lionel Jouin <lionel.jouin@est.tech>
2024-11-07 09:54:19 +01:00
Lionel Jouin 5d7a16b0a5 [KEP-4817] improve testing
* Test feature-gate enabled/disabled for validation
* Test pkg/registry/resource/resourceclaim
* Add Data and NetworkData to integration test

Signed-off-by: Lionel Jouin <lionel.jouin@est.tech>
2024-11-07 09:54:19 +01:00
Lionel Jouin 3e595db0af [KEP-4817] API, validation and feature-gate
* Add status
* Add validation to check if fields are correct (Network field, device
  has been allocated))
* Add feature-gate
* Drop field if feature-gate not set

Signed-off-by: Lionel Jouin <lionel.jouin@est.tech>
2024-11-07 09:54:17 +01:00
Kubernetes Prow Robot 6cc3570466
Merge pull request #128190 from HarshalNeelkamal/external-jwt
Add plugin and key-cache for ExternalJWTSigner integration
2024-11-07 06:29:45 +00:00
Kubernetes Prow Robot 3b6978051b
Merge pull request #121897 from carlory/ds-registry-test
daemonset registry: add unit test for UpdateStatus
2024-11-07 06:29:29 +00:00
Harshal Neelkamal 6fdacf0411 Add plugin and key-cache for ExternalJWTSigner integration 2024-11-07 03:16:23 +00:00
Kubernetes Prow Robot 4c487b00af
Merge pull request #128627 from kannon92/revert-128046-ga3960
Revert "Graduate PodLifecycleSleepAction to GA"
2024-11-07 00:25:51 +00:00
Kevin Hannon 350b0d2b93
Revert "Graduate PodLifecycleSleepAction to GA" 2024-11-06 16:29:19 -05:00
Ben Luddy 439d2f7b40
Wire serving codecs to CBOR feature gate.
Integration testing has to this point relied on patching serving codecs for built-in APIs. The
test-only patching is removed and replaced by feature gated checks at runtime.
2024-11-06 15:41:39 -05:00
Jian Zeng d9687a8c3a
feat(apiserver): set stream param in LogLocation
Signed-off-by: Jian Zeng <anonymousknight96@gmail.com>
2024-11-06 22:42:18 +08:00
Patrick Ohly 2e64c72249 DRA API: register v1beta1
This is the minimal set of changes that are needed to make the new version
usable. The storage version is still v1alpha3. More changes will follow.
2024-11-06 13:03:18 +01:00
Anish Shah e55bf09ca5 Fix unit tests 2024-11-06 01:33:16 +00:00
Anish Shah 832d7f7dc2 apply feedback 2024-11-06 01:33:15 +00:00
Anish Shah 4c69bf2496 implement GetResetFieldsFilter
GetResetFieldsFilter returns a set of fields filter reset
by pod resize strategy. This is needed to make server-side apply
work correctly.
2024-11-06 01:33:15 +00:00
Anish Shah 3b91edb660 unit tests to ensure pod metadata cannot be updated during resize. 2024-11-06 01:33:15 +00:00
Anish Shah 07ca0b09bb refactor logic to override pod fields 2024-11-06 01:33:14 +00:00
Anish Shah 878c54fc9a test: add unit tests to verify the .status.resize field 2024-11-06 01:33:14 +00:00
Anish Shah 2bf1f2349c validate resize request
We validate resize request by ensuring that pod QoS is unchanged and
only cpu and memory resources and resize policies are mutated.
2024-11-06 01:33:14 +00:00
Anish Shah 8f967c19b3 drop unrelated changes for /resize request
Since resize request takes the full pod object as the request type, drop
any unrelated changes. Only container resources and resize policy should
be validated.
2024-11-06 01:33:13 +00:00
Anish Shah 507ce443b0 introduce resize REST object
This commit introduces a basic REST object for resize subresource and
adds it to the pod storage.
2024-11-06 01:33:13 +00:00
Kubernetes Prow Robot 2d6c8a129d
Merge pull request #127134 from jpbetz/mutating-admission
KEP-3962: MutatingAdmissionPolicy Alpha
2024-11-05 17:31:38 +00:00
Kubernetes Prow Robot bc79d3ba87
Merge pull request #128396 from ritazh/deprecate-EnforceMountableSecretsAnnotation
deprecate EnforceMountableSecretsAnnotation in 1.32
2024-11-05 06:07:40 +00:00
Joe Betz 0dc08eded9 Reorganize and expand unit test coverage
Also apply reviewer feedback
2024-11-04 21:41:33 -05:00
Joe Betz 0cb90973b0 Add authz test for deny when relevant fields are not changed 2024-11-04 21:40:54 -05:00
Joe Betz 1ad6fd7a0f Improve error messaging for validating admission policy authz 2024-11-04 21:40:54 -05:00
Joe Betz 3a1733f302 Add MutatingAdmissionPolicy API
This is closely aligned with ValidatingAdmissionPolicy
except that instead of validations that can fail with
messages, there are mutations, which can be defined
either with as an ApplyConfiguration or JSONPatch.

Co-authored-by: cici37 <cicih@google.com>
2024-11-04 21:40:38 -05:00
Kubernetes Prow Robot 9fe41b6198
Merge pull request #128046 from AxeZhan/ga3960
Graduate PodLifecycleSleepAction to GA
2024-11-04 22:09:35 +00:00
Rita Zhang e7cdc59555
deprecate EnforceMountableSecretsAnnotation in 1.32
Signed-off-by: Rita Zhang <rita.z.zhang@gmail.com>
2024-11-04 13:13:32 -08:00
Kubernetes Prow Robot 6a1a6fd85f
Merge pull request #126894 from carlory/ZeroLimitedNominalConcurrencyShares
remove generally available feature-gate ZeroLimitedNominalConcurrencyShares
2024-11-04 17:19:29 +00:00
AxeZhan 200a61b6b9 Graduate PodLifecycleSleepAction to GA 2024-11-02 11:05:36 +08:00
Kubernetes Prow Robot 6bc0768c62
Merge pull request #127744 from carlory/fix-126662
Tighten validation on the qosClass field of pod status
2024-11-01 22:33:27 +00:00
carlory 9cb7d58b3c Tighten validation on the qosClass field of pod status 2024-11-01 10:36:03 +08:00
Kubernetes Prow Robot f68a0371f1
Merge pull request #128433 from pohly/dra-admin-access-in-status
DRA API: check "AdminAccess in use" only once
2024-10-31 20:25:33 +00:00
Kubernetes Prow Robot 8233d1edc8
Merge pull request #127164 from cici37/correctGoDoc
Correct go doc for admissionregistration resources
2024-10-31 15:21:26 +00:00
Patrick Ohly d1f0d24ef9 DRA API: check "AdminAccess in use" only once
This is simpler and an opportunity to explain the concept.
2024-10-31 09:42:18 +01:00
Kubernetes Prow Robot daef8c2419
Merge pull request #127266 from pohly/dra-admin-access-in-status
DRA API: AdminAccess in DeviceRequestAllocationResult + DRAAdminAccess feature gate
2024-10-30 03:41:25 +00:00
Patrick Ohly 4419568259 DRA: treat AdminAccess as a new feature gated field
Using the "normal" logic for a feature gated field simplifies the
implementation of the feature gate.

There is one (entirely theoretic!) problem with updating from 1.31: if a claim
was allocated in 1.31 with admin access, the status field was not set because
it didn't exist yet. If a driver now follows the current definition of "unset =
off", then it will not grant admin access even though it should. This is
theoretic because drivers are starting to support admin access with 1.32, so
there shouldn't be any claim where this problem could occur.
2024-10-29 10:22:31 +01:00
Patrick Ohly 9a7e4ccab2 DRA admin access: add feature gate
The new DRAAdminAccess feature gate has the following effects:
- If disabled in the apiserver, the spec.devices.requests[*].adminAccess
  field gets cleared. Same in the status. In both cases the scenario
  that it was already set and a claim or claim template get updated
  is special: in those cases, the field is not cleared.

  Also, allocating a claim with admin access is allowed regardless of the
  feature gate and the field is not cleared. In practice, the scheduler
  will not do that.
- If disabled in the resource claim controller, creating ResourceClaims
  with the field set gets rejected. This prevents running workloads
  which depend on admin access.
- If disabled in the scheduler, claims with admin access don't get
  allocated. The effect is the same.

The alternative would have been to ignore the fields in claim controller and
scheduler. This is bad because a monitoring workload then runs, blocking
resources that probably were meant for production workloads.
2024-10-29 09:50:11 +01:00
Patrick Ohly 9d1b0654e0 DRA: add wg/device-management label automatically
This makes PRs show up automatically in the WG's project
board (https://github.com/orgs/kubernetes/projects/95/views/1).
2024-10-28 16:36:04 +01:00
Kubernetes Prow Robot d7bd728403
Merge pull request #128168 from liggitt/4601-beta
KEP-4601: AuthorizeNodeWithSelectors / AuthorizeWithSelectors to beta
2024-10-18 17:39:03 +01:00
carlory f68dc13760 remove general avaliable feature-gate ZeroLimitedNominalConcurrencyShares 2024-10-18 14:32:43 +08:00
Jordan Liggitt 9caca73126
KEP-4601: AuthorizeNodeWithSelectors / AuthorizeWithSelectors to beta 2024-10-17 21:02:55 -04:00
Patrick Ohly f84eb5ecf8 DRA: remove "classic DRA"
This removes the DRAControlPlaneController feature gate, the fields controlled
by it (claim.spec.controller, claim.status.deallocationRequested,
claim.status.allocation.controller, class.spec.suitableNodes), the
PodSchedulingContext type, and all code related to the feature.

The feature gets removed because there is no path towards beta and GA and DRA
with "structured parameters" should be able to replace it.
2024-10-16 23:09:50 +02:00