Announcement Announcement Module
Collapse
No announcement yet.
Hyperic Page Title Module
Move Remove Collapse
X
Conversation Detail Module
Collapse
  • Filter
  • Time
  • Show
Clear All
new posts

  • Hyperic

    We are expecting the class below to be able to be autodiscovered by Hyperic but it isn't. We can query it in the view tab in hyperic and see its attributes, but it is not autodiscovered in the monitor tab. Any ideas?

    import org.springframework.jmx.export.annotation.ManagedA ttribute;
    import org.springframework.jmx.export.annotation.ManagedM etric;
    import org.springframework.jmx.export.annotation.ManagedO peration;
    import org.springframework.jmx.export.annotation.ManagedO perationParameter;
    import org.springframework.jmx.export.annotation.ManagedR esource;
    import org.springframework.jmx.support.MetricType;
    import org.springframework.stereotype.Component;

    import com.dialect.utility.Application;
    import com.dialect.utility.jmx.JmxBeanRegistrar;

    /**
    * TODO: Javadoc
    */
    @Component
    @ManagedResource(objectName="spring.application:ap plication=swf-booking-mvc,type=MessageListener,name=bookingMessageListen er")
    public final class JmxFooServiceImpl{
    @ManagedMetric(category="UTILIZATION", displayName="HypericSpikeAttribute",
    description="Some time dependent value",
    metricType = MetricType.GAUGE, unit="TB")
    public String getSomeValue() {
    return "" + System.currentTimeMillis() % 99;
    }

    @ManagedMetric(category="UTILIZATION", displayName="HypericSpikeAttribute2",
    description="Some other time dependent value",
    metricType = MetricType.GAUGE, unit="TB")
    public int getSomeOtherValue() {
    return (int) System.currentTimeMillis() % 99;
    }
    private int counter=0;

    @ManagedAttribute(description = "numberOfTimesAccessed")
    public int getAccess(){
    counter++;
    return counter;
    }
    }
Working...
X