Skip to content

Request Deep Dive: Pod-by-Pod Tracing

Traces an inference request through every pod in the Red Hat OpenShift AI 3.5 Models as a Service stack, with the oc commands to debug each hop.

This page traces an inference request through every pod in the Red Hat OpenShift AI 3.5 Models as a Service stack. Use it to understand where to look when debugging, what each component does to the request, and which oc commands to run.

Tip

For an animated walkthrough of these flows, see the RHOAI 3.5 Flow Visualizer .

Envoy Filter Chain (Inside the Gateway)

The maas-default-gateway Envoy proxy in openshift-ingress processes every request through this filter chain:

Envoy filter chain - 4 stages inside the Gateway
OrderFilterPod / MechanismWhat It Does
①ext_proc (IPP Pre)payload-pre-processingRuns two plugins: model-extractor (body-field-to-header) copies the model field from the body into the X-Gateway-Model-Name header, and model-provider-resolver resolves it. Runs BEFORE auth so Kuadrant can use the header for per-model policy matching.
②wasm (Kuadrant)WasmPlugin CR (in-process)Auth via Authorino (gRPC), rate limiting via Limitador (gRPC). Uses X-Gateway-Model-Name for route-level policy enforcement.
③ext_proc (IPP Post)payload-processingHeader guarding, usage enforcement, provider resolution, API format translation, credential injection. Runs AFTER auth completes.
④router(built-in)Routes the mutated request to the upstream - external provider API or on-cluster InferencePool/InferenceService.
# View the EnvoyFilter that configures the two-stage IPP
oc get envoyfilter payload-processing -n openshift-ingress -o yaml

# View the Kuadrant WasmPlugin
oc get wasmplugin -n openshift-ingress -o yaml

# View all filters on the gateway
oc get envoyfilters -n openshift-ingress

Namespace Map

Every component lives in a specific namespace. Here is the full layout for RHOAI 3.5:

RHOAI 3.5 namespace map
NamespaceComponentsPurpose
openshift-ingressmaas-default-gateway (Envoy), payload-pre-processing, payload-processing, istiod, kube-auth-proxy, router-defaultGateway, IPP ext_proc pods, Istio control plane
redhat-ai-gateway-inframaas-api, maas-api-key-cleanup (CronJob)API key management (moved from redhat-ods-applications in 3.5)
redhat-ods-applicationsmaas-controller, maas-ui, postgresMaaS controller, UI, PostgreSQL database
kuadrant-systemauthorino, limitador-limitadorAuth server, rate limit server
models-as-a-serviceMaaSAuthPolicy, MaaSSubscription CRsUser-facing access control and quota definitions
ai-tenantsAITenant CRsMulti-tenancy configuration
model namespace (e.g., llm)vLLM pods, MaaSModelRef, TokenRateLimitPolicy, LLMInferenceServiceModel serving workloads
external-models namespaceExternalProvider, ExternalModel CRsThird-party API proxy configuration
# Quick view of all MaaS-related pods across namespaces
oc get pods -n openshift-ingress -l app.kubernetes.io/part-of=maas 2>/dev/null; \
oc get pods -n redhat-ai-gateway-infra; \
oc get pods -n redhat-ods-applications | grep -E 'maas|postgres'; \
oc get pods -n kuadrant-system

Pod-by-Pod Request Trace

External Model Request (e.g., Anthropic)

