Improve container details UX, dashboard shortcuts, and RPC rate limits.
Release rolling / release (push) Successful in 8m38s
Release rolling / release (push) Successful in 8m38s
Tighten container detail tabs into a fit-to-viewport layout with a richer overview, debounced process filters, and a readable process table. Make dashboard KPI cards navigate to resource views (with status filters that reset on leave), and raise per-peer RPC limits so normal UI polling no longer trips rate limiting.
This commit is contained in:
@@ -7,21 +7,22 @@ class RateLimiter {
|
||||
// Map of peer ID to request timestamps
|
||||
this.requests = new Map();
|
||||
|
||||
// Configuration
|
||||
// Configuration — sized for interactive UI (auto-refresh, dashboard,
|
||||
// multi-tab inspect) without tripping under normal operator use.
|
||||
this.config = {
|
||||
maxRequests: 100, // Max requests per window (non-stream)
|
||||
maxRequests: 3000, // Max non-stream RPCs per window (~50/s avg)
|
||||
windowMs: 60000, // 1 minute window
|
||||
commandLimits: {
|
||||
deployContainer: { max: 5, windowMs: 60000 }, // 5 deployments per minute
|
||||
dockerCommand: { max: 30, windowMs: 10000 }, // 30 commands per 10 seconds
|
||||
startContainer: { max: 20, windowMs: 60000 }, // 20 starts per minute
|
||||
stopContainer: { max: 20, windowMs: 60000 }, // 20 stops per minute
|
||||
deployContainer: { max: 30, windowMs: 60000 }, // deploys per minute
|
||||
dockerCommand: { max: 200, windowMs: 10000 }, // host docker CLI / 10s
|
||||
startContainer: { max: 120, windowMs: 60000 }, // starts per minute
|
||||
stopContainer: { max: 120, windowMs: 60000 }, // stops per minute
|
||||
},
|
||||
};
|
||||
|
||||
/**
|
||||
* High-frequency stream methods (keystrokes, resizes, chunks).
|
||||
* Exempt from the general 100/min cap; optional soft ceiling.
|
||||
* Exempt from the general cap; optional soft ceiling.
|
||||
*/
|
||||
this.streamMethods = new Set([
|
||||
'terminalInput',
|
||||
@@ -32,7 +33,7 @@ class RateLimiter {
|
||||
'binaryStreamChunk',
|
||||
'dockerTerminalResize',
|
||||
]);
|
||||
this.streamLimit = { max: 6000, windowMs: 60000 }; // ~100/s sustained
|
||||
this.streamLimit = { max: 18000, windowMs: 60000 }; // ~300/s sustained
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user