1. 0.3.0 大版本更新

This commit is contained in:
jianguo 2024-05-31 16:08:18 +08:00
parent 0091075137
commit f6a4717dac
4 changed files with 14 additions and 3 deletions

View File

@ -6,7 +6,7 @@
<groupId>org.aohe</groupId>
<artifactId>sane-service</artifactId>
<version>0.2.6</version>
<version>0.3.0</version>
<name>aohe-sane-service</name>
@ -145,6 +145,8 @@
<generateInstaller>true</generateInstaller>
<administratorRequired>false</administratorRequired>
<platform>linux</platform>
<displayName>奥诃影像扫描控件</displayName>
<description>Sane's socket access programme for use with WEB.</description>
<linuxConfig>
<generateAppImage>true</generateAppImage>
<generateDeb>true</generateDeb>

View File

@ -47,4 +47,6 @@ public class Main {
log.info("socket 服务已关闭 ");
}));
}
}

View File

@ -72,7 +72,13 @@ public class NewWindow extends JFrame {
textField.setForeground(Color.GREEN);
textField.setText("服务状态:启动");
}else{
setView("socket 服务启动失败请检查8997端口是否被占用");
setView("socket 服务启动失败");
setView("请检查8997端口是否被占用,或是否重复打开此程序");
setView("应用退出中...");
new Thread( () -> {
sleep(5000);
System.exit(0);
} ).start();
}
}

View File

@ -3,6 +3,7 @@ package org.aohe.core.web;
import lombok.Getter;
import lombok.extern.slf4j.Slf4j;
import java.net.BindException;
import java.net.UnknownHostException;
/**
@ -40,7 +41,7 @@ public class SocketFactory {
public static boolean start() {
try {
getSocket().start();
} catch (UnknownHostException e) {
} catch (Exception e){
return false;
}
log.info("socket 已启动");