package com.scpyun.platform.jilinsscgsdp.config;

//import net.javacrumbs.shedlock.core.LockProvider;
//import net.javacrumbs.shedlock.provider.jdbctemplate.JdbcTemplateLockProvider;
//import net.javacrumbs.shedlock.spring.ScheduledLockConfiguration;
//import net.javacrumbs.shedlock.spring.ScheduledLockConfigurationBuilder;
import org.springframework.context.annotation.Bean;
import org.springframework.stereotype.Component;

import javax.sql.DataSource;
import java.time.Duration;

/**
 * @Author liu
 * @Date 2024/6/27 17:51
 * @PackageName:com.scpyun.platform.jilinsscgsdp.config
 * @ClassName: ShedLockConfig
 * @Description: TODO
 * @Version 1.0
 */
@Component
public class ShedLockConfig {
//    @Bean
//    public LockProvider lockProvider(DataSource dataSource) {
//        return new JdbcTemplateLockProvider(dataSource);
//    }
//
//    @Bean
//    public ScheduledLockConfiguration scheduledLockConfiguration(LockProvider lockProvider) {
//        return ScheduledLockConfigurationBuilder.withLockProvider(lockProvider)
//                .withPoolSize(10)
//                .withDefaultLockAtMostFor(Duration.ofMinutes(10))
//                .build();
//    }
}
