example icon indicating copy to clipboard operation
example copied to clipboard

Example doesn't print anything

Open rstupek opened this issue 1 year ago • 2 comments

Example plugin does not print anything using provided Corefile

.:1053 { example log forward . 8.8.8.8 }

Sample output: CoreDNS-1.11.1 linux/amd64, go1.20.12, 945db2fa-dirty [INFO] 127.0.0.1:45207 - 6605 "A IN google.com. udp 39 false 4096" NOERROR qr,rd,ra 195 0.002194196s

Also a new plugin created using the instructions provided for creating plugins similarly does not print anything

I have tried moving the example plugin around in the corefile with no differences viewed.

rstupek avatar Jan 19 '24 17:01 rstupek

I'm experiencing the same thing. When I try to do a lookup I'm not seeing the output even if I add debug to my Corefile.

litobro avatar Apr 17 '24 02:04 litobro

I've successfully implemented a plugin with logging. Can you try increasing the position of your plugin inside of plugin.cfg? If you place it below cache:cache this should allow it to print properly. As the comment says, the order is important.

litobro avatar Apr 18 '24 00:04 litobro