fix: restore channels after gateway restart
This commit is contained in:
@@ -58,4 +58,11 @@ if (!workerMain.includes("process.env.API_WORKER_METRICS_HOST?.trim() || '127.0.
|
||||
throw new Error('send worker metrics must default to loopback');
|
||||
}
|
||||
|
||||
const gatewayRestart = deploy.indexOf('systemctl restart cmpp-gateway');
|
||||
const apiRestart = deploy.indexOf('systemctl restart cmpp-api');
|
||||
const workerRestart = deploy.indexOf('systemctl restart cmpp-send-worker');
|
||||
if (gatewayRestart < 0 || apiRestart < gatewayRestart || workerRestart < apiRestart) {
|
||||
throw new Error('production deploy must restart Gateway before API and the send worker so API startup restores active channels');
|
||||
}
|
||||
|
||||
console.log('Production deployment verified: Nginx/API guards and the split durable send worker contract are present.');
|
||||
|
||||
Reference in New Issue
Block a user