Skip to content

Distributed Peer-to-Peer Web Search Engine and Intranet Search Appliance

bugfixes, more sorttable

orbiter1198b9989df4
diff --git a/htroot/AccessTracker_p.html b/htroot/AccessTracker_p.html
index 501cd5d8a..ce078ff0c 100644
--- a/htroot/AccessTracker_p.html
+++ b/htroot/AccessTracker_p.html
@@ -7,6 +7,7 @@
<body id="AccessTracker">
#%env/templates/header.template%#
#%env/templates/submenuAccessTracker.template%#
+ <script src="/js/sorttable.js"></script>
#(page)#
<h2>Server Access Overview</h2>
<p>This is a list of #[num]# requests to the local http server within the last hour.</p>
@@ -32,7 +33,7 @@
#{/list}#
</table>
<p>The following hosts are registered as source for brute-force requests to protected pages</p>
- <table border="0" cellpadding="2" cellspacing="1">
+ <table class="sortable" border="0" cellpadding="2" cellspacing="1">
<tr class="TableHeader">
<td>Host</td>
<td>Access Times</td>
@@ -48,7 +49,7 @@
<h2>Server Access Details</h2>
<p>This is a list of requests to the local http server within the last hour.</p>
<p>Showing #[num]# requests.</p>
- <table border="0" cellpadding="2" cellspacing="1">
+ <table class="sortable" border="0" cellpadding="2" cellspacing="1">
<tr class="TableHeader">
<td>Host</td>
<td>Date</td>
@@ -66,7 +67,8 @@
<h2>Local Search Log</h2>
<p>This is a list of searches that had been requested from this' peer search interface</p>
<p>Showing #[num]# entries from a total of #[total]# requests.</p>
- <table border="0" cellpadding="2" cellspacing="1">
+ <table class="sortable" border="0" cellpadding="2" cellspacing="1">
+ <thead>
<tr class="TableHeader">
<td>Requesting Host</td>
<td>Date</td>
@@ -78,6 +80,8 @@
<td>Snippet comp (ms)</td>
<td>Query</td>
</tr>
+ </thead>
+ <tbody>
#{list}#
<tr class="TableCell#(dark)#Light::Dark#(/dark)#">
<td>#[host]#</td>
@@ -91,6 +95,8 @@
<td><a href="/yacysearch.html?search=#[querystring]#&resource=local">#[querystring]#</a></td>
</tr>
#{/list}#
+ </tbody>
+ <tfoot>
<tr class="TableHeader">
<td></td>
<td></td>
@@ -102,18 +108,22 @@
<td>&#216; #[snippettime_avg]#</td>
<td></td>
</tr>
+ </tfoot>
</table>
::
<h2>Local Search Host Tracker</h2>
<p>This is a list of searches that had been requested from this' peer search interface</p>
<p>Showing #[num]# entries from a total of #[total]# requests.</p>
- <table border="0" cellpadding="2" cellspacing="1">
+ <table class="sortable" border="0" cellpadding="2" cellspacing="1">
+ <thead>
<tr class="TableHeader">
<td>Requesting Host</td>
<td>Count</td>
<td>Queries Per Last Hour</td>
<td>Access Dates</td>
</tr>
+ </thead>
+ <tbody>
#{list}#
<tr class="TableCell#(dark)#Light::Dark#(/dark)#">
<td>#[host]#</td>
@@ -122,18 +132,22 @@
<td>#{dates}##[date]# #{/dates}#</td>
</tr>
#{/list}#
+ </tbody>
+ <tfoot>
<tr class="TableHeader">
<td></td>
<td>&#931; #[total]#</td>
<td>&#931; #[qph_sum]#</td>
<td></td>
</tr>
+ </tfoot>
</table>
::
<h2>Remote Search Log</h2>
<p>This is a list of searches that had been requested from remote peer search interface</p>
<p>Showing #[num]# entries from a total of #[total]# requests.</p>
- <table border="0" cellpadding="2" cellspacing="1">
+ <table class="sortable" border="0" cellpadding="2" cellspacing="1">
+ <thead>
<tr class="TableHeader">
<td>Requesting Host</td>
<td>Peer Name</td>
@@ -145,6 +159,8 @@
<td>Snippet comp (ms)</td>
<td>Search Word Hashes</td>
</tr>
+ </thead>
+ <tbody>
#{list}#
<tr class="TableCell#(dark)#Light::Dark#(/dark)#">
<td>#[host]#</td>
@@ -158,6 +174,8 @@
<td>#[queryhashes]#</td>
</tr>
#{/list}#
+ </tbody>
+ <tfoot>
<tr class="TableHeader">
<td>Total: #[num]#
<br/>Success: #[resultcount]#</td>
@@ -175,12 +193,14 @@
<br/>&#216; #[snippettime_avg1]#</td>
<td></td>
</tr>
+ </tfoot>
</table>
::
<h2>Remote Search Host Tracker</h2>
<p>This is a list of searches that had been requested from remote peer search interface</p>
<p>Showing #[num]# entries from a total of #[total]# requests.</p>
- <table border="0" cellpadding="2" cellspacing="1">
+ <table class="sortable" border="0" cellpadding="2" cellspacing="1">
+ <thead>
<tr class="TableHeader">
<td>Requesting Host</td>
<td>Peer Name</td>
@@ -188,6 +208,8 @@
<td>Queries Per Last Hour</td>
<td>Access Dates</td>
</tr>
+ </thead>
+ <tbody>
#{list}#
<tr class="TableCell#(dark)#Light::Dark#(/dark)#">
<td>#[host]#</td>
@@ -197,6 +219,8 @@
<td>#{dates}##[date]# #{/dates}#</td>
</tr>
#{/list}#
+ </tbody>
+ <tfoot>
<tr class="TableHeader">
<td></td>
<td></td>
@@ -204,6 +228,7 @@
<td>&#931; #[qph_sum]#</td>
<td></td>
</tr>
+ </tfoot>
</table>
#(/page)#
#%env/templates/footer.template%#
diff --git a/htroot/Connections_p.html b/htroot/Connections_p.html
index 6c057642b..9cd846661 100644
--- a/htroot/Connections_p.html
+++ b/htroot/Connections_p.html
@@ -8,11 +8,11 @@
<body id="Connections">
#%env/templates/header.template%#
#%env/templates/submenuAccessTracker.template%#
-
+ <script src="/js/sorttable.js"></script>
<h2>Server Connection Tracking</h2>
<h3>Incoming Connections</h3>
<p>Showing #[numActiveRunning]# active, #[numActivePending]# pending connections from a max. of #[numMax]# allowed incoming connections.</p>
- <table border="0" cellpadding="2" cellspacing="1">
+ <table class="sortable" border="0" cellpadding="2" cellspacing="1">
<tr class="TableHeader" valign="bottom">
<td>Protocol</td>
<td>Duration</td>
@@ -37,7 +37,7 @@
<h3>Outgoing Connections</h3>
<p>Showing #[clientActive]# pooled outgoing connections used as:</p>
- <table border="0" cellpadding="2" cellspacing="1">
+ <table class="sortable" border="0" cellpadding="2" cellspacing="1">
<tr class="TableHeader" valign="bottom">
<td>Protocol</td>
<td>Duration</td>
diff --git a/htroot/Network.html b/htroot/Network.html
index 36be79571..1b581d3c9 100644
--- a/htroot/Network.html
+++ b/htroot/Network.html
@@ -63,7 +63,7 @@ To see a list of all APIs, please visit the <a href="http://www.yacy-websuche.de
</form>
<table class="sortable" border="0" cellpadding="2" cellspacing="1">
<tr class="TableHeader" valign="bottom">
- <td>send&nbsp;<strong>M</strong>essage/<br />show&nbsp;<strong>P</strong>rofile/<br />edit&nbsp;<strong>W</strong>iki<br />q</td>
+ <td>send&nbsp;<strong>M</strong>essage/<br />show&nbsp;<strong>P</strong>rofile/<br />edit&nbsp;<strong>W</strong>iki</td>
<td><strong>Name</strong><br /></td>
<td style="width:44px;"><strong>Info</strong></td>
<td><strong>Release/<br />SVN</strong></td>
@@ -72,7 +72,7 @@ To see a list of all APIs, please visit the <a href="http://www.yacy-websuche.de
<td><strong>Last<br />Seen</strong></td>
<td><strong>UTC</strong><br />Offset</td>
<td><strong>Location</strong><br /></td>
- <td style="width:70px;"><strong>Uptime</strong>/td>
+ <td style="width:70px;"><strong>Uptime</strong></td>
<td><strong>Links</strong></td>
<td><strong>RWIs</strong></td>
<td><strong>URLs for<br />Remote<br />Crawl</strong></td>
diff --git a/source/net/yacy/kelondro/data/meta/DigestURI.java b/source/net/yacy/kelondro/data/meta/DigestURI.java
index e2f74ecbb..da793cdf2 100644
--- a/source/net/yacy/kelondro/data/meta/DigestURI.java
+++ b/source/net/yacy/kelondro/data/meta/DigestURI.java
@@ -1058,25 +1058,43 @@ public class DigestURI implements Serializable {
public boolean exists() {
if (isFile()) return getFSFile().exists();
- if (isSMB()) try {return getSmbFile().exists();}
- catch (SmbException e) {return false;}
- catch (MalformedURLException e) {return false;}
+ if (isSMB()) try {
+ return getSmbFile().exists();
+ } catch (SmbException e) {
+ Log.logWarning("DigestURI", "SMB.exists SmbException for " + this.toString() + ": " + e.getMessage());
+ return false;
+ } catch (MalformedURLException e) {
+ Log.logWarning("DigestURI", "SMB.exists MalformedURLException for " + this.toString() + ": " + e.getMessage());
+ return false;
+ }
return false;
}
public boolean canRead() {
if (isFile()) return getFSFile().canRead();
- if (isSMB()) try {return getSmbFile().canRead();}
- catch (SmbException e) {return false;}
- catch (MalformedURLException e) {return false;}
+ if (isSMB()) try {
+ return getSmbFile().canRead();
+ } catch (SmbException e) {
+ Log.logWarning("DigestURI", "SMB.canRead SmbException for " + this.toString() + ": " + e.getMessage());
+ return false;
+ } catch (MalformedURLException e) {
+ Log.logWarning("DigestURI", "SMB.canRead MalformedURLException for " + this.toString() + ": " + e.getMessage());
+ return false;
+ }
return false;
}
public boolean canWrite() {
if (isFile()) return getFSFile().canWrite();
- if (isSMB()) try {return getSmbFile().canWrite();}
- catch (SmbException e) {return false;}
- catch (MalformedURLException e) {return false;}
+ if (isSMB()) try {
+ return getSmbFile().canWrite();
+ } catch (SmbException e) {
+ Log.logWarning("DigestURI", "SMB.canWrite SmbException for " + this.toString() + ": " + e.getMessage());
+ return false;
+ } catch (MalformedURLException e) {
+ Log.logWarning("DigestURI", "SMB.canWrite MalformedURLException for " + this.toString() + ": " + e.getMessage());
+ return false;
+ }
return false;
}
@@ -1088,47 +1106,82 @@ public class DigestURI implements Serializable {
public boolean isHidden() {
if (isFile()) return getFSFile().isHidden();
- if (isSMB()) try {return getSmbFile().isHidden();}
- catch (SmbException e) {return false;}
- catch (MalformedURLException e) {return false;}
+ if (isSMB()) try {
+ return getSmbFile().isHidden();
+ } catch (SmbException e) {
+ Log.logWarning("DigestURI", "SMB.isHidden SmbException for " + this.toString() + ": " + e.getMessage());
+ return false;
+ } catch (MalformedURLException e) {
+ Log.logWarning("DigestURI", "SMB.isHidden MalformedURLException for " + this.toString() + ": " + e.getMessage());
+ return false;
+ }
return false;
}
public boolean isDirectory() {
if (isFile()) return getFSFile().isDirectory();
- if (isSMB()) try {return getSmbFile().isDirectory();}
- catch (SmbException e) {return false;}
- catch (MalformedURLException e) {return false;}
+ if (isSMB()) try {
+ return getSmbFile().isDirectory();
+ } catch (SmbException e) {
+ Log.logWarning("DigestURI", "SMB.isDirectory SmbException for " + this.toString() + ": " + e.getMessage());
+ return false;
+ } catch (MalformedURLException e) {
+ Log.logWarning("DigestURI", "SMB.isDirectory MalformedURLException for " + this.toString() + ": " + e.getMessage());
+ return false;
+ }
return false;
}
public long length() {
if (isFile()) return getFSFile().length();
- if (isSMB()) try {return getSmbFile().length();}
- catch (SmbException e) {return 0;}
- catch (MalformedURLException e) {return 0;}
+ if (isSMB()) try {
+ return getSmbFile().length();
+ } catch (SmbException e) {
+ Log.logWarning("DigestURI", "SMB.length SmbException for " + this.toString() + ": " + e.getMessage());
+ return 0;
+ } catch (MalformedURLException e) {
+ Log.logWarning("DigestURI", "SMB.length MalformedURLException for " + this.toString() + ": " + e.getMessage());
+ return 0;
+ }
return 0;
}
public long lastModified() {
if (isFile()) return getFSFile().lastModified();
- if (isSMB()) try {return getSmbFile().lastModified();}
- catch (SmbException e) {return 0;}
- catch (MalformedURLException e) {return 0;}
+ if (isSMB()) try {
+ return getSmbFile().lastModified();
+ } catch (SmbException e) {
+ Log.logWarning("DigestURI", "SMB.lastModified SmbException for " + this.toString() + ": " + e.getMessage());
+ return 0;
+ } catch (MalformedURLException e) {
+ Log.logWarning("DigestURI", "SMB.lastModified MalformedURLException for " + this.toString() + ": " + e.getMessage());
+ return 0;
+ }
return 0;
}
public String getName() {
if (isFile()) return getFSFile().getName();
- if (isSMB()) try {return getSmbFile().getName();} catch (MalformedURLException e) {return null;}
+ if (isSMB()) try {
+ return getSmbFile().getName();
+ } catch (MalformedURLException e) {
+ Log.logWarning("DigestURI", "SMB.getName MalformedURLException for " + this.toString() + ": " + e.getMessage());
+ return null;
+ }
return null;
}
public String[] list() {
if (isFile()) return getFSFile().list();
- if (isSMB()) try {return getSmbFile().list();}
- catch (SmbException e) {return null;}
- catch (MalformedURLException e) {return null;}
+ if (isSMB()) try {
+ return getSmbFile().list();
+ } catch (SmbException e) {
+ Log.logWarning("DigestURI", "SMB.list SmbException for " + this.toString() + ": " + e.getMessage());
+ return null;
+ } catch (MalformedURLException e) {
+ Log.logWarning("DigestURI", "SMB.list MalformedURLException for " + this.toString() + ": " + e.getMessage());
+ return null;
+ }
return null;
}