added segment sizes, postprocessing status and cpu load to crawler

monitor
pull/1/head
orbiter 12 years ago
parent 86b514cf46
commit 9c681cc00d

@ -21,14 +21,14 @@
#%env/templates/submenuCrawlMonitor.template%# #%env/templates/submenuCrawlMonitor.template%#
<h2>Crawler</h2> <h2>Crawler</h2>
<noscript><p>(Please enable JavaScript to automatically update this page!)</p></noscript> <noscript><p>(Please enable JavaScript to automatically update this page!)</p></noscript>
<fieldset style="width:260px;height:140px;float:left;"> <fieldset style="width:180px;height:160px;float:left;">
<legend>Queues</legend> <legend>Queues</legend>
<table border="0" cellpadding="2" cellspacing="1" class="watchCrawler"> <table border="0" cellpadding="2" cellspacing="1" class="watchCrawler">
<tbody> <tbody>
<tr class="TableHeader"> <tr class="TableHeader">
<th width="110">Queue</th> <th width="110">Queue<br/>&nbsp;</th>
<th>Size</th> <th>Size<br/>&nbsp;</th>
<th width="50">Pause/Resume</th> <th width="50">Pause/<br/>Resume</th>
</tr> </tr>
<tr class="TableCellLight"> <tr class="TableCellLight">
<td align="left">Local Crawler</td> <td align="left">Local Crawler</td>
@ -75,41 +75,45 @@
</table> </table>
<div class="warning" id="message">&nbsp;#[queuemessage]#<div> <div class="warning" id="message">&nbsp;#[queuemessage]#<div>
</fieldset> </fieldset>
<fieldset style="width:180px;height:140px;float:left;"> <fieldset style="width:220px;height:160px;float:left;">
<legend>Index Size</legend> <legend>Index Size</legend>
<table border="0" cellpadding="2" cellspacing="1" class="watchCrawler"> <table border="0" cellpadding="2" cellspacing="1" class="watchCrawler">
<tbody> <tbody>
<tr class="TableHeader"> <tr class="TableHeader">
<th width="100">Database</th> <th width="140">Database<br/>&nbsp;</th>
<th width="80">Entries</th> <th width="80">Entries<br/>&nbsp;</th>
<th width="40">Seg-<br/>ments</th>
</tr> </tr>
<tr class="TableCellLight"> <tr class="TableCellLight">
<td align="left">Documents<br/><a href="/solr/select?core=collection1&q=*:*&start=0&rows=3">solr search api</a></td> <td align="left">Documents<br/><a href="/solr/select?core=collection1&q=*:*&start=0&rows=3">solr search api</a></td>
<td align="right"><span id="urldbsize">#[urlpublictextSize]#</span></td> <td align="right"><span id="urlpublictextSize">#[urlpublictextSize]#</span></td>
<td align="right"><span id="urlpublictextSegmentCount">#[urlpublictextSegmentCount]#</span></td>
</tr> </tr>
<tr class="TableCellLight"> <tr class="TableCellLight">
<td align="left">Webgraph Edges<br/><a href="/solr/select?core=webgraph&q=*:*&start=0&rows=3">solr search api</a></td> <td align="left">Webgraph Edges<br/><a href="/solr/select?core=webgraph&q=*:*&start=0&rows=3">solr search api</a></td>
<td align="right"><span id="webgraphsize">#[webgraphSize]#</span></td> <td align="right"><span id="webgraphSize">#[webgraphSize]#</span></td>
<td align="right"><span id="webgraphSegmentCount">#[webgraphSegmentCount]#</span></td>
</tr> </tr>
<tr class="TableCellLight"> <tr class="TableCellLight">
<td align="left">RWIs<br/>(P2P Chunks)</td> <td align="left">RWIs<br/>(P2P Chunks)</td>
<td align="right"><span id="rwidbsize">#[rwipublictextSize]#</span></td> <td align="right"><span id="rwipublictextSize">#[rwipublictextSize]#</span></td>
<td align="right"><span id="rwipublictextSegmentCount">#[rwipublictextSegmentCount]#</span></td>
</tr> </tr>
</tbody> </tbody>
</table> </table>
</fieldset> </fieldset>
<fieldset style="width:520px;height:140px;;float:left;"> <fieldset style="width:430px;height:160px;;float:left;">
<legend>Progress</legend> <legend>Progress</legend>
<form action="Crawler_p.html" method="post" enctype="multipart/form-data" accept-charset="UTF-8"> <form action="Crawler_p.html" method="post" enctype="multipart/form-data" accept-charset="UTF-8">
<table border="0" cellpadding="2" cellspacing="1" class="watchCrawler"> <table border="0" cellpadding="2" cellspacing="1" class="watchCrawler">
<tbody> <tbody>
<tr class="TableHeader"> <tr class="TableHeader">
<th width="90">Indicator</th> <th width="100">Indicator<br/>&nbsp;</th>
<th colspan="2">Level</th> <th width="300" colspan="4">Level<br/>&nbsp;</th>
</tr> </tr>
<tr class="TableCellLight"> <tr class="TableCellLight">
<td align="left">Speed</td> <td align="left">Speed</td>
<td align="left" colspan="2"> <td align="left" colspan="4">
<input #(crawlingSpeedMinChecked)#::class="TableCellDark"#(/crawlingSpeedMinChecked)# type="submit" name="crawlingPerformance" value="minimum" /> <input #(crawlingSpeedMinChecked)#::class="TableCellDark"#(/crawlingSpeedMinChecked)# type="submit" name="crawlingPerformance" value="minimum" />
<input #(crawlingSpeedCustChecked)#::class="TableCellDark"#(/crawlingSpeedCustChecked)# id="customPPM" name="customPPM" type="text" size="5" maxlength="5" value="#[customPPMdefault]#" />PPM <input type="submit" name="crawlingPerformance" value="custom" /> <input #(crawlingSpeedCustChecked)#::class="TableCellDark"#(/crawlingSpeedCustChecked)# id="customPPM" name="customPPM" type="text" size="5" maxlength="5" value="#[customPPMdefault]#" />PPM <input type="submit" name="crawlingPerformance" value="custom" />
<input #(crawlingSpeedMaxChecked)#::class="TableCellDark"#(/crawlingSpeedMaxChecked)# type="submit" name="crawlingPerformance" value="maximum" /> <input #(crawlingSpeedMaxChecked)#::class="TableCellDark"#(/crawlingSpeedMaxChecked)# type="submit" name="crawlingPerformance" value="maximum" />
@ -117,14 +121,21 @@
</tr> </tr>
<tr class="TableCellLight"> <tr class="TableCellLight">
<td align="left">PPM (Pages Per Minute)</td> <td align="left">PPM (Pages Per Minute)</td>
<td align="left" width="20"><span id="ppmNum">&nbsp;&nbsp;&nbsp;</span></td> <td align="left" width="40"><span id="ppmNum">&nbsp;&nbsp;&nbsp;</span></td>
<td align="left" width="400px"> <td align="left" width="260px" colspan="3">
<progress id="ppmbar" max="30000" value="0" style="width:94%;"/> <progress id="ppmbar" max="30000" value="0" style="width:94%;"/>
</td> </td>
</tr> </tr>
<tr class="TableCellLight"> <tr class="TableCellLight">
<td align="left">Traffic (Crawler)</td> <td align="left">Traffic (Crawler)</td>
<td align="left"><span id="trafficCrawler">&nbsp;&nbsp;&nbsp;</span> MB</td> <td align="left"><span id="trafficCrawler">&nbsp;&nbsp;&nbsp;</span> MB</td>
<td colspan="3">&nbsp;</td>
</tr>
<tr class="TableCellLight">
<td align="left">Load</td>
<td align="left"><span id="load">&nbsp;&nbsp;&nbsp;</span></td>
<td align="left" width="100">Postprocessing</td>
<td align="left"><span id="postprocessing">&nbsp;&nbsp;&nbsp;</span></td>
<td>&nbsp;</td> <td>&nbsp;</td>
</tr> </tr>
</tbody> </tbody>

