Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

perf(handler) do not use cache with dbless when looking up service for route #8972

Merged
merged 1 commit into from
Jun 30, 2022

Conversation

bungle
Copy link
Member

@bungle bungle commented Jun 16, 2022

Summary

It does not make sense to use cache with dbless where the data is already in memory, especially because the route rebuild process can use a lookup table.

It also consumes a lot of memory to have service in:

  1. lmdb (in memory)
  2. shared dictionary (in memory)
  3. worker local memory

So this commit removes the unneccessary use of cache here.

Reading shdict also causes locking.

@bungle bungle requested a review from a team as a code owner June 16, 2022 20:46
@bungle bungle force-pushed the perf/no-cache-dbless-get-service branch from dd6e570 to 2de9bc9 Compare June 23, 2022 14:27
@github-actions
Copy link
Contributor

🚀 Performance test result

Test Suite: 01-rps 02-flamegraph (baseline,single_route,simple)

["Imgur Images","Imgur Images","Imgur Images"]

Click to expand
Please see Github Actions artifacts for flamegraphs.

  ### Result for upstream directly (run 1):
Running 30s test @ http://10.67.35.129:8088/test
  5 threads and 100 connections
  Thread Stats   Avg      Stdev     Max   +/- Stdev
    Latency   567.69us    1.25ms  20.07ms   87.28%
    Req/Sec   166.46k    13.29k  219.27k    66.07%
  24844543 requests in 30.05s, 3.24GB read
Requests/sec: 826860.76
Transfer/sec:    110.40MB
### Result for upstream directly (run 2):
Running 30s test @ http://10.67.35.129:8088/test
  5 threads and 100 connections
  Thread Stats   Avg      Stdev     Max   +/- Stdev
    Latency   573.24us    1.26ms  12.14ms   87.29%
    Req/Sec   152.33k     7.96k  203.34k    75.93%
  22734855 requests in 30.01s, 2.96GB read
Requests/sec: 757486.37
Transfer/sec:    101.13MB
### Result for upstream directly (run 3):
Running 30s test @ http://10.67.35.129:8088/test
  5 threads and 100 connections
  Thread Stats   Avg      Stdev     Max   +/- Stdev
    Latency   569.12us    1.26ms  19.99ms   87.30%
    Req/Sec   153.42k     8.21k  193.21k    72.35%
  22910539 requests in 30.10s, 2.99GB read
Requests/sec: 761150.21
Transfer/sec:    101.62MB
### Combined result for upstream directly:
RPS     Avg: 781832.45
Latency Avg: nanms    Max: nanms
  
### Test Suite: git:e9f3d176fe72d38e8d26c41c31d1a56019202b8d #simple #no_plugins #single_route
### Result for Kong git:e9f3d176fe72d38e8d26c41c31d1a56019202b8d (run 1):
Running 30s test @ http://10.67.35.131:8000/s1-r1
  5 threads and 100 connections
  Thread Stats   Avg      Stdev     Max   +/- Stdev
    Latency     2.85ms   32.95ms   1.01s    99.63%
    Req/Sec    32.65k     8.97k   58.23k    62.05%
  4879451 requests in 30.10s, 1.02GB read
Requests/sec: 162111.59
Transfer/sec:     34.78MB
### Result for Kong git:e9f3d176fe72d38e8d26c41c31d1a56019202b8d (run 2):
Running 30s test @ http://10.67.35.131:8000/s1-r1
  5 threads and 100 connections
  Thread Stats   Avg      Stdev     Max   +/- Stdev
    Latency     1.18ms    1.88ms  31.88ms   88.25%
    Req/Sec    32.57k     8.94k   58.13k    59.45%
  4867590 requests in 30.10s, 1.02GB read
Requests/sec: 161718.51
Transfer/sec:     34.70MB
### Result for Kong git:e9f3d176fe72d38e8d26c41c31d1a56019202b8d (run 3):
Running 30s test @ http://10.67.35.131:8000/s1-r1
  5 threads and 100 connections
  Thread Stats   Avg      Stdev     Max   +/- Stdev
    Latency     1.17ms    1.84ms  29.88ms   88.24%
    Req/Sec    32.72k     8.70k   59.12k    59.45%
  4890362 requests in 30.10s, 1.02GB read
Requests/sec: 162474.35
Transfer/sec:     34.86MB
### Combined result for Kong git:e9f3d176fe72d38e8d26c41c31d1a56019202b8d:
RPS     Avg: 162101.48
Latency Avg: 1.73ms    Max: 1010.00ms
  
