All Downloads are FREE. Search and download functionalities are using the official Maven repository.

org.apache.hadoop.hbase.tmpl.regionserver.RSStatusTmplImpl Maven / Gradle / Ivy

There is a newer version: 3.0.0-beta-1
Show newest version
// Autogenerated Jamon implementation
// /home/apurtell/tmp/RM/hbase/hbase-server/src/main/jamon/org/apache/hadoop/hbase/tmpl/regionserver/RSStatusTmpl.jamon

package org.apache.hadoop.hbase.tmpl.regionserver;

// 27, 1
import java.util.*;
// 28, 1
import org.apache.hadoop.hbase.regionserver.HRegionServer;
// 29, 1
import org.apache.hadoop.hbase.client.RegionInfo;
// 30, 1
import org.apache.hadoop.hbase.ServerName;
// 31, 1
import org.apache.hadoop.hbase.HBaseConfiguration;
// 32, 1
import org.apache.hadoop.hbase.io.hfile.CacheConfig;
// 33, 1
import org.apache.hadoop.hbase.shaded.protobuf.ProtobufUtil;
// 34, 1
import org.apache.hadoop.hbase.shaded.protobuf.generated.AdminProtos.ServerInfo;
// 35, 1
import org.apache.hadoop.hbase.util.JvmVersion;
// 36, 1
import org.apache.hadoop.hbase.zookeeper.MasterAddressTracker;

public class RSStatusTmplImpl
  extends org.jamon.AbstractTemplateImpl
  implements org.apache.hadoop.hbase.tmpl.regionserver.RSStatusTmpl.Intf

