All Projects → Wasabi1234 → Java Concurrency Progamming Tutorial

Wasabi1234 / Java Concurrency Progamming Tutorial

Licence: other
BAT华为大厂一线工程师四年磨一剑精心编排 Java 高并发编程案例代码 & 教程 & 面试题集锦。详细文档讲解请阅读本人的知识库仓:https://github.com/Wasabi1234/Java-Interview-Tutorial

Programming Languages

java
68154 projects - #9 most used programming language
java8
65 projects

Projects that are alternatives of or similar to Java Concurrency Progamming Tutorial

practice
Java并发编程与高并发解决方案:http://coding.imooc.com/class/195.html Java开发企业级权限管理系统:http://coding.imooc.com/class/149.html
Stars: ✭ 39 (-93.56%)
Mutual labels:  concurrency, concurrent-programming
traffic
Massively real-time traffic streaming application
Stars: ✭ 25 (-95.87%)
Mutual labels:  concurrency, concurrent-programming
java-multithread
Códigos feitos para o curso de Multithreading com Java, no canal RinaldoDev do YouTube.
Stars: ✭ 24 (-96.04%)
Mutual labels:  concurrency, concurrent-programming
go-left-right
A faster RWLock primitive in Go, 2-3 times faster than RWMutex. A Go implementation of concurrency control algorithm in paper <Left-Right - A Concurrency Control Technique with Wait-Free Population Oblivious Reads>
Stars: ✭ 42 (-93.07%)
Mutual labels:  concurrency, concurrent-programming
Zio
ZIO — A type-safe, composable library for async and concurrent programming in Scala
Stars: ✭ 3,167 (+422.61%)
Mutual labels:  concurrency, concurrent-programming
Actors.jl
Concurrent computing in Julia based on the Actor Model
Stars: ✭ 95 (-84.32%)
Mutual labels:  concurrency, concurrent-programming
TAOMP
《多处理器编程的艺术》一书中的示例代码实现,带有注释与单元测试
Stars: ✭ 39 (-93.56%)
Mutual labels:  concurrency, concurrent-programming
Chymyst Core
Declarative concurrency in Scala - The implementation of the chemical machine
Stars: ✭ 142 (-76.57%)
Mutual labels:  concurrency, concurrent-programming
geeteventbus
An inprocess eventbus for highly concurrent Python applications
Stars: ✭ 17 (-97.19%)
Mutual labels:  concurrency, concurrent-programming
mux-stream
(De)multiplex asynchronous streams
Stars: ✭ 34 (-94.39%)
Mutual labels:  concurrency, concurrent-programming
Concurrent Map
a thread-safe concurrent map for go
Stars: ✭ 2,627 (+333.5%)
Mutual labels:  concurrency, concurrent-programming
Golang Tutorials
Go Tutorials - Let's get our hands really dirty by writing a lot of Golang code
Stars: ✭ 277 (-54.29%)
Mutual labels:  concurrency, concurrent-programming
Sobjectizer
An implementation of Actor, Publish-Subscribe, and CSP models in one rather small C++ framework. With performance, quality, and stability proved by years in the production.
Stars: ✭ 172 (-71.62%)
Mutual labels:  concurrency, concurrent-programming
Linux-Kernel-Driver-Programming
Implementation of PCI drivers, kprobe, sysfs, devfs, sensor driver, miscdevices, synchronization
Stars: ✭ 43 (-92.9%)
Mutual labels:  concurrency, concurrent-programming
Tascalate Concurrent
Implementation of blocking (IO-Bound) cancellable java.util.concurrent.CompletionStage and related extensions to java.util.concurrent.ExecutorService-s
Stars: ✭ 144 (-76.24%)
Mutual labels:  concurrency, concurrent-programming
scalable-concurrent-containers
High performance containers and utilities for concurrent and asynchronous programming
Stars: ✭ 101 (-83.33%)
Mutual labels:  concurrency, concurrent-programming
Mt
tlock, RWMUTEX, Collab, USM, RSem and other C++ templates for Windows to provide read/write mutex locks, various multithreading tools, collaboration, differential updates and more
Stars: ✭ 18 (-97.03%)
Mutual labels:  concurrency, concurrent-programming
Awesome Lockfree
A collection of resources on wait-free and lock-free programming
Stars: ✭ 1,046 (+72.61%)
Mutual labels:  concurrency, concurrent-programming
transit
Massively real-time city transit streaming application
Stars: ✭ 20 (-96.7%)
Mutual labels:  concurrency, concurrent-programming
Java Concurrency
Java并发知识点总结
Stars: ✭ 3,457 (+470.46%)
Mutual labels:  concurrency, concurrent-programming

1 目标

致力于建立全球最完善的 Java 高并发理论体系。让我们的程序更加可靠,跳槽面试更轻松。

