From 0b87edc7275724cc646341614772ac38d7bb852c Mon Sep 17 00:00:00 2001 From: Stef Walter Date: Sat, 15 Mar 2008 16:53:11 +0000 Subject: Use SNMP GETNEXT requests for the table queries. Make table queries more efficient by combining match/value in the same request whenever we've already gotten a match previously. --- daemon/rrdbotd.h | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) (limited to 'daemon/rrdbotd.h') diff --git a/daemon/rrdbotd.h b/daemon/rrdbotd.h index f907de2..c370bb6 100644 --- a/daemon/rrdbotd.h +++ b/daemon/rrdbotd.h @@ -72,6 +72,7 @@ typedef struct _rb_item /* The oid that we are querying */ struct asn_oid field_oid; + int field_request; /* Host names, with alternate hosts */ #define MAX_HOSTNAMES 16 @@ -83,8 +84,10 @@ typedef struct _rb_item int has_query; struct asn_oid query_oid; const char* query_match; - asn_subid_t query_last; - int query_value; + int query_matched; + int query_searched; + struct asn_oid query_last; + int query_request; /* The last value / current request */ union @@ -98,9 +101,6 @@ typedef struct _rb_item #define VALUE_FLOAT 2 int vtype; - /* A request in progress */ - int request; - /* Pointers to related */ struct _rb_poller* poller; @@ -123,6 +123,9 @@ typedef struct _rb_poller /* The things to poll. rb_poller owns this list */ rb_item* items; + /* Polling is active */ + int polling; + /* Book keeping */ mstime last_request; mstime last_polled; -- cgit v1.2.3