Skip to content

Commit

Permalink
refactor(hooks) remove duplicate handlers (Kong#2478)
Browse files Browse the repository at this point in the history
  • Loading branch information
p0pr0ck5 authored and Tieske committed May 1, 2017
1 parent da577a2 commit 0f9bca8
Showing 1 changed file with 0 additions and 13 deletions.
13 changes: 0 additions & 13 deletions kong/core/hooks.lua
Original file line number Diff line number Diff line change
Expand Up @@ -46,19 +46,6 @@ local function invalidate(message_t)

elseif message_t.collection == "ssl_servers_names" then
cache.delete(cache.certificate_key(message_t.entity.name))

elseif message_t.collection == "targets" then
-- targets only append new entries, we're not changing anything
-- but we need to reload the related upstreams target-history, so invalidate
-- that instead of the target
cache.delete(cache.targets_key(message_t.entity.upstream_id))

elseif message_t.collection == "upstreams" then
--we invalidate the list, the individual upstream, and its target history
cache.delete(cache.upstreams_dict_key())
cache.delete(cache.upstream_key(message_t.entity.id))
cache.delete(cache.targets_key(message_t.entity.id))
balancer.invalidate_balancer(message_t.entity.name)
end
end

Expand Down

0 comments on commit 0f9bca8

Please sign in to comment.