上一页 1 2 3 4 5 6 7 8 9 10 ··· 21 下一页
摘要: 原文地址:http://jm-blog.aliapp.com/?p=590 目前绝大多数应用采取的两种分库分表规则 mod方式 dayofweek系列日期方式(所有星期1的数据在一个库/表,或所有?月份的数据在一个库表) 这两种方式有个本质的特点,就是离散性加周期性。 例如以一个表的主键对3取余数的 阅读全文
posted @ 2017-09-22 01:06 liqipeng 阅读(518) 评论(1) 推荐(0) 编辑
摘要: ~ 查看进程树 ptree -p | grep httpd 获取指定名称的进程并杀掉 #!/bin/bash if [ ! -n "$1" ] ;then echo "Please enter a keyword!" exit else NAME=$1 echo "You are looking u 阅读全文
posted @ 2017-09-22 00:59 liqipeng 阅读(277) 评论(0) 推荐(0) 编辑
摘要: 1. "在 Windows 下配置 Redis 集群" 2. "在 Windows 下配置多个 Redis(简化配置)" 3. "MicrosoftArchive/redis" 4. "官方Redis集群搭建文档" 5. "Redis命令" 6. "CentOS完美搭建Redis3.0集群" 7. 阅读全文
posted @ 2017-09-19 13:27 liqipeng 阅读(139) 评论(0) 推荐(0) 编辑
摘要: 1. "wireshark如何抓取本机包" 2. "wireshark抓包详细图文教程" 3. Ubuntu安装wireshark 4. 阅读全文
posted @ 2017-09-14 22:05 liqipeng 阅读(205) 评论(0) 推荐(0) 编辑
摘要: 收集一些常用集合操作的代码,用于治疗健忘症,:) 1. set转list "来源" 2. "java Collection中的排序" a. list排序:Collections.sort或者Arrays.sort b. set排序:先转为list,再排序 c. map排序:构造TreeMap(利用T 阅读全文
posted @ 2017-09-11 13:29 liqipeng 阅读(196) 评论(0) 推荐(0) 编辑
摘要: 使用Junit时,有多种方式来进行异常的断言 1. ExeceptedException & @Rule,可以同时断言异常类型和消息 参考: "JUnit:使用ExpectedException进行异常测试" 2. Test(excepted=XXException.class),只能断言异常类型, 阅读全文
posted @ 2017-09-11 13:20 liqipeng 阅读(1009) 评论(0) 推荐(0) 编辑
摘要: Note : This article is original from "https://gist.github.com/aslakknutsen/9648594" JDK 8 Released Most of us won't be able to use/deploy JDK 8 in pro 阅读全文
posted @ 2017-09-04 23:47 liqipeng 阅读(304) 评论(0) 推荐(0) 编辑
摘要: 对jar包、jdk版本,以及不同jdk版本的jar包的兼容性有一些疑问,搜集一些资料于此 查看jar包的jdk版本 1. 查看.jar包中的META INF\MANIFEST.MF 2. 通过反编译.class文件来查看 然后看 是多少 J2SE 6.0 = 50 (0x32 hex) J2SE 5 阅读全文
posted @ 2017-09-04 23:42 liqipeng 阅读(1685) 评论(0) 推荐(0) 编辑
摘要: 1. 开启驼峰命名 1. 批量insert 1. "Spring, MyBatis 多数据源的配置和管理" 1. 生成entity的toString方法 参考: "http://www.mybatis.org/generator/reference/plugins.html" "http://www 阅读全文
posted @ 2017-09-03 17:19 liqipeng 阅读(160) 评论(0) 推荐(0) 编辑
摘要: 文件上传配置: Controller代码 单元测试代码 遇到问题: Controller代码可以正常上传,而单元测试代码上传只有0字节 原因: 在计算stream的md5时,已经将流的游标移动到了最后,如果不做任何处理直接使用,则无法再从流里读到字节。而Controller里的file.getInp 阅读全文
posted @ 2017-09-03 17:18 liqipeng 阅读(4660) 评论(0) 推荐(1) 编辑
上一页 1 2 3 4 5 6 7 8 9 10 ··· 21 下一页