Skip to content

Commit

Permalink
Launch Flyway operations only when Arc is ready
Browse files Browse the repository at this point in the history
This avoids a race condition with the AppCDS generation process.
  • Loading branch information
geoand committed Jun 7, 2023
1 parent e15e6c1 commit 614f0f4
Showing 1 changed file with 2 additions and 1 deletion.
Expand Up @@ -34,6 +34,7 @@
import io.quarkus.agroal.spi.JdbcDataSourceSchemaReadyBuildItem;
import io.quarkus.agroal.spi.JdbcInitialSQLGeneratorBuildItem;
import io.quarkus.arc.deployment.AdditionalBeanBuildItem;
import io.quarkus.arc.deployment.BeanContainerBuildItem;
import io.quarkus.arc.deployment.SyntheticBeanBuildItem;
import io.quarkus.arc.deployment.SyntheticBeansRuntimeInitBuildItem;
import io.quarkus.arc.processor.DotNames;
Expand Down Expand Up @@ -204,7 +205,7 @@ void createBeans(FlywayRecorder recorder,
}

@BuildStep
@Consume(SyntheticBeansRuntimeInitBuildItem.class)
@Consume(BeanContainerBuildItem.class)
@Record(ExecutionTime.RUNTIME_INIT)
public ServiceStartBuildItem startActions(FlywayRecorder recorder,
FlywayRuntimeConfig config,
Expand Down

0 comments on commit 614f0f4

Please sign in to comment.