External model request sequence
StepPodNamespaceWhat HappensDebug Command
1client-Sends POST /v1/chat/completions with Authorization: Bearer sk-oai-...curl -v https://maas.${CLUSTER_DOMAIN}/v1/chat/completions ...
2-4payload-pre-processingopenshift-ingressParses JSON body, extracts model field, sets X-Gateway-Model-Name header. Resolves model type.oc logs -n openshift-ingress deploy/payload-pre-processing -f
5-6maas-default-gateway (Wasm)openshift-ingressKuadrant WasmPlugin triggers auth-service actionoc logs -n openshift-ingress deploy/maas-default-gateway-istio -c istio-proxy -f
7authorinokuadrant-systemReceives gRPC call from Wasm shim. Calls MaaS API to validate the sk-oai-* key. On success, injects the identity headers (X-MaaS-Username, X-MaaS-Group, X-MaaS-Subscription) from the validation result via the MaaSAuthPolicy response stage.oc logs -n kuadrant-system deploy/authorino -f
8-9maas-apiredhat-ai-gateway-infraLooks up key hash in PostgreSQL. Returns the validation result {valid, userId, groups, subscription} to Authorino (a JSON body, not headers). The subscription comes from the key record bound at mint time.oc logs -n redhat-ai-gateway-infra deploy/maas-api -f
10limitador-limitadorkuadrant-systemReceives gRPC call from Wasm shim. Checks token quota for the subscription.oc logs -n kuadrant-system deploy/limitador-limitador -f
11-17payload-processingopenshift-ingressRuns post-processing plugins in order: maas-headers-guard, stream-usage-enforcer, model-provider-resolver (resolves ExternalModel CRD), api-translation (OpenAI to Anthropic format), apikey-injection (injects provider key from Secret).oc logs -n openshift-ingress deploy/payload-processing -f
18-19maas-default-gateway (router)openshift-ingressRoutes mutated request to https://api.anthropic.com/v1/messagesoc logs -n openshift-ingress deploy/maas-default-gateway-istio -c istio-proxy -f
20Anthropic API-Processes request, returns Anthropic Messages format response-
21-22payload-processingopenshift-ingressResponse plugins: api-translation converts Anthropic response back to OpenAI format (only when response translation is enabled - see note below)oc logs -n openshift-ingress deploy/payload-processing -f
23-25maas-default-gateway (Wasm)openshift-ingressKuadrant Wasm reads usage.total_tokens from response body. Reports consumed tokens to Limitador via gRPC.oc logs -n openshift-ingress deploy/maas-default-gateway-istio -c istio-proxy -f
26client-Receives OpenAI-format response regardless of which provider was used-
Note

Response api-translation is off by default. The payload-processing-plugins ConfigMap ships with an empty response profile (response: []) so streaming (SSE) is not held by a response processor. Providers that rewrite responses (for example Anthropic Messages to OpenAI) need it enabled manually on the ConfigMap. Steps 21-22 above only run once you opt in. See the upstream MaaS docs (External Model Setup - IPP response translation).

Internal Model Request (P/D Disaggregated)

Internal Model P/D disaggregated sequence

After step 16 (IPP Post returns to Gateway), the internal model flow diverges:

StepPodNamespaceWhat HappensDebug Command
17-19EPP (ext_proc)model namespaceEndpoint Picker selects optimal Prefill and Decode pods based on KV cache utilization and queue depthoc logs -n <model-ns> deploy/<epp-deploy> -f
20-21Sidecarmodel namespaceCoordinates the Prefill/Decode transactionoc logs -n <model-ns> <sidecar-pod> -f
22-23Prefill Pod (vLLM)model namespaceProcesses input prompt, generates KV cache, returns KVXfer metadataoc logs -n <model-ns> <prefill-pod> -c kserve-container -f
24-25NIXLmodel namespaceHigh-speed KV cache transfer from Prefill to Decode pod (GPU-direct RDMA or DCN)-
26-27Decode Pod (vLLM)model namespacePulls KV cache via NIXL, generates tokens auto-regressively, streams response back to Gatewayoc logs -n <model-ns> <decode-pod> -c kserve-container -f

Key Configuration Resources

CRD relationship hierarchy

These are the ConfigMaps, Secrets, and CRDs that control the request flow:

