You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@uima.apache.org by de...@apache.org on 2016/03/03 20:14:41 UTC
svn commit: r1733515 - in
/uima/sandbox/uima-ducc/trunk/uima-ducc-web/src/main:
java/org/apache/uima/ducc/ws/ java/org/apache/uima/ducc/ws/server/
webapp/root/
Author: degenaro
Date: Thu Mar 3 19:14:41 2016
New Revision: 1733515
URL: http://svn.apache.org/viewvc?rev=1733515&view=rev
Log:
UIMA-4815 DUCC Web Server (WS) System Machines page re-imagined
Added:
uima/sandbox/uima-ducc/trunk/uima-ducc-web/src/main/java/org/apache/uima/ducc/ws/Distiller.java (with props)
uima/sandbox/uima-ducc/trunk/uima-ducc-web/src/main/java/org/apache/uima/ducc/ws/Helper.java (with props)
Modified:
uima/sandbox/uima-ducc/trunk/uima-ducc-web/src/main/java/org/apache/uima/ducc/ws/WebServerComponent.java
uima/sandbox/uima-ducc/trunk/uima-ducc-web/src/main/java/org/apache/uima/ducc/ws/server/DuccHandlerClassic.java
uima/sandbox/uima-ducc/trunk/uima-ducc-web/src/main/java/org/apache/uima/ducc/ws/server/DuccHandlerJsonFormat.java
uima/sandbox/uima-ducc/trunk/uima-ducc-web/src/main/webapp/root/system.machines.jsp
Added: uima/sandbox/uima-ducc/trunk/uima-ducc-web/src/main/java/org/apache/uima/ducc/ws/Distiller.java
URL: http://svn.apache.org/viewvc/uima/sandbox/uima-ducc/trunk/uima-ducc-web/src/main/java/org/apache/uima/ducc/ws/Distiller.java?rev=1733515&view=auto
==============================================================================
--- uima/sandbox/uima-ducc/trunk/uima-ducc-web/src/main/java/org/apache/uima/ducc/ws/Distiller.java (added)
+++ uima/sandbox/uima-ducc/trunk/uima-ducc-web/src/main/java/org/apache/uima/ducc/ws/Distiller.java Thu Mar 3 19:14:41 2016
@@ -0,0 +1,219 @@
+package org.apache.uima.ducc.ws;
+
+import java.util.HashMap;
+import java.util.Map;
+import java.util.Set;
+
+import org.apache.uima.ducc.common.NodeIdentity;
+import org.apache.uima.ducc.common.utils.DuccLogger;
+import org.apache.uima.ducc.common.utils.DuccLoggerComponents;
+import org.apache.uima.ducc.common.utils.id.DuccId;
+import org.apache.uima.ducc.transport.event.OrchestratorStateDuccEvent;
+import org.apache.uima.ducc.transport.event.common.IDuccProcess;
+import org.apache.uima.ducc.transport.event.common.IDuccProcessMap;
+import org.apache.uima.ducc.transport.event.common.IDuccReservation;
+import org.apache.uima.ducc.transport.event.common.IDuccReservationMap;
+import org.apache.uima.ducc.transport.event.common.IDuccWork;
+import org.apache.uima.ducc.transport.event.common.IDuccWorkJob;
+import org.apache.uima.ducc.transport.event.common.IDuccWorkMap;
+import org.apache.uima.ducc.transport.event.common.IDuccWorkReservation;
+
+public class Distiller {
+
+ private static DuccLogger logger = DuccLoggerComponents.getWsLogger(Distiller.class.getName());
+ private static DuccId jobid = null;
+
+ // map of key = machine name, value = bytes allocated
+ private static volatile Map<String,Long> map = new HashMap<String,Long>();
+
+ /**
+ * get map of key = machine name, value = bytes allocated
+ */
+ public static Map<String,Long> getMap() {
+ HashMap<String,Long> retVal = new HashMap<String,Long>();
+ retVal.putAll(map);
+ return retVal;
+ }
+
+ /**
+ * for each OR publication that arrives, calculate a new map of <machine name, bytes allocated>
+ */
+ public static Map<String,Long> deriveMachineMemoryInUse(OrchestratorStateDuccEvent duccEvent) {
+ String location = "getMachineMemoryInUse";
+ Map<String,Long> revisedMap = new HashMap<String,Long>();
+ try {
+ if(duccEvent != null) {
+ IDuccWorkMap dwm = duccEvent.getWorkMap();
+ if(dwm != null) {
+ jobs(revisedMap, dwm);
+ reservations(revisedMap, dwm);
+ managedReservations(revisedMap, dwm);
+ services(revisedMap, dwm);
+ }
+ }
+ }
+ catch(Exception e) {
+ logger.error(location, jobid, e);
+ }
+ map = revisedMap;
+ return map;
+ }
+
+ // accumulate bytes allocated on each machine for each active job
+ private static void jobs(Map<String,Long> map, IDuccWorkMap dwm) {
+ String location = "jobs";
+ try {
+ if(map != null) {
+ if(dwm != null) {
+ Set<DuccId> keys = dwm.getJobKeySet();
+ for(DuccId key : keys) {
+ IDuccWork dw = dwm.findDuccWork(key);
+ IDuccWorkJob dwj = (IDuccWorkJob) dw;
+ if(dwj != null) {
+ if(dwj.isOperational()) {
+ long bytes = dwj.getSchedulingInfo().getMemorySizeAllocatedInBytes();
+ IDuccProcessMap processMap = dwj.getProcessMap();
+ if(processMap != null) {
+ for(IDuccProcess process : processMap.values()) {
+ if(!process.isDeallocated()) {
+ NodeIdentity ni = process.getNodeIdentity();
+ if(ni != null) {
+ String name = ni.getName();
+ if(name != null) {
+ add(map, name, bytes);
+ }
+ }
+ }
+ }
+ }
+ }
+ }
+ }
+ }
+ }
+ }
+ catch(Exception e) {
+ logger.error(location, jobid, e);
+ }
+ }
+
+ // accumulate bytes allocated on each machine for each active reservation
+ private static void reservations(Map<String,Long> map, IDuccWorkMap dwm) {
+ String location = "reservations";
+ try {
+ if(map != null) {
+ if(dwm != null) {
+ Set<DuccId> keys = dwm.getReservationKeySet();
+ for(DuccId key : keys) {
+ IDuccWork dw = dwm.findDuccWork(key);
+ IDuccWorkReservation dwr = (IDuccWorkReservation) dw;
+ if(dwr != null) {
+ if(dwr.isOperational()) {
+ IDuccReservationMap reservationMap = dwr.getReservationMap();
+ for(IDuccReservation reservation : reservationMap.values()) {
+ long bytes = reservation.getBytes();
+ NodeIdentity ni = reservation.getNodeIdentity();
+ if(ni != null) {
+ String name = ni.getName();
+ if(name != null) {
+ add(map, name, bytes);
+ }
+ }
+ }
+ }
+ }
+ }
+ }
+ }
+ }
+ catch(Exception e) {
+ logger.error(location, jobid, e);
+ }
+ }
+
+ // accumulate bytes allocated on each machine for each active managed reservation
+ private static void managedReservations(Map<String,Long> map, IDuccWorkMap dwm) {
+ String location = "managedReservations";
+ try {
+ if(map != null) {
+ if(dwm != null) {
+ Set<DuccId> keys = dwm.getManagedReservationKeySet();
+ for(DuccId key : keys) {
+ IDuccWork dw = dwm.findDuccWork(key);
+ IDuccWorkJob dwmr = (IDuccWorkJob) dw;
+ if(dwmr != null) {
+ if(dwmr.isOperational()) {
+ long bytes = dwmr.getSchedulingInfo().getMemorySizeAllocatedInBytes();
+ IDuccProcessMap processMap = dwmr.getProcessMap();
+ if(processMap != null) {
+ for(IDuccProcess process : processMap.values()) {
+ if(!process.isDeallocated()) {
+ NodeIdentity ni = process.getNodeIdentity();
+ if(ni != null) {
+ String name = ni.getName();
+ if(name != null) {
+ add(map, name, bytes);
+ }
+ }
+ }
+ }
+ }
+ }
+ }
+ }
+ }
+ }
+ }
+ catch(Exception e) {
+ logger.error(location, jobid, e);
+ }
+ }
+
+ // accumulate bytes allocated on each machine for each active service instance
+ private static void services(Map<String,Long> map, IDuccWorkMap dwm) {
+ String location = "services";
+ try {
+ if(map != null) {
+ if(dwm != null) {
+ Set<DuccId> keys = dwm.getServiceKeySet();
+ for(DuccId key : keys) {
+ IDuccWork dw = dwm.findDuccWork(key);
+ IDuccWorkJob dws = (IDuccWorkJob) dw;
+ if(dws != null) {
+ if(dws.isOperational()) {
+ long bytes = dws.getSchedulingInfo().getMemorySizeAllocatedInBytes();
+ IDuccProcessMap processMap = dws.getProcessMap();
+ if(processMap != null) {
+ for(IDuccProcess process : processMap.values()) {
+ if(!process.isDeallocated()) {
+ NodeIdentity ni = process.getNodeIdentity();
+ if(ni != null) {
+ String name = ni.getName();
+ if(name != null) {
+ add(map, name, bytes);
+ }
+ }
+ }
+ }
+ }
+ }
+ }
+ }
+ }
+ }
+ }
+ catch(Exception e) {
+ logger.error(location, jobid, e);
+ }
+ }
+
+ // accumulate bytes allocated on specified machine
+ private static void add(Map<String,Long> map, String name, long bytes) {
+ Long value = new Long(0);
+ if(!map.containsKey(name)) {
+ map.put(name, value);
+ }
+ value = map.get(name)+bytes;
+ map.put(name,value);
+ }
+}
Propchange: uima/sandbox/uima-ducc/trunk/uima-ducc-web/src/main/java/org/apache/uima/ducc/ws/Distiller.java
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: uima/sandbox/uima-ducc/trunk/uima-ducc-web/src/main/java/org/apache/uima/ducc/ws/Distiller.java
------------------------------------------------------------------------------
svn:mime-type = text/plain
Added: uima/sandbox/uima-ducc/trunk/uima-ducc-web/src/main/java/org/apache/uima/ducc/ws/Helper.java
URL: http://svn.apache.org/viewvc/uima/sandbox/uima-ducc/trunk/uima-ducc-web/src/main/java/org/apache/uima/ducc/ws/Helper.java?rev=1733515&view=auto
==============================================================================
--- uima/sandbox/uima-ducc/trunk/uima-ducc-web/src/main/java/org/apache/uima/ducc/ws/Helper.java (added)
+++ uima/sandbox/uima-ducc/trunk/uima-ducc-web/src/main/java/org/apache/uima/ducc/ws/Helper.java Thu Mar 3 19:14:41 2016
@@ -0,0 +1,18 @@
+package org.apache.uima.ducc.ws;
+
+public class Helper {
+
+ /**
+ * Convert String to long, else zero
+ */
+ public static long String2Long(String value) {
+ long retVal = 0;
+ try{
+ retVal = Long.parseLong(value);
+ }
+ catch(Exception e) {
+ // oh well
+ }
+ return retVal;
+ }
+}
Propchange: uima/sandbox/uima-ducc/trunk/uima-ducc-web/src/main/java/org/apache/uima/ducc/ws/Helper.java
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: uima/sandbox/uima-ducc/trunk/uima-ducc-web/src/main/java/org/apache/uima/ducc/ws/Helper.java
------------------------------------------------------------------------------
svn:mime-type = text/plain
Modified: uima/sandbox/uima-ducc/trunk/uima-ducc-web/src/main/java/org/apache/uima/ducc/ws/WebServerComponent.java
URL: http://svn.apache.org/viewvc/uima/sandbox/uima-ducc/trunk/uima-ducc-web/src/main/java/org/apache/uima/ducc/ws/WebServerComponent.java?rev=1733515&r1=1733514&r2=1733515&view=diff
==============================================================================
--- uima/sandbox/uima-ducc/trunk/uima-ducc-web/src/main/java/org/apache/uima/ducc/ws/WebServerComponent.java (original)
+++ uima/sandbox/uima-ducc/trunk/uima-ducc-web/src/main/java/org/apache/uima/ducc/ws/WebServerComponent.java Thu Mar 3 19:14:41 2016
@@ -19,6 +19,8 @@
package org.apache.uima.ducc.ws;
import java.io.File;
+import java.util.Map;
+import java.util.Map.Entry;
import java.util.concurrent.atomic.AtomicInteger;
import java.util.concurrent.atomic.AtomicLong;
@@ -144,9 +146,18 @@ implements IWebServer {
DuccData.getInstance().put(wm);
DuccPlugins.getInstance().update(wm);
DuccListeners.getInstance().update(duccEvent);
+ Map<String,Long> map = Distiller.deriveMachineMemoryInUse(duccEvent);
+ report(map);
duccLogger.trace(methodName, jobid, duccMsg.fetch("exit"));
}
+ private void report(Map<String,Long> map) {
+ String location = "report";
+ for(Entry<String, Long> entry : map.entrySet()) {
+ duccLogger.trace(location, jobid, entry.getKey()+"="+entry.getValue());
+ }
+ }
+
private void sortMachines() {
long last = updateLast.get();
long deadline = last + updateIntervalMilliSeconds;
Modified: uima/sandbox/uima-ducc/trunk/uima-ducc-web/src/main/java/org/apache/uima/ducc/ws/server/DuccHandlerClassic.java
URL: http://svn.apache.org/viewvc/uima/sandbox/uima-ducc/trunk/uima-ducc-web/src/main/java/org/apache/uima/ducc/ws/server/DuccHandlerClassic.java?rev=1733515&r1=1733514&r2=1733515&view=diff
==============================================================================
--- uima/sandbox/uima-ducc/trunk/uima-ducc-web/src/main/java/org/apache/uima/ducc/ws/server/DuccHandlerClassic.java (original)
+++ uima/sandbox/uima-ducc/trunk/uima-ducc-web/src/main/java/org/apache/uima/ducc/ws/server/DuccHandlerClassic.java Thu Mar 3 19:14:41 2016
@@ -42,6 +42,7 @@ import org.apache.uima.ducc.cli.ws.json.
import org.apache.uima.ducc.common.IDuccEnv;
import org.apache.uima.ducc.common.NodeConfiguration;
import org.apache.uima.ducc.common.SizeBytes;
+import org.apache.uima.ducc.common.SizeBytes.Type;
import org.apache.uima.ducc.common.boot.DuccDaemonRuntimeProperties;
import org.apache.uima.ducc.common.boot.DuccDaemonRuntimeProperties.DaemonName;
import org.apache.uima.ducc.common.internationalization.Messages;
@@ -66,9 +67,11 @@ import org.apache.uima.ducc.transport.ev
import org.apache.uima.ducc.transport.event.common.IDuccWorkJob;
import org.apache.uima.ducc.transport.event.common.IRationale;
import org.apache.uima.ducc.transport.event.common.JdReservationBean;
+import org.apache.uima.ducc.ws.Distiller;
import org.apache.uima.ducc.ws.DuccDaemonsData;
import org.apache.uima.ducc.ws.DuccData;
import org.apache.uima.ducc.ws.DuccMachinesData;
+import org.apache.uima.ducc.ws.Helper;
import org.apache.uima.ducc.ws.Info;
import org.apache.uima.ducc.ws.JobInfo;
import org.apache.uima.ducc.ws.MachineInfo;
@@ -1590,11 +1593,12 @@ public class DuccHandlerClassic extends
String methodName = "handleServletClassicSystemMachines";
duccLogger.trace(methodName, jobid, messages.fetch("enter"));
int counter = 0;
- int sumMemTotal = 0;
- int sumMemReserve = 0;
- int sumSwapInuse = 0;
- int sumSwapFree = 0;
- int sumAliens = 0;
+ long sumMemTotal = 0;
+ long sumMemFree = 0;
+ long sumMemReserve = 0;
+ long sumSwapInuse = 0;
+ long sumSwapFree = 0;
+ long sumAliens = 0;
String hover;
ListIterator<MachineFacts> listIterator;
StringBuffer row;
@@ -1607,16 +1611,25 @@ public class DuccHandlerClassic extends
while(listIterator.hasNext()) {
MachineFacts facts = listIterator.next();
try {
- sumMemTotal += Integer.parseInt(facts.memTotal);
- sumMemReserve += Integer.parseInt(facts.memReserve);
- sumSwapInuse += Integer.parseInt(facts.swapInuse);
- sumSwapFree += Integer.parseInt(facts.swapFree);
+ sumMemTotal += Helper.String2Long(facts.memTotal);
+ sumMemReserve += Helper.String2Long(facts.memReserve);
+ sumSwapInuse += Helper.String2Long(facts.swapInuse);
+ sumSwapFree += Helper.String2Long(facts.swapFree);
sumAliens += facts.aliens.size();
}
catch(Exception e) {
duccLogger.trace(methodName, jobid, e);
}
}
+ //
+ Map<String, Long> allocatedMap = Distiller.getMap();
+ long sumMemAllocated = 0;
+ for(Long bytes : allocatedMap.values()) {
+ sumMemAllocated += bytes;
+ }
+ SizeBytes sbAllocated = new SizeBytes(Type.Bytes, sumMemAllocated);
+ sumMemFree = sumMemTotal - sbAllocated.getGBytes();
+ //
row = new StringBuffer();
row.append("<tr>");
// Status
@@ -1636,6 +1649,10 @@ public class DuccHandlerClassic extends
row.append("<td align=\"right\" "+hover+">");
row.append(""+sumMemReserve);
row.append("</td>");
+ // Memory: free
+ row.append("<td align=\"right\">");
+ row.append(""+sumMemFree);
+ row.append("</td>");
// Swap: inuse
row.append("<td align=\"right\">");
row.append(""+sumSwapInuse);
@@ -1708,6 +1725,22 @@ public class DuccHandlerClassic extends
row.append("</td>");
}
else {
+ row.append("<td align=\"right\">");
+ row.append("</td>");
+ }
+ // Memory: free
+ if(!status.equals("defined")) {
+ long memFree = Helper.String2Long(facts.memTotal);
+ if(allocatedMap.containsKey(facts.name)) {
+ long bytes = allocatedMap.get(facts.name);
+ SizeBytes allocated = new SizeBytes(Type.Bytes, bytes);
+ memFree = memFree - allocated.getGBytes();
+ }
+ row.append("<td align=\"right\">");
+ row.append(memFree);
+ row.append("</td>");
+ }
+ else {
row.append("<td align=\"right\">");
row.append("</td>");
}
Modified: uima/sandbox/uima-ducc/trunk/uima-ducc-web/src/main/java/org/apache/uima/ducc/ws/server/DuccHandlerJsonFormat.java
URL: http://svn.apache.org/viewvc/uima/sandbox/uima-ducc/trunk/uima-ducc-web/src/main/java/org/apache/uima/ducc/ws/server/DuccHandlerJsonFormat.java?rev=1733515&r1=1733514&r2=1733515&view=diff
==============================================================================
--- uima/sandbox/uima-ducc/trunk/uima-ducc-web/src/main/java/org/apache/uima/ducc/ws/server/DuccHandlerJsonFormat.java (original)
+++ uima/sandbox/uima-ducc/trunk/uima-ducc-web/src/main/java/org/apache/uima/ducc/ws/server/DuccHandlerJsonFormat.java Thu Mar 3 19:14:41 2016
@@ -45,6 +45,7 @@ import org.apache.uima.ducc.cli.ws.json.
import org.apache.uima.ducc.common.IDuccEnv;
import org.apache.uima.ducc.common.NodeConfiguration;
import org.apache.uima.ducc.common.SizeBytes;
+import org.apache.uima.ducc.common.SizeBytes.Type;
import org.apache.uima.ducc.common.boot.DuccDaemonRuntimeProperties;
import org.apache.uima.ducc.common.boot.DuccDaemonRuntimeProperties.DaemonName;
import org.apache.uima.ducc.common.internationalization.Messages;
@@ -70,9 +71,11 @@ import org.apache.uima.ducc.transport.ev
import org.apache.uima.ducc.transport.event.common.IDuccWorkJob;
import org.apache.uima.ducc.transport.event.common.IRationale;
import org.apache.uima.ducc.transport.event.common.JdReservationBean;
+import org.apache.uima.ducc.ws.Distiller;
import org.apache.uima.ducc.ws.DuccDaemonsData;
import org.apache.uima.ducc.ws.DuccData;
import org.apache.uima.ducc.ws.DuccMachinesData;
+import org.apache.uima.ducc.ws.Helper;
import org.apache.uima.ducc.ws.Info;
import org.apache.uima.ducc.ws.JobInfo;
import org.apache.uima.ducc.ws.MachineInfo;
@@ -1402,11 +1405,12 @@ public class DuccHandlerJsonFormat exten
JsonObject jsonResponse = new JsonObject();
JsonArray data = new JsonArray();
String hover;
- int sumMemTotal = 0;
- int sumMemReserve = 0;
- int sumSwapInuse = 0;
- int sumSwapFree = 0;
- int sumAliens = 0;
+ long sumMemTotal = 0;
+ long sumMemFree = 0;
+ long sumMemReserve = 0;
+ long sumSwapInuse = 0;
+ long sumSwapFree = 0;
+ long sumAliens = 0;
ListIterator<MachineFacts> listIterator;
JsonArray row;
StringBuffer sb;
@@ -1418,16 +1422,25 @@ public class DuccHandlerJsonFormat exten
while(listIterator.hasNext()) {
MachineFacts facts = listIterator.next();
try {
- sumMemTotal += Integer.parseInt(facts.memTotal);
- sumMemReserve += Integer.parseInt(facts.memReserve);
- sumSwapInuse += Integer.parseInt(facts.swapInuse);
- sumSwapFree += Integer.parseInt(facts.swapFree);
+ sumMemTotal += Helper.String2Long(facts.memTotal);
+ sumMemReserve += Helper.String2Long(facts.memReserve);
+ sumSwapInuse += Helper.String2Long(facts.swapInuse);
+ sumSwapFree += Helper.String2Long(facts.swapFree);
sumAliens += facts.aliens.size();
}
catch(Exception e) {
duccLogger.trace(methodName, jobid, e);
}
}
+ //
+ Map<String, Long> allocatedMap = Distiller.getMap();
+ long sumMemAllocated = 0;
+ for(Long bytes : allocatedMap.values()) {
+ sumMemAllocated += bytes;
+ }
+ SizeBytes sbAllocated = new SizeBytes(Type.Bytes, sumMemAllocated);
+ sumMemFree = sumMemTotal - sbAllocated.getGBytes();
+ //
row = new JsonArray();
// Status
row.add(new JsonPrimitive("Total"));
@@ -1439,6 +1452,8 @@ public class DuccHandlerJsonFormat exten
hover = "title=\"total="+sumMemTotal+"\"";
String sumMemReserveWithHover = "<span "+hover+" >"+sumMemReserve+"</span>";
row.add(new JsonPrimitive(sumMemReserveWithHover));
+ // Memory: free
+ row.add(new JsonPrimitive(sumMemFree));
// Swap: inuse
row.add(new JsonPrimitive(sumSwapInuse));
// Swap: free
@@ -1493,6 +1508,19 @@ public class DuccHandlerJsonFormat exten
}
else {
row.add(new JsonPrimitive(""));
+ }
+ // Memory: free
+ if(!status.equals("defined")) {
+ long memFree = Helper.String2Long(facts.memTotal);
+ if(allocatedMap.containsKey(facts.name)) {
+ long bytes = allocatedMap.get(facts.name);
+ SizeBytes allocated = new SizeBytes(Type.Bytes, bytes);
+ memFree = memFree - allocated.getGBytes();
+ }
+ row.add(new JsonPrimitive(memFree));
+ }
+ else {
+ row.add(new JsonPrimitive(""));
}
// Swap: inuse
sb = new StringBuffer();
Modified: uima/sandbox/uima-ducc/trunk/uima-ducc-web/src/main/webapp/root/system.machines.jsp
URL: http://svn.apache.org/viewvc/uima/sandbox/uima-ducc/trunk/uima-ducc-web/src/main/webapp/root/system.machines.jsp?rev=1733515&r1=1733514&r2=1733515&view=diff
==============================================================================
--- uima/sandbox/uima-ducc/trunk/uima-ducc-web/src/main/webapp/root/system.machines.jsp (original)
+++ uima/sandbox/uima-ducc/trunk/uima-ducc-web/src/main/webapp/root/system.machines.jsp Thu Mar 3 19:14:41 2016
@@ -39,12 +39,13 @@ under the License.
"sAjaxSource": "ducc-servlet/json-format-aaData-machines",
aaSorting: [],
"fnRowCallback" : function(nRow,aData,iDisplayIndex) {
+ $('td:eq(3)' , nRow).css( "text-align", "right" );
+ $('td:eq(4)' , nRow).css( "text-align", "right" );
$('td:eq(5)' , nRow).css( "text-align", "right" );
$('td:eq(6)' , nRow).css( "text-align", "right" );
$('td:eq(7)' , nRow).css( "text-align", "right" );
- $('td:eq(8)' , nRow).css( "text-align", "right" );
- $('td:eq(9)' , nRow).css( "text-align", "right" );
- $('td:eq(12)' , nRow).css( "text-align", "right" );
+ $('td:eq(8)' , nRow).css( "text-align", "right" );
+ $('td:eq(9)' , nRow).css( "text-align", "right" );
return nRow;
},
} );
@@ -104,6 +105,7 @@ if (table_style.equals("scroll")) {
<th align="left" title="The host IP">IP</th>
<th align="left" title="The host name">Name</th>
<th align="left" title="The host usable memory size, in GB" >Memory(GB):usable</th>
+ <th align="left" title="The host free memory size, in GB" >Memory(GB):free</th>
<th align="left" title="The host inuse swap size, in GB" >Swap(GB):inuse</th>
<th align="left" title="The host free swap size, in GB" >Swap(GB):free</th>
<th align="left" title="The host C-Groups status" >C-Groups</th>
@@ -131,6 +133,7 @@ if (table_style.equals("classic")) {
<th align="left" title="The host IP">IP</th>
<th align="left" title="The host name">Name</th>
<th class="sorttable_numeric" align="left" title="The host usable memory size, in GB" >Memory(GB):usable</th>
+ <th class="sorttable_numeric" align="left" title="The host free memory size, in GB" >Memory(GB):free</th>
<th class="sorttable_numeric" align="left" title="The host inuse swap size, in GB" >Swap(GB):inuse</th>
<th class="sorttable_numeric" align="left" title="The host free swap size, in GB" >Swap(GB):free</th>
<th align="left" title="The host C-Groups status" >C-Groups</th>