redis-benchmarks-specification 0.2.4__py3-none-any.whl → 0.2.5__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.

Potentially problematic release.


This version of redis-benchmarks-specification might be problematic. Click here for more details.

@@ -0,0 +1,109 @@
1
+ version: 0.4
2
+ name: memtier_benchmark-session-caching-json-100k-sessions
3
+ description: |
4
+ Runs memtier_benchmark to simulate a session caching workload for a SaaS application.
5
+ This benchmark focuses exclusively on JSON-based session storage, where each session
6
+ is stored as a Redis JSON document (`session:<id>`) with fields like user ID, timestamps, device info,
7
+ and metadata (total ~400–600B).
8
+
9
+ The benchmark models a typical read-heavy cache usage pattern, with an approximate
10
+ **read:write ratio of 90:10**, reflecting session retrievals and infrequent updates.
11
+
12
+ Command groups:
13
+ - Session cache reads (`JSON.GET`): ~90%
14
+ - Session cache writes (`JSON.SET`): ~10%
15
+
16
+ To better approximate real-world access patterns, the benchmark uses a **Zipfian key distribution**
17
+ (`--command-key-pattern=Z`). This simulates **skewed access** where a small subset of sessions (hot keys)
18
+ receives a majority of reads — a common pattern in production workloads.
19
+
20
+ While Zipfian is technically a power-law distribution, it effectively mimics **Poisson-like behavior**
21
+ in large-scale systems, where access frequency is uneven but statistically predictable.
22
+ This access skew mirrors real-life scenarios such as:
23
+ - Frequently accessed or "sticky" user sessions
24
+ - Popular user accounts or active devices
25
+ - Hot caches for trending or recently used resources
26
+
27
+ Using Zipfian distribution allows this benchmark to capture **contention**, **cache pressure**, and
28
+ **read amplification** effects that occur in real SaaS applications under load.
29
+
30
+
31
+ dbconfig:
32
+ configuration-parameters:
33
+ save: '""'
34
+ resources:
35
+ requests:
36
+ memory: 1g
37
+ init_lua: |
38
+ local seed = 12345
39
+ math.randomseed(seed)
40
+ local now = tonumber(redis.call('TIME')[1])
41
+ local function rand_str(len)
42
+ local chars = 'abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789'
43
+ local res = ''
44
+ for i = 1, len do
45
+ local idx = math.random(#chars)
46
+ res = res .. chars:sub(idx, idx)
47
+ end
48
+ return res
49
+ end
50
+ for i = 1, 100000 do
51
+ local session_id = 'session:' .. i
52
+ local user_id = 'user-' .. i
53
+ local org_id = 'org-' .. i
54
+ local session_data = {
55
+ userId = user_id,
56
+ organizationId = org_id,
57
+ role = 'member',
58
+ createdAt = tostring(now - math.random(3600)),
59
+ lastAccessed = tostring(now),
60
+ ipAddress = '192.168.1.' .. (i % 255),
61
+ device = 'device-' .. rand_str(8),
62
+ authMethod = 'password',
63
+ status = 'active',
64
+ metadata = rand_str(200 + (i % 100))
65
+ }
66
+ redis.call('JSON.SET', session_id, '$', cjson.encode(session_data))
67
+ end
68
+ return 'OK'
69
+
70
+ tested-groups:
71
+ - json
72
+
73
+ tested-commands:
74
+ - json.get
75
+ - json.set
76
+
77
+ redis-topologies:
78
+ - oss-standalone
79
+
80
+ build-variants:
81
+ - gcc:15.2.0-amd64-debian-bookworm-default
82
+ - gcc:15.2.0-arm64-debian-bookworm-default
83
+ - dockerhub
84
+
85
+ clientconfig:
86
+ run_image: redislabs/memtier_benchmark:edge
87
+ tool: memtier_benchmark
88
+ arguments: >
89
+ --key-prefix ""
90
+ --key-minimum 1
91
+ --key-maximum 100000
92
+ --data-size-range=400-600
93
+ --pipeline=1
94
+ --print-percentiles=50,90,95,99
95
+ --run-count=1
96
+ --test-time=120
97
+ --command="JSON.GET session:__key__"
98
+ --command-key-pattern=Z
99
+ --command-ratio=90
100
+ --command="JSON.SET session:__key__ $ \"{\\\"userId\\\":\\\"user-__key__\\\",\\\"organizationId\\\":\\\"org-__key__\\\",\\\"role\\\":\\\"admin\\\",\\\"email\\\":\\\"user__key__@example.com\\\",\\\"name\\\":\\\"User __key__\\\",\\\"permissions\\\":[\\\"read\\\",\\\"write\\\"],\\\"lastActivity\\\":__key__,\\\"ipAddress\\\":\\\"192.168.1.__key__\\\",\\\"userAgent\\\":\\\"Mozilla/5.0\\\",\\\"createdAt\\\":__key__}\""
101
+ --command-key-pattern=Z
102
+ --command-ratio=10
103
+ --hide-histogram
104
+ resources:
105
+ requests:
106
+ cpus: '4'
107
+ memory: 2g
108
+
109
+ priority: 150
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: redis-benchmarks-specification
3
- Version: 0.2.4
3
+ Version: 0.2.5
4
4
  Summary: The Redis benchmarks specification describes the cross-language/tools requirements and expectations to foster performance and observability standards around redis related technologies. Members from both industry and academia, including organizations and individuals are encouraged to contribute.
5
5
  Author: filipecosta90
6
6
  Author-email: filipecosta.90@gmail.com
@@ -277,13 +277,14 @@ redis_benchmarks_specification/test-suites/memtier_benchmark-nokeys-pubsub-mixed
277
277
  redis_benchmarks_specification/test-suites/memtier_benchmark-nokeys-pubsub-publish-1K-channels-10B-no-subscribers.yml,sha256=8M9AdpNaVBuSUm78cqKModOF_xITV_RM7RLCTyvtvaQ,825
278
278
  redis_benchmarks_specification/test-suites/memtier_benchmark-nokeys-server-time-pipeline-10.yml,sha256=zeTHtpbhNGfzTXHfr9P5e62PebxUONRvTsCbXJZhsTs,721
279
279
  redis_benchmarks_specification/test-suites/memtier_benchmark-playbook-session-caching-hash-100k-sessions.yml,sha256=H98DrXlq-lRhoe1M7vehfDBbUdZ7WwWroriTpklx-PI,3646
280
+ redis_benchmarks_specification/test-suites/memtier_benchmark-playbook-session-caching-json-100k-sessions.yml,sha256=MDvxjvFvIv_vnbeon8AEOd0XNouqGNhwer3JN_Vzi9c,3858
280
281
  redis_benchmarks_specification/test-suites/memtier_benchmark-playbook-session-caching-string-100k-sessions.yml,sha256=yVrHQxMp2xzSpZ5Vx7GCTqhwbjMB-RoBf1T20qz9puE,3909
281
282
  redis_benchmarks_specification/test-suites/memtier_benchmark-playbook-session-storage-100k-sessions.yml,sha256=GCNREyvwGlhMDmrvOaRWi1w0GqG9YA-8TRoh1xIa4xw,7012
282
283
  redis_benchmarks_specification/test-suites/memtier_benchmark-playbook-session-storage-1k-sessions.yml,sha256=2egtIxPxCze2jlbAfgsk4v9JSQHNMoPLbDWFEW8olDg,7006
283
284
  redis_benchmarks_specification/test-suites/template.txt,sha256=ezqGiRPOvuSDO0iG7GEf-AGXNfHbgXI89_G0RUEzL88,481
284
285
  redis_benchmarks_specification/vector-search-test-suites/vector_db_benchmark_test.yml,sha256=PD7ow-k4Ll2BkhEC3aIqiaCZt8Hc4aJIp96Lw3J3mcI,791
285
- redis_benchmarks_specification-0.2.4.dist-info/LICENSE,sha256=xx0jnfkXJvxRnG63LTGOxlggYnIysveWIZ6H3PNdCrQ,11357
286
- redis_benchmarks_specification-0.2.4.dist-info/METADATA,sha256=Ibm4P1A-tkSkmJGeTgmhd4ONjm7j5TJKFJ4jmEVRdlA,22766
287
- redis_benchmarks_specification-0.2.4.dist-info/WHEEL,sha256=sP946D7jFCHeNz5Iq4fL4Lu-PrWrFsgfLXbbkciIZwg,88
288
- redis_benchmarks_specification-0.2.4.dist-info/entry_points.txt,sha256=x5WBXCZsnDRTZxV7SBGmC65L2k-ygdDOxV8vuKN00Nk,715
289
- redis_benchmarks_specification-0.2.4.dist-info/RECORD,,
286
+ redis_benchmarks_specification-0.2.5.dist-info/LICENSE,sha256=xx0jnfkXJvxRnG63LTGOxlggYnIysveWIZ6H3PNdCrQ,11357
287
+ redis_benchmarks_specification-0.2.5.dist-info/METADATA,sha256=--58lygIdodiACPH_c6Zqfak9ldjWH7XHLAqwG29nb0,22766
288
+ redis_benchmarks_specification-0.2.5.dist-info/WHEEL,sha256=sP946D7jFCHeNz5Iq4fL4Lu-PrWrFsgfLXbbkciIZwg,88
289
+ redis_benchmarks_specification-0.2.5.dist-info/entry_points.txt,sha256=x5WBXCZsnDRTZxV7SBGmC65L2k-ygdDOxV8vuKN00Nk,715
290
+ redis_benchmarks_specification-0.2.5.dist-info/RECORD,,