more derby shutdown woes resolved

This commit is contained in:
gtully 2015-05-20 09:53:32 +01:00
parent 3fdf9861b2
commit baa10ed33e
2 changed files with 1 additions and 4 deletions

View File

@ -98,10 +98,6 @@ abstract public class DataSourceServiceSupport extends LockableServiceSupport {
final EmbeddedDataSource ds = new EmbeddedDataSource();
ds.setDatabaseName("derbydb");
ds.setCreateDatabase("create");
try {
ds.getConnection().close();
} catch (SQLException ignored) {
}
return ds;
}

View File

@ -26,6 +26,7 @@ public class JDBCNetworkBrokerDetachTest extends NetworkBrokerDetachTest {
JDBCPersistenceAdapter jdbc = new JDBCPersistenceAdapter();
EmbeddedDataSource dataSource = (EmbeddedDataSource) jdbc.getDataSource();
dataSource.setDatabaseName(broker.getBrokerName());
dataSource.getConnection().close(); // ensure derby for brokerName is initialized
broker.setPersistenceAdapter(jdbc);
broker.setUseVirtualTopics(false);
}