/** * {@inheritDoc} */ @Override public void afterPropertiesSet() throws Exception { agentJar = SpringAgent.getInspectitJarFile(); }
/** * Initializes log directory location. */ private static synchronized void initLogDirLocation() { if (null == logDirLocation) { // set the location of logs to just [agent-path]/logs/startup for start File agentJar = SpringAgent.getInspectitJarFile(); logDirLocation = agentJar.getParent() + File.separator + "logs" + File.separator + "startup"; // NOPMD } }
/** * Sets the agent name and re-initializes the logging so that the agentName is used as folder * for logging. * * @param agentName * Agent name. */ public static void setAgentNameAndInitLogging(String agentName) { File agentJar = SpringAgent.getInspectitJarFile(); if (null == agentJar) { return; } // set the location of logs based to agent name logDirLocation = agentJar.getParent() + File.separator + "logs" + File.separator + agentName; initLogging(); }
File agentJar = SpringAgent.getInspectitJarFile(); if (null == agentJar) { return;