上一页 1 2 3 4 5 6 7 8 9 ··· 34 下一页
  2014年3月20日
摘要: 123 阅读全文
posted @ 2014-03-20 18:12 ZimZz 阅读(485) 评论(0) 推荐(0) 编辑
  2014年2月25日
摘要: 用JMap和JStack做堆dump和线程dump命令1. jmap -dump:format=b,file=filename pidjmap -dump:format=b,file=jmap0225.bin 18646jmap -histo pid : 查看当期那 heap 的对象sudo -u ... 阅读全文
posted @ 2014-02-25 23:59 ZimZz 阅读(4738) 评论(0) 推荐(0) 编辑
摘要: mysql> show variables like "%general_log%";+------------------+------------------------------------+| Variable_name | Value |+------------------+------------------------------------+| general_log | ON || general_log_file | /usr/loc... 阅读全文
posted @ 2014-02-25 12:03 ZimZz 阅读(392) 评论(0) 推荐(0) 编辑
  2014年2月24日
摘要: 数据模型ZooKeeper跟分布式文件系统一样, 有一系列的命名空间. 唯一不同的地方是命名空间中的每个节点都有数据和他相关联. 它类似于一个允许文件同时是一个目录的文件系统. 节点的路径永远是以斜杠分隔的标准绝对路径; 没有相对路径. 你可以使用任何unicode字符, 但必须遵循以下限制:路径名不允许使用null字符(\u0000).(这会引起C绑定问题)以下字符不允许使用, 因为他们的显示渲染有问题: \u0001 - \u001F 以及 \u007F - \u009F以下字符不允许使用:\ud800 - uF8FF, \uFFF0 - uFFFF, \uXFFFE - \uXFFFF 阅读全文
posted @ 2014-02-24 21:58 ZimZz 阅读(625) 评论(0) 推荐(0) 编辑
  2014年2月19日
摘要: AsyncHandlerInterceptor提供了一个afterConcurrentHandlingStarted()方法, 这个方法会在Controller方法异步执行时开始执行, 而Interceptor的postHandle方法则是需要等到Controller的异步执行完才能执行例如 @Override public void postHandle(HttpServletRequest request, HttpServletResponse response, Object handler, ModelAndView modelAndView) throws Except... 阅读全文
posted @ 2014-02-19 21:13 ZimZz 阅读(9670) 评论(0) 推荐(0) 编辑
  2014年2月18日
摘要: ZooKepper: 一个分布式应用的分布式协调服务(Distributed Coordination Service)分布式服务难以管理, 他们容易造成死锁和竞争, ZooKepper的动机就是为了让分布式应用的责任从协调服务中解脱出来.设计目的ZooKeeper很简单ZooKeeper通过共享一个类似于标准文件系统的命名空间(namespace)来协调分布式进程. 命名空间包括数据注册器(data registers) - 用ZooKeeper的语法说, 叫做 znode - 他们类似于文件系统中得文件和目录. 和典型文件系统不一样的是, ZooKeeper设计不是用来做存储的, 它把数据 阅读全文
posted @ 2014-02-18 16:57 ZimZz 阅读(718) 评论(2) 推荐(1) 编辑
  2014年2月12日
摘要: 111 阅读全文
posted @ 2014-02-12 21:36 ZimZz 阅读(224) 评论(0) 推荐(0) 编辑
  2014年2月9日
摘要: 今天尝试对一张MySQL表做查询优化, 500W数据但是发现加了索引比不加索引使用全表扫描还慢, 上网查, 据说是因为需要回表, 因为没有用到 using index(覆盖索引), 而回表查询是随机读1. 如果回表查询的数据是在磁盘, 随机读将会非常慢, 导致使用索引以后的查询速度是30s左右2. 如果回表查询的数据实在内存, 则会比全表扫描快我这里全表扫描的时间是3s如果我将查询中所有的字段都加入索引, 则会使用覆盖索引(using index), 此时查询时间缩减为 0.5s但是这样有个很大限制, 就是查询的字段必须全都在索引中, 否则不会使用覆盖索引, 并且, 索引将会变得非常大 阅读全文
posted @ 2014-02-09 23:58 ZimZz 阅读(227) 评论(0) 推荐(0) 编辑
  2014年1月7日
摘要: A locking read, anUPDATE, or aDELETEgenerally set record locks on every index record that is scanned in the processing of the SQL statement. It does not matter whether there areWHEREconditions in the statement that would exclude the row.InnoDBdoes not remember the exactWHEREcondition, but only knows 阅读全文
posted @ 2014-01-07 16:20 ZimZz 阅读(860) 评论(0) 推荐(0) 编辑
  2014年1月3日
摘要: InnoDBhas several types of record-level locks including record locks, gap locks, and next-key locks. For information about shared locks, exclusive locks, and intention locks, seeSection14.3.5.3, “InnoDBLock Modes”.InnoDB有几种行级锁类型, 包括 record 锁, gap 锁, next-key锁.Record lock: This is a lock on an index 阅读全文
posted @ 2014-01-03 12:40 ZimZz 阅读(2138) 评论(1) 推荐(0) 编辑
上一页 1 2 3 4 5 6 7 8 9 ··· 34 下一页