@@ -15,7 +15,7 @@ import (
15
15
// parameter.
16
16
// Envoy sends the request body to ext proc before sending the request to the backend server.
17
17
func (s * Server ) HandleRequestBody (reqCtx * RequestContext , req * extProcPb.ProcessingRequest ) (* extProcPb.ProcessingResponse , error ) {
18
- klog .V (2 ).Infof ("Handling request body" )
18
+ klog .V (3 ).Infof ("Handling request body" )
19
19
20
20
// Unmarshal request body (must be JSON).
21
21
v := req .Request .(* extProcPb.ProcessingRequest_RequestBody )
@@ -24,14 +24,14 @@ func (s *Server) HandleRequestBody(reqCtx *RequestContext, req *extProcPb.Proces
24
24
klog .Errorf ("Error unmarshaling request body: %v" , err )
25
25
return nil , fmt .Errorf ("error unmarshaling request body: %v" , err )
26
26
}
27
- klog .V (2 ).Infof ("Request body: %v" , rb )
27
+ klog .V (3 ).Infof ("Request body: %v" , rb )
28
28
29
29
// Resolve target models.
30
30
model , ok := rb ["model" ].(string )
31
31
if ! ok {
32
32
return nil , fmt .Errorf ("model not found in request" )
33
33
}
34
- klog .V (2 ).Infof ("Model requested: %v" , model )
34
+ klog .V (3 ).Infof ("Model requested: %v" , model )
35
35
llmReq := & scheduling.LLMRequest {
36
36
Model : model ,
37
37
// For now use the model as the target model.
@@ -47,13 +47,13 @@ func (s *Server) HandleRequestBody(reqCtx *RequestContext, req *extProcPb.Proces
47
47
klog .Errorf ("Error marshaling request body: %v" , err )
48
48
return nil , fmt .Errorf ("error marshaling request body: %v" , err )
49
49
}
50
- klog .V (2 ).Infof ("Updated body: %v" , updatedBody )
50
+ klog .V (3 ).Infof ("Updated body: %v" , updatedBody )
51
51
52
52
targetPod , err := s .scheduler .Schedule (llmReq )
53
53
if err != nil {
54
54
return nil , fmt .Errorf ("failed to find target pod: %v" , err )
55
55
}
56
- klog .V (2 ).Infof ("Selected target model %v in target pod: %v\n " , llmReq .ResolvedTargetModel , targetPod )
56
+ klog .V (3 ).Infof ("Selected target model %v in target pod: %v\n " , llmReq .ResolvedTargetModel , targetPod )
57
57
58
58
reqCtx .Model = llmReq .Model
59
59
reqCtx .TargetPod = targetPod
@@ -69,7 +69,7 @@ func (s *Server) HandleRequestBody(reqCtx *RequestContext, req *extProcPb.Proces
69
69
}
70
70
// Print headers for debugging
71
71
for _ , header := range headers {
72
- klog .V (2 ).Infof ("[request_body] Header Key: %s, Header Value: %s\n " , header .Header .Key , header .Header .RawValue )
72
+ klog .V (3 ).Infof ("[request_body] Header Key: %s, Header Value: %s\n " , header .Header .Key , header .Header .RawValue )
73
73
}
74
74
75
75
resp := & extProcPb.ProcessingResponse {
@@ -93,10 +93,10 @@ func (s *Server) HandleRequestBody(reqCtx *RequestContext, req *extProcPb.Proces
93
93
}
94
94
95
95
func HandleRequestHeaders (reqCtx * RequestContext , req * extProcPb.ProcessingRequest ) * extProcPb.ProcessingResponse {
96
- klog .V (2 ).Info ("--- In RequestHeaders processing ..." )
96
+ klog .V (3 ).Info ("--- In RequestHeaders processing ..." )
97
97
r := req .Request
98
98
h := r .(* extProcPb.ProcessingRequest_RequestHeaders )
99
- klog .V (2 ).Infof ("Headers: %+v\n " , h )
99
+ klog .V (3 ).Infof ("Headers: %+v\n " , h )
100
100
101
101
resp := & extProcPb.ProcessingResponse {
102
102
Response : & extProcPb.ProcessingResponse_RequestHeaders {
0 commit comments