mirror of
https://gitee.com/dromara/Jpom.git
synced 2024-12-02 03:48:05 +08:00
会话错别字
This commit is contained in:
parent
117682af93
commit
417e1a31ae
2
FQA.md
2
FQA.md
@ -8,7 +8,7 @@
|
||||
|
||||
修改管理程序命令文件中 --jpom.log=/jpom/log/
|
||||
|
||||
### 如何修改回话超时时长
|
||||
### 如何修改会话超时时长
|
||||
|
||||
在管理程序命令文件中 ARGS 变量添加 --tomcat.sessionTimeOut=1800
|
||||
|
||||
|
@ -35,7 +35,7 @@ public class FileTailWatcher implements Runnable {
|
||||
private LimitQueue limitQueue = new LimitQueue(10);
|
||||
private final RandomAccessFile randomFile;
|
||||
/**
|
||||
* 所有回话
|
||||
* 所有会话
|
||||
*/
|
||||
private Set<Session> socketSessions = new HashSet<>();
|
||||
private final String log;
|
||||
@ -49,7 +49,7 @@ public class FileTailWatcher implements Runnable {
|
||||
* 添加文件监听
|
||||
*
|
||||
* @param log 日志文件路径
|
||||
* @param session 回话
|
||||
* @param session 会话
|
||||
* @throws IOException 异常
|
||||
*/
|
||||
public static void addWatcher(String log, Session session) throws IOException {
|
||||
@ -76,7 +76,7 @@ public class FileTailWatcher implements Runnable {
|
||||
/**
|
||||
* 有客户端离线
|
||||
*
|
||||
* @param session 回话
|
||||
* @param session 会话
|
||||
*/
|
||||
public static void offline(Session session) {
|
||||
Collection<FileTailWatcher> collection = CONCURRENT_HASH_MAP.values();
|
||||
@ -96,9 +96,9 @@ public class FileTailWatcher implements Runnable {
|
||||
}
|
||||
|
||||
/**
|
||||
* 添加监听回话
|
||||
* 添加监听会话
|
||||
*
|
||||
* @param session 回话
|
||||
* @param session 会话
|
||||
*/
|
||||
private void add(Session session) {
|
||||
if (this.socketSessions.add(session)) {
|
||||
|
@ -37,7 +37,7 @@ public class TopManager {
|
||||
/**
|
||||
* 添加top 命令监听
|
||||
*
|
||||
* @param session 回话
|
||||
* @param session 会话
|
||||
*/
|
||||
public static void addMonitor(Session session) {
|
||||
SESSIONS.add(session);
|
||||
@ -47,7 +47,7 @@ public class TopManager {
|
||||
/**
|
||||
* 移除top 命令监控
|
||||
*
|
||||
* @param session 回话
|
||||
* @param session 会话
|
||||
*/
|
||||
public static void removeMonitor(Session session) {
|
||||
SESSIONS.remove(session);
|
||||
|
@ -7,7 +7,7 @@ import javax.websocket.Session;
|
||||
import java.io.IOException;
|
||||
|
||||
/**
|
||||
* socket 回话对象
|
||||
* socket 会话对象
|
||||
*
|
||||
* @author jiangzeyin
|
||||
* @date 2018/9/29
|
||||
@ -25,7 +25,7 @@ public class SocketSessionUtil {
|
||||
/**
|
||||
* 发送消息
|
||||
*
|
||||
* @param session 回话对象
|
||||
* @param session 会话对象
|
||||
* @param msg 消息
|
||||
* @throws IOException 异常
|
||||
*/
|
||||
|
@ -13,7 +13,7 @@ import java.net.URISyntaxException;
|
||||
import java.util.Objects;
|
||||
|
||||
/**
|
||||
* 代理socket 回话
|
||||
* 代理socket 会话
|
||||
*
|
||||
* @author jiangzeyin
|
||||
* @date 2019/4/16
|
||||
|
@ -80,7 +80,7 @@ public class LoginControl extends BaseServerController {
|
||||
circleCaptcha.write(response.getOutputStream());
|
||||
String code = circleCaptcha.getCode();
|
||||
setSessionAttribute(LOGIN_CODE, code);
|
||||
// 回话显示验证码
|
||||
// 会话显示验证码
|
||||
setSessionAttribute(SHOW_CODE, true);
|
||||
}
|
||||
|
||||
|
@ -43,7 +43,7 @@ public class ServerWebSocketHandle {
|
||||
*
|
||||
* @param userInfo 用户授权信息
|
||||
* @param projectId 项目id
|
||||
* @param session 回话
|
||||
* @param session 会话
|
||||
*/
|
||||
@OnOpen
|
||||
public void onOpen(@PathParam("nodeId") String nodeId, @PathParam("userInfo") String userInfo, @PathParam("projectId") String projectId, Session session) {
|
||||
@ -71,7 +71,7 @@ public class ServerWebSocketHandle {
|
||||
url = StrUtil.format(url, projectId, userName);
|
||||
ProxySession proxySession = new ProxySession(url, session);
|
||||
PROXY_SESSION_CONCURRENT_HASH_MAP.put(session.getId(), proxySession);
|
||||
SocketSessionUtil.send(session, StrUtil.format("欢迎加入:{} 回话id:{} 当前会话总数:{}", userModel.getName(), session.getId(), onlineCount.incrementAndGet()));
|
||||
SocketSessionUtil.send(session, StrUtil.format("欢迎加入:{} 会话id:{} 当前会话总数:{}", userModel.getName(), session.getId(), onlineCount.incrementAndGet()));
|
||||
USER.put(session.getId(), userModel);
|
||||
} catch (Exception e) {
|
||||
DefaultSystemLog.ERROR().error("socket 错误", e);
|
||||
@ -92,7 +92,7 @@ public class ServerWebSocketHandle {
|
||||
public void onMessage(String message, Session session) throws IOException {
|
||||
UserModel userModel = USER.get(session.getId());
|
||||
if (userModel == null) {
|
||||
SocketSessionUtil.send(session, "回话信息失效,刷新网页再试");
|
||||
SocketSessionUtil.send(session, "会话信息失效,刷新网页再试");
|
||||
session.close();
|
||||
return;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user