summaryrefslogtreecommitdiff
path: root/qpid/java/management/client/console/resources_management.jsp
blob: 1541f3a5bc0ee8533a4785d7db6af28f6ff115be (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
<%@ taglib prefix="fmt" uri="http://java.sun.com/jsp/jstl/fmt" %>
<%@ taglib uri='http://java.sun.com/jsp/jstl/core' prefix='c'%>
<%@page import="org.apache.qpid.management.web.action.BrokerModel"%>
<%@page import="java.util.Set"%>
<%@page import="javax.management.ObjectName"%>
<%@page import="org.apache.qpid.management.Names"%>
<%@page import="java.util.List"%>

<%
	BrokerModel model = (BrokerModel) request.getAttribute("model");	
%>
<html>
	<head>
		<link rel="stylesheet" href="<%=request.getContextPath()%>/images/style.css" type="text/css" />
		<title>QMan Administration Console</title>
	</head>
	<body>
		<div id="page" align="center">
			<jsp:include page="/fragments/header.jsp">
				<jsp:param name="title" value="Resources Management"/>
			</jsp:include>
				
			<div id="content" align="center">
				<jsp:include page="/fragments/menu.jsp"/>
				
				
			<div id="contenttext">
        	<div id="wsdmmenu" align="left">
                <ul>
                	<% if (model != null) {%>
                    <li><a href="#"><span>${model.id}</span></a></li>
                    <%} %>
                </ul>
            </div>
            <br />
			<div class="panel" align="justify" style="height:500px; overflow-y:auto;">
				<span class="bodytext">
                	<table width="100%" border="0" cellpadding="1" cellspacing="2">
<%
	if (model != null ){
		Set<String> categoryNames = model.getCategoryNames();
		for(String categoryName : categoryNames)
		{
			List<ObjectName> categoryObjects = model.getCategory(categoryName);
%>                	          	
                    	<tr>
                        	<td valign="top" nowrap align="left">
								<fieldset>
									<legend><%=categoryName%></legend>
                                        		<h4 style="color: #006633; font-size: xx-small">
                                        			<ul>
                                                 	<%
                                                 		for (ObjectName objectName : categoryObjects)
                                                 		{%>
                                                 		
                                                 		<li>
                                                 			<a href="<%=request.getContextPath()%>/jmx_perspective?resourceId=<%=objectName%>">
                                                 				<%=objectName.getKeyProperty(Names.OBJECT_ID)%>
                                                 			</a>
                                                 		</li>
                                                 		<%
                                                 		}
                                                 	%>  
                                                 </ul>	 
								</fieldset>                                             
                        	</td>
						</tr>
<%
		}
	} else {
%>			
<table><tr>
<td nowrap style="font-weight: bold;" >Sorry, but it seems that QMan is not connected with any broker...</td>
</tr>
</table>
<%
	}
%>
				</table>
				</span>			
			</div>
		</div>
	</body>
</html>