### Test Suite: git:e9f3d176fe72d38e8d26c41c31d1a56019202b8d #simple #no_plugins 10 services each has 10 routes
### Result for Kong git:e9f3d176fe72d38e8d26c41c31d1a56019202b8d (run 1):
Running 30s test @ http://10.67.35.131:8000/
  5 threads and 100 connections
  Thread Stats   Avg      Stdev     Max   +/- Stdev
    Latency     1.19ms    1.84ms  31.73ms   89.36%
    Req/Sec    29.70k     7.84k   54.71k    65.25%
  4446498 requests in 30.10s, 0.93GB read
Requests/sec: 147727.60
Transfer/sec:     31.70MB
### Result for Kong git:e9f3d176fe72d38e8d26c41c31d1a56019202b8d (run 2):
Running 30s test @ http://10.67.35.131:8000/
  5 threads and 100 connections
  Thread Stats   Avg      Stdev     Max   +/- Stdev
    Latency     1.19ms    1.85ms  29.50ms   88.97%
    Req/Sec    30.17k     7.95k   53.75k    60.37%
  4515429 requests in 30.10s, 0.95GB read
Requests/sec: 150018.06
Transfer/sec:     32.19MB
### Result for Kong git:e9f3d176fe72d38e8d26c41c31d1a56019202b8d (run 3):
Running 30s test @ http://10.67.35.131:8000/
  5 threads and 100 connections
  Thread Stats   Avg      Stdev     Max   +/- Stdev
    Latency     1.18ms    1.84ms  33.19ms   89.17%
    Req/Sec    29.91k     8.26k   53.13k    59.53%
  4478360 requests in 30.10s, 0.94GB read
Requests/sec: 148785.99
Transfer/sec:     31.93MB
### Combined result for Kong git:e9f3d176fe72d38e8d26c41c31d1a56019202b8d:
RPS     Avg: 148843.88
Latency Avg: 1.19ms    Max: 33.19ms
  
### Test Suite: git:e9f3d176fe72d38e8d26c41c31d1a56019202b8d #simple #key-auth 10 services each has 10 routes with key-auth, 100 consumers
### Result for Kong git:e9f3d176fe72d38e8d26c41c31d1a56019202b8d (run 1):
Running 30s test @ http://10.67.35.131:8000/
  5 threads and 100 connections
  Thread Stats   Avg      Stdev     Max   +/- Stdev
    Latency     1.28ms    2.33ms 128.43ms   92.01%
    Req/Sec    25.79k     6.85k   43.56k    63.12%
  3862335 requests in 30.10s, 828.75MB read
Requests/sec: 128319.59
Transfer/sec:     27.53MB
### Result for Kong git:e9f3d176fe72d38e8d26c41c31d1a56019202b8d (run 2):
Running 30s test @ http://10.67.35.131:8000/
  5 threads and 100 connections
  Thread Stats   Avg      Stdev     Max   +/- Stdev
    Latency     1.22ms    1.85ms  41.01ms   90.69%
    Req/Sec    26.12k     6.95k   49.26k    59.47%
  3911578 requests in 30.10s, 839.32MB read
Requests/sec: 129955.49
Transfer/sec:     27.88MB
### Result for Kong git:e9f3d176fe72d38e8d26c41c31d1a56019202b8d (run 3):
Running 30s test @ http://10.67.35.131:8000/
  5 threads and 100 connections
  Thread Stats   Avg      Stdev     Max   +/- Stdev
    Latency     1.28ms    1.86ms  31.78ms   89.30%
    Req/Sec    25.80k     6.59k   43.49k    62.19%
  3864453 requests in 30.10s, 829.21MB read
Requests/sec: 128389.98
Transfer/sec:     27.55MB
### Combined result for Kong git:e9f3d176fe72d38e8d26c41c31d1a56019202b8d:
RPS     Avg: 128888.35
Latency Avg: 1.26ms    Max: 128.43ms
  
### Test Suite: git:master #simple #no_plugins #single_route
### Result for Kong git:master (run 1):
Running 30s test @ http://10.67.35.131:8000/s1-r1
  5 threads and 100 connections
  Thread Stats   Avg      Stdev     Max   +/- Stdev
    Latency     1.18ms    1.87ms  39.61ms   88.89%
    Req/Sec    31.57k     8.51k   53.97k    61.78%
  4717197 requests in 30.10s, 0.99GB read
