public class R2dbcScriptDatabaseInitializer extends AbstractScriptDatabaseInitializer
InitializingBean
that initializes a database represented by an R2DBC
ConnectionFactory
.Constructor and Description |
---|
R2dbcScriptDatabaseInitializer(io.r2dbc.spi.ConnectionFactory connectionFactory,
DatabaseInitializationSettings settings)
Creates a new
R2dbcScriptDatabaseInitializer that will initialize the
database recognized by the given connectionFactory using the given
settings . |
Modifier and Type | Method and Description |
---|---|
protected boolean |
isEmbeddedDatabase()
Returns whether the database that is to be initialized is embedded.
|
protected void |
runScripts(List<Resource> scripts,
boolean continueOnError,
String separator,
Charset encoding) |
afterPropertiesSet, initializeDatabase, setResourceLoader
public R2dbcScriptDatabaseInitializer(io.r2dbc.spi.ConnectionFactory connectionFactory, DatabaseInitializationSettings settings)
R2dbcScriptDatabaseInitializer
that will initialize the
database recognized by the given connectionFactory
using the given
settings
.connectionFactory
- connectionFactory for the databasesettings
- initialization settingsprotected boolean isEmbeddedDatabase()
AbstractScriptDatabaseInitializer
isEmbeddedDatabase
in class AbstractScriptDatabaseInitializer
true
if the database is embedded, otherwise false
protected void runScripts(List<Resource> scripts, boolean continueOnError, String separator, Charset encoding)
runScripts
in class AbstractScriptDatabaseInitializer