Package org.apache.cxf.workqueue

Examples of org.apache.cxf.workqueue.WorkQueueManager


       
        if (executor == null || SynchronousExecutor.isA(executor)) {
            // need true asynchrony
            Bus bus = message.getExchange().get(Bus.class);
            if (bus != null) {
                WorkQueueManager workQueueManager =
                    bus.getExtension(WorkQueueManager.class);
                Executor autoWorkQueue =
                    workQueueManager.getNamedWorkQueue("ws-addressing");
                executor = autoWorkQueue != null
                           ? autoWorkQueue
                           :  workQueueManager.getAutomaticWorkQueue();
            } else {
                executor = OneShotAsyncExecutor.getInstance();
            }
        }
        message.getExchange().put(Executor.class, executor);
View Full Code Here


                };
                HTTPClientPolicy policy = getClient(outMessage);
                try {
                    Executor ex = outMessage.getExchange().get(Executor.class);
                    if (ex == null) {
                        WorkQueueManager mgr = outMessage.getExchange().get(Bus.class)
                            .getExtension(WorkQueueManager.class);
                        AutomaticWorkQueue qu = mgr.getNamedWorkQueue("http-conduit");
                        if (qu == null) {
                            qu = mgr.getAutomaticWorkQueue();
                        }
                        long timeout = 5000;
                        if (policy != null && policy.isSetAsyncExecuteTimeout()) {
                            timeout = policy.getAsyncExecuteTimeout();
                        }
View Full Code Here

       
        if (executor == null || SynchronousExecutor.isA(executor)) {
            // need true asynchrony
            Bus bus = message.getExchange().get(Bus.class);
            if (bus != null) {
                WorkQueueManager workQueueManager =
                    bus.getExtension(WorkQueueManager.class);
                Executor autoWorkQueue =
                    workQueueManager.getNamedWorkQueue("ws-addressing");
                executor = autoWorkQueue != null
                           ? autoWorkQueue
                           :  workQueueManager.getAutomaticWorkQueue();
            } else {
                executor = OneShotAsyncExecutor.getInstance();
            }
        }
        message.getExchange().put(Executor.class, executor);
View Full Code Here

        InstrumentationManagerImpl imi = (InstrumentationManagerImpl)im;
        assertEquals("service:jmx:rmi:///jndi/rmi://localhost:9914/jmxrmi", imi.getJMXServiceURL());
        assertTrue(imi.isEnabled());
        assertNotNull(imi.getMBeanServer());

        WorkQueueManager manager = bus.getExtension(WorkQueueManager.class);
        manager.getAutomaticWorkQueue();
       
        MBeanServer mbs = im.getMBeanServer();       
        ObjectName name = new ObjectName(ManagementConstants.DEFAULT_DOMAIN_NAME
                                         + ":type=WorkQueueMBean,*");
        Set s = mbs.queryNames(name, null);
View Full Code Here

                    while (message != null) {
                        //REVISIT  to get the thread pool                       
                        //Executor executor = jmsDestination.callback.getExecutor();
                        Executor executor = null;
                        if (executor == null) {
                            WorkQueueManager wqm =
                                base.bus.getExtension(WorkQueueManager.class);
                            if (null != wqm) {
                                executor = wqm.getAutomaticWorkQueue();
                            }   
                        }
                        if (executor != null) {
                            try {
                                executor.execute(new JMSExecutor(message));
View Full Code Here

        InstrumentationManagerImpl imi = (InstrumentationManagerImpl)im;
        assertEquals("service:jmx:rmi:///jndi/rmi://localhost:9916/jmxrmi", imi.getJMXServiceURL());
        assertTrue(imi.isEnabled());
        assertNotNull(imi.getMBeanServer());

        WorkQueueManager manager = bus.getExtension(WorkQueueManager.class);
        manager.getAutomaticWorkQueue();
       
        MBeanServer mbs = im.getMBeanServer();       
        ObjectName name = new ObjectName(ManagementConstants.DEFAULT_DOMAIN_NAME
                                         + ":type=WorkQueueMBean,*");
        Set s = mbs.queryNames(name, null);
View Full Code Here

                    while (message != null) {
                        //REVISIT  to get the thread pool                       
                        //Executor executor = jmsDestination.callback.getExecutor();
                        Executor executor = null;
                        if (executor == null) {
                            WorkQueueManager wqm =
                                base.bus.getExtension(WorkQueueManager.class);
                            if (null != wqm) {
                                executor = wqm.getAutomaticWorkQueue();
                            }   
                        }
                        if (executor != null) {
                            try {
                                executor.execute(new JMSExecutor(message));
View Full Code Here

       
        if (executor == null || SynchronousExecutor.isA(executor)) {
            // need true asynchrony
            Bus bus = message.getExchange().get(Bus.class);
            if (bus != null) {
                WorkQueueManager workQueueManager =
                    bus.getExtension(WorkQueueManager.class);
                Executor autoWorkQueue =
                    workQueueManager.getAutomaticWorkQueue();
                executor = autoWorkQueue != null
                           ? autoWorkQueue
                           : OneShotAsyncExecutor.getInstance();
            } else {
                executor = OneShotAsyncExecutor.getInstance();
View Full Code Here

       
        if (executor == null || SynchronousExecutor.isA(executor)) {
            // need true asynchrony
            Bus bus = message.getExchange().get(Bus.class);
            if (bus != null) {
                WorkQueueManager workQueueManager =
                    bus.getExtension(WorkQueueManager.class);
                Executor autoWorkQueue =
                    workQueueManager.getNamedWorkQueue("ws-addressing");
                executor = autoWorkQueue != null
                           ? autoWorkQueue
                           :  workQueueManager.getAutomaticWorkQueue();
            } else {
                executor = OneShotAsyncExecutor.getInstance();
            }
        }
        message.getExchange().put(Executor.class, executor);
View Full Code Here

                };
                HTTPClientPolicy policy = getClient(outMessage);
                try {
                    Executor ex = outMessage.getExchange().get(Executor.class);
                    if (ex == null) {
                        WorkQueueManager mgr = outMessage.getExchange().get(Bus.class)
                            .getExtension(WorkQueueManager.class);
                        AutomaticWorkQueue qu = mgr.getNamedWorkQueue("http-conduit");
                        if (qu == null) {
                            qu = mgr.getAutomaticWorkQueue();
                        }
                        long timeout = 5000;
                        if (policy != null && policy.isSetAsyncExecuteTimeout()) {
                            timeout = policy.getAsyncExecuteTimeout();
                        }
View Full Code Here

TOP

Related Classes of org.apache.cxf.workqueue.WorkQueueManager

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.