(pid uint32)
| 247 | } |
| 248 | |
| 249 | func (p *javaTLSProgram) newJavaProcess(pid uint32) { |
| 250 | if !p.isJavaProcess(pid) { |
| 251 | return |
| 252 | } |
| 253 | if !p.isAttachmentAllowed(pid) { |
| 254 | log.Debugf("java pid %d attachment rejected", pid) |
| 255 | return |
| 256 | } |
| 257 | |
| 258 | if err := java.InjectAgent(int(pid), p.tracerJarPath, p.tracerArguments); err != nil { |
| 259 | log.Error(err) |
| 260 | } |
| 261 | } |
| 262 | |
| 263 | func (p *javaTLSProgram) PreStart(*manager.Manager) error { |
| 264 | p.cleanupExec = p.processMonitor.SubscribeExec(p.newJavaProcess) |
nothing calls this directly
no test coverage detected