ResourceNamespacePurpose
ConfigMap/payload-processing-pluginsopenshift-ingressDefines which plugins run in IPP pre and post stages
Secret with label inference.llm-d.ai/ipp-managed=trueexternal-models namespaceProvider API keys for apikey-injection plugin (3.5 label; was bbr-managed in 3.4)
Config/default(cluster-scoped)Platform anchor CR that triggers MaaS controller reconciliation
AITenantai-tenantsMulti-tenancy configuration for the AI Gateway
MaaSModelRefmodel namespaceMaps user-facing model name to provider endpoint and target model ID
MaaSAuthPolicymodels-as-a-serviceConfigures API key authentication via K8s Secret
MaaSSubscriptionmodels-as-a-serviceDefines quota - associates user/team with allowed models and rate limits
ExternalProviderexternal-models namespaceProvider connection config (URL, auth type)
ExternalModelexternal-models namespaceMaps model name to provider and target model
AuthPolicyopenshift-ingressGenerated by maas-controller from MaaSAuthPolicy
TokenRateLimitPolicymodel namespaceGenerated by maas-controller from MaaSSubscription
# View IPP plugin configuration
oc get cm payload-processing-plugins -n openshift-ingress -o yaml

# View provider secrets (check label)
oc get secrets -l inference.llm-d.ai/ipp-managed=true -A

# View all MaaS CRDs
oc get maasmodelref -A
oc get maasauthpolicy -A
oc get maassubscription -A
oc get externalmodel -A
oc get externalprovider -A

# View platform config
oc get config default -o yaml
oc get aitenant -A

Common Debugging Scenarios

Debugging decision tree

500 Error on External Model

The request reaches the provider but credential injection failed:

# Check if the Secret has the correct label
oc get secrets -n <external-models-ns> -l inference.llm-d.ai/ipp-managed=true

# Check payload-processing logs for apikey-injection errors
oc logs -n openshift-ingress deploy/payload-processing | grep -i "apikey\|credential\|secret"

# Check ExternalModel CRD is correct
oc get externalmodel <model-name> -n <external-models-ns> -o yaml

401 Unauthorized

The API key is invalid, expired, or revoked:

# Check Authorino logs
oc logs -n kuadrant-system deploy/authorino | grep -i "denied\|reject\|invalid"

# Check MaaS API key validation
oc logs -n redhat-ai-gateway-infra deploy/maas-api | grep -i "validate\|invalid"

# Check MaaSAuthPolicy
oc get maasauthpolicy -A -o yaml

429 Too Many Requests

Token quota exceeded:

# Check Limitador logs
oc logs -n kuadrant-system deploy/limitador-limitador | grep -i "rate\|limit\|exceed"

# Check subscription limits
oc get maassubscription -A -o yaml | grep -A5 "rateLimits"

# Check TokenRateLimitPolicy
oc get tokenratelimitpolicy -A -o yaml

Model Not Found

The model name doesn’t match any MaaSModelRef:

# List all registered models
oc get maasmodelref -A

# Check payload-processing logs for resolver errors
oc logs -n openshift-ingress deploy/payload-processing | grep -i "resolver\|model.*not.*found"

# Check the pre-processing header extraction
oc logs -n openshift-ingress deploy/payload-pre-processing | grep -i "model\|header"

RHOAI 3.4 vs 3.5 Differences

RHOAI 3.4 vs 3.5 architecture comparison

If you are debugging a 3.4 cluster, these are the key differences:

What3.43.5
DSC componentkserve.modelsAsServiceaigateway.modelsAsAService
MaaS API namespaceredhat-ods-applicationsredhat-ai-gateway-infra
Secret labelinference.networking.k8s.io/bbr-managed=trueinference.llm-d.ai/ipp-managed=true
Kuadrant integrationEnvoyFilter-based WasmWasmPlugin CRs
External model CRDSingle ExternalModelExternalProvider + ExternalModel
IPP architectureSingle ext_proc stage (after auth)Two stages: pre (before auth) + post (after auth)
IPP plugins (post)model-provider-resolver, body-field-to-header, api-translation, apikey-injectionmaas-headers-guard, stream-usage-enforcer, model-provider-resolver, api-translation, apikey-injection