MCPcopy Create free account
hub / github.com/ByteYellow/AgentProvenance / SetSessionCPUProfile

Method SetSessionCPUProfile

internal/control/service.go:324–333  ·  view source on GitHub ↗
(sessionID, profile string)

Source from the content-addressed store, hash-verified

322}
323
324func (s Service) SetSessionCPUProfile(sessionID, profile string) error {
325 var containerID, runID string
326 if err := s.DB.QueryRow(`SELECT COALESCE(container_id, ''), run_id FROM sessions WHERE id = ?`, sessionID).Scan(&containerID, &runID); err != nil {
327 return err
328 }
329 if containerID == "" {
330 return fmt.Errorf("session %s has no container id", sessionID)
331 }
332 return s.setContainerCPUProfile(runID, sessionID, containerID, profile)
333}
334
335func (s Service) Interrupt(processID string) error {
336 var containerID string

Callers 1

sessionCmdFunction · 0.45

Calls 1

Tested by

no test coverage detected