Merge branch 'ff/dns'
[collectd.git] / src / plugin.h
index e1303c7..a77c87f 100644 (file)
@@ -1,3 +1,6 @@
+#ifndef PLUGIN_H
+#define PLUGIN_H
+
 /**
  * collectd - src/plugin.h
  * Copyright (C) 2005,2006  Florian octo Forster
  *   Florian octo Forster <octo at verplant.org>
  **/
 
-#ifndef PLUGIN_H
-#define PLUGIN_H
+/*
+ *
+ */
+typedef struct complain_s
+{
+       unsigned int interval; /* how long we wait for reporting this error again */
+       unsigned int delay;    /* how many more iterations we still need to wait */
+} complain_t;
 
 /*
  * NAME
@@ -90,7 +99,7 @@ int  plugin_load (const char *type);
 
 int  plugin_load_all (char *dir);
 void plugin_init_all (void);
-void plugin_read_all (void);
+void plugin_read_all (const int *loop);
 
 void plugin_register (char *type,
                void (*init) (void),
@@ -117,4 +126,8 @@ void plugin_write    (char *host, char *type, char *inst, char *val);
 
 void plugin_submit   (char *type, char *inst, char *val);
 
+
+void plugin_complain (int level, complain_t *c, const char *format, ...);
+void plugin_relief (int level, complain_t *c, const char *format, ...);
+
 #endif /* PLUGIN_H */