2 深入底层原理,实现并发业务

  • 线程N种实现方式

  • 线程启动你真的会么?

  • 线程停止、中断的最佳实践

  • 线程生命周期

  • 趣解Thread和Object类中线程相关方法:wait、notify、join、yield…

  • 线程属性

  • 线程异常处理

  • 线程安全与程序性能的取舍之道

...

3 环境参数

  • Maven 3.6+

  • JDK 8+

  • Tomcat 8.5+

  • MySQL 8.0.16+

  • Redis 6.0+

  • Intellij IDEA 2019.3

4 方案概要

线程安全性

线程安全性,主要从原子性、可见性、有序性三个方面

原子性部分, atomic包下相关类、CAS原理、Unsafe类、synchronized关键字等的使用及注意事项

可见性部分,主要介绍的是volatile关键字的规则和使用,及synchronized关键字的可见性

有序性部分,则重点讲解了happens-before原则

安全发布对象

安全发布对象的一些核心方法,主要通过单例类的多种实现方式,让大家在实现过程中去体会这些方法的具体含义 这也是对线程安全性的巩固,也是把线程安全性涉及的一些关键字和类再一次放到实际场景中使用,加深大家对他们的印象和认识

线程安全策略

线程安全策略,包括定义不可变对象、线程封闭、同步容器、并发容器等,引出并发里的关键知识J.U.C。

同时还额外介绍了开发中常见的一些线程不安全类和写法,并给出他们各自对应的替代方案。这一章涉及的内容在日常开发和面试中都会涉及很多。...

AQS

J.U.C的重要组件,也是面试的重要考点。

AQS模型设计及相关同步组件的原理和使用,都非常实用

具体包括:CountDownLatch、Semaphore、CyclicBarrier、ReentrantLock与锁、Condition等。

这些组件需要大家能熟练明白他们的用途及差异,不但会使用,而且还要明确知道不同方法调用后的不同效果。

J.U.C组件拓展

J.U.C相关组件,主要包括FutureTask、Fork/Join框架、BlockingQueue,其中FutureTask讲解时会对比着Callable、Runnable、Future来讲。

这些组件使用场景相对AQS会少一些,但也是J.U.C的重要组成部分,也是需要掌握的

线程调度-线程池

J.U.C里最后一部分:线程池。面试大概率会问到线程池相关的知识点。

这一章将主要从new Thread弊端、线程池的好处、ThreadPoolExecutor详细介绍(参数、状态、方法)、线程池类图、Executor框架接口等进行讲解,需要大家能了解线程池的许多细节及配置,并能在实际项目中正确使用

多线程并发拓展讲解

对并发编程做些补充,但都贴近当前的面试,主要讲解死锁产生的条件及预防、多线程并发编程的最佳实践、Spring与线程安全、以及面试都特别喜欢问的HashMap和ConcurrentMap源码细节。当然,面试喜欢问的问题,对实际项目开发也是特别重要的

扩容

高并发部分:思路,侧重面试,扩容思路,首先介绍垂直扩容和水平扩容的区别,数据库读操作扩展和写操作扩展思路。

缓存

思路,本章讲解高并发中缓存方案。

包含对缓存特征(命中率、最大元素、清空策略)、影响缓存命中率因素、缓存分类和应用场景(本地缓存、分布式缓存)、高并发场景下缓存常见问题(缓存一致性、缓存并发、缓存穿透、雪崩)等的具体介绍。此外,针对大家常用的缓存组件Guava Cache、Memcache、Redis

消息队列

消息队列的特性(业务无关、FIFO、容灾、性能)、为什么需要消息队列以及消息队列的好处(业务解耦、最终一致性、广播、错峰与流控),对当前比较流行的消息队列组件kafka和rabbitmq做架构分析和特性介绍

应用拆分

从实际项目拆分步骤讲起,让大家可以实际感受到应用拆分的好处和解决的问题,之后引出对应用拆分原则(业务优先、循序渐进、兼顾技术、可靠测试)和应用拆分时思考的内容(应用之间通信、应用之间数据库设计、避免事务跨应用),并引出对服务化Dubbo和微服务Spring Cloud的框架介绍

限流

明确限流的重要作用 限流常用的四种算法:计数法、滑动窗口、漏桶算法和令牌桶算法,并对他们做了简单的对比

服务降级与服务熔断

服务降级的分类:自动降级(超时、失败次数、故障、限流)和人工降级(开关),总结了服务降级和服务熔断的共性(目的、最终表现、粒度、自治)和区别(出发原因、管理目标层次、实现方式)以及服务降级要考虑的问题

数据库分库分表与高可用

高并发部分:主讲思路,从数据库瓶颈开始讲起,引出对数据库切库分库分表的介绍。数据库切库里重点介绍了读写分离的设计,对比支持多数据源和分库的区别;

什么时候该考虑分表、横向分表与纵向分表,以及通过mybatis的分页插件shardbatis2.0实现数据库分表

知识体系

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].