Skip to content

Commit a193716

Browse files
committed
move debug print to balancer.lua
1 parent 670352c commit a193716

File tree

2 files changed

+1
-1
lines changed

2 files changed

+1
-1
lines changed

rootfs/etc/nginx/lua/balancer.lua

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -123,6 +123,7 @@ local function sync_backend(backend)
123123
balancers[backend.name] = nil
124124
return
125125
end
126+
print("Syncing backend: ", backend.name, "with endpoints: ", cjson.encode(backend.endpoints))
126127

127128
backend.endpoints = format_ipv6_endpoints(backend.endpoints)
128129

rootfs/etc/nginx/lua/test/balancer_test.lua

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -453,7 +453,6 @@ describe("Balancer", function()
453453
implementation.new = function(self, backend) return mock_instance end
454454
local s = spy.on(implementation, "new")
455455
assert.has_no.errors(function() balancer.sync_backend(backend) end)
456-
print(cjson.encode(balancer.get_balancer_by_upstream_name(backend.name)))
457456
assert.spy(s).was_not_called()
458457
assert.is_nil(balancer.get_balancer_by_upstream_name(backend.name))
459458
end)

0 commit comments

Comments
 (0)