bunqueue-dashboard 0.0.37 → 0.0.38
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +5 -3
- package/dist/.vite/manifest.json +114 -114
- package/dist/assets/{AddJob-CWkkVHmf.js → AddJob-CC4bfHLH.js} +1 -1
- package/dist/assets/{Alerts-Gh1pVbqj.js → Alerts-C2bAi-Kj.js} +1 -1
- package/dist/assets/{Benchmark-Dir2A1CQ.js → Benchmark-ClJmYZoC.js} +1 -1
- package/dist/assets/{BulkAddJobs-Di_IgRSH.js → BulkAddJobs-BBWqQpP7.js} +1 -1
- package/dist/assets/{CopilotPanel-Db5nYpo1.js → CopilotPanel-Bhh-uCpN.js} +3 -3
- package/dist/assets/{Cron-BRgWcBGk.js → Cron-pJJ5KXFG.js} +1 -1
- package/dist/assets/{CronManager-CbM0x_s0.js → CronManager-lNZ4lHh1.js} +1 -1
- package/dist/assets/{Database-BeoEreW0.js → Database-DxiXsUl4.js} +1 -1
- package/dist/assets/{Diagnostics-Cw9iJ84f.js → Diagnostics-DLvCT7zI.js} +1 -1
- package/dist/assets/{Dlq-DfCg04Jd.js → Dlq-Bx4YXTp5.js} +1 -1
- package/dist/assets/{DlqControl-BRCkUXvb.js → DlqControl-DJGhuyu3.js} +1 -1
- package/dist/assets/{DlqPro-BHJwBYsN.js → DlqPro-BhXIKtrt.js} +1 -1
- package/dist/assets/{Flows-BAzbFP_W.js → Flows-Bb9j-YhZ.js} +1 -1
- package/dist/assets/{JobInspector-qvW_APO6.js → JobInspector-DfqBq4O5.js} +2 -2
- package/dist/assets/{Jobs-URpnFjC6.js → Jobs-Blavwd1H.js} +1 -1
- package/dist/assets/{JobsPro-pQ_RFSU3.js → JobsPro-D8dH9um7.js} +1 -1
- package/dist/assets/{Logs-C5jX2OPE.js → Logs-B3dsGSF8.js} +1 -1
- package/dist/assets/{LogsPro-Cq_npmmS.js → LogsPro-BCB7etG2.js} +1 -1
- package/dist/assets/{McpServer-DtCTmQBu.js → McpServer-Cz1-GwD5.js} +1 -1
- package/dist/assets/{Metrics-BdxitePr.js → Metrics-Bkuy6Ntb.js} +1 -1
- package/dist/assets/{MetricsPro-orHfW0mg.js → MetricsPro-BbJmy0oO.js} +1 -1
- package/dist/assets/{Overview-DaNns1aj.js → Overview-Ba5odzYe.js} +1 -1
- package/dist/assets/{QueueActions-jiTzndPH.js → QueueActions-B6M0ByGt.js} +1 -1
- package/dist/assets/{QueueControl-l5bSdMgb.js → QueueControl-CWHsVfWU.js} +1 -1
- package/dist/assets/{QueueDetail-URK2pjtH.js → QueueDetail-BClRbWC5.js} +1 -1
- package/dist/assets/{QueueDetailPro-C9M5CV4K.js → QueueDetailPro-CIimG0pX.js} +1 -1
- package/dist/assets/{Queues-DeLXlww2.js → Queues-CGPgEkVm.js} +1 -1
- package/dist/assets/{QueuesOverview-DoQ-MUfT.js → QueuesOverview-ChC5Dtqh.js} +1 -1
- package/dist/assets/{S3Backup-D2agV9_z.js → S3Backup-5OKa8G13.js} +1 -1
- package/dist/assets/S3BackupPro-BkwTXdtw.js +3 -0
- package/dist/assets/{ServerControl-QVd6m_iR.js → ServerControl-DJHKMaf9.js} +1 -1
- package/dist/assets/{Settings-CiJRj_SM.js → Settings-C1HtCK6h.js} +1 -1
- package/dist/assets/{Usage-DbHJgA4t.js → Usage-QyZkUhgs.js} +1 -1
- package/dist/assets/{UsagePro-LoPo3k1L.js → UsagePro-DMxrXxur.js} +1 -1
- package/dist/assets/{Webhooks-CuzIJHwk.js → Webhooks-D0JQQf0q.js} +1 -1
- package/dist/assets/{Workers-BpUgpwUH.js → Workers-Cn8Bkgy1.js} +1 -1
- package/dist/assets/{WorkersPro-BYY0P1Pt.js → WorkersPro-BOTuX9EP.js} +1 -1
- package/dist/assets/{Workflows-ByJw4FFH.js → Workflows-DqTKWPmT.js} +1 -1
- package/dist/assets/bq-Bmysbg0r.js +1 -0
- package/dist/assets/index-Cue53Myw.js +8 -0
- package/dist/assets/install-CFiYX86d.js +3 -0
- package/dist/assets/{usePolledData-c53tx1jw.js → usePolledData-g80Z_UB-.js} +1 -1
- package/dist/assets/useThroughputSeries-CrsZYKbT.js +1 -0
- package/dist/index.html +3 -3
- package/package.json +10 -5
- package/scripts/embedded.gen.ts +142 -142
- package/dist/assets/S3BackupPro--WSZWTQn.js +0 -3
- package/dist/assets/bq-DYmbVkgR.js +0 -1
- package/dist/assets/index-D64v2vNO.js +0 -8
- package/dist/assets/install-jXi1SOYY.js +0 -3
- package/dist/assets/useThroughputSeries-DWHQl7cM.js +0 -1
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
var e=e=>({ok:!0,result:e});function t(t,n){let r=t[1];return n===`GET`&&r===`status`?e({success:!0,message:`Backup configuration loaded`,data:{enabled:!0,bucket:`bunqueue-demo-backups`,endpoint:`https://s3.example.com`,interval:`6h`,retention:`30d`}}):n===`GET`&&r===`list`?e({success:!0,message:`Backups listed`,data:[{key:`backups/bunqueue-2026-08-04.db`,size:`2.6 MB`,date:`2026-08-04T10:00:00Z`},{key:`backups/bunqueue-2026-08-03.db`,size:`2.5 MB`,date:`2026-08-03T10:00:00Z`}]}):n===`POST`&&r===`configure`?e({configured:!0,enabled:!0}):n===`POST`&&r===`now`?e({success:!0,message:`Demo backup completed`,data:{key:`backups/bunqueue-demo-now.db`}}):n===`POST`&&r===`restore`?e({success:!0,message:`Demo backup restored`}):{ok:!1,error:`Demo backup route not found`}}var n={command:`bunx bunqueue@2.8.59 start`,httpPort:6790,tcpPort:6791,dataPath:`./data/bunqueue.db`,extraEnv:{LOG_LEVEL:`info`}},r=()=>({status:`running`,generation:1,pid:42317,startedAt:Date.now()-36e5,exitCode:null,healthy:!0,version:`2.8.59`,config:n,runningConfig:n,db:{path:n.dataPath,exists:!0,size:2621440,walSize:49152,shmSize:32768,totalSize:2703360,mtimeMs:Date.now()-12e3}}),i=()=>{let e=Date.now();return{ok:!0,data:{workers:[{id:`wrk-9f21c3d0`,name:`worker-emails-1`,queues:[`emails`,`notifications`],concurrency:10,hostname:`worker-01`,pid:3411,status:`active`,registeredAt:e-54e5,lastSeen:e-4e3,activeJobs:0,processedJobs:1284,failedJobs:6,currentJob:null,uptime:54e5},{id:`wrk-4b77aa19`,name:`worker-media-1`,queues:[`image-processing`],concurrency:4,hostname:`worker-02`,pid:3987,status:`active`,registeredAt:e-51e5,lastSeen:e-2e3,activeJobs:2,processedJobs:342,failedJobs:1,currentJob:`019f252b-8769-7000-bc44-cfc168232f53`,uptime:51e5},{id:`wrk-c05e881f`,name:`worker-batch-1`,queues:[`reports`],concurrency:2,hostname:`worker-02`,pid:4102,status:`stale`,registeredAt:e-9e6,lastSeen:e-12e5,activeJobs:0,processedJobs:57,failedJobs:0,currentJob:null,uptime:78e5}],stats:{total:3,active:2,totalProcessed:1683,totalFailed:7,activeJobs:2}}}},a=()=>{let e=Date.now(),t=(t,n,r,i)=>({seq:t,ts:e-n,stream:r,line:i});return{lines:[t(1,8e3,`sys`,`starting: bunx bunqueue@2.8.59 start`),t(2,7800,`stdout`,`bunqueue v2.8.59 — HTTP :6790, TCP :6791`),t(3,7600,`stdout`,`SQLite ready (WAL) at ./data/bunqueue.db`),t(4,5e3,`stdout`,`worker registered: image-processing`),t(5,1200,`stdout`,`health ok — 4 queues, 34 jobs`)]}},o={ok:!0,sqliteVersion:`3.45.1`,pageSize:4096,pageCount:640,journalMode:`wal`,freelistPages:8,tables:6,indexes:11,fileSize:2621440,walSize:49152},s={jobs:{columns:[`id`,`queue`,`state`,`priority`,`attempts`,`created_at`],types:{id:`TEXT`,queue:`TEXT`,state:`TEXT`,priority:`INTEGER`,attempts:`INTEGER`,created_at:`INTEGER`},rows:[[`019f252b-86c0-7000-a54e-3816c968ebf0`,`emails`,`prioritized`,1,0,1783035037376],[`019f252b-8769-7000-bc44-cfc168232f53`,`image-processing`,`active`,0,0,1783035037545],[`019f252b-86da-7000-a9e3-6b1b74944d70`,`emails`,`completed`,3,0,1783035037402],[`019f252b-8716-7000-bbec-d8c65e09f340`,`emails`,`failed`,3,0,1783035037462],[`019f252b-87d8-7000-8f0c-e8ca5fec7d18`,`reports`,`delayed`,0,0,1783035037656]]},queues:{columns:[`name`,`paused`,`concurrency`,`rate_limit`],types:{name:`TEXT`,paused:`INTEGER`,concurrency:`INTEGER`,rate_limit:`INTEGER`},rows:[[`emails`,0,10,0],[`image-processing`,0,4,100],[`reports`,0,2,0],[`notifications`,0,8,0]]},dlq:{columns:[`id`,`queue`,`reason`,`attempts`,`entered_at`],types:{id:`TEXT`,queue:`TEXT`,reason:`TEXT`,attempts:`INTEGER`,entered_at:`INTEGER`},rows:[[`019f252b-8716-7000-bbec-d8c65e09f340`,`emails`,`max attempts reached`,3,1783035037462],[`019f252b-8a02-7000-9b21-4c1f0b7e2a55`,`reports`,`handler threw`,5,1783035039101]]},crons:{columns:[`name`,`queue`,`pattern`,`tz`,`next_run`],types:{name:`TEXT`,queue:`TEXT`,pattern:`TEXT`,tz:`TEXT`,next_run:`INTEGER`},rows:[[`nightly-report`,`reports`,`0 2 * * *`,`UTC`,17830944e5],[`digest-email`,`emails`,`*/15 * * * *`,`UTC`,17830359e5]]},webhooks:{columns:[`id`,`url`,`events`,`active`,`failures`,`created_at`],types:{id:`TEXT`,url:`TEXT`,events:`TEXT`,active:`INTEGER`,failures:`INTEGER`,created_at:`INTEGER`},rows:[[`wh_9c31`,`https://hooks.example.com/bunqueue`,`job:completed,job:failed`,1,0,1783034e6]]},job_results:{columns:[`job_id`,`result`,`stored_at`],types:{job_id:`TEXT`,result:`TEXT`,stored_at:`INTEGER`},rows:[[`019f252b-86da-7000-a9e3-6b1b74944d70`,`{"messageId":"smtp-7712"}`,1783035037999],[`019f252b-8769-7000-bc44-cfc168232f53`,`{"bytes":184320}`,1783035038220],[`019f252b-87d8-7000-8f0c-e8ca5fec7d18`,`{"rows":128}`,1783035038511],[`019f252b-8a02-7000-9b21-4c1f0b7e2a55`,`{"error":"handler threw"}`,1783035039300],[`demo-csv-formula`,`=SUM(1,2)`,1783035039400]]}};function c(e){return Object.hasOwn(s,e)?s[e]:void 0}var l={ok:!0,tables:Object.entries(s).map(([e,t])=>({name:e,rows:t.rows.length,columns:t.columns.length}))};function u(e){let t=c(e),n=t?.columns??[`id`,`data`],r=t?.types??{};return{ok:!0,table:e,columns:n.map((e,t)=>({name:e,type:r[e]??`TEXT`,notNull:t===0,defaultValue:null,primaryKey:t===0})),indexes:[{name:`idx_${e}_${n[0]}`,unique:!0,columns:[n[0]]}],sql:`CREATE TABLE ${e} (${n.map(e=>`${e} ${r[e]??`TEXT`}`).join(`, `)})`,rowCount:t?.rows.length??0}}var d=e=>e.replace(/[A-Z]/g,e=>e.toLowerCase());function f(e,t,n=!1){let r=c(e);if(n&&!r)throw Error(`No such table: ${e}`);let i=r?.columns??[`id`,`data`],a=r?.rows??[],o=new URLSearchParams(t);if(n){let e=new Set([`orderBy`,`dir`,`fcol`,`fop`,`fval`]);for(let t of o.keys()){if(!e.has(t))throw Error(`Unknown database export option: ${t}`);if(o.getAll(t).length!==1)throw Error(`Duplicate database export option: ${t}`)}}let s=o.get(`orderBy`);if(n&&s===``)throw Error(`Database export orderBy must not be empty`);let l=s||null,u=o.get(`dir`);if(n&&u!==null&&u!==`asc`&&u!==`desc`)throw Error(`Database export dir must be "asc" or "desc"`);let f=u===`desc`?`desc`:`asc`,p=o.get(`fcol`),m=o.get(`fop`),h=o.get(`fval`);if(n&&(p!==null||m!==null||h!==null)&&(!p||!h||m!==`contains`&&m!==`eq`&&m!==`ne`))throw Error(`Database export filter requires valid fcol, fop and fval values`);let g=p&&h?{column:p,op:m===`eq`?`eq`:m===`ne`?`ne`:`contains`,value:h}:null,_=g?i.indexOf(g.column):-1;if(g&&_<0&&n)throw Error(`No such column: ${g.column}`);let v=g&&_>=0?a.filter(e=>{let t=e[_];if(t==null)return!1;let n=String(t);return g.op===`eq`?n===g.value:g.op===`ne`?n!==g.value:d(n).includes(d(g.value))}):a,y=l?i.indexOf(l):-1;if(l&&y<0&&n)throw Error(`No such column: ${l}`);return{table:e,columns:i,rows:y>=0?[...v].sort((e,t)=>{let n=e[y],r=t[y],i=n==null?r==null?0:-1:r==null?1:n<r?-1:+(n>r);return f===`desc`?-i:i}):v,orderBy:y>=0?l:null,dir:f,filter:_>=0?g:null}}function p(e,t){let n=f(e,t),r=new URLSearchParams(t),i=(e,t)=>{let n=Number(e);return e!==null&&Number.isFinite(n)&&n>=0?n:t},a=i(r.get(`limit`),50),o=i(r.get(`offset`),0),s=n.rows.slice(o,o+(a>0?a:n.rows.length));return{ok:!0,table:e,columns:n.columns,rows:s,rowids:s.map((e,t)=>o+t+1),truncatedCells:s.map(e=>e.map(()=>!1)),total:n.rows.length,limit:a,offset:o,orderBy:n.orderBy,dir:n.dir,filter:n.filter}}var m=2e5,h=16*1024*1024,g=2e3,_=2e3;function v(e){let t,n=!1;if(e==null)t=``;else if(typeof e==`string`)t=new TextEncoder().encode(e).byteLength>g?`${[...e].slice(0,_).join(``)}…`:e,n=!0;else if(typeof e==`number`||typeof e==`bigint`||typeof e==`boolean`)t=String(e);else if(e instanceof Uint8Array)t=`<blob ${e.byteLength} B>`,n=!0;else throw Error(`Database export produced an unsupported SQLite value`);let r=n&&/^[=+\-@\t\r]/.test(t)?`'${t}`:t;return/[",\r\n]/.test(r)?`"${r.replaceAll(`"`,`""`)}"`:r}function y(e,t){try{let n=f(e,t,!0),r=new TextEncoder,i=[],a=0,o=0,s=null,c=e=>{let t=r.encode(e);return a+t.byteLength>h?!1:(i.push(t),a+=t.byteLength,!0)};if(!c(n.columns.map(v).join(`,`)))throw Error(`Database export header exceeds the ${h}-byte export limit`);for(let e of n.rows){if(o>=m){s=`rows`;break}if(!c(`\r\n${e.map(v).join(`,`)}`)){s=`bytes`;break}o++}let l=new Uint8Array(a),u=0;for(let e of i)l.set(e,u),u+=e.byteLength;return new Response(l,{status:200,headers:{"Content-Type":`text/csv; charset=utf-8`,"Content-Length":String(a),"Cache-Control":`no-store`,"X-Content-Type-Options":`nosniff`,"X-Bunqueue-Db-Export-Version":`1`,"X-Bunqueue-Db-Export-Table":encodeURIComponent(n.table),"X-Bunqueue-Db-Export-Rows":String(o),"X-Bunqueue-Db-Export-Bytes":String(a),"X-Bunqueue-Db-Export-Cap":s??`none`,"Access-Control-Expose-Headers":`Content-Length, X-Bunqueue-Db-Export-Version, X-Bunqueue-Db-Export-Table, X-Bunqueue-Db-Export-Rows, X-Bunqueue-Db-Export-Bytes, X-Bunqueue-Db-Export-Cap`}})}catch(e){return new Response(JSON.stringify({ok:!1,error:e instanceof Error?e.message:String(e)}),{status:400,headers:{"Content-Type":`application/json`}})}}var b={"flow-order-9a3f":{id:`flow-order-9a3f`,queue:`orders`,data:{name:`process-order`,orderId:`demo-9a3f`,__childrenIds:[`flow-charge-1`,`flow-ship-2`,`flow-notify-3`]},state:`waiting-children`,priority:1,parentId:null,childrenIds:[`flow-charge-1`,`flow-ship-2`,`flow-notify-3`],dependsOn:[`flow-charge-1`,`flow-ship-2`,`flow-notify-3`]},"flow-charge-1":{id:`flow-charge-1`,queue:`payments`,data:{name:`charge-payment`,__parentId:`flow-order-9a3f`,__parentQueue:`orders`},state:`completed`,priority:2,parentId:`flow-order-9a3f`,childrenIds:[],dependsOn:[]},"flow-ship-2":{id:`flow-ship-2`,queue:`shipping`,data:{name:`ship-order`,__parentId:`flow-order-9a3f`,__parentQueue:`orders`,__childrenIds:[`flow-label-4`]},state:`waiting-children`,priority:1,parentId:`flow-order-9a3f`,childrenIds:[`flow-label-4`],dependsOn:[`flow-label-4`]},"flow-label-4":{id:`flow-label-4`,queue:`shipping`,data:{name:`create-label`,__parentId:`flow-ship-2`,__parentQueue:`shipping`},state:`waiting`,priority:0,parentId:`flow-ship-2`,childrenIds:[],dependsOn:[]},"flow-notify-3":{id:`flow-notify-3`,queue:`emails`,data:{name:`notify-customer`,__parentId:`flow-order-9a3f`,__parentQueue:`orders`},state:`delayed`,priority:0,parentId:`flow-order-9a3f`,childrenIds:[],dependsOn:[`flow-charge-1`]}},x={id:`flow-order-9a3f`,name:`process-order`,queueName:`orders`,state:`waiting-children`,children:[{id:`flow-charge-1`,name:`charge-payment`,queueName:`payments`,state:`completed`,children:[]},{id:`flow-ship-2`,name:`ship-order`,queueName:`shipping`,state:`waiting-children`,children:[{id:`flow-label-4`,name:`create-label`,queueName:`shipping`,state:`waiting`,children:[]}]},{id:`flow-notify-3`,name:`notify-customer`,queueName:`emails`,state:`delayed`,children:[]}]};function S(e,t,n=``){return e[1]===`results`?{ok:!0,result:{operation:`getParentResults`,entries:[[`flow-demo-child`,{rows:42}],[`flow-demo-zero`,0]]}}:e[1]===`tree`?{ok:!0,result:{flow:ee(n)}}:e[1]===`create`?{ok:!0,result:{operation:`add`,root:{id:`flow-demo-created`,name:`aggregate`,queueName:`reports`,state:`waiting-children`,children:[]}}}:t===`GET`?{ok:!0,result:{values:{},dependencies:{processed:{},unprocessed:[`flow-demo-child`]},counts:{processed:0,unprocessed:1}}}:{ok:!0,result:{applied:!0,removed:!0}}}function ee(e){let t=new URLSearchParams(e),n=C(t.get(`depth`),500),r=C(t.get(`maxChildren`),500),i=(e,t)=>({...e,children:t>=n?[]:e.children.slice(0,r).map(e=>i(e,t+1))});return i(x,0)}function C(e,t){return e===null||!/^\d+$/.test(e)?t:Math.min(Number(e),500)}var w={health:{ok:!0,status:`healthy`,uptime:133,version:`2.8.59`,queues:{waiting:13,active:2,delayed:6,completed:4,dlq:2},connections:{tcp:0,ws:0,sse:0},memory:{heapUsed:3,heapTotal:4,rss:68}},ping:{ok:!0,data:{pong:!0,time:1783035131368}},stats:{ok:!0,stats:{waiting:13,prioritized:7,delayed:6,active:2,dlq:2,completed:4,"waiting-children":0,totalPushed:34,totalPulled:8,totalCompleted:4,totalFailed:0,uptime:133882,cronJobs:2,cronPending:2,pushPerSec:.25,pullPerSec:.06,completePerSec:.03,failPerSec:0},memory:{heapUsed:3,heapTotal:4,rss:69,external:1,arrayBuffers:0},collections:{jobIndex:34,completedJobs:4,jobResults:0,jobLogs:0,customIdMap:0,jobLocks:0,clientJobs:0,clientJobsTotal:0,pendingDepChecks:0,stalledCandidates:0,processingTotal:2,queuedTotal:26,waitingDepsTotal:0,temporalIndexTotal:34,delayedHeapTotal:6}},storage:{ok:!0,data:{diskFull:!1,error:null,since:null}},dashboard:{ok:!0,stats:{waiting:13,active:2,delayed:6,completed:4,dlq:2,totalPushed:34,totalPulled:8,totalCompleted:4,totalFailed:0,uptime:133882},throughput:{pushPerSec:.25,pullPerSec:.06,completePerSec:.03,failPerSec:0},latency:{averages:{pushMs:.07645341176470588,pullMs:.3890205,ackMs:1.03645825},percentiles:{push:{p50:.1,p95:.5,p99:1},pull:{p50:.1,p95:1,p99:1},ack:{p50:2.5,p95:2.5,p99:2.5}}},memory:{heapUsed:3,heapTotal:4,rss:70},collections:{jobIndex:34,completedJobs:4,jobResults:0,jobLogs:0,customIdMap:0,jobLocks:0,clientJobs:0,clientJobsTotal:0,pendingDepChecks:0,stalledCandidates:0,processingTotal:2,queuedTotal:26,waitingDepsTotal:0,temporalIndexTotal:34,delayedHeapTotal:6},workers:{total:0,active:0,list:[],truncated:!1},crons:{total:2,list:[{name:`nightly-report`,jobName:`generate-report`,queue:`reports`,schedule:`0 2 * * *`,repeatEvery:null,nextRun:17830368e5,executions:0},{name:`heartbeat`,jobName:`send-heartbeat`,queue:`notifications`,schedule:null,repeatEvery:6e4,nextRun:1783035191362,executions:0}],truncated:!1},storage:{diskFull:!1,error:null,since:null},timestamp:1783035131369},dashboardQueues:{ok:!0,queues:[{name:`emails`,waiting:2,delayed:0,active:0,dlq:2,paused:!1},{name:`image-processing`,waiting:7,delayed:0,active:2,dlq:0,paused:!1},{name:`reports`,waiting:0,delayed:6,active:0,dlq:0,paused:!1},{name:`notifications`,waiting:4,delayed:0,active:0,dlq:0,paused:!1}],total:4,limit:100,offset:0,timestamp:1783035131370},queuesSummary:[{name:`emails`,paused:!1,counts:{waiting:2,prioritized:7,active:0,completed:4,failed:2,delayed:0}},{name:`image-processing`,paused:!1,counts:{waiting:7,prioritized:0,active:2,completed:0,failed:0,delayed:0}},{name:`reports`,paused:!1,counts:{waiting:0,prioritized:0,active:0,completed:0,failed:0,delayed:6}},{name:`notifications`,paused:!1,counts:{waiting:4,prioritized:0,active:0,completed:0,failed:0,delayed:0}}],crons:{ok:!0,crons:[{name:`nightly-report`,jobName:`generate-report`,queue:`reports`,schedule:`0 2 * * *`,repeatEvery:null,nextRun:17830368e5,executions:0,maxLimit:null,timezone:null},{name:`heartbeat`,jobName:`send-heartbeat`,queue:`notifications`,schedule:null,repeatEvery:6e4,nextRun:1783035191362,executions:0,maxLimit:null,timezone:null}]},webhooks:{ok:!0,data:{webhooks:[{id:`019f252c-f5e3-7000-883c-28cc5dc157a0`,url:`https://hooks.example.com/bunqueue`,events:[`job.completed`,`job.failed`],queue:null,createdAt:1783035131363,lastTriggered:178303512e4,successCount:42,failureCount:3,enabled:!0}],stats:{total:1,enabled:1}}},workers:{ok:!0,data:{workers:[],stats:{total:0,active:0,totalProcessed:0,totalFailed:0,activeJobs:0}}},dlqStats:{ok:!0,total:2,byQueue:{emails:2}},counts_emails:{ok:!0,counts:{waiting:2,prioritized:7,delayed:0,active:0,completed:4,failed:2,"waiting-children":0,paused:0}},dlq_emails:{ok:!0,entries:[{job:{id:`019f252b-8716-7000-bbec-d8c65e09f340`,queue:`emails`,data:{to:`user8@example.com`,subject:`Welcome 8`},createdAt:1783035037462,runAt:1783035037462,startedAt:1783035131364,completedAt:null,attempts:0,backoff:1e3,backoffConfig:null,dependsOn:[],childrenIds:[],childrenCompleted:0,tags:[],progress:0,progressMessage:null,stacktrace:null,repeat:null,lastHeartbeat:1783035131364,stallCount:0,priority:3,lifo:!1,maxAttempts:3,removeOnComplete:!1,removeOnFail:!1,ttl:null,timeout:null,uniqueKey:null,customId:null,parentId:null,groupId:null,stallTimeout:null,stackTraceLimit:10,keepLogs:null,sizeLimit:null,failParentOnFailure:!1,removeDependencyOnFailure:!1,continueParentOnFailure:!1,ignoreDependencyOnFailure:!1,deduplicationTtl:null,deduplicationExtend:!1,deduplicationReplace:!1,debounceId:null,debounceTtl:null,timeline:[{state:`prioritized`,timestamp:1783035037462},{state:`active`,timestamp:1783035131364}]},enteredAt:1783035131367,reason:`timeout`,error:`Job exceeded its 30000 ms timeout while connecting to smtp.example.com`,attempts:[{attempt:0,startedAt:1783035131364,failedAt:1783035131367,reason:`timeout`,error:`Job exceeded its 30000 ms timeout while connecting to smtp.example.com`,duration:3}],retryCount:0,lastRetryAt:null,nextRetryAt:null,expiresAt:1783639931367},{job:{id:`019f252b-8750-7000-afa1-767720d8f433`,queue:`emails`,data:{to:`user13@example.com`,subject:`Welcome 13`},createdAt:1783035037520,runAt:1783035037520,startedAt:1783035131364,completedAt:null,attempts:0,backoff:1e3,backoffConfig:null,dependsOn:[],childrenIds:[],childrenCompleted:0,tags:[],progress:0,progressMessage:null,stacktrace:null,repeat:null,lastHeartbeat:1783035131364,stallCount:0,priority:3,lifo:!1,maxAttempts:3,removeOnComplete:!1,removeOnFail:!1,ttl:null,timeout:null,uniqueKey:null,customId:null,parentId:null,groupId:null,stallTimeout:null,stackTraceLimit:10,keepLogs:null,sizeLimit:null,failParentOnFailure:!1,removeDependencyOnFailure:!1,continueParentOnFailure:!1,ignoreDependencyOnFailure:!1,deduplicationTtl:null,deduplicationExtend:!1,deduplicationReplace:!1,debounceId:null,debounceTtl:null,timeline:[{state:`prioritized`,timestamp:1783035037520},{state:`active`,timestamp:1783035131364}]},enteredAt:1783035131368,reason:`max_attempts`,error:`SMTP 550: mailbox unavailable (user13@example.com) — 3 of 3 attempts failed`,attempts:[{attempt:0,startedAt:1783035131364,failedAt:1783035131368,reason:`max_attempts`,error:`SMTP 550: mailbox unavailable (user13@example.com) — 3 of 3 attempts failed`,duration:4}],retryCount:0,lastRetryAt:null,nextRetryAt:null,expiresAt:1783639931368}],total:2},detail_emails:{ok:!0,name:`emails`,counts:{waiting:2,prioritized:7,delayed:0,active:0,completed:4,failed:2,"waiting-children":0,totalCompleted:4,totalFailed:0,paused:0},paused:!1,priorityCounts:{0:2,1:3,2:4},dlqPreview:[{id:`019f252b-8716-7000-bbec-d8c65e09f340`,data:{to:`user8@example.com`,subject:`Welcome 8`},attempts:0,createdAt:1783035037462},{id:`019f252b-8750-7000-afa1-767720d8f433`,data:{to:`user13@example.com`,subject:`Welcome 13`},attempts:0,createdAt:1783035037520}],timestamp:1783035131373,jobs:{waiting:[{id:`019f252b-86f2-7000-a45d-6e5e3dd4abf0`,priority:0,createdAt:1783035037426,runAt:1783035037426,attempts:0,progress:0},{id:`019f252b-872e-7000-91af-f820da905a23`,priority:0,createdAt:1783035037486,runAt:1783035037486,attempts:0,progress:0}],active:[],delayed:[],paused:[]}},"counts_image-processing":{ok:!0,counts:{waiting:7,prioritized:0,delayed:0,active:2,completed:0,failed:0,"waiting-children":0,paused:0}},"dlq_image-processing":{ok:!0,entries:[],total:0},"detail_image-processing":{ok:!0,name:`image-processing`,counts:{waiting:7,prioritized:0,delayed:0,active:2,completed:0,failed:0,"waiting-children":0,totalCompleted:0,totalFailed:0,paused:0},paused:!1,priorityCounts:{0:7},dlqPreview:[],timestamp:1783035131374,jobs:{waiting:[{id:`019f252b-8780-7000-9066-7f3a95bbb309`,priority:0,createdAt:1783035037568,runAt:1783035037568,attempts:0,progress:0},{id:`019f252b-878d-7000-9396-88a9de934b0c`,priority:0,createdAt:1783035037581,runAt:1783035037581,attempts:0,progress:0},{id:`019f252b-8799-7000-8433-2f4d874dfa3f`,priority:0,createdAt:1783035037593,runAt:1783035037593,attempts:0,progress:0},{id:`019f252b-87a5-7000-b3d2-48c6816be571`,priority:0,createdAt:1783035037605,runAt:1783035037605,attempts:0,progress:0}],active:[{id:`019f252b-8769-7000-bc44-cfc168232f53`,priority:0,createdAt:1783035037545,runAt:1783035037545,attempts:0,progress:0},{id:`019f252b-8775-7000-884a-63456175f48c`,priority:0,createdAt:1783035037557,runAt:1783035037557,attempts:0,progress:0}],delayed:[],paused:[]}},counts_reports:{ok:!0,counts:{waiting:0,prioritized:0,delayed:6,active:0,completed:0,failed:0,"waiting-children":0,paused:0}},dlq_reports:{ok:!0,entries:[],total:0},detail_reports:{ok:!0,name:`reports`,counts:{waiting:0,prioritized:0,delayed:6,active:0,completed:0,failed:0,"waiting-children":0,totalCompleted:0,totalFailed:0,paused:0},paused:!1,priorityCounts:{0:6},dlqPreview:[],timestamp:1783035131374,jobs:{waiting:[],active:[],delayed:[{id:`019f252b-87d8-7000-8f0c-e8ca5fec7d18`,priority:0,createdAt:1783035037656,runAt:1783035637656,attempts:0,progress:0},{id:`019f252b-87e3-7000-b0dc-18aac125e1ce`,priority:0,createdAt:1783035037667,runAt:1783035637667,attempts:0,progress:0},{id:`019f252b-87ee-7000-bb98-e9997d218441`,priority:0,createdAt:1783035037678,runAt:1783035637678,attempts:0,progress:0},{id:`019f252b-87fa-7000-9eb8-5b7a6d7aa7b4`,priority:0,createdAt:1783035037690,runAt:1783035637690,attempts:0,progress:0}],paused:[]}},counts_notifications:{ok:!0,counts:{waiting:4,prioritized:0,delayed:0,active:0,completed:0,failed:0,"waiting-children":0,paused:0}},dlq_notifications:{ok:!0,entries:[],total:0},detail_notifications:{ok:!0,name:`notifications`,counts:{waiting:4,prioritized:0,delayed:0,active:0,completed:0,failed:0,"waiting-children":0,totalCompleted:0,totalFailed:0,paused:0},paused:!1,priorityCounts:{0:4},dlqPreview:[],timestamp:1783035131375,jobs:{waiting:[{id:`019f252b-8823-7000-9455-de9cff6a56e2`,priority:0,createdAt:1783035037731,runAt:1783035037731,attempts:0,progress:0},{id:`019f252b-882e-7000-ae38-9c7fe01639d5`,priority:0,createdAt:1783035037742,runAt:1783035037742,attempts:0,progress:0},{id:`019f252b-883b-7000-8789-839b741a1011`,priority:0,createdAt:1783035037755,runAt:1783035037755,attempts:0,progress:0},{id:`019f252b-884d-7000-b703-96a357151ef4`,priority:0,createdAt:1783035037773,runAt:1783035037773,attempts:0,progress:0}],active:[],delayed:[],paused:[]}},emailsWaiting:{ok:!0,jobs:[{id:`019f252b-86c0-7000-a54e-3816c968ebf0`,queue:`emails`,data:{to:`user1@example.com`,subject:`Welcome 1`},createdAt:1783035037376,runAt:1783035037376,startedAt:null,completedAt:null,attempts:0,backoff:1e3,backoffConfig:null,dependsOn:[],childrenIds:[],childrenCompleted:0,tags:[],progress:0,progressMessage:null,stacktrace:null,repeat:null,lastHeartbeat:1783035037376,stallCount:0,priority:1,lifo:!1,maxAttempts:3,removeOnComplete:!1,removeOnFail:!1,ttl:null,timeout:null,uniqueKey:null,customId:null,parentId:null,groupId:null,stallTimeout:null,stackTraceLimit:10,keepLogs:null,sizeLimit:null,failParentOnFailure:!1,removeDependencyOnFailure:!1,continueParentOnFailure:!1,ignoreDependencyOnFailure:!1,deduplicationTtl:null,deduplicationExtend:!1,deduplicationReplace:!1,debounceId:null,debounceTtl:null,timeline:[{state:`prioritized`,timestamp:1783035037376}],_state:`prioritized`,state:`prioritized`},{id:`019f252b-86ce-7000-adfc-613a9495a6ef`,queue:`emails`,data:{to:`user2@example.com`,subject:`Welcome 2`},createdAt:1783035037390,runAt:1783035037390,startedAt:null,completedAt:null,attempts:0,backoff:1e3,backoffConfig:null,dependsOn:[],childrenIds:[],childrenCompleted:0,tags:[],progress:0,progressMessage:null,stacktrace:null,repeat:null,lastHeartbeat:1783035037390,stallCount:0,priority:2,lifo:!1,maxAttempts:3,removeOnComplete:!1,removeOnFail:!1,ttl:null,timeout:null,uniqueKey:null,customId:null,parentId:null,groupId:null,stallTimeout:null,stackTraceLimit:10,keepLogs:null,sizeLimit:null,failParentOnFailure:!1,removeDependencyOnFailure:!1,continueParentOnFailure:!1,ignoreDependencyOnFailure:!1,deduplicationTtl:null,deduplicationExtend:!1,deduplicationReplace:!1,debounceId:null,debounceTtl:null,timeline:[{state:`prioritized`,timestamp:1783035037390}],_state:`prioritized`,state:`prioritized`},{id:`019f252b-86fe-7000-894d-fe3ad935cc36`,queue:`emails`,data:{to:`user6@example.com`,subject:`Welcome 6`},createdAt:1783035037438,runAt:1783035037438,startedAt:null,completedAt:null,attempts:0,backoff:1e3,backoffConfig:null,dependsOn:[],childrenIds:[],childrenCompleted:0,tags:[],progress:0,progressMessage:null,stacktrace:null,repeat:null,lastHeartbeat:1783035037438,stallCount:0,priority:1,lifo:!1,maxAttempts:3,removeOnComplete:!1,removeOnFail:!1,ttl:null,timeout:null,uniqueKey:null,customId:null,parentId:null,groupId:null,stallTimeout:null,stackTraceLimit:10,keepLogs:null,sizeLimit:null,failParentOnFailure:!1,removeDependencyOnFailure:!1,continueParentOnFailure:!1,ignoreDependencyOnFailure:!1,deduplicationTtl:null,deduplicationExtend:!1,deduplicationReplace:!1,debounceId:null,debounceTtl:null,timeline:[{state:`prioritized`,timestamp:1783035037438}],_state:`prioritized`,state:`prioritized`},{id:`019f252b-870a-7000-91d2-ca4070505abe`,queue:`emails`,data:{to:`user7@example.com`,subject:`Welcome 7`},createdAt:1783035037450,runAt:1783035037450,startedAt:null,completedAt:null,attempts:0,backoff:1e3,backoffConfig:null,dependsOn:[],childrenIds:[],childrenCompleted:0,tags:[],progress:0,progressMessage:null,stacktrace:null,repeat:null,lastHeartbeat:1783035037450,stallCount:0,priority:2,lifo:!1,maxAttempts:3,removeOnComplete:!1,removeOnFail:!1,ttl:null,timeout:null,uniqueKey:null,customId:null,parentId:null,groupId:null,stallTimeout:null,stackTraceLimit:10,keepLogs:null,sizeLimit:null,failParentOnFailure:!1,removeDependencyOnFailure:!1,continueParentOnFailure:!1,ignoreDependencyOnFailure:!1,deduplicationTtl:null,deduplicationExtend:!1,deduplicationReplace:!1,debounceId:null,debounceTtl:null,timeline:[{state:`prioritized`,timestamp:1783035037450}],_state:`prioritized`,state:`prioritized`}]},emailsCompleted:{ok:!0,jobs:[{id:`019f252b-86da-7000-a9e3-6b1b74944d70`,queue:`emails`,data:{to:`user3@example.com`,subject:`Welcome 3`},createdAt:1783035037402,runAt:1783035037402,startedAt:1783035131364,completedAt:1783035131367,attempts:0,backoff:1e3,backoffConfig:null,dependsOn:[],childrenIds:[],childrenCompleted:0,tags:[],progress:0,progressMessage:null,stacktrace:null,repeat:null,lastHeartbeat:1783035131364,stallCount:0,priority:3,lifo:!1,maxAttempts:3,removeOnComplete:!1,removeOnFail:!1,ttl:null,timeout:null,uniqueKey:null,customId:null,parentId:null,groupId:null,stallTimeout:null,stackTraceLimit:10,keepLogs:null,sizeLimit:null,failParentOnFailure:!1,removeDependencyOnFailure:!1,continueParentOnFailure:!1,ignoreDependencyOnFailure:!1,deduplicationTtl:null,deduplicationExtend:!1,deduplicationReplace:!1,debounceId:null,debounceTtl:null,timeline:[{state:`prioritized`,timestamp:1783035037402},{state:`active`,timestamp:1783035131364},{state:`completed`,timestamp:1783035131367}],_state:`completed`,state:`completed`},{id:`019f252b-86e6-7000-a51e-e65a7cd2ce85`,queue:`emails`,data:{to:`user4@example.com`,subject:`Welcome 4`},createdAt:1783035037414,runAt:1783035037414,startedAt:1783035131364,completedAt:1783035131366,attempts:0,backoff:1e3,backoffConfig:null,dependsOn:[],childrenIds:[],childrenCompleted:0,tags:[],progress:0,progressMessage:null,stacktrace:null,repeat:null,lastHeartbeat:1783035131364,stallCount:0,priority:4,lifo:!1,maxAttempts:3,removeOnComplete:!1,removeOnFail:!1,ttl:null,timeout:null,uniqueKey:null,customId:null,parentId:null,groupId:null,stallTimeout:null,stackTraceLimit:10,keepLogs:null,sizeLimit:null,failParentOnFailure:!1,removeDependencyOnFailure:!1,continueParentOnFailure:!1,ignoreDependencyOnFailure:!1,deduplicationTtl:null,deduplicationExtend:!1,deduplicationReplace:!1,debounceId:null,debounceTtl:null,timeline:[{state:`prioritized`,timestamp:1783035037414},{state:`active`,timestamp:1783035131364},{state:`completed`,timestamp:1783035131366}],_state:`completed`,state:`completed`},{id:`019f252b-8722-7000-9270-14be63598def`,queue:`emails`,data:{to:`user9@example.com`,subject:`Welcome 9`},createdAt:1783035037474,runAt:1783035037474,startedAt:1783035131364,completedAt:1783035131366,attempts:0,backoff:1e3,backoffConfig:null,dependsOn:[],childrenIds:[],childrenCompleted:0,tags:[],progress:0,progressMessage:null,stacktrace:null,repeat:null,lastHeartbeat:1783035131364,stallCount:0,priority:4,lifo:!1,maxAttempts:3,removeOnComplete:!1,removeOnFail:!1,ttl:null,timeout:null,uniqueKey:null,customId:null,parentId:null,groupId:null,stallTimeout:null,stackTraceLimit:10,keepLogs:null,sizeLimit:null,failParentOnFailure:!1,removeDependencyOnFailure:!1,continueParentOnFailure:!1,ignoreDependencyOnFailure:!1,deduplicationTtl:null,deduplicationExtend:!1,deduplicationReplace:!1,debounceId:null,debounceTtl:null,timeline:[{state:`prioritized`,timestamp:1783035037474},{state:`active`,timestamp:1783035131364},{state:`completed`,timestamp:1783035131366}],_state:`completed`,state:`completed`},{id:`019f252b-875b-7000-8f4b-3d571d84663d`,queue:`emails`,data:{to:`user14@example.com`,subject:`Welcome 14`},createdAt:1783035037531,runAt:1783035037531,startedAt:1783035131364,completedAt:1783035131367,attempts:0,backoff:1e3,backoffConfig:null,dependsOn:[],childrenIds:[],childrenCompleted:0,tags:[],progress:0,progressMessage:null,stacktrace:null,repeat:null,lastHeartbeat:1783035131364,stallCount:0,priority:4,lifo:!1,maxAttempts:3,removeOnComplete:!1,removeOnFail:!1,ttl:null,timeout:null,uniqueKey:null,customId:null,parentId:null,groupId:null,stallTimeout:null,stackTraceLimit:10,keepLogs:null,sizeLimit:null,failParentOnFailure:!1,removeDependencyOnFailure:!1,continueParentOnFailure:!1,ignoreDependencyOnFailure:!1,deduplicationTtl:null,deduplicationExtend:!1,deduplicationReplace:!1,debounceId:null,debounceTtl:null,timeline:[{state:`prioritized`,timestamp:1783035037531},{state:`active`,timestamp:1783035131364},{state:`completed`,timestamp:1783035131367}],_state:`completed`,state:`completed`}]},oneJob:{ok:!0,job:{id:`019f252b-8716-7000-bbec-d8c65e09f340`,queue:`emails`,data:{to:`user8@example.com`,subject:`Welcome 8`},createdAt:1783035037462,runAt:1783035037462,startedAt:1783035131364,completedAt:null,attempts:0,backoff:1e3,backoffConfig:null,dependsOn:[],childrenIds:[],childrenCompleted:0,tags:[],progress:0,progressMessage:null,stacktrace:null,repeat:null,lastHeartbeat:1783035131364,stallCount:0,priority:3,lifo:!1,maxAttempts:3,removeOnComplete:!1,removeOnFail:!1,ttl:null,timeout:null,uniqueKey:null,customId:null,parentId:null,groupId:null,stallTimeout:null,stackTraceLimit:10,keepLogs:null,sizeLimit:null,failParentOnFailure:!1,removeDependencyOnFailure:!1,continueParentOnFailure:!1,ignoreDependencyOnFailure:!1,deduplicationTtl:null,deduplicationExtend:!1,deduplicationReplace:!1,debounceId:null,debounceTtl:null,timeline:[{state:`prioritized`,timestamp:1783035037462},{state:`active`,timestamp:1783035131364}],state:`failed`}}},T=e=>w[e]?.jobs??[],E=w.oneJob.job,D=[...T(`emailsWaiting`),...T(`emailsCompleted`),...E?[E]:[]],te=[`emails`,`image-processing`,`reports`,`notifications`];function O(e,t,n){let r={...e,name:typeof e.name==`string`?e.name:`${t}-job`,...e.state===`completed`&&!Object.hasOwn(e,`returnvalue`)?{returnvalue:{ok:!0}}:{},...e.state===`failed`&&!Object.hasOwn(e,`failedReason`)?{failedReason:`Demo job exhausted its retries`}:{}};return t===`emails`?r:{...r,id:`${t}-${String(e.id).slice(-12)}-${n}`,queue:t}}function k(e){if(b[e])return b[e];let t=D.find(t=>t.id===e);if(t)return O(t,`emails`,0);for(let t of te){let n=D.map((e,n)=>O(e,t,n)).find(t=>t.id===e);if(n)return n}return{...E??{queue:`emails`,state:`failed`},id:e,customId:e.startsWith(`demo-custom:`)?e.slice(12):null}}var A=[{id:`wf-order-2026-0804`,workflowName:`order-fulfillment`,state:`running`,currentNodeIndex:3,createdAt:178583892e4,updatedAt:178583904e4,definitionHash:`sha256:8a03c8e91db4d8f5`,input:{orderId:`ord_9a3f`,customerId:`cus_417`,total:129.9},steps:{validate:{status:`completed`,attempts:1,startedAt:1785838920100,completedAt:1785838920210,result:{valid:!0}},charge:{status:`completed`,attempts:1,startedAt:1785838920300,completedAt:1785838921120,compensatable:!0,idempotencyKey:`charge:ord_9a3f`,result:{paymentId:`pay_802`}},reserveInventory:{status:`completed`,attempts:2,startedAt:1785838921200,completedAt:1785838930600,compensatable:!0,result:{reservationId:`res_551`}},ship:{status:`running`,attempts:1,startedAt:178583904e4,childExecutionId:`wf-shipping-0804`}},resolvedSteps:[`validate`,`charge`,`reserveInventory`,`ship`],signals:{},decisions:{"branch:payment":`card`}},{id:`wf-refund-2026-0803`,workflowName:`refund-order`,state:`compensation-stuck`,currentNodeIndex:4,createdAt:17857512e5,updatedAt:178575132e4,rollbackStatus:`stuck`,failureReason:`Refund provider unavailable after 3 attempts`,definitionHash:`sha256:cc89ab41c1b2f011`,input:{orderId:`ord_772`,reason:`customer_request`},steps:{loadOrder:{status:`completed`,attempts:1,result:{paymentId:`pay_331`}},revokeShipment:{status:`completed`,attempts:1,compensatable:!0,compensation:{status:`compensated`,at:1785751300100}},refundPayment:{status:`failed`,attempts:3,compensatable:!0,error:`Provider timeout`,compensation:{status:`compensation-failed`,at:178575132e4,error:`Provider unavailable`}}},resolvedSteps:[`loadOrder`,`revokeShipment`,`refundPayment`],signals:{approved:{actor:`ops@example.com`}},decisions:{"branch:refund-method":`original-payment`}},{id:`wf-signup-2026-0802`,workflowName:`customer-onboarding`,state:`waiting`,currentNodeIndex:2,createdAt:17856648e5,updatedAt:178566492e4,input:{customerId:`cus_881`,plan:`pro`},steps:{createAccount:{status:`completed`,attempts:1,result:{accountId:`acc_881`}},sendVerification:{status:`completed`,attempts:1,result:{messageId:`msg_194`}}},resolvedSteps:[`createAccount`,`sendVerification`],signals:{}}],j=[{id:`wf-month-close-2026-07`,workflowName:`month-end-close`,state:`completed`,currentNodeIndex:4,createdAt:17855784e5,updatedAt:1785578465e3,archivedAt:17856648e5,rollbackStatus:`not-applicable`,definitionHash:`sha256:78b6fd851d8b32a1`,input:{period:`2026-07`},steps:{lockPeriod:{status:`completed`,attempts:1,result:{locked:!0}},aggregate:{status:`completed`,attempts:1,result:{entries:1842}},publish:{status:`completed`,attempts:1,result:{reportId:`rep_2026_07`}}},resolvedSteps:[`lockPeriod`,`aggregate`,`publish`],signals:{},decisions:{}},{id:`wf-import-legacy-441`,workflowName:`legacy-import`,state:`failed`,currentNodeIndex:1,createdAt:1785492e6,updatedAt:1785492009e3,archivedAt:17856648e5,rollbackStatus:`not-applicable`,failureReason:`Input schema rejected row 441`,input:{batch:`legacy-2026-07`},steps:{validate:{status:`failed`,attempts:1,error:`Invalid customer reference at row 441`}},resolvedSteps:[`validate`],signals:{},decisions:{}}],ne={configured:!0,ready:!0,moduleName:`demo-workflows`,workflowNames:[`customer-onboarding`,`order-fulfillment`,`refund-order`]},M=e=>({ok:!0,result:e});function re(e,t){return e[1]===`runtime`&&(e.length===2||e[2]===`reload`)?M(ne):t===`POST`?e[1]===`start`?M({run:{id:`wf-demo-started`,workflowName:`order-fulfillment`}}):e[1]===`recover`?M({recovered:{running:1,waiting:1,compensating:0,total:2}}):e[1]===`archive`||e[1]===`cleanup`?M({affected:1}):e[2]===`signal`||e[2]===`resume-compensation`||e[2]===`abandon-compensation`?M({applied:!0}):null:null}function ie(e,t,n){let r=re(e,n);if(r)return r;if(e[1]===`stats`){let e={running:0,waiting:0,completed:0,failed:0,compensating:0,"compensation-stuck":0};for(let t of A)e[t.state]++;return{ok:!0,available:!0,activeTotal:A.length,archiveTotal:j.length,states:e,workflowNames:[...new Set([...A,...j].map(e=>String(e.workflowName)))].sort()}}let i=new URLSearchParams(t),a=i.get(`kind`)===`archive`?j:A;if(e[1]){let t=a.find(t=>t.id===decodeURIComponent(e[1]));return t?{ok:!0,execution:t}:{ok:!1,error:`Workflow execution not found`}}let o=i.get(`workflowName`),s=i.get(`state`),c=Number(i.get(`offset`)??0),l=Number(i.get(`limit`)??50),u=a.filter(e=>(!o||e.workflowName===o)&&(!s||e.state===s||s===`compensation`&&(e.state===`compensating`||e.state===`compensation-stuck`)));return{ok:!0,available:!0,executions:u.slice(c,c+l).map(({input:e,steps:t,resolvedSteps:n,signals:r,decisions:i,...a})=>a),total:u.length,limit:l,offset:c}}var ae=new Set([`events`,`health`,`healthz`,`live`,`ready`,`ping`,`stats`,`metrics`,`storage`,`dashboard`,`queues`,`queue-operations`,`jobs`,`crons`,`webhooks`,`workers`,`dlq`,`control`,`db`,`workflows`,`flows`,`backup`,`gc`,`heapstats`]);function oe(e,t){if(e[0]!==`queues`||!e[1])return null;let n=decodeURIComponent(e[1]);if(e[2]===`counts`)return w[`counts_${n}`]??{ok:!0,counts:{}};if(e[2]===`dlq`&&e[3]===`stats`)return{ok:!0,stats:n===`emails`?{total:2,byReason:{timeout:1,max_attempts:1}}:{total:0,byReason:{}}};if(e[2]===`dlq`)return w[`dlq_${n}`]??{ok:!0,entries:[],total:0};if(e[2]===`stall-config`)return{ok:!0,config:{enabled:!0,stallInterval:3e4,maxStalls:3,gracePeriod:5e3}};if(e[2]===`dlq-config`)return{ok:!0,config:{autoRetry:!1,autoRetryInterval:6e4,maxAutoRetries:3,maxAge:null,maxEntries:1e3}};if(e[2]!==`jobs`||e[3]!==`list`)return null;let r=new URLSearchParams(t),i=(r.get(`states`)??r.get(`state`)??``).split(`,`).map(e=>e.trim()).filter(Boolean),a=e=>i.length===0||i.includes(String(e))||i.includes(`waiting`)&&e===`prioritized`;return{ok:!0,jobs:D.filter(e=>a(e.state)).map((e,t)=>O(e,n,t))}}function N(e){let t=w.dashboardQueues,n=Array.isArray(t.queues)?t.queues:[],r=new URLSearchParams(e),i=Number(r.get(`limit`)??t.limit),a=Number(r.get(`offset`)??t.offset),o=Number.isSafeInteger(i)&&i>=0?i:Number(t.limit),s=Number.isSafeInteger(a)&&a>=0?a:Number(t.offset);return{...t,queues:n.slice(s,s+o),total:n.length,limit:o,offset:s}}function P(e){if(e[0]!==`jobs`||!e[1])return null;let t=decodeURIComponent(e[1]);if(e[1]===`custom`&&e[2])return{ok:!0,job:k(`demo-custom:${decodeURIComponent(e[2])}`)};if(e[2]===`result`)return{ok:!0,id:t,result:{sent:!0,provider:`demo`}};if(e[2]===`logs`){let e=[`[info] picked up by worker-emails-1`,`[info] connecting to smtp.example.com:587`,`[error] SMTP 550: mailbox unavailable — will retry with backoff`];return{ok:!0,data:{logs:e,count:e.length}}}return e[2]?null:{ok:!0,job:k(t)}}function F(e,t){if(e[0]!==`db`)return null;if(e[1]===`info`)return o;if(e[1]===`tables`&&!e[2])return l;if(e[1]!==`tables`||!e[2])return null;let n=decodeURIComponent(e[2]);return e[3]===`schema`?u(n):e[3]===`cell`?{ok:!0,value:`demo cell value`}:p(n,t)}function I(e,t){return e===`/gc`?{ok:!0,before:{heapUsed:118,heapTotal:176,rss:214},after:{heapUsed:94,heapTotal:150,rss:181}}:e.endsWith(`/db/query`)?{ok:!0,columns:[`note`],rows:[[`This is the demo. Queries run against a static in-memory sample.`]],rowCount:1,truncated:!1,ms:.4}:e.endsWith(`/jobs`)||e.endsWith(`/jobs/bulk`)?{ok:!0,id:`demo-${t.join(`-`)}`,ids:[`demo-1`]}:{ok:!0}}function L(e,o,s){let c=e.replace(/\/+$/,``)||`/`,l=c.split(`/`).filter(Boolean);if(l[0]===`control`)return l[1]===`logs`?a():l[1]===`config`?n:r();if(l[0]===`workflows`)return ie(l,s,o);if(l[0]===`backup`)return t(l,o);if(l[0]===`flows`)return S(l,o,s);if(o!==`GET`)return I(c,l);if(c===`/workers`)return i();if(c===`/ready`)return{ok:!0,ready:!0};if(c===`/metrics`){let e=w.stats.stats;return{ok:!0,metrics:{totalPushed:e.totalPushed,totalPulled:e.totalPulled,totalCompleted:e.totalCompleted,totalFailed:e.totalFailed}}}if(c===`/heapstats`)return{ok:!0,memory:{heapUsed:94,heapTotal:150,rss:181},heap:{objectCount:486204,protectedCount:1284,globalCount:312},collections:{},topObjectTypes:[{type:`Structure`,count:42118},{type:`Object`,count:31064},{type:`Function`,count:18902},{type:`string`,count:12447},{type:`Array`,count:8021}]};if(c===`/dashboard/queues`)return N(s);let u={"/health":`health`,"/ping":`ping`,"/stats":`stats`,"/storage":`storage`,"/dashboard":`dashboard`,"/queues/summary":`queuesSummary`,"/crons":`crons`,"/webhooks":`webhooks`,"/dlq/stats":`dlqStats`};return u[c]?w[u[c]]:l[0]===`dashboard`&&l[1]===`queues`&&l[2]?w[`detail_${l[2]}`]??w.detail_emails:oe(l,s)??P(l)??F(l,s)??{ok:!0}}var R=(e,t=200)=>new Response(JSON.stringify(e),{status:t,headers:{"Content-Type":`application/json`}});function z(e){let t=new TextEncoder,n=[`emails`,`image-processing`,`reports`,`notifications`],r=[`job:active`,`job:completed`,`job:completed`,`job:waiting`,`job:failed`,`job:active`],i=new ReadableStream({start(i){let a=0,o=!1,s,c=()=>{if(!o){o=!0,clearInterval(s);try{i.close()}catch{}}};i.enqueue(t.encode(`data: {"connected":true}
|
|
2
|
+
|
|
3
|
+
`)),s=setInterval(()=>{if(o)return;let e=r[a%r.length],s=n[a%n.length],l=JSON.stringify({queue:s,jobId:`demo-${a}`,name:s,timestamp:Date.now()});try{i.enqueue(t.encode(`event: ${e}\ndata: ${l}\n\n`))}catch{c()}a+=1},1400),e?.aborted?c():e?.addEventListener(`abort`,c,{once:!0})}});return new Response(i,{status:200,headers:{"Content-Type":`text/event-stream`}})}var B={emails:{rateLimit:null,concurrency:10,activeJobs:0,consumedJobs:0,cooldownMs:0,events:1284,completed:[2,1,0,1],failed:[1,0,1],deduplications:[[`welcome:user8@example.com`,`019f252b-86c0-7000-a54e-3816c968ebf0`]]},"image-processing":{rateLimit:{max:100,duration:6e4},concurrency:4,activeJobs:2,consumedJobs:100,cooldownMs:750,events:1428,completed:[7,9,4,6,3],failed:[0,1,0,0,1],deduplications:[[`asset:hero`,`019f252b-8769-7000-bc44-cfc168232f53`]]},reports:{rateLimit:null,concurrency:2,activeJobs:0,consumedJobs:0,cooldownMs:0,events:318,completed:[1,0,2],failed:[1],deduplications:[]},notifications:{rateLimit:null,concurrency:8,activeJobs:0,consumedJobs:0,cooldownMs:0,events:612,completed:[5,4,3],failed:[],deduplications:[]}},V={rateLimit:null,concurrency:null,activeJobs:0,consumedJobs:0,cooldownMs:0,events:0,completed:[],failed:[],deduplications:[]},H=8*1024,U=1e4,W=1e6,G=1783035039e3;function K(){let e=new Map,t=t=>{let n=e.get(t);if(n)return n;let r=B[t]??V,i={...r,deduplications:new Map(r.deduplications)};return e.set(t,i),i};return async(e,n)=>{try{let r=await se(e,n,t);return r?R(r):de()}catch(e){return R({ok:!1,error:fe(e)},400)}}}async function se(e,t,n){let r=t.replace(/\/+$/,``).split(`/`).filter(Boolean);if(r[0]!==`queue-operations`||r.length<3)return null;let i=le(decodeURIComponent(r[1])),a=r.slice(2).join(`/`),o=n(i);if(e.method===`GET`&&a===`limits`){let t=X(q(e,[`target`,`maxJobs`]).get(`maxJobs`),`maxJobs`,0,1e6),n=o.rateLimit===null?-2:t!==void 0&&o.consumedJobs<t?0:o.cooldownMs;return{ok:!0,limits:{rateLimit:o.rateLimit,concurrency:o.concurrency,rateLimitTtl:n,maxed:o.concurrency!==null&&o.activeJobs>=o.concurrency}}}if(e.method===`GET`&&a===`deduplication`){let t=Y(q(e,[`target`,`deduplicationId`]).get(`deduplicationId`));return{ok:!0,jobId:o.deduplications.get(t)??null}}if(e.method===`GET`&&a===`metrics`){let t=q(e,[`target`,`type`,`start`,`end`]),n=ue(t.get(`type`)),r=X(t.get(`start`),`start`,0,U)??0,i=X(t.get(`end`),`end`,-1,U)??-1;if(i!==-1&&i<r)throw Error(`Metrics end must be -1 or at least start`);return{ok:!0,metrics:ce(o[n],r,i)}}if(e.method===`POST`&&a===`deduplication/remove`){q(e,[`target`]);let t=Y((await J(e,[`deduplicationId`])).deduplicationId);return{ok:!0,removed:+!!o.deduplications.delete(t)}}if(e.method===`POST`&&a===`events/trim`){q(e,[`target`]);let t=Z((await J(e,[`maxLength`])).maxLength,`maxLength`,0,W),n=Math.max(0,o.events-t);return o.events-=n,{ok:!0,removed:n}}return null}function ce(e,t,n){let r=n===-1?e.length:Math.min(e.length,n+1);return{meta:{count:e.reduce((e,t)=>e+t,0),prevTS:e.length?G:0,prevCount:e[0]??0},data:t>=r?[]:e.slice(t,r),count:e.length}}function q(e,t){let n=new URL(e.url).searchParams;for(let e of n.keys()){if(!t.includes(e))throw Error(`Unknown Queue operation option: ${e}`);if(n.getAll(e).length!==1)throw Error(`Duplicate Queue operation option: ${e}`)}if(!n.get(`target`))throw Error(`Queue operation target is required`);return n}async function J(e,t){let n=await e.text();if(new TextEncoder().encode(n).byteLength>H)throw Error(`Queue operation request body exceeds 8 KiB`);let r;try{r=JSON.parse(n)}catch{throw Error(`Queue operation request must be valid JSON`)}if(!Q(r))throw Error(`Queue operation request must be an object`);let i=Object.keys(r).find(e=>!t.includes(e));if(i)throw Error(`Unknown Queue operation body field: ${i}`);return r}function le(e){if(!e||e.length>256||e===`.`||e===`..`||!/^[\w.:-]+$/.test(e))throw Error(`Queue name must contain 1-256 letters, numbers, underscores, dashes, dots or colons`);return e}function Y(e){if(typeof e!=`string`||!e||e.length>1024)throw Error(`Deduplication ID must contain 1-1024 characters`);return e}function ue(e){if(e!==`completed`&&e!==`failed`)throw Error(`Metrics type must be completed or failed`);return e}function X(e,t,n,r){if(e!==null){if(!/^-?\d+$/.test(e))throw Error(`${t} must be an integer`);return Z(Number(e),t,n,r)}}function Z(e,t,n,r){if(!Number.isSafeInteger(e)||e<n||e>r)throw Error(`${t} must be an integer from ${n} to ${r}`);return e}function Q(e){return!!e&&typeof e==`object`&&!Array.isArray(e)}function de(){return R({ok:!1,error:`Unknown Queue operation`},404)}var fe=e=>e instanceof Error?e.message:String(e),$=!1;function pe(){if($||typeof window>`u`)return()=>void 0;$=!0;let e=window.fetch,t=e.bind(window),n=`/`.replace(/\/+$/,``),r=K(),i=async(e,i)=>{let a=e instanceof Request?e:null,o=typeof e==`string`?e:e instanceof URL?e.href:a?.url??``,s=(i?.method??a?.method??`GET`).toUpperCase(),c;try{c=new URL(o,window.location.origin)}catch{return t(e,i)}let l=c.pathname;n&&(l===n||l.startsWith(`${n}/`))&&(l=l.slice(n.length)||`/`),(l===`/api`||l.startsWith(`/api/`))&&(l=l.slice(4)||`/`);let u=l.split(`/`).filter(Boolean)[0];if(!u||!ae.has(u))return t(e,i);if(u===`queue-operations`)try{let t=e instanceof Request?new Request(e,i):new Request(c,i);return await r(t,l)}catch(e){return R({ok:!1,error:`Invalid Queue operation request: ${e instanceof Error?e.message:String(e)}`},400)}if(u===`events`)return z(i?.signal??a?.signal);if(u===`healthz`||u===`live`)return new Response(`OK`,{status:200});if(s===`GET`){let e=l.replace(/\/+$/,``).split(`/`).filter(Boolean);if(e.length===4&&e[0]===`db`&&e[1]===`tables`&&e[3]===`export`)return y(decodeURIComponent(e[2]),c.search)}return R(L(l,s,c.search))};window.fetch=i;let a=!1;return()=>{a||(a=!0,window.fetch===i&&(window.fetch=e),$=!1)}}export{pe as installDemo};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{i as e}from"./cn-zFEt5SO8.js";import{g as t}from"./react-vendor-CyjgmGTq.js";import{o as n}from"./connectionStore-CKFQrxDo.js";var r=e(t(),1);function i(e){let t=!0;return()=>t?(t=!1,!0):!e()}function a(e,t=[],a={}){let o=n(e=>e.refreshMs),s=n(e=>JSON.stringify([e.baseUrl,e.token,e.agentToken])),c=a.intervalMs??o,l=(0,r.useRef)(null),u=(0,r.useRef)(0),d=[s,...t];(l.current===null||l.current.length!==d.length||l.current.some((e,t)=>!Object.is(e,d[t])))&&(l.current=d,u.current+=1);let f=u.current,[p,m]=(0,r.useState)(null),[h,g]=(0,r.useState)(null),[_,v]=(0,r.useState)(!0),y=(0,r.useRef)(e);y.current=e;let b=(0,r.useRef)(!0),x=(0,r.useRef)(0),S=(0,r.useRef)(void 0),C=(0,r.useRef)(!0),w=(0,r.useRef)(!1),T=(0,r.useRef)(0),E=(0,r.useRef)(0),D=(0,r.useRef)(()=>Promise.resolve()),O=(0,r.useCallback)(async(e,t,n)=>{try{let r=await y.current(n);if(!b.current||e!==x.current)return;let i;try{i=JSON.stringify(r)}catch{i=String(Math.random())}i===S.current?T.current=t:(S.current=i,T.current=t,m(r)),w.current&&(w.current=!1,E.current=0,g(null))}catch(n){if(!b.current||e!==x.current)return;w.current=!0,E.current=t,g(n)}finally{b.current&&e===x.current&&C.current&&(C.current=!1,v(!1))}},[]),k=(0,r.useCallback)(()=>D.current(),[]);(0,r.useEffect)(()=>{b.current=!0;let e=++x.current,t=new AbortController;S.current=void 0,C.current=!0,m(null),v(!0),w.current&&(w.current=!1,g(null));let n=null,r=!1,a=!1,o=!1,s=[],l=()=>
|
|
1
|
+
import{i as e}from"./cn-zFEt5SO8.js";import{g as t}from"./react-vendor-CyjgmGTq.js";import{o as n}from"./connectionStore-CKFQrxDo.js";var r=e(t(),1);function i(e){let t=!0;return()=>t?(t=!1,!0):!e()}function a(e,t=[],a={}){let o=n(e=>e.refreshMs),s=n(e=>JSON.stringify([e.baseUrl,e.token,e.agentToken])),c=a.intervalMs??o,l=(0,r.useRef)(null),u=(0,r.useRef)(0),d=[s,...t];(l.current===null||l.current.length!==d.length||l.current.some((e,t)=>!Object.is(e,d[t])))&&(l.current=d,u.current+=1);let f=u.current,[p,m]=(0,r.useState)(null),[h,g]=(0,r.useState)(null),[_,v]=(0,r.useState)(!0),y=(0,r.useRef)(e);y.current=e;let b=(0,r.useRef)(!0),x=(0,r.useRef)(0),S=(0,r.useRef)(void 0),C=(0,r.useRef)(!0),w=(0,r.useRef)(!1),T=(0,r.useRef)(0),E=(0,r.useRef)(0),D=(0,r.useRef)(()=>Promise.resolve()),O=(0,r.useCallback)(async(e,t,n)=>{try{let r=await y.current(n);if(!b.current||e!==x.current)return;let i;try{i=JSON.stringify(r)}catch{i=String(Math.random())}i===S.current?T.current=t:(S.current=i,T.current=t,m(r)),w.current&&(w.current=!1,E.current=0,g(null))}catch(n){if(!b.current||e!==x.current)return;w.current=!0,E.current=t,g(n)}finally{b.current&&e===x.current&&C.current&&(C.current=!1,v(!1))}},[]),k=(0,r.useCallback)(()=>D.current(),[]);(0,r.useEffect)(()=>{b.current=!0;let e=++x.current,t=new AbortController;S.current=void 0,C.current=!0,m(null),v(!0),w.current&&(w.current=!1,g(null));let n=null,r=!1,a=!1,o=!1,s=[],l=()=>globalThis.document?.hidden??!1,u=i(l),d=()=>{n!==null&&clearTimeout(n),n=null},p=()=>{r||(d(),n=setTimeout(()=>{n=null,_(!1)},c))},h=async()=>{a=!0;try{await O(e,f,t.signal)}finally{if(a=!1,!r)if(o){o=!1;let e=s;s=[],_(!0).finally(()=>{for(let t of e)t()})}else p()}};function _(e){return r?Promise.resolve():a?e?(o=!0,new Promise(e=>s.push(e))):Promise.resolve():(d(),!e&&!u()?(p(),Promise.resolve()):h())}let y=()=>_(!0);D.current=y,_(!1);let T=()=>{l()||r||a||_(!0)};return typeof document<`u`&&document.addEventListener(`visibilitychange`,T),()=>{r=!0,b.current=!1,t.abort(),d();for(let e of s)e();s=[],D.current===y&&(D.current=()=>Promise.resolve()),x.current===e&&(x.current+=1),typeof document<`u`&&document.removeEventListener(`visibilitychange`,T)}},[c,f,O]);let A=T.current===f,j=E.current===f;return{data:A?p:null,error:j?h:null,loading:A||j?_:!0,refetch:k}}export{a as n,i as t};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{i as e}from"./cn-zFEt5SO8.js";import{g as t}from"./react-vendor-CyjgmGTq.js";import{o as n}from"./connectionStore-CKFQrxDo.js";import{t as r}from"./bq-Bmysbg0r.js";import{t as i}from"./usePolledData-g80Z_UB-.js";var a=e(t(),1),o=1e3,s={push:[],complete:[],fail:[],depth:[]},c=()=>typeof performance<`u`?performance.now():Date.now(),l=(e,t)=>`${e}\u0000${t}`;function u(e=60){let t=l(n(e=>e.baseUrl),n(e=>e.token)),[u,d]=(0,a.useState)(s),[f,p]=(0,a.useState)(null),[m,h]=(0,a.useState)(null),g=(0,a.useRef)(0),_=(0,a.useRef)(0),v=(0,a.useRef)(t),y=v.current===t;return(0,a.useEffect)(()=>{let n=++g.current,a=new AbortController,l=!1;v.current!==t&&(v.current=t,d(s),p(null),h(null),_.current=0);let u=i(()=>globalThis.document?.hidden??!1),f=async()=>{if(l||!u())return;l=!0;let t=c();try{let[i,c]=await Promise.all([r.overview({signal:a.signal}),r.stats({signal:a.signal})]);if(a.signal.aborted||g.current!==n)return;let l=i?.stats,u=i?.throughput,f=c?.stats;if(!l||!u||!f)throw Error(`malformed telemetry body`);if(![l.waiting,l.active,l.delayed,l.completed,l.dlq,l.totalPushed,l.totalPulled,l.totalCompleted,l.totalFailed,l.uptime,u.pushPerSec,u.completePerSec,u.failPerSec,f.waiting,f.prioritized,f.active,f.delayed,f[`waiting-children`]].every(e=>typeof e==`number`&&Number.isFinite(e)))throw Error(`malformed telemetry numeric metrics`);let m=u.pushPerSec,v=u.completePerSec,y=u.failPerSec,b=f.waiting+f.prioritized+f.active+f.delayed+f[`waiting-children`],x=_.current>0&&t-_.current>4*o;_.current=t,p(i),h(null),d(t=>{let n=x?s:t;return{push:[...n.push,m].slice(-e),complete:[...n.complete,v].slice(-e),fail:[...n.fail,y].slice(-e),depth:[...n.depth,b].slice(-e)}})}catch(e){!a.signal.aborted&&g.current===n&&h(e)}finally{l=!1}};f();let m=setInterval(f,o);return()=>{clearInterval(m),a.abort(),g.current===n&&(g.current+=1)}},[e,t]),y?{...u,latest:f,error:m}:{...s,latest:null,error:null}}function d(e,t=o){if(e.length<2)return{slope:0,label:`steady`,draining:!1};let n=e.length,r=(n-1)/2,i=e.reduce((e,t)=>e+t,0)/n,a=0,s=0;for(let t=0;t<n;t++)a+=(t-r)*(e[t]-i),s+=(t-r)**2;let c=s===0?0:a/s,l=t>0?o/t*c:c,u=l<-.05;return{slope:l,label:u?`draining`:l>.05?`accumulating`:`steady`,draining:u}}export{u as n,d as t};
|
package/dist/index.html
CHANGED
|
@@ -46,16 +46,16 @@
|
|
|
46
46
|
content="Fully drive a bunqueue server from one UI: queues, jobs, DLQ, cron, webhooks, workers, and start/stop/restart. Live demo, no signup."
|
|
47
47
|
/>
|
|
48
48
|
<meta name="twitter:image" content="https://egeominotti.github.io/bunqueue-dashboard/og.png" />
|
|
49
|
-
<script type="module" crossorigin src="/assets/index-
|
|
49
|
+
<script type="module" crossorigin src="/assets/index-Cue53Myw.js"></script>
|
|
50
50
|
<link rel="modulepreload" crossorigin href="/assets/cn-zFEt5SO8.js">
|
|
51
51
|
<link rel="modulepreload" crossorigin href="/assets/react-vendor-CyjgmGTq.js">
|
|
52
52
|
<link rel="modulepreload" crossorigin href="/assets/connectionStore-CKFQrxDo.js">
|
|
53
53
|
<link rel="modulepreload" crossorigin href="/assets/upstreamPaths-CDVsu6IM.js">
|
|
54
|
-
<link rel="modulepreload" crossorigin href="/assets/bq-
|
|
54
|
+
<link rel="modulepreload" crossorigin href="/assets/bq-Bmysbg0r.js">
|
|
55
55
|
<link rel="modulepreload" crossorigin href="/assets/toastStore-B7n0zS0y.js">
|
|
56
56
|
<link rel="modulepreload" crossorigin href="/assets/icons-CIvFfU2b.js">
|
|
57
57
|
<link rel="modulepreload" crossorigin href="/assets/api-V_sVpHDo.js">
|
|
58
|
-
<link rel="modulepreload" crossorigin href="/assets/usePolledData-
|
|
58
|
+
<link rel="modulepreload" crossorigin href="/assets/usePolledData-g80Z_UB-.js">
|
|
59
59
|
<link rel="modulepreload" crossorigin href="/assets/Button-BPqpRZJD.js">
|
|
60
60
|
<link rel="modulepreload" crossorigin href="/assets/Card-C7NMhqUt.js">
|
|
61
61
|
<link rel="modulepreload" crossorigin href="/assets/feedback-BnGE2oW2.js">
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "bunqueue-dashboard",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.38",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"description": "Web dashboard for a bunqueue server (queues, jobs, DLQ, cron, metrics, workers, live activity). Run with `bunx bunqueue-dashboard` (requires Bun).",
|
|
6
6
|
"bin": {
|
|
@@ -69,9 +69,12 @@
|
|
|
69
69
|
"test:e2e": "bun run test:e2e:flow && bun run test:e2e:workflow && bun run test:e2e:queue-operations",
|
|
70
70
|
"test:package": "bun run scripts/validate-package-runtime.ts",
|
|
71
71
|
"test:coverage": "bun test --coverage --coverage-reporter=text --coverage-reporter=lcov --coverage-dir=coverage && bun scripts/check-coverage.ts",
|
|
72
|
-
"
|
|
73
|
-
"
|
|
74
|
-
"format": "
|
|
72
|
+
"lint": "oxlint . && bun run scripts/check-implicit-any-let.ts",
|
|
73
|
+
"lint:fix": "oxlint --fix . && bun run scripts/check-implicit-any-let.ts",
|
|
74
|
+
"format": "oxfmt .",
|
|
75
|
+
"format:check": "oxfmt --check .",
|
|
76
|
+
"check": "bun run lint && bun run format:check",
|
|
77
|
+
"check:fix": "bun run lint:fix && bun run format",
|
|
75
78
|
"audit:high": "bun audit --audit-level=high --ignore=GHSA-qwww-vcr4-c8h2",
|
|
76
79
|
"quality": "bun run architecture && bun run check && bun run build && bun run size && bun run docs:build && bun run test:coverage && bun run test:e2e && bun run test:package && bun run audit:high"
|
|
77
80
|
},
|
|
@@ -80,7 +83,6 @@
|
|
|
80
83
|
"@ai-sdk/google": "^4.0.8",
|
|
81
84
|
"@ai-sdk/openai": "^4.0.7",
|
|
82
85
|
"@ai-sdk/openai-compatible": "^3.0.5",
|
|
83
|
-
"@biomejs/biome": "^2.5.2",
|
|
84
86
|
"@fontsource-variable/inter": "^5.2.8",
|
|
85
87
|
"@fontsource-variable/jetbrains-mono": "^5.2.8",
|
|
86
88
|
"@shikijs/vitepress-twoslash": "^4.3.0",
|
|
@@ -93,6 +95,9 @@
|
|
|
93
95
|
"bun-types": "^1.3.14",
|
|
94
96
|
"happy-dom": "^20.10.6",
|
|
95
97
|
"mermaid": "^11.16.0",
|
|
98
|
+
"oxfmt": "^0.63.0",
|
|
99
|
+
"oxlint": "^1.78.0",
|
|
100
|
+
"oxlint-tsgolint": "^7.0.2001",
|
|
96
101
|
"react": "^19.2.7",
|
|
97
102
|
"react-dom": "^19.2.7",
|
|
98
103
|
"react-router-dom": "^7.18.1",
|
package/scripts/embedded.gen.ts
CHANGED
|
@@ -3,80 +3,80 @@
|
|
|
3
3
|
import f0 from "../dist/index.html" with { type: 'file' };
|
|
4
4
|
import f1 from "../dist/favicon.svg" with { type: 'file' };
|
|
5
5
|
import f2 from "../dist/og.png" with { type: 'file' };
|
|
6
|
-
import f3 from "../dist/assets/
|
|
7
|
-
import f4 from "../dist/assets/
|
|
8
|
-
import f5 from "../dist/assets/
|
|
9
|
-
import f6 from "../dist/assets/
|
|
10
|
-
import f7 from "../dist/assets/
|
|
11
|
-
import f8 from "../dist/assets/
|
|
12
|
-
import f9 from "../dist/assets/
|
|
13
|
-
import f10 from "../dist/assets/
|
|
14
|
-
import f11 from "../dist/assets/
|
|
15
|
-
import f12 from "../dist/assets/
|
|
16
|
-
import f13 from "../dist/assets/
|
|
17
|
-
import f14 from "../dist/assets/
|
|
18
|
-
import f15 from "../dist/assets/
|
|
19
|
-
import f16 from "../dist/assets/
|
|
20
|
-
import f17 from "../dist/assets/
|
|
21
|
-
import f18 from "../dist/assets/
|
|
22
|
-
import f19 from "../dist/assets/
|
|
23
|
-
import f20 from "../dist/assets/
|
|
24
|
-
import f21 from "../dist/assets/
|
|
25
|
-
import f22 from "../dist/assets/
|
|
26
|
-
import f23 from "../dist/assets/
|
|
27
|
-
import f24 from "../dist/assets/
|
|
28
|
-
import f25 from "../dist/assets/
|
|
29
|
-
import f26 from "../dist/assets/
|
|
30
|
-
import f27 from "../dist/assets/
|
|
31
|
-
import f28 from "../dist/assets/
|
|
32
|
-
import f29 from "../dist/assets/
|
|
33
|
-
import f30 from "../dist/assets/
|
|
34
|
-
import f31 from "../dist/assets/
|
|
35
|
-
import f32 from "../dist/assets/
|
|
36
|
-
import f33 from "../dist/assets/
|
|
37
|
-
import f34 from "../dist/assets/
|
|
38
|
-
import f35 from "../dist/assets/
|
|
39
|
-
import f36 from "../dist/assets/
|
|
40
|
-
import f37 from "../dist/assets/
|
|
41
|
-
import f38 from "../dist/assets/
|
|
42
|
-
import f39 from "../dist/assets/
|
|
43
|
-
import f40 from "../dist/assets/
|
|
44
|
-
import f41 from "../dist/assets/
|
|
45
|
-
import f42 from "../dist/assets/
|
|
46
|
-
import f43 from "../dist/assets/
|
|
47
|
-
import f44 from "../dist/assets/
|
|
48
|
-
import f45 from "../dist/assets/
|
|
49
|
-
import f46 from "../dist/assets/
|
|
50
|
-
import f47 from "../dist/assets/
|
|
51
|
-
import f48 from "../dist/assets/
|
|
52
|
-
import f49 from "../dist/assets/
|
|
53
|
-
import f50 from "../dist/assets/
|
|
54
|
-
import f51 from "../dist/assets/
|
|
55
|
-
import f52 from "../dist/assets/
|
|
56
|
-
import f53 from "../dist/assets/
|
|
57
|
-
import f54 from "../dist/assets/
|
|
58
|
-
import f55 from "../dist/assets/
|
|
6
|
+
import f3 from "../dist/assets/Benchmark-ClJmYZoC.js" with { type: 'file' };
|
|
7
|
+
import f4 from "../dist/assets/bq-Bmysbg0r.js" with { type: 'file' };
|
|
8
|
+
import f5 from "../dist/assets/JobInspector-DfqBq4O5.js" with { type: 'file' };
|
|
9
|
+
import f6 from "../dist/assets/QueueActions-B6M0ByGt.js" with { type: 'file' };
|
|
10
|
+
import f7 from "../dist/assets/UsagePro-DMxrXxur.js" with { type: 'file' };
|
|
11
|
+
import f8 from "../dist/assets/index-Cue53Myw.js" with { type: 'file' };
|
|
12
|
+
import f9 from "../dist/assets/inter-latin-wght-normal-Dx4kXJAl.woff2" with { type: 'file' };
|
|
13
|
+
import f10 from "../dist/assets/CronManager-lNZ4lHh1.js" with { type: 'file' };
|
|
14
|
+
import f11 from "../dist/assets/BulkAddJobs-BBWqQpP7.js" with { type: 'file' };
|
|
15
|
+
import f12 from "../dist/assets/DlqControl-DJGhuyu3.js" with { type: 'file' };
|
|
16
|
+
import f13 from "../dist/assets/LogsPro-BCB7etG2.js" with { type: 'file' };
|
|
17
|
+
import f14 from "../dist/assets/exportFile-C7xhE8Yh.js" with { type: 'file' };
|
|
18
|
+
import f15 from "../dist/assets/Usage-QyZkUhgs.js" with { type: 'file' };
|
|
19
|
+
import f16 from "../dist/assets/connectionStore-CKFQrxDo.js" with { type: 'file' };
|
|
20
|
+
import f17 from "../dist/assets/AreaChart-w0ruozXH.js" with { type: 'file' };
|
|
21
|
+
import f18 from "../dist/assets/dist-DjvZiKhB.js" with { type: 'file' };
|
|
22
|
+
import f19 from "../dist/assets/flowMutationSafety-DObp9nJo.js" with { type: 'file' };
|
|
23
|
+
import f20 from "../dist/assets/api-V_sVpHDo.js" with { type: 'file' };
|
|
24
|
+
import f21 from "../dist/assets/Logs-B3dsGSF8.js" with { type: 'file' };
|
|
25
|
+
import f22 from "../dist/assets/install-CFiYX86d.js" with { type: 'file' };
|
|
26
|
+
import f23 from "../dist/assets/controlConnectionEpoch-JM4omZ6j.js" with { type: 'file' };
|
|
27
|
+
import f24 from "../dist/assets/responses-CBLyy1Ob.js" with { type: 'file' };
|
|
28
|
+
import f25 from "../dist/assets/Overview-Ba5odzYe.js" with { type: 'file' };
|
|
29
|
+
import f26 from "../dist/assets/Cron-pJJ5KXFG.js" with { type: 'file' };
|
|
30
|
+
import f27 from "../dist/assets/DlqPro-BhXIKtrt.js" with { type: 'file' };
|
|
31
|
+
import f28 from "../dist/assets/S3BackupPro-BkwTXdtw.js" with { type: 'file' };
|
|
32
|
+
import f29 from "../dist/assets/useServerActionGuard-OTv6_fU0.js" with { type: 'file' };
|
|
33
|
+
import f30 from "../dist/assets/Flows-Bb9j-YhZ.js" with { type: 'file' };
|
|
34
|
+
import f31 from "../dist/assets/JobsPro-D8dH9um7.js" with { type: 'file' };
|
|
35
|
+
import f32 from "../dist/assets/Card-C7NMhqUt.js" with { type: 'file' };
|
|
36
|
+
import f33 from "../dist/assets/Diagnostics-DLvCT7zI.js" with { type: 'file' };
|
|
37
|
+
import f34 from "../dist/assets/jetbrains-mono-latin-ext-wght-normal-DBQx-q_a.woff2" with { type: 'file' };
|
|
38
|
+
import f35 from "../dist/assets/form-tC20r4Ma.js" with { type: 'file' };
|
|
39
|
+
import f36 from "../dist/assets/ServerControl-DJHKMaf9.js" with { type: 'file' };
|
|
40
|
+
import f37 from "../dist/assets/Dlq-Bx4YXTp5.js" with { type: 'file' };
|
|
41
|
+
import f38 from "../dist/assets/McpServer-Cz1-GwD5.js" with { type: 'file' };
|
|
42
|
+
import f39 from "../dist/assets/dist-DpZcbP9W.js" with { type: 'file' };
|
|
43
|
+
import f40 from "../dist/assets/icons-CIvFfU2b.js" with { type: 'file' };
|
|
44
|
+
import f41 from "../dist/assets/Database-DxiXsUl4.js" with { type: 'file' };
|
|
45
|
+
import f42 from "../dist/assets/upstreamPaths-CDVsu6IM.js" with { type: 'file' };
|
|
46
|
+
import f43 from "../dist/assets/PageHeader-BXlZSBcc.js" with { type: 'file' };
|
|
47
|
+
import f44 from "../dist/assets/cn-zFEt5SO8.js" with { type: 'file' };
|
|
48
|
+
import f45 from "../dist/assets/Workflows-DqTKWPmT.js" with { type: 'file' };
|
|
49
|
+
import f46 from "../dist/assets/Metrics-Bkuy6Ntb.js" with { type: 'file' };
|
|
50
|
+
import f47 from "../dist/assets/Pagination-Q-vf4hsX.js" with { type: 'file' };
|
|
51
|
+
import f48 from "../dist/assets/useThroughputSeries-CrsZYKbT.js" with { type: 'file' };
|
|
52
|
+
import f49 from "../dist/assets/QueuesOverview-ChC5Dtqh.js" with { type: 'file' };
|
|
53
|
+
import f50 from "../dist/assets/MetricsPro-BbJmy0oO.js" with { type: 'file' };
|
|
54
|
+
import f51 from "../dist/assets/jetbrains-mono-latin-wght-normal-B9CIFXIH.woff2" with { type: 'file' };
|
|
55
|
+
import f52 from "../dist/assets/format-Cg7VCIZW.js" with { type: 'file' };
|
|
56
|
+
import f53 from "../dist/assets/Workers-Cn8Bkgy1.js" with { type: 'file' };
|
|
57
|
+
import f54 from "../dist/assets/S3Backup-5OKa8G13.js" with { type: 'file' };
|
|
58
|
+
import f55 from "../dist/assets/react-vendor-CyjgmGTq.js" with { type: 'file' };
|
|
59
59
|
import f56 from "../dist/assets/dist-1f1fMHVO.js" with { type: 'file' };
|
|
60
60
|
import f57 from "../dist/assets/feedback-BnGE2oW2.js" with { type: 'file' };
|
|
61
|
-
import f58 from "../dist/assets/
|
|
62
|
-
import f59 from "../dist/assets/
|
|
63
|
-
import f60 from "../dist/assets/
|
|
64
|
-
import f61 from "../dist/assets/
|
|
65
|
-
import f62 from "../dist/assets/
|
|
66
|
-
import f63 from "../dist/assets/
|
|
67
|
-
import f64 from "../dist/assets/
|
|
68
|
-
import f65 from "../dist/assets/
|
|
69
|
-
import f66 from "../dist/assets/
|
|
70
|
-
import f67 from "../dist/assets/
|
|
61
|
+
import f58 from "../dist/assets/Webhooks-D0JQQf0q.js" with { type: 'file' };
|
|
62
|
+
import f59 from "../dist/assets/index-DOze4TKg.css" with { type: 'file' };
|
|
63
|
+
import f60 from "../dist/assets/toastStore-B7n0zS0y.js" with { type: 'file' };
|
|
64
|
+
import f61 from "../dist/assets/promisePool-BVfQ9n9Q.js" with { type: 'file' };
|
|
65
|
+
import f62 from "../dist/assets/WorkersPro-BOTuX9EP.js" with { type: 'file' };
|
|
66
|
+
import f63 from "../dist/assets/CopilotPanel-Bhh-uCpN.js" with { type: 'file' };
|
|
67
|
+
import f64 from "../dist/assets/QueueDetailPro-CIimG0pX.js" with { type: 'file' };
|
|
68
|
+
import f65 from "../dist/assets/Settings-C1HtCK6h.js" with { type: 'file' };
|
|
69
|
+
import f66 from "../dist/assets/AddJob-CC4bfHLH.js" with { type: 'file' };
|
|
70
|
+
import f67 from "../dist/assets/Alerts-C2bAi-Kj.js" with { type: 'file' };
|
|
71
71
|
import f68 from "../dist/assets/Button-BPqpRZJD.js" with { type: 'file' };
|
|
72
|
-
import f69 from "../dist/assets/
|
|
73
|
-
import f70 from "../dist/assets/
|
|
74
|
-
import f71 from "../dist/assets/
|
|
75
|
-
import f72 from "../dist/assets/
|
|
76
|
-
import f73 from "../dist/assets/
|
|
77
|
-
import f74 from "../dist/assets/
|
|
78
|
-
import f75 from "../dist/assets/
|
|
79
|
-
import f76 from "../dist/assets/
|
|
72
|
+
import f69 from "../dist/assets/dist-BlWBaCN6.js" with { type: 'file' };
|
|
73
|
+
import f70 from "../dist/assets/StatusBadge-B0I7hNBX.js" with { type: 'file' };
|
|
74
|
+
import f71 from "../dist/assets/Queues-CGPgEkVm.js" with { type: 'file' };
|
|
75
|
+
import f72 from "../dist/assets/Jobs-Blavwd1H.js" with { type: 'file' };
|
|
76
|
+
import f73 from "../dist/assets/QueueDetail-BClRbWC5.js" with { type: 'file' };
|
|
77
|
+
import f74 from "../dist/assets/inter-latin-ext-wght-normal-DO1Apj_S.woff2" with { type: 'file' };
|
|
78
|
+
import f75 from "../dist/assets/QueueControl-CWHsVfWU.js" with { type: 'file' };
|
|
79
|
+
import f76 from "../dist/assets/usePolledData-g80Z_UB-.js" with { type: 'file' };
|
|
80
80
|
import f77 from "../dist/assets/jobActions-LQD4KfCc.js" with { type: 'file' };
|
|
81
81
|
import f78 from "../dist/assets/dist-DZL8soAh.js" with { type: 'file' };
|
|
82
82
|
import f79 from "../dist/.vite/manifest.json" with { type: 'file' };
|
|
@@ -85,80 +85,80 @@ export const ASSETS: Record<string, string> = {
|
|
|
85
85
|
"/index.html": f0,
|
|
86
86
|
"/favicon.svg": f1,
|
|
87
87
|
"/og.png": f2,
|
|
88
|
-
"/assets/
|
|
89
|
-
"/assets/
|
|
90
|
-
"/assets/
|
|
91
|
-
"/assets/
|
|
92
|
-
"/assets/
|
|
93
|
-
"/assets/
|
|
94
|
-
"/assets/
|
|
95
|
-
"/assets/
|
|
96
|
-
"/assets/
|
|
97
|
-
"/assets/
|
|
98
|
-
"/assets/
|
|
99
|
-
"/assets/
|
|
100
|
-
"/assets/
|
|
101
|
-
"/assets/
|
|
102
|
-
"/assets/
|
|
103
|
-
"/assets/
|
|
104
|
-
"/assets/
|
|
105
|
-
"/assets/
|
|
106
|
-
"/assets/
|
|
107
|
-
"/assets/
|
|
108
|
-
"/assets/
|
|
109
|
-
"/assets/
|
|
110
|
-
"/assets/
|
|
111
|
-
"/assets/
|
|
112
|
-
"/assets/
|
|
113
|
-
"/assets/
|
|
114
|
-
"/assets/
|
|
115
|
-
"/assets/
|
|
116
|
-
"/assets/
|
|
117
|
-
"/assets/
|
|
118
|
-
"/assets/
|
|
119
|
-
"/assets/
|
|
120
|
-
"/assets/
|
|
121
|
-
"/assets/
|
|
122
|
-
"/assets/
|
|
123
|
-
"/assets/
|
|
124
|
-
"/assets/
|
|
125
|
-
"/assets/
|
|
126
|
-
"/assets/
|
|
127
|
-
"/assets/
|
|
128
|
-
"/assets/
|
|
129
|
-
"/assets/
|
|
130
|
-
"/assets/
|
|
131
|
-
"/assets/
|
|
132
|
-
"/assets/
|
|
133
|
-
"/assets/
|
|
134
|
-
"/assets/
|
|
135
|
-
"/assets/
|
|
136
|
-
"/assets/
|
|
137
|
-
"/assets/
|
|
138
|
-
"/assets/
|
|
139
|
-
"/assets/
|
|
140
|
-
"/assets/
|
|
88
|
+
"/assets/Benchmark-ClJmYZoC.js": f3,
|
|
89
|
+
"/assets/bq-Bmysbg0r.js": f4,
|
|
90
|
+
"/assets/JobInspector-DfqBq4O5.js": f5,
|
|
91
|
+
"/assets/QueueActions-B6M0ByGt.js": f6,
|
|
92
|
+
"/assets/UsagePro-DMxrXxur.js": f7,
|
|
93
|
+
"/assets/index-Cue53Myw.js": f8,
|
|
94
|
+
"/assets/inter-latin-wght-normal-Dx4kXJAl.woff2": f9,
|
|
95
|
+
"/assets/CronManager-lNZ4lHh1.js": f10,
|
|
96
|
+
"/assets/BulkAddJobs-BBWqQpP7.js": f11,
|
|
97
|
+
"/assets/DlqControl-DJGhuyu3.js": f12,
|
|
98
|
+
"/assets/LogsPro-BCB7etG2.js": f13,
|
|
99
|
+
"/assets/exportFile-C7xhE8Yh.js": f14,
|
|
100
|
+
"/assets/Usage-QyZkUhgs.js": f15,
|
|
101
|
+
"/assets/connectionStore-CKFQrxDo.js": f16,
|
|
102
|
+
"/assets/AreaChart-w0ruozXH.js": f17,
|
|
103
|
+
"/assets/dist-DjvZiKhB.js": f18,
|
|
104
|
+
"/assets/flowMutationSafety-DObp9nJo.js": f19,
|
|
105
|
+
"/assets/api-V_sVpHDo.js": f20,
|
|
106
|
+
"/assets/Logs-B3dsGSF8.js": f21,
|
|
107
|
+
"/assets/install-CFiYX86d.js": f22,
|
|
108
|
+
"/assets/controlConnectionEpoch-JM4omZ6j.js": f23,
|
|
109
|
+
"/assets/responses-CBLyy1Ob.js": f24,
|
|
110
|
+
"/assets/Overview-Ba5odzYe.js": f25,
|
|
111
|
+
"/assets/Cron-pJJ5KXFG.js": f26,
|
|
112
|
+
"/assets/DlqPro-BhXIKtrt.js": f27,
|
|
113
|
+
"/assets/S3BackupPro-BkwTXdtw.js": f28,
|
|
114
|
+
"/assets/useServerActionGuard-OTv6_fU0.js": f29,
|
|
115
|
+
"/assets/Flows-Bb9j-YhZ.js": f30,
|
|
116
|
+
"/assets/JobsPro-D8dH9um7.js": f31,
|
|
117
|
+
"/assets/Card-C7NMhqUt.js": f32,
|
|
118
|
+
"/assets/Diagnostics-DLvCT7zI.js": f33,
|
|
119
|
+
"/assets/jetbrains-mono-latin-ext-wght-normal-DBQx-q_a.woff2": f34,
|
|
120
|
+
"/assets/form-tC20r4Ma.js": f35,
|
|
121
|
+
"/assets/ServerControl-DJHKMaf9.js": f36,
|
|
122
|
+
"/assets/Dlq-Bx4YXTp5.js": f37,
|
|
123
|
+
"/assets/McpServer-Cz1-GwD5.js": f38,
|
|
124
|
+
"/assets/dist-DpZcbP9W.js": f39,
|
|
125
|
+
"/assets/icons-CIvFfU2b.js": f40,
|
|
126
|
+
"/assets/Database-DxiXsUl4.js": f41,
|
|
127
|
+
"/assets/upstreamPaths-CDVsu6IM.js": f42,
|
|
128
|
+
"/assets/PageHeader-BXlZSBcc.js": f43,
|
|
129
|
+
"/assets/cn-zFEt5SO8.js": f44,
|
|
130
|
+
"/assets/Workflows-DqTKWPmT.js": f45,
|
|
131
|
+
"/assets/Metrics-Bkuy6Ntb.js": f46,
|
|
132
|
+
"/assets/Pagination-Q-vf4hsX.js": f47,
|
|
133
|
+
"/assets/useThroughputSeries-CrsZYKbT.js": f48,
|
|
134
|
+
"/assets/QueuesOverview-ChC5Dtqh.js": f49,
|
|
135
|
+
"/assets/MetricsPro-BbJmy0oO.js": f50,
|
|
136
|
+
"/assets/jetbrains-mono-latin-wght-normal-B9CIFXIH.woff2": f51,
|
|
137
|
+
"/assets/format-Cg7VCIZW.js": f52,
|
|
138
|
+
"/assets/Workers-Cn8Bkgy1.js": f53,
|
|
139
|
+
"/assets/S3Backup-5OKa8G13.js": f54,
|
|
140
|
+
"/assets/react-vendor-CyjgmGTq.js": f55,
|
|
141
141
|
"/assets/dist-1f1fMHVO.js": f56,
|
|
142
142
|
"/assets/feedback-BnGE2oW2.js": f57,
|
|
143
|
-
"/assets/
|
|
144
|
-
"/assets/
|
|
145
|
-
"/assets/
|
|
146
|
-
"/assets/
|
|
147
|
-
"/assets/
|
|
148
|
-
"/assets/
|
|
149
|
-
"/assets/
|
|
150
|
-
"/assets/
|
|
151
|
-
"/assets/
|
|
152
|
-
"/assets/
|
|
143
|
+
"/assets/Webhooks-D0JQQf0q.js": f58,
|
|
144
|
+
"/assets/index-DOze4TKg.css": f59,
|
|
145
|
+
"/assets/toastStore-B7n0zS0y.js": f60,
|
|
146
|
+
"/assets/promisePool-BVfQ9n9Q.js": f61,
|
|
147
|
+
"/assets/WorkersPro-BOTuX9EP.js": f62,
|
|
148
|
+
"/assets/CopilotPanel-Bhh-uCpN.js": f63,
|
|
149
|
+
"/assets/QueueDetailPro-CIimG0pX.js": f64,
|
|
150
|
+
"/assets/Settings-C1HtCK6h.js": f65,
|
|
151
|
+
"/assets/AddJob-CC4bfHLH.js": f66,
|
|
152
|
+
"/assets/Alerts-C2bAi-Kj.js": f67,
|
|
153
153
|
"/assets/Button-BPqpRZJD.js": f68,
|
|
154
|
-
"/assets/
|
|
155
|
-
"/assets/
|
|
156
|
-
"/assets/
|
|
157
|
-
"/assets/
|
|
158
|
-
"/assets/
|
|
159
|
-
"/assets/
|
|
160
|
-
"/assets/
|
|
161
|
-
"/assets/
|
|
154
|
+
"/assets/dist-BlWBaCN6.js": f69,
|
|
155
|
+
"/assets/StatusBadge-B0I7hNBX.js": f70,
|
|
156
|
+
"/assets/Queues-CGPgEkVm.js": f71,
|
|
157
|
+
"/assets/Jobs-Blavwd1H.js": f72,
|
|
158
|
+
"/assets/QueueDetail-BClRbWC5.js": f73,
|
|
159
|
+
"/assets/inter-latin-ext-wght-normal-DO1Apj_S.woff2": f74,
|
|
160
|
+
"/assets/QueueControl-CWHsVfWU.js": f75,
|
|
161
|
+
"/assets/usePolledData-g80Z_UB-.js": f76,
|
|
162
162
|
"/assets/jobActions-LQD4KfCc.js": f77,
|
|
163
163
|
"/assets/dist-DZL8soAh.js": f78,
|
|
164
164
|
"/.vite/manifest.json": f79,
|
|
@@ -1,3 +0,0 @@
|
|
|
1
|
-
import{i as e}from"./cn-zFEt5SO8.js";import{g as t,t as n}from"./react-vendor-CyjgmGTq.js";import{d as r,f as i,i as a,o,u as s}from"./connectionStore-CKFQrxDo.js";import{o as c,t as l}from"./bq-DYmbVkgR.js";import{w as u}from"./icons-CIvFfU2b.js";import{n as d}from"./usePolledData-c53tx1jw.js";import{t as f}from"./Button-BPqpRZJD.js";import{t as p}from"./Card-C7NMhqUt.js";import{t as m}from"./PageHeader-BXlZSBcc.js";import{a as h}from"./index-D64v2vNO.js";import{a as g,n as _,r as v,t as y}from"./form-tC20r4Ma.js";var b=e(t(),1),ee=`bq-dash-s3`,x=2,S=[`disabled`,`6h`,`12h`,`24h`],C={endpoint:``,region:`us-east-1`,bucket:``,schedule:`disabled`,pathPrefix:``,virtualHostedStyle:`auto`,retention:7};function w(e){return typeof e==`object`&&!!e&&!Array.isArray(e)}function T(e,t,n){return typeof e==`string`&&e.length<=n?e:t}function E(e){return S.includes(e)?e:`disabled`}function D(e){return e===`virtual-hosted`||e===`path-style`?e:`auto`}function O(e){return typeof e==`number`&&Number.isSafeInteger(e)&&e>=1&&e<=1e6?e:C.retention}function k(e){let t=w(e)?e:{};return{endpoint:T(t.endpoint,C.endpoint,2048),region:T(t.region,C.region,128),bucket:T(t.bucket,C.bucket,255),schedule:E(t.schedule),pathPrefix:T(t.pathPrefix,C.pathPrefix,1024),virtualHostedStyle:D(t.virtualHostedStyle),retention:O(t.retention)}}function A(e){return k(e)}function j(){try{return globalThis.localStorage??null}catch{return null}}function M(e){try{let t=JSON.parse(e),n=w(t)?t:{},r=k(`state`in n?n.state:n),i=typeof n.version==`number`?n.version:void 0;return{hydration:JSON.stringify({state:r,...i===void 0?{}:{version:i}}),canonical:JSON.stringify({state:r,version:x})}}catch{return null}}var te={getItem(e){let t=j();if(!t)return null;let n;try{n=t.getItem(e)}catch{return null}if(n===null||e!==`bq-dash-s3`)return n;let r=M(n);if(!r){try{t.removeItem(e)}catch{}return null}if(n!==r.canonical)try{t.setItem(e,r.canonical)}catch{try{t.removeItem(e)}catch{}}return r.hydration},setItem(e,t){try{j()?.setItem(e,t)}catch{}},removeItem(e){try{j()?.removeItem(e)}catch{}}},ne=i()(r(e=>({...C,accessKeyId:``,secretAccessKey:``,sessionToken:``,set:t=>e(e=>{let n={...e,...t};return{...k(n),accessKeyId:T(n.accessKeyId,``,512),secretAccessKey:T(n.secretAccessKey,``,2048),sessionToken:T(n.sessionToken,``,4096)}})}),{name:ee,version:x,storage:s(()=>te),partialize:A,migrate:k,merge:(e,t)=>({...t,...k(e),accessKeyId:``,secretAccessKey:``,sessionToken:``})})),N=new Set([`enabled`,`bucket`,`endpoint`,`interval`,`retention`]),P=new Set([`key`,`size`,`date`]);function F(e){let t=L(e,N,`Backup status`);return typeof t.enabled!=`boolean`&&B(`Backup status`),{enabled:t.enabled,bucket:R(t.bucket,`Backup status bucket`,1024),endpoint:R(t.endpoint,`Backup status endpoint`,4096),interval:R(t.interval,`Backup status interval`,128),retention:R(t.retention,`Backup status retention`,128)}}function I(e){(!Array.isArray(e)||e.length>2e4)&&B(`Backup list`);let t=new Set,n=0;return e.map((e,r)=>{let i=L(e,P,`Backup list item ${r}`),a=R(i.key,`Backup list item ${r} key`,2048),o=R(i.size,`Backup list item ${r} size`,128),s=R(i.date,`Backup list item ${r} date`,128);return n+=a.length+o.length+s.length,(n>2*1024*1024||t.has(a)||!z(s))&&B(`Backup list item ${r}`),t.add(a),{key:a,size:o,date:s}})}function L(e,t,n){(!e||typeof e!=`object`||Array.isArray(e))&&B(n);let r=e;return Object.keys(r).some(e=>!t.has(e))&&B(n),r}function R(e,t,n){return(typeof e!=`string`||e.length<1||e.length>n)&&B(t),e}function z(e){let t=Date.parse(e);return/^\d{4}-\d{2}-\d{2}T\d{2}:\d{2}:\d{2}\.\d{3}Z$/.test(e)&&Number.isFinite(t)&&new Date(t).toISOString()===e}function B(e){throw Error(`${e} returned an invalid Bunqueue 2.8.59 contract`)}function V(e){let t={};for(let n of e.split(`
|
|
2
|
-
`)){let e=n.indexOf(`=`);if(e<1)throw Error(`Generated backup environment is malformed`);let r=n.slice(0,e),i=n.slice(e+1);if(!/^S3_[A-Z0-9_]+$/.test(r))throw Error(`Unexpected backup key: ${r}`);let a;try{a=JSON.parse(i)}catch{if(i===`true`||i===`false`||/^\d+$/.test(i))a=i;else throw Error(`Generated backup value for ${r} is malformed`)}t[r]=String(a)}return t}var H=e=>`${e}?target=${encodeURIComponent(a())}`,U=e=>({method:`POST`,headers:e===void 0?void 0:{"Content-Type":`application/json`},body:e===void 0?void 0:JSON.stringify(e)}),W=async(e,t)=>(await c(H(e),t)).result,G={status:()=>W(`/backup/status`),list:()=>W(`/backup/list`),backupNow:()=>W(`/backup/now`,U()),restore:(e,t)=>W(`/backup/restore`,U({key:e,database:t})),configure:e=>W(`/backup/configure`,U({environment:e})),restoreContext:async()=>{let e=await c(`/control/status`);return{serverStatus:e.status,database:e.db??null}}},K=n();function q({environmentText:e,repository:t=G}){let n=d(()=>X(t),[t],{intervalMs:15e3}),[r,i]=(0,b.useState)(``),[a,o]=(0,b.useState)(``),[s,c]=(0,b.useState)(``),l=(0,b.useRef)(!1),u=async(e,t)=>{if(!l.current){l.current=!0,i(e),o(``),c(``);try{let r=(await t())?.message;c(r??`${e} completed.`),await n.refetch()}catch(e){o(e instanceof Error?e.message:String(e))}finally{l.current=!1,i(``)}}},f=()=>{e&&window.confirm(`Apply this S3 configuration to the managed server? A restart is required.`)&&u(`Configuration`,()=>t.configure(V(e)))},p=()=>{window.confirm(`Create a transactionally consistent S3 backup now?`)&&u(`Backup`,()=>t.backupNow())},m=e=>{let r=n.data?.context?.database;!r||n.data?.context?.serverStatus!==`stopped`||window.prompt(`Type RESTORE to replace ${r.path} with ${e}`)===`RESTORE`&&u(`Restore`,()=>t.restore(e,r))},h=n.data;return(0,K.jsxs)(`section`,{className:`mt-6 overflow-hidden rounded-lg border border-line bg-surface`,children:[(0,K.jsxs)(`header`,{className:`flex flex-wrap items-start justify-between gap-3 border-b border-line px-4 py-3`,children:[(0,K.jsxs)(`div`,{children:[(0,K.jsx)(`h2`,{className:`text-sm font-semibold text-fg`,children:`Live backup operations`}),(0,K.jsx)(`p`,{className:`mt-1 text-xs text-faint`,children:`Official Bunqueue 2.8.59 backup CLI, executed by the local control agent.`})]}),(0,K.jsxs)(`div`,{className:`flex flex-wrap gap-2`,children:[(0,K.jsx)(`button`,{type:`button`,disabled:!e||!!r,onClick:f,className:`rounded-md border border-line px-3 py-2 text-xs text-muted disabled:opacity-40`,children:`Apply configuration`}),(0,K.jsx)(`button`,{type:`button`,disabled:!!r,onClick:p,className:`rounded-md bg-accent px-3 py-2 text-xs font-medium text-accent-fg disabled:opacity-40`,children:r===`Backup`?`Backing up…`:`Backup now`}),(0,K.jsx)(`button`,{type:`button`,disabled:n.loading,onClick:()=>void n.refetch(),className:`rounded-md border border-line px-3 py-2 text-xs text-muted disabled:opacity-40`,children:`Refresh`})]})]}),h?.status&&(0,K.jsx)(J,{status:h.status,context:h.context}),a||h?.errors.length?(0,K.jsx)(`div`,{role:`alert`,className:`border-b border-line px-4 py-3 text-xs text-danger`,children:a||h?.errors.join(` · `)}):null,s&&(0,K.jsx)(`div`,{role:`status`,className:`border-b border-line px-4 py-3 text-xs text-success`,children:s}),(0,K.jsx)(Y,{rows:h?.backups??[],canRestore:h?.context?.serverStatus===`stopped`&&!!h.context.database,busy:!!r,onRestore:m})]})}function J({status:e,context:t}){return(0,K.jsx)(`dl`,{className:`grid border-b border-line sm:grid-cols-2 xl:grid-cols-5`,children:[[`Scheduler`,e.enabled?`Enabled after restart`:`Disabled`],[`Bucket`,e.bucket||`—`],[`Endpoint`,e.endpoint],[`Retention`,e.retention],[`Server`,t?.serverStatus??`Unknown`]].map(([e,t])=>(0,K.jsxs)(`div`,{className:`border-b border-line px-4 py-3 last:border-b-0 xl:border-r xl:border-b-0`,children:[(0,K.jsx)(`dt`,{className:`text-[10px] uppercase tracking-wider text-faint`,children:e}),(0,K.jsx)(`dd`,{className:`mt-1 truncate text-xs text-fg`,title:t,children:t})]},e))})}function Y({rows:e,canRestore:t,busy:n,onRestore:r}){return e.length?(0,K.jsx)(`div`,{className:`overflow-x-auto`,children:(0,K.jsxs)(`table`,{className:`w-full min-w-[680px] text-left text-xs`,children:[(0,K.jsx)(`thead`,{className:`border-b border-line text-[10px] uppercase tracking-wider text-faint`,children:(0,K.jsxs)(`tr`,{children:[(0,K.jsx)(`th`,{className:`px-4 py-2 font-medium`,children:`Object key`}),(0,K.jsx)(`th`,{className:`px-4 py-2 font-medium`,children:`Size`}),(0,K.jsx)(`th`,{className:`px-4 py-2 font-medium`,children:`Created`}),(0,K.jsx)(`th`,{className:`px-4 py-2 text-right font-medium`,children:`Restore`})]})}),(0,K.jsx)(`tbody`,{className:`divide-y divide-line`,children:e.map(e=>(0,K.jsxs)(`tr`,{children:[(0,K.jsx)(`td`,{className:`max-w-md truncate px-4 py-3 font-mono text-fg`,title:e.key,children:e.key}),(0,K.jsx)(`td`,{className:`px-4 py-3 text-muted`,children:e.size}),(0,K.jsx)(`td`,{className:`px-4 py-3 text-muted`,children:e.date}),(0,K.jsx)(`td`,{className:`px-4 py-3 text-right`,children:(0,K.jsx)(`button`,{type:`button`,disabled:!t||n,title:t?`Restore this backup`:`Stop the managed server before restore`,onClick:()=>r(e.key),className:`rounded-md border border-danger/40 px-2.5 py-1.5 text-danger disabled:opacity-35`,children:`Restore`})})]},e.key))})]})}):(0,K.jsx)(`p`,{className:`px-4 py-8 text-center text-sm text-muted`,children:`No backup objects returned.`})}async function X(e){let[t,n,r]=await Promise.allSettled([e.status().then(e=>F(e.data)),e.list().then(e=>I(e.data)),e.restoreContext()]),i=[t,n,r].filter(e=>e.status===`rejected`).map(e=>e.reason instanceof Error?e.reason.message:String(e.reason));return{status:t.status===`fulfilled`?t.value:void 0,backups:n.status===`fulfilled`?n.value:[],context:r.status===`fulfilled`?r.value:void 0,errors:i}}function re(e){if(typeof e!=`object`||!e||Array.isArray(e)||typeof e.ok!=`boolean`)throw Error(`Malformed storage status response.`);let t=e.data;if(typeof t!=`object`||!t||Array.isArray(t)||typeof t.diskFull!=`boolean`)throw Error(`Storage status response is missing disk health data.`);return{diskFull:t.diskFull}}var Z=e=>JSON.stringify([e.baseUrl,e.token]),Q={"6h":360*60*1e3,"12h":720*60*1e3,"24h":1440*60*1e3};function $(e,t){return`${e}=${typeof t==`string`?JSON.stringify(t):String(t)}`}function ie(e){let t=[],n=e.endpoint.trim(),r=e.region.trim(),i=e.bucket.trim(),a=e.accessKeyId.trim(),o=e.secretAccessKey.trim(),s=e.sessionToken.trim(),c=e.pathPrefix.trim();if(e.schedule===`disabled`)return{ok:!0,value:$(`S3_BACKUP_ENABLED`,!1)};if((!r||r.length>128)&&t.push(`Region is required (maximum 128 characters).`),(!i||i.length>255)&&t.push(`Bucket is required (maximum 255 characters).`),(!a||a.length>512)&&t.push(`Access key ID is required (maximum 512 characters).`),(!o||o.length>2048)&&t.push(`Secret access key is required (maximum 2048 characters).`),s.length>4096&&t.push(`Session token is too long.`),(!Number.isSafeInteger(e.retention)||e.retention<1||e.retention>1e6)&&t.push(`Retention must be a whole number from 1 to 1000000.`),c.length>1024&&t.push(`Path prefix is too long.`),n)try{let e=new URL(n);(e.protocol!==`http:`&&e.protocol!==`https:`||e.username||e.password||n.length>2048)&&t.push(`Endpoint must be an http(s) URL without embedded credentials.`)}catch{t.push(`Endpoint must be a valid http(s) URL.`)}if(t.length)return{ok:!1,errors:t};let l=[$(`S3_BACKUP_ENABLED`,!0),$(`S3_ACCESS_KEY_ID`,a),$(`S3_SECRET_ACCESS_KEY`,o),$(`S3_BUCKET`,i),$(`S3_REGION`,r),$(`S3_BACKUP_RETENTION`,e.retention)];return s&&l.push($(`S3_SESSION_TOKEN`,s)),e.virtualHostedStyle!==`auto`&&l.push($(`S3_VIRTUAL_HOSTED_STYLE`,e.virtualHostedStyle===`virtual-hosted`)),n&&l.push($(`S3_ENDPOINT`,n)),c&&l.push($(`S3_BACKUP_PREFIX`,c)),l.push($(`S3_BACKUP_INTERVAL`,Q[e.schedule])),{ok:!0,value:l.join(`
|
|
3
|
-
`)}}function ae({environment:e}){return(0,K.jsxs)(p,{children:[(0,K.jsxs)(`div`,{className:`mb-3 flex items-center justify-between gap-3`,children:[(0,K.jsxs)(`div`,{children:[(0,K.jsx)(`h2`,{className:`text-base font-semibold text-fg`,children:`Server environment`}),(0,K.jsx)(`p`,{className:`mt-1 text-xs text-faint`,children:`Credentials stay in memory and are copied or applied only when you request it.`})]}),e.ok&&(0,K.jsx)(h,{value:e.value})]}),e.ok?(0,K.jsx)(`pre`,{className:`overflow-x-auto whitespace-pre-wrap break-all rounded-lg bg-surface-2 p-4 font-mono text-xs text-muted`,children:e.value.replace(/^S3_ACCESS_KEY_ID=.*$/m,`S3_ACCESS_KEY_ID="••••••••"`).replace(/^S3_SECRET_ACCESS_KEY=.*$/m,`S3_SECRET_ACCESS_KEY="••••••••"`).replace(/^S3_SESSION_TOKEN=.*$/m,`S3_SESSION_TOKEN="••••••••"`)}):(0,K.jsx)(`ul`,{className:`space-y-1 text-sm text-danger`,"aria-label":`Configuration errors`,children:e.errors.map(e=>(0,K.jsxs)(`li`,{children:[`• `,e]},e))})]})}function oe(){let e=ne(),t=o(Z),[n,r]=(0,b.useState)(null),[i,a]=(0,b.useState)(null),s=(0,b.useRef)(0),c=ie(e),d=n?.target===t?n:null,h=i===t;return(0,b.useEffect)(()=>(s.current++,r(null),a(null),()=>{s.current++}),[t]),(0,K.jsxs)(`div`,{children:[(0,K.jsx)(m,{title:`S3 Backup Setup`,description:`Configure and operate Bunqueue 2.8.59 S3 backups.`}),(0,K.jsxs)(`div`,{className:`mb-6 flex items-center justify-between rounded-xl border border-line bg-surface px-5 py-4`,children:[(0,K.jsxs)(`div`,{className:`flex items-center gap-3`,children:[(0,K.jsx)(`span`,{className:`flex size-10 items-center justify-center rounded-lg bg-surface-2 text-faint`,children:(0,K.jsx)(u,{className:`size-5`})}),(0,K.jsxs)(`div`,{children:[(0,K.jsx)(`div`,{className:`font-semibold text-fg`,children:c.ok?`Configuration draft complete`:`Configuration draft incomplete`}),(0,K.jsx)(`div`,{className:`text-xs text-faint`,children:c.ok?e.schedule===`disabled`?`Safe disable settings ready to apply`:`Target: ${e.bucket.trim()} · ready to apply`:`Complete the required fields to generate server settings`})]})]}),(0,K.jsx)(`span`,{className:c.ok?`rounded-full bg-emerald-500/10 px-3 py-1 text-xs font-medium text-success`:`rounded-full bg-amber-500/10 px-3 py-1 text-xs font-medium text-warning`,children:c.ok?`Ready`:`Configure`})]}),(0,K.jsx)(`div`,{className:`mb-6 rounded-lg border border-line bg-surface/60 px-4 py-2.5 text-xs text-faint`,children:`Apply the generated settings through the local control agent below, then restart Bunqueue. Status, object listing, manual backups, and guarded restores use the official Bunqueue CLI. Non-secret draft fields are stored locally; credentials remain in memory.`}),(0,K.jsxs)(p,{className:`mb-6`,children:[(0,K.jsx)(`h2`,{className:`mb-1 text-base font-semibold text-fg`,children:`Connection Settings`}),(0,K.jsx)(`p`,{className:`mb-4 text-xs text-faint`,children:`Works with AWS S3, Cloudflare R2, MinIO, DigitalOcean Spaces, and any S3-compatible provider.`}),(0,K.jsxs)(`div`,{className:`grid grid-cols-1 gap-4 md:grid-cols-2`,children:[(0,K.jsx)(y,{label:`Endpoint`,children:(0,K.jsx)(_,{name:`s3-endpoint`,value:e.endpoint,onChange:t=>e.set({endpoint:t.target.value}),placeholder:`https://s3.amazonaws.com`,maxLength:2048,autoComplete:`off`,inputMode:`url`})}),(0,K.jsx)(y,{label:`Region`,children:(0,K.jsx)(_,{name:`s3-region`,value:e.region,onChange:t=>e.set({region:t.target.value}),placeholder:`us-east-1`,maxLength:128,autoComplete:`off`,spellCheck:!1})}),(0,K.jsx)(`div`,{className:`md:col-span-2`,children:(0,K.jsx)(y,{label:`Bucket name`,children:(0,K.jsx)(_,{name:`s3-bucket`,value:e.bucket,onChange:t=>e.set({bucket:t.target.value}),placeholder:`my-bunqueue-backups`,maxLength:255,autoComplete:`off`,spellCheck:!1})})}),(0,K.jsx)(y,{label:`Access key ID`,children:(0,K.jsx)(_,{name:`s3-access-key-id`,value:e.accessKeyId,onChange:t=>e.set({accessKeyId:t.target.value}),placeholder:`AKIA…`,maxLength:512,autoComplete:`off`,spellCheck:!1})}),(0,K.jsx)(y,{label:`Secret access key`,children:(0,K.jsx)(_,{name:`s3-secret-access-key`,type:`password`,value:e.secretAccessKey,onChange:t=>e.set({secretAccessKey:t.target.value}),placeholder:`••••••••••••••••`,maxLength:2048,autoComplete:`off`,spellCheck:!1})}),(0,K.jsx)(`div`,{className:`md:col-span-2`,children:(0,K.jsx)(y,{label:`Session token (optional, for temporary STS credentials)`,children:(0,K.jsx)(_,{name:`s3-session-token`,type:`password`,value:e.sessionToken,onChange:t=>e.set({sessionToken:t.target.value}),placeholder:`Temporary AWS session token`,maxLength:4096,autoComplete:`off`,spellCheck:!1})})}),(0,K.jsx)(`p`,{className:`-mt-2 text-xs text-faint md:col-span-2`,children:`Keys are kept in memory only and cleared on reload.`}),(0,K.jsxs)(`div`,{children:[(0,K.jsx)(v,{htmlFor:`s3-backup-schedule`,children:`Backup interval`}),(0,K.jsxs)(g,{id:`s3-backup-schedule`,name:`s3-backup-schedule`,value:e.schedule,onChange:t=>e.set({schedule:t.target.value}),className:`mt-1.5`,title:`Written to S3_BACKUP_ENABLED and S3_BACKUP_INTERVAL in the generated config`,autoComplete:`off`,children:[(0,K.jsx)(`option`,{value:`disabled`,children:`Disabled`}),(0,K.jsx)(`option`,{value:`6h`,children:`Every 6 hours`}),(0,K.jsx)(`option`,{value:`12h`,children:`Every 12 hours`}),(0,K.jsx)(`option`,{value:`24h`,children:`Every 24 hours`})]})]}),(0,K.jsx)(y,{label:`Path prefix (optional)`,children:(0,K.jsx)(_,{name:`s3-path-prefix`,value:e.pathPrefix,onChange:t=>e.set({pathPrefix:t.target.value}),placeholder:`backups/production/`,maxLength:1024,autoComplete:`off`,spellCheck:!1})}),(0,K.jsxs)(`div`,{children:[(0,K.jsx)(v,{htmlFor:`s3-addressing-style`,children:`Addressing style`}),(0,K.jsxs)(g,{id:`s3-addressing-style`,name:`s3-addressing-style`,value:e.virtualHostedStyle,onChange:t=>e.set({virtualHostedStyle:t.target.value}),className:`mt-1.5`,children:[(0,K.jsx)(`option`,{value:`auto`,children:`Provider default`}),(0,K.jsx)(`option`,{value:`virtual-hosted`,children:`Virtual-hosted style`}),(0,K.jsx)(`option`,{value:`path-style`,children:`Path style`})]})]}),(0,K.jsx)(y,{label:`Backups to retain`,children:(0,K.jsx)(_,{name:`s3-retention`,type:`number`,min:1,max:1e6,step:1,value:e.retention,onChange:t=>e.set({retention:Number(t.target.value)}),inputMode:`numeric`})})]}),(0,K.jsxs)(`div`,{className:`mt-5 flex flex-wrap items-center gap-2`,children:[(0,K.jsx)(f,{onClick:async()=>{let e=t,n=++s.current;r(null),a(e);try{let t=await l.storage();if(n!==s.current||Z(o.getState())!==e)return;let i=re(t);r({target:e,ok:!i.diskFull,msg:i.diskFull?`Server disk is full`:`Server disk healthy — this does not validate the S3 credentials`})}catch(t){if(n!==s.current||Z(o.getState())!==e)return;r({target:e,ok:!1,msg:t.message})}finally{n===s.current&&a(null)}},children:h?`Checking server storage…`:`Check server storage`}),(0,K.jsx)(`span`,{className:`text-xs text-faint`,children:`This checks SQLite disk health only, not S3 connectivity.`}),d&&(0,K.jsx)(`span`,{role:`status`,className:d.ok?`text-xs text-success`:`text-xs text-danger`,children:d.msg})]})]}),(0,K.jsx)(ae,{environment:c}),(0,K.jsx)(q,{environmentText:c.ok?c.value:void 0})]})}export{oe as S3BackupPro};
|