OurGrid RSS Status OurGrid RSS Status pt-br <%@ page import="java.util.*, org.ourgrid.webstatus.*, org.ourgrid.common.spec.*" %> <% int totalPeers = 0; int totalGums = 0; int totalOnlineGums = 0; // Total accountant int qtdTotal = 0; int qtdOnline = 0; int qtdIdle = 0; int qtdLocal = 0; int qtdCommunity= 0; int qtdDonating = 0; Date currentDate = new Date(); Date timeSnapshot = (Date)request.getAttribute("timeSnapshot"); Collection peerInfoList = (Collection)request.getAttribute("peerInfoList"); totalPeers = peerInfoList.size(); Iterator itFunction = peerInfoList.iterator(); while(itFunction.hasNext()) { PeerInfoPack pack = (PeerInfoPack) itFunction.next(); if (pack.getConfiguratedGums() != null) { totalGums += pack.getConfiguratedGums().size(); totalOnlineGums += pack.getOnlineGums().size(); } else { totalOnlineGums += pack.getLocalGuMs().size(); } } %> <![CDATA[Server Time: <%= currentDate %>]]> <![CDATA[Last Snapshot: <%= timeSnapshot %>]]> <![CDATA[Peers: <%= totalPeers %>]]> <![CDATA[Grid Machines: <%= totalGums %>]]> <![CDATA[Online Grid Machines: <%= totalOnlineGums %>]]> <![CDATA[-------------------- Online Peers --------------------]]> <% int contador = 0; Iterator itDiv = peerInfoList.iterator(); while (itDiv.hasNext()) { PeerInfoPack pack = (PeerInfoPack) itDiv.next(); String peerName = pack.getPeerID().getName(); %> <![CDATA[<%= ++contador %> - <%= peerName %>]]> <%= pack.getDescription() %> <% } %>