Requests/sec: 156718.19
Transfer/sec:     33.63MB
### Result for Kong git:master (run 2):
Running 30s test @ http://10.67.35.131:8000/s1-r1
  5 threads and 100 connections
  Thread Stats   Avg      Stdev     Max   +/- Stdev
    Latency     1.17ms    1.80ms  31.12ms   88.28%
    Req/Sec    31.96k     8.66k   53.83k    59.72%
  4776727 requests in 30.10s, 1.00GB read
Requests/sec: 158700.08
Transfer/sec:     34.05MB
### Result for Kong git:master (run 3):
Running 30s test @ http://10.67.35.131:8000/s1-r1
  5 threads and 100 connections
  Thread Stats   Avg      Stdev     Max   +/- Stdev
    Latency     1.18ms    1.83ms  31.43ms   88.49%
    Req/Sec    31.87k     8.61k   55.68k    60.65%
  4763113 requests in 30.10s, 1.00GB read
Requests/sec: 158244.64
Transfer/sec:     33.96MB
### Combined result for Kong git:master:
RPS     Avg: 157887.64
Latency Avg: 1.18ms    Max: 39.61ms
  
### Test Suite: git:master #simple #no_plugins 10 services each has 10 routes
### Result for Kong git:master (run 1):
Running 30s test @ http://10.67.35.131:8000/
  5 threads and 100 connections
  Thread Stats   Avg      Stdev     Max   +/- Stdev
    Latency     1.23ms    1.95ms  34.28ms   89.35%
    Req/Sec    29.74k     8.20k   50.94k    61.90%
  4450955 requests in 30.10s, 0.93GB read
Requests/sec: 147875.90
Transfer/sec:     31.73MB
### Result for Kong git:master (run 2):
Running 30s test @ http://10.67.35.131:8000/
  5 threads and 100 connections
  Thread Stats   Avg      Stdev     Max   +/- Stdev
    Latency     1.18ms    1.82ms  32.62ms   89.00%
    Req/Sec    30.06k     7.94k   54.58k    57.94%
  4501818 requests in 30.10s, 0.94GB read
Requests/sec: 149565.10
Transfer/sec:     32.09MB
### Result for Kong git:master (run 3):
Running 30s test @ http://10.67.35.131:8000/
  5 threads and 100 connections
  Thread Stats   Avg      Stdev     Max   +/- Stdev
    Latency     1.20ms    1.89ms  30.04ms   89.04%
    Req/Sec    30.00k     8.17k   54.13k    60.13%
  4492347 requests in 30.10s, 0.94GB read
Requests/sec: 149250.91
Transfer/sec:     32.03MB
### Combined result for Kong git:master:
RPS     Avg: 148897.30
Latency Avg: 1.20ms    Max: 34.28ms
  
### Test Suite: git:master #simple #key-auth 10 services each has 10 routes with key-auth, 100 consumers
### Result for Kong git:master (run 1):
Running 30s test @ http://10.67.35.131:8000/
  5 threads and 100 connections
  Thread Stats   Avg      Stdev     Max   +/- Stdev
    Latency     1.25ms    2.00ms  65.72ms   91.30%
    Req/Sec    25.66k     6.70k   47.63k    62.72%
  3835409 requests in 30.10s, 822.98MB read
Requests/sec: 127425.11
Transfer/sec:     27.34MB
### Result for Kong git:master (run 2):
Running 30s test @ http://10.67.35.131:8000/
  5 threads and 100 connections
  Thread Stats   Avg      Stdev     Max   +/- Stdev
    Latency     1.22ms    1.79ms  36.28ms   90.83%
    Req/Sec    25.67k     6.49k   45.72k    61.78%
  3836127 requests in 30.10s, 823.13MB read
Requests/sec: 127448.48
Transfer/sec:     27.35MB
### Result for Kong git:master (run 3):
Running 30s test @ http://10.67.35.131:8000/
  5 threads and 100 connections
  Thread Stats   Avg      Stdev     Max   +/- Stdev
    Latency     1.22ms    1.82ms  38.67ms   90.92%
    Req/Sec    25.85k     6.60k   43.74k    63.05%
  3863662 requests in 30.10s, 829.04MB read
Requests/sec: 128362.83
Transfer/sec:     27.54MB
### Combined result for Kong git:master:
RPS     Avg: 127745.47
Latency Avg: 1.23ms    Max: 65.72ms
  

Kong error logs are also available in Github Actions artifacts.

Download Artifacts for detailed results and interactive SVG flamegraphs.

…r route

### Summary

It does not make sense to use cache with dbless where the data is already in
memory, especially because the route rebuild process can use a lookup table.

