Commit 87402a23 by giaogiao

修改日志级别

parent b64ef6f0
...@@ -207,7 +207,7 @@ public class ShiroConfig { ...@@ -207,7 +207,7 @@ public class ShiroConfig {
Map<String, String> filterChainDefinitionMap = new LinkedHashMap<>(); Map<String, String> filterChainDefinitionMap = new LinkedHashMap<>();
// 获取排除的路径 // 获取排除的路径
List<String[]> anonList = shiroProperties.getAnon(); List<String[]> anonList = shiroProperties.getAnon();
log.debug("anonList:{}", JSON.toJSONString(anonList)); log.info("anonList:{}", JSON.toJSONString(anonList));
if (CollectionUtils.isNotEmpty(anonList)) { if (CollectionUtils.isNotEmpty(anonList)) {
anonList.forEach(anonArray -> { anonList.forEach(anonArray -> {
if (ArrayUtils.isNotEmpty(anonArray)) { if (ArrayUtils.isNotEmpty(anonArray)) {
...@@ -222,7 +222,7 @@ public class ShiroConfig { ...@@ -222,7 +222,7 @@ public class ShiroConfig {
String definitions = shiroProperties.getFilterChainDefinitions(); String definitions = shiroProperties.getFilterChainDefinitions();
if (StringUtils.isNotBlank(definitions)) { if (StringUtils.isNotBlank(definitions)) {
Map<String, String> section = IniUtil.parseIni(definitions); Map<String, String> section = IniUtil.parseIni(definitions);
log.debug("definitions:{}", JSON.toJSONString(section)); log.info("definitions:{}", JSON.toJSONString(section));
for (Map.Entry<String, String> entry : section.entrySet()) { for (Map.Entry<String, String> entry : section.entrySet()) {
filterChainDefinitionMap.put(entry.getKey(), entry.getValue()); filterChainDefinitionMap.put(entry.getKey(), entry.getValue());
} }
...@@ -230,7 +230,7 @@ public class ShiroConfig { ...@@ -230,7 +230,7 @@ public class ShiroConfig {
// 获取自定义权限路径配置集合 // 获取自定义权限路径配置集合
List<ShiroPermissionProperties> permissionConfigs = shiroProperties.getPermission(); List<ShiroPermissionProperties> permissionConfigs = shiroProperties.getPermission();
log.debug("permissionConfigs:{}", JSON.toJSONString(permissionConfigs)); log.info("permissionConfigs:{}", JSON.toJSONString(permissionConfigs));
if (CollectionUtils.isNotEmpty(permissionConfigs)) { if (CollectionUtils.isNotEmpty(permissionConfigs)) {
for (ShiroPermissionProperties permissionConfig : permissionConfigs) { for (ShiroPermissionProperties permissionConfig : permissionConfigs) {
String url = permissionConfig.getUrl(); String url = permissionConfig.getUrl();
...@@ -261,7 +261,7 @@ public class ShiroConfig { ...@@ -261,7 +261,7 @@ public class ShiroConfig {
filterChainDefinitionMap.put("/**", ANON); filterChainDefinitionMap.put("/**", ANON);
} }
log.debug("filterChainMap:{}", JSON.toJSONString(filterChainDefinitionMap)); log.info("filterChainMap:{}", JSON.toJSONString(filterChainDefinitionMap));
// 添加默认的filter // 添加默认的filter
Map<String, String> newFilterChainDefinitionMap = addDefaultFilterDefinition(filterChainDefinitionMap); Map<String, String> newFilterChainDefinitionMap = addDefaultFilterDefinition(filterChainDefinitionMap);
......
...@@ -46,7 +46,7 @@ public class SpringBootPlusCorsConfig { ...@@ -46,7 +46,7 @@ public class SpringBootPlusCorsConfig {
*/ */
@Bean @Bean
public FilterRegistrationBean corsFilter(SpringBootPlusCorsProperties corsProperties) { public FilterRegistrationBean corsFilter(SpringBootPlusCorsProperties corsProperties) {
log.debug("corsProperties:{}", corsProperties); log.info("corsProperties:{}", corsProperties);
UrlBasedCorsConfigurationSource source = new UrlBasedCorsConfigurationSource(); UrlBasedCorsConfigurationSource source = new UrlBasedCorsConfigurationSource();
CorsConfiguration corsConfiguration = new CorsConfiguration(); CorsConfiguration corsConfiguration = new CorsConfiguration();
// 跨域配置 // 跨域配置
......
...@@ -147,7 +147,7 @@ public class SpringBootPlusWebMvcConfig implements WebMvcConfigurer { ...@@ -147,7 +147,7 @@ public class SpringBootPlusWebMvcConfig implements WebMvcConfigurer {
filterConfig = springBootPlusProperties.getFilter(); filterConfig = springBootPlusProperties.getFilter();
interceptorConfig = springBootPlusProperties.getInterceptor(); interceptorConfig = springBootPlusProperties.getInterceptor();
// 打印SpringBootPlusProperties配置信息 // 打印SpringBootPlusProperties配置信息
log.debug("SpringBootPlusProperties:{}", JSON.toJSONString(springBootPlusProperties)); log.info("SpringBootPlusProperties:{}", JSON.toJSONString(springBootPlusProperties));
} }
@Override @Override
......
...@@ -244,7 +244,7 @@ public class Swagger2Config { ...@@ -244,7 +244,7 @@ public class Swagger2Config {
* @return * @return
*/ */
public String[] getBasePackages() { public String[] getBasePackages() {
log.debug("swaggerProperties = " + swaggerProperties); log.info("swaggerProperties = " + swaggerProperties);
String basePackage = swaggerProperties.getBasePackage(); String basePackage = swaggerProperties.getBasePackage();
if (StringUtils.isBlank(basePackage)) { if (StringUtils.isBlank(basePackage)) {
throw new SpringBootPlusConfigException("Swagger basePackage不能为空"); throw new SpringBootPlusConfigException("Swagger basePackage不能为空");
......
...@@ -62,7 +62,7 @@ public class FirebaseTest { ...@@ -62,7 +62,7 @@ public class FirebaseTest {
BufferedReader reader = new BufferedReader(in); BufferedReader reader = new BufferedReader(in);
String line = reader.readLine(); String line = reader.readLine();
log.debug(line); log.info(line);
wr.close(); wr.close();
reader.close(); reader.close();
......
...@@ -31,7 +31,7 @@ ...@@ -31,7 +31,7 @@
// @OperationLog(name = "helloWorld") // @OperationLog(name = "helloWorld")
// @ApiOperation(value = "helloWorld", response = String.class) // @ApiOperation(value = "helloWorld", response = String.class)
// public ApiResult<String> helloWorld() throws IOException { // public ApiResult<String> helloWorld() throws IOException {
// log.debug("Hello World...app"); // log.info("Hello World...app");
// return ApiResult.ok("Hello World app"); // return ApiResult.ok("Hello World app");
// } // }
// //
...@@ -40,7 +40,7 @@ ...@@ -40,7 +40,7 @@
// @OperationLog(name = "needRole") // @OperationLog(name = "needRole")
// @ApiOperation(value = "needRole", response = String.class) // @ApiOperation(value = "needRole", response = String.class)
// public ApiResult<String> needRole() throws IOException { // public ApiResult<String> needRole() throws IOException {
// log.debug("Hello World...app"); // log.info("Hello World...app");
// return ApiResult.ok("Hello World app"); // return ApiResult.ok("Hello World app");
// } // }
// //
...@@ -49,7 +49,7 @@ ...@@ -49,7 +49,7 @@
// @ApiOperation(value = "needRoleAdmin", response = String.class) // @ApiOperation(value = "needRoleAdmin", response = String.class)
// @RequiresRoles("app:admin") // @RequiresRoles("app:admin")
// public ApiResult<String> needRoleAdmin() throws IOException { // public ApiResult<String> needRoleAdmin() throws IOException {
// log.debug("Hello World...app"); // log.info("Hello World...app");
// return ApiResult.ok("Hello World needRoleAdmin"); // return ApiResult.ok("Hello World needRoleAdmin");
// } // }
// //
...@@ -58,7 +58,7 @@ ...@@ -58,7 +58,7 @@
// @ApiOperation(value = "needRoleAll", response = String.class) // @ApiOperation(value = "needRoleAll", response = String.class)
// @RequiresRoles("app:all") // @RequiresRoles("app:all")
// public ApiResult<String> needRoleAll() throws IOException { // public ApiResult<String> needRoleAll() throws IOException {
// log.debug("Hello World...app"); // log.info("Hello World...app");
// return ApiResult.ok("Hello World needRoleAll"); // return ApiResult.ok("Hello World needRoleAll");
// } // }
// //
......
...@@ -46,7 +46,7 @@ public class DownloadInterceptor extends HandlerInterceptorAdapter { ...@@ -46,7 +46,7 @@ public class DownloadInterceptor extends HandlerInterceptorAdapter {
// 访问全路径 // 访问全路径
String fullUrl = request.getRequestURL().toString(); String fullUrl = request.getRequestURL().toString();
// 下载拦截器,业务处理代码 // 下载拦截器,业务处理代码
log.debug("DownloadInterceptor..."); log.info("DownloadInterceptor...");
// 访问token,如果需要,可以设置参数,进行鉴权 // 访问token,如果需要,可以设置参数,进行鉴权
// String token = request.getParameter(JwtTokenUtil.getTokenName()); // String token = request.getParameter(JwtTokenUtil.getTokenName());
return true; return true;
......
...@@ -46,7 +46,7 @@ public class ResourceInterceptor extends HandlerInterceptorAdapter { ...@@ -46,7 +46,7 @@ public class ResourceInterceptor extends HandlerInterceptorAdapter {
// 访问全路径 // 访问全路径
String fullUrl = request.getRequestURL().toString(); String fullUrl = request.getRequestURL().toString();
// 资源拦截器,业务处理代码 // 资源拦截器,业务处理代码
log.debug("ResourceInterceptor..."); log.info("ResourceInterceptor...");
// 访问token,如果需要,可以设置参数,进行鉴权 // 访问token,如果需要,可以设置参数,进行鉴权
// String token = request.getParameter(JwtTokenUtil.getTokenName()); // String token = request.getParameter(JwtTokenUtil.getTokenName());
return true; return true;
......
...@@ -47,7 +47,7 @@ public class UploadInterceptor extends HandlerInterceptorAdapter { ...@@ -47,7 +47,7 @@ public class UploadInterceptor extends HandlerInterceptorAdapter {
// 访问全路径 // 访问全路径
String fullUrl = request.getRequestURL().toString(); String fullUrl = request.getRequestURL().toString();
// 上传拦截器,业务处理代码 // 上传拦截器,业务处理代码
log.debug("UploadInterceptor..."); log.info("UploadInterceptor...");
// 访问token,如果需要,可以设置参数,进行鉴权 // 访问token,如果需要,可以设置参数,进行鉴权
// String token = request.getParameter(JwtTokenUtil.getTokenName()); // String token = request.getParameter(JwtTokenUtil.getTokenName());
return true; return true;
......
...@@ -64,7 +64,7 @@ public class NettyApiRequest { ...@@ -64,7 +64,7 @@ public class NettyApiRequest {
String body = FullHttpRequestUtils.getBody(httpRequest); String body = FullHttpRequestUtils.getBody(httpRequest);
if (log.isDebugEnabled()) { if (log.isDebugEnabled()) {
log.debug("httpRequest:\n" + httpRequest.toString() + "\n" + body); log.info("httpRequest:\n" + httpRequest.toString() + "\n" + body);
} }
if (path.contains(WsConstants.WS_URL)) { if (path.contains(WsConstants.WS_URL)) {
......
...@@ -113,7 +113,7 @@ public class ImConversationServiceImpl extends BaseServiceImpl<ImConversationMap ...@@ -113,7 +113,7 @@ public class ImConversationServiceImpl extends BaseServiceImpl<ImConversationMap
Integer repetitionConversation = getRepetitionConversation(client.getId(), client2.getId()); Integer repetitionConversation = getRepetitionConversation(client.getId(), client2.getId());
if (repetitionConversation != 0) { if (repetitionConversation != 0) {
log.debug("repetitionConversation != 0"); log.info("repetitionConversation != 0");
// 返回已存在的会话id // 返回已存在的会话id
ImConversation repetitionConversationInfo = imConversationMapper.getRepetitionConversationInfo(client.getId(), client2.getId()); ImConversation repetitionConversationInfo = imConversationMapper.getRepetitionConversationInfo(client.getId(), client2.getId());
ImConversationCreateVo imConversationCreateVo = new ImConversationCreateVo(); ImConversationCreateVo imConversationCreateVo = new ImConversationCreateVo();
...@@ -146,7 +146,7 @@ public class ImConversationServiceImpl extends BaseServiceImpl<ImConversationMap ...@@ -146,7 +146,7 @@ public class ImConversationServiceImpl extends BaseServiceImpl<ImConversationMap
} }
if (imConversationCreate.getAttributes().equals(hashMap)) { if (imConversationCreate.getAttributes().equals(hashMap)) {
log.debug(imConversationCreate.getAttributes() + ",出现重复"); log.info(imConversationCreate.getAttributes() + ",出现重复");
ImConversationCreateVo imConversationCreateVo = new ImConversationCreateVo(); ImConversationCreateVo imConversationCreateVo = new ImConversationCreateVo();
imConversationCreateVo.setId(repetitionConversationInfo.getId()); imConversationCreateVo.setId(repetitionConversationInfo.getId());
// 为重复 // 为重复
......
...@@ -68,7 +68,7 @@ public class UserCache { ...@@ -68,7 +68,7 @@ public class UserCache {
// 获取机器内网ip // 获取机器内网ip
static { static {
lAN_IP = getLocalIpAddress(); lAN_IP = getLocalIpAddress();
log.debug("lAN_IP:" + lAN_IP); log.info("lAN_IP:" + lAN_IP);
} }
/** /**
...@@ -124,7 +124,7 @@ public class UserCache { ...@@ -124,7 +124,7 @@ public class UserCache {
} }
} }
} catch (SocketException e) { } catch (SocketException e) {
log.debug("获取本机IP地址失败。" + e); log.info("获取本机IP地址失败。" + e);
} }
...@@ -138,7 +138,7 @@ public class UserCache { ...@@ -138,7 +138,7 @@ public class UserCache {
* @param id * @param id
*/ */
public void online(String id) { public void online(String id) {
log.debug("ws用户上线保存redis连接ip:" + lAN_IP, ",uid:" ); log.info("ws用户上线保存redis连接ip:" + lAN_IP, ",uid:");
// redisUtils.hset(KEY_BASE + id, PRIVATE_IP_KEY, lAN_IP); // redisUtils.hset(KEY_BASE + id, PRIVATE_IP_KEY, lAN_IP);
// redisUtils.hset(KEY_BASE + id, ONLINE_STATUS_KEY, String.valueOf(ONLINE)); // redisUtils.hset(KEY_BASE + id, ONLINE_STATUS_KEY, String.valueOf(ONLINE));
} }
...@@ -149,7 +149,7 @@ public class UserCache { ...@@ -149,7 +149,7 @@ public class UserCache {
* @param id * @param id
*/ */
public void offline(String id) { public void offline(String id) {
log.debug("ws用户离线删除redis key,uid:" + id); log.info("ws用户离线删除redis key,uid:" + id);
// redisUtils.kdel(KEY_BASE + id); // redisUtils.kdel(KEY_BASE + id);
} }
......
...@@ -45,7 +45,7 @@ public class ReadWsData { ...@@ -45,7 +45,7 @@ public class ReadWsData {
String clientId = ctx.channel().attr(MangerChannelService.CLIENT_ID).get(); String clientId = ctx.channel().attr(MangerChannelService.CLIENT_ID).get();
if (PING.equals(data)) { if (PING.equals(data)) {
log.debug("收到心跳:" + clientId); log.info("收到心跳:" + clientId);
return; return;
} }
......
...@@ -46,7 +46,7 @@ public class PushTask { ...@@ -46,7 +46,7 @@ public class PushTask {
*/ */
@Async @Async
public void push(HashMap<String, String> pushMap, ImClient imClientReceiver, ImApplication imApplication) { public void push(HashMap<String, String> pushMap, ImClient imClientReceiver, ImApplication imApplication) {
log.debug("push:" + imClientReceiver.getClientId()); log.info("push:" + imClientReceiver.getClientId());
PushModel pushModel = new PushModel(); PushModel pushModel = new PushModel();
...@@ -61,7 +61,7 @@ public class PushTask { ...@@ -61,7 +61,7 @@ public class PushTask {
// 校验参数 // 校验参数
if (imClientReceiver.getValid() == null || imClientReceiver.getDeviceToken() == null || imClientReceiver.getDeviceType() == null) { if (imClientReceiver.getValid() == null || imClientReceiver.getDeviceToken() == null || imClientReceiver.getDeviceType() == null) {
log.debug("push参数错误"); log.info("push参数错误");
return; return;
} }
// 设备不想收到推送提醒, 1想, 0不想 // 设备不想收到推送提醒, 1想, 0不想
...@@ -81,7 +81,7 @@ public class PushTask { ...@@ -81,7 +81,7 @@ public class PushTask {
private void android(PushModel pushModel, ImClient imClientReceiver, ImApplication imApplication) { private void android(PushModel pushModel, ImClient imClientReceiver, ImApplication imApplication) {
// 安卓推送通道,友盟:1;firebase:2; 信鸽3 // 安卓推送通道,友盟:1;firebase:2; 信鸽3
if (imApplication.getAndroidPushChannel() == 1) { if (imApplication.getAndroidPushChannel() == 1) {
log.debug("友盟"); log.info("友盟");
// 友盟推送 // 友盟推送
PushUtils pushUtils = new PushUtils(imApplication.getUmengKey(), imApplication.getUmengSecret()); PushUtils pushUtils = new PushUtils(imApplication.getUmengKey(), imApplication.getUmengSecret());
...@@ -97,7 +97,7 @@ public class PushTask { ...@@ -97,7 +97,7 @@ public class PushTask {
} else if (imApplication.getAndroidPushChannel() == 2) { } else if (imApplication.getAndroidPushChannel() == 2) {
//firebase:2 //firebase:2
log.debug("firebase"); log.info("firebase");
String jsonStr = null; String jsonStr = null;
try { try {
...@@ -131,7 +131,7 @@ public class PushTask { ...@@ -131,7 +131,7 @@ public class PushTask {
String line = reader.readLine(); String line = reader.readLine();
log.debug(line); log.info(line);
wr.close(); wr.close();
reader.close(); reader.close();
} catch (Exception e) { } catch (Exception e) {
...@@ -140,11 +140,11 @@ public class PushTask { ...@@ -140,11 +140,11 @@ public class PushTask {
} else if (imApplication.getAndroidPushChannel() == 3) { } else if (imApplication.getAndroidPushChannel() == 3) {
// 信鸽3 // 信鸽3
log.debug("信鸽3"); log.info("信鸽3");
} else { } else {
log.debug("没有找到推送类型"); log.info("没有找到推送类型");
return; return;
} }
} }
...@@ -152,7 +152,7 @@ public class PushTask { ...@@ -152,7 +152,7 @@ public class PushTask {
private void ios(PushModel pushModel, ImClient imClientReceiver, ImApplication imApplication) { private void ios(PushModel pushModel, ImClient imClientReceiver, ImApplication imApplication) {
// ios推送通道,友盟:1;firebase:2; apns原生:3 // ios推送通道,友盟:1;firebase:2; apns原生:3
if (imApplication.getIosPushChannel() == 1) { if (imApplication.getIosPushChannel() == 1) {
log.debug("友盟"); log.info("友盟");
// 友盟推送 // 友盟推送
PushUtils pushUtils = new PushUtils(imApplication.getUmengKey(), imApplication.getUmengSecret()); PushUtils pushUtils = new PushUtils(imApplication.getUmengKey(), imApplication.getUmengSecret());
...@@ -170,7 +170,7 @@ public class PushTask { ...@@ -170,7 +170,7 @@ public class PushTask {
} else if (imApplication.getIosPushChannel() == 2) { } else if (imApplication.getIosPushChannel() == 2) {
//firebase:2 //firebase:2
log.debug("firebase"); log.info("firebase");
String jsonStr = null; String jsonStr = null;
...@@ -204,7 +204,7 @@ public class PushTask { ...@@ -204,7 +204,7 @@ public class PushTask {
String line = reader.readLine(); String line = reader.readLine();
log.debug(line); log.info(line);
wr.close(); wr.close();
reader.close(); reader.close();
...@@ -215,10 +215,10 @@ public class PushTask { ...@@ -215,10 +215,10 @@ public class PushTask {
} else if (imApplication.getIosPushChannel() == 3) { } else if (imApplication.getIosPushChannel() == 3) {
// apns原生:3 // apns原生:3
log.debug("apns原生"); log.info("apns原生");
} else { } else {
log.debug("没有找到推送类型"); log.info("没有找到推送类型");
return; return;
} }
} }
......
...@@ -123,13 +123,13 @@ public class MangerChannelServiceImpl implements MangerChannelService { ...@@ -123,13 +123,13 @@ public class MangerChannelServiceImpl implements MangerChannelService {
// NioSocketChannel nioSocketChannel = get(String.valueOf(userId)); // NioSocketChannel nioSocketChannel = get(String.valueOf(userId));
// if (null == nioSocketChannel) { // if (null == nioSocketChannel) {
// userCache.offline(String.valueOf(userId)); // userCache.offline(String.valueOf(userId));
// log.debug("rpc-writeData连接为空:" + userId + "," + msg); // log.info("rpc-writeData连接为空:" + userId + "," + msg);
// return false; // return false;
// } // }
// //
// // 判断连接是否断开 // // 判断连接是否断开
// if (nioSocketChannel.isShutdown()) { // if (nioSocketChannel.isShutdown()) {
// log.debug("rpc-writeData连接断开:" + userId + "," + msg + ",\nchannelId:" + nioSocketChannel.id().asLongText()); // log.info("rpc-writeData连接断开:" + userId + "," + msg + ",\nchannelId:" + nioSocketChannel.id().asLongText());
// return false; // return false;
// } // }
// //
...@@ -168,19 +168,19 @@ public class MangerChannelServiceImpl implements MangerChannelService { ...@@ -168,19 +168,19 @@ public class MangerChannelServiceImpl implements MangerChannelService {
// //
// NioSocketChannel nioSocketChannel = get(String.valueOf(userId)); // NioSocketChannel nioSocketChannel = get(String.valueOf(userId));
// if (null == nioSocketChannel) { // if (null == nioSocketChannel) {
// log.debug("rpc-kickWriteData连接为空:" + userId + "," + msg); // log.info("rpc-kickWriteData连接为空:" + userId + "," + msg);
// return false; // return false;
// } // }
// //
// // 判断连接是否断开 // // 判断连接是否断开
// if (nioSocketChannel.isShutdown()) { // if (nioSocketChannel.isShutdown()) {
// log.debug("rpc-kickWriteData连接断开:" + userId + "," + msg + ",\nchannelId:" + nioSocketChannel.id().asLongText()); // log.info("rpc-kickWriteData连接断开:" + userId + "," + msg + ",\nchannelId:" + nioSocketChannel.id().asLongText());
// nioSocketChannel.close(); // nioSocketChannel.close();
// return false; // return false;
// } // }
// //
// if (log.isDebugEnabled()) { // if (log.isDebugEnabled()) {
// log.debug("rpc-kickWriteData:" + userId + "," + msg + ",\nchannelId:" + nioSocketChannel.id().asLongText()); // log.info("rpc-kickWriteData:" + userId + "," + msg + ",\nchannelId:" + nioSocketChannel.id().asLongText());
// } // }
// //
// ChannelFuture channelFuture = nioSocketChannel.writeAndFlush(new TextWebSocketFrame(msg)); // ChannelFuture channelFuture = nioSocketChannel.writeAndFlush(new TextWebSocketFrame(msg));
...@@ -188,7 +188,7 @@ public class MangerChannelServiceImpl implements MangerChannelService { ...@@ -188,7 +188,7 @@ public class MangerChannelServiceImpl implements MangerChannelService {
// //执行后回调的方法 // //执行后回调的方法
// (ChannelFutureListener) channelFuture1 -> { // (ChannelFutureListener) channelFuture1 -> {
// if (log.isDebugEnabled()) { // if (log.isDebugEnabled()) {
// log.debug("rpc-netty踢人线程异步执行结果:" + channelFuture1.isDone() + ",业务执行结果:" + channelFuture1.isSuccess() // log.info("rpc-netty踢人线程异步执行结果:" + channelFuture1.isDone() + ",业务执行结果:" + channelFuture1.isSuccess()
// + ";\nkickWriteData:" + userId + "," + msg + ",channelId:" + nioSocketChannel.id().asLongText()); // + ";\nkickWriteData:" + userId + "," + msg + ",channelId:" + nioSocketChannel.id().asLongText());
// } // }
// }); // });
...@@ -213,7 +213,7 @@ public class MangerChannelServiceImpl implements MangerChannelService { ...@@ -213,7 +213,7 @@ public class MangerChannelServiceImpl implements MangerChannelService {
// Future<Boolean> future = THREAD_POOL_RPC_WRITE_EXECUTOR.submit(() -> { // Future<Boolean> future = THREAD_POOL_RPC_WRITE_EXECUTOR.submit(() -> {
// NioSocketChannel nioSocketChannel = get(String.valueOf(userId)); // NioSocketChannel nioSocketChannel = get(String.valueOf(userId));
// if (null == nioSocketChannel) { // if (null == nioSocketChannel) {
// log.debug("rpc-closeOldChannel连接为空:" + userId); // log.info("rpc-closeOldChannel连接为空:" + userId);
// return false; // return false;
// } // }
// // 关闭 // // 关闭
...@@ -237,18 +237,18 @@ public class MangerChannelServiceImpl implements MangerChannelService { ...@@ -237,18 +237,18 @@ public class MangerChannelServiceImpl implements MangerChannelService {
// NioSocketChannel nioSocketChannel = get(String.valueOf(userId)); // NioSocketChannel nioSocketChannel = get(String.valueOf(userId));
// if (null == nioSocketChannel) { // if (null == nioSocketChannel) {
// userCache.offline(String.valueOf(userId)); // userCache.offline(String.valueOf(userId));
// log.debug("writeData连接为空:" + userId + "," + msg); // log.info("writeData连接为空:" + userId + "," + msg);
// return false; // return false;
// } // }
// //
// // 判断连接是否断开 // // 判断连接是否断开
// if (nioSocketChannel.isShutdown()) { // if (nioSocketChannel.isShutdown()) {
// log.debug("writeData连接断开:" + userId + "," + msg + ",\nchannelId:" + nioSocketChannel.id().asLongText()); // log.info("writeData连接断开:" + userId + "," + msg + ",\nchannelId:" + nioSocketChannel.id().asLongText());
// return false; // return false;
// } // }
// //
// if (log.isDebugEnabled()) { // if (log.isDebugEnabled()) {
// log.debug("writeData:" + userId + "," + msg + ",\nchannelId:" + nioSocketChannel.id().asLongText()); // log.info("writeData:" + userId + "," + msg + ",\nchannelId:" + nioSocketChannel.id().asLongText());
// } // }
// //
// ChannelFuture channelFuture = nioSocketChannel.writeAndFlush(new TextWebSocketFrame(msg)); // ChannelFuture channelFuture = nioSocketChannel.writeAndFlush(new TextWebSocketFrame(msg));
...@@ -256,7 +256,7 @@ public class MangerChannelServiceImpl implements MangerChannelService { ...@@ -256,7 +256,7 @@ public class MangerChannelServiceImpl implements MangerChannelService {
// //执行后回调的方法 // //执行后回调的方法
// (ChannelFutureListener) channelFuture1 -> { // (ChannelFutureListener) channelFuture1 -> {
// if (log.isDebugEnabled()) { // if (log.isDebugEnabled()) {
// log.debug("netty线程异步执行结果:" + channelFuture1.isDone() + ",业务执行结果:" + channelFuture1.isSuccess() // log.info("netty线程异步执行结果:" + channelFuture1.isDone() + ",业务执行结果:" + channelFuture1.isSuccess()
// + ";\nwriteData:" + userId + "," + msg + ",channelId:" + nioSocketChannel.id().asLongText()); // + ";\nwriteData:" + userId + "," + msg + ",channelId:" + nioSocketChannel.id().asLongText());
// } // }
// }); // });
...@@ -289,14 +289,14 @@ public class MangerChannelServiceImpl implements MangerChannelService { ...@@ -289,14 +289,14 @@ public class MangerChannelServiceImpl implements MangerChannelService {
if (null == nioSocketChannel) { if (null == nioSocketChannel) {
// userCache.offline(toAppKey + toClientId); // userCache.offline(toAppKey + toClientId);
if (log.isDebugEnabled()) { if (log.isDebugEnabled()) {
log.debug("writeData 不存在 连接为空:" + toAppKey + toClientId); log.info("writeData 不存在 连接为空:" + toAppKey + toClientId);
} }
return false; return false;
} }
// 判断连接是否断开 // 判断连接是否断开
if (nioSocketChannel.isShutdown()) { if (nioSocketChannel.isShutdown()) {
if (log.isDebugEnabled()) { if (log.isDebugEnabled()) {
log.debug("writeData连接断开:" + toAppKey + toClientId + "channelId:" + nioSocketChannel.id().asLongText()); log.info("writeData连接断开:" + toAppKey + toClientId + "channelId:" + nioSocketChannel.id().asLongText());
} }
return false; return false;
} }
...@@ -311,20 +311,20 @@ public class MangerChannelServiceImpl implements MangerChannelService { ...@@ -311,20 +311,20 @@ public class MangerChannelServiceImpl implements MangerChannelService {
if (null == nioSocketChannel) { if (null == nioSocketChannel) {
// userCache.offline(toAppKey + toClientId); // userCache.offline(toAppKey + toClientId);
if (log.isDebugEnabled()) { if (log.isDebugEnabled()) {
log.debug("writeData连接为空:" + toAppKey + toClientId + "," + msg); log.info("writeData连接为空:" + toAppKey + toClientId + "," + msg);
} }
return false; return false;
} }
// 判断连接是否断开 // 判断连接是否断开
if (nioSocketChannel.isShutdown()) { if (nioSocketChannel.isShutdown()) {
if (log.isDebugEnabled()) { if (log.isDebugEnabled()) {
log.debug("writeData连接断开:" + toAppKey + toClientId + "," + msg + ",\nchannelId:" + nioSocketChannel.id().asLongText()); log.info("writeData连接断开:" + toAppKey + toClientId + "," + msg + ",\nchannelId:" + nioSocketChannel.id().asLongText());
} }
return false; return false;
} }
if (log.isDebugEnabled()) { if (log.isDebugEnabled()) {
log.debug("writeData:" + toAppKey + "," + toClientId + "," + msg + ",\nchannelId:" + nioSocketChannel.id().asLongText()); log.info("writeData:" + toAppKey + "," + toClientId + "," + msg + ",\nchannelId:" + nioSocketChannel.id().asLongText());
} }
ChannelFuture channelFuture = nioSocketChannel.writeAndFlush(new TextWebSocketFrame(msg)); ChannelFuture channelFuture = nioSocketChannel.writeAndFlush(new TextWebSocketFrame(msg));
...@@ -332,7 +332,7 @@ public class MangerChannelServiceImpl implements MangerChannelService { ...@@ -332,7 +332,7 @@ public class MangerChannelServiceImpl implements MangerChannelService {
//执行后回调的方法 //执行后回调的方法
(ChannelFutureListener) channelFuture1 -> { (ChannelFutureListener) channelFuture1 -> {
if (log.isDebugEnabled()) { if (log.isDebugEnabled()) {
log.debug("netty线程异步执行结果:" + channelFuture1.isDone() + ",业务执行结果:" + channelFuture1.isSuccess() log.info("netty线程异步执行结果:" + channelFuture1.isDone() + ",业务执行结果:" + channelFuture1.isSuccess()
+ ";\nwriteData:" + toAppKey + toClientId + "," + msg + ",channelId:" + nioSocketChannel.id().asLongText()); + ";\nwriteData:" + toAppKey + toClientId + "," + msg + ",channelId:" + nioSocketChannel.id().asLongText());
} }
}); });
......
...@@ -42,7 +42,7 @@ public class SpringBootPlusStaticProperties { ...@@ -42,7 +42,7 @@ public class SpringBootPlusStaticProperties {
@PostConstruct @PostConstruct
public void init() { public void init() {
INFO_PROJECT_VERSION = this.infoProjectVersion; INFO_PROJECT_VERSION = this.infoProjectVersion;
log.debug("INFO_PROJECT_VERSION:" + INFO_PROJECT_VERSION); log.info("INFO_PROJECT_VERSION:" + INFO_PROJECT_VERSION);
} }
} }
...@@ -63,7 +63,7 @@ public class EnumController { ...@@ -63,7 +63,7 @@ public class EnumController {
@GetMapping("/enum") @GetMapping("/enum")
public ApiResult<Map<String, Map<Integer, EnumVo<? extends BaseEnum>>>> enumList() { public ApiResult<Map<String, Map<Integer, EnumVo<? extends BaseEnum>>>> enumList() {
log.debug("enumList..."); log.info("enumList...");
return ApiResult.ok(BaseEnumUtil.getEnumMap()); return ApiResult.ok(BaseEnumUtil.getEnumMap());
} }
...@@ -76,7 +76,7 @@ public class EnumController { ...@@ -76,7 +76,7 @@ public class EnumController {
enumPackages.addAll(FRAMEWORK_ENUM_PACKAGES); enumPackages.addAll(FRAMEWORK_ENUM_PACKAGES);
// 获取BaseEnum接口的所有实现 // 获取BaseEnum接口的所有实现
log.debug("enumPackages:" + enumPackages); log.info("enumPackages:" + enumPackages);
Reflections reflections = new Reflections(enumPackages); Reflections reflections = new Reflections(enumPackages);
Set<Class<? extends BaseEnum>> set = reflections.getSubTypesOf(BaseEnum.class); Set<Class<? extends BaseEnum>> set = reflections.getSubTypesOf(BaseEnum.class);
if (CollectionUtils.isEmpty(set)) { if (CollectionUtils.isEmpty(set)) {
...@@ -98,7 +98,7 @@ public class EnumController { ...@@ -98,7 +98,7 @@ public class EnumController {
// 设置map // 设置map
BaseEnumUtil.getEnumMap().put(clazz.getName(), enumVoMap); BaseEnumUtil.getEnumMap().put(clazz.getName(), enumVoMap);
} }
log.debug("enumMap:{}", BaseEnumUtil.getEnumMap()); log.info("enumMap:{}", BaseEnumUtil.getEnumMap());
} catch (Exception e) { } catch (Exception e) {
log.error("获取BaseEnum枚举map异常", e); log.error("获取BaseEnum枚举map异常", e);
} }
......
...@@ -171,13 +171,13 @@ public abstract class BaseLogAop { ...@@ -171,13 +171,13 @@ public abstract class BaseLogAop {
requestIdType = logAopConfig.getRequestIdType(); requestIdType = logAopConfig.getRequestIdType();
operationLogConfig = springBootPlusAopProperties.getOperationLog(); operationLogConfig = springBootPlusAopProperties.getOperationLog();
loginLogConfig = springBootPlusAopProperties.getLoginLog(); loginLogConfig = springBootPlusAopProperties.getLoginLog();
log.debug("logAopConfig = " + logAopConfig); log.info("logAopConfig = " + logAopConfig);
log.debug("logPrintType = " + logPrintType); log.info("logPrintType = " + logPrintType);
log.debug("enableRequestId = " + enableRequestId); log.info("enableRequestId = " + enableRequestId);
log.debug("requestIdType = " + requestIdType); log.info("requestIdType = " + requestIdType);
log.debug("operationLogConfig = " + operationLogConfig); log.info("operationLogConfig = " + operationLogConfig);
log.debug("loginLogConfig = " + loginLogConfig); log.info("loginLogConfig = " + loginLogConfig);
log.debug("contextPath = " + contextPath); log.info("contextPath = " + contextPath);
} }
/** /**
......
...@@ -114,7 +114,7 @@ public class JwtFilter extends AuthenticatingFilter { ...@@ -114,7 +114,7 @@ public class JwtFilter extends AuthenticatingFilter {
@Override @Override
protected boolean isAccessAllowed(ServletRequest request, ServletResponse response, Object mappedValue) { protected boolean isAccessAllowed(ServletRequest request, ServletResponse response, Object mappedValue) {
String url = WebUtils.toHttp(request).getRequestURI(); String url = WebUtils.toHttp(request).getRequestURI();
log.debug("isAccessAllowed url:{}", url); log.info("isAccessAllowed url:{}", url);
if (this.isLoginRequest(request, response)) { if (this.isLoginRequest(request, response)) {
return true; return true;
} }
...@@ -142,7 +142,7 @@ public class JwtFilter extends AuthenticatingFilter { ...@@ -142,7 +142,7 @@ public class JwtFilter extends AuthenticatingFilter {
@Override @Override
protected boolean onLoginSuccess(AuthenticationToken token, Subject subject, ServletRequest request, ServletResponse response) throws Exception { protected boolean onLoginSuccess(AuthenticationToken token, Subject subject, ServletRequest request, ServletResponse response) throws Exception {
String url = WebUtils.toHttp(request).getRequestURI(); String url = WebUtils.toHttp(request).getRequestURI();
log.debug("鉴权成功,token:{},url:{}", token, url); log.info("鉴权成功,token:{},url:{}", token, url);
// 刷新token // 刷新token
JwtToken jwtToken = (JwtToken) token; JwtToken jwtToken = (JwtToken) token;
HttpServletResponse httpServletResponse = WebUtils.toHttp(response); HttpServletResponse httpServletResponse = WebUtils.toHttp(response);
......
...@@ -59,7 +59,7 @@ public class JwtRealmAppUser extends AuthorizingRealm { ...@@ -59,7 +59,7 @@ public class JwtRealmAppUser extends AuthorizingRealm {
*/ */
@Override @Override
protected AuthorizationInfo doGetAuthorizationInfo(PrincipalCollection principalCollection) { protected AuthorizationInfo doGetAuthorizationInfo(PrincipalCollection principalCollection) {
log.debug("doGetAuthorizationInfo principalCollection..."); log.info("doGetAuthorizationInfo principalCollection...");
// 设置角色/权限信息 // 设置角色/权限信息
JwtToken jwtToken = (JwtToken) principalCollection.getPrimaryPrincipal(); JwtToken jwtToken = (JwtToken) principalCollection.getPrimaryPrincipal();
...@@ -92,7 +92,7 @@ public class JwtRealmAppUser extends AuthorizingRealm { ...@@ -92,7 +92,7 @@ public class JwtRealmAppUser extends AuthorizingRealm {
*/ */
@Override @Override
protected AuthenticationInfo doGetAuthenticationInfo(AuthenticationToken authenticationToken) throws AuthenticationException { protected AuthenticationInfo doGetAuthenticationInfo(AuthenticationToken authenticationToken) throws AuthenticationException {
log.debug("doGetAuthenticationInfo authenticationToken..."); log.info("doGetAuthenticationInfo authenticationToken...");
// 校验token // 校验token
JwtToken jwtToken = (JwtToken) authenticationToken; JwtToken jwtToken = (JwtToken) authenticationToken;
if (jwtToken == null) { if (jwtToken == null) {
......
...@@ -105,7 +105,7 @@ public class ShiroLoginServiceImpl implements ShiroLoginService { ...@@ -105,7 +105,7 @@ public class ShiroLoginServiceImpl implements ShiroLoginService {
// JwtToken newJwtToken = JwtToken.build(newToken, username, jwtToken.getUserId(), salt, expireSecond, jwtToken.getType(), null); // JwtToken newJwtToken = JwtToken.build(newToken, username, jwtToken.getUserId(), salt, expireSecond, jwtToken.getType(), null);
// // 更新redis缓存 // // 更新redis缓存
// sysLoginRedisService.refreshLoginInfo(token, username, newJwtToken); // sysLoginRedisService.refreshLoginInfo(token, username, newJwtToken);
// log.debug("刷新token成功,原token:{},新token:{}", token, newToken); // log.info("刷新token成功,原token:{},新token:{}", token, newToken);
// // 设置响应头 // // 设置响应头
// // 刷新token // // 刷新token
// httpServletResponse.setStatus(CommonConstant.JWT_REFRESH_TOKEN_CODE); // httpServletResponse.setStatus(CommonConstant.JWT_REFRESH_TOKEN_CODE);
......
...@@ -39,7 +39,7 @@ public class JwtTokenUtil { ...@@ -39,7 +39,7 @@ public class JwtTokenUtil {
public JwtTokenUtil(JwtProperties jwtProperties) { public JwtTokenUtil(JwtProperties jwtProperties) {
tokenName = jwtProperties.getTokenName(); tokenName = jwtProperties.getTokenName();
log.debug("tokenName:{}", tokenName); log.info("tokenName:{}", tokenName);
} }
/** /**
......
...@@ -79,13 +79,13 @@ public class JwtUtil { ...@@ -79,13 +79,13 @@ public class JwtUtil {
log.error("username不能为空"); log.error("username不能为空");
return null; return null;
} }
log.debug("clientId:{}", clientId); log.info("clientId:{}", clientId);
// // 如果盐值为空,则使用默认值:666666 // // 如果盐值为空,则使用默认值:666666
// if (StringUtils.isBlank(salt)) { // if (StringUtils.isBlank(salt)) {
// salt = jwtProperties.getSecret(); // salt = jwtProperties.getSecret();
// } // }
log.debug("salt:{}", salt); log.info("salt:{}", salt);
// 过期时间,单位:秒 // 过期时间,单位:秒
Long expireSecond; Long expireSecond;
...@@ -95,9 +95,9 @@ public class JwtUtil { ...@@ -95,9 +95,9 @@ public class JwtUtil {
} else { } else {
expireSecond = expireDuration.getSeconds(); expireSecond = expireDuration.getSeconds();
} }
log.debug("expireSecond:{}", expireSecond); log.info("expireSecond:{}", expireSecond);
Date expireDate = DateUtils.addSeconds(new Date(), expireSecond.intValue()); Date expireDate = DateUtils.addSeconds(new Date(), expireSecond.intValue());
log.debug("expireDate:{}", expireDate); log.info("expireDate:{}", expireDate);
// 生成token // 生成token
Algorithm algorithm = Algorithm.HMAC256(salt); Algorithm algorithm = Algorithm.HMAC256(salt);
......
...@@ -94,13 +94,13 @@ public final class UploadUtil { ...@@ -94,13 +94,13 @@ public final class UploadUtil {
public static void deleteQuietly(String uploadPath, String saveFileName) { public static void deleteQuietly(String uploadPath, String saveFileName) {
File saveDir = new File(uploadPath); File saveDir = new File(uploadPath);
File saveFile = new File(saveDir, saveFileName); File saveFile = new File(saveDir, saveFileName);
log.debug("删除文件:" + saveFile); log.info("删除文件:" + saveFile);
FileUtils.deleteQuietly(saveFile); FileUtils.deleteQuietly(saveFile);
} }
public static interface UploadFileNameHandle { public interface UploadFileNameHandle {
/** /**
* 回调处理接口 * 回调处理接口
* *
......
...@@ -33,7 +33,7 @@ public class HelloScheduled { ...@@ -33,7 +33,7 @@ public class HelloScheduled {
*/ */
@Scheduled(cron = "0 0 0/1 * * ? ") @Scheduled(cron = "0 0 0/1 * * ? ")
public void hello() throws Exception { public void hello() throws Exception {
log.debug("HelloScheduled..."); log.info("HelloScheduled...");
} }
} }
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment