Getting values from other Datapoints in Groovy ComplexDatapoint
Hello,
Is there any possibility/workaround of invoking other datapoint values within a Groovy Complex DP?
Thank you!
Vitor_Santos
Posted 5 years ago·Last reply 4 years ago
9 comments
Hello,
Is there any possibility/workaround of invoking other datapoint values within a Groovy Complex DP?
Thank you!
jrip
·4 years ago@Vitor Santos Care to share how you managed to do this?
Vitor_Santos
OP5 years agoUnderstood...
Yeah, thankfully we've arranged other solution.
Appreciate the help anyway!
LM User
·5 years agoYeah, the output is passed to the groovy datapoint before the delta is calculated. Simply the raw output from the poll.
Vitor_Santos
OP5 years agoWe were already doing that. However, we wanted values from other datapoints (gauge, derive, etc...).... Which as per the documentation isn't possible (validated on Friday)
LM User
·5 years agoFor Groovy based datapoints, when SNMP is the collector, there is a variable set in the script called "output". You can parse through that output variable to get the data. If it's counters, you'd need to use collector script caching to get the previous poll value to run the delta manually.
Vitor_Santos
OP5 years agoThe collection method is SNMP.
In the meanwhile, we've managed to sort it out using another method.
LM User
·5 years agoWhat's the collection method used?
Vitor_Santos
OP5 years agoTotally understand you...
But, for what we want it would really need to access the actual datapoints value... Unfortunately, we'll need to leverage other options.
I appreciate your reply anyway mate :)/emoticons/smile@2x.png 2x" title=":)" width="20" />
mnagel
·5 years agoSeems like a no-brainer to support that, right? The only way you could as it stands is via API calls, which, without library support, is a non-starter for me. It could be done if you want to maintain many copies of the same code across modules (which seems to be the norm now, except they are all slightly different based on who writes them as you would expect).