Пример #1
0
 public NodeInfo(Context context, ResourceView resourceView)
 {
     // JAXB needs this
     this.id           = context.GetNodeId().ToString();
     this.nodeHostName = context.GetNodeId().GetHost();
     this.totalVmemAllocatedContainersMB = resourceView.GetVmemAllocatedForContainers(
         ) / BytesInMb;
     this.vmemCheckEnabled = resourceView.IsVmemCheckEnabled();
     this.totalPmemAllocatedContainersMB = resourceView.GetPmemAllocatedForContainers(
         ) / BytesInMb;
     this.pmemCheckEnabled = resourceView.IsPmemCheckEnabled();
     this.totalVCoresAllocatedContainers = resourceView.GetVCoresAllocatedForContainers
                                               ();
     this.nodeHealthy               = context.GetNodeHealthStatus().GetIsNodeHealthy();
     this.lastNodeUpdateTime        = context.GetNodeHealthStatus().GetLastHealthReportTime();
     this.healthReport              = context.GetNodeHealthStatus().GetHealthReport();
     this.nodeManagerVersion        = YarnVersionInfo.GetVersion();
     this.nodeManagerBuildVersion   = YarnVersionInfo.GetBuildVersion();
     this.nodeManagerVersionBuiltOn = YarnVersionInfo.GetDate();
     this.hadoopVersion             = VersionInfo.GetVersion();
     this.hadoopBuildVersion        = VersionInfo.GetBuildVersion();
     this.hadoopVersionBuiltOn      = VersionInfo.GetDate();
 }