From 01df5ce4562c622fbbdb8150c4fb2ae8bb83a393 Mon Sep 17 00:00:00 2001 From: Rene Schallner Date: Fri, 20 Jan 2023 20:41:54 +0100 Subject: [PATCH] more endpoint comments --- examples/endpoint/main.zig | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/examples/endpoint/main.zig b/examples/endpoint/main.zig index 1893053..828b656 100644 --- a/examples/endpoint/main.zig +++ b/examples/endpoint/main.zig @@ -39,6 +39,11 @@ pub fn main() !void { // and run zap.start(.{ .threads = 2000, + // IMPORTANT! It is crucial to only have a single worker for this example to work! + // Multiple workers would have multiple copies of the users hashmap. + // + // Since zap is quite fast, you can do A LOT with a single worker. + // Try it with `zig build run-endpoint -Drelease-fast` .workers = 1, }); }