Skip to content

Commit d6f6e08

Browse files
authored
Merge pull request #39237 from MikeSpreitzer/more-apf-obsservability
Extend APF Observability with logging and response headers
2 parents db2ca0c + ca383c3 commit d6f6e08

File tree

1 file changed

+32
-1
lines changed

1 file changed

+32
-1
lines changed

content/en/docs/concepts/cluster-administration/flow-control.md

Lines changed: 32 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -638,6 +638,10 @@ poorly-behaved workloads that may be harming system health.
638638
standard deviation of seat demand seen during the last concurrency
639639
borrowing adjustment period.
640640

641+
* `apiserver_flowcontrol_demand_seats_smoothed` is a gauge vector
642+
holding, for each priority level, the smoothed enveloped seat demand
643+
determined at the last concurrency adjustment.
644+
641645
* `apiserver_flowcontrol_target_seats` is a gauge vector holding, for
642646
each priority level, the concurrency target going into the borrowing
643647
allocation problem.
@@ -761,7 +765,34 @@ serves the following additional paths at its HTTP[S] ports.
761765
system, system-nodes, 12, 0, system:node:127.0.0.1, 2020-07-23T15:31:03.583823404Z, system:node:127.0.0.1, create, /api/v1/namespaces/scaletest/configmaps,
762766
system, system-nodes, 12, 1, system:node:127.0.0.1, 2020-07-23T15:31:03.594555947Z, system:node:127.0.0.1, create, /api/v1/namespaces/scaletest/configmaps,
763767
```
764-
768+
769+
### Debug logging
770+
771+
At `-v=3` or more verbose the server outputs an httplog line for every
772+
request, and it includes the following attributes.
773+
774+
- `apf_fs`: the name of the flow schema to which the request was classified.
775+
- `apf_pl`: the name of the priority level for that flow schema.
776+
- `apf_iseats`: the number of seats determined for the initial
777+
(normal) stage of execution of the request.
778+
- `apf_fseats`: the number of seats determined for the final stage of
779+
execution (accounting for the associated WATCH notifications) of the
780+
request.
781+
- `apf_additionalLatency`: the duration of the final stage of
782+
execution of the request.
783+
784+
At higher levels of verbosity there will be log lines exposing details
785+
of how APF handled the request, primarily for debug purposes.
786+
787+
### Response headers
788+
789+
APF adds the following two headers to each HTTP response message.
790+
791+
- `X-Kubernetes-PF-FlowSchema-UID` holds the UID of the FlowSchema
792+
object to which the corresponding request was classified.
793+
- `X-Kubernetes-PF-PriorityLevel-UID` holds the UID of the
794+
PriorityLevelConfiguration object associated with that FlowSchema.
795+
765796
## {{% heading "whatsnext" %}}
766797

767798

0 commit comments

Comments
 (0)