I have a Kong TCP plugin, I use this for user validation. I find it can only work in global, but I want it to work only on some routers. When I add it to routers or services, it does not work. My steps are as follows
1 add the plugin with handler.lua and schema.lua
2 the handler.lua is like this
function MyAuthHandler:preread(conf)
...parsing header
end
return MyAuthHandler
3 I add plugin through web like konga, if I add the plugin as global, it works. But it does not work if I add the plugin to some routers
My question is: Is there any special setting required for locally effective plugins? Or is there some doc?