pinpoint agent线程模型
以下分析基于pinpoint1.7.1版本
pinpoint agent主要使用到的异步线程有4个
DeadlockMonitorThread : 死锁监测线程,执行一次休眠60s
public DeadlockMonitorThread(DeadlockThreadRegistry deadlockThreadRegistry, long intervalMillis) {
this.deadlockMonitorTask = new DeadlockMonitorTask(deadlockThreadRegistry, intervalMillis);
this.deadlockMonitorThread = new Thread(deadlockMonitorTask, "Pinpoint-deadlock-monitor");
this.deadlockMonitorThread.setDaemon(true);
// for preload
deadlockMonitorTask.doTask();
}
AgentInfoSender: agent信息上报定时任务,是个timer,3秒上报一次
DefaultAgentStatMonitor: agent状态信息上报(jvm状态等),线程数为1的定时线程池(ScheduledExecutorService),延迟5秒执行,每5秒上报一次
private final ScheduledExecutorService execut