drain old web slot before blue-green shutdown

This commit is contained in:
2026-09-21 09:26:50 +08:00
parent 3b4e288564
commit 8f2f485402
3 changed files with 10 additions and 1 deletions
@@ -26,6 +26,9 @@ test('all backend business services have blue-green runtime contracts', async ()
assert.match(script, /connect_routing_aliases "\$candidate" "\$ROUTING_ALIAS" "\$NACOS_SERVICE"/)
assert.match(script, /file,file-service:file/)
assert.match(script, /docker stop --time "\$STOP_TIMEOUT" "\$active_container"/)
assert.match(script, /DRAIN_SECONDS="\$\{BLUE_GREEN_DRAIN_SECONDS:-30\}"/)
assert.match(script, /蓝绿切换后连接排空/)
assert.match(script, /sleep "\$DRAIN_SECONDS"/)
assert.match(script, /mv -f "\$STATE_FILE\.tmp" "\$STATE_FILE"/)
})