-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
3360875
commit 47f9291
Showing
381 changed files
with
223,584 additions
and
0 deletions.
There are no files selected for viewing
Binary file added
BIN
+804 KB
2018/11/11/hadoop-native/2.7.7/Linux-x64/hadoop-2.7.7-native-c7.tar.gz
Binary file not shown.
Binary file added
BIN
+801 KB
2018/11/11/hadoop-native/2.8.5/Linux-x64/hadoop-2.8.5-native-c7.tar.gz
Binary file not shown.
Binary file added
BIN
+804 KB
2018/11/11/hadoop-native/2.9.1/Linux-x64/hadoop-2.9.1-native-c7.tar.gz
Binary file not shown.
Binary file added
BIN
+812 KB
2018/11/11/hadoop-native/3.0.3/Linux-x64/hadoop-3.0.3-native-c7.tar.gz
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file added
BIN
+814 KB
2018/11/11/hadoop-native/3.1.1/Linux-x64/hadoop-3.1.1-native-c7.tar.gz
Binary file not shown.
Binary file not shown.
Binary file not shown.
Large diffs are not rendered by default.
Oops, something went wrong.
Large diffs are not rendered by default.
Oops, something went wrong.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file not shown.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,229 @@ | ||
<!DOCTYPE html> | ||
<html lang=zh> | ||
<head> | ||
<meta charset="UTF-8"> | ||
<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1"> | ||
<meta http-equiv="X-UA-Compatible" content="ie=edge"> | ||
<meta name="keywords" content=""> | ||
|
||
<link rel="icon" href=""> | ||
|
||
|
||
<title>并发编程概述 | 上下未形,何由考之?冥昭瞢暗,誰能極之?馮翼惟象,何以識之?</title> | ||
<meta name="description" content=""> | ||
|
||
<link rel="stylesheet" href="/style.css"> | ||
|
||
|
||
<link rel="stylesheet" href="/lib/jquery.fancybox.min.css"> | ||
|
||
<link href="https://maxcdn.bootstrapcdn.com/font-awesome/4.7.0/css/font-awesome.min.css"> | ||
<meta name="generator" content="Hexo 6.3.0"></head> | ||
|
||
<body> | ||
<header> | ||
<div class="header-container"> | ||
<a class='logo' href="/"> | ||
<span>上下未形,何由考之?冥昭瞢暗,誰能極之?馮翼惟象,何以識之?</span> | ||
</a> | ||
<ul class="right-header"> | ||
|
||
<li class="nav-item"> | ||
|
||
<a href="/" class="item-link">首页</a> | ||
|
||
</li> | ||
|
||
<li class="nav-item"> | ||
|
||
<a href="/about" class="item-link">关于</a> | ||
|
||
</li> | ||
|
||
<li class="nav-item"> | ||
|
||
<a href="/archives" class="item-link">归档</a> | ||
|
||
</li> | ||
|
||
<li class="nav-item"> | ||
|
||
<a href="/tags" class="item-link">标签</a> | ||
|
||
</li> | ||
|
||
</ul> | ||
</div> | ||
</header> | ||
|
||
<main id='post'> | ||
<div class="content"> | ||
<article> | ||
<section class="content markdown-body"> | ||
<h1> | ||
并发编程概述 | ||
</h1> | ||
<div class='post-meta'> | ||
<i class="fa fa-calendar" | ||
aria-hidden="true"></i> <time> | ||
2018/11/17</time> | ||
|
||
| <i class="fa fa-folder-open-o" | ||
aria-hidden="true"></i> | ||
|
||
<div class="article-category"> | ||
<a class="article-category-link" href="/categories/Programming/">Programming</a>/ <a class="article-category-link" href="/categories/Programming/Java/">Java</a> | ||
</div> | ||
|
||
|
||
|
||
|
||
|
||
| | ||
|
||
<i class="fa fa-tags" | ||
aria-hidden="true"></i> | ||
|
||
|
||
<a href="/tags/#Programming" class='tag'>Programming</a> | ||
|
||
<a href="/tags/#Java" class='tag'>Java</a> | ||
|
||
<a href="/tags/#Concurrent" class='tag'>Concurrent</a> | ||
|
||
|
||
|
||
</div> | ||
<h1 id="并发编程"><a href="#并发编程" class="headerlink" title="并发编程"></a>并发编程</h1><p>并发编程领域可以抽象成三个核心问题:分工、协作和互斥。</p> | ||
<p><img src="/2018/11/17/%E5%B9%B6%E5%8F%91%E7%BC%96%E7%A8%8B%E6%A6%82%E8%BF%B0/concurrent-programming.png" alt="并发编程全景图"></p> | ||
<h2 id="分工"><a href="#分工" class="headerlink" title="分工"></a>分工</h2><ul> | ||
<li>ThreadPool/Executor</li> | ||
<li>ForkJoinPool/ForkJoinTask</li> | ||
<li>ScheduledThreadPoolExecutor</li> | ||
<li>Guarded Suspension (wait/notify)</li> | ||
<li>Balking pattern (reject)</li> | ||
<li>Messaging design pattern</li> | ||
</ul> | ||
<h2 id="协作"><a href="#协作" class="headerlink" title="协作"></a>协作</h2><ul> | ||
<li>Semaphore</li> | ||
<li>monitor<ul> | ||
<li>Lock<ul> | ||
<li>ReadWriteLock</li> | ||
</ul> | ||
</li> | ||
<li>Condition</li> | ||
<li>synchronized</li> | ||
</ul> | ||
</li> | ||
<li>CountDownLatch</li> | ||
<li>CyclicBarrier</li> | ||
<li>Phaser</li> | ||
<li>Exchanger</li> | ||
</ul> | ||
<h2 id="互斥"><a href="#互斥" class="headerlink" title="互斥"></a>互斥</h2><h3 id="无锁"><a href="#无锁" class="headerlink" title="无锁"></a>无锁</h3><ul> | ||
<li>local variables</li> | ||
<li>immutable data structures</li> | ||
<li>TLS</li> | ||
<li>Copy-on-Write</li> | ||
<li>CAS</li> | ||
<li>atomic package</li> | ||
</ul> | ||
<h3 id="互斥锁"><a href="#互斥锁" class="headerlink" title="互斥锁"></a>互斥锁</h3><ul> | ||
<li>synchronized</li> | ||
<li>Lock</li> | ||
<li>ReadWriteLock</li> | ||
</ul> | ||
|
||
</section> | ||
</article> | ||
|
||
|
||
</div> | ||
<aside> | ||
|
||
<div class="toc-container"> | ||
<h1> | ||
catalog | ||
</h1> | ||
<div class="content"> | ||
<ol class="toc"><li class="toc-item toc-level-1"><a class="toc-link" href="#%E5%B9%B6%E5%8F%91%E7%BC%96%E7%A8%8B"><span class="toc-number">1.</span> <span class="toc-text">并发编程</span></a><ol class="toc-child"><li class="toc-item toc-level-2"><a class="toc-link" href="#%E5%88%86%E5%B7%A5"><span class="toc-number">1.1.</span> <span class="toc-text">分工</span></a></li><li class="toc-item toc-level-2"><a class="toc-link" href="#%E5%8D%8F%E4%BD%9C"><span class="toc-number">1.2.</span> <span class="toc-text">协作</span></a></li><li class="toc-item toc-level-2"><a class="toc-link" href="#%E4%BA%92%E6%96%A5"><span class="toc-number">1.3.</span> <span class="toc-text">互斥</span></a><ol class="toc-child"><li class="toc-item toc-level-3"><a class="toc-link" href="#%E6%97%A0%E9%94%81"><span class="toc-number">1.3.1.</span> <span class="toc-text">无锁</span></a></li><li class="toc-item toc-level-3"><a class="toc-link" href="#%E4%BA%92%E6%96%A5%E9%94%81"><span class="toc-number">1.3.2.</span> <span class="toc-text">互斥锁</span></a></li></ol></li></ol></li></ol> | ||
</div> | ||
</div> | ||
|
||
</aside> | ||
</main> | ||
|
||
|
||
|
||
<footer> | ||
<div class="copyright"> | ||
<div> | ||
© | ||
2024 | Powered by <a href="https://hexo.io" | ||
target="_blank">Hexo</a>  | ||
</div> | ||
<div> | ||
Theme by <a href="https://github.com/lewis-geek/hexo-theme-Aath" | ||
target="_blank">Aath</a> | ||
</div> | ||
</div> | ||
</footer> | ||
|
||
|
||
<script src="https://cdn.bootcss.com/jquery/3.2.1/jquery.min.js"></script> | ||
|
||
<script src="/lib/ScrollMagic.min.js"></script> | ||
|
||
|
||
<script src="/lib/lodash.min.js"></script> | ||
|
||
<script> | ||
document.body.addEventListener('touchstart', function () { }); | ||
|
||
// 文章图片预览 | ||
$("article img").each(function () { | ||
var strA = "<a data-fancybox='gallery' href='" + this.src + "'></a>"; | ||
$(this).wrapAll(strA); | ||
}); | ||
|
||
// 目录联动 | ||
let tocLinkList = $('.toc-link') | ||
|
||
let controller = new ScrollMagic.Controller({ | ||
globalSceneOptions: { | ||
triggerHook: 0.01 | ||
} | ||
}) | ||
|
||
tocLinkList.each(function (index, elem) { | ||
let href = $(this).attr("href"); | ||
let nextHref = tocLinkList.eq(index + 1).attr("href"); | ||
let height = href && nextHref ? $(nextHref).offset().top - $(href).offset().top : 0 | ||
|
||
new ScrollMagic.Scene({ triggerElement: href }) | ||
.duration(height) | ||
.setClassToggle(".toc [href='" + href + "']", 'active') | ||
.addTo(controller) | ||
}) | ||
|
||
window.addEventListener('load', function () { | ||
// 目录联动 图片加载完成后从新计算 | ||
tocLinkList.each(function (index, elem) { | ||
let href = $(this).attr("href"); | ||
let nextHref = tocLinkList.eq(index + 1).attr("href"); | ||
let height = href && nextHref ? $(nextHref).offset().top - $(href).offset().top : 0 | ||
|
||
new ScrollMagic.Scene({ triggerElement: href }) | ||
.duration(height) | ||
.setClassToggle(".toc [href='" + href + "']", 'active') | ||
.addTo(controller) | ||
}) | ||
}) | ||
</script> | ||
|
||
<script src="/lib/jquery.fancybox.min.js"></script> | ||
|
||
|
||
|
||
</body> | ||
</html> |
Oops, something went wrong.