71 lines
2.2 KiB
Java
71 lines
2.2 KiB
Java
/**/
|
|
|
|
package net.shapelight;
|
|
|
|
//import net.shapelight.modules.dev.mqtt.MqttClientUtil;
|
|
import cn.hutool.json.JSONObject;
|
|
import lombok.extern.slf4j.Slf4j;
|
|
//import org.bytedeco.javacpp.Loader;
|
|
//import org.bytedeco.opencv.global.opencv_imgproc;
|
|
//import org.bytedeco.opencv.opencv_core.CvPoint;
|
|
//import org.bytedeco.opencv.opencv_imgproc.CvFont;
|
|
import net.shapelight.common.config.CxFeignConfig;
|
|
import net.shapelight.modules.feignClient.CxFeignClient;
|
|
import org.springframework.beans.factory.annotation.Autowired;
|
|
import org.springframework.boot.SpringApplication;
|
|
import org.springframework.boot.autoconfigure.SpringBootApplication;
|
|
import org.springframework.boot.web.servlet.ServletComponentScan;
|
|
import org.springframework.cache.annotation.EnableCaching;
|
|
import org.springframework.cloud.openfeign.EnableFeignClients;
|
|
import org.springframework.context.annotation.Bean;
|
|
import org.springframework.transaction.annotation.EnableTransactionManagement;
|
|
|
|
import javax.annotation.PostConstruct;
|
|
|
|
@Slf4j
|
|
//@ImportResource(value = { "classpath:spring/spring.xml" })
|
|
@SpringBootApplication//(exclude = DataSourceAutoConfiguration.class)//排除DataSourceConfiguratrion
|
|
@EnableCaching
|
|
@EnableTransactionManagement
|
|
@ServletComponentScan
|
|
@EnableFeignClients
|
|
//@MapperScan("net.shapelight.modules.sys.dao")
|
|
public class AdminApplication {
|
|
@Autowired
|
|
CxFeignClient cxFeignClient;
|
|
|
|
public static void main(String[] args) {
|
|
SpringApplication.run(AdminApplication.class, args);
|
|
|
|
// Loader.load(opencv_imgproc.class);
|
|
// Loader.load(CvPoint.class);
|
|
// Loader.load(CvFont.class);
|
|
|
|
//初始化掌静脉sdk
|
|
// int initCode = PalmSDK.init();
|
|
// log.debug("掌静脉sdk初始化。。。。。。。。。。:"+initCode);
|
|
//// //mqtt服务启动
|
|
//// MqttClientUtil.createClient();
|
|
////
|
|
// Runtime.getRuntime().addShutdownHook(new Thread() {
|
|
// @Override
|
|
// public void run() {
|
|
// try {
|
|
// int code = PalmSDK.release();
|
|
// log.debug("掌静脉sdk释放。。。。。。。。。。:"+code);
|
|
// } catch (Throwable e) {
|
|
// e.printStackTrace();
|
|
// }
|
|
// }
|
|
// });
|
|
}
|
|
|
|
/* @Bean
|
|
@PostConstruct
|
|
void init(){
|
|
String res = cxFeignClient.getToken("5bb50ad0cc40e10565089c35aa61e7f3","k9?8bCqaQ*R1e2Wx0f65AzY4^]LDp@_Z");
|
|
CxFeignConfig.token = res;
|
|
}*/
|
|
|
|
}
|