use of org.springframework.jdbc.datasource.embedded.EmbeddedDatabaseBuilder in project nikita-noark5-core by HiOA-ABI.
the class DemoDataSource method dataSource.
// Note: use the following string when accessing the database jdbc:h2:mem:n5DemoDb
@Bean
public DataSource dataSource() {
EmbeddedDatabaseBuilder builder = new EmbeddedDatabaseBuilder();
EmbeddedDatabase db = builder.setType(EmbeddedDatabaseType.H2).setName("n5DemoDb").build();
return db;
}
use of org.springframework.jdbc.datasource.embedded.EmbeddedDatabaseBuilder in project nikita-noark5-core by HiOA-ABI.
the class DevDataSource method dataSource.
// Note: use the following string when checking database jdbc:h2:mem:n5DemoDb
@Bean
public DataSource dataSource() {
EmbeddedDatabaseBuilder builder = new EmbeddedDatabaseBuilder();
EmbeddedDatabase db = builder.setType(EmbeddedDatabaseType.H2).setName("n5DevDb").build();
return db;
}
use of org.springframework.jdbc.datasource.embedded.EmbeddedDatabaseBuilder in project nikita-noark5-core by HiOA-ABI.
the class TestDataSource method dataSource.
// Note: use the following string when checking database jdbc:h2:mem:n5DemoDb
@Bean
public DataSource dataSource() {
EmbeddedDatabaseBuilder builder = new EmbeddedDatabaseBuilder();
EmbeddedDatabase db = builder.setType(EmbeddedDatabaseType.H2).setName("test").build();
return db;
}
use of org.springframework.jdbc.datasource.embedded.EmbeddedDatabaseBuilder in project spring-integration by spring-projects.
the class JdbcMessageHandlerIntegrationTests method setUp.
@BeforeClass
public static void setUp() {
EmbeddedDatabaseBuilder builder = new EmbeddedDatabaseBuilder();
builder.setType(EmbeddedDatabaseType.HSQL).addScript("classpath:org/springframework/integration/jdbc/messageHandlerIntegrationTest.sql");
embeddedDatabase = builder.build();
jdbcTemplate = new JdbcTemplate(embeddedDatabase);
}
use of org.springframework.jdbc.datasource.embedded.EmbeddedDatabaseBuilder in project spring-integration by spring-projects.
the class StoredProcMessageHandlerDerbyIntegrationTests method setUp.
@BeforeClass
public static void setUp() throws SQLException {
EmbeddedDatabaseBuilder builder = new EmbeddedDatabaseBuilder();
builder.setType(EmbeddedDatabaseType.DERBY);
builder.addScript("classpath:derby-stored-procedures.sql");
embeddedDatabase = builder.build();
jdbcTemplate = new JdbcTemplate(embeddedDatabase);
}
Aggregations