Codota Logo
Configure.getValue
Code IndexAdd Codota to your IDE (free)

How to use
getValue
method
in
scouter.agent.Configure

Best Java code snippets using scouter.agent.Configure.getValue (Showing top 20 results out of 315)

  • Add the Codota plugin to your IDE and get smart completions
private void myMethod () {
ArrayList a =
  • Codota Iconnew ArrayList<String>()
  • Codota Iconnew ArrayList()
  • Codota Iconnew ArrayList<Object>()
  • Smart code suggestions by Codota
}
origin: scouter-project/scouter

public int getInt(String key, int def) {
  try {
    String v = getValue(key);
    if (v != null)
      return Integer.parseInt(v);
  } catch (Exception e) {
  }
  return def;
}
origin: scouter-project/scouter

public boolean getBoolean(String key, boolean def) {
  try {
    String v = getValue(key);
    if (v != null)
      return Boolean.parseBoolean(v);
  } catch (Exception e) {
  }
  return def;
}
origin: scouter-project/scouter

public boolean getBoolean(String key, boolean def) {
  try {
    String v = getValue(key);
    if (v != null)
      return Boolean.parseBoolean(v);
  } catch (Exception e) {
  }
  return def;
}
origin: scouter-project/scouter

public long getLong(String key, long def) {
  try {
    String v = getValue(key);
    if (v != null)
      return Long.parseLong(v);
  } catch (Exception e) {
  }
  return def;
}
origin: scouter-project/scouter

public long getLong(String key, long def) {
  try {
    String v = getValue(key);
    if (v != null)
      return Long.parseLong(v);
  } catch (Exception e) {
  }
  return def;
}
origin: scouter-project/scouter

public int getInt(String key, int def) {
  try {
    String v = getValue(key);
    if (v != null)
      return Integer.parseInt(v);
  } catch (Exception e) {
  }
  return def;
}
origin: scouter-project/scouter

public long getLong(String key, long def) {
  try {
    String v = getValue(key);
    if (v != null)
      return Long.parseLong(v);
  } catch (Exception e) {
  }
  return def;
}
origin: scouter-project/scouter

public int getInt(String key, int def) {
  try {
    String v = getValue(key);
    if (v != null)
      return Integer.parseInt(v);
  } catch (Exception e) {
  }
  return def;
}
origin: scouter-project/scouter

public boolean getBoolean(String key, boolean def) {
  try {
    String v = getValue(key);
    if (v != null)
      return Boolean.parseBoolean(v);
  } catch (Exception e) {
  }
  return def;
}
origin: scouter-project/scouter

public int getInt(String key, int def, int min) {
  try {
    String v = getValue(key);
    if (v != null) {
      return Math.max(Integer.parseInt(v), min);
    }
  } catch (Exception e) {
  }
  return Math.max(def, min);
}
origin: scouter-project/scouter

public int getInt(String key, int def, int min) {
  try {
    String v = getValue(key);
    if (v != null) {
      return Math.max(Integer.parseInt(v), min);
    }
  } catch (Exception e) {
  }
  return Math.max(def, min);
}
origin: scouter-project/scouter

public int getInt(String key, int def, int min) {
  try {
    String v = getValue(key);
    if (v != null) {
      return Math.max(Integer.parseInt(v), min);
    }
  } catch (Exception e) {
  }
  return Math.max(def, min);
}
origin: scouter-project/scouter

public synchronized void resetObjInfo() {
  String detected = CounterConstants.HOST;
  if (SystemUtil.IS_LINUX) {
    detected = CounterConstants.LINUX;
  } else if (SystemUtil.IS_WINDOWS) {
    detected = CounterConstants.WINDOWS;
  } else if (SystemUtil.IS_MAC_OSX) {
    detected = CounterConstants.OSX;
  } else if (SystemUtil.IS_AIX) {
    detected = CounterConstants.AIX;
  } else if (SystemUtil.IS_HP_UX) {
    detected = CounterConstants.HPUX;
  }
  this.objDetectedType = detected;
  this.monitoring_group_type = getValue("monitoring_group_type");
  this.obj_type = StringUtil.isEmpty(this.monitoring_group_type) ? getValue("obj_type", detected) : this.monitoring_group_type;
  this.obj_name = getValue("obj_name", SysJMX.getHostName());
  this.objName = "/" + this.obj_name;
  this.objHash = HashUtil.hash(objName);
}
origin: scouter-project/scouter

this.monitoring_group_type = getValue("monitoring_group_type");
this.obj_type = StringUtil.isEmpty(this.monitoring_group_type) ? getValue("obj_type", detected) : this.monitoring_group_type;
this.objExtType = ObjTypeDetector.objExtType;
  detected = CounterConstants.HPUX;
this.obj_host_type = getValue("obj_host_type", detected);
this.obj_host_name = getValue("obj_host_name", SysJMX.getHostName());
this.objHostName = "/" + this.obj_host_name;
this.objHostHash = HashUtil.hash(objHostName);
  defaultName = this.obj_type + "1";
this.obj_name = getValue("obj_name", System.getProperty("jvmRoute", defaultName));
this.objName = objHostName + "/" + this.obj_name;
this.objHash = HashUtil.hash(objName);
origin: scouter-project/scouter

this.monitoring_group_type = getValue("monitoring_group_type");
this.obj_type = StringUtil.isEmpty(this.monitoring_group_type) ? getValue("obj_type", detected) : this.monitoring_group_type;
this.objExtType = ObjTypeDetector.objExtType;
  detected = CounterConstants.HPUX;
