Skip to content

Commit 025dc57

Browse files
committed
Fix connector logging bug: dereference pointer to show actual value
The connector variable is a *string from flag.String(), but the logger was printing the pointer address instead of the actual string value. This fixes the log output to show 'connector=nixlv2' instead of 'connector=0xc00012a1e0'.
1 parent 689f6c7 commit 025dc57

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

cmd/llm-d-routing-sidecar/main.go

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -53,14 +53,15 @@ func main() {
5353
ctx := signals.SetupSignalHandler(context.Background())
5454
logger := klog.FromContext(ctx)
5555

56+
5657
if *connector != proxy.ConnectorNIXLV1 && *connector != proxy.ConnectorNIXLV2 && *connector != proxy.ConnectorLMCache {
5758
logger.Info("Error: --connector must either be 'nixl', 'nixlv2' or 'lmcache'")
5859
return
5960
}
6061
if *connector == proxy.ConnectorNIXLV1 {
6162
logger.Info("Warning: nixl connector is deprecated and will be removed in a future release in favor of --connector=nixlv2")
6263
}
63-
logger.Info("p/d connector validated", "connector", connector)
64+
logger.Info("p/d connector validated", "connector", *connector)
6465

6566
// Determine namespace and pool name for SSRF protection
6667
if *enableSSRFProtection {

0 commit comments

Comments
 (0)