mirror of
https://github.com/hibiken/asynqmon.git
synced 2025-08-23 22:28:43 +08:00
Display queue memory usage in task view
This commit is contained in:
@@ -217,6 +217,7 @@ export interface Queue {
|
||||
queue: string;
|
||||
paused: boolean;
|
||||
size: number;
|
||||
memory_usage_bytes: number;
|
||||
active: number;
|
||||
pending: number;
|
||||
scheduled: number;
|
||||
|
@@ -2,6 +2,7 @@ import React from "react";
|
||||
import { connect, ConnectedProps } from "react-redux";
|
||||
import { makeStyles } from "@material-ui/core/styles";
|
||||
import Typography from "@material-ui/core/Typography";
|
||||
import prettyBytes from "pretty-bytes";
|
||||
import { AppState } from "../store";
|
||||
import { percentage } from "../utils";
|
||||
|
||||
@@ -68,7 +69,9 @@ function QueueInfoBanner(props: Props & ReduxProps) {
|
||||
<Typography variant="subtitle2" color="textPrimary" gutterBottom>
|
||||
Memory usage
|
||||
</Typography>
|
||||
<Typography color="textSecondary">1.2MB</Typography>
|
||||
<Typography color="textSecondary">
|
||||
{queue ? prettyBytes(queue.memory_usage_bytes) : "-"}
|
||||
</Typography>
|
||||
</div>
|
||||
|
||||
<div className={classes.bannerItem}>
|
||||
|
Reference in New Issue
Block a user