package com.kuyuntech.vrv.corerestful.configuration.core;

import org.springframework.context.annotation.ComponentScan;
import org.springframework.context.annotation.Configuration;
import com.wbspool.fastboot.core.jpa.repository.FastbootRepositoryImpl;
import org.springframework.data.jpa.repository.config.EnableJpaRepositories;
import com.wbspool.fastboot.core.jpa.annotation.FastbootAutoDatasource;
import org.springframework.boot.autoconfigure.condition.ConditionalOnExpression;
import com.wbspool.fastboot.core.dubbo.configuration.FastbootDubboConfiguration;
import org.springframework.context.annotation.Import;


@ConditionalOnExpression("!${fastboot.comp.vrv-core-restful.dubbo.enable:false}")
@Configuration
@EnableJpaRepositories(repositoryBaseClass = FastbootRepositoryImpl.class, basePackages = "com.kuyuntech.vrv.corerestful", transactionManagerRef = "${fastboot.restful.vrv-core-restful.transactionManager:vrvCoreRestfulTransactionManager}", entityManagerFactoryRef = "${fastboot.restful.vrv-core-restful.entityManagerFactory:vrvCoreRestfulEntityManagerFactory}")
@FastbootAutoDatasource(appName = "vrv-core-restful",entityPackages = {"com.kuyuntech.vrv.corerestful"})
@ComponentScan(basePackages = "com.kuyuntech.vrv.corerestful")
public class VrvCoreRestfulConfiguration {

    @ConditionalOnExpression("${fastboot.dubbo.enable:false}")
    @Import(FastbootDubboConfiguration.class)
    static class EnableDubbo{

    }



}
