public class ApplicationContextAwareSpringJdbcMigrationResolver
extends org.flywaydb.core.internal.resolver.spring.SpringJdbcMigrationResolver
Migration resolver for SpringJdbcMigration
s which are registered in the given ApplicationContext
. This resolver provides the ability to use other beans
registered in the ApplicationContext
and reference them via Spring’s dependency injection facility inside the SpringJdbcMigration
s.
Constructor and Description |
---|
ApplicationContextAwareSpringJdbcMigrationResolver(ClassLoader classLoader,
org.flywaydb.core.internal.util.Location location,
org.springframework.context.ApplicationContext applicationContext)
Creates a new instance.
|
Modifier and Type | Method and Description |
---|---|
Collection<org.flywaydb.core.api.resolver.ResolvedMigration> |
resolveMigrations() |
public ApplicationContextAwareSpringJdbcMigrationResolver(ClassLoader classLoader, org.flywaydb.core.internal.util.Location location, org.springframework.context.ApplicationContext applicationContext)
Creates a new instance.
classLoader
- The ClassLoader for loading migrations on the classpath.location
- The base package on the classpath where to migrations are located.applicationContext
- The Spring application context to load the SpringJdbcMigration
s from.public Collection<org.flywaydb.core.api.resolver.ResolvedMigration> resolveMigrations()
resolveMigrations
in interface org.flywaydb.core.api.resolver.MigrationResolver
resolveMigrations
in class org.flywaydb.core.internal.resolver.spring.SpringJdbcMigrationResolver
Copyright © 2010 - 2019 edorasware ag. All Rights Reserved.