@ -73,8 +73,11 @@ public class Crawler_p {
final serverObjects prop = new serverObjects(); final serverObjects prop = new serverObjects();
prop.put("rejected", 0); prop.put("rejected", 0);
prop.put("urlpublictextSize", 0); prop.put("urlpublictextSize", 0);
prop.put("urlpublictextSegmentCount", 0);
prop.put("webgraphSize", 0); prop.put("webgraphSize", 0);
prop.put("webgraphSegmentCount", 0);
prop.put("rwipublictextSize", 0); prop.put("rwipublictextSize", 0);
prop.put("rwipublictextSegmentCount", 0);
prop.put("list", "0"); prop.put("list", "0");
prop.put("loaderSize", 0); prop.put("loaderSize", 0);
prop.put("loaderMax", 0); prop.put("loaderMax", 0);

@ -89,12 +89,24 @@ function handleStatus(){
trafCrawlerSpan.appendChild(document.createTextNode(Math.round((trafficCrawlerValue) / 1024 / 10.24) / 100)); trafCrawlerSpan.appendChild(document.createTextNode(Math.round((trafficCrawlerValue) / 1024 / 10.24) / 100));
dbsize=getFirstChild(statusTag, "dbsize"); dbsize=getFirstChild(statusTag, "dbsize");
urlpublictextSize=getValue(getFirstChild(dbsize, "urlpublictext")); urlpublictext=getValue(getFirstChild(dbsize, "urlpublictext"));
rwipublictextSize=getValue(getFirstChild(dbsize, "rwipublictext")); urlpublictextSegmentCount=getValue(getFirstChild(dbsize, "urlpublictextSegmentCount"));
webgraphSize=getValue(getFirstChild(dbsize, "webgraph")); webgraph=getValue(getFirstChild(dbsize, "webgraph"));
document.getElementById("urldbsize").firstChild.nodeValue=urlpublictextSize; webgraphSegmentCount=getValue(getFirstChild(dbsize, "webgraphSegmentCount"));
document.getElementById("webgraphsize").firstChild.nodeValue=webgraphSize; rwipublictext=getValue(getFirstChild(dbsize, "rwipublictext"));
document.getElementById("rwidbsize").firstChild.nodeValue=rwipublictextSize; rwipublictextSegmentCount=getValue(getFirstChild(dbsize, "rwipublictextSegmentCount"));
document.getElementById("urlpublictextSize").firstChild.nodeValue=urlpublictext;
document.getElementById("urlpublictextSegmentCount").firstChild.nodeValue=urlpublictextSegmentCount;
document.getElementById("webgraphSize").firstChild.nodeValue=webgraph;
document.getElementById("webgraphSegmentCount").firstChild.nodeValue=webgraphSegmentCount;
document.getElementById("rwipublictextSize").firstChild.nodeValue=rwipublictext;
document.getElementById("rwipublictextSegmentCount").firstChild.nodeValue=rwipublictextSegmentCount;
postprocessing=getFirstChild(statusTag, "postprocessing");
document.getElementById("postprocessing").firstChild.nodeValue=getValue(getFirstChild(postprocessing, "status"));
load=getFirstChild(statusTag, "load");
document.getElementById("load").firstChild.nodeValue=getValue(load);
loaderqueue=getFirstChild(statusTag, "loaderqueue"); loaderqueue=getFirstChild(statusTag, "loaderqueue");
loaderqueue_size=getValue(getFirstChild(loaderqueue, "size")); loaderqueue_size=getValue(getFirstChild(loaderqueue, "size"));

Loading…
Cancel
Save