It also consumes a lot of memory to have service in:
1. lmdb (in memory)
2. shared dictionary (in memory)
3. worker local memory

So this commit removes the unneccessary use of cache here.
@bungle bungle force-pushed the perf/no-cache-dbless-get-service branch from 2de9bc9 to 63d9f45 Compare June 30, 2022 08:38
@github-actions
Copy link
Contributor

🚀 Performance test result

Test Suite: 01-rps 02-flamegraph (baseline,single_route,simple)

["Imgur Images","Imgur Images","Imgur Images"]

Click to expand
Please see Github Actions artifacts for flamegraphs.

  ### Result for upstream directly (run 1):
Running 30s test @ http://10.67.35.135:8088/test
  5 threads and 100 connections
  Thread Stats   Avg      Stdev     Max   +/- Stdev
    Latency   564.38us    1.26ms  24.02ms   87.31%
    Req/Sec   170.43k    15.32k  212.08k    62.03%
  25451341 requests in 30.10s, 3.32GB read
Requests/sec: 845582.96
Transfer/sec:    112.90MB
### Result for upstream directly (run 2):
Running 30s test @ http://10.67.35.135:8088/test
  5 threads and 100 connections
  Thread Stats   Avg      Stdev     Max   +/- Stdev
    Latency   577.93us    1.27ms  12.13ms   87.20%
    Req/Sec   154.33k     7.77k  198.89k    75.42%
  23047350 requests in 30.10s, 3.01GB read
Requests/sec: 765713.27
Transfer/sec:    102.23MB
### Result for upstream directly (run 3):
Running 30s test @ http://10.67.35.135:8088/test
  5 threads and 100 connections
  Thread Stats   Avg      Stdev     Max   +/- Stdev
    Latency   575.25us    1.27ms  12.12ms   87.20%
    Req/Sec   154.32k     7.50k  207.67k    72.82%
  23048697 requests in 30.10s, 3.01GB read
Requests/sec: 765741.77
Transfer/sec:    102.24MB
### Combined result for upstream directly:
RPS     Avg: 792346.00
Latency Avg: nanms    Max: nanms
  
### Test Suite: git:9042dbdb8fea76177349bed91ab53141b33f94a3 #simple #no_plugins #single_route
### Result for Kong git:9042dbdb8fea76177349bed91ab53141b33f94a3 (run 1):
Running 30s test @ http://10.67.35.137:8000/s1-r1
  5 threads and 100 connections
  Thread Stats   Avg      Stdev     Max   +/- Stdev
    Latency     1.34ms    2.26ms  36.29ms   89.01%
    Req/Sec    31.91k     9.03k   62.90k    60.43%
  4765606 requests in 30.10s, 1.00GB read
Requests/sec: 158329.03
Transfer/sec:     33.97MB
### Result for Kong git:9042dbdb8fea76177349bed91ab53141b33f94a3 (run 2):
Running 30s test @ http://10.67.35.137:8000/s1-r1
  5 threads and 100 connections
  Thread Stats   Avg      Stdev     Max   +/- Stdev
    Latency     1.25ms    1.98ms  29.47ms   88.19%
    Req/Sec    31.87k     8.51k   53.68k    60.92%
  4763210 requests in 30.10s, 1.00GB read
Requests/sec: 158251.08
Transfer/sec:     33.96MB
### Result for Kong git:9042dbdb8fea76177349bed91ab53141b33f94a3 (run 3):
Running 30s test @ http://10.67.35.137:8000/s1-r1
  5 threads and 100 connections
  Thread Stats   Avg      Stdev     Max   +/- Stdev
    Latency     1.24ms    1.99ms  42.96ms   88.25%
    Req/Sec    32.02k     8.73k   50.69k    58.32%
  4784820 requests in 30.10s, 1.00GB read
Requests/sec: 158967.80
Transfer/sec:     34.11MB
### Combined result for Kong git:9042dbdb8fea76177349bed91ab53141b33f94a3:
RPS     Avg: 158515.97
Latency Avg: 1.28ms    Max: 42.96ms
  
### Test Suite: git:9042dbdb8fea76177349bed91ab53141b33f94a3 #simple #no_plugins 10 services each has 10 routes
### Result for Kong git:9042dbdb8fea76177349bed91ab53141b33f94a3 (run 1):
Running 30s test @ http://10.67.35.137:8000/
  5 threads and 100 connections
  Thread Stats   Avg      Stdev     Max   +/- Stdev
    Latency     1.29ms    2.10ms  36.50ms   88.93%
    Req/Sec    29.84k     7.99k   48.45k    60.00%
  4468125 requests in 30.10s, 0.94GB read