{
  private final HRegionServer regionServer;
  private final String bcn;
  private final String bcv;
  private final String filter;
  private final String format;
  // 56, 1
  
  public String formatZKString() {
    StringBuilder quorums = new StringBuilder();
    String zkQuorum = regionServer.getZooKeeper().getQuorum();

    if (null == zkQuorum) {
      return quorums.toString();
    }

    String[] zks = zkQuorum.split(",");

    if (zks.length == 0) {
      return quorums.toString();
    }

    for(int i = 0; i < zks.length; ++i) {
      quorums.append(zks[i].trim());

      if (i != (zks.length - 1)) {
        quorums.append("
"); } } return quorums.toString(); } protected static org.apache.hadoop.hbase.tmpl.regionserver.RSStatusTmpl.ImplData __jamon_setOptionalArguments(org.apache.hadoop.hbase.tmpl.regionserver.RSStatusTmpl.ImplData p_implData) { if(! p_implData.getBcn__IsNotDefault()) { p_implData.setBcn(""); } if(! p_implData.getBcv__IsNotDefault()) { p_implData.setBcv(""); } if(! p_implData.getFilter__IsNotDefault()) { p_implData.setFilter("general"); } if(! p_implData.getFormat__IsNotDefault()) { p_implData.setFormat("html"); } return p_implData; } public RSStatusTmplImpl(org.jamon.TemplateManager p_templateManager, org.apache.hadoop.hbase.tmpl.regionserver.RSStatusTmpl.ImplData p_implData) { super(p_templateManager, __jamon_setOptionalArguments(p_implData)); regionServer = p_implData.getRegionServer(); bcn = p_implData.getBcn(); bcv = p_implData.getBcv(); filter = p_implData.getFilter(); format = p_implData.getFormat(); } @Override public void renderNoFlush(final java.io.Writer jamonWriter) throws java.io.IOException { // 39, 1 if (format.equals("json") && bcn != null && bcn.length() > 0 ) { // 39, 66 jamonWriter.write("\n "); // 40, 3 { org.apache.hadoop.hbase.tmpl.regionserver.BlockCacheViewTmpl __jamon__var_0 = new org.apache.hadoop.hbase.tmpl.regionserver.BlockCacheViewTmpl(this.getTemplateManager()); __jamon__var_0.renderNoFlush(jamonWriter, new CacheConfig(regionServer.getConfiguration()), regionServer.getConfiguration(), bcn, bcv, regionServer.getBlockCache().orElse(null) ); } // 40, 210 jamonWriter.write("\n "); // 41, 3 return; } // 42, 1 else if (format.equals("json") ) { // 42, 34 jamonWriter.write("\n "); // 43, 3 { org.apache.hadoop.hbase.tmpl.common.TaskMonitorTmpl __jamon__var_1 = new org.apache.hadoop.hbase.tmpl.common.TaskMonitorTmpl(this.getTemplateManager()); __jamon__var_1.setFilter(filter); __jamon__var_1.setFormat("json" ); __jamon__var_1.renderNoFlush(jamonWriter); } // 43, 68 jamonWriter.write("\n "); // 44, 3 return; } // 45, 7 jamonWriter.write("\n"); // 46, 1 ServerInfo serverInfo = ProtobufUtil.getServerInfo(null, regionServer.getRSRpcServices()); ServerName serverName = ProtobufUtil.toServerName(serverInfo.getServerName()); List onlineRegions = ProtobufUtil.getOnlineRegions(regionServer.getRSRpcServices()); MasterAddressTracker masterAddressTracker = regionServer.getMasterAddressTracker(); ServerName masterServerName = masterAddressTracker == null ? null : masterAddressTracker.getMasterAddress(); int infoPort = masterAddressTracker == null ? 0 : masterAddressTracker.getMasterInfoPort(); // 83, 1 jamonWriter.write("\n\n\n \n \n HBase Region Server: "); // 88, 33 org.jamon.escaping.Escaping.NONE.write(org.jamon.emit.StandardEmitter.valueOf(serverName.getHostname()), jamonWriter); // 88, 63 jamonWriter.write("\n \n \n\n \n \n \n \n\n \n\n
\n
\n
\n \n \"HBase\n
\n
\n \n
\n
\n
\n
\n\n
\n
\n
\n

RegionServer "); // 130, 37 org.jamon.escaping.Escaping.NONE.write(org.jamon.emit.StandardEmitter.valueOf(serverName), jamonWriter); // 130, 53 jamonWriter.write("

\n
\n
\n
\n\n
\n

Server Metrics

\n "); // 137, 5 { org.apache.hadoop.hbase.tmpl.regionserver.ServerMetricsTmpl __jamon__var_2 = new org.apache.hadoop.hbase.tmpl.regionserver.ServerMetricsTmpl(this.getTemplateManager()); __jamon__var_2.renderNoFlush(jamonWriter, regionServer.getMetrics().getRegionServerWrapper(), regionServer.getRpcServer().getMetrics().getHBaseServerWrapper(), regionServer.getRpcServer().getByteBuffAllocator()); } // 139, 75 jamonWriter.write("\n
\n\n
\n

Block Cache

\n "); // 144, 5 { org.apache.hadoop.hbase.tmpl.regionserver.BlockCacheTmpl __jamon__var_3 = new org.apache.hadoop.hbase.tmpl.regionserver.BlockCacheTmpl(this.getTemplateManager()); __jamon__var_3.renderNoFlush(jamonWriter, new CacheConfig(regionServer.getConfiguration()), regionServer.getConfiguration(), regionServer.getBlockCache().orElse(null) ); } // 144, 179 jamonWriter.write("\n
\n\n
\n "); // 148, 5 { org.apache.hadoop.hbase.tmpl.common.TaskMonitorTmpl __jamon__var_4 = new org.apache.hadoop.hbase.tmpl.common.TaskMonitorTmpl(this.getTemplateManager()); __jamon__var_4.setFilter(filter); __jamon__var_4.setParent("/rs-status" ); __jamon__var_4.renderNoFlush(jamonWriter); } // 148, 76 jamonWriter.write("\n
\n\n
\n

Regions

\n "); // 153, 5 { org.apache.hadoop.hbase.tmpl.regionserver.RegionListTmpl __jamon__var_5 = new org.apache.hadoop.hbase.tmpl.regionserver.RegionListTmpl(this.getTemplateManager()); __jamon__var_5.renderNoFlush(jamonWriter, regionServer, onlineRegions); } // 153, 86 jamonWriter.write("\n
\n\n
\n

Replication Status

\n "); // 158, 5 { org.apache.hadoop.hbase.tmpl.regionserver.ReplicationStatusTmpl __jamon__var_6 = new org.apache.hadoop.hbase.tmpl.regionserver.ReplicationStatusTmpl(this.getTemplateManager()); __jamon__var_6.renderNoFlush(jamonWriter, regionServer); } // 158, 62 jamonWriter.write("\n
\n\n
\n

Software Attributes

\n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n
Attribute NameValueDescription
JVM Version"); // 171, 17 org.jamon.escaping.Escaping.NONE.write(org.jamon.emit.StandardEmitter.valueOf(JvmVersion.getVersion()), jamonWriter); // 171, 46 jamonWriter.write("JVM vendor and version
HBase Version"); // 176, 17 org.jamon.escaping.Escaping.NONE.write(org.jamon.emit.StandardEmitter.valueOf(org.apache.hadoop.hbase.util.VersionInfo.getVersion()), jamonWriter); // 176, 76 jamonWriter.write(", revision="); // 176, 87 org.jamon.escaping.Escaping.NONE.write(org.jamon.emit.StandardEmitter.valueOf(org.apache.hadoop.hbase.util.VersionInfo.getRevision()), jamonWriter); // 176, 147 jamonWriter.write("HBase version and revision
HBase Compiled"); // 181, 17 org.jamon.escaping.Escaping.NONE.write(org.jamon.emit.StandardEmitter.valueOf(org.apache.hadoop.hbase.util.VersionInfo.getDate()), jamonWriter); // 181, 73 jamonWriter.write(", "); // 181, 75 org.jamon.escaping.Escaping.NONE.write(org.jamon.emit.StandardEmitter.valueOf(org.apache.hadoop.hbase.util.VersionInfo.getUser()), jamonWriter); // 181, 131 jamonWriter.write("When HBase version was compiled and by whom
HBase Source Checksum"); // 186, 17 org.jamon.escaping.Escaping.NONE.write(org.jamon.emit.StandardEmitter.valueOf(org.apache.hadoop.hbase.util.VersionInfo.getSrcChecksum()), jamonWriter); // 186, 80 jamonWriter.write("HBase source SHA512 checksum
Hadoop Version"); // 191, 17 org.jamon.escaping.Escaping.NONE.write(org.jamon.emit.StandardEmitter.valueOf(org.apache.hadoop.util.VersionInfo.getVersion()), jamonWriter); // 191, 70 jamonWriter.write(", revision="); // 191, 81 org.jamon.escaping.Escaping.NONE.write(org.jamon.emit.StandardEmitter.valueOf(org.apache.hadoop.util.VersionInfo.getRevision()), jamonWriter); // 191, 135 jamonWriter.write("Hadoop version and revision
Hadoop Compiled"); // 196, 17 org.jamon.escaping.Escaping.NONE.write(org.jamon.emit.StandardEmitter.valueOf(org.apache.hadoop.util.VersionInfo.getDate()), jamonWriter); // 196, 67 jamonWriter.write(", "); // 196, 69 org.jamon.escaping.Escaping.NONE.write(org.jamon.emit.StandardEmitter.valueOf(org.apache.hadoop.util.VersionInfo.getUser()), jamonWriter); // 196, 119 jamonWriter.write("When Hadoop version was compiled and by whom
Hadoop Source Checksum"); // 201, 17 org.jamon.escaping.Escaping.NONE.write(org.jamon.emit.StandardEmitter.valueOf(org.apache.hadoop.util.VersionInfo.getSrcChecksum()), jamonWriter); // 201, 74 jamonWriter.write("Hadoop source MD5 checksum
ZooKeeper Client Version"); // 206, 17 org.jamon.escaping.Escaping.NONE.write(org.jamon.emit.StandardEmitter.valueOf(org.apache.zookeeper.Version.getVersion()), jamonWriter); // 206, 64 jamonWriter.write(", revision="); // 206, 75 org.jamon.escaping.Escaping.NONE.write(org.jamon.emit.StandardEmitter.valueOf(org.apache.zookeeper.Version.getRevisionHash()), jamonWriter); // 206, 127 jamonWriter.write("ZooKeeper client version and revision hash
ZooKeeper Client Compiled"); // 211, 17 org.jamon.escaping.Escaping.NONE.write(org.jamon.emit.StandardEmitter.valueOf(org.apache.zookeeper.Version.getBuildDate()), jamonWriter); // 211, 66 jamonWriter.write("When ZooKeeper client version was compiled
ZooKeeper Quorum"); // 217, 17 org.jamon.escaping.Escaping.NONE.write(org.jamon.emit.StandardEmitter.valueOf(formatZKString()), jamonWriter); // 217, 39 jamonWriter.write("Addresses of all registered ZK servers
Coprocessors"); // 222, 17 org.jamon.escaping.Escaping.NONE.write(org.jamon.emit.StandardEmitter.valueOf(java.util.Arrays.toString(regionServer.getRegionServerCoprocessors())), jamonWriter); // 222, 92 jamonWriter.write("Coprocessors currently loaded by this regionserver
RS Start Time"); // 227, 17 org.jamon.escaping.Escaping.NONE.write(org.jamon.emit.StandardEmitter.valueOf(new Date(regionServer.getStartcode())), jamonWriter); // 227, 60 jamonWriter.write("Date stamp of when this region server was started
HBase Master\n "); // 233, 17 if (masterServerName == null ) { // 233, 49 jamonWriter.write("\n No master found\n "); } // 235, 17 else { // 235, 24 jamonWriter.write("\n "); // 236, 17 String host = masterServerName.getHostname() + ":" + infoPort; String url = "//" + host + "/master-status"; // 240, 17 jamonWriter.write(""); // 240, 37 org.jamon.escaping.Escaping.NONE.write(org.jamon.emit.StandardEmitter.valueOf(host), jamonWriter); // 240, 47 jamonWriter.write("\n "); } // 241, 23 jamonWriter.write("\n Address of HBase Master
\n
\n
\n
\n\n\n\n\n\n\n\n"); } }




© 2015 - 2024 Weber Informatics LLC | Privacy Policy