I managed to get the first of your examples, the one with a basic graph, to
work. Thats great! But when I try the 95th percentile script I get the
following error:
[root@... /usr/local/opennms/bin]# groovy test.groovy
org.codehaus.groovy.control.MultipleCompilationErrorsException: startup
failed, /usr/local/opennms/bin/test.groovy: 19: unable to resolve class
DataProcessor
@ line 19, column 15.
DataProcessor dp = new DataProcessor((int)(startTime.getTime()/1000),
(int)(endTime.getTime()/1000));
^
/usr/local/opennms/bin/test.groovy: 19: unable to resolve class
DataProcessor
@ line 19, column 20.
DataProcessor dp = new DataProcessor((int)(startTime.getTime()/1000),
(int)(endTime.getTime()/1000));
^
/usr/local/opennms/bin/test.groovy: 20: unable to resolve class
DataProcessor
@ line 20, column 1.
dp.addDatasource("octIn",rrd1, "ifInOctets", "AVERAGE");
^
/usr/local/opennms/bin/test.groovy: 21: unable to resolve class
DataProcessor
@ line 21, column 1.
dp.addDatasource("octOut", rrd2, "ifOutOctets", "AVERAGE");
^
/usr/local/opennms/bin/test.groovy: 22: unable to resolve class
DataProcessor
@ line 22, column 1.
dp.addDatasource("rawbitsIn", "octIn,8,*");
^
/usr/local/opennms/bin/test.groovy: 23: unable to resolve class
DataProcessor
@ line 23, column 1.
dp.addDatasource("rawbitsOut", "octOut,8,*");
^
/usr/local/opennms/bin/test.groovy: 24: unable to resolve class
DataProcessor
@ line 24, column 1.
dp.addDatasource("rawbitsOutNeg", "0,rawbitsOut,-");
^
/usr/local/opennms/bin/test.groovy: 25: unable to resolve class
DataProcessor
@ line 25, column 3.
dp.processData();
^
/usr/local/opennms/bin/test.groovy: 28: unable to resolve class
DataProcessor
@ line 28, column 8.
in95 = dp.getPercentile("rawbitsIn");
^
/usr/local/opennms/bin/test.groovy: 29: unable to resolve class
DataProcessor
@ line 29, column 9.
out95 = dp.getPercentile("rawbitsOut");
^
/usr/local/opennms/bin/test.groovy: 30: unable to resolve class
DataProcessor
@ line 30, column 12.
out95neg = dp.getPercentile("rawbitsOutNeg");
^
11 errors
[root@... /usr/local/opennms/bin]#
Any ideas on what cousing this?
/Marcus
On Fri, 29 May 2009 09:25:32 +1200, Daniel Lawson <daniel@...>
wrote:
> Marcus Eide wrote:
>> Hi all,
>> I'd like to export graphs from some of the .jrb files created by OpenNMS
>> and present them on a different webserver. It's a customer portal I've
>> been
>> working on, and I figured it'll be a nice feature for my customers.
>>
>> I've been trying to find information on how this can be done, but I am
>> way
>> too inexperienced with java/jrobin to pull it off my self. Therefore I
>> wonder if any of you maybe know how to do it? Basically I just want to
>> use
>> a .jrb file to create a .png graph. So, if you have any thought or maybe
>> some scripts you already made, I'll be really interested!
>>
>
> I had to the same thing a while ago, because I needed to give users
> visibility into only a certain set of port graphs.
>
> The guts of my system is a script written in groovy (interpreted java,
> basically), which I posted to the opennms wiki at
> http://www.opennms.org/index.php/Groovy_Scripting
>
>
> This script is a bit basic, but it shouldn't be too hard to see where to
> take it from there. As a note to the other poster, this script also
> generates 95th percentiles.
>
>
>
------------------------------------------------------------------------------
> Register Now for Creativity and Technology (CaT), June 3rd, NYC. CaT
> is a gathering of tech-side developers & brand creativity professionals.
> Meet
> the minds behind Google Creative Lab, Visual Complexity, Processing, &
> iPhoneDevCamp as they present alongside digital heavyweights like
Barbarian
>
> Group, R/GA, & Big Spaceship. http://p.sf.net/sfu/creativitycat-com
> _______________________________________________
> Please read the OpenNMS Mailing List FAQ:
> http://www.opennms.org/index.php/Mailing_List_FAQ
>
> opennms-discuss mailing list
>
> To *unsubscribe* or change your subscription options, see the bottom of
> this page:
> https://lists.sourceforge.net/lists/listinfo/opennms-discuss
|