//package dev.sonpx.loyalty.agent.config;
//
//import org.flywaydb.core.Flyway;
//import org.springframework.beans.BeansException;
//import org.springframework.beans.factory.config.BeanPostProcessor;
//import org.springframework.context.annotation.Bean;
//import org.springframework.context.annotation.Configuration;
//import org.springframework.lang.NonNull;
//import javax.sql.DataSource;
//
//@Configuration
//public class FlywayConfig {
//
//    @Bean
//    public FlywayMigrationStrategy flywayMigrationStrategy() {
//        return flyway -> {
//            // Ví dụ: Xóa hết schema cũ rồi mới chạy migration (chỉ áp dụng thử nghiệm!)
//            // flyway.clean();
//            flyway.migrate();
//        };
//    }
//}
