}
public void run() throws Exception {
logger.log(Level.INFO, "run()");
TransactionManager txn_mgr_proxy = null;
final String serviceName =
"net.jini.core.transaction.server.TransactionManager";
try {
txn_mgr_proxy =
(TransactionManager)manager.startService(serviceName);
if (!manager.killVM(txn_mgr_proxy)) {
logger.log(Level.INFO, "Could not kill " + serviceName);
}
// get delay in seconds
int killDelay = getConfig().getIntConfigVal(
"com.sun.jini.qa.harness.killvm.delay", 15);
if (killDelay < 0) {
killDelay = 15;
}
// Allow service time to auto-restart, which should fail
try {
Thread.sleep(killDelay * 1000);
} catch (InterruptedException ie) {
logger.log(Level.INFO, "Sleep was interrupted");
//ignore
}
} catch (Exception e) {
e.printStackTrace();
throw new TestException("Caught unexpected exception: " + e);
}
try {
/*
* Should recover locators upon startup and try to
* use null recovered locator preparer.
*/
txn_mgr_proxy.create(1000);
throw new TestException("Restarted service with "
+ "invalid configuration");
} catch (Throwable e) {
e.printStackTrace();
if (!verifyConfigurationException(e)) {