上一页 1 ··· 4 5 6 7 8 9 10 11 12 ··· 17 下一页
摘要: package com.java.enums; public enum UserTypeEnum { /** * UserTypeEnum ROOT_ADMIN => ROOT_ADMIN.getName()... * UserTypeEnum ADMIN => ADMIN.getName()... * UserTypeEnum USER => ... 阅读全文
posted @ 2019-07-31 10:28 scwyfy 阅读(172) 评论(0) 推荐(0) 编辑
摘要: package video.controller;import video.config.WeChatConfig;import video.domain.User;import video.dto.JsonData;import video.utils.HttpUtils;import video 阅读全文
posted @ 2019-07-03 09:24 scwyfy 阅读(325) 评论(0) 推荐(0) 编辑
摘要: package video.exception;import org.springframework.web.bind.annotation.ControllerAdvice;import org.springframework.web.bind.annotation.ExceptionHandle 阅读全文
posted @ 2019-07-02 17:33 scwyfy 阅读(195) 评论(0) 推荐(0) 编辑
摘要: 方案一:采用redis集群 架构: 浏览器 > Nginx > 应用集群 > redis集群 首次登录时,服务器端生成token,存入redis,并将token返回给客户端(浏览器), 然后浏览器每次访问服务器端时都会携带token, 应用服务器携带token会访问redis集群,如果根据token 阅读全文
posted @ 2019-06-21 21:47 scwyfy 阅读(185) 评论(0) 推荐(0) 编辑
摘要: eureka: client: service-url: #defaultZone: http://localhost:8762/eureka/,http://localhost:8763/eureka/ #eureka相互注册(保证高可用) defaultZone: http://localhost:8761/eureka/,http://localhost... 阅读全文
posted @ 2019-02-14 15:32 scwyfy 阅读(116) 评论(0) 推荐(0) 编辑
摘要: package com.demo.read.write.lock; import java.util.HashMap; import java.util.Map; import java.util.concurrent.locks.Lock; import java.util.concurrent.locks.ReadWriteLock; import java.util.concurrent... 阅读全文
posted @ 2018-12-06 19:57 scwyfy 阅读(312) 评论(0) 推荐(0) 编辑
摘要: package com.demo.lock.writer.to.read; import java.util.HashMap; import java.util.Map; import java.util.concurrent.locks.Lock; import java.util.concurrent.locks.ReadWriteLock; import java.util.concur... 阅读全文
posted @ 2018-12-06 19:55 scwyfy 阅读(488) 评论(0) 推荐(0) 编辑
摘要: /**查询全部员工及领导*/ select e.ename,m.ename from emp e join emp m on e.mgr = m.empno; 现象: 上面sql无法查询最高领导(最高领导没有对应的领导) 解决: 采用left join方式 阅读全文
posted @ 2018-10-31 11:29 scwyfy 阅读(193) 评论(0) 推荐(0) 编辑
摘要: 1、index、shard、document理解: a.每个index包含有多个document,index采用数据路由将document存放在shard中, b.算法(数据路由): shard = hash(routing) % num(primary shard) routing的取值决定将数据存放于哪个shard中 routing一... 阅读全文
posted @ 2018-10-29 09:52 scwyfy 阅读(305) 评论(0) 推荐(0) 编辑
摘要: 1、query string search 2、query DSL 3、query filter 4、full-text search 5、phrase search 6、highlight search ----------------------------------------------------------------------------------- took:耗费了几毫秒... 阅读全文
posted @ 2018-10-08 16:00 scwyfy 阅读(2091) 评论(0) 推荐(0) 编辑
上一页 1 ··· 4 5 6 7 8 9 10 11 12 ··· 17 下一页