use of cbit.vcell.message.server.ServerMessagingDelegate in project vcell by virtualcell.
the class SolverPreprocessor method sendFailureAndExit.
/**
* Starts the application.
* @param args an array of command-line arguments
* @throws VCMessagingException
*/
public static void sendFailureAndExit(HTCSolver htcSolver, SimulationTask simTask, String hostName, SimulationMessage simMessage) throws VCMessagingException {
VCMessagingService service = VCellServiceHelper.getInstance().loadService(VCMessagingService.class);
service.setDelegate(new ServerMessagingDelegate());
VCMessageSession session = service.createProducerSession();
try {
WorkerEventMessage.sendFailed(session, htcSolver, simTask, hostName, simMessage);
sleep(500);
service.close();
sleep(500);
} catch (VCMessagingException e1) {
e1.printStackTrace();
} finally {
System.exit(-1);
}
}
Aggregations