You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@hbase.apache.org by to...@apache.org on 2010/12/14 04:57:30 UTC
svn commit: r1048927 - in /hbase/branches/0.90: CHANGES.txt
src/main/resources/hbase-webapps/master/table.jsp
src/main/resources/hbase-webapps/static/hbase.css
Author: todd
Date: Tue Dec 14 03:57:30 2010
New Revision: 1048927
URL: http://svn.apache.org/viewvc?rev=1048927&view=rev
Log:
HBASE-3353. table.jsp doesn't handle entries in META without server info
Modified:
hbase/branches/0.90/CHANGES.txt
hbase/branches/0.90/src/main/resources/hbase-webapps/master/table.jsp
hbase/branches/0.90/src/main/resources/hbase-webapps/static/hbase.css
Modified: hbase/branches/0.90/CHANGES.txt
URL: http://svn.apache.org/viewvc/hbase/branches/0.90/CHANGES.txt?rev=1048927&r1=1048926&r2=1048927&view=diff
==============================================================================
--- hbase/branches/0.90/CHANGES.txt (original)
+++ hbase/branches/0.90/CHANGES.txt Tue Dec 14 03:57:30 2010
@@ -738,6 +738,7 @@ Release 0.90.0 - Unreleased
info:regioninfo column
HBASE-3321 Replication.join shouldn't clear the logs znode
HBASE-3352 enabling a non-existent table from shell prints no error
+ HBASE-3353 table.jsp doesn't handle entries in META without server info
IMPROVEMENTS
Modified: hbase/branches/0.90/src/main/resources/hbase-webapps/master/table.jsp
URL: http://svn.apache.org/viewvc/hbase/branches/0.90/src/main/resources/hbase-webapps/master/table.jsp?rev=1048927&r1=1048926&r2=1048927&view=diff
==============================================================================
--- hbase/branches/0.90/src/main/resources/hbase-webapps/master/table.jsp (original)
+++ hbase/branches/0.90/src/main/resources/hbase-webapps/master/table.jsp Tue Dec 14 03:57:30 2010
@@ -138,21 +138,44 @@
<%= tableHeader %>
<%
for(Map.Entry<HRegionInfo, HServerAddress> hriEntry : regions.entrySet()) {
- int infoPort = master.getServerManager().getHServerInfo(hriEntry.getValue()).getInfoPort();
- String urlRegionServer =
- "http://" + hriEntry.getValue().getHostname().toString() + ":" + infoPort + "/";
+ HRegionInfo regionInfo = hriEntry.getKey();
+ HServerAddress addr = hriEntry.getValue();
+
+ int infoPort = 0;
+ String urlRegionServer = null;
+
+ if (addr != null) {
+ HServerInfo info = master.getServerManager().getHServerInfo(addr);
+ if (info != null) {
+ infoPort = info.getInfoPort();
+ urlRegionServer =
+ "http://" + addr.getHostname().toString() + ":" + infoPort + "/";
+ }
+ }
%>
<tr>
- <td><%= Bytes.toStringBinary(hriEntry.getKey().getRegionName())%></td>
- <td><a href="<%= urlRegionServer %>"><%= hriEntry.getValue().getHostname().toString() + ":" + infoPort %></a></td>
- <td><%= Bytes.toStringBinary(hriEntry.getKey().getStartKey())%></td>
- <td><%= Bytes.toStringBinary(hriEntry.getKey().getEndKey())%></td>
+ <td><%= Bytes.toStringBinary(regionInfo.getRegionName())%></td>
+ <%
+ if (urlRegionServer != null) {
+ %>
+ <td>
+ <a href="<%= urlRegionServer %>"><%= addr.getHostname().toString() + ":" + infoPort %></a>
+ </td>
+ <%
+ } else {
+ %>
+ <td class="undeployed-region">not deployed</td>
+ <%
+ }
+ %>
+ <td><%= Bytes.toStringBinary(regionInfo.getStartKey())%></td>
+ <td><%= Bytes.toStringBinary(regionInfo.getEndKey())%></td>
</tr>
<% } %>
</table>
<% }
} catch(Exception ex) {
- ex.printStackTrace();
+ ex.printStackTrace(System.err);
}
} // end else
%>
Modified: hbase/branches/0.90/src/main/resources/hbase-webapps/static/hbase.css
URL: http://svn.apache.org/viewvc/hbase/branches/0.90/src/main/resources/hbase-webapps/static/hbase.css?rev=1048927&r1=1048926&r2=1048927&view=diff
==============================================================================
--- hbase/branches/0.90/src/main/resources/hbase-webapps/static/hbase.css (original)
+++ hbase/branches/0.90/src/main/resources/hbase-webapps/static/hbase.css Tue Dec 14 03:57:30 2010
@@ -13,3 +13,7 @@ div.warning {
font-size: 110%;
font-weight: bold;
}
+
+td.undeployed-region {
+ background-color: #faa;
+}