GithubHelp home page GithubHelp logo

perf_compare's Introduction

Background

In order to confirm that there is not some nasty artefact inside of chronicle queue causing the nasty high percentile latencies we sometimes see, this is a test of chronicle queue against the simplest possible comparison I could find - Agrona’s ringbuffer.

Chronicle queue does a lot more than Agrona ringbuffer e.g. indexing, rolling, unbounded, multi-thread publish & consume etc.

There is a JLBH test for queue and another for Agrona and each test starts up a consumer thread to read messages, and generates them in the JLBH thread. The Agrona test uses a memory-mapped file to make it as similar as possible to CQ. We measure the time it takes to get from producer thread to consumer thread.

Results

Agrona vs Queue

  • very similar at 99.99/worst

  • Agrona consistently better at lower percentiles which of course is to be expected as it is doing less

The fact that they are pretty much the same at worst says to me that we don’t have any lurking issues in chronicle queue.

TODO: test with 2 processes

AgronaManyToOneFileJLBH

-------------------------------- SUMMARY (end to end)------------------------------------------------------------
Percentile   run1         run2         run3         run4         run5         run6         run7      % Variation
50:             0.19         0.14         0.14         0.14         0.14         0.15         0.16         7.08
90:             0.23         0.18         0.17         0.18         0.17         0.18         0.17         3.01
99:             0.28         0.20         0.20         0.20         0.20         0.20         0.20         2.65
99.9:           4.99         0.47         0.22         0.26         0.24         4.99         0.24        93.53
99.99:         16.13         7.81         8.45         8.06         8.45         9.47         8.45        12.44
worst:         96.26        33.79        10.50        10.50        16.13        10.50        10.50        59.67

Queue

-------------------------------- SUMMARY (end to end)------------------------------------------------------------
Percentile   run1         run2         run3         run4         run5         run6         run7      % Variation
50:             0.31         0.28         0.28         0.28         0.28         0.28         0.21        17.62
90:             0.34         0.33         0.31         0.33         0.31         0.31         0.26        13.91
99:             1.57         1.44         1.50         0.39         1.50         1.57         3.14        82.35
99.9:           6.53         5.50         4.99         4.03         8.45         7.81         9.47        47.35
99.99:         27.14         9.98         8.96         9.47         9.47         9.98        10.50        10.26
worst:        135.17        37.89        17.92        13.06        10.50        11.01        10.50        63.50
-------------------------------------------------------------------------------------------------------------------

AgronaManyToOneMemoryJLBH

-------------------------------- SUMMARY (end to end)------------------------------------------------------------
Percentile   run1         run2         run3         run4         run5         run6         run7      % Variation
50:             0.20         0.16         0.15         0.16         0.15         0.16         0.16         6.72
90:             0.24         0.20         0.19         0.19         0.19         0.19         0.20         2.76
99:             0.28         0.24         0.21         0.21         0.21         0.22         4.99        93.76
99.9:           1.25         0.30         0.24         0.24         3.26         7.30         9.47        96.31
99.99:         12.54         8.45         8.45         8.06         8.06         9.98        10.50        16.74
worst:        129.02        92.16        10.50        10.50        46.08        11.01        12.03        83.84

ErbJLBH

-------------------------------- SUMMARY (end to end)------------------------------------------------------------
Percentile   run1         run2         run3         run4         run5         run6         run7      % Variation
50:             0.38         0.34         0.36         0.38         0.36         0.36         0.36         5.84
90:             0.42         0.39         0.41         0.41         0.39         0.41         0.41         2.65
99:             0.47         0.44         0.46         0.46         0.46         0.47         4.03        84.48
99.9:           0.91         0.82         0.53         0.53         2.37         7.81         9.47        91.87
99.99:         10.50        10.50         9.47         9.47         8.96        10.50        10.50        10.26
worst:        135.17       135.17       135.17       135.17       135.17       135.17        96.26        21.23

Results longer-running

These tests compare purely performance for a larger, longer-running workload. Each run is 5,000,000 iterations of a 128 byte message @ 50K/sec = 620MB of data.

AgronaManyToOneFileJLBH

-------------------------------- SUMMARY (end to end)---------------------------------
Percentile   run1         run2         run3         run4         run5      % Variation
50:             0.34         0.33         0.33         0.33         0.33         0.00
90:             0.41         0.39         0.39         0.39         0.39         0.17
99:             3.04         0.47         1.46         2.03         1.73        69.17
99.9:           5.13         3.47         3.35         3.38         3.37         2.41
99.99:       2806.78         4.53         3.61         3.71         3.61        14.45
99.999:     11554.82       452.22       593.15       734.46         7.96        98.38
worst:      12513.28      1422.85      1555.97      1690.11       362.62        70.93

Queue (w pretouch)

-------------------------------- SUMMARY (end to end)---------------------------------
Percentile   run1         run2         run3         run4         run5      % Variation
50:             0.59         0.59         0.59         0.59         0.59         0.11
90:             0.67         0.66         0.66         0.66         0.66         0.20
99:             3.39         3.42         3.42         3.39         3.39         0.51
99.9:         300.16        43.73         7.06         4.31         4.72        85.91
99.99:      17473.54      6109.18      4945.92      4191.23      4581.38        23.38
99.999:     25649.15     13643.78      6084.61      5883.90      5908.48        46.79
worst:      26386.43     14397.44      6498.30      6195.20      6428.67        46.88

ErbJLBH

-------------------------------- SUMMARY (end to end)----------------------------------
Percentile   run1         run2         run3         run4         run5      % Variation
50:             0.61         0.62         0.63         0.63         0.63         0.53
90:             0.66         0.66         0.67         0.67         0.67         0.20
99:             1.81         0.73         0.72         0.73         0.71         1.84
99.9:           7.43         1.86         1.85         1.95         0.78        49.93
99.99:      17637.38      5421.06         2.02         4.08         1.00        99.97
99.999:     26501.12      9826.30       383.87       267.39        43.79        99.33
worst:      27451.39     10465.28      1142.27      1137.15       561.41        92.16

perf_compare's People

Contributors

jerryshea avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.