ZITADEL Docs
APIsBenchmarksv4.17.1

password session benchmark of zitadel v4.17.1

Benchmark results of the v4.17.1 release of Zitadel.

Performance test results

MetricValue
Baselinenone
PurposeTest current performance
Test start2026-08-27 20:02:39 UTC
Test end2026-08-27 20:32:49 UTC
Test duration30min
Executed testpassword_session
k6 versionv2.1.0
VUs600
Client locationUS1
ZITADEL locationUS1
ZITADEL container specificationvCPU: 6
Memory: 6 Gi
Container min scale: 7
Container max scale: 7
ZITADEL Versionv4.17.1
ZITADEL SettingsEventstore autovacuum (new in v4.17): Enabled: true
VacuumThreshold: 1000000
AnalyzeThreshold: 1000000
Tuned for the ~4,000 events/s expected during the benchmark, per the tuning guide.
ZITADEL feature flagsEnabled: loginDefaultOrg (instance), oidcTokenExchange (system), enableBackChannelLogout (system), consoleUseV2UserApi (instance)
improvedPerformance (instance): IMPROVED_PERFORMANCE_PROJECT_GRANT, IMPROVED_PERFORMANCE_PROJECT, IMPROVED_PERFORMANCE_USER_GRANT, IMPROVED_PERFORMANCE_ORG_DOMAIN_VERIFIED
Disabled: loginV2 (explicitly false at instance), userSchema, debugOidcParentError, oidcSingleV1SessionTermination, permissionCheckV2
Captured from the instance before the run (sequence 7, set 2026-08-27 13:35:31 UTC); the same capture covers manipulate_user at 13:41 and the rest of the sweep from 14:56, so all eleven targets ran the same configuration.
This restores like-for-like comparison with the v4 pages, which ran five improvedPerformance options. The fifth, IMPROVED_PERFORMANCE_ORG_BY_ID, is reserved in the proto and no longer exists.
Databasetype: psql
version: v17.4
Database locationUS1
Database specificationvCPU: 8
memory: 32Gib
ZITADEL metrics during testCPU: p50 50%, p99 69% (peak 75%)
Memory: p50 7%, peak 16%
Instances: 7 (constant), no container startups recorded
Server-side: 140 req/s, latency p50 2.6s / p95 10.7s / p99 11.5s
Observed errors1 of 253,280 requests failed (0.00%): 1x connection reset. 1 iteration aborted on a null response body. 1 of 252,683 checks failed (0.00%): set Session status ok (1 failed)
Top 3 most expensive database queries1: Projection handler advisory lock, one per projection per instance — lock wait, not query work (18,303 s)
2: Eventstore read barrier: advisory lock + unlock on events2 — lock wait (6,904 s)
3: Query events by instance_id, aggregate_types, event_types, position (paged) (3,794 s)
Ranked by total accumulated execution time summed across concurrent sessions (Cloud SQL Query Insights) — not CPU time; it can exceed the wall-clock window.
Database metrics during testCPU: 51% median, 52% peak
Memory: 40%
Connections: 46
Transactions: 2,029/s
IOPS: read 3, write 597
k6 Iterations per second68
k6 outputoutput
flowchart outcomePotential issues. Not resource-bound: database CPU 51%, ZITADEL CPU 50%, yet 86% of the top-5 query time is advisory lock wait — predominantly the projection handler lock, which serialises this workload. Additional vCPU will not help. Logged as an issue rather than blocking further scale testing.

Endpoint latencies

k6 output

  █ TOTAL RESULTS

    checks_total.......: 252683 136.744628/s
    checks_succeeded...: 99.99% 252682 out of 252683
    checks_failed......: 0.00%  1 out of 252683

    ✓ user defined
    ✓ authorize status ok
    ✓ login name status ok
    ✓ login shows password page
    ✓ password status ok
    ✓ password callback
    ✓ code set
    ✓ token status ok
    ✓ access token created
    ✓ id token created
    ✓ info created
    ✓ org created
    ✓ create user is status ok
    ✓ set email otp status ok
    ✓ add Session status ok
    ✗ set Session status ok
      ↳  99% — ✓ 125734 / ✗ 1
    ✓ org removed

    CUSTOM
    login_ui_enter_login_name_duration...: min=163.44ms avg=163.44ms max=163.44ms p(50)=163.44ms p(95)=163.44ms p(99)=163.44ms
    login_ui_enter_password_duration.....: min=12.83ms  avg=12.83ms  max=12.83ms  p(50)=12.83ms  p(95)=12.83ms  p(99)=12.83ms
    login_ui_init_login_duration.........: min=55.61ms  avg=55.61ms  max=55.61ms  p(50)=55.61ms  p(95)=55.61ms  p(99)=55.61ms
    login_ui_token_duration..............: min=97.03ms  avg=97.03ms  max=97.03ms  p(50)=97.03ms  p(95)=97.03ms  p(99)=97.03ms
    org_create_org_duration..............: min=56.23ms  avg=56.23ms  max=56.23ms  p(50)=56.23ms  p(95)=56.23ms  p(99)=56.23ms
    password_session_duration............: min=361ms    avg=8.61s    max=36.61s   p(50)=5.67s    p(95)=22.32s   p(99)=25.76s
    session_add_session_duration.........: min=48.7ms   avg=8.23s    max=33.11s   p(50)=5.29s    p(95)=21.94s   p(99)=25.31s
    session_set_session_duration.........: min=619.72µs avg=372.12ms max=8.7s     p(50)=339.05ms p(95)=530.41ms p(99)=711.46ms
    set_human_email_otp_duration.........: min=24.46ms  avg=158.74ms max=552.96ms p(50)=118.89ms p(95)=445.68ms p(99)=528.23ms
    user_create_human_duration...........: min=350.17ms avg=3.56s    max=7.21s    p(50)=3.7s     p(95)=6.72s    p(99)=6.95s

    HTTP
    http_req_duration....................: min=619.72µs avg=4.28s    max=33.11s   p(50)=408.63ms p(95)=20s      p(99)=24.05s
      { expected_response:true }.........: min=12.83ms  avg=4.28s    max=33.11s   p(50)=408.64ms p(95)=20s      p(99)=24.05s
    http_req_failed......................: 0.00%  1 out of 253280
    http_reqs............................: 253280 137.067706/s

    EXECUTION
    iteration_duration...................: min=361.04ms avg=8.61s    max=36.61s   p(50)=5.67s    p(95)=22.32s   p(99)=25.76s
    iterations...........................: 125735 68.044094/s
    vus..................................: 0      min=0           max=600
    vus_max..............................: 600    min=600         max=600

    NETWORK
    data_received........................: 192 MB 104 kB/s
    data_sent............................: 86 MB  47 kB/s

running (30m47.8s), 000/600 VUs, 125735 complete and 0 interrupted iterations
default ✓ [ 100% ] 600 VUs  30m0s

Was this page helpful?

On this page