[代码优化](v2.5): update

pull/455/head
ZhengJie 2020-06-21 16:17:14 +08:00
parent 157373eb8b
commit fbd09cf4d2
3 changed files with 3 additions and 3 deletions

View File

@ -13,7 +13,6 @@
* See the License for the specific language governing permissions and * See the License for the specific language governing permissions and
* limitations under the License. * limitations under the License.
*/ */
package me.zhengjie.utils; package me.zhengjie.utils;
@ -23,6 +22,7 @@ package me.zhengjie.utils;
* @apiNote: Key * @apiNote: Key
*/ */
public interface CacheKey { public interface CacheKey {
/** /**
* key * key
*/ */
@ -41,7 +41,6 @@ public interface CacheKey {
/** /**
* s * s
*/ */
String DATE_USER = "data::user:"; String DATE_USER = "data::user:";
/** /**
* *

View File

@ -28,6 +28,7 @@ import me.zhengjie.modules.quartz.service.QuartzJobService;
import me.zhengjie.service.EmailService; import me.zhengjie.service.EmailService;
import me.zhengjie.utils.RedisUtils; import me.zhengjie.utils.RedisUtils;
import me.zhengjie.utils.SpringContextHolder; import me.zhengjie.utils.SpringContextHolder;
import me.zhengjie.utils.StringUtils;
import me.zhengjie.utils.ThrowableUtil; import me.zhengjie.utils.ThrowableUtil;
import org.quartz.JobExecutionContext; import org.quartz.JobExecutionContext;
import org.springframework.scheduling.annotation.Async; import org.springframework.scheduling.annotation.Async;

View File

@ -234,7 +234,7 @@ public class RoleServiceImpl implements RoleService {
private void cleanCache(Role resources, List<User> users) { private void cleanCache(Role resources, List<User> users) {
// 清理缓存 // 清理缓存
if (CollectionUtil.isNotEmpty(users)) { if (CollectionUtil.isNotEmpty(users)) {
users.stream().forEach(item -> { users.forEach(item -> {
userCacheClean.cleanUserCache(item.getUsername()); userCacheClean.cleanUserCache(item.getUsername());
}); });
Set<Long> userIds = users.stream().map(User::getId).collect(Collectors.toSet()); Set<Long> userIds = users.stream().map(User::getId).collect(Collectors.toSet());