Package org.apache.airavata.workflow.tracking.client

Examples of org.apache.airavata.workflow.tracking.client.Subscription


        subscriptionId = subToBrokerWithMsgBoxSink(msgBoxAddr, topic, xpath, wseClient, subscribePermananly);
        messagePuller = msgboxHandler.startPullingEventsFromMsgBox(msgBoxAddr, this, 1500L, 30000l);
        if (logger.isDebugEnabled())
            logger.debug("\n\nCreate Subscription for topic" + topic + " [Messagebox]\n\n");

        Subscription subscription = new Subscription(this, subscriptionId, topic, callback, this.brokerURL);
        subscription.setMessageBoxEpr(msgBoxAddr);
        subscription.setBrokerURL(this.brokerURL);
        return subscription;
    }
View Full Code Here


        subscriptionId = subToBrokerWithMsgBoxSink(msgBoxAddr, topic, xpath, wseClient, subscribePermanatly);
        messagePuller = msgboxHandler.startPullingEventsFromMsgBox(msgBoxAddr, this, 500L, 30000l);
        if (logger.isDebugEnabled())
            logger.debug("\n\nCreate Subscription for topic" + topic + " [Messagebox]\n\n");
        Subscription subscription = new Subscription(this, subscriptionId, topic, callback, this.brokerURL);
        subscription.setMessageBoxEpr(msgBoxAddr);
        subscription.setBrokerURL(this.brokerURL);
        return subscription;

    }
View Full Code Here

    public static void main(String[] args) {

        String brokerLocation = args.length > 0 ? args[0] : "localhost:8080/axis2/services/EventingService";
        String topic = "pickTheTOpicThatWorkflowPublishTheEventsFrom";

        Subscription subscription = null;
        // Create a sbscription
        try {
            // create a callback
            CallbackHandler callback = new CallbackHandler();
            // create the subscription
View Full Code Here

        String brokerLocation = args.length > 0 ? args[0] : "http://localhost:8080/axis2/services/EventingService";
        // "rainier.extreme.indiana.edu:12346";
        String topic = "pickTheTOpicThatWorkflowPublishTheEventsFrom";

        System.out.println(LeadNotificationManager.getBrokerPublishEPR(brokerLocation, topic));
        Subscription subscription = null;
        // Create a sbscription
        try {
            subscription = LeadNotificationManager.createSubscription(brokerLocation, topic,
                    new org.apache.airavata.workflow.tracking.samples.simple_listener.CallbackHandler(), 2222);
        } catch (Exception e) {
            // Falied to create subscription
            System.out.println("Failed to create Subscription");
            e.printStackTrace();
            // do what you want to do instead of rethrowing. e.g. like retrying
            throw new RuntimeException(e);
        }

        System.out.println(subscription.getBrokerPublishEPR());
        subscription.destroy();
        System.out.println("Subscription cleared");
        System.exit(0);
    }
View Full Code Here

            endpointReference = EndpointReferenceHelper.fromString(epr);
        } catch (AxisFault f) {
            throw new MsgBrokerClientException("unable to convert end point reference", f);
        }
        subscriptionId = subscribeToBroker(endpointReference.getAddress(), topic, xpath, wseClient, subscribePermanatly);
        Subscription subscription = new Subscription(this, subscriptionId, topic, callback, this.brokerURL);
        subscription.setMessageBoxEpr(endpointReference);
        return subscription;
    }
View Full Code Here

        this.topic = topic;
        WseMsgBrokerClient wseClient = new WseMsgBrokerClient();
        logger.info("\n\nCreate Subscription for topic" + topic + " [Messagebox]\n\n");

        subscriptionId = subscribeToBroker(endpointReference.getAddress(), topic, xpath, wseClient, subscribePermanatly);
        Subscription subscription = new Subscription(this, subscriptionId, topic, callback, this.brokerURL);
        subscription.setMessageBoxEpr(endpointReference);
        return subscription;
    }
View Full Code Here

            formattedEventSink = String.format(format, msgBoxEventSink, msgBoxId);

        }

        subscriptionId = subscribeToBroker(formattedEventSink, topic, xpath, wseClient, subscribePermanatly);
        Subscription subscription = new Subscription(this, subscriptionId, topic, callback, this.brokerURL);
        subscription.setMessageBoxEpr(msgBoxAddr);
        return subscription;

    }
View Full Code Here

        subscriptionId = subToBrokerWithMsgBoxSink(msgBoxAddr, topic, xpath, wseClient, subscribePermananly);
        messagePuller = msgboxHandler.startPullingEventsFromMsgBox(msgBoxAddr, this, 1500L, 30000l);
        if (logger.isDebugEnabled())
            logger.debug("\n\nCreate Subscription for topic" + topic + " [Messagebox]\n\n");

        Subscription subscription = new Subscription(this, subscriptionId, topic, callback, this.brokerURL);
        subscription.setMessageBoxEpr(msgBoxAddr);
        subscription.setBrokerURL(this.brokerURL);
        return subscription;
    }
View Full Code Here

        subscriptionId = subToBrokerWithMsgBoxSink(msgBoxAddr, topic, xpath, wseClient, subscribePermanatly);
        messagePuller = msgboxHandler.startPullingEventsFromMsgBox(msgBoxAddr, this, 500L, 30000l);
        if (logger.isDebugEnabled())
            logger.info("\n\nCreate Subscription for topic" + topic + " [Messagebox]\n\n");
        Subscription subscription = new Subscription(this, subscriptionId, topic, callback, this.brokerURL);
        subscription.setMessageBoxEpr(msgBoxAddr);
        subscription.setBrokerURL(this.brokerURL);
        return subscription;

    }
View Full Code Here

            formattedEventSink = String.format(format, msgBoxEventSink, msgBoxId);

        }

        subscriptionId = subscribeToBroker(formattedEventSink, topic, xpath, wseClient, subscribePermanatly);
        Subscription subscription = new Subscription(this, subscriptionId, topic, callback, this.brokerURL);
        subscription.setMessageBoxEpr(msgBoxAddr);
        return subscription;

    }
View Full Code Here

TOP

Related Classes of org.apache.airavata.workflow.tracking.client.Subscription

Copyright © 2018 www.massapicom. 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.