Examples of produce()


Examples of org.apache.karaf.cellar.core.event.EventProducer.produce()

        Group group = groupManager.findGroupByName(groupName);
        EventProducer producer = eventTransportFactory.getEventProducer(groupName, true);
        RemoteFeaturesEvent event = new RemoteFeaturesEvent(feature, version, FeatureEvent.EventType.FeatureUninstalled);
        event.setForce(true);
        event.setSourceGroup(group);
        producer.produce(event);

        updateFeatureStatus(groupName, feature, version, true);
        return null;
    }
View Full Code Here

Examples of org.apache.karaf.cellar.core.event.EventProducer.produce()

        // create an event and produce it
        EventProducer producer = eventTransportFactory.getEventProducer(groupName, true);
        ObrUrlEvent event = new ObrUrlEvent(url, Constants.URL_REMOVE_EVENT_TYPE);
        event.setForce(true);
        event.setSourceGroup(group);
        producer.produce(event);
        // remove URL from the distributed map
        Set<String> urls = clusterManager.getSet(Constants.URLS_DISTRIBUTED_SET_NAME + Configurations.SEPARATOR + groupName);
        urls.remove(url);
        // remove bundles from the distributed map
        Set<ObrBundleInfo> bundles = clusterManager.getSet(Constants.BUNDLES_DISTRIBUTED_SET_NAME + Configurations.SEPARATOR + groupName);
View Full Code Here

Examples of org.apache.karaf.cellar.core.event.EventProducer.produce()

        // create an event and produce it
        EventProducer producer = eventTransportFactory.getEventProducer(groupName, true);
        ObrUrlEvent event = new ObrUrlEvent(url, Constants.URL_ADD_EVENT_TYPE);
        event.setForce(true);
        event.setSourceGroup(group);
        producer.produce(event);
        // push the OBR URL in the distributed set
        Set<String> urls = clusterManager.getSet(Constants.URLS_DISTRIBUTED_SET_NAME + Configurations.SEPARATOR + groupName);
        urls.add(url);
        // push the bundles in the OBR distributed set
        Set<ObrBundleInfo> bundles = clusterManager.getSet(Constants.BUNDLES_DISTRIBUTED_SET_NAME + Configurations.SEPARATOR + groupName);
View Full Code Here

Examples of org.apache.karaf.cellar.core.event.EventProducer.produce()

        int type = 0;
        if (start) type = Constants.BUNDLE_START_EVENT_TYPE;
        ObrBundleEvent event = new ObrBundleEvent(bundleId, type);
        event.setForce(true);
        event.setSourceGroup(group);
        producer.produce(event);
        return null;
    }

}
View Full Code Here

Examples of org.apache.karaf.cellar.core.event.EventProducer.produce()

        // broadcast the event
        EventProducer producer = eventTransportFactory.getEventProducer(groupName, true);
        RemoteBundleEvent event = new RemoteBundleEvent(name, version, null, BundleEvent.UNINSTALLED);
        event.setForce(true);
        event.setSourceGroup(group);
        producer.produce(event);

        return null;
    }

}
View Full Code Here

Examples of org.apache.karaf.cellar.core.event.EventProducer.produce()

                    Object obj = method.invoke(targetService, event.getArguments().toArray());
                    RemoteServiceResult result = new RemoteServiceResult(event.getId());
                    result.setResult(obj);

                    EventProducer producer = eventTransportFactory.getEventProducer(Constants.RESULT_PREFIX + Constants.SEPARATOR + event.getSourceNode().getId() + event.getEndpointId(), false);
                    producer.produce(result);

                } catch (NoSuchMethodException e) {
                    LOGGER.error("CELLAR DOSGI: unable to find remote method for service", e);
                } catch (InvocationTargetException e) {
                    LOGGER.error("CELLAR DOSGI: unable to invoke remote method for service", e);
View Full Code Here

Examples of org.apache.karaf.cellar.core.event.EventProducer.produce()

        // broadcast the event
        EventProducer producer = eventTransportFactory.getEventProducer(groupName, true);
        RemoteBundleEvent event = new RemoteBundleEvent(name, version, location, BundleEvent.INSTALLED);
        event.setForce(true);
        event.setSourceGroup(group);
        producer.produce(event);

        return null;
    }

}
View Full Code Here

Examples of org.apache.karaf.cellar.core.event.EventProducer.produce()

        // broadcast the event
        EventProducer producer = eventTransportFactory.getEventProducer(groupName, true);
        RemoteBundleEvent event = new RemoteBundleEvent(name, version, null, BundleEvent.STOPPED);
        event.setForce(true);
        event.setSourceGroup(group);
        producer.produce(event);

        return null;
    }

}
View Full Code Here

Examples of org.apache.karaf.cellar.core.event.EventProducer.produce()

        // broadcast the event
        EventProducer producer = eventTransportFactory.getEventProducer(groupName, true);
        RemoteBundleEvent event = new RemoteBundleEvent(name, version, null, BundleEvent.STARTED);
        event.setForce(true);
        event.setSourceGroup(group);
        producer.produce(event);

        return null;
    }

}
View Full Code Here

Examples of org.apache.karaf.cellar.core.event.EventProducer.produce()

        // broadcast the event
        EventProducer producer = eventTransportFactory.getEventProducer(groupName, true);
        RemoteBundleEvent event = new RemoteBundleEvent(name, version, location, BundleEvent.INSTALLED);
        event.setForce(true);
        event.setSourceGroup(group);
        producer.produce(event);
    }

    public void uninstall(String groupName, String symbolicName, String version) throws Exception {
        Group group = groupManager.findGroupByName(groupName);
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.