大内存CMS还是会stop the world很长时间,比如超过20GB的内存,因此HBase建议单个JVM别超过15GB的内存。

其实我觉得如果能不stop the world,compaction时间长一点倒无所谓。因为碎片肯定会出现,要避免碎片出现,程序可以自己做一些优化,比如学习HBase。

根据实际经验,内存大了对象多了,stop the world就很长

Phases

Once the GC is triggered, the CMS algorithm consists of a series of phases run in sequence.

Initial Mark - Pauses all application threads and marks all objects directly reachable from root objects as live. This phase stops the world.

Concurrent Mark - Application threads are restarted. All live objects are transitively marked as reachable by following references from the objects marked in the initial mark.

Concurrent Preclean - This phase looks at objects which have been updated or promoted during the concurrent mark or new objects that have been allocated during the concurrent mark. It updates the mark bit to denote whether these objects are live or dead. This phase may be run repeatedly until there is a specified occupancy ratio in Eden.

Remark Since some objects may have been updated during the preclean phase its still necessary to do stop the world in order to process the residual objects. This phase does a retrace from the roots. It also processes reference objects, such as soft and weak references. This phase stops the world.

Concurrent Sweep - This looks through the Ordinary Object Pointer (OOP) Table, which references all objects in the heap, and finds the dead objects. It then re-adds the memory allocated to those objects to its freelist. This is the list of spaces from which an object can be allocated.

Concurrent Reset - Reset all internal data structures in order to be able to run CMS again in future.

【 在 Apache9 的大作中提到: 】

: CMS已经能做到大部分时候不stop the world,但问题是,简单的mark sweep时间长了之后碎片会很严重的,到一定阶段不得不做一次compaction,这个就死慢了。。。

java的有意思的_发现一个有意思的项目banana相关推荐

  1. 发现一个有意思的博主(科研工作者)

    科学网  这个社区好像都是大学老师? 发现一个有意思的博主,王立新的博客: http://blog.sciencenet.cn/u/fuzzywanglixin 博主写的文章有点意思啊,感觉很是犀利. ...

  2. 最近发现一个爬虫开源项目weixin_crawler

    最近发现一个爬虫开源项目weixin_crawler weixin_crawler weixin_crawler是一款使用Scrapy.Flask.Echarts.Elasticsearch等实现的微 ...

  3. 发现一个有意思的奇葩极客网站

    今天无意中上网,发现一个奇葩的有意思的网站:http://www.jikedaohang.com/index.html  从网站来看,网站的主题是Android的开发和应用为中心.但是还是发现了一些以 ...

  4. 学java 开发会掉头_作为一个全新的开发人员,我会学到什么

    学java 开发会掉头 重点 (Top highlight) It's been five years since I learned to code and changed careers. 自从我 ...

  5. 网站加入代码让网页以电脑端打开_发现一个超级好用的视频播放网站-酷播云...

    历时6个小时,研究网站HTML5怎么加入视频,怎么实现电脑版和手机版都能打开正常播放,研究代码,研究第三方跳转,研究来研究去,搞得自己头昏脑涨,现在是23点了,我连万方都没吃,竟被我偶然间发现一个视频 ...

  6. java开发岗位认识_身为一个java开发人员对目前java开发的一些小小的认识

    为什么要学java? 第一要工作,第二想要高薪 首先身为java开发工作人员你的思想认知程度要搞,思想认知程度决定你的专业技能水平 JavaSE工程师     B/S 架构   ----    浏览器 ...

  7. eclipse创建springboot项目_创建一个 Spring Boot 项目,你会几种方法?

    我最早是 2016 年底开始写 Spring Boot 相关的博客,当时使用的版本还是 1.4.x ,文章发表在 CSDN 上,阅读量最大的一篇有 42W+,如下图: 2017 年由于种种原因,就没有 ...

  8. 发现一个有意思的论坛

    快跟着小编一起来逛逛吧 01 进入论坛 方式一 首先进入龙测科技官网: http://www.dragontesting.cn 找到顶部的"社区" 方法二 找到底部"社区 ...

  9. java 最大子数组_求一个数组中子数组的最大和算法(Java实现)

    前几天在微信订阅号"待字闺中"中看到的一篇文章<小技巧求一个数组中子数组的最大和>,提供下Java的实现,并且在对题目做下小修改,本来打算直接在微信里直接回复,但是发现 ...

最新文章

  1. robotframework的学习笔记(十二)------DatabaseLibrary 库
  2. jquery获得option的值和对option进行操作
  3. Attribute class invalid for tag present according to TLD
  4. tensorflow就该这么学--6(多层神经网络)
  5. Spark Streaming 作者,Alluxio 的创始人李浩源:AI 潮流对做数据存储业务公司的挑战...
  6. Antechinus C# Editor!
  7. 对于移动类型Z17和帐户64020100 物料号 (009)的不同的字段选择(公司间调拨)
  8. php_mongo模块,PHP安装mongo模块详细步骤
  9. 管理感悟:复制代码是错误行为
  10. HG255D电信原版刷机实战整理,既HG255D刷uboot、Openwrt
  11. 俄罗斯大神 lopatkin 毛子 最新 Windows 10 Pro 19041.450 20H1 Release x86-x64 ZH-CN DREY
  12. 立体匹配算法(局部立体匹配 、全局立体匹配 、深度学习立体匹配 )
  13. 使用Xftp6上传文件显示状态错误
  14. VS Code 安装 VSIX 插件
  15. 探秘广场舞:中老年市场绝佳切口?
  16. 解决 ZeroDivisionError integer division or modulo by zero
  17. 演示固态硬盘装win11系统教程
  18. 江南爱窗帘十大品牌 | 推荐3种简单的窗帘上色方法
  19. linux下iso文件的制做和解压
  20. OPPO K9和OPPO K7参数对比 选哪个

热门文章

  1. pytrhon画图matplolib
  2. Linux下设置python脚本文件为服务
  3. 关于.net ashx一般处理文件中取不到session问题
  4. 机器学习初探(手写数字识别)HOG图片
  5. 卡片选项页面 JTabbedPane 的使用
  6. Android MVP框架实现过程
  7. 在用到select2时,临时抱佛脚学习了一下
  8. 常见错误Delegate already added to touch dispatcher.的解决方案
  9. 学会查找问题的源头:《全屏游戏中自动切出到桌面的问题解决(二)》
  10. 【报告分享】新世代、新圈层:2020垂直圈层营销报告(附下载链接)