monitor_list.jsp 9.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245
  1. <%@ include file="../common/header.jsp" %>
  2. <script type="text/javascript">
  3. <!--
  4. function chart(title, id, ts, raw) {
  5. var data = new Array();
  6. var rl = raw.length;
  7. for (var i=0,il=raw.length; i<il; i++) {
  8. data.push([i, raw[i]]);
  9. }
  10. var myChart = new JSChart(id, 'line');
  11. myChart.setTitle(title);
  12. myChart.setSize(800, 600);
  13. myChart.setDataArray(data);
  14. myChart.setIntervalStartX(0);
  15. myChart.setIntervalEndX(rl);
  16. myChart.setShowXValues(false);
  17. myChart.setAxisNameX('Time');
  18. myChart.setAxisNameY('');
  19. var time = new Date(ts);
  20. var hs = time.getHours() * 60 + time.getMinutes();
  21. var hsm = Math.floor(hs / 120) * 120;
  22. var p = hs - hsm;
  23. hsm += 1440;
  24. for (var i=0; i<24; i++) {
  25. var m = hsm % 60;
  26. var h = (hsm / 60) % 24;
  27. var s = (h > 9 ? h : '0'+h) + ':' + (m > 9 ? m : '0'+m);
  28. myChart.setLabelX([p, s]);
  29. hsm -= 120;
  30. p += 120;
  31. }
  32. myChart.draw();
  33. }
  34. function doStart(adaptorId){
  35. document.forms.monitor.action.value="start";
  36. document.forms.monitor.clear.value="true";
  37. document.forms.monitor.adaptorId.value=adaptorId;
  38. document.forms.monitor.submit();
  39. }
  40. function doStop(adaptorId){
  41. document.forms.monitor.action.value="stop";
  42. document.forms.monitor.clear.value="true";
  43. document.forms.monitor.adaptorId.value=adaptorId;
  44. document.forms.monitor.submit();
  45. }
  46. function doKill(correlId,adaptorId){
  47. document.forms.monitor.action.value="kill";
  48. document.forms.monitor.clear.value="true";
  49. document.forms.monitor.correlId.value=correlId;
  50. document.forms.monitor.adaptorId.value=adaptorId;
  51. document.forms.monitor.submit();
  52. }
  53. -->
  54. </script>
  55. <form name="monitor" method="post" action="monitor.do">
  56. <input type="hidden" name="start" value="">
  57. <input type="hidden" name="startx" value="">
  58. <input type="hidden" name="action" value="">
  59. <input type="hidden" name="code" value="">
  60. <input type="hidden" name="adaptorId" value="">
  61. <input type="hidden" name="correlId" value="">
  62. <input type="hidden" name="count" value="">
  63. <input type="hidden" name="clear" value="">
  64. <table width="100%" border="0" align="center" cellpadding="2" cellspacing="4">
  65. <tr>
  66. <td class="titleHeader"><bean:message key="project.monitor.key"/> - LIST</td>
  67. </tr>
  68. </table>
  69. <table width="100%" border="0" cellspacing="1" cellpadding="1">
  70. <logic:notEmpty name="monitorList">
  71. <logic:iterate id="element" name="monitorList" scope="request" indexId="index">
  72. <tr>
  73. <logic:notEmpty name="element" property="broker">
  74. <td width="20%" align="left" height="10" valign="top" class="titleField">Broker</td>
  75. </logic:notEmpty>
  76. <logic:notEmpty name="element" property="executionGroup">
  77. <td width="20%" align="left" height="10" valign="top" class="titleField">
  78. Execution Group &nbsp;&nbsp;
  79. <input type="button" value="Start" onclick="javascript:doStart('<bean:write name="element" property="executionGroup"/>');">
  80. &nbsp;&nbsp;
  81. <input type="button" value="Stop" onclick="javascript:doStop();">
  82. </td>
  83. </logic:notEmpty>
  84. <logic:notEmpty name="element" property="flow">
  85. <td width="20%" align="left" height="10" valign="top" class="titleField">Flow</td>
  86. </logic:notEmpty>
  87. <logic:notEmpty name="element" property="idTcp">
  88. <td width="20%" align="left" height="10" valign="top" class="titleField">Id</td>
  89. </logic:notEmpty>
  90. </tr>
  91. <tr>
  92. <td width="10%" align="left" valign="top"></td>
  93. <logic:notEmpty name="element" property="group">
  94. <td width="20%" align="left" height="10" valign="top" class="titleField">Group</td>
  95. </logic:notEmpty>
  96. <logic:notEmpty name="element" property="idServerPort">
  97. <td width="20%" align="left" height="10" valign="top" class="titleField">Id</td>
  98. </logic:notEmpty>
  99. <logic:notEmpty name="element" property="port">
  100. <td width="20%" align="left" height="10" valign="top" class="titleField">
  101. Port
  102. </td>
  103. </logic:notEmpty>
  104. <logic:notEmpty name="element" property="statusServerPort">
  105. <td width="20%" align="left" height="10" valign="top" class="titleField">Status</td>
  106. </logic:notEmpty>
  107. </tr>
  108. <tr>
  109. <td width="10%" align="left" valign="top"></td>
  110. <td width="10%" align="left" valign="top"></td>
  111. <logic:notEmpty name="element" property="ckd">
  112. <td width="10%" align="left" height="10" valign="top" class="titleField">Ckd</td>
  113. </logic:notEmpty>
  114. <logic:notEmpty name="element" property="connectTime">
  115. <td width="20%" align="left" height="10" valign="top" class="titleField">Connect Time</td>
  116. </logic:notEmpty>
  117. <logic:notEmpty name="element" property="corellationId">
  118. <td width="10%" align="left" height="10" valign="top" class="titleField">
  119. Corellation ID &nbsp;&nbsp;
  120. <input type="button" value="Start" onclick="javascript:doKill('<bean:write name="element" property="corellationId"/>,<bean:write name="element" property="executionGroup"/>');">
  121. </td>
  122. </logic:notEmpty>
  123. <logic:notEmpty name="element" property="idChannel">
  124. <td width="10%" align="left" height="10" valign="top" class="titleField">Id</td>
  125. </logic:notEmpty>
  126. <logic:notEmpty name="element" property="incomingCount">
  127. <td width="5%" align="left" height="10" valign="top" class="titleField">Incoming Count</td>
  128. </logic:notEmpty>
  129. <logic:notEmpty name="element" property="lastActivity">
  130. <td width="20%" align="left" height="10" valign="top" class="titleField">Last Activity</td>
  131. </logic:notEmpty>
  132. <logic:notEmpty name="element" property="outgoingCount">
  133. <td width="5%" align="left" height="10" valign="top" class="titleField">Outgoing Count</td>
  134. </logic:notEmpty>
  135. <logic:notEmpty name="element" property="signOn">
  136. <td width="10%" align="left" height="10" valign="top" class="titleField">Sign On</td>
  137. </logic:notEmpty>
  138. <logic:notEmpty name="element" property="statusChannel">
  139. <td width="10%" align="left" height="10" valign="top" class="titleField">Status</td>
  140. </logic:notEmpty>
  141. </tr>
  142. <tr>
  143. <logic:notEmpty name="element" property="broker">
  144. <td align="left" class="celBorder">
  145. &nbsp;<bean:write name="element" property="broker"/>
  146. </td>
  147. </logic:notEmpty>
  148. <logic:notEmpty name="element" property="executionGroup">
  149. <td align="left" class="celBorder">
  150. &nbsp;<bean:write name="element" property="executionGroup"/>
  151. </td>
  152. </logic:notEmpty>
  153. <logic:notEmpty name="element" property="flow">
  154. <td align="left" class="celBorder">
  155. &nbsp;<bean:write name="element" property="flow"/>
  156. </td>
  157. </logic:notEmpty>
  158. <logic:notEmpty name="element" property="idTcp">
  159. <td align="left" class="celBorder">
  160. &nbsp;<bean:write name="element" property="idTcp"/>
  161. </td>
  162. </logic:notEmpty>
  163. </tr>
  164. <tr>
  165. <td align="left"></td>
  166. <logic:notEmpty name="element" property="group">
  167. <td align="left" class="celBorder">
  168. &nbsp;<bean:write name="element" property="group"/>
  169. </td>
  170. </logic:notEmpty>
  171. <logic:notEmpty name="element" property="idServerPort">
  172. <td align="left" class="celBorder">
  173. &nbsp;<bean:write name="element" property="idServerPort"/>
  174. </td>
  175. </logic:notEmpty>
  176. <logic:notEmpty name="element" property="port">
  177. <td align="left" class="celBorder">
  178. &nbsp;<bean:write name="element" property="port"/>
  179. </td>
  180. </logic:notEmpty>
  181. <logic:notEmpty name="element" property="statusServerPort">
  182. <td align="left" class="celBorder">
  183. &nbsp;<bean:write name="element" property="statusServerPort"/>
  184. </td>
  185. </logic:notEmpty>
  186. </tr>
  187. <tr>
  188. <td align="left"></td>
  189. <td align="left"></td>
  190. <logic:notEmpty name="element" property="ckd">
  191. <td align="left" class="celBorder">
  192. &nbsp;<bean:write name="element" property="ckd"/>
  193. </td>
  194. </logic:notEmpty>
  195. <logic:notEmpty name="element" property="connectTime">
  196. <td align="left" class="celBorder">
  197. &nbsp;<bean:write name="element" property="connectTime"/>
  198. </td>
  199. </logic:notEmpty>
  200. <logic:notEmpty name="element" property="corellationId">
  201. <td align="left" class="celBorder">
  202. &nbsp;<bean:write name="element" property="corellationId"/>
  203. </td>
  204. </logic:notEmpty>
  205. <logic:notEmpty name="element" property="idChannel">
  206. <td align="left" class="celBorder">
  207. &nbsp;<bean:write name="element" property="idChannel"/>
  208. </td>
  209. </logic:notEmpty>
  210. <logic:notEmpty name="element" property="incomingCount">
  211. <td align="left" class="celBorder">
  212. &nbsp;<bean:write name="element" property="incomingCount"/>
  213. </td>
  214. </logic:notEmpty>
  215. <logic:notEmpty name="element" property="lastActivity">
  216. <td align="left" class="celBorder">
  217. &nbsp;<bean:write name="element" property="lastActivity"/>
  218. </td>
  219. </logic:notEmpty>
  220. <logic:notEmpty name="element" property="outgoingCount">
  221. <td align="left" class="celBorder">
  222. &nbsp;<bean:write name="element" property="outgoingCount"/>
  223. </td>
  224. </logic:notEmpty>
  225. <logic:notEmpty name="element" property="signOn">
  226. <td align="left" class="celBorder">
  227. &nbsp;<bean:write name="element" property="signOn"/>
  228. </td>
  229. </logic:notEmpty>
  230. <logic:notEmpty name="element" property="statusChannel">
  231. <td align="left" class="celBorder">
  232. &nbsp;<bean:write name="element" property="statusChannel"/>
  233. </td>
  234. </logic:notEmpty>
  235. </tr>
  236. </logic:iterate>
  237. </logic:notEmpty>
  238. </table>
  239. </form>
  240. <%@ include file="../common/footer.jsp" %>