summaryrefslogtreecommitdiff
path: root/plugins/logger/interface.go
diff options
context:
space:
mode:
Diffstat (limited to 'plugins/logger/interface.go')
-rw-r--r--plugins/logger/interface.go16
1 files changed, 16 insertions, 0 deletions
diff --git a/plugins/logger/interface.go b/plugins/logger/interface.go
new file mode 100644
index 00000000..876629a9
--- /dev/null
+++ b/plugins/logger/interface.go
@@ -0,0 +1,16 @@
+package logger
+
+type (
+ // Logger is an general RR log interface
+ Logger interface {
+ Debug(msg string, keyvals ...interface{})
+ Info(msg string, keyvals ...interface{})
+ Warn(msg string, keyvals ...interface{})
+ Error(msg string, keyvals ...interface{})
+ }
+)
+
+// With creates a child logger and adds structured context to it
+type WithLogger interface {
+ With(keyvals ...interface{}) Logger
+}