@Nullable Profile getAuxThreadProfile(String agentId, String traceId) throws Exception { ConnectedAgent connectedAgent = connectedAgents.get(agentId); if (connectedAgent == null) { throw new AgentNotConnectedException(); } return connectedAgent.getAuxThreadProfile(traceId); }