Requests/sec: 148443.41
Transfer/sec:     31.85MB
### Result for Kong git:9042dbdb8fea76177349bed91ab53141b33f94a3 (run 2):
Running 30s test @ http://10.67.35.137:8000/
  5 threads and 100 connections
  Thread Stats   Avg      Stdev     Max   +/- Stdev
    Latency     1.24ms    1.96ms  37.69ms   88.70%
    Req/Sec    29.83k     7.71k   49.96k    59.87%
  4466932 requests in 30.10s, 0.94GB read
Requests/sec: 148404.01
Transfer/sec:     31.84MB
### Result for Kong git:9042dbdb8fea76177349bed91ab53141b33f94a3 (run 3):
Running 30s test @ http://10.67.35.137:8000/
  5 threads and 100 connections
  Thread Stats   Avg      Stdev     Max   +/- Stdev
    Latency     1.26ms    2.02ms  37.82ms   88.95%
    Req/Sec    29.69k     7.95k   53.40k    60.80%
  4445331 requests in 30.10s, 0.93GB read
Requests/sec: 147685.84
Transfer/sec:     31.69MB
### Combined result for Kong git:9042dbdb8fea76177349bed91ab53141b33f94a3:
RPS     Avg: 148177.75
Latency Avg: 1.26ms    Max: 37.82ms
  
### Test Suite: git:9042dbdb8fea76177349bed91ab53141b33f94a3 #simple #key-auth 10 services each has 10 routes with key-auth, 100 consumers
### Result for Kong git:9042dbdb8fea76177349bed91ab53141b33f94a3 (run 1):
Running 30s test @ http://10.67.35.137:8000/
  5 threads and 100 connections
  Thread Stats   Avg      Stdev     Max   +/- Stdev
    Latency     1.38ms    2.48ms 128.74ms   91.11%
    Req/Sec    25.90k     6.52k   41.83k    59.40%
  3877989 requests in 30.10s, 832.11MB read
Requests/sec: 128837.13
Transfer/sec:     27.65MB
### Result for Kong git:9042dbdb8fea76177349bed91ab53141b33f94a3 (run 2):
Running 30s test @ http://10.67.35.137:8000/
  5 threads and 100 connections
  Thread Stats   Avg      Stdev     Max   +/- Stdev
    Latency     1.30ms    2.02ms  37.76ms   90.47%
    Req/Sec    25.77k     6.61k   48.27k    62.32%
  3850446 requests in 30.10s, 826.20MB read
Requests/sec: 127926.65
Transfer/sec:     27.45MB
### Result for Kong git:9042dbdb8fea76177349bed91ab53141b33f94a3 (run 3):
Running 30s test @ http://10.67.35.137:8000/
  5 threads and 100 connections
  Thread Stats   Avg      Stdev     Max   +/- Stdev
    Latency     1.30ms    2.03ms  35.88ms   90.23%
    Req/Sec    26.00k     6.47k   49.54k    58.80%
  3894134 requests in 30.10s, 835.58MB read
Requests/sec: 129373.53
Transfer/sec:     27.76MB
### Combined result for Kong git:9042dbdb8fea76177349bed91ab53141b33f94a3:
RPS     Avg: 128712.44
Latency Avg: 1.33ms    Max: 128.74ms
  
### Test Suite: git:master #simple #no_plugins #single_route
### Result for Kong git:master (run 1):
Running 30s test @ http://10.67.35.137:8000/s1-r1
  5 threads and 100 connections
  Thread Stats   Avg      Stdev     Max   +/- Stdev
    Latency     1.25ms    2.02ms  32.97ms   88.34%
    Req/Sec    31.86k     8.29k   53.58k    61.05%
  4762197 requests in 30.10s, 1.00GB read
Requests/sec: 158214.80
Transfer/sec:     33.95MB
### Result for Kong git:master (run 2):
Running 30s test @ http://10.67.35.137:8000/s1-r1
  5 threads and 100 connections
  Thread Stats   Avg      Stdev     Max   +/- Stdev
    Latency     1.22ms    1.93ms  39.24ms   88.13%
    Req/Sec    32.04k     8.25k   56.82k    58.99%
  4787854 requests in 30.10s, 1.00GB read
