Skip to content

Commit

Permalink
Add number of cores used by RabbitMQ nodes to the management overview.
Browse files Browse the repository at this point in the history
Also remove the deprectated node type field from the UI to reclaim
some screen estate.

RAM nodes are deprecated and almost never used.
  • Loading branch information
kjnilsson committed Jun 5, 2024
1 parent ebbff46 commit 95ea150
Show file tree
Hide file tree
Showing 4 changed files with 17 additions and 15 deletions.
6 changes: 6 additions & 0 deletions deps/rabbitmq_management/priv/www/api/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -2068,6 +2068,12 @@ <h2>/api/nodes</h2>
Time since the Erlang VM started, in milliseconds.
</td>
</tr>
<tr>
<td><code>processors</code></td>
<td>
Number of logical CPU cores used by RabbitMQ.
</td>
</tr>
</table>

<h2>/api/nodes/(name)</h2>
Expand Down
1 change: 1 addition & 0 deletions deps/rabbitmq_management/priv/www/js/global.js
Original file line number Diff line number Diff line change
Expand Up @@ -141,6 +141,7 @@ var ALL_COLUMNS =
['memory', 'Memory', true],
['disk_space', 'Disk space', true]],
'General': [['uptime', 'Uptime', true],
['cores', 'Cores', true],
['info', 'Info', true],
['reset_stats', 'Reset stats', true]]}};

Expand Down
14 changes: 4 additions & 10 deletions deps/rabbitmq_management/priv/www/js/tmpl/node.ejs
Original file line number Diff line number Diff line change
Expand Up @@ -23,22 +23,16 @@
<th>Uptime</th>
<td><%= fmt_uptime(node.uptime) %></td>
</tr>
<tr>
<th>Cores</th>
<td><%= fmt_string(node.processors) %></td>
</tr>
<% if (rabbit_versions_interesting) { %>
<tr>
<th>RabbitMQ Version</th>
<td><%= fmt_rabbit_version(node.applications) %></td>
</tr>
<% } %>
<tr>
<th>Type</th>
<td>
<% if (node.type == 'disc') { %>
<abbr title="Broker definitions are held on disc.">Disc</abbr>
<% } else { %>
<abbr title="Broker definitions are held in RAM. Messages will still be written to disc if necessary.">RAM</abbr>
<% } %>
</td>
</tr>
<tr>
<th>
<a href="https://www.rabbitmq.com/configure.html" target="_blank">Config file</a>
Expand Down
11 changes: 6 additions & 5 deletions deps/rabbitmq_management/priv/www/js/tmpl/overview.ejs
Original file line number Diff line number Diff line change
Expand Up @@ -99,6 +99,9 @@
<% if (show_column('overview', 'uptime')) { %>
<th>Uptime</th>
<% } %>
<% if (show_column('overview', 'cores')) { %>
<th>Cores</th>
<% } %>
<% if (show_column('overview', 'info')) { %>
<th>Info</th>
<% } %>
Expand Down Expand Up @@ -188,17 +191,15 @@
<% if (show_column('overview', 'uptime')) { %>
<td><span><%= fmt_uptime(node.uptime) %></span></td>
<% } %>
<% if (show_column('overview', 'cores')) { %>
<td><span><%= fmt_string(node.processors) %></span></td>
<% } %>
<% if (show_column('overview', 'info')) { %>
<td>
<% if (node.being_drained) { %>
<abbr class="status-yellow" title="Node was put under maintenance">maintenance mode</abbr>
<% } %>
<abbr title="Message rates"><%= fmt_string(node.rates_mode) %></abbr>
<% if (node.type == 'disc') { %>
<abbr title="Broker definitions are held on disc.">disc</abbr>
<% } else { %>
<abbr title="Broker definitions are held in RAM. Messages will still be written to disc if necessary.">RAM</abbr>
<% } %>
<%= fmt_plugins_small(node) %>
<abbr title="Memory calculation strategy"><%= fmt_string(node.mem_calculation_strategy) %></abbr>
</td>
Expand Down

0 comments on commit 95ea150

Please sign in to comment.