/** * Reload the config from the default config file * * @exception java.io.IOException * Thrown if the specified config file cannot be * read/loaded * @throws java.io.IOException * if any. */ public static void reload() throws IOException { init(); getInstance().update(); }
public Map<String, String> getRuntimeAttributes(InetAddress address) { return WmiPeerFactory.getInstance().getAgentConfig(address).toMap(); }
public Map<String, String> getRuntimeAttributes(InetAddress address) { return WmiPeerFactory.getInstance().getAgentConfig(address).toMap(); }
@Override public Map<String, Object> getRuntimeAttributes(CollectionAgent agent, Map<String, Object> parameters) { final Map<String, Object> runtimeAttributes = new HashMap<>(); final String collectionName = ParameterMap.getKeyedString(parameters, "collection", ParameterMap.getKeyedString(parameters, "wmi-collection", null)); final WmiCollection collection = WmiDataCollectionConfigFactory.getInstance().getWmiCollection(collectionName); runtimeAttributes.put(WMI_COLLECTION_KEY, collection); final WmiAgentConfig agentConfig = WmiPeerFactory.getInstance().getAgentConfig(agent.getAddress()); runtimeAttributes.put(WMI_AGENT_CONFIG_KEY, agentConfig); return runtimeAttributes; }
@Override public Map<String, Object> getRuntimeAttributes(CollectionAgent agent, Map<String, Object> parameters) { final Map<String, Object> runtimeAttributes = new HashMap<>(); final String collectionName = ParameterMap.getKeyedString(parameters, "collection", ParameterMap.getKeyedString(parameters, "wmi-collection", null)); final WmiCollection collection = WmiDataCollectionConfigFactory.getInstance().getWmiCollection(collectionName); runtimeAttributes.put(WMI_COLLECTION_KEY, collection); final WmiAgentConfig agentConfig = WmiPeerFactory.getInstance().getAgentConfig(agent.getAddress()); runtimeAttributes.put(WMI_AGENT_CONFIG_KEY, agentConfig); return runtimeAttributes; }
final InetAddress ipAddr = svc.getAddress(); final WmiAgentConfig agentConfig = WmiPeerFactory.getInstance().getAgentConfig(ipAddr); String matchType = DEFAULT_WMI_MATCH_TYPE; String compVal = DEFAULT_WMI_COMP_VAL;
final InetAddress ipAddr = svc.getAddress(); final WmiAgentConfig agentConfig = WmiPeerFactory.getInstance().getAgentConfig(ipAddr); String matchType = DEFAULT_WMI_MATCH_TYPE; String compVal = DEFAULT_WMI_COMP_VAL;