|
@@ -0,0 +1,39 @@
|
|
|
+package cn.com.qmth.examcloud.core.basic.starter.config;
|
|
|
+
|
|
|
+import org.springframework.beans.factory.annotation.Autowired;
|
|
|
+import org.springframework.boot.ApplicationArguments;
|
|
|
+import org.springframework.boot.ApplicationRunner;
|
|
|
+import org.springframework.core.annotation.Order;
|
|
|
+import org.springframework.stereotype.Component;
|
|
|
+
|
|
|
+import cn.com.qmth.examcloud.commons.web.support.RemoteProcedureCallTester;
|
|
|
+
|
|
|
+/**
|
|
|
+ * 应用自检
|
|
|
+ *
|
|
|
+ * @author WANGWEI
|
|
|
+ * @date 2018年6月21日
|
|
|
+ * @Copyright (c) 2018-? http://qmth.com.cn All Rights Reserved.
|
|
|
+ */
|
|
|
+@Component
|
|
|
+@Order(1)
|
|
|
+public class AppSelfInspection implements ApplicationRunner {
|
|
|
+
|
|
|
+ @Autowired
|
|
|
+ RemoteProcedureCallTester remoteCallTester;
|
|
|
+
|
|
|
+ /**
|
|
|
+ * 自检
|
|
|
+ *
|
|
|
+ * @author WANGWEI
|
|
|
+ */
|
|
|
+ private void inspect() {
|
|
|
+ // remoteCallTester.testRestTemplate("XXXXX");
|
|
|
+ }
|
|
|
+
|
|
|
+ @Override
|
|
|
+ public void run(ApplicationArguments args) throws Exception {
|
|
|
+ inspect();
|
|
|
+ }
|
|
|
+
|
|
|
+}
|