Examples of CEPEngineProvider


Examples of org.wso2.carbon.cep.core.backend.CEPEngineProvider

    private static final Log log = LogFactory.getLog(CEPEngineProviderHelper.class);


    public static CEPEngineProvider fromOM(OMElement cepEngineProviderElement)
            throws CEPConfigurationException {
        CEPEngineProvider cepEngineProvider = new CEPEngineProvider();

        String name =
                cepEngineProviderElement.getAttributeValue(
                        new QName(CEPConstants.CEP_CONF_ATTR_NAME));

        if (name == null) {
            String errorMessage = "Provider name is not given in the cep config";
            log.error(errorMessage);
            throw new CEPConfigurationException(errorMessage);
        }
        cepEngineProvider.setName(name);

        String providerClassName =
                cepEngineProviderElement.getAttributeValue(
                        new QName(CEPConstants.CEP_CONF_ATTR_CLASS));
        if (providerClassName == null) {
            String errorMessage = "Provider class is not given in the cep config";
            log.error(errorMessage);
            throw new CEPConfigurationException(errorMessage);
        }

        // here we assume cep provider should have given as a fragment host for this bundle
        // TODO: is it necessary to publish provider as an OSGI service
        try {
            Class providerClass = Class.forName(providerClassName);
            cepEngineProvider.setProviderClass(providerClass);
            return cepEngineProvider;
        } catch (ClassNotFoundException e) {
            String errorMessage = "Can not load the " + providerClassName;
            log.error(errorMessage);
            throw new CEPConfigurationException(errorMessage, e);
View Full Code Here

Examples of org.wso2.carbon.cep.core.backend.CEPEngineProvider

        }
    }

    public void addBucket(Bucket bucket, AxisConfiguration axisConfiguration) throws CEPConfigurationException {

        CEPEngineProvider cepEngineProvider;
        this.axisConfiguration = axisConfiguration;
        if (bucket.getEngineProvider() == null) {
            String errorMessage = "No cep engine provider is given";
            log.error(errorMessage);
            throw new CEPConfigurationException(errorMessage);
View Full Code Here

Examples of org.wso2.carbon.cep.core.backend.CEPEngineProvider

    private static final Log log = LogFactory.getLog(FustionBackEndRuntimeDS.class);

    protected void activate(ComponentContext context) {
        // registers with the cep service
        CEPEngineProvider droolsFusionCEPEngineProvider = new CEPEngineProvider();
        droolsFusionCEPEngineProvider.setName("DroolsFusionCEPRuntime");
        droolsFusionCEPEngineProvider.setProviderClass(FusionBackEndRuntimeFactory.class);

        try {
            FusionBackEndRuntimeValueHolder.getInstance().getCEPService()
                .registerCEPEngineProvider(droolsFusionCEPEngineProvider);
        } catch (CEPConfigurationException e) {
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.