Posts Tagged ‘ RingBuffer

如何使用Disruptor(二)如何从Ringbuffer读取

作者:Trisha  译者:古圣昌  校对:方腾飞

上一篇文章中我们都了解了什么是Ring Buffer以及它是如何的特别。但遗憾的是,我还没有讲述如何使用DisruptorRing Buffer写数据和从Ring Buffer中读取数据。

Read more

并发框架Disruptor译文

Martin Fowler在自己网站上写了一篇LMAX架构的文章,在文章中他介绍了LMAX是一种新型零售金融交易平台,它能够以很低的延迟产生大量交易。这个系统是建立在JVM平台上,其核心是一个业务逻辑处理器,它能够在一个线程里每秒处理6百万订单。业务逻辑处理器完全是运行在内存中,使用事件源驱动方式。业务逻辑处理器的核心是Disruptor。

Disruptor它是一个开源的并发框架,并获得2011 Duke’s 程序框架创新奖,能够在无锁的情况下实现网络的Queue并发操作。本文是Disruptor官网中发布的文章的译文(现在被移到了GitHub)。

剖析Disruptor:为什么会这么快

  1. 剖析Disruptor:为什么会这么快?(一)锁的缺点
  2. 剖析Disruptor:为什么会这么快?(二)神奇的缓存行填充
  3. 剖析Disruptor:为什么会这么快?(三)伪共享
  4. 剖析Disruptor:为什么会这么快?(四)揭秘内存屏障

Disruptor如何工作和使用

  1. 如何使用Disruptor(一)Ringbuffer的特别之处
  2. 如何使用Disruptor(二)如何从Ringbuffer读取
  3. 如何使用Disruptor(三)写入Ringbuffer
  4. 解析Disruptor关系组装
  5. Disruptor(无锁并发框架)-发布
  6. LMAX Disruptor——一个高性能、低延迟且简单的框架
  7. Disruptor Wizard已死,Disruptor Wizard永存!
  8. Disruptor 2.0更新摘要
  9. 线程间共享数据不需要竞争

Disruptor的应用

  1. LMAX的架构
  2. 通过Axon和Disruptor处理1M tps

如何使用 Disruptor(三)写入 Ringbuffer

原文地址:http://ifeve.com/dissecting-the-disruptor-writing-to-the-ring-buffer/

作者:Trisha   译者:廖涵  校对:方腾飞

这是 Disruptor 全方位解析(end-to-end view)中缺少的一章。当心,本文非常长。但是为了让你能联系上下文阅读,我还是决定把它们写进一篇博客里。

本文的 重点 是:不要让 Ring 重叠;如何通知消费者;生产者一端的批处理;以及多个生产者如何协同工作。 Read more

剖析Disruptor:为什么会这么快?(一)Ringbuffer的特别之处

原文地址:http://ifeve.com/ringbuffer/

作者:Trisha    译者寒桐  校对:方腾飞

最近,我们开源了LMAX Disruptor,它是我们的交易系统吞吐量快(LMAX是一个新型的交易平台,号称能够单线程每秒处理数百万的订单)的关键原因。为什么我们要将其开源?我们意识到对高性能编程领域的一些传统观点,有点不对劲。我们找到了一种更好、更快地在线程间共享数据的方法,如果不公开于业界共享的话,那未免太自私了。同时开源也让我们觉得看起来更酷。

从这个站点,你可以下载到一篇解释什么是Disruptor及它为什么如此高性能的文档。这篇文档的编写过程,我并没有参与太多,只是简单地插入了一些标点符号和重组了一些我不懂的句子,但是非常高兴的是,我仍然从中提升了自己的写作水平。

我发现要把所有的事情一下子全部解释清楚还是有点困难的,所有我准备一部分一部分地解释它们,以适合我的NADD听众。

首先介绍ringbuffer。我对Disruptor的最初印象就是ringbuffer。但是后来我意识到尽管ringbuffer是整个模式(Disruptor)的核心,但是Disruptor对ringbuffer的访问控制策略才是真正的关键点所在。

Read more

Dissecting the Disruptor: How do I read from the ring buffer?

原文地址:http://mechanitis.blogspot.com/2011/06/dissecting-disruptor-how-do-i-read-from.html(因为有墙转载到墙内)

作者:Trisha

The next in the series of understanding the Disruptor pattern developed at LMAX.

After the last post we all understand ring buffers and how awesome they are.  Unfortunately for you, I have not said anything about how to actually populate them or read from them when you’re using the Disruptor.

ConsumerBarriers and Consumers
I’m going to approach this slightly backwards, because it’s probably easier to understand in the long run.  Assuming that some magic has populated it: how do you read something from the ring buffer?

(OK, I’m starting to regret using Paint/Gimp.  Although it’s an excellent excuse to purchase a graphics tablet if I do continue down this road.  Also UML gurus are probably cursing my name right now.)

Read more

Dissecting the Disruptor: Writing to the ring buffer

原文地址:http://mechanitis.blogspot.com/2011/07/dissecting-disruptor-writing-to-ring.html(因被墙移到墙内)  作者:Trisha

This is the missing piece in the end-to-end view of the Disruptor.  Brace yourselves, it’s quite long.  But I decided to keep it in a single blog so you could have the context in one place.

The important areas are: not wrapping the ring; informing the consumers; batching for producers; and how multiple producers work. Read more

Disruptor 2.0 – All Change Please

原文地址:http://mechanitis.blogspot.com/2011/08/disruptor-20-all-change-please.html  (因被墙移到墙内)  作者:Trisha

Martin recently announced version 2.0 of the Disruptor – basically there have been so many changes since we first open-sourced it that it’s time to mark that officially.  His post goes over all the changes, the aim of this article is to attempt to translate my previous blog posts into new-world-speak, since it’s going to take a long time to re-write each of them all over again. Now I see the disadvantage of hand-drawing everything.

Read more

return top