INNER CODE UNIT · JavaScript
MAX_BODY
vibeeval/vibecosystem · tools/dashboard/server.js:219
const MAX_BODY = 64 * 1024; // 64KB limit
req.on('data', chunk => {
bodySize += chunk.length;
if (bodySize > MAX_BODY) {
res.writeHead(413, { 'Content-Type': 'application/json' });
res.end('{"error":"payload too large"}');
req.destroy();
return;
}
body += chunk;
});
req.on('end', () => {
try {
const event = JSON.parse(body);
addEvent(event);
// Tum WS client'lara broadcast et
wss.clients.forEach(client => {
if (client.readyState === 1) { // WebSocket.OPEN