Package org.mule.api.context.notification

Examples of org.mule.api.context.notification.ServerNotification


    {
        while (!disposed.get())
        {
            try
            {
                ServerNotification notification = (ServerNotification) eventQueue.poll(
                    muleContext.getConfiguration().getDefaultQueueTimeout(),
                    TimeUnit.MILLISECONDS);
                if (notification != null)
                {
                    notifyListeners(notification);
View Full Code Here


    protected void logNotifications()
    {
        logger.info("Number of notifications: " + notifications.getNotifications().size());
        for (Iterator iterator = notifications.getNotifications().iterator(); iterator.hasNext();)
        {
            ServerNotification notification = (ServerNotification) iterator.next();
            logger.info(notification);
        }
    }
View Full Code Here

     */
    protected void assertExpectedNotifications(RestrictedNode spec)
    {
        for (Iterator iterator = notifications.getNotifications().iterator(); iterator.hasNext();)
        {
            ServerNotification notification = (ServerNotification) iterator.next();
                switch (spec.match(notification))
            {
            case Node.SUCCESS:
                break;
            case Node.FAILURE:
View Full Code Here

        while (!disposed.get())
        {
            try
            {
                int timeout = muleContext.getConfiguration().getDefaultQueueTimeout();
                ServerNotification notification = eventQueue.poll(timeout, TimeUnit.MILLISECONDS);
                if (notification != null)
                {
                    notifyListeners(notification);
                }
            }
View Full Code Here

        }

        @Override
        public boolean matches(Object argument)
        {
            ServerNotification notification = (ServerNotification) argument;
            if (exceptionExpected)
            {
                MessagingException exception = null;
                if (notification instanceof PipelineMessageNotification)
                {
                    exception = ((PipelineMessageNotification) notification).getException();
                }
                else if (notification instanceof AsyncMessageNotification)
                {
                    exception = ((AsyncMessageNotification) notification).getException();

                }
                return expectedAction == notification.getAction() && exception != null
                       && notification.getSource() != null
                       && (this.event == null || this.event == notification.getSource());
            }
            else
            {
                return expectedAction == notification.getAction() && notification.getSource() != null
                       && (this.event == null || this.event == notification.getSource());
            }

        }
View Full Code Here

    protected void logNotifications()
    {
        logger.info("Number of notifications: " + notificationLogger.getNotifications().size());
        for (Iterator<?> iterator = notificationLogger.getNotifications().iterator(); iterator.hasNext();)
        {
            ServerNotification notification = (ServerNotification) iterator.next();
            logger.info(notification);
        }
    }
View Full Code Here

     */
    protected void assertExpectedNotifications(RestrictedNode spec)
    {
        for (Iterator<?> iterator = notificationLogger.getNotifications().iterator(); iterator.hasNext();)
        {
            ServerNotification notification = (ServerNotification) iterator.next();
            switch (spec.match(notification))
            {
                case Node.SUCCESS :
                    break;
                case Node.FAILURE :
View Full Code Here

TOP

Related Classes of org.mule.api.context.notification.ServerNotification

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.