[{"data":1,"prerenderedAt":515},["ShallowReactive",2],{"navigation":3,"/changelog/v2-2-0":240,"/changelog/v2-2-0-surround":510},[4,34,66,87,106,145,166,176,204],{"title":5,"path":6,"stem":7,"children":8,"icon":32,"defaultOpen":33},"Getting Started","/getting-started","1.getting-started/1.index",[9,12,17,22,27],{"title":10,"path":6,"stem":7,"icon":11},"Introduction","i-lucide-info",{"title":13,"path":14,"stem":15,"icon":16},"Installation","/getting-started/installation","1.getting-started/2.installation","i-lucide-download",{"title":18,"path":19,"stem":20,"icon":21},"Quickstart (Local)","/getting-started/quickstart-local","1.getting-started/3.quickstart-local","i-lucide-zap",{"title":23,"path":24,"stem":25,"icon":26},"Quickstart (Redis)","/getting-started/quickstart-redis","1.getting-started/4.quickstart-redis","i-lucide-database",{"title":28,"path":29,"stem":30,"icon":31},"Quickstart (Hybrid)","/getting-started/quickstart-hybrid","1.getting-started/5.quickstart-hybrid","i-lucide-arrow-left-right","i-lucide-rocket",true,{"title":35,"icon":36,"defaultOpen":33,"path":37,"stem":38,"children":39,"page":65},"Concepts","i-lucide-lightbulb","/concepts","2.concepts",[40,45,50,55,60],{"title":41,"path":42,"stem":43,"icon":44},"Keys","/concepts/keys","2.concepts/1.keys","i-lucide-key-round",{"title":46,"path":47,"stem":48,"icon":49},"Rate Limits","/concepts/rate-limits","2.concepts/2.rate-limits","i-lucide-badge-percent",{"title":51,"path":52,"stem":53,"icon":54},"Sliding Windows","/concepts/sliding-windows","2.concepts/3.sliding-windows","i-lucide-timer-reset",{"title":56,"path":57,"stem":58,"icon":59},"Decisions","/concepts/decisions","2.concepts/4.decisions","i-lucide-check-check",{"title":61,"path":62,"stem":63,"icon":64},"Configuration Types","/concepts/configuration-types","2.concepts/5.configuration-types","i-lucide-box",false,{"title":67,"icon":68,"defaultOpen":33,"path":69,"stem":70,"children":71,"page":65},"Strategies","i-lucide-git-branch","/strategies","3.strategies",[72,77,82],{"title":73,"path":74,"stem":75,"icon":76},"Absolute","/strategies/absolute","3.strategies/1.absolute","i-lucide-shield",{"title":78,"path":79,"stem":80,"icon":81},"Suppressed","/strategies/suppressed","3.strategies/2.suppressed","i-lucide-activity",{"title":83,"path":84,"stem":85,"icon":86},"How Suppression Works","/strategies/how-suppression-works","3.strategies/3.how-suppression-works","i-lucide-function-square",{"title":88,"icon":89,"defaultOpen":33,"path":90,"stem":91,"children":92,"page":65},"Providers","i-lucide-layers","/providers","4.providers",[93,98,102],{"title":94,"path":95,"stem":96,"icon":97},"Local","/providers/local","4.providers/1.local","i-lucide-cpu",{"title":99,"path":100,"stem":101,"icon":26},"Redis","/providers/redis","4.providers/2.redis",{"title":103,"path":104,"stem":105,"icon":31},"Hybrid","/providers/hybrid","4.providers/3.hybrid",{"title":107,"path":108,"stem":109,"children":110,"icon":76,"defaultOpen":65},"Actix Web","/actix-web","5.actix-web/1.index",[111,113,118,122,127,131,136,140],{"title":112,"path":108,"stem":109,"icon":76},"Overview",{"title":114,"path":115,"stem":116,"icon":117},"Client IPs","/actix-web/client-ips","5.actix-web/2.client-ips","i-lucide-network",{"title":119,"path":120,"stem":121,"icon":44},"Keys and custom extractors","/actix-web/keys","5.actix-web/3.keys",{"title":123,"path":124,"stem":125,"icon":126},"Limits","/actix-web/limits","5.actix-web/4.limits","i-lucide-gauge",{"title":128,"path":129,"stem":130,"icon":26},"Backends","/actix-web/backends","5.actix-web/5.backends",{"title":132,"path":133,"stem":134,"icon":135},"Responses","/actix-web/responses","5.actix-web/6.responses","i-lucide-reply",{"title":137,"path":138,"stem":139,"icon":81},"Observability","/actix-web/observability","5.actix-web/7.observability",{"title":141,"path":142,"stem":143,"icon":144},"Performance","/actix-web/performance","5.actix-web/8.performance","i-lucide-timer",{"title":146,"icon":147,"defaultOpen":65,"path":148,"stem":149,"children":150,"page":65},"Guides","i-lucide-map","/guides","5.guides",[151,156,161],{"title":152,"path":153,"stem":154,"icon":155},"Configuration","/guides/configuration","5.guides/1.configuration","i-lucide-sliders-horizontal",{"title":157,"path":158,"stem":159,"icon":160},"Cleanup","/guides/cleanup","5.guides/2.cleanup","i-lucide-trash-2",{"title":162,"path":163,"stem":164,"icon":165},"Troubleshooting","/guides/troubleshooting","5.guides/4.troubleshooting","i-lucide-wrench",{"title":167,"icon":168,"defaultOpen":65,"path":169,"stem":170,"children":171,"page":65},"Reference","i-lucide-file-text","/reference","6.reference",[172],{"title":173,"path":174,"stem":175,"icon":168},"API Reference Guide","/reference/api","6.reference/1.api",{"title":177,"icon":126,"defaultOpen":65,"path":178,"stem":179,"children":180,"page":65},"Benchmarks","/benchmarks","7.benchmarks",[181,186,190],{"title":182,"path":183,"stem":184,"icon":185},"Benchmark Concepts","/benchmarks/benchmark-concepts","7.benchmarks/0.benchmark-concepts","i-lucide-book-open",{"title":187,"path":188,"stem":189,"icon":126},"Benchmarking & Load Testing","/benchmarks/benchmarking-load-testing","7.benchmarks/1.benchmarking-load-testing",{"title":191,"path":192,"stem":193,"children":194,"icon":203},"Benchmark Results","/benchmarks/benchmark-results","7.benchmarks/2.benchmark-results",[195,199],{"title":196,"path":197,"stem":198,"icon":97},"Local Benchmark Comparison","/benchmarks/benchmark-results/local-benchmark-comparison","7.benchmarks/2.benchmark-results/1.local-benchmark-comparison",{"title":200,"path":201,"stem":202,"icon":26},"Redis + Hybrid Benchmark Comparison","/benchmarks/benchmark-results/redis-benchmark-comparison","7.benchmarks/2.benchmark-results/2.redis-benchmark-comparison","i-lucide-chart-no-axes-combined",{"title":205,"path":206,"stem":207,"children":208,"icon":210,"defaultOpen":65},"Changelog","/changelog","8.changelog/0.index",[209,211,216,220,224,228,232,236],{"title":205,"path":206,"stem":207,"icon":210},"i-lucide-scroll",{"title":212,"path":213,"stem":214,"icon":215},"v2.2.1","/changelog/v2-2-1","8.changelog/1.v2-2-1","i-lucide-tag",{"title":217,"path":218,"stem":219,"icon":215},"v2.2.0","/changelog/v2-2-0","8.changelog/2.v2-2-0",{"title":221,"path":222,"stem":223,"icon":215},"v2.1.0","/changelog/v2-1-0","8.changelog/3.v2-1-0",{"title":225,"path":226,"stem":227,"icon":215},"v2.0.0","/changelog/v2-0-0","8.changelog/4.v2-0-0",{"title":229,"path":230,"stem":231,"icon":215},"v1.1.0","/changelog/v1-1-0","8.changelog/5.v1-1-0",{"title":233,"path":234,"stem":235,"icon":215},"v1.0.1","/changelog/v1-0-1","8.changelog/6.v1-0-1",{"title":237,"path":238,"stem":239,"icon":215},"v1.0.0","/changelog/v1-0-0","8.changelog/7.v1-0-0",{"id":241,"title":217,"authors":242,"badge":217,"body":243,"date":242,"description":504,"extension":505,"links":242,"meta":506,"navigation":507,"path":218,"seo":508,"stem":219,"__hash__":509},"docs/8.changelog/2.v2-2-0.md",null,{"type":244,"value":245,"toc":501},"minimark",[246,254,257,262,327,481,489,497],[247,248,249,253],"p",{},[250,251,252],"strong",{},"Status:"," Released · October 4, 2026",[247,255,256],{},"Version 2.2.0 adds a synchronous increment to the two hybrid limiters and a borrowed form of the\nRedis key.",[258,259,261],"h2",{"id":260},"added","Added",[263,264,265,274,288,306,312],"ul",{},[266,267,268,269,273],"li",{},"Added ",[270,271,272],"code",{},"try_inc(key, count)"," to the absolute and suppressed hybrid limiters. It is synchronous.\nIt makes the decision from the local state of the instance and does not wait for Redis.",[266,275,276,279,280,283,284,287],{},[270,277,278],{},"try_inc"," returns ",[270,281,282],{},"Ok(None)"," and records nothing when the decision needs Redis. This occurs for\na new key, for expired local state, and when the local capacity is used. Then call ",[270,285,286],{},"inc",".",[266,289,268,290,293,294,297,298,301,302,305],{},[270,291,292],{},"RedisKeyRef",", a borrowed key with the same validation rules as ",[270,295,296],{},"RedisKey",".\n",[270,299,300],{},"RedisKeyRef::try_from"," accepts a ",[270,303,304],{},"&str"," and does not allocate.",[266,307,268,308,311],{},[270,309,310],{},"RedisKey::as_key_ref()",". It borrows an owned key and does not validate the key again.",[266,313,314,316,317,320,321,323,324,326],{},[270,315,296],{}," now implements ",[270,318,319],{},"Borrow\u003Cstr>",". Thus, a map with ",[270,322,296],{}," keys accepts a ",[270,325,304],{},"\nfor a lookup.",[328,329,334],"pre",{"className":330,"code":331,"language":332,"meta":333,"style":333},"language-rust shiki shiki-themes material-theme-lighter github-light github-dark monokai","let decision = match provider.absolute().try_inc(key.as_key_ref(), 1)? {\n    Some(decision) => decision,\n    None => provider.absolute().inc(&key, &rate, 1).await?,\n};\n","rust","",[270,335,336,401,424,475],{"__ignoreMap":333},[337,338,341,345,349,353,357,360,362,366,370,372,374,377,380,382,385,388,392,395,398],"span",{"class":339,"line":340},"line",1,[337,342,344],{"class":343},"srJo8","let",[337,346,348],{"class":347},"ss--_"," decision ",[337,350,352],{"class":351},"sGXK2","=",[337,354,356],{"class":355},"sRxSC"," match",[337,358,359],{"class":347}," provider",[337,361,287],{"class":351},[337,363,365],{"class":364},"sD0ED","absolute",[337,367,369],{"class":368},"swvn1","()",[337,371,287],{"class":351},[337,373,278],{"class":364},[337,375,376],{"class":368},"(",[337,378,379],{"class":347},"key",[337,381,287],{"class":351},[337,383,384],{"class":364},"as_key_ref",[337,386,387],{"class":368},"(),",[337,389,391],{"class":390},"sYThS"," 1",[337,393,394],{"class":368},")",[337,396,397],{"class":351},"?",[337,399,400],{"class":368}," {\n",[337,402,404,408,410,413,415,418,421],{"class":339,"line":403},2,[337,405,407],{"class":406},"sKvfc","    Some",[337,409,376],{"class":368},[337,411,412],{"class":347},"decision",[337,414,394],{"class":368},[337,416,417],{"class":351}," =>",[337,419,420],{"class":347}," decision",[337,422,423],{"class":368},",\n",[337,425,427,430,432,434,436,438,440,442,444,446,449,451,454,457,460,462,464,466,468,471,473],{"class":339,"line":426},3,[337,428,429],{"class":406},"    None",[337,431,417],{"class":351},[337,433,359],{"class":347},[337,435,287],{"class":351},[337,437,365],{"class":364},[337,439,369],{"class":368},[337,441,287],{"class":351},[337,443,286],{"class":364},[337,445,376],{"class":368},[337,447,448],{"class":351},"&",[337,450,379],{"class":347},[337,452,453],{"class":368},",",[337,455,456],{"class":351}," &",[337,458,459],{"class":347},"rate",[337,461,453],{"class":368},[337,463,391],{"class":390},[337,465,394],{"class":368},[337,467,287],{"class":351},[337,469,470],{"class":355},"await",[337,472,397],{"class":351},[337,474,423],{"class":368},[337,476,478],{"class":339,"line":477},4,[337,479,480],{"class":368},"};\n",[247,482,483,484,287],{},"See ",[485,486,488],"a",{"href":487},"/providers/hybrid#deciding-without-awaiting","Deciding without awaiting",[247,490,491],{},[485,492,496],{"href":493,"rel":494},"https://crates.io/crates/trypema/2.2.0",[495],"nofollow","trypema 2.2.0 on crates.io",[498,499,500],"style",{},"html pre.shiki code .srJo8, html code.shiki .srJo8{--shiki-light:#9C3EDA;--shiki-light-font-style:inherit;--shiki-default:#D73A49;--shiki-default-font-style:inherit;--shiki-dark:#F97583;--shiki-dark-font-style:inherit;--shiki-sepia:#66D9EF;--shiki-sepia-font-style:italic}html pre.shiki code .ss--_, html code.shiki .ss--_{--shiki-light:#90A4AE;--shiki-default:#24292E;--shiki-dark:#E1E4E8;--shiki-sepia:#F8F8F2}html pre.shiki code .sGXK2, html code.shiki .sGXK2{--shiki-light:#39ADB5;--shiki-default:#D73A49;--shiki-dark:#F97583;--shiki-sepia:#F92672}html pre.shiki code .sRxSC, html code.shiki .sRxSC{--shiki-light:#39ADB5;--shiki-light-font-style:italic;--shiki-default:#D73A49;--shiki-default-font-style:inherit;--shiki-dark:#F97583;--shiki-dark-font-style:inherit;--shiki-sepia:#F92672;--shiki-sepia-font-style:inherit}html pre.shiki code .sD0ED, html code.shiki .sD0ED{--shiki-light:#6182B8;--shiki-default:#6F42C1;--shiki-dark:#B392F0;--shiki-sepia:#A6E22E}html pre.shiki code .swvn1, html code.shiki .swvn1{--shiki-light:#39ADB5;--shiki-default:#24292E;--shiki-dark:#E1E4E8;--shiki-sepia:#F8F8F2}html pre.shiki code .sYThS, html code.shiki .sYThS{--shiki-light:#F76D47;--shiki-default:#005CC5;--shiki-dark:#79B8FF;--shiki-sepia:#AE81FF}html pre.shiki code .sKvfc, html code.shiki .sKvfc{--shiki-light:#E2931D;--shiki-light-text-decoration:inherit;--shiki-default:#6F42C1;--shiki-default-text-decoration:inherit;--shiki-dark:#B392F0;--shiki-dark-text-decoration:inherit;--shiki-sepia:#A6E22E;--shiki-sepia-text-decoration:underline}html .light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html.light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html .default .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}html.dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}html .sepia .shiki span {color: var(--shiki-sepia);background: var(--shiki-sepia-bg);font-style: var(--shiki-sepia-font-style);font-weight: var(--shiki-sepia-font-weight);text-decoration: var(--shiki-sepia-text-decoration);}html.sepia .shiki span {color: var(--shiki-sepia);background: var(--shiki-sepia-bg);font-style: var(--shiki-sepia-font-style);font-weight: var(--shiki-sepia-font-weight);text-decoration: var(--shiki-sepia-text-decoration);}",{"title":333,"searchDepth":340,"depth":403,"links":502},[503],{"id":260,"depth":403,"text":261},"A synchronous increment for the hybrid limiters, and a borrowed Redis key type.","md",{},{"icon":215},{"title":217,"description":504},"zcVtvP14n1ervDo2dY_ltQtFCAazrtq9Gz5-s4xkhaI",[511,513],{"title":212,"path":213,"stem":214,"description":512,"icon":215,"children":-1},"Redis scripts stay below the Lua argument limit, and a cleanup pass runs each step.",{"title":221,"path":222,"stem":223,"description":514,"icon":215,"children":-1},"Rate-only updates and explicit key lifecycle operations across every provider.",1791663182020]