Requests/sec: 159070.33
Transfer/sec:     34.13MB
### Result for Kong git:master (run 3):
Running 30s test @ http://10.67.35.137:8000/s1-r1
  5 threads and 100 connections
  Thread Stats   Avg      Stdev     Max   +/- Stdev
    Latency     1.24ms    1.99ms  37.83ms   88.36%
    Req/Sec    31.67k     8.51k   57.65k    61.12%
  4732476 requests in 30.10s, 0.99GB read
Requests/sec: 157229.22
Transfer/sec:     33.74MB
### Combined result for Kong git:master:
RPS     Avg: 158171.45
Latency Avg: 1.24ms    Max: 39.24ms
  
### Test Suite: git:master #simple #no_plugins 10 services each has 10 routes
### Result for Kong git:master (run 1):
Running 30s test @ http://10.67.35.137:8000/
  5 threads and 100 connections
  Thread Stats   Avg      Stdev     Max   +/- Stdev
    Latency     1.27ms    2.04ms  32.21ms   88.80%
    Req/Sec    29.86k     7.77k   48.24k    59.67%
  4471386 requests in 30.10s, 0.94GB read
Requests/sec: 148552.17
Transfer/sec:     31.88MB
### Result for Kong git:master (run 2):
Running 30s test @ http://10.67.35.137:8000/
  5 threads and 100 connections
  Thread Stats   Avg      Stdev     Max   +/- Stdev
    Latency     1.25ms    1.98ms  35.82ms   88.96%
    Req/Sec    29.69k     7.58k   52.19k    61.66%
  4447332 requests in 30.10s, 0.93GB read
Requests/sec: 147753.30
Transfer/sec:     31.70MB
### Result for Kong git:master (run 3):
Running 30s test @ http://10.67.35.137:8000/
  5 threads and 100 connections
  Thread Stats   Avg      Stdev     Max   +/- Stdev
    Latency     1.26ms    2.01ms  33.44ms   88.85%
    Req/Sec    29.43k     8.15k   54.54k    59.04%
  4404851 requests in 30.10s, 0.92GB read
Requests/sec: 146341.43
Transfer/sec:     31.40MB
### Combined result for Kong git:master:
RPS     Avg: 147548.97
Latency Avg: 1.26ms    Max: 35.82ms
  
### Test Suite: git:master #simple #key-auth 10 services each has 10 routes with key-auth, 100 consumers
### Result for Kong git:master (run 1):
Running 30s test @ http://10.67.35.137:8000/
  5 threads and 100 connections
  Thread Stats   Avg      Stdev     Max   +/- Stdev
    Latency     1.40ms    2.43ms 127.76ms   90.83%
    Req/Sec    25.66k     6.85k   45.23k    62.39%
  3842776 requests in 30.10s, 824.56MB read
Requests/sec: 127668.48
Transfer/sec:     27.39MB
### Result for Kong git:master (run 2):
Running 30s test @ http://10.67.35.137:8000/
  5 threads and 100 connections
  Thread Stats   Avg      Stdev     Max   +/- Stdev
    Latency     1.30ms    2.05ms  39.89ms   90.48%
    Req/Sec    25.77k     6.26k   47.18k    60.40%
  3859319 requests in 30.10s, 828.11MB read
Requests/sec: 128217.24
Transfer/sec:     27.51MB
### Result for Kong git:master (run 3):
Running 30s test @ http://10.67.35.137:8000/
  5 threads and 100 connections
  Thread Stats   Avg      Stdev     Max   +/- Stdev
    Latency     1.33ms    2.13ms  46.69ms   90.53%
    Req/Sec    25.70k     6.48k   46.06k    62.59%
  3847533 requests in 30.10s, 825.58MB read
Requests/sec: 127825.63
Transfer/sec:     27.43MB
### Combined result for Kong git:master:
RPS     Avg: 127903.78
Latency Avg: 1.34ms    Max: 127.76ms
  

Kong error logs are also available in Github Actions artifacts.

Download Artifacts for detailed results and interactive SVG flamegraphs.

Copy link
Member

@kikito kikito left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This only affects the loading of services when building the (old) router on dbless and if I understood this comment correctly:

the route rebuild process can use a lookup table

We are using some other kind of cache (lookup table) for the services when rebuilding the Router. That would mean that this change would only affect the initial building of the router.

I spent some time trying to find now build_router changed in the flamegraphs, but could not find it - is this expected?

In principle I am not opposed to this, so I give it a +1.

@bungle bungle merged commit ff61489 into master Jun 30, 2022
@bungle bungle deleted the perf/no-cache-dbless-get-service branch June 30, 2022 14:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants