1 -- example dynamic request script which demonstrates changing 2 -- the request path and a header for each request 3 ------------------------------------------------------------- 4 -- NOTE: each wrk thread has an independent Lua scripting 5 -- context and thus there will be one counter per thread 6 7 counter = 0 8 9 request = function() 10 path = "/" .. counter 11 wrk.headers["X-Counter"] = counter 12 counter = counter + 1 13 return wrk.format(nil, path) 14 end