Package org.logicblaze.lingo.example

Examples of org.logicblaze.lingo.example.ExampleService


* @version $Revision: 1.2 $
*/
public class JmsMultiplexingRemotingTest extends JmsRemotingTest {

    public void testJmsProxyFactoryBeanAndAsyncServiceExporter() throws Throwable {
        ExampleService target = new ExampleServiceImpl();
        exporter = new JmsServiceExporter();
        exporter.setServiceInterface(ExampleService.class);
        exporter.setService(target);
        exporter.setProducer(createJmsProducer());
        configure(exporter);
        subscribeToQueue(exporter, getDestinationName());

        pfb = new JmsProxyFactoryBean();
        pfb.setServiceInterface(ExampleService.class);
        pfb.setServiceUrl("http://myurl");
        pfb.setRemoteInvocationFactory(new LingoRemoteInvocationFactory(new SimpleMetadataStrategy(true)));
        pfb.setRequestor(createRequestor(getDestinationName()));
        configure(pfb);
       
        ExampleService proxy = (ExampleService) pfb.getObject();

        TestResultListener listener = new TestResultListener();
        proxy.asyncRequestResponse("IBM", listener);

        listener.waitForAsyncResponses(2);

        List results = listener.getResults();
        System.out.println("Found results: " + results);
View Full Code Here

TOP

Related Classes of org.logicblaze.lingo.example.ExampleService

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.