this.obj_host_type = getValue("obj_host_type", detected);
this.obj_host_name = getValue("obj_host_name", SysJMX.getHostName());
this.objHostName = "/" + this.obj_host_name;
this.objHostHash = HashUtil.hash(objHostName);
  defaultName = this.obj_type + "1";
this.obj_name = getValue("obj_name", System.getProperty("jvmRoute", defaultName));
this.objName = objHostName + "/" + this.obj_name;
this.objHash = HashUtil.hash(objName);
origin: scouter-project/scouter

private StringSet getStringSet(String key, String deli) {
  StringSet set = new StringSet();
  String v = getValue(key);
  if (v != null) {
    String[] vv = StringUtil.split(v, deli);
    for (String x : vv) {
      x = StringUtil.trimToEmpty(x);
      if (x.length() > 0)
        set.put(x);
    }
  }
  return set;
}
origin: scouter-project/scouter

private StringSet getStringSet(String key, String deli) {
  StringSet set = new StringSet();
  String v = getValue(key);
  if (v != null) {
    String[] vv = StringUtil.split(v, deli);
    for (String x : vv) {
      x = StringUtil.trimToEmpty(x);
      if (x.length() > 0)
        set.put(x);
    }
  }
  return set;
}
origin: scouter-project/scouter

private StringSet getStringSet(String key, String deli) {
  StringSet set = new StringSet();
  String v = getValue(key);
  if (v != null) {
    String[] vv = StringUtil.split(v, deli);
    for (String x : vv) {
      x = StringUtil.trimToEmpty(x);
      if (x.length() > 0)
        set.put(x);
    }
  }
  return set;
}
origin: scouter-project/scouter

public void process(CounterBasket pw) throws IOException {
  Configure conf = Configure.getInstance();
  boolean redisEnabled = conf.getBoolean("redis_enabled", false);
  if (redisEnabled) {
    String serverIp = conf.getValue("redis_server_ip", "127.0.0.1");
    int serverPort = conf.getInt("redis_server_port", 6379);
    String perfInfo = getRedisPerfInfo(serverIp, serverPort);
    String[] lines = perfInfo.split("\n");
    PerfCounterPack p = pw.getPack(conf.getObjName(), TimeTypeEnum.REALTIME);
    for (String line : lines) {
      String key = line.substring(0, line.indexOf(':'));
      String value = line.substring(line.indexOf(':') + 1);
      if (floatSet.contains(key)) {
        p.put(key, new FloatValue(Float.valueOf(value.trim())));
      }
      if (decimalSet.contains(key)) {
        p.put(key, new DecimalValue(Long.valueOf(value.trim())));
      }
    }
  }
}
origin: scouter-project/scouter

this.mgr_log_ignore_ids = getStringSet("mgr_log_ignore_ids", ",");
this.net_local_udp_ip = getValue("net_local_udp_ip");
this.net_local_udp_port = getInt("net_local_udp_port", 0);
this.net_collector_ip = getValue("net_collector_ip", getValue("server.addr", "127.0.0.1"));
this.net_collector_udp_port = getInt("net_collector_udp_port", getInt("server.port", NetConstants.SERVER_UDP_PORT));
this.net_collector_tcp_port = getInt("net_collector_tcp_port", getInt("server.port", NetConstants.SERVER_TCP_PORT));
this.counter_netstat_enabled = getBoolean("counter_netstat_enabled", true);
this.log_dir = getValue("log_dir", "./logs");
this.log_rotation_enalbed = getBoolean("log_rotation_enalbed", true);
this.log_keep_days = getInt("log_keep_days", 365);
this.counter_object_registry_path = getValue("counter_object_registry_path", "/tmp/scouter");
scouter.agentConfiguregetValue

Popular methods of Configure

  • <init>
  • apply
  • getBoolean
  • getConfigureDesc
  • getConfigureValueType
  • getInstance
  • getInt
  • getKeyValueInfo
  • getLong
  • getObjDetectedType
  • getObjHash
  • getObjName
  • getObjHash,
  • getObjName,
  • getPropertyFile,
  • getStringSet,
  • loadText,
  • printConfig,
  • reload,
  • resetObjInfo,
  • saveText

Popular in Java

  • Start an intent from android
  • setRequestProperty (URLConnection)
  • onRequestPermissionsResult (Fragment)
  • getSupportFragmentManager (FragmentActivity)
    Return the FragmentManager for interacting with fragments associated with this activity.
  • ConnectException (java.net)
    A ConnectException is thrown if a connection cannot be established to a remote host on a specific po
  • Date (java.util)
    A specific moment in time, with millisecond precision. Values typically come from System#currentTime
  • HashMap (java.util)
    HashMap is an implementation of Map. All optional operations are supported.All elements are permitte
  • SortedSet (java.util)
    A Set that further provides a total ordering on its elements. The elements are ordered using their C
  • Vector (java.util)
    The Vector class implements a growable array of objects. Like an array, it contains components that
  • TimeUnit (java.util.concurrent)
    A TimeUnit represents time durations at a given unit of granularity and provides utility methods to
Codota Logo
  • Products

    Search for Java codeSearch for JavaScript codeEnterprise
  • IDE Plugins

    IntelliJ IDEAWebStormAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimAtomGoLandRubyMineEmacsJupyter
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogCodota Academy Plugin user guide Terms of usePrivacy policyJava Code IndexJavascript Code Index
Get Codota for your IDE now