From 2b1b16708e5f8670a54e89cac71e106e163232cd Mon Sep 17 00:00:00 2001 From: Chrono Date: Fri, 20 Sep 2024 18:33:24 +0800 Subject: [PATCH] fix(pdk/vault): handle crud events for dbless (#13663) * fix(pdk/vault): handle crud events for dbless * check cluster_rpc * fix mistake --- kong/pdk/vault.lua | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/kong/pdk/vault.lua b/kong/pdk/vault.lua index 14bf4f8bbbab..d0ef4cf3f359 100644 --- a/kong/pdk/vault.lua +++ b/kong/pdk/vault.lua @@ -1443,7 +1443,7 @@ local function new(self) --- -- Initializes vault. -- - -- Registers event handlers (on non-dbless nodes) and starts a recurring secrets + -- Registers event handlers and starts a recurring secrets -- rotation timer. It does nothing on control planes. -- -- @local @@ -1455,7 +1455,7 @@ local function new(self) initialized = true - if self.configuration.database ~= "off" then + if self.configuration.database ~= "off" or self.configuration.cluster_rpc then self.worker_events.register(handle_vault_crud_event, "crud", "vaults") end