rearrange metrics
This commit is contained in:
parent
be0f53c0e2
commit
f237d292be
|
@ -31,6 +31,15 @@ export const UserCount = new client.Gauge({
|
|||
},
|
||||
});
|
||||
|
||||
export const InstanceCount = new client.Gauge({
|
||||
name: "instance_count",
|
||||
help: "total number of unique instances",
|
||||
|
||||
async collect() {
|
||||
this.set(await prisma.instance.count());
|
||||
},
|
||||
});
|
||||
|
||||
export const OnlineUsers = new client.Gauge({
|
||||
name: "connected_count",
|
||||
help: "total connected sockets",
|
||||
|
@ -82,15 +91,6 @@ export const TotalPixels = new client.Gauge({
|
|||
},
|
||||
});
|
||||
|
||||
export const UniqueInstances = new client.Gauge({
|
||||
name: "instance_count",
|
||||
help: "total number of unique instances",
|
||||
|
||||
async collect() {
|
||||
this.set(await prisma.instance.count());
|
||||
},
|
||||
});
|
||||
|
||||
export const handleMetricsEndpoint = async (
|
||||
req: e.Request,
|
||||
res: e.Response
|
||||
|
|
Loading…
Reference in New Issue