Pre and Post Action for Data Queries

Anything that you think should be in Cacti.

Moderators: Developers, Moderators

Post Reply
henkwiedig
Posts: 8
Joined: Thu Aug 06, 2009 1:32 pm
Location: Germany

Pre and Post Action for Data Queries

Post by henkwiedig »

We use a lot of Data Queries with do not get the data by snmp but insted we use SQL, CSV files, Web Pages, ...

It woult be useful to have a pre action in data queries wich could fetch the data to the local cacti maschine where it's then parsed, insted of for example calling the web page once per value.

Post acions could cleanup, start onother data gatering, ...
User avatar
TheWitness
Developer
Posts: 17047
Joined: Tue May 14, 2002 5:08 pm
Location: MI, USA
Contact:

Post by TheWitness »

I would prefer this to be done asynchronously. The pre and post actions, would likely slow things down.

By doing this asynchronously, we simply always expect the latest data to either be in your flat file, or database table.

So, I would like to reject this request, if you don't mind. There are too many published and unpublished plugins that already take the async route.

I suggest you look at a simple plugin like dsstats for a method to launch collectors in the background, if you want to do this in Cacti. There is a hook called poller_top and another called poller_bottom that address your requirement perfectly.

TheWitness
True understanding begins only when we realize how little we truly understand...

Life is an adventure, let yours begin with Cacti!

Author of dozens of Cacti plugins and customization's. Advocate of LAMP, MariaDB, IBM Spectrum LSF and the world of batch. Creator of IBM Spectrum RTM, author of quite a bit of unpublished work and most of Cacti's bugs.
_________________
Official Cacti Documentation
GitHub Repository with Supported Plugins
Percona Device Packages (no support)
Interesting Device Packages


For those wondering, I'm still here, but lost in the shadows. Yearning for less bugs. Who want's a Cacti 1.3/2.0? Streams anyone?
Post Reply

Who is online

Users browsing this forum: No registered users and 1 guest