Skip to content

Commit c706b93

Browse files
author
Arvind Thirumurugan
committed
update API comments
1 parent 7f639c3 commit c706b93

File tree

2 files changed

+6
-4
lines changed

2 files changed

+6
-4
lines changed

apis/placement/v1alpha1/disruptionbudget_types.go

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -44,8 +44,7 @@ type PlacementDisruptionBudgetSpec struct {
4444
// If a percentage is specified, Fleet will calculate the corresponding absolute values
4545
// as follows:
4646
// * if the linked Placement object is of the PickFixed placement type,
47-
// the percentage is against the number of clusters specified in the placement (i.e., the
48-
// length of ClusterNames field in the placement policy);
47+
// we don't perform any calculation because eviction is not allowed for PickFixed CRP.
4948
// * if the linked Placement object is of the PickAll placement type, MaxUnavailable cannot
5049
// be specified since we cannot derive the total number of clusters selected.
5150
// * if the linked Placement object is of the PickN placement type,
@@ -74,8 +73,7 @@ type PlacementDisruptionBudgetSpec struct {
7473
// If a percentage is specified, Fleet will calculate the corresponding absolute values
7574
// as follows:
7675
// * if the linked Placement object is of the PickFixed placement type,
77-
// the percentage is against the number of clusters specified in the placement (i.e., the
78-
// length of ClusterNames field in the placement policy);
76+
// we don't perform any calculation because eviction is not allowed for PickFixed CRP.
7977
// * if the linked Placement object is of the PickAll placement type, MinAvailable can be
8078
// specified but only as an integer since we cannot derive the total number of clusters selected.
8179
// * if the linked Placement object is of the PickN placement type,

apis/placement/v1alpha1/eviction_types.go

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,10 @@ import (
3737
// (e.g., the CRP object or the placement appears later). To fix the situation, re-create the
3838
// Eviction object.
3939
//
40+
// Note: Eviction of resources from a cluster propagated by a PickFixed CRP is not allowed.
41+
// If the user wants to remove resources from a cluster propagated by a PickFixed CRP simply
42+
// remove the cluster name from cluster names field from the CRP spec.
43+
//
4044
// Executed evictions might be kept around for a while for auditing purposes; the Fleet controllers might
4145
// have a TTL set up for such objects and will garbage collect them automatically. For further
4246
// information, see the Fleet documentation.

0 commit comments

Comments
 (0)