use of org.kie.server.client.jms.BlockingResponseCallback in project droolsjbpm-integration by kiegroup.
the class JmsResponseHandlerIntegrationTest method testStartProcessUseOfAsyncResponseHandlerWithMarshaller.
@Test
public void testStartProcessUseOfAsyncResponseHandlerWithMarshaller() throws Exception {
ResponseCallback callback = new BlockingResponseCallback(createMarshaller());
testStartProcessResponseHandler(new AsyncResponseHandler(callback));
// now let's check if response has arrived
Long processInstanceId = callback.get(Long.class);
assertThat(processInstanceId).isNotNull().isPositive();
}
use of org.kie.server.client.jms.BlockingResponseCallback in project droolsjbpm-integration by kiegroup.
the class JmsResponseHandlerIntegrationTest method testGlobalConfigurationOfAsyncResponseHandler.
@Test
public void testGlobalConfigurationOfAsyncResponseHandler() throws Exception {
ResponseCallback callback = new BlockingResponseCallback(createMarshaller());
testStartProcessWithGlobalConfiguration(new AsyncResponseHandler(callback));
Long processInstanceId = callback.get(Long.class);
assertThat(processInstanceId).isNotNull().isPositive();
}
use of org.kie.server.client.jms.BlockingResponseCallback in project droolsjbpm-integration by kiegroup.
the class JmsResponseHandlerIntegrationTest method testGetProcessInstancesUseOfAsyncResponseHandlerWithMarshaller.
@Test
public void testGetProcessInstancesUseOfAsyncResponseHandlerWithMarshaller() throws Exception {
ResponseCallback callback = new BlockingResponseCallback(createMarshaller());
testGetProcessInstancesResponseHandler(new AsyncResponseHandler(callback));
// now let's check if response has arrived
ProcessInstanceList processInstanceList = callback.get(ProcessInstanceList.class);
assertThat(processInstanceList).isNotNull();
assertThat(processInstanceList.getItems()).isNotNull().hasSize(1);
}
use of org.kie.server.client.jms.BlockingResponseCallback in project droolsjbpm-integration by kiegroup.
the class JmsResponseHandlerIntegrationTest method testQueryRegistrationUseOfAsyncResponseHandler.
@Test
public void testQueryRegistrationUseOfAsyncResponseHandler() throws Exception {
ResponseCallback callback = new BlockingResponseCallback(null);
testQueryRegistration(new AsyncResponseHandler(callback));
}
use of org.kie.server.client.jms.BlockingResponseCallback in project droolsjbpm-integration by kiegroup.
the class ContainerJmsResponseHandlerIntegrationTest method setupClients.
@Before
public void setupClients() throws Exception {
asyncClient = createDefaultClient();
Marshaller marshaller = MarshallerFactory.getMarshaller(new HashSet<Class<?>>(extraClasses.values()), configuration.getMarshallingFormat(), asyncClient.getClassLoader());
responseCallback = new BlockingResponseCallback(marshaller);
asyncClient.setResponseHandler(new AsyncResponseHandler(responseCallback));
fireAndForgetClient = createDefaultClient();
fireAndForgetClient.setResponseHandler(new FireAndForgetResponseHandler());
}
Aggregations