org.hyperic.sigar.NetStat.getTcpSynRecv()方法的使用及代码示例

x33g5p2x  于2022-01-25 转载在 其他  
字(4.5k)|赞(0)|评价(0)|浏览(147)

本文整理了Java中org.hyperic.sigar.NetStat.getTcpSynRecv()方法的一些代码示例,展示了NetStat.getTcpSynRecv()的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。NetStat.getTcpSynRecv()方法的具体详情如下:
包路径:org.hyperic.sigar.NetStat
类名称:NetStat
方法名:getTcpSynRecv

NetStat.getTcpSynRecv介绍

暂无

代码示例

代码示例来源:origin: apache/incubator-druid

.put("sys/tcp/state/synRecv", (long) netStat.getTcpSynRecv())
.put("sys/tcp/state/finWait1", (long) netStat.getTcpFinWait1())
.put("sys/tcp/state/finWait2", (long) netStat.getTcpFinWait2())

代码示例来源:origin: com.axway.ats.framework.agent.standalone/ats-agent-monitoring

@Override
  public float poll() {
    return fixLongValue( sigarWrapper.netstat.getTcpSynRecv() );
  }
};

代码示例来源:origin: griddynamics/jagger

private static Map<String, String> toMap(NetStat netStat) {
  Map<String, String> result = Maps.newHashMap();
  result.put("allInboundTotal", "" + netStat.getAllInboundTotal());
  result.put("allOutboundTotal", "" + netStat.getAllOutboundTotal());
  result.put("tcpBound", "" + netStat.getTcpBound());
  result.put("tcpClose", "" + netStat.getTcpClose());
  result.put("tcpCloseWait", "" + netStat.getTcpCloseWait());
  result.put("tcpClosing", "" + netStat.getTcpClosing());
  result.put("tcpEstablished", "" + netStat.getTcpEstablished());
  result.put("tcpFinWait1", "" + netStat.getTcpFinWait1());
  result.put("tcpFinWait2", "" + netStat.getTcpFinWait2());
  result.put("tcpIdle", "" + netStat.getTcpIdle());
  result.put("tcpInboundTotal", "" + netStat.getTcpInboundTotal());
  result.put("tcpLastAck", "" + netStat.getTcpLastAck());
  result.put("tcpListen", "" + netStat.getTcpListen());
  result.put("tcpOutboundTotal", "" + netStat.getTcpOutboundTotal());
  result.put("tcpStates", "" + netStat.getTcpStates());
  result.put("tcpSynRecv", "" + netStat.getTcpSynRecv());
  result.put("tcpSynSent", "" + netStat.getTcpSynSent());
  result.put("tcpTimeWait", "" + netStat.getTcpTimeWait());
  return result;
}

代码示例来源:origin: metamx/java-util

.put("sys/tcp/state/synRecv", (long) netStat.getTcpSynRecv())
.put("sys/tcp/state/finWait1", (long) netStat.getTcpFinWait1())
.put("sys/tcp/state/finWait2", (long) netStat.getTcpFinWait2())

代码示例来源:origin: com.metamx/java-util

.put("sys/tcp/state/synRecv", (long) netStat.getTcpSynRecv())
.put("sys/tcp/state/finWait1", (long) netStat.getTcpFinWait1())
.put("sys/tcp/state/finWait2", (long) netStat.getTcpFinWait2())

代码示例来源:origin: io.druid/java-util

.put("sys/tcp/state/synRecv", (long) netStat.getTcpSynRecv())
.put("sys/tcp/state/finWait1", (long) netStat.getTcpFinWait1())
.put("sys/tcp/state/finWait2", (long) netStat.getTcpFinWait2())

代码示例来源:origin: org.apache.druid/java-util

.put("sys/tcp/state/synRecv", (long) netStat.getTcpSynRecv())
.put("sys/tcp/state/finWait1", (long) netStat.getTcpFinWait1())
.put("sys/tcp/state/finWait2", (long) netStat.getTcpFinWait2())

代码示例来源:origin: com.metamx/server-metrics

.put("sys/tcp/state/synRecv", (long) netStat.getTcpSynRecv())
.put("sys/tcp/state/finWait1", (long) netStat.getTcpFinWait1())
.put("sys/tcp/state/finWait2", (long) netStat.getTcpFinWait2())

代码示例来源:origin: griddynamics/jagger

@Override
public TcpData getTcpData() {
  TcpData data = new TcpData();
  try {
    NetStat stat = sigar.getNetStat();
    data.setTcpBound(stat.getTcpBound());
    data.setTcpEstablished(stat.getTcpEstablished());
    data.setTcpIdle(stat.getTcpIdle());
    data.setTcpListen(stat.getTcpListen());
    data.setTcpSynchronizedReceived(stat.getTcpSynRecv());
    long inboundBytes = 0;
    long outboundBytes = 0;
    for(String netInterface : sigar.getNetInterfaceList()) {
      for(String mask : interfaceNames) {
        if(netInterface.matches(mask)) {
          inboundBytes += sigar.getNetInterfaceStat(netInterface).getRxBytes();
          outboundBytes += sigar.getNetInterfaceStat(netInterface).getTxBytes();
        }
      }
    }
    data.setTcpInboundTotal(inboundBytes);
    data.setTcpOutboundTotal(outboundBytes);
    logger.debug("getTcpData: {}", data);
  } catch (SigarException e) {
    logger.warn("Exception during getTcpData", e);
  }
  return data;
}

代码示例来源:origin: kg.apc/perfmon

break;
case SYN_RECV:
  val = stat.getTcpSynRecv();
  break;
case TIME_WAIT:

代码示例来源:origin: undera/perfmon-agent

break;
case SYN_RECV:
  val = stat.getTcpSynRecv();
  break;
case TIME_WAIT:

相关文章