[{"data":1,"prerenderedAt":3201},["ShallowReactive",2],{"navigation":3,"docs-path-index":268,"-docs-modules-queue-api":348,"-docs-modules-queue-api-surround":3196},[4],{"title":5,"icon":6,"path":7,"stem":8,"children":9,"page":56},"Docs","i-lucide-book-marked","\u002Fdocs","docs",[10,26,57,229,250],{"title":11,"path":12,"stem":13,"children":14,"icon":25},"Getting Started","\u002Fdocs\u002Fgetting-started","docs\u002F1.getting-started\u002F1.index",[15,17,21],{"title":16,"path":12,"stem":13},"Introduction",{"title":18,"path":19,"stem":20},"Installation","\u002Fdocs\u002Fgetting-started\u002Finstallation","docs\u002F1.getting-started\u002F2.installation",{"title":22,"path":23,"stem":24},"Examples","\u002Fdocs\u002Fgetting-started\u002Fexamples","docs\u002F1.getting-started\u002F3.examples","i-lucide-rocket",{"title":27,"icon":28,"path":29,"stem":30,"children":31,"page":56},"Core features","i-lucide-square-function","\u002Fdocs\u002Fcore-features","docs\u002F2.core-features",[32,36,40,44,48,52],{"title":33,"path":34,"stem":35},"Configuration","\u002Fdocs\u002Fcore-features\u002Fconfiguration","docs\u002F2.core-features\u002F0.configuration",{"title":37,"path":38,"stem":39},"Dependency Injection","\u002Fdocs\u002Fcore-features\u002Fcontainer","docs\u002F2.core-features\u002F1.container",{"title":41,"path":42,"stem":43},"Controllers","\u002Fdocs\u002Fcore-features\u002Fcontrollers","docs\u002F2.core-features\u002F2.controllers",{"title":45,"path":46,"stem":47},"Middlewares","\u002Fdocs\u002Fcore-features\u002Fmiddlewares","docs\u002F2.core-features\u002F3.middlewares",{"title":49,"path":50,"stem":51},"Validation","\u002Fdocs\u002Fcore-features\u002Fvalidation","docs\u002F2.core-features\u002F4.validation",{"title":53,"path":54,"stem":55},"Introspection","\u002Fdocs\u002Fcore-features\u002Fintrospection","docs\u002F2.core-features\u002F5.introspection",false,{"title":58,"icon":59,"defaultOpen":60,"path":61,"stem":62,"children":63,"page":56},"Modules","i-lucide-boxes",true,"\u002Fdocs\u002Fmodules","docs\u002F3.modules",[64,81,92,108,127,142,150,165,176,191,210,218],{"title":65,"icon":56,"defaultOpen":56,"path":66,"stem":67,"children":68,"page":56},"Auth","\u002Fdocs\u002Fmodules\u002Fauth","docs\u002F3.modules\u002F1.auth",[69,73,77],{"title":70,"path":71,"stem":72},"Overview","\u002Fdocs\u002Fmodules\u002Fauth\u002Foverview","docs\u002F3.modules\u002F1.auth\u002F0.overview",{"title":74,"path":75,"stem":76},"Decorators","\u002Fdocs\u002Fmodules\u002Fauth\u002Fdecorators","docs\u002F3.modules\u002F1.auth\u002F1.decorators",{"title":78,"path":79,"stem":80},"API Reference","\u002Fdocs\u002Fmodules\u002Fauth\u002Fapi","docs\u002F3.modules\u002F1.auth\u002F2.api",{"title":82,"icon":56,"defaultOpen":56,"path":83,"stem":84,"children":85,"page":56},"Devtools","\u002Fdocs\u002Fmodules\u002Fdevtools","docs\u002F3.modules\u002F10.devtools",[86,89],{"title":70,"path":87,"stem":88},"\u002Fdocs\u002Fmodules\u002Fdevtools\u002Foverview","docs\u002F3.modules\u002F10.devtools\u002F0.overview",{"title":33,"path":90,"stem":91},"\u002Fdocs\u002Fmodules\u002Fdevtools\u002Fconfiguration","docs\u002F3.modules\u002F10.devtools\u002F1.configuration",{"title":93,"path":94,"stem":95,"children":96,"page":56},"Telemetry","\u002Fdocs\u002Fmodules\u002Ftelemetry","docs\u002F3.modules\u002F11.telemetry",[97,100,104],{"title":70,"path":98,"stem":99},"\u002Fdocs\u002Fmodules\u002Ftelemetry\u002Foverview","docs\u002F3.modules\u002F11.telemetry\u002F0.overview",{"title":101,"path":102,"stem":103},"API","\u002Fdocs\u002Fmodules\u002Ftelemetry\u002Fapi","docs\u002F3.modules\u002F11.telemetry\u002F1.api",{"title":105,"path":106,"stem":107},"Instrumentation","\u002Fdocs\u002Fmodules\u002Ftelemetry\u002Finstrumentation","docs\u002F3.modules\u002F11.telemetry\u002F2.instrumentation",{"title":109,"path":110,"stem":111,"children":112,"page":56},"Queue","\u002Fdocs\u002Fmodules\u002Fqueue","docs\u002F3.modules\u002F12.queue",[113,116,120,124],{"title":70,"path":114,"stem":115},"\u002Fdocs\u002Fmodules\u002Fqueue\u002Foverview","docs\u002F3.modules\u002F12.queue\u002F0.overview",{"title":117,"path":118,"stem":119},"Consumers","\u002Fdocs\u002Fmodules\u002Fqueue\u002Fconsumers","docs\u002F3.modules\u002F12.queue\u002F1.consumers",{"title":121,"path":122,"stem":123},"Strategies","\u002Fdocs\u002Fmodules\u002Fqueue\u002Fstrategies","docs\u002F3.modules\u002F12.queue\u002F2.strategies",{"title":101,"path":125,"stem":126},"\u002Fdocs\u002Fmodules\u002Fqueue\u002Fapi","docs\u002F3.modules\u002F12.queue\u002F3.api",{"title":128,"icon":56,"defaultOpen":56,"path":129,"stem":130,"children":131,"page":56},"Logger","\u002Fdocs\u002Fmodules\u002Flogger","docs\u002F3.modules\u002F2.logger",[132,135,139],{"title":70,"path":133,"stem":134},"\u002Fdocs\u002Fmodules\u002Flogger\u002Foverview","docs\u002F3.modules\u002F2.logger\u002F0.overview",{"title":136,"path":137,"stem":138},"Drains & Adapters","\u002Fdocs\u002Fmodules\u002Flogger\u002Fdrivers","docs\u002F3.modules\u002F2.logger\u002F1.drivers",{"title":101,"path":140,"stem":141},"\u002Fdocs\u002Fmodules\u002Flogger\u002Fapi","docs\u002F3.modules\u002F2.logger\u002F2.api",{"title":143,"icon":56,"defaultOpen":56,"path":144,"stem":145,"children":146,"page":56},"Serverless","\u002Fdocs\u002Fmodules\u002Fserverless","docs\u002F3.modules\u002F3.serverless",[147],{"title":70,"path":148,"stem":149},"\u002Fdocs\u002Fmodules\u002Fserverless\u002Foverview","docs\u002F3.modules\u002F3.serverless\u002F0.overview",{"title":151,"icon":56,"defaultOpen":56,"path":152,"stem":153,"children":154,"page":56},"Storage","\u002Fdocs\u002Fmodules\u002Fstorage","docs\u002F3.modules\u002F4.storage",[155,158,162],{"title":70,"path":156,"stem":157},"\u002Fdocs\u002Fmodules\u002Fstorage\u002Foverview","docs\u002F3.modules\u002F4.storage\u002F0.overview",{"title":159,"path":160,"stem":161},"Drivers","\u002Fdocs\u002Fmodules\u002Fstorage\u002Fdrivers","docs\u002F3.modules\u002F4.storage\u002F1.drivers",{"title":101,"path":163,"stem":164},"\u002Fdocs\u002Fmodules\u002Fstorage\u002Fapi","docs\u002F3.modules\u002F4.storage\u002F2.api",{"title":166,"icon":56,"defaultOpen":56,"path":167,"stem":168,"children":169,"page":56},"Web Sockets","\u002Fdocs\u002Fmodules\u002Fweb-sockets","docs\u002F3.modules\u002F5.web-sockets",[170,173],{"title":70,"path":171,"stem":172},"\u002Fdocs\u002Fmodules\u002Fweb-sockets\u002Foverview","docs\u002F3.modules\u002F5.web-sockets\u002F0.overview",{"title":101,"path":174,"stem":175},"\u002Fdocs\u002Fmodules\u002Fweb-sockets\u002Fapi","docs\u002F3.modules\u002F5.web-sockets\u002F1.api",{"title":177,"icon":56,"defaultOpen":56,"path":178,"stem":179,"children":180,"page":56},"Schema","\u002Fdocs\u002Fmodules\u002Fschema","docs\u002F3.modules\u002F6.schema",[181,184,187],{"title":70,"path":182,"stem":183},"\u002Fdocs\u002Fmodules\u002Fschema\u002Foverview","docs\u002F3.modules\u002F6.schema\u002F0.overview",{"title":74,"path":185,"stem":186},"\u002Fdocs\u002Fmodules\u002Fschema\u002Fdecorators","docs\u002F3.modules\u002F6.schema\u002F1.decorators",{"title":188,"path":189,"stem":190},"Scalar","\u002Fdocs\u002Fmodules\u002Fschema\u002Fscalar","docs\u002F3.modules\u002F6.schema\u002F2.scalar",{"title":192,"icon":56,"defaultOpen":56,"path":193,"stem":194,"children":195,"page":56},"Nitro","\u002Fdocs\u002Fmodules\u002Fnitro","docs\u002F3.modules\u002F7.nitro",[196,199,202,206],{"title":70,"path":197,"stem":198},"\u002Fdocs\u002Fmodules\u002Fnitro\u002Foverview","docs\u002F3.modules\u002F7.nitro\u002F0.overview",{"title":151,"path":200,"stem":201},"\u002Fdocs\u002Fmodules\u002Fnitro\u002Fstorage","docs\u002F3.modules\u002F7.nitro\u002F1.storage",{"title":203,"path":204,"stem":205},"File-Based Routes","\u002Fdocs\u002Fmodules\u002Fnitro\u002Ffile-based-routes","docs\u002F3.modules\u002F7.nitro\u002F2.file-based-routes",{"title":207,"path":208,"stem":209},"Middleware","\u002Fdocs\u002Fmodules\u002Fnitro\u002Fmiddleware","docs\u002F3.modules\u002F7.nitro\u002F3.middleware",{"title":211,"icon":56,"defaultOpen":56,"path":212,"stem":213,"children":214,"page":56},"Vite","\u002Fdocs\u002Fmodules\u002Fvite","docs\u002F3.modules\u002F8.vite",[215],{"title":70,"path":216,"stem":217},"\u002Fdocs\u002Fmodules\u002Fvite\u002Foverview","docs\u002F3.modules\u002F8.vite\u002F0.overview",{"title":219,"icon":56,"defaultOpen":56,"path":220,"stem":221,"children":222,"page":56},"Cache","\u002Fdocs\u002Fmodules\u002Fcache","docs\u002F3.modules\u002F9.cache",[223,226],{"title":70,"path":224,"stem":225},"\u002Fdocs\u002Fmodules\u002Fcache\u002Foverview","docs\u002F3.modules\u002F9.cache\u002F0.overview",{"title":101,"path":227,"stem":228},"\u002Fdocs\u002Fmodules\u002Fcache\u002Fapi","docs\u002F3.modules\u002F9.cache\u002F1.api",{"title":230,"icon":231,"path":232,"stem":233,"children":234,"page":56},"Deployment","i-lucide-cloud-upload","\u002Fdocs\u002Fdeployment","docs\u002F4.deployment",[235,238,242,246],{"title":70,"path":236,"stem":237},"\u002Fdocs\u002Fdeployment\u002Foverview","docs\u002F4.deployment\u002F0.overview",{"title":239,"path":240,"stem":241},"Vercel","\u002Fdocs\u002Fdeployment\u002Fvercel","docs\u002F4.deployment\u002F1.vercel",{"title":243,"path":244,"stem":245},"AWS Lambda","\u002Fdocs\u002Fdeployment\u002Faws-lambda","docs\u002F4.deployment\u002F2.aws-lambda",{"title":247,"path":248,"stem":249},"Azure Functions","\u002Fdocs\u002Fdeployment\u002Fazure-functions","docs\u002F4.deployment\u002F3.azure-functions",{"title":251,"icon":252,"path":253,"stem":254,"children":255,"page":56},"Advanced","i-lucide-brain","\u002Fdocs\u002Fadvanced","docs\u002F99.advanced",[256,260,264],{"title":257,"path":258,"stem":259},"Custom Decorator","\u002Fdocs\u002Fadvanced\u002Fcustom-decorator","docs\u002F99.advanced\u002F1.custom-decorator",{"title":261,"path":262,"stem":263},"Plugins","\u002Fdocs\u002Fadvanced\u002Fcustom-plugin","docs\u002F99.advanced\u002F2.custom-plugin",{"title":265,"path":266,"stem":267},"Custom CLI Command","\u002Fdocs\u002Fadvanced\u002Fcustom-cli-command","docs\u002F99.advanced\u002F3.custom-cli-command",[269,271,273,274,275,276,278,279,280,281,282,283,284,286,288,289,290,291,293,294,295,296,297,298,299,300,301,302,304,305,306,307,309,310,312,313,314,315,317,318,319,321,322,323,324,326,327,328,329,330,332,333,335,336,337,339,340,341,342,343,345,346,347],{"path":270},"\u002Fdocs\u002F.navigation",{"path":272},"\u002Fdocs\u002Fgetting-started\u002F.navigation",{"path":12},{"path":19},{"path":23},{"path":277},"\u002Fdocs\u002Fcore-features\u002F.navigation",{"path":34},{"path":38},{"path":42},{"path":46},{"path":50},{"path":54},{"path":285},"\u002Fdocs\u002Fmodules\u002F.navigation",{"path":287},"\u002Fdocs\u002Fmodules\u002Fauth\u002F.navigation",{"path":71},{"path":75},{"path":79},{"path":292},"\u002Fdocs\u002Fmodules\u002Fdevtools\u002F.navigation",{"path":87},{"path":90},{"path":98},{"path":102},{"path":106},{"path":114},{"path":118},{"path":122},{"path":125},{"path":303},"\u002Fdocs\u002Fmodules\u002Flogger\u002F.navigation",{"path":133},{"path":137},{"path":140},{"path":308},"\u002Fdocs\u002Fmodules\u002Fserverless\u002F.navigation",{"path":148},{"path":311},"\u002Fdocs\u002Fmodules\u002Fstorage\u002F.navigation",{"path":156},{"path":160},{"path":163},{"path":316},"\u002Fdocs\u002Fmodules\u002Fweb-sockets\u002F.navigation",{"path":171},{"path":174},{"path":320},"\u002Fdocs\u002Fmodules\u002Fschema\u002F.navigation",{"path":182},{"path":185},{"path":189},{"path":325},"\u002Fdocs\u002Fmodules\u002Fnitro\u002F.navigation",{"path":197},{"path":200},{"path":204},{"path":208},{"path":331},"\u002Fdocs\u002Fmodules\u002Fvite\u002F.navigation",{"path":216},{"path":334},"\u002Fdocs\u002Fmodules\u002Fcache\u002F.navigation",{"path":224},{"path":227},{"path":338},"\u002Fdocs\u002Fdeployment\u002F.navigation",{"path":236},{"path":240},{"path":244},{"path":248},{"path":344},"\u002Fdocs\u002Fadvanced\u002F.navigation",{"path":258},{"path":262},{"path":266},{"id":349,"title":101,"body":350,"description":3190,"extension":3191,"links":3192,"meta":3193,"navigation":60,"path":125,"seo":3194,"stem":126,"__hash__":3195},"docs\u002Fdocs\u002F3.modules\u002F12.queue\u002F3.api.md",{"type":351,"value":352,"toc":3167},"minimark",[353,358,367,513,657,660,665,668,764,777,780,783,948,959,963,966,1141,1206,1209,1315,1319,1322,1431,1435,1442,1613,1620,1635,1742,1746,1757,1893,1899,1903,1963,1977,1981,1984,2003,2007,2010,2125,2129,2136,2275,2281,2285,2288,2468,2477,2483,2486,2489,2586,2590,2593,2647,2651,2654,2687,2690,2768,2775,2779,2782,2897,2901,2911,3068,3073,3077,3084,3145,3148,3158,3163],[354,355,357],"h2",{"id":356},"queueplugin","QueuePlugin",[359,360,361,362,366],"p",{},"Binds the ",[363,364,365],"code",{},"QueueManager"," and mounts the strategies it is given.",[368,369,374],"pre",{"className":370,"code":371,"language":372,"meta":373,"style":373},"language-ts shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","app.addPlugin(QueuePlugin, {\n  autoStart: true,\n  concurrency: 1,\n  onUnhandled: 'ignore',\n  maxEvents: 50,\n  strategies: [defineQueueStrategy({ strategy: MemoryStrategy })],\n});\n","ts","",[363,375,376,402,419,433,453,466,502],{"__ignoreMap":373},[377,378,381,385,389,393,396,399],"span",{"class":379,"line":380},"line",1,[377,382,384],{"class":383},"sTEyZ","app",[377,386,388],{"class":387},"sMK4o",".",[377,390,392],{"class":391},"s2Zo4","addPlugin",[377,394,395],{"class":383},"(QueuePlugin",[377,397,398],{"class":387},",",[377,400,401],{"class":387}," {\n",[377,403,405,409,412,416],{"class":379,"line":404},2,[377,406,408],{"class":407},"swJcz","  autoStart",[377,410,411],{"class":387},":",[377,413,415],{"class":414},"sfNiH"," true",[377,417,418],{"class":387},",\n",[377,420,422,425,427,431],{"class":379,"line":421},3,[377,423,424],{"class":407},"  concurrency",[377,426,411],{"class":387},[377,428,430],{"class":429},"sbssI"," 1",[377,432,418],{"class":387},[377,434,436,439,441,444,448,451],{"class":379,"line":435},4,[377,437,438],{"class":407},"  onUnhandled",[377,440,411],{"class":387},[377,442,443],{"class":387}," '",[377,445,447],{"class":446},"sfazB","ignore",[377,449,450],{"class":387},"'",[377,452,418],{"class":387},[377,454,456,459,461,464],{"class":379,"line":455},5,[377,457,458],{"class":407},"  maxEvents",[377,460,411],{"class":387},[377,462,463],{"class":429}," 50",[377,465,418],{"class":387},[377,467,469,472,474,477,480,483,486,489,491,494,497,500],{"class":379,"line":468},6,[377,470,471],{"class":407},"  strategies",[377,473,411],{"class":387},[377,475,476],{"class":383}," [",[377,478,479],{"class":391},"defineQueueStrategy",[377,481,482],{"class":383},"(",[377,484,485],{"class":387},"{",[377,487,488],{"class":407}," strategy",[377,490,411],{"class":387},[377,492,493],{"class":383}," MemoryStrategy ",[377,495,496],{"class":387},"}",[377,498,499],{"class":383},")]",[377,501,418],{"class":387},[377,503,505,507,510],{"class":379,"line":504},7,[377,506,496],{"class":387},[377,508,509],{"class":383},")",[377,511,512],{"class":387},";\n",[514,515,516,532],"table",{},[517,518,519],"thead",{},[520,521,522,526,529],"tr",{},[523,524,525],"th",{},"Option",[523,527,528],{},"Default",[523,530,531],{},"Description",[533,534,535,559,574,589,608,623,642],"tbody",{},[520,536,537,543,548],{},[538,539,540],"td",{},[363,541,542],{},"strategies",[538,544,545],{},[363,546,547],{},"[]",[538,549,550,551,554,555,558],{},"Strategies to mount when the application boots. Wrap each entry in ",[363,552,553],{},"defineQueueStrategy()"," to have its ",[363,556,557],{},"initOptions"," checked.",[520,560,561,566,571],{},[538,562,563],{},[363,564,565],{},"autoStart",[538,567,568],{},[363,569,570],{},"true",[538,572,573],{},"Start consumers once the container is initialized. Set to false in producer-only processes.",[520,575,576,581,586],{},[538,577,578],{},[363,579,580],{},"concurrency",[538,582,583],{},[363,584,585],{},"1",[538,587,588],{},"Default jobs processed in parallel per queue.",[520,590,591,596,601],{},[538,592,593],{},[363,594,595],{},"onUnhandled",[538,597,598],{},[363,599,600],{},"'ignore'",[538,602,603,604,607],{},"What to do with a job no handler is registered for. ",[363,605,606],{},"fail"," reports it as failed so the transport can dead-letter it.",[520,609,610,615,620],{},[538,611,612],{},[363,613,614],{},"maxEvents",[538,616,617],{},[363,618,619],{},"50",[538,621,622],{},"How many processed jobs are kept for inspection.",[520,624,625,630,635],{},[538,626,627],{},[363,628,629],{},"capturePayloads",[538,631,632],{},[363,633,634],{},"false",[538,636,637,638,641],{},"Keep the payload and headers of failed attempts, so a failure can be diagnosed. ",[363,639,640],{},"@vercube\u002Fdevtools"," turns this on for the session it inspects.",[520,643,644,649,654],{},[538,645,646],{},[363,647,648],{},"maxPayloadBytes",[538,650,651],{},[363,652,653],{},"4096",[538,655,656],{},"Largest payload preview and stack trace kept, in bytes.",[354,658,365],{"id":659},"queuemanager",[661,662,664],"h3",{"id":663},"mount","mount()",[359,666,667],{},"Mounts a strategy under a name. The strategy is resolved through the container and connects when the manager starts, or on first use when it is mounted after that.",[368,669,671],{"className":370,"code":670,"language":372,"meta":373,"style":373},"await queueManager.mount({ strategy: MemoryStrategy });\nawait queueManager.mount({ name: 'events', strategy: KafkaStrategy, initOptions: { client, groupId } });\n",[363,672,673,702],{"__ignoreMap":373},[377,674,675,679,682,684,686,688,690,692,694,696,698,700],{"class":379,"line":380},[377,676,678],{"class":677},"s7zQu","await",[377,680,681],{"class":383}," queueManager",[377,683,388],{"class":387},[377,685,663],{"class":391},[377,687,482],{"class":383},[377,689,485],{"class":387},[377,691,488],{"class":407},[377,693,411],{"class":387},[377,695,493],{"class":383},[377,697,496],{"class":387},[377,699,509],{"class":383},[377,701,512],{"class":387},[377,703,704,706,708,710,712,714,716,719,721,723,726,728,730,732,734,737,739,742,744,747,750,752,755,757,760,762],{"class":379,"line":404},[377,705,678],{"class":677},[377,707,681],{"class":383},[377,709,388],{"class":387},[377,711,663],{"class":391},[377,713,482],{"class":383},[377,715,485],{"class":387},[377,717,718],{"class":407}," name",[377,720,411],{"class":387},[377,722,443],{"class":387},[377,724,725],{"class":446},"events",[377,727,450],{"class":387},[377,729,398],{"class":387},[377,731,488],{"class":407},[377,733,411],{"class":387},[377,735,736],{"class":383}," KafkaStrategy",[377,738,398],{"class":387},[377,740,741],{"class":407}," initOptions",[377,743,411],{"class":387},[377,745,746],{"class":387}," {",[377,748,749],{"class":383}," client",[377,751,398],{"class":387},[377,753,754],{"class":383}," groupId ",[377,756,496],{"class":387},[377,758,759],{"class":387}," }",[377,761,509],{"class":383},[377,763,512],{"class":387},[359,765,766,768,769,772,773,776],{},[363,767,557],{}," is required when the strategy declares initialization options, optional when they include ",[363,770,771],{},"undefined",", and rejected when the strategy takes none. The strategy is inferred from ",[363,774,775],{},"strategy",", so passing the options of a different strategy is a compile error.",[661,778,553],{"id":779},"definequeuestrategy",[359,781,782],{},"Type checks one mount and erases its options type, so a list of mounts of different strategies stays checked.",[368,784,786],{"className":370,"code":785,"language":372,"meta":373,"style":373},"import { defineQueueStrategy } from '@vercube\u002Fqueue';\n\napp.addPlugin(QueuePlugin, {\n  strategies: [\n    defineQueueStrategy({ strategy: RabbitMQStrategy, initOptions: { url: 'amqp:\u002F\u002Flocalhost' } }),\n    defineQueueStrategy({ name: 'events', strategy: KafkaStrategy, initOptions: { client, groupId } }),\n  ],\n});\n",[363,787,788,812,817,831,840,884,932,939],{"__ignoreMap":373},[377,789,790,793,795,798,800,803,805,808,810],{"class":379,"line":380},[377,791,792],{"class":677},"import",[377,794,746],{"class":387},[377,796,797],{"class":383}," defineQueueStrategy",[377,799,759],{"class":387},[377,801,802],{"class":677}," from",[377,804,443],{"class":387},[377,806,807],{"class":446},"@vercube\u002Fqueue",[377,809,450],{"class":387},[377,811,512],{"class":387},[377,813,814],{"class":379,"line":404},[377,815,816],{"emptyLinePlaceholder":60},"\n",[377,818,819,821,823,825,827,829],{"class":379,"line":421},[377,820,384],{"class":383},[377,822,388],{"class":387},[377,824,392],{"class":391},[377,826,395],{"class":383},[377,828,398],{"class":387},[377,830,401],{"class":387},[377,832,833,835,837],{"class":379,"line":435},[377,834,471],{"class":407},[377,836,411],{"class":387},[377,838,839],{"class":383}," [\n",[377,841,842,845,847,849,851,853,856,858,860,862,864,867,869,871,874,876,878,880,882],{"class":379,"line":455},[377,843,844],{"class":391},"    defineQueueStrategy",[377,846,482],{"class":383},[377,848,485],{"class":387},[377,850,488],{"class":407},[377,852,411],{"class":387},[377,854,855],{"class":383}," RabbitMQStrategy",[377,857,398],{"class":387},[377,859,741],{"class":407},[377,861,411],{"class":387},[377,863,746],{"class":387},[377,865,866],{"class":407}," url",[377,868,411],{"class":387},[377,870,443],{"class":387},[377,872,873],{"class":446},"amqp:\u002F\u002Flocalhost",[377,875,450],{"class":387},[377,877,759],{"class":387},[377,879,759],{"class":387},[377,881,509],{"class":383},[377,883,418],{"class":387},[377,885,886,888,890,892,894,896,898,900,902,904,906,908,910,912,914,916,918,920,922,924,926,928,930],{"class":379,"line":468},[377,887,844],{"class":391},[377,889,482],{"class":383},[377,891,485],{"class":387},[377,893,718],{"class":407},[377,895,411],{"class":387},[377,897,443],{"class":387},[377,899,725],{"class":446},[377,901,450],{"class":387},[377,903,398],{"class":387},[377,905,488],{"class":407},[377,907,411],{"class":387},[377,909,736],{"class":383},[377,911,398],{"class":387},[377,913,741],{"class":407},[377,915,411],{"class":387},[377,917,746],{"class":387},[377,919,749],{"class":383},[377,921,398],{"class":387},[377,923,754],{"class":383},[377,925,496],{"class":387},[377,927,759],{"class":387},[377,929,509],{"class":383},[377,931,418],{"class":387},[377,933,934,937],{"class":379,"line":504},[377,935,936],{"class":383},"  ]",[377,938,418],{"class":387},[377,940,942,944,946],{"class":379,"line":941},8,[377,943,496],{"class":387},[377,945,509],{"class":383},[377,947,512],{"class":387},[949,950,951],"note",{},[359,952,953,955,956,958],{},[363,954,664],{}," checks ",[363,957,557],{}," on its own, because it infers the strategy from its argument. A plain array cannot: every entry holds a different strategy, and there is no inference site per entry. This helper is that site, and it compiles away to the object you passed it.",[661,960,962],{"id":961},"add","add()",[359,964,965],{},"Adds a single job to a queue.",[368,967,969],{"className":370,"code":968,"language":372,"meta":373,"style":373},"const ref = await queueManager.add({\n  queue: 'emails',\n  job: 'welcome',\n  payload: { userId: '1' },\n  options: { attempts: 3, backoff: { type: 'exponential', delay: 1000 }, delay: 5000 },\n});\n\nref.id; \u002F\u002F job id, as assigned by the transport\n",[363,970,971,997,1013,1029,1052,1112,1120,1124],{"__ignoreMap":373},[377,972,973,977,980,983,986,988,990,992,994],{"class":379,"line":380},[377,974,976],{"class":975},"spNyl","const",[377,978,979],{"class":383}," ref ",[377,981,982],{"class":387},"=",[377,984,985],{"class":677}," await",[377,987,681],{"class":383},[377,989,388],{"class":387},[377,991,961],{"class":391},[377,993,482],{"class":383},[377,995,996],{"class":387},"{\n",[377,998,999,1002,1004,1006,1009,1011],{"class":379,"line":404},[377,1000,1001],{"class":407},"  queue",[377,1003,411],{"class":387},[377,1005,443],{"class":387},[377,1007,1008],{"class":446},"emails",[377,1010,450],{"class":387},[377,1012,418],{"class":387},[377,1014,1015,1018,1020,1022,1025,1027],{"class":379,"line":421},[377,1016,1017],{"class":407},"  job",[377,1019,411],{"class":387},[377,1021,443],{"class":387},[377,1023,1024],{"class":446},"welcome",[377,1026,450],{"class":387},[377,1028,418],{"class":387},[377,1030,1031,1034,1036,1038,1041,1043,1045,1047,1049],{"class":379,"line":435},[377,1032,1033],{"class":407},"  payload",[377,1035,411],{"class":387},[377,1037,746],{"class":387},[377,1039,1040],{"class":407}," userId",[377,1042,411],{"class":387},[377,1044,443],{"class":387},[377,1046,585],{"class":446},[377,1048,450],{"class":387},[377,1050,1051],{"class":387}," },\n",[377,1053,1054,1057,1059,1061,1064,1066,1069,1071,1074,1076,1078,1081,1083,1085,1088,1090,1092,1095,1097,1100,1103,1105,1107,1110],{"class":379,"line":455},[377,1055,1056],{"class":407},"  options",[377,1058,411],{"class":387},[377,1060,746],{"class":387},[377,1062,1063],{"class":407}," attempts",[377,1065,411],{"class":387},[377,1067,1068],{"class":429}," 3",[377,1070,398],{"class":387},[377,1072,1073],{"class":407}," backoff",[377,1075,411],{"class":387},[377,1077,746],{"class":387},[377,1079,1080],{"class":407}," type",[377,1082,411],{"class":387},[377,1084,443],{"class":387},[377,1086,1087],{"class":446},"exponential",[377,1089,450],{"class":387},[377,1091,398],{"class":387},[377,1093,1094],{"class":407}," delay",[377,1096,411],{"class":387},[377,1098,1099],{"class":429}," 1000",[377,1101,1102],{"class":387}," },",[377,1104,1094],{"class":407},[377,1106,411],{"class":387},[377,1108,1109],{"class":429}," 5000",[377,1111,1051],{"class":387},[377,1113,1114,1116,1118],{"class":379,"line":468},[377,1115,496],{"class":387},[377,1117,509],{"class":383},[377,1119,512],{"class":387},[377,1121,1122],{"class":379,"line":504},[377,1123,816],{"emptyLinePlaceholder":60},[377,1125,1126,1129,1131,1134,1137],{"class":379,"line":941},[377,1127,1128],{"class":383},"ref",[377,1130,388],{"class":387},[377,1132,1133],{"class":383},"id",[377,1135,1136],{"class":387},";",[377,1138,1140],{"class":1139},"sHwdD"," \u002F\u002F job id, as assigned by the transport\n",[514,1142,1143,1152],{},[517,1144,1145],{},[520,1146,1147,1150],{},[523,1148,1149],{},"Field",[523,1151,531],{},[533,1153,1154,1164,1174,1184,1196],{},[520,1155,1156,1161],{},[538,1157,1158],{},[363,1159,1160],{},"queue",[538,1162,1163],{},"Queue the job is added to.",[520,1165,1166,1171],{},[538,1167,1168],{},[363,1169,1170],{},"job",[538,1172,1173],{},"Name of the job, used to pick the handler.",[520,1175,1176,1181],{},[538,1177,1178],{},[363,1179,1180],{},"payload",[538,1182,1183],{},"Payload handed to the handler. Must survive JSON serialization.",[520,1185,1186,1190],{},[538,1187,1188],{},[363,1189,775],{},[538,1191,1192,1193,388],{},"Mounted strategy to publish through. Defaults to ",[363,1194,1195],{},"default",[520,1197,1198,1203],{},[538,1199,1200],{},[363,1201,1202],{},"options",[538,1204,1205],{},"Per-job options, described below.",[359,1207,1208],{},"Job options:",[514,1210,1211,1219],{},[517,1212,1213],{},[520,1214,1215,1217],{},[523,1216,525],{},[523,1218,531],{},[533,1220,1221,1231,1245,1255,1265,1275,1285,1295,1305],{},[520,1222,1223,1228],{},[538,1224,1225],{},[363,1226,1227],{},"attempts",[538,1229,1230],{},"Total attempts, the first one included.",[520,1232,1233,1238],{},[538,1234,1235],{},[363,1236,1237],{},"backoff",[538,1239,1240,1241,1244],{},"Delay between attempts. A number is fixed milliseconds, ",[363,1242,1243],{},"{ type: 'exponential', delay }"," doubles it every attempt.",[520,1246,1247,1252],{},[538,1248,1249],{},[363,1250,1251],{},"delay",[538,1253,1254],{},"Milliseconds before the job becomes available.",[520,1256,1257,1262],{},[538,1258,1259],{},[363,1260,1261],{},"priority",[538,1263,1264],{},"Lower values are processed first.",[520,1266,1267,1272],{},[538,1268,1269],{},[363,1270,1271],{},"jobId",[538,1273,1274],{},"Explicit id, used by transports that deduplicate on it.",[520,1276,1277,1282],{},[538,1278,1279],{},[363,1280,1281],{},"key",[538,1283,1284],{},"Routing or partition key, keeping related jobs ordered on Kafka and RabbitMQ.",[520,1286,1287,1292],{},[538,1288,1289],{},[363,1290,1291],{},"headers",[538,1293,1294],{},"Extra transport headers travelling with the job.",[520,1296,1297,1302],{},[538,1298,1299],{},[363,1300,1301],{},"removeOnComplete",[538,1303,1304],{},"Whether completed jobs are kept, or how many, on transports that store history.",[520,1306,1307,1312],{},[538,1308,1309],{},[363,1310,1311],{},"removeOnFail",[538,1313,1314],{},"Whether failed jobs are kept, or how many, on transports that store history.",[661,1316,1318],{"id":1317},"addmany","addMany()",[359,1320,1321],{},"Adds many jobs of the same kind, using the transport's batch API when it has one.",[368,1323,1325],{"className":370,"code":1324,"language":372,"meta":373,"style":373},"await queueManager.addMany({\n  queue: 'emails',\n  job: 'digest',\n  payloads: users.map((user) => ({ userId: user.id })),\n});\n",[363,1326,1327,1342,1356,1371,1423],{"__ignoreMap":373},[377,1328,1329,1331,1333,1335,1338,1340],{"class":379,"line":380},[377,1330,678],{"class":677},[377,1332,681],{"class":383},[377,1334,388],{"class":387},[377,1336,1337],{"class":391},"addMany",[377,1339,482],{"class":383},[377,1341,996],{"class":387},[377,1343,1344,1346,1348,1350,1352,1354],{"class":379,"line":404},[377,1345,1001],{"class":407},[377,1347,411],{"class":387},[377,1349,443],{"class":387},[377,1351,1008],{"class":446},[377,1353,450],{"class":387},[377,1355,418],{"class":387},[377,1357,1358,1360,1362,1364,1367,1369],{"class":379,"line":421},[377,1359,1017],{"class":407},[377,1361,411],{"class":387},[377,1363,443],{"class":387},[377,1365,1366],{"class":446},"digest",[377,1368,450],{"class":387},[377,1370,418],{"class":387},[377,1372,1373,1376,1378,1381,1383,1386,1388,1390,1394,1396,1399,1402,1404,1406,1408,1411,1413,1416,1418,1421],{"class":379,"line":435},[377,1374,1375],{"class":407},"  payloads",[377,1377,411],{"class":387},[377,1379,1380],{"class":383}," users",[377,1382,388],{"class":387},[377,1384,1385],{"class":391},"map",[377,1387,482],{"class":383},[377,1389,482],{"class":387},[377,1391,1393],{"class":1392},"sHdIc","user",[377,1395,509],{"class":387},[377,1397,1398],{"class":975}," =>",[377,1400,1401],{"class":383}," (",[377,1403,485],{"class":387},[377,1405,1040],{"class":407},[377,1407,411],{"class":387},[377,1409,1410],{"class":383}," user",[377,1412,388],{"class":387},[377,1414,1415],{"class":383},"id ",[377,1417,496],{"class":387},[377,1419,1420],{"class":383},"))",[377,1422,418],{"class":387},[377,1424,1425,1427,1429],{"class":379,"line":455},[377,1426,496],{"class":387},[377,1428,509],{"class":383},[377,1430,512],{"class":387},[661,1432,1434],{"id":1433},"registerconsumer","registerConsumer()",[359,1436,1437,1438,1441],{},"Registers a job handler. This is what ",[363,1439,1440],{},"@Job()"," calls.",[368,1443,1445],{"className":370,"code":1444,"language":372,"meta":373,"style":373},"queueManager.registerConsumer({\n  strategy: 'default',\n  queue: 'emails',\n  job: 'welcome',\n  handler: async (payload, context) => mailer.send(payload),\n  options: { attempts: 3, timeout: 10_000, schema: WelcomeSchema },\n  concurrency: 5,\n  source: 'EmailConsumer.welcome',\n});\n",[363,1446,1447,1461,1476,1490,1504,1540,1577,1588,1604],{"__ignoreMap":373},[377,1448,1449,1452,1454,1457,1459],{"class":379,"line":380},[377,1450,1451],{"class":383},"queueManager",[377,1453,388],{"class":387},[377,1455,1456],{"class":391},"registerConsumer",[377,1458,482],{"class":383},[377,1460,996],{"class":387},[377,1462,1463,1466,1468,1470,1472,1474],{"class":379,"line":404},[377,1464,1465],{"class":407},"  strategy",[377,1467,411],{"class":387},[377,1469,443],{"class":387},[377,1471,1195],{"class":446},[377,1473,450],{"class":387},[377,1475,418],{"class":387},[377,1477,1478,1480,1482,1484,1486,1488],{"class":379,"line":421},[377,1479,1001],{"class":407},[377,1481,411],{"class":387},[377,1483,443],{"class":387},[377,1485,1008],{"class":446},[377,1487,450],{"class":387},[377,1489,418],{"class":387},[377,1491,1492,1494,1496,1498,1500,1502],{"class":379,"line":435},[377,1493,1017],{"class":407},[377,1495,411],{"class":387},[377,1497,443],{"class":387},[377,1499,1024],{"class":446},[377,1501,450],{"class":387},[377,1503,418],{"class":387},[377,1505,1506,1509,1511,1514,1516,1518,1520,1523,1525,1527,1530,1532,1535,1538],{"class":379,"line":455},[377,1507,1508],{"class":391},"  handler",[377,1510,411],{"class":387},[377,1512,1513],{"class":975}," async",[377,1515,1401],{"class":387},[377,1517,1180],{"class":1392},[377,1519,398],{"class":387},[377,1521,1522],{"class":1392}," context",[377,1524,509],{"class":387},[377,1526,1398],{"class":975},[377,1528,1529],{"class":383}," mailer",[377,1531,388],{"class":387},[377,1533,1534],{"class":391},"send",[377,1536,1537],{"class":383},"(payload)",[377,1539,418],{"class":387},[377,1541,1542,1544,1546,1548,1550,1552,1554,1556,1559,1561,1564,1566,1569,1571,1574],{"class":379,"line":468},[377,1543,1056],{"class":407},[377,1545,411],{"class":387},[377,1547,746],{"class":387},[377,1549,1063],{"class":407},[377,1551,411],{"class":387},[377,1553,1068],{"class":429},[377,1555,398],{"class":387},[377,1557,1558],{"class":407}," timeout",[377,1560,411],{"class":387},[377,1562,1563],{"class":429}," 10_000",[377,1565,398],{"class":387},[377,1567,1568],{"class":407}," schema",[377,1570,411],{"class":387},[377,1572,1573],{"class":383}," WelcomeSchema ",[377,1575,1576],{"class":387},"},\n",[377,1578,1579,1581,1583,1586],{"class":379,"line":504},[377,1580,424],{"class":407},[377,1582,411],{"class":387},[377,1584,1585],{"class":429}," 5",[377,1587,418],{"class":387},[377,1589,1590,1593,1595,1597,1600,1602],{"class":379,"line":941},[377,1591,1592],{"class":407},"  source",[377,1594,411],{"class":387},[377,1596,443],{"class":387},[377,1598,1599],{"class":446},"EmailConsumer.welcome",[377,1601,450],{"class":387},[377,1603,418],{"class":387},[377,1605,1607,1609,1611],{"class":379,"line":1606},9,[377,1608,496],{"class":387},[377,1610,509],{"class":383},[377,1612,512],{"class":387},[359,1614,1615,1616,1619],{},"Throws when a handler for the same job of the same queue already exists. Use ",[363,1617,1618],{},"unregisterConsumer({ strategy, queue, job })"," to remove one, which also stops the consumer once the queue has no handler left.",[359,1621,1622,1623,1626,1627,1630,1631,1634],{},"Registering under the job name ",[363,1624,1625],{},"*"," makes the handler the fallback of its queue, which is what ",[363,1628,1629],{},"@AnyJob()"," does. The exported ",[363,1632,1633],{},"WILDCARD_JOB"," constant holds that name, so nothing has to be spelled out by hand:",[368,1636,1638],{"className":370,"code":1637,"language":372,"meta":373,"style":373},"import { WILDCARD_JOB } from '@vercube\u002Fqueue';\n\nqueueManager.registerConsumer({ strategy: 'default', queue: 'events', job: WILDCARD_JOB, handler, options: {}, source: 'ingest' });\n",[363,1639,1640,1661,1665],{"__ignoreMap":373},[377,1641,1642,1644,1646,1649,1651,1653,1655,1657,1659],{"class":379,"line":380},[377,1643,792],{"class":677},[377,1645,746],{"class":387},[377,1647,1648],{"class":383}," WILDCARD_JOB",[377,1650,759],{"class":387},[377,1652,802],{"class":677},[377,1654,443],{"class":387},[377,1656,807],{"class":446},[377,1658,450],{"class":387},[377,1660,512],{"class":387},[377,1662,1663],{"class":379,"line":404},[377,1664,816],{"emptyLinePlaceholder":60},[377,1666,1667,1669,1671,1673,1675,1677,1679,1681,1683,1685,1687,1689,1692,1694,1696,1698,1700,1702,1705,1707,1709,1711,1714,1716,1719,1721,1724,1727,1729,1731,1734,1736,1738,1740],{"class":379,"line":421},[377,1668,1451],{"class":383},[377,1670,388],{"class":387},[377,1672,1456],{"class":391},[377,1674,482],{"class":383},[377,1676,485],{"class":387},[377,1678,488],{"class":407},[377,1680,411],{"class":387},[377,1682,443],{"class":387},[377,1684,1195],{"class":446},[377,1686,450],{"class":387},[377,1688,398],{"class":387},[377,1690,1691],{"class":407}," queue",[377,1693,411],{"class":387},[377,1695,443],{"class":387},[377,1697,725],{"class":446},[377,1699,450],{"class":387},[377,1701,398],{"class":387},[377,1703,1704],{"class":407}," job",[377,1706,411],{"class":387},[377,1708,1648],{"class":383},[377,1710,398],{"class":387},[377,1712,1713],{"class":383}," handler",[377,1715,398],{"class":387},[377,1717,1718],{"class":407}," options",[377,1720,411],{"class":387},[377,1722,1723],{"class":387}," {},",[377,1725,1726],{"class":407}," source",[377,1728,411],{"class":387},[377,1730,443],{"class":387},[377,1732,1733],{"class":446},"ingest",[377,1735,450],{"class":387},[377,1737,759],{"class":387},[377,1739,509],{"class":383},[377,1741,512],{"class":387},[661,1743,1745],{"id":1744},"registerhook","registerHook()",[359,1747,1748,1749,1752,1753,1756],{},"Registers a lifecycle hook. This is what ",[363,1750,1751],{},"@OnJobCompleted()"," and ",[363,1754,1755],{},"@OnJobFailed()"," call.",[368,1758,1760],{"className":370,"code":1759,"language":372,"meta":373,"style":373},"queueManager.registerHook('failed', {\n  strategy: 'default',\n  queue: 'emails',\n  job: 'welcome',\n  hook: async (error, context) => alerts.report(error, context.id),\n  source: 'EmailConsumer.failed',\n});\n",[363,1761,1762,1784,1798,1812,1826,1870,1885],{"__ignoreMap":373},[377,1763,1764,1766,1768,1771,1773,1775,1778,1780,1782],{"class":379,"line":380},[377,1765,1451],{"class":383},[377,1767,388],{"class":387},[377,1769,1770],{"class":391},"registerHook",[377,1772,482],{"class":383},[377,1774,450],{"class":387},[377,1776,1777],{"class":446},"failed",[377,1779,450],{"class":387},[377,1781,398],{"class":387},[377,1783,401],{"class":387},[377,1785,1786,1788,1790,1792,1794,1796],{"class":379,"line":404},[377,1787,1465],{"class":407},[377,1789,411],{"class":387},[377,1791,443],{"class":387},[377,1793,1195],{"class":446},[377,1795,450],{"class":387},[377,1797,418],{"class":387},[377,1799,1800,1802,1804,1806,1808,1810],{"class":379,"line":421},[377,1801,1001],{"class":407},[377,1803,411],{"class":387},[377,1805,443],{"class":387},[377,1807,1008],{"class":446},[377,1809,450],{"class":387},[377,1811,418],{"class":387},[377,1813,1814,1816,1818,1820,1822,1824],{"class":379,"line":435},[377,1815,1017],{"class":407},[377,1817,411],{"class":387},[377,1819,443],{"class":387},[377,1821,1024],{"class":446},[377,1823,450],{"class":387},[377,1825,418],{"class":387},[377,1827,1828,1831,1833,1835,1837,1840,1842,1844,1846,1848,1851,1853,1856,1859,1861,1863,1865,1868],{"class":379,"line":455},[377,1829,1830],{"class":391},"  hook",[377,1832,411],{"class":387},[377,1834,1513],{"class":975},[377,1836,1401],{"class":387},[377,1838,1839],{"class":1392},"error",[377,1841,398],{"class":387},[377,1843,1522],{"class":1392},[377,1845,509],{"class":387},[377,1847,1398],{"class":975},[377,1849,1850],{"class":383}," alerts",[377,1852,388],{"class":387},[377,1854,1855],{"class":391},"report",[377,1857,1858],{"class":383},"(error",[377,1860,398],{"class":387},[377,1862,1522],{"class":383},[377,1864,388],{"class":387},[377,1866,1867],{"class":383},"id)",[377,1869,418],{"class":387},[377,1871,1872,1874,1876,1878,1881,1883],{"class":379,"line":468},[377,1873,1592],{"class":407},[377,1875,411],{"class":387},[377,1877,443],{"class":387},[377,1879,1880],{"class":446},"EmailConsumer.failed",[377,1882,450],{"class":387},[377,1884,418],{"class":387},[377,1886,1887,1889,1891],{"class":379,"line":504},[377,1888,496],{"class":387},[377,1890,509],{"class":383},[377,1892,512],{"class":387},[359,1894,1895,1898],{},[363,1896,1897],{},"unregisterHook(event, registration)"," removes it again, given the very registration that was registered.",[661,1900,1902],{"id":1901},"start-stop-and-close","start(), stop() and close()",[368,1904,1906],{"className":370,"code":1905,"language":372,"meta":373,"style":373},"await queueManager.start(); \u002F\u002F connect every strategy and consume every queue that has a handler\nawait queueManager.stop();  \u002F\u002F stop consumers, keep connections open so publishing still works\nawait queueManager.close(); \u002F\u002F stop consumers and close every connection\n",[363,1907,1908,1927,1945],{"__ignoreMap":373},[377,1909,1910,1912,1914,1916,1919,1922,1924],{"class":379,"line":380},[377,1911,678],{"class":677},[377,1913,681],{"class":383},[377,1915,388],{"class":387},[377,1917,1918],{"class":391},"start",[377,1920,1921],{"class":383},"()",[377,1923,1136],{"class":387},[377,1925,1926],{"class":1139}," \u002F\u002F connect every strategy and consume every queue that has a handler\n",[377,1928,1929,1931,1933,1935,1938,1940,1942],{"class":379,"line":404},[377,1930,678],{"class":677},[377,1932,681],{"class":383},[377,1934,388],{"class":387},[377,1936,1937],{"class":391},"stop",[377,1939,1921],{"class":383},[377,1941,1136],{"class":387},[377,1943,1944],{"class":1139},"  \u002F\u002F stop consumers, keep connections open so publishing still works\n",[377,1946,1947,1949,1951,1953,1956,1958,1960],{"class":379,"line":421},[377,1948,678],{"class":677},[377,1950,681],{"class":383},[377,1952,388],{"class":387},[377,1954,1955],{"class":391},"close",[377,1957,1921],{"class":383},[377,1959,1136],{"class":387},[377,1961,1962],{"class":1139}," \u002F\u002F stop consumers and close every connection\n",[359,1964,1965,1966,1969,1970,1972,1973,1976],{},"All three are safe to call more than once. ",[363,1967,1968],{},"start()"," runs automatically after the container is initialized unless ",[363,1971,565],{}," is false, and ",[363,1974,1975],{},"close()"," runs when the container is torn down.",[661,1978,1980],{"id":1979},"drain","drain()",[359,1982,1983],{},"Waits for the work the manager scheduled in the background: consumers starting or stopping, and retries waiting for their backoff. Useful in tests and before a deliberate shutdown.",[368,1985,1987],{"className":370,"code":1986,"language":372,"meta":373,"style":373},"await queueManager.drain();\n",[363,1988,1989],{"__ignoreMap":373},[377,1990,1991,1993,1995,1997,1999,2001],{"class":379,"line":380},[377,1992,678],{"class":677},[377,1994,681],{"class":383},[377,1996,388],{"class":387},[377,1998,1979],{"class":391},[377,2000,1921],{"class":383},[377,2002,512],{"class":387},[661,2004,2006],{"id":2005},"stats","stats()",[359,2008,2009],{},"Reads the counters a transport keeps for a queue. Transports that keep none return an empty object.",[368,2011,2013],{"className":370,"code":2012,"language":372,"meta":373,"style":373},"const stats = await queueManager.stats({ queue: 'emails' });\n\nstats.waiting;   \u002F\u002F jobs waiting to be processed\nstats.active;    \u002F\u002F jobs being processed\nstats.completed; \u002F\u002F completed jobs, on transports that store history\nstats.failed;    \u002F\u002F jobs that exhausted their attempts\nstats.delayed;   \u002F\u002F jobs waiting for their delay\n",[363,2014,2015,2052,2056,2070,2084,2098,2111],{"__ignoreMap":373},[377,2016,2017,2019,2022,2024,2026,2028,2030,2032,2034,2036,2038,2040,2042,2044,2046,2048,2050],{"class":379,"line":380},[377,2018,976],{"class":975},[377,2020,2021],{"class":383}," stats ",[377,2023,982],{"class":387},[377,2025,985],{"class":677},[377,2027,681],{"class":383},[377,2029,388],{"class":387},[377,2031,2005],{"class":391},[377,2033,482],{"class":383},[377,2035,485],{"class":387},[377,2037,1691],{"class":407},[377,2039,411],{"class":387},[377,2041,443],{"class":387},[377,2043,1008],{"class":446},[377,2045,450],{"class":387},[377,2047,759],{"class":387},[377,2049,509],{"class":383},[377,2051,512],{"class":387},[377,2053,2054],{"class":379,"line":404},[377,2055,816],{"emptyLinePlaceholder":60},[377,2057,2058,2060,2062,2065,2067],{"class":379,"line":421},[377,2059,2005],{"class":383},[377,2061,388],{"class":387},[377,2063,2064],{"class":383},"waiting",[377,2066,1136],{"class":387},[377,2068,2069],{"class":1139},"   \u002F\u002F jobs waiting to be processed\n",[377,2071,2072,2074,2076,2079,2081],{"class":379,"line":435},[377,2073,2005],{"class":383},[377,2075,388],{"class":387},[377,2077,2078],{"class":383},"active",[377,2080,1136],{"class":387},[377,2082,2083],{"class":1139},"    \u002F\u002F jobs being processed\n",[377,2085,2086,2088,2090,2093,2095],{"class":379,"line":455},[377,2087,2005],{"class":383},[377,2089,388],{"class":387},[377,2091,2092],{"class":383},"completed",[377,2094,1136],{"class":387},[377,2096,2097],{"class":1139}," \u002F\u002F completed jobs, on transports that store history\n",[377,2099,2100,2102,2104,2106,2108],{"class":379,"line":468},[377,2101,2005],{"class":383},[377,2103,388],{"class":387},[377,2105,1777],{"class":383},[377,2107,1136],{"class":387},[377,2109,2110],{"class":1139},"    \u002F\u002F jobs that exhausted their attempts\n",[377,2112,2113,2115,2117,2120,2122],{"class":379,"line":504},[377,2114,2005],{"class":383},[377,2116,388],{"class":387},[377,2118,2119],{"class":383},"delayed",[377,2121,1136],{"class":387},[377,2123,2124],{"class":1139},"   \u002F\u002F jobs waiting for their delay\n",[661,2126,2128],{"id":2127},"subscribe","subscribe()",[359,2130,2131,2132,2135],{},"Follows every job the manager finishes, as it finishes it, instead of polling\n",[363,2133,2134],{},"inspect()",". This is how the devtools panel stays live.",[368,2137,2139],{"className":370,"code":2138,"language":372,"meta":373,"style":373},"const stop = queueManager.subscribe((event) => {\n  if (event.status === 'failed') {\n    metrics.increment(`queue.${event.queue}.${event.job}.failed`);\n  }\n});\n\nstop(); \u002F\u002F removes the listener again\n",[363,2140,2141,2169,2197,2247,2252,2260,2264],{"__ignoreMap":373},[377,2142,2143,2145,2148,2150,2152,2154,2156,2158,2160,2163,2165,2167],{"class":379,"line":380},[377,2144,976],{"class":975},[377,2146,2147],{"class":383}," stop ",[377,2149,982],{"class":387},[377,2151,681],{"class":383},[377,2153,388],{"class":387},[377,2155,2127],{"class":391},[377,2157,482],{"class":383},[377,2159,482],{"class":387},[377,2161,2162],{"class":1392},"event",[377,2164,509],{"class":387},[377,2166,1398],{"class":975},[377,2168,401],{"class":387},[377,2170,2171,2174,2176,2178,2180,2183,2186,2188,2190,2192,2195],{"class":379,"line":404},[377,2172,2173],{"class":677},"  if",[377,2175,1401],{"class":407},[377,2177,2162],{"class":383},[377,2179,388],{"class":387},[377,2181,2182],{"class":383},"status",[377,2184,2185],{"class":387}," ===",[377,2187,443],{"class":387},[377,2189,1777],{"class":446},[377,2191,450],{"class":387},[377,2193,2194],{"class":407},") ",[377,2196,996],{"class":387},[377,2198,2199,2202,2204,2207,2209,2212,2215,2218,2220,2222,2224,2226,2228,2230,2232,2234,2236,2238,2241,2243,2245],{"class":379,"line":421},[377,2200,2201],{"class":383},"    metrics",[377,2203,388],{"class":387},[377,2205,2206],{"class":391},"increment",[377,2208,482],{"class":407},[377,2210,2211],{"class":387},"`",[377,2213,2214],{"class":446},"queue.",[377,2216,2217],{"class":387},"${",[377,2219,2162],{"class":383},[377,2221,388],{"class":387},[377,2223,1160],{"class":383},[377,2225,496],{"class":387},[377,2227,388],{"class":446},[377,2229,2217],{"class":387},[377,2231,2162],{"class":383},[377,2233,388],{"class":387},[377,2235,1170],{"class":383},[377,2237,496],{"class":387},[377,2239,2240],{"class":446},".failed",[377,2242,2211],{"class":387},[377,2244,509],{"class":407},[377,2246,512],{"class":387},[377,2248,2249],{"class":379,"line":435},[377,2250,2251],{"class":387},"  }\n",[377,2253,2254,2256,2258],{"class":379,"line":455},[377,2255,496],{"class":387},[377,2257,509],{"class":383},[377,2259,512],{"class":387},[377,2261,2262],{"class":379,"line":468},[377,2263,816],{"emptyLinePlaceholder":60},[377,2265,2266,2268,2270,2272],{"class":379,"line":504},[377,2267,1937],{"class":391},[377,2269,1921],{"class":383},[377,2271,1136],{"class":387},[377,2273,2274],{"class":1139}," \u002F\u002F removes the listener again\n",[359,2276,2277,2278,2280],{},"The listener gets the same event the inspection buffer keeps, so it carries the\noutcome, the attempt, the duration and, for a failure, the error with its stack.\nIt is called even when ",[363,2279,614],{}," is 0, so a live view keeps working without any\nbuffer at all. A listener that throws is logged and kept, and never changes the\noutcome of the job.",[661,2282,2284],{"id":2283},"peek","peek()",[359,2286,2287],{},"Shows what a queue is holding, without consuming any of it.",[368,2289,2291],{"className":370,"code":2290,"language":372,"meta":373,"style":373},"const messages = await queueManager.peek({ queue: 'emails', limit: 25, states: ['waiting', 'delayed', 'failed'] });\n\nmessages[0].state;      \u002F\u002F 'waiting', 'active', 'delayed' or 'failed'\nmessages[0].job;        \u002F\u002F name of the job\nmessages[0].payload;    \u002F\u002F preview, with credential-looking fields withheld\nmessages[0].availableAt; \u002F\u002F when a delayed message becomes available\nmessages[0].error;      \u002F\u002F why it failed, for a message in a failed set\n",[363,2292,2293,2374,2378,2399,2416,2433,2451],{"__ignoreMap":373},[377,2294,2295,2297,2300,2302,2304,2306,2308,2310,2312,2314,2316,2318,2320,2322,2324,2326,2329,2331,2334,2336,2339,2341,2343,2345,2347,2349,2351,2353,2355,2357,2359,2361,2363,2365,2368,2370,2372],{"class":379,"line":380},[377,2296,976],{"class":975},[377,2298,2299],{"class":383}," messages ",[377,2301,982],{"class":387},[377,2303,985],{"class":677},[377,2305,681],{"class":383},[377,2307,388],{"class":387},[377,2309,2283],{"class":391},[377,2311,482],{"class":383},[377,2313,485],{"class":387},[377,2315,1691],{"class":407},[377,2317,411],{"class":387},[377,2319,443],{"class":387},[377,2321,1008],{"class":446},[377,2323,450],{"class":387},[377,2325,398],{"class":387},[377,2327,2328],{"class":407}," limit",[377,2330,411],{"class":387},[377,2332,2333],{"class":429}," 25",[377,2335,398],{"class":387},[377,2337,2338],{"class":407}," states",[377,2340,411],{"class":387},[377,2342,476],{"class":383},[377,2344,450],{"class":387},[377,2346,2064],{"class":446},[377,2348,450],{"class":387},[377,2350,398],{"class":387},[377,2352,443],{"class":387},[377,2354,2119],{"class":446},[377,2356,450],{"class":387},[377,2358,398],{"class":387},[377,2360,443],{"class":387},[377,2362,1777],{"class":446},[377,2364,450],{"class":387},[377,2366,2367],{"class":383},"] ",[377,2369,496],{"class":387},[377,2371,509],{"class":383},[377,2373,512],{"class":387},[377,2375,2376],{"class":379,"line":404},[377,2377,816],{"emptyLinePlaceholder":60},[377,2379,2380,2383,2386,2389,2391,2394,2396],{"class":379,"line":421},[377,2381,2382],{"class":383},"messages[",[377,2384,2385],{"class":429},"0",[377,2387,2388],{"class":383},"]",[377,2390,388],{"class":387},[377,2392,2393],{"class":383},"state",[377,2395,1136],{"class":387},[377,2397,2398],{"class":1139},"      \u002F\u002F 'waiting', 'active', 'delayed' or 'failed'\n",[377,2400,2401,2403,2405,2407,2409,2411,2413],{"class":379,"line":435},[377,2402,2382],{"class":383},[377,2404,2385],{"class":429},[377,2406,2388],{"class":383},[377,2408,388],{"class":387},[377,2410,1170],{"class":383},[377,2412,1136],{"class":387},[377,2414,2415],{"class":1139},"        \u002F\u002F name of the job\n",[377,2417,2418,2420,2422,2424,2426,2428,2430],{"class":379,"line":455},[377,2419,2382],{"class":383},[377,2421,2385],{"class":429},[377,2423,2388],{"class":383},[377,2425,388],{"class":387},[377,2427,1180],{"class":383},[377,2429,1136],{"class":387},[377,2431,2432],{"class":1139},"    \u002F\u002F preview, with credential-looking fields withheld\n",[377,2434,2435,2437,2439,2441,2443,2446,2448],{"class":379,"line":468},[377,2436,2382],{"class":383},[377,2438,2385],{"class":429},[377,2440,2388],{"class":383},[377,2442,388],{"class":387},[377,2444,2445],{"class":383},"availableAt",[377,2447,1136],{"class":387},[377,2449,2450],{"class":1139}," \u002F\u002F when a delayed message becomes available\n",[377,2452,2453,2455,2457,2459,2461,2463,2465],{"class":379,"line":504},[377,2454,2382],{"class":383},[377,2456,2385],{"class":429},[377,2458,2388],{"class":383},[377,2460,388],{"class":387},[377,2462,1839],{"class":383},[377,2464,1136],{"class":387},[377,2466,2467],{"class":1139},"      \u002F\u002F why it failed, for a message in a failed set\n",[359,2469,2470,2471,2473,2474,2476],{},"Only transports that can be read without side effects support this, which they\nreport as the ",[363,2472,2283],{}," capability: memory and BullMQ do, RabbitMQ and Kafka do not\nand return nothing. On BullMQ the ",[363,2475,1777],{}," set is the interesting one, because\nRedis keeps both the data and the stack trace of every job that ran out of attempts.",[2478,2479,2480],"warning",{},[359,2481,2482],{},"Peeking RabbitMQ would mean taking delivery of a message and putting it back,\nwhich changes delivery counts, can reorder the queue and competes with the running\nconsumer. The module reports the limit instead of quietly perturbing your queue.",[661,2484,2134],{"id":2485},"inspect",[359,2487,2488],{},"Describes what the module holds: mounted strategies, registered handlers, per-queue counters and the last processed jobs. This is what the devtools panel reads.",[368,2490,2492],{"className":370,"code":2491,"language":372,"meta":373,"style":373},"const snapshot = queueManager.inspect();\n\nsnapshot.started;    \u002F\u002F whether consumers are running\nsnapshot.strategies; \u002F\u002F one entry per mount, with its capabilities and status\nsnapshot.consumers;  \u002F\u002F one entry per registered handler\nsnapshot.metrics;    \u002F\u002F published, processed, failed, retried, unhandled and active, per queue\nsnapshot.events;     \u002F\u002F recently processed jobs, newest first\n",[363,2493,2494,2513,2517,2532,2545,2559,2573],{"__ignoreMap":373},[377,2495,2496,2498,2501,2503,2505,2507,2509,2511],{"class":379,"line":380},[377,2497,976],{"class":975},[377,2499,2500],{"class":383}," snapshot ",[377,2502,982],{"class":387},[377,2504,681],{"class":383},[377,2506,388],{"class":387},[377,2508,2485],{"class":391},[377,2510,1921],{"class":383},[377,2512,512],{"class":387},[377,2514,2515],{"class":379,"line":404},[377,2516,816],{"emptyLinePlaceholder":60},[377,2518,2519,2522,2524,2527,2529],{"class":379,"line":421},[377,2520,2521],{"class":383},"snapshot",[377,2523,388],{"class":387},[377,2525,2526],{"class":383},"started",[377,2528,1136],{"class":387},[377,2530,2531],{"class":1139},"    \u002F\u002F whether consumers are running\n",[377,2533,2534,2536,2538,2540,2542],{"class":379,"line":435},[377,2535,2521],{"class":383},[377,2537,388],{"class":387},[377,2539,542],{"class":383},[377,2541,1136],{"class":387},[377,2543,2544],{"class":1139}," \u002F\u002F one entry per mount, with its capabilities and status\n",[377,2546,2547,2549,2551,2554,2556],{"class":379,"line":455},[377,2548,2521],{"class":383},[377,2550,388],{"class":387},[377,2552,2553],{"class":383},"consumers",[377,2555,1136],{"class":387},[377,2557,2558],{"class":1139},"  \u002F\u002F one entry per registered handler\n",[377,2560,2561,2563,2565,2568,2570],{"class":379,"line":468},[377,2562,2521],{"class":383},[377,2564,388],{"class":387},[377,2566,2567],{"class":383},"metrics",[377,2569,1136],{"class":387},[377,2571,2572],{"class":1139},"    \u002F\u002F published, processed, failed, retried, unhandled and active, per queue\n",[377,2574,2575,2577,2579,2581,2583],{"class":379,"line":504},[377,2576,2521],{"class":383},[377,2578,388],{"class":387},[377,2580,725],{"class":383},[377,2582,1136],{"class":387},[377,2584,2585],{"class":1139},"     \u002F\u002F recently processed jobs, newest first\n",[661,2587,2589],{"id":2588},"configure","configure()",[359,2591,2592],{},"Sets manager-wide settings, merging into the existing ones. Per-job and per-handler options always win.",[368,2594,2596],{"className":370,"code":2595,"language":372,"meta":373,"style":373},"queueManager.configure({ concurrency: 4, onUnhandled: 'fail', maxEvents: 200 });\n",[363,2597,2598],{"__ignoreMap":373},[377,2599,2600,2602,2604,2606,2608,2610,2613,2615,2618,2620,2623,2625,2627,2629,2631,2633,2636,2638,2641,2643,2645],{"class":379,"line":380},[377,2601,1451],{"class":383},[377,2603,388],{"class":387},[377,2605,2588],{"class":391},[377,2607,482],{"class":383},[377,2609,485],{"class":387},[377,2611,2612],{"class":407}," concurrency",[377,2614,411],{"class":387},[377,2616,2617],{"class":429}," 4",[377,2619,398],{"class":387},[377,2621,2622],{"class":407}," onUnhandled",[377,2624,411],{"class":387},[377,2626,443],{"class":387},[377,2628,606],{"class":446},[377,2630,450],{"class":387},[377,2632,398],{"class":387},[377,2634,2635],{"class":407}," maxEvents",[377,2637,411],{"class":387},[377,2639,2640],{"class":429}," 200",[377,2642,759],{"class":387},[377,2644,509],{"class":383},[377,2646,512],{"class":387},[661,2648,2650],{"id":2649},"getstrategy","getStrategy()",[359,2652,2653],{},"Returns a mounted strategy, for the rare case a transport-specific API is needed.",[368,2655,2657],{"className":370,"code":2656,"language":372,"meta":373,"style":373},"const bullmq = queueManager.getStrategy() as BullMQStrategy;\n",[363,2658,2659],{"__ignoreMap":373},[377,2660,2661,2663,2666,2668,2670,2672,2675,2678,2681,2685],{"class":379,"line":380},[377,2662,976],{"class":975},[377,2664,2665],{"class":383}," bullmq ",[377,2667,982],{"class":387},[377,2669,681],{"class":383},[377,2671,388],{"class":387},[377,2673,2674],{"class":391},"getStrategy",[377,2676,2677],{"class":383},"() ",[377,2679,2680],{"class":677},"as",[377,2682,2684],{"class":2683},"sBMFI"," BullMQStrategy",[377,2686,512],{"class":387},[354,2688,74],{"id":2689},"decorators",[514,2691,2692,2704],{},[517,2693,2694],{},[520,2695,2696,2699,2702],{},[523,2697,2698],{},"Decorator",[523,2700,2701],{},"Applies to",[523,2703,531],{},[533,2705,2706,2719,2732,2744,2756],{},[520,2707,2708,2713,2716],{},[538,2709,2710],{},[363,2711,2712],{},"@Consumer(options)",[538,2714,2715],{},"class",[538,2717,2718],{},"Declares the queue the class reads from and the defaults of its handlers.",[520,2720,2721,2726,2729],{},[538,2722,2723],{},[363,2724,2725],{},"@Job(name, options?)",[538,2727,2728],{},"method",[538,2730,2731],{},"Declares the method as the handler of one job name.",[520,2733,2734,2739,2741],{},[538,2735,2736],{},[363,2737,2738],{},"@AnyJob(options?)",[538,2740,2728],{},[538,2742,2743],{},"Declares the method as the handler of every job the queue has no named handler for.",[520,2745,2746,2751,2753],{},[538,2747,2748],{},[363,2749,2750],{},"@OnJobCompleted(options?)",[538,2752,2728],{},[538,2754,2755],{},"Runs after a job of the queue completed.",[520,2757,2758,2763,2765],{},[538,2759,2760],{},[363,2761,2762],{},"@OnJobFailed(options?)",[538,2764,2728],{},[538,2766,2767],{},"Runs after an attempt of a job of the queue threw.",[359,2769,2770,2771,2774],{},"See ",[2772,2773,117],"a",{"href":118}," for the full description of each.",[354,2776,2778],{"id":2777},"jobcontext","JobContext",[359,2780,2781],{},"The second argument of every handler and hook.",[514,2783,2784,2792],{},[517,2785,2786],{},[520,2787,2788,2790],{},[523,2789,1149],{},[523,2791,531],{},[533,2793,2794,2803,2812,2821,2830,2840,2849,2858,2867,2877,2887],{},[520,2795,2796,2800],{},[538,2797,2798],{},[363,2799,1133],{},[538,2801,2802],{},"Job id, as assigned by the transport.",[520,2804,2805,2809],{},[538,2806,2807],{},[363,2808,1170],{},[538,2810,2811],{},"Name of the job.",[520,2813,2814,2818],{},[538,2815,2816],{},[363,2817,1160],{},[538,2819,2820],{},"Queue it came from.",[520,2822,2823,2827],{},[538,2824,2825],{},[363,2826,775],{},[538,2828,2829],{},"Name of the mounted strategy it came from.",[520,2831,2832,2837],{},[538,2833,2834],{},[363,2835,2836],{},"attempt",[538,2838,2839],{},"Attempt number, starting at 1.",[520,2841,2842,2846],{},[538,2843,2844],{},[363,2845,1227],{},[538,2847,2848],{},"Total attempts this job may take.",[520,2850,2851,2855],{},[538,2852,2853],{},[363,2854,1180],{},[538,2856,2857],{},"Validated payload, identical to the first handler argument.",[520,2859,2860,2864],{},[538,2861,2862],{},[363,2863,1291],{},[538,2865,2866],{},"Transport headers received with the job.",[520,2868,2869,2874],{},[538,2870,2871],{},[363,2872,2873],{},"raw",[538,2875,2876],{},"The transport-native job or message.",[520,2878,2879,2884],{},[538,2880,2881],{},[363,2882,2883],{},"logger",[538,2885,2886],{},"Logger scoped to this job, or null when none is bound.",[520,2888,2889,2894],{},[538,2890,2891],{},[363,2892,2893],{},"updateProgress(progress)",[538,2895,2896],{},"Reports progress, a no-op on transports that do not track it.",[354,2898,2900],{"id":2899},"queueerror","QueueError",[359,2902,2903,2904,2906,2907,2910],{},"Every failure the module raises itself is a ",[363,2905,2900],{},". What a handler throws is passed through untouched, so a handler that throws a plain ",[363,2908,2909],{},"Error"," fails the attempt with that error.",[368,2912,2914],{"className":370,"code":2913,"language":372,"meta":373,"style":373},"try {\n  await queueManager.add({ queue: 'emails', job: 'welcome', payload });\n} catch (error) {\n  if (error instanceof QueueError) {\n    error.operation; \u002F\u002F 'add', 'publish', 'consume', 'validate', 'timeout', ...\n    error.retryable; \u002F\u002F false when running the job again cannot help\n    error.cause;     \u002F\u002F the transport error underneath\n    error.metadata;  \u002F\u002F queue, job and other non-sensitive context\n  }\n}\n",[363,2915,2916,2923,2971,2983,3001,3016,3030,3044,3058,3062],{"__ignoreMap":373},[377,2917,2918,2921],{"class":379,"line":380},[377,2919,2920],{"class":677},"try",[377,2922,401],{"class":387},[377,2924,2925,2928,2930,2932,2934,2936,2938,2940,2942,2944,2946,2948,2950,2952,2954,2956,2958,2960,2962,2965,2967,2969],{"class":379,"line":404},[377,2926,2927],{"class":677},"  await",[377,2929,681],{"class":383},[377,2931,388],{"class":387},[377,2933,961],{"class":391},[377,2935,482],{"class":407},[377,2937,485],{"class":387},[377,2939,1691],{"class":407},[377,2941,411],{"class":387},[377,2943,443],{"class":387},[377,2945,1008],{"class":446},[377,2947,450],{"class":387},[377,2949,398],{"class":387},[377,2951,1704],{"class":407},[377,2953,411],{"class":387},[377,2955,443],{"class":387},[377,2957,1024],{"class":446},[377,2959,450],{"class":387},[377,2961,398],{"class":387},[377,2963,2964],{"class":383}," payload",[377,2966,759],{"class":387},[377,2968,509],{"class":407},[377,2970,512],{"class":387},[377,2972,2973,2975,2978,2981],{"class":379,"line":421},[377,2974,496],{"class":387},[377,2976,2977],{"class":677}," catch",[377,2979,2980],{"class":383}," (error) ",[377,2982,996],{"class":387},[377,2984,2985,2987,2989,2991,2994,2997,2999],{"class":379,"line":435},[377,2986,2173],{"class":677},[377,2988,1401],{"class":407},[377,2990,1839],{"class":383},[377,2992,2993],{"class":387}," instanceof",[377,2995,2996],{"class":2683}," QueueError",[377,2998,2194],{"class":407},[377,3000,996],{"class":387},[377,3002,3003,3006,3008,3011,3013],{"class":379,"line":455},[377,3004,3005],{"class":383},"    error",[377,3007,388],{"class":387},[377,3009,3010],{"class":383},"operation",[377,3012,1136],{"class":387},[377,3014,3015],{"class":1139}," \u002F\u002F 'add', 'publish', 'consume', 'validate', 'timeout', ...\n",[377,3017,3018,3020,3022,3025,3027],{"class":379,"line":468},[377,3019,3005],{"class":383},[377,3021,388],{"class":387},[377,3023,3024],{"class":383},"retryable",[377,3026,1136],{"class":387},[377,3028,3029],{"class":1139}," \u002F\u002F false when running the job again cannot help\n",[377,3031,3032,3034,3036,3039,3041],{"class":379,"line":504},[377,3033,3005],{"class":383},[377,3035,388],{"class":387},[377,3037,3038],{"class":383},"cause",[377,3040,1136],{"class":387},[377,3042,3043],{"class":1139},"     \u002F\u002F the transport error underneath\n",[377,3045,3046,3048,3050,3053,3055],{"class":379,"line":941},[377,3047,3005],{"class":383},[377,3049,388],{"class":387},[377,3051,3052],{"class":383},"metadata",[377,3054,1136],{"class":387},[377,3056,3057],{"class":1139},"  \u002F\u002F queue, job and other non-sensitive context\n",[377,3059,3060],{"class":379,"line":1606},[377,3061,2251],{"class":387},[377,3063,3065],{"class":379,"line":3064},10,[377,3066,3067],{"class":387},"}\n",[359,3069,3070,3072],{},[363,3071,3024],{}," is what the manager reads when deciding whether to schedule another attempt: a validation failure or a missing handler is never retried, while a broker hiccup is.",[354,3074,3076],{"id":3075},"job-headers","Job headers",[359,3078,3079,3080,3083],{},"Three headers travel with every job so any transport can route and retry it. They are visible in ",[363,3081,3082],{},"context.headers"," and can be read by other consumers of the same broker.",[514,3085,3086,3095],{},[517,3087,3088],{},[520,3089,3090,3093],{},[523,3091,3092],{},"Header",[523,3094,531],{},[533,3096,3097,3106,3115,3125,3135],{},[520,3098,3099,3104],{},[538,3100,3101],{},[363,3102,3103],{},"x-job",[538,3105,2811],{},[520,3107,3108,3113],{},[538,3109,3110],{},[363,3111,3112],{},"x-attempt",[538,3114,2839],{},[520,3116,3117,3122],{},[538,3118,3119],{},[363,3120,3121],{},"x-attempts",[538,3123,3124],{},"Total attempts the publisher asked for, when it asked for more than one.",[520,3126,3127,3132],{},[538,3128,3129],{},[363,3130,3131],{},"x-key",[538,3133,3134],{},"Partition or routing key, when the job was published with one.",[520,3136,3137,3142],{},[538,3138,3139],{},[363,3140,3141],{},"x-priority",[538,3143,3144],{},"Priority, when the job was published with one.",[359,3146,3147],{},"A retry is a fresh publish, so it is these headers that carry the key and the priority of the original across it.",[359,3149,3150,3151,3154,3155,3157],{},"A message that carries no job name, because it was produced outside this module and its transport's own field is empty too, is dispatched as the job ",[363,3152,3153],{},"unknown",", which an ",[363,3156,1629],{}," handler picks up.",[359,3159,3160,3162],{},[363,3161,3121],{}," is read off the wire on transports that do not retry natively, so the budget it asks for is capped at 50 and a backoff is never held longer than a day.",[3164,3165,3166],"style",{},"html pre.shiki code .sTEyZ, html code.shiki .sTEyZ{--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8}html pre.shiki code .sMK4o, html code.shiki .sMK4o{--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF}html pre.shiki code .s2Zo4, html code.shiki .s2Zo4{--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF}html pre.shiki code .swJcz, html code.shiki .swJcz{--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178}html pre.shiki code .sfNiH, html code.shiki .sfNiH{--shiki-light:#FF5370;--shiki-default:#FF9CAC;--shiki-dark:#FF9CAC}html pre.shiki code .sbssI, html code.shiki .sbssI{--shiki-light:#F76D47;--shiki-default:#F78C6C;--shiki-dark:#F78C6C}html pre.shiki code .sfazB, html code.shiki .sfazB{--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D}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 pre.shiki code .s7zQu, html code.shiki .s7zQu{--shiki-light:#39ADB5;--shiki-light-font-style:italic;--shiki-default:#89DDFF;--shiki-default-font-style:italic;--shiki-dark:#89DDFF;--shiki-dark-font-style:italic}html pre.shiki code .spNyl, html code.shiki .spNyl{--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA}html pre.shiki code .sHwdD, html code.shiki .sHwdD{--shiki-light:#90A4AE;--shiki-light-font-style:italic;--shiki-default:#546E7A;--shiki-default-font-style:italic;--shiki-dark:#676E95;--shiki-dark-font-style:italic}html pre.shiki code .sHdIc, html code.shiki .sHdIc{--shiki-light:#90A4AE;--shiki-light-font-style:italic;--shiki-default:#EEFFFF;--shiki-default-font-style:italic;--shiki-dark:#BABED8;--shiki-dark-font-style:italic}html pre.shiki code .sBMFI, html code.shiki .sBMFI{--shiki-light:#E2931D;--shiki-default:#FFCB6B;--shiki-dark:#FFCB6B}",{"title":373,"searchDepth":380,"depth":404,"links":3168},[3169,3170,3186,3187,3188,3189],{"id":356,"depth":404,"text":357},{"id":659,"depth":404,"text":365,"children":3171},[3172,3173,3174,3175,3176,3177,3178,3179,3180,3181,3182,3183,3184,3185],{"id":663,"depth":421,"text":664},{"id":779,"depth":421,"text":553},{"id":961,"depth":421,"text":962},{"id":1317,"depth":421,"text":1318},{"id":1433,"depth":421,"text":1434},{"id":1744,"depth":421,"text":1745},{"id":1901,"depth":421,"text":1902},{"id":1979,"depth":421,"text":1980},{"id":2005,"depth":421,"text":2006},{"id":2127,"depth":421,"text":2128},{"id":2283,"depth":421,"text":2284},{"id":2485,"depth":421,"text":2134},{"id":2588,"depth":421,"text":2589},{"id":2649,"depth":421,"text":2650},{"id":2689,"depth":404,"text":74},{"id":2777,"depth":404,"text":2778},{"id":2899,"depth":404,"text":2900},{"id":3075,"depth":404,"text":3076},"Reference for QueueManager, the queue plugin, decorators, types and errors","md",null,{},{"title":101,"description":3190},"NzHKbQHRNB8w9L3IIt7GxR0eHvtDP2vGFyozLGTLYpE",[3197,3199],{"title":121,"path":122,"stem":123,"description":3198,"children":-1},"Memory, BullMQ, RabbitMQ and Kafka transports, their options and their limits",{"title":70,"path":133,"stem":134,"description":3200,"children":-1},"Structured wide-event logging for Vercube, powered by evlog",1791443501933]