@@ -69,29 +69,29 @@ import (
6969// }
7070// defer client.Stop()
7171type Client struct {
72- options ClientOptions
73- process * exec.Cmd
74- client * jsonrpc2.Client
75- actualPort int
76- actualHost string
77- state ConnectionState
78- sessions map [string ]* Session
79- sessionsMux sync.Mutex
80- isExternalServer bool
72+ options ClientOptions
73+ process * exec.Cmd
74+ client * jsonrpc2.Client
75+ actualPort int
76+ actualHost string
77+ state ConnectionState
78+ sessions map [string ]* Session
79+ sessionsMux sync.Mutex
80+ isExternalServer bool
8181 negotiatedProtocolVersion int
82- conn net.Conn // stores net.Conn for external TCP connections
83- useStdio bool // resolved value from options
84- autoStart bool // resolved value from options
85- autoRestart bool // resolved value from options
86- modelsCache []ModelInfo
87- modelsCacheMux sync.Mutex
88- lifecycleHandlers []SessionLifecycleHandler
89- typedLifecycleHandlers map [SessionLifecycleEventType ][]SessionLifecycleHandler
90- lifecycleHandlersMux sync.Mutex
91- startStopMux sync.RWMutex // protects process and state during start/[force]stop
92- processDone chan struct {}
93- processErrorPtr * error
94- osProcess atomic.Pointer [os.Process ]
82+ conn net.Conn // stores net.Conn for external TCP connections
83+ useStdio bool // resolved value from options
84+ autoStart bool // resolved value from options
85+ autoRestart bool // resolved value from options
86+ modelsCache []ModelInfo
87+ modelsCacheMux sync.Mutex
88+ lifecycleHandlers []SessionLifecycleHandler
89+ typedLifecycleHandlers map [SessionLifecycleEventType ][]SessionLifecycleHandler
90+ lifecycleHandlersMux sync.Mutex
91+ startStopMux sync.RWMutex // protects process and state during start/[force]stop
92+ processDone chan struct {}
93+ processErrorPtr * error
94+ osProcess atomic.Pointer [os.Process ]
9595
9696 // RPC provides typed server-scoped RPC methods.
9797 // This field is nil until the client is connected via Start().
0 commit comments