Package org.asmatron.messengine.engines

Examples of org.asmatron.messengine.engines.DefaultMessagingDelegate.request()


        engine.send(expectedResponse);
      }
    });
    long startTime = System.currentTimeMillis();

    Future<Message<?>> future = engine.request(new TestMessage<String>("requestType", "requestBody"), responseType,
        timeout);
    asyncResponseThread.start();
    Message<?> actualResponse = future.get();

    long totalTime = System.currentTimeMillis() - startTime;
View Full Code Here


    final DefaultMessagingDelegate engine = new DefaultMessagingDelegate();
    engine.start();
    final int timeout = 300;
    long startTime = System.currentTimeMillis();

    Future<Message<?>> future = engine.request(new TestMessage<String>("requestType", "requestBody"), "responseType",
        timeout);
    Message<?> actualResponse = future.get();

    long totalTime = System.currentTimeMillis() - startTime;
    assertTrue(totalTime >= timeout);
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.