fix: update drifted line citations in patterns.md
Two citations were out of bounds against kubernetes/kubernetes HEAD: - delta_fifo.go:797-801 → 797-800 (DeletedFinalStateUnknown struct ends at line 800; file has 800 lines total, off-by-one) - kube_features.go:2798-2811 → 2771-2784 (init() function moved up ~27 lines; file now has 2784 lines, old citation was past EOF) Audited all 30 citations (28 OK, 2 fixed, 0 flagged for review).
This commit is contained in:
@@ -428,7 +428,7 @@ func (q *rateLimitingType[T]) AddRateLimited(item T) {
|
|||||||
|
|
||||||
## 4. Tombstone Pattern (DeletedFinalStateUnknown)
|
## 4. Tombstone Pattern (DeletedFinalStateUnknown)
|
||||||
|
|
||||||
**Source:** `staging/src/k8s.io/client-go/tools/cache/delta_fifo.go` (lines 797–801)
|
**Source:** `staging/src/k8s.io/client-go/tools/cache/delta_fifo.go` (lines 797–800)
|
||||||
|
|
||||||
### What it does
|
### What it does
|
||||||
When a watch disconnects and reconnects, some delete events may be missed. The DeltaFIFO synthesizes a `DeletedFinalStateUnknown` ("tombstone") containing the last known state of the object.
|
When a watch disconnects and reconnects, some delete events may be missed. The DeltaFIFO synthesizes a `DeletedFinalStateUnknown` ("tombstone") containing the last known state of the object.
|
||||||
@@ -437,7 +437,7 @@ When a watch disconnects and reconnects, some delete events may be missed. The D
|
|||||||
Without this, controllers would never learn about deletions that happened during disconnects.
|
Without this, controllers would never learn about deletions that happened during disconnects.
|
||||||
|
|
||||||
```go
|
```go
|
||||||
// staging/src/k8s.io/client-go/tools/cache/delta_fifo.go:797-801
|
// staging/src/k8s.io/client-go/tools/cache/delta_fifo.go:797-800
|
||||||
type DeletedFinalStateUnknown struct {
|
type DeletedFinalStateUnknown struct {
|
||||||
Key string
|
Key string
|
||||||
Obj interface{}
|
Obj interface{}
|
||||||
@@ -852,7 +852,7 @@ func (le *LeaderElector) Run(ctx context.Context) {
|
|||||||
|
|
||||||
## 8. Feature Gates Pattern
|
## 8. Feature Gates Pattern
|
||||||
|
|
||||||
**Source:** `pkg/features/kube_features.go` (lines 34–2811), `staging/src/k8s.io/client-go/features/features.go` (lines 34–80)
|
**Source:** `pkg/features/kube_features.go` (lines 34–2784), `staging/src/k8s.io/client-go/features/features.go` (lines 34–80)
|
||||||
|
|
||||||
### What it does
|
### What it does
|
||||||
A global registry of boolean flags that control feature rollout. Features progress through Alpha → Beta → GA → Deprecated lifecycle stages.
|
A global registry of boolean flags that control feature rollout. Features progress through Alpha → Beta → GA → Deprecated lifecycle stages.
|
||||||
@@ -888,7 +888,7 @@ const (
|
|||||||
### Registration at init()
|
### Registration at init()
|
||||||
|
|
||||||
```go
|
```go
|
||||||
// pkg/features/kube_features.go:2798-2811
|
// pkg/features/kube_features.go:2771-2784
|
||||||
func init() {
|
func init() {
|
||||||
ca := &clientAdapter{utilfeature.DefaultMutableFeatureGate}
|
ca := &clientAdapter{utilfeature.DefaultMutableFeatureGate}
|
||||||
runtime.Must(clientfeatures.AddVersionedFeaturesToExistingFeatureGates(ca))
|
runtime.Must(clientfeatures.AddVersionedFeaturesToExistingFeatureGates(ca))
|
||||||
|
|||||||
Reference in New Issue
Block a user