...
 
Commits (3)
    https://gitcode.net/maxkeytop/MaxKey/-/commit/c488b53f0d8aaece1a9e46b879ef62cff82bb892 Thread HistoryLogin insert 2023-07-19T09:13:17+08:00 MaxKey shimingxy@qq.com https://gitcode.net/maxkeytop/MaxKey/-/commit/ee7a18fa712301b002dc2b7fc5c41c22f6570c6b readme update 2023-07-20T09:36:14+08:00 MaxKey shimingxy@qq.com https://gitcode.net/maxkeytop/MaxKey/-/commit/b1ccb458bd29607aa5af1962e752416e6e85dd22 3.5.19 2023-07-27T19:02:40+08:00 MaxKey shimingxy@qq.com
...@@ -166,6 +166,7 @@ Download the current version from Baidu Pan,<a href="http://www.maxkey.top/zh/ab ...@@ -166,6 +166,7 @@ Download the current version from Baidu Pan,<a href="http://www.maxkey.top/zh/ab
| 上海中商网络股份有限公司 | | 上海中商网络股份有限公司 |
| 上海半天妖餐饮管理有限公司 | | 上海半天妖餐饮管理有限公司 |
| GAP盖璞(上海)商业有限公司 | | GAP盖璞(上海)商业有限公司 |
| 汤臣倍健股份有限公司 |
| 跳羚科技(厦门)有限公司 | | 跳羚科技(厦门)有限公司 |
| 飞天诚信科技股份有限公司 | | 飞天诚信科技股份有限公司 |
| 浪潮工业互联网股份有限公司 | | 浪潮工业互联网股份有限公司 |
......
...@@ -165,6 +165,7 @@ Download the current version from Baidu Pan,<a href="http://www.maxkey.top/zh/ab ...@@ -165,6 +165,7 @@ Download the current version from Baidu Pan,<a href="http://www.maxkey.top/zh/ab
| 上海中商网络股份有限公司 | | 上海中商网络股份有限公司 |
| 上海半天妖餐饮管理有限公司 | | 上海半天妖餐饮管理有限公司 |
| GAP盖璞(上海)商业有限公司 | | GAP盖璞(上海)商业有限公司 |
| 汤臣倍健股份有限公司 |
| 跳羚科技(厦门)有限公司 | | 跳羚科技(厦门)有限公司 |
| 飞天诚信科技股份有限公司 | | 飞天诚信科技股份有限公司 |
| 浪潮工业互联网股份有限公司 | | 浪潮工业互联网股份有限公司 |
......
...@@ -167,6 +167,7 @@ MaxKey注重企业级场景下的性能、安全和易用性,广泛应用于 ...@@ -167,6 +167,7 @@ MaxKey注重企业级场景下的性能、安全和易用性,广泛应用于
| 上海中商网络股份有限公司 | | 上海中商网络股份有限公司 |
| 上海半天妖餐饮管理有限公司 | | 上海半天妖餐饮管理有限公司 |
| GAP盖璞(上海)商业有限公司 | | GAP盖璞(上海)商业有限公司 |
| 汤臣倍健股份有限公司 |
| 跳羚科技(厦门)有限公司 | | 跳羚科技(厦门)有限公司 |
| 飞天诚信科技股份有限公司 | | 飞天诚信科技股份有限公司 |
| 浪潮工业互联网股份有限公司 | | 浪潮工业互联网股份有限公司 |
......
...@@ -15,7 +15,7 @@ ...@@ -15,7 +15,7 @@
# */ # */
#maxkey properties #maxkey properties
group =org.dromara.maxkey group =org.dromara.maxkey
version =3.5.18 version =3.5.19
vendor =https://www.maxkey.top vendor =https://www.maxkey.top
author =MaxKeyTop author =MaxKeyTop
...@@ -27,9 +27,9 @@ jibToAuthPassword =docker registry credential ...@@ -27,9 +27,9 @@ jibToAuthPassword =docker registry credential
#maxkey used jars version #maxkey used jars version
#spring #spring
springVersion =5.3.28 springVersion =5.3.29
springBootVersion =2.7.13 springBootVersion =2.7.14
springSecurityVersion =5.7.9 springSecurityVersion =5.7.10
springDataVersion =2.7.8 springDataVersion =2.7.8
springkafkaVersion =2.9.0 springkafkaVersion =2.9.0
springretryVersion =1.3.3 springretryVersion =1.3.3
...@@ -74,7 +74,7 @@ kafkaclientsVersion =2.8.9 ...@@ -74,7 +74,7 @@ kafkaclientsVersion =2.8.9
rocketmqclientVersion =4.9.4 rocketmqclientVersion =4.9.4
rocketmqspringbootVersion =2.2.2 rocketmqspringbootVersion =2.2.2
#apache tomcat #apache tomcat
tomcatVersion =9.0.76 tomcatVersion =9.0.78
#logs #logs
log4jVersion =2.20.0 log4jVersion =2.20.0
slf4jVersion =1.7.36 slf4jVersion =1.7.36
......
...@@ -25,7 +25,7 @@ import org.slf4j.LoggerFactory; ...@@ -25,7 +25,7 @@ import org.slf4j.LoggerFactory;
import org.springframework.jdbc.core.JdbcTemplate; import org.springframework.jdbc.core.JdbcTemplate;
public class LoginHistoryRepository { public class LoginHistoryRepository {
private static Logger _logger = LoggerFactory.getLogger(LoginHistoryRepository.class); private static Logger logger = LoggerFactory.getLogger(LoginHistoryRepository.class);
private static final String HISTORY_LOGIN_INSERT_STATEMENT = "insert into mxk_history_login (id , sessionid , userid , username , displayname , logintype , message , code , provider , sourceip , ipregion , iplocation, browser , platform , application , loginurl , sessionstatus ,instid)values( ? , ? , ? , ? , ? , ? , ? , ? , ?, ? , ? , ?, ? , ? , ?, ? , ? , ?)"; private static final String HISTORY_LOGIN_INSERT_STATEMENT = "insert into mxk_history_login (id , sessionid , userid , username , displayname , logintype , message , code , provider , sourceip , ipregion , iplocation, browser , platform , application , loginurl , sessionstatus ,instid)values( ? , ? , ? , ? , ? , ? , ? , ? , ?, ? , ? , ?, ? , ? , ?, ? , ? , ?)";
...@@ -38,21 +38,68 @@ public class LoginHistoryRepository { ...@@ -38,21 +38,68 @@ public class LoginHistoryRepository {
public void login(HistoryLogin historyLogin) { public void login(HistoryLogin historyLogin) {
historyLogin.setId(WebContext.genId()); historyLogin.setId(WebContext.genId());
historyLogin.setLoginUrl(WebContext.getRequest().getRequestURI()); historyLogin.setLoginUrl(WebContext.getRequest().getRequestURI());
_logger.debug(" historyLogin " + historyLogin); //Thread insert
jdbcTemplate.update(HISTORY_LOGIN_INSERT_STATEMENT, new Thread(new HistoryLoginRunnable(jdbcTemplate,historyLogin)).start();
new Object[] {
historyLogin.getId(), historyLogin.getSessionId(), historyLogin.getUserId(), historyLogin.getUsername(),
historyLogin.getDisplayName(), historyLogin.getLoginType(), historyLogin.getMessage(), historyLogin.getCode(),
historyLogin.getProvider(), historyLogin.getSourceIp(),historyLogin.getIpRegion(),historyLogin.getIpLocation(),
historyLogin.getBrowser(), historyLogin.getPlatform(),"Browser", historyLogin.getLoginUrl() ,
historyLogin.getSessionStatus(),historyLogin.getInstId()
},
new int[] {
Types.VARCHAR, Types.VARCHAR, Types.VARCHAR, Types.VARCHAR, Types.VARCHAR,
Types.VARCHAR, Types.VARCHAR, Types.VARCHAR, Types.VARCHAR, Types.VARCHAR,
Types.VARCHAR, Types.VARCHAR, Types.VARCHAR, Types.VARCHAR, Types.VARCHAR,
Types.VARCHAR ,Types.INTEGER, Types.VARCHAR
});
} }
public class HistoryLoginRunnable implements Runnable{
JdbcTemplate jdbcTemplate;
HistoryLogin historyLogin;
public HistoryLoginRunnable(JdbcTemplate jdbcTemplate, HistoryLogin historyLogin) {
super();
this.jdbcTemplate = jdbcTemplate;
this.historyLogin = historyLogin;
}
@Override
public void run() {
logger.debug("History Login {}" , historyLogin);
jdbcTemplate.update(HISTORY_LOGIN_INSERT_STATEMENT,
new Object[] {
historyLogin.getId(),
historyLogin.getSessionId(),
historyLogin.getUserId(),
historyLogin.getUsername(),
historyLogin.getDisplayName(),
historyLogin.getLoginType(),
historyLogin.getMessage(),
historyLogin.getCode(),
historyLogin.getProvider(),
historyLogin.getSourceIp(),
historyLogin.getIpRegion(),
historyLogin.getIpLocation(),
historyLogin.getBrowser(),
historyLogin.getPlatform(),
"Browser",
historyLogin.getLoginUrl(),
historyLogin.getSessionStatus(),
historyLogin.getInstId()
},
new int[] {
Types.VARCHAR,
Types.VARCHAR,
Types.VARCHAR,
Types.VARCHAR,
Types.VARCHAR,
Types.VARCHAR,
Types.VARCHAR,
Types.VARCHAR,
Types.VARCHAR,
Types.VARCHAR,
Types.VARCHAR,
Types.VARCHAR,
Types.VARCHAR,
Types.VARCHAR,
Types.VARCHAR,
Types.VARCHAR,
Types.INTEGER,
Types.VARCHAR
});
}
}
} }
#端口号 #端口号
application: application:
name: maxkey-gateway-server name: maxkey-gateway-server
formatted-version: v3.5.18 GA formatted-version: v3.5.19 GA
server: server:
port: 9000 port: 9000
spring: spring:
......
...@@ -16,7 +16,7 @@ ...@@ -16,7 +16,7 @@
#MaxKey Title and Version # #MaxKey Title and Version #
############################################################################ ############################################################################
application.title =MaxKey application.title =MaxKey
application.formatted-version =v3.5.18 GA application.formatted-version =v3.5.19 GA
#for dynamic service discovery #for dynamic service discovery
spring.application.name =maxkey spring.application.name =maxkey
############################################################################ ############################################################################
......
...@@ -16,7 +16,7 @@ ...@@ -16,7 +16,7 @@
#MaxKey Title and Version # #MaxKey Title and Version #
############################################################################ ############################################################################
application.title =MaxKey-Mgt application.title =MaxKey-Mgt
application.formatted-version =v3.5.18 GA application.formatted-version =v3.5.19 GA
#for dynamic service discovery #for dynamic service discovery
spring.application.name =maxkey-mgt spring.application.name =maxkey-mgt
############################################################################ ############################################################################
......
...@@ -16,7 +16,7 @@ ...@@ -16,7 +16,7 @@
#MaxKey Title and Version # #MaxKey Title and Version #
############################################################################ ############################################################################
application.title =MaxKey-OpenApi application.title =MaxKey-OpenApi
application.formatted-version =v3.5.18 GA application.formatted-version =v3.5.19 GA
#for dynamic service discovery #for dynamic service discovery
spring.application.name =maxkey-openapi spring.application.name =maxkey-openapi
############################################################################ ############################################################################
......