Charcoal-SE / metasmoke

Web dashboard for SmokeDetector.
https://metasmoke.erwaysoftware.com
Creative Commons Zero v1.0 Universal
43 stars 34 forks source link

Add an "Active" column per Smokey Instance on the Status page #687

Closed rschrieken closed 4 years ago

rschrieken commented 4 years ago

On the status page https://metasmoke.erwaysoftware.com/status we see the available smokey instances. We find their name and last ping.

That status page becomes relevant when two instances are active (aka !!/location gets two or more replies) because this seems to be the agreed guidance

Each of those two messages was sent by a different instance (on completely separate computers in different areas of the world, although most instances are in the USA). The order of those messages doesn't matter. You can go to the SD status page and click on each instance to see a graph of activity for that instance. The one that has been active the most over the last while is the one we will normally prefer stays running. The reason for that is that there is some state information which is specific to each instance (e.g. user-blacklist; notify list; recently reported post list; user-whitelist; etc). We generally want to keep the instance active which has the larger amount of recent information.

To make the correct call you have to open two active graphs and then by eye decide which one is the most "active".

I think a number that represents the number of sent messages over the last hour, day and week would work here but any other stat that is cheap to get and helps in making the decision which instance to keep and which one to standby is fine.

ArtOfCode- commented 4 years ago

Already kinda exists, enough that I'm gonna call this completed: click on the instance name from the status page. It'll take you to a page of statistics, including the number of posts scanned in recent history. You can use those numbers to decide - you can also switch it to a daily view to see which instance has scanned more posts (and has therefore been more active) today.

rschrieken commented 4 years ago

but @ArtOfCode- this:

To make the correct call you have to open two active graphs and then by eye decide which one is the most "active".

was the most relevant part of my request, to basically not have to open multiple tabs to compare stuff. I wouldn't call that completed ;)

ArtOfCode- commented 4 years ago

Broke it again while trying to make it more efficient. Reopening and self-assigning to remind me to work on this when I next have time.

ArtOfCode- commented 4 years ago

Actually fixed now

double-beep commented 4 years ago

@ArtOfCode- can you add 0 instead of unavailable if the instance has done 0 scans?

ArtOfCode- commented 4 years ago

@double-beep (unavailable) does not necessarily indicate zero scans; it may also indicate an error. Adding a zero as well would require another few queries, so I'd rather not add it for minimal gain; if you see an "unavailable", just assume it's inactive.