Search in sources :

Example 1 with ServiceDetectorRegistry

use of org.opennms.netmgt.provision.detector.registry.api.ServiceDetectorRegistry in project opennms by OpenNMS.

the class LocationAwareDetectorClientIT method addServicesOnStartup.

@SuppressWarnings("rawtypes")
@Override
protected void addServicesOnStartup(Map<String, KeyValueHolder<Object, Dictionary>> services) {
    services.put(MinionIdentity.class.getName(), new KeyValueHolder<Object, Dictionary>(new MinionIdentity() {

        @Override
        public String getId() {
            return "0";
        }

        @Override
        public String getLocation() {
            return REMOTE_LOCATION_NAME;
        }
    }, new Properties()));
    Properties props = new Properties();
    props.setProperty("alias", "opennms.broker");
    services.put(Component.class.getName(), new KeyValueHolder<Object, Dictionary>(queuingservice, props));
    services.put(ServiceDetectorRegistry.class.getName(), new KeyValueHolder<Object, Dictionary>(serviceDetectorRegistry, new Properties()));
}
Also used : Dictionary(java.util.Dictionary) ServiceDetectorRegistry(org.opennms.netmgt.provision.detector.registry.api.ServiceDetectorRegistry) MinionIdentity(org.opennms.minion.core.api.MinionIdentity) Properties(java.util.Properties) Component(org.apache.camel.Component)

Aggregations

Dictionary (java.util.Dictionary)1 Properties (java.util.Properties)1 Component (org.apache.camel.Component)1 MinionIdentity (org.opennms.minion.core.api.MinionIdentity)1 ServiceDetectorRegistry (org.opennms.netmgt.provision.detector.registry.api.ServiceDetectorRegistry)1