mirror of
https://github.com/postmannen/ctrl.git
synced 2024-12-14 12:37:31 +00:00
changed the logging of processes
This commit is contained in:
parent
2561c1266c
commit
c57c2ffc6f
2 changed files with 3 additions and 1 deletions
|
@ -142,6 +142,8 @@ func (p process) spawnWorker(procs *processes, natsConn *nats.Conn) {
|
|||
}
|
||||
|
||||
processName := processNameGet(p.subject.name(), p.processKind)
|
||||
|
||||
// Add prometheus metrics for the process.
|
||||
p.processes.promProcessesVec.With(prometheus.Labels{"processName": string(processName)})
|
||||
|
||||
// Start a publisher worker, which will start a go routine (process)
|
||||
|
|
|
@ -311,7 +311,7 @@ func (m methodREQOpCommand) handler(proc process, message Message, nodeName stri
|
|||
procNew := newProcess(proc.natsConn, proc.processes, proc.toRingbufferCh, proc.configuration, sub, proc.errorCh, processKindSubscriber, arg.AllowedNodes, nil)
|
||||
go procNew.spawnWorker(proc.processes, proc.natsConn)
|
||||
|
||||
er := fmt.Errorf("info: startProc: started %v on %v", sub, message.ToNode)
|
||||
er := fmt.Errorf("info: startProc: started id: %v, subject: %v: node: %v", procNew.processID, sub, message.ToNode)
|
||||
sendErrorLogMessage(proc.toRingbufferCh, proc.node, er)
|
||||
|
||||
case "stopProc":
|
||||
|
|
Loading…
Reference in a new issue