|
@@ -9,8 +9,8 @@ import java.util.concurrent.TimeUnit;
|
9
|
9
|
/**
|
10
|
10
|
* @author xuxueli 2018-10-31 19:05:43
|
11
|
11
|
*/
|
12
|
|
-public class Application {
|
13
|
|
- private static Logger logger = LoggerFactory.getLogger(Application.class);
|
|
12
|
+public class FramelessApplication {
|
|
13
|
+ private static Logger logger = LoggerFactory.getLogger(FramelessApplication.class);
|
14
|
14
|
|
15
|
15
|
public static void main(String[] args) {
|
16
|
16
|
|
|
@@ -18,8 +18,13 @@ public class Application {
|
18
|
18
|
// start
|
19
|
19
|
FrameLessXxlJobConfig.getInstance().initXxlJobExecutor();
|
20
|
20
|
|
|
21
|
+ // Blocks until interrupted
|
21
|
22
|
while (true) {
|
22
|
|
- TimeUnit.HOURS.sleep(1);
|
|
23
|
+ try {
|
|
24
|
+ TimeUnit.HOURS.sleep(1);
|
|
25
|
+ } catch (InterruptedException e) {
|
|
26
|
+ break;
|
|
27
|
+ }
|
23
|
28
|
}
|
24
|
29
|
} catch (Exception e) {
|
25
|
30
|
logger.error(e.getMessage(), e);
|