@kedem/okdb 2.6.0 → 2.6.2
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/CHANGELOG.md +18 -0
- package/algorithm-worker-thread.js +1 -1
- package/bin/okdb.js +1 -1
- package/docs/queue.md +6 -0
- package/okdb-functions-sandbox-worker.js +1 -1
- package/okdb-http-worker-child.js +1 -1
- package/okdb-views-bootstrap-worker.js +1 -1
- package/okdb.js +1 -1
- package/package.json +1 -1
- package/public/vendor/okjs/ok.esm.min.js +1 -1
- package/public/vendor/okjs/toolkit/components/ok-chart.ok.js +1 -1
- package/public/vendor/okjs/toolkit/components/ok-doc-viewer.ok.js +1 -1
- package/public/vendor/okjs/toolkit/components/ok-monaco.ok.js +1 -1
- package/public/vendor/okjs/toolkit/core/virtualized.ok.js +1 -1
- package/public/vendor/okjs/toolkit/editor/ok-live-shell.ok.js +1 -1
- package/public/vendor/okjs/toolkit/elements/ok-select.ok.js +1 -1
- package/public/vendor/okjs/toolkit/elements/ok-table.ok.js +1 -1
- package/types/features/queue.d.ts +4 -0
package/bin/okdb.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
'use strict';const _0x3d20e4=_0x8cd7;(function(_0x4f62fc,_0x510b66){const _0x30a075=_0x8cd7,_0x46544f=_0x4f62fc();while(!![]){try{const _0x23446a=-parseInt(_0x30a075(0x646))/0x1+-parseInt(_0x30a075(0x505))/0x2+-parseInt(_0x30a075(0x6d3))/0x3*(-parseInt(_0x30a075(0x615))/0x4)+-parseInt(_0x30a075(0x163))/0x5+parseInt(_0x30a075(0x719))/0x6+-parseInt(_0x30a075(0x672))/0x7+-parseInt(_0x30a075(0x663))/0x8*(-parseInt(_0x30a075(0x290))/0x9);if(_0x23446a===_0x510b66)break;else _0x46544f['push'](_0x46544f['shift']());}catch(_0x21e221){_0x46544f['push'](_0x46544f['shift']());}}}(_0x166e,0x92b37));var require$$1=require('path'),require$$0$1=require('fs'),require$$0=require('os'),require$$4$1=require(_0x3d20e4(0x423)),require$$5$1=require(_0x3d20e4(0x4e1)),require$$0$3=require('readline'),require$$2=require(_0x3d20e4(0x6c5)),require$$5=require(_0x3d20e4(0x667)),require$$2$1=require(_0x3d20e4(0x276)),require$$0$2=require(_0x3d20e4(0x252)),require$$4=require(_0x3d20e4(0x57b)),require$$1$1=require(_0x3d20e4(0x2bd)),require$$0$4=require(_0x3d20e4(0x2db)),require$$0$5=require('perf_hooks'),require$$0$6=require(_0x3d20e4(0x23f)),require$$0$7=require(_0x3d20e4(0x91)),require$$1$2=require(_0x3d20e4(0x3ce)),require$$2$2=require(_0x3d20e4(0x62d)),require$$2$3=require('worker_threads'),require$$3$1=require(_0x3d20e4(0xcf)),commonjsGlobal=typeof globalThis!==_0x3d20e4(0x4be)?globalThis:typeof window!==_0x3d20e4(0x4be)?window:typeof global!==_0x3d20e4(0x4be)?global:typeof self!==_0x3d20e4(0x4be)?self:{};function getDefaultExportFromCjs(_0x5d498c){const _0x448208=_0x3d20e4;return _0x5d498c&&_0x5d498c['__esModule']&&Object['prototype']['hasOwnProperty'][_0x448208(0x3c6)](_0x5d498c,_0x448208(0x3e8))?_0x5d498c['default']:_0x5d498c;}var okdb$1={},okdbWorkers,hasRequiredOkdbWorkers;function requireOkdbWorkers(){if(hasRequiredOkdbWorkers)return okdbWorkers;hasRequiredOkdbWorkers=0x1;const _0x1bd139=require$$0,_0x2c7ceb=require$$0$1,_0x3263ef=require$$1;let _0x478373;function _0x58b634(){const _0x165d7f=_0x8cd7;if(process.env.OKDB_FORCE_SHMBUF_FALLBACK==='1')return![];if(_0x478373!==undefined)return _0x478373;try{const _0x3048c7=_0x3263ef['dirname'](require[_0x165d7f(0x738)](_0x165d7f(0x6b9)));_0x478373=_0x2c7ceb[_0x165d7f(0x1c9)](_0x3263ef[_0x165d7f(0x10b)](_0x3048c7,'build',_0x165d7f(0x314),_0x165d7f(0x26d)));}catch{_0x478373=![];}return _0x478373;}function _0x1e40a1(){const _0x52cac4=_0x8cd7,_0x38902c=_0x1bd139[_0x52cac4(0x19c)]()[_0x52cac4(0x39d)];return Math[_0x52cac4(0x68c)](0x1,_0x38902c-0x1);}function _0x390fdc(_0x180fdc,_0x5de5b7={}){const _0x47cfb9=_0x8cd7,_0x5ee58f=_0x5de5b7[_0x47cfb9(0xfd)]!==undefined?_0x5de5b7['shmbufNative']:_0x58b634();let _0x22bd00;if(_0x180fdc?.[_0x47cfb9(0x38a)])_0x22bd00=0x1;else{let _0x341c28,_0x440512;if(_0x180fdc?.[_0x47cfb9(0x3bd)]!==undefined&&_0x180fdc[_0x47cfb9(0x3bd)]!==null&&_0x180fdc['workersFlag']!=='')_0x341c28=_0x180fdc[_0x47cfb9(0x3bd)],_0x440512=_0x47cfb9(0x548);else{if(process.env.OKDB_HTTP_WORKERS!==undefined&&process.env.OKDB_HTTP_WORKERS!=='')_0x341c28=process.env.OKDB_HTTP_WORKERS,_0x440512=_0x47cfb9(0x3b5);else _0x180fdc?.[_0x47cfb9(0x91)]?.[_0x47cfb9(0x150)]!==undefined&&_0x180fdc['http'][_0x47cfb9(0x150)]!==null&&_0x180fdc[_0x47cfb9(0x91)][_0x47cfb9(0x150)]!==''&&(_0x341c28=_0x180fdc['http'][_0x47cfb9(0x150)],_0x440512=_0x47cfb9(0x68));}if(_0x341c28===undefined)_0x22bd00=_0x1e40a1();else{const _0x587870=Number(_0x341c28);!Number[_0x47cfb9(0x446)](_0x587870)||_0x587870<0x1?(console[_0x47cfb9(0x6a7)](_0x47cfb9(0x94)+_0x440512+'='+JSON[_0x47cfb9(0x5c1)](_0x341c28)+_0x47cfb9(0x49a)),_0x22bd00=0x1):_0x22bd00=_0x587870;}}return!_0x5ee58f&&_0x22bd00>0x1&&(console[_0x47cfb9(0x6a7)]('[okdb]\x20shmbuf\x20native\x20binding\x20unavailable\x20—\x20multi-process\x20clustering\x20is\x20unsafe\x20'+(_0x47cfb9(0x3f5)+_0x22bd00+').')),_0x22bd00=0x1),_0x22bd00;}return okdbWorkers={'isShmbufNative':_0x58b634,'defaultWorkers':_0x1e40a1,'resolveWorkers':_0x390fdc},okdbWorkers;}var version=_0x3d20e4(0x5f3),require$$3={'version':version},okdbMigrate={'exports':{}},okdbError,hasRequiredOkdbError;function requireOkdbError(){if(hasRequiredOkdbError)return okdbError;hasRequiredOkdbError=0x1;class _0x44a72e extends Error{constructor(_0x8b8635,_0x1cefca,_0x2e61d7={}){const _0x335c58=_0x8cd7;super(_0x8b8635),this[_0x335c58(0x707)]=_0x335c58(0x102),this['code']=_0x1cefca,this['details']=_0x2e61d7,_0x2e61d7[_0x335c58(0x300)]&&(this[_0x335c58(0x300)]=_0x2e61d7[_0x335c58(0x300)]),Error['captureStackTrace'](this,this[_0x335c58(0x533)]);}}class _0x3c9c1e extends _0x44a72e{constructor(_0x401aa6,_0x50c659,_0x40272e,_0x93908a){const _0x28da0b=_0x8cd7;super(_0x28da0b(0x370)+_0x401aa6+'@'+_0x50c659+_0x28da0b(0x2be)+_0x40272e+_0x28da0b(0x2a0)+_0x93908a,_0x28da0b(0x405),{'type':_0x401aa6,'key':_0x50c659,'expectedVersion':_0x40272e,'actualVersion':_0x93908a}),this[_0x28da0b(0x707)]=_0x28da0b(0x648);}}class _0x181237 extends _0x44a72e{constructor(_0x1fcc0c,_0xde4172){const _0x4859bb=_0x8cd7;super(_0x1fcc0c+'@'+_0xde4172+'\x20does\x20not\x20exist',_0x4859bb(0x269),{'type':_0x1fcc0c,'key':_0xde4172}),this['name']='OKDBNotFoundError';}}class _0x3de3a6 extends _0x44a72e{constructor(_0x54bd0b,_0x1ed186){const _0x4b1fe2=_0x8cd7;super(_0x54bd0b+'@'+_0x1ed186+'\x20already\x20exists',_0x4b1fe2(0x24a),{'type':_0x54bd0b,'key':_0x1ed186}),this[_0x4b1fe2(0x707)]=_0x4b1fe2(0x53f);}}class _0x3a793a extends _0x44a72e{constructor(_0x3b444d,_0x413d67){const _0x99e9da=_0x8cd7,_0x5af810=typeof _0x413d67;super(_0x99e9da(0x544)+_0x3b444d+_0x99e9da(0x709)+_0x5af810+_0x99e9da(0x745)+_0x413d67,_0x99e9da(0x4fe),{'index':_0x3b444d,'key':_0x413d67,'keyType':_0x5af810}),this['name']=_0x99e9da(0x2de);}}class _0x2189d7 extends _0x44a72e{constructor(_0xd3ea4e){const _0x2715e7=_0x8cd7,_0x3dd669=typeof _0xd3ea4e;super(_0x2715e7(0x710)+_0x3dd669+'.\x20Primary\x20keys\x20must\x20be\x20string\x20or\x20number.\x20Got:\x20'+_0xd3ea4e,'INVALID_PRIMARY_KEY',{'key':_0xd3ea4e,'keyType':_0x3dd669}),this[_0x2715e7(0x707)]=_0x2715e7(0x72d);}}class _0x26c014 extends _0x44a72e{constructor(_0x44c180){const _0x23e57e=_0x8cd7;super(_0x23e57e(0x210)+_0x44c180+_0x23e57e(0x1d8),'TYPE_NOT_REGISTERED',{'type':_0x44c180}),this[_0x23e57e(0x707)]=_0x23e57e(0x28f);}}class _0x8a3f8c extends _0x44a72e{constructor(_0x1f56b8){const _0x1a0b93=_0x8cd7;super(_0x1a0b93(0x210)+_0x1f56b8+_0x1a0b93(0x571),'TYPE_ALREADY_REGISTERED',{'type':_0x1f56b8}),this[_0x1a0b93(0x707)]='OKDBTypeAlreadyRegisteredError';}}class _0x3f8fd2 extends _0x44a72e{constructor(_0xd46925,_0x184a8b){const _0x10e053=_0x8cd7;super(_0x10e053(0x140)+_0x184a8b+_0x10e053(0x162)+_0xd46925+'\x27\x20doesn\x27t\x20exist','INDEX_NOT_REGISTERED',{'type':_0xd46925,'index':_0x184a8b}),this[_0x10e053(0x707)]=_0x10e053(0x27d);}}class _0x14c259 extends _0x44a72e{constructor(_0x5d3065,_0x3f14f6){const _0x2c644e=_0x8cd7;super(_0x2c644e(0x140)+_0x3f14f6+'\x27\x20on\x20type\x20\x27'+_0x5d3065+_0x2c644e(0x41d),_0x2c644e(0x19a),{'type':_0x5d3065,'index':_0x3f14f6}),this[_0x2c644e(0x707)]='OKDBIndexAlreadyRegisteredError';}}class _0x43c5e7 extends _0x44a72e{constructor(_0xe6f192,_0x49606d={}){const _0x6012c8=_0x8cd7;super(_0xe6f192,_0x6012c8(0x6cd),_0x49606d),this[_0x6012c8(0x707)]=_0x6012c8(0x164);}}class _0x129a3c extends _0x44a72e{constructor(_0x22140c,_0x36e66c,_0x1e6416,_0x2f710e,_0x398c4a){const _0x302ace=_0x8cd7;super(_0x302ace(0x222)+_0x22140c+'@'+_0x36e66c+_0x302ace(0x702)+_0x1e6416+_0x302ace(0x4f1)+_0x2f710e+_0x302ace(0x5b8)+_0x398c4a+'\x27',_0x302ace(0x741),{'type':_0x22140c,'index':_0x36e66c,'indexKey':_0x1e6416,'existingKey':_0x2f710e,'conflictingKey':_0x398c4a}),this[_0x302ace(0x707)]=_0x302ace(0x28a);}}class _0xc957ec extends _0x44a72e{constructor(_0x58c2a0,_0x22593c,_0x2aed89){const _0x4d9e98=_0x8cd7;super('Schema\x20validation\x20failed\x20for\x20'+_0x58c2a0+'@'+_0x22593c,_0x4d9e98(0x4e3),{'type':_0x58c2a0,'key':_0x22593c,'errors':_0x2aed89}),this[_0x4d9e98(0x707)]=_0x4d9e98(0x6e),this[_0x4d9e98(0x66f)]=_0x58c2a0,this[_0x4d9e98(0x466)]=_0x22593c,this[_0x4d9e98(0x422)]=_0x2aed89;}}class _0x160b4b extends _0x44a72e{constructor(_0x3c9eb9,_0x234c17){const _0x4e5cbd=_0x8cd7;super(_0x4e5cbd(0x1f1)+_0x3c9eb9+':\x20'+_0x234c17[_0x4e5cbd(0x39d)]+_0x4e5cbd(0x4b4),_0x4e5cbd(0x341),{'type':_0x3c9eb9,'failures':_0x234c17}),this[_0x4e5cbd(0x707)]=_0x4e5cbd(0xc1),this[_0x4e5cbd(0x66f)]=_0x3c9eb9,this[_0x4e5cbd(0x529)]=_0x234c17;}}class _0x3445a6 extends _0x44a72e{constructor(_0x3e2fde,_0x2e3cec,_0x42c821,_0x46e689,_0x528765){const _0x29bdea=_0x8cd7;super(_0x29bdea(0x464)+_0x3e2fde+'@'+_0x2e3cec+'.'+_0x42c821+'\x20references\x20'+_0x46e689+'@'+_0x528765+_0x29bdea(0x5d7),_0x29bdea(0x51c),{'sourceType':_0x3e2fde,'sourceKey':_0x2e3cec,'fieldPath':_0x42c821,'targetType':_0x46e689,'targetKey':_0x528765}),this[_0x29bdea(0x707)]=_0x29bdea(0x54c),this[_0x29bdea(0x20a)]=_0x3e2fde,this[_0x29bdea(0x563)]=_0x2e3cec,this['fieldPath']=_0x42c821,this[_0x29bdea(0x67a)]=_0x46e689,this[_0x29bdea(0x23b)]=_0x528765;}}class _0x593dd2 extends _0x44a72e{constructor(_0x550398,_0x57ff20,_0x32385b){const _0x29b8eb=_0x8cd7;super(_0x29b8eb(0x664)+_0x550398+'@'+_0x57ff20+':\x20'+_0x32385b['length']+_0x29b8eb(0x46d),_0x29b8eb(0x171),{'targetType':_0x550398,'targetKey':_0x57ff20,'references':_0x32385b}),this[_0x29b8eb(0x707)]=_0x29b8eb(0x4dc),this[_0x29b8eb(0x67a)]=_0x550398,this['targetKey']=_0x57ff20,this[_0x29b8eb(0x6ee)]=_0x32385b;}}class _0x5cbc98 extends _0x44a72e{constructor(_0xe0e80d,_0x36c784,_0x4486e4){const _0x58f618=_0x8cd7;super(_0x58f618(0x10d)+_0x36c784+_0x58f618(0x304)+_0xe0e80d+_0x58f618(0x24d)+_0x4486e4[_0x58f618(0x757)](_0x491a7a=>_0x491a7a[_0x58f618(0xaa)]+':'+_0x491a7a[_0x58f618(0x707)])[_0x58f618(0x10b)](',\x20'),_0x58f618(0x31c),{'type':_0xe0e80d,'index':_0x36c784,'usedBy':_0x4486e4}),this[_0x58f618(0x707)]=_0x58f618(0x62e);}}return okdbError={'OKDBError':_0x44a72e,'OKDBVersionMismatchError':_0x3c9c1e,'OKDBNotFoundError':_0x181237,'OKDBAlreadyExistsError':_0x3de3a6,'OKDBInvalidIndexKeyError':_0x3a793a,'OKDBInvalidPrimaryKeyError':_0x2189d7,'OKDBTypeNotRegisteredError':_0x26c014,'OKDBTypeAlreadyRegisteredError':_0x8a3f8c,'OKDBIndexNotRegisteredError':_0x3f8fd2,'OKDBIndexAlreadyRegisteredError':_0x14c259,'OKDBInvalidValueError':_0x43c5e7,'OKDBUniqueConstraintError':_0x129a3c,'OKDBSchemaValidationError':_0xc957ec,'OKDBSchemaCollectionError':_0x160b4b,'OKDBForeignKeyError':_0x3445a6,'OKDBForeignKeyDeleteError':_0x593dd2,'OKDBIndexHasConsumersError':_0x5cbc98},okdbError;}var hasRequiredOkdbMigrate;function requireOkdbMigrate(){const _0x1f7bf3=_0x3d20e4;if(hasRequiredOkdbMigrate)return okdbMigrate[_0x1f7bf3(0x71d)];hasRequiredOkdbMigrate=0x1;const _0x268cb0=require$$0$1,_0x3909fa=require$$1,_0x13954a=require$$2,{OKDBError:_0x4c4660}=requireOkdbError(),_0x6046be=_0x1f7bf3(0x632),_0x4c7be3=_0x1f7bf3(0x124),_0x1c72c8=_0x1f7bf3(0x2b7),_0x4c2baf='data',_0x5cefbc='change',_0x7e630b=0x1f4,_0x249d9f=0x3e8,_0x3fe4af='okdb-backup.json';async function _0x5a4efc(_0x2cc592,_0x6629ff,_0x5cd565,_0xdf65c0){const _0x3068c2=_0x1f7bf3;if(_0x2cc592){await _0x2cc592['backup'](_0x5cd565,Boolean(_0xdf65c0));return;}const _0x162cb1=_0x13954a[_0x3068c2(0x1fd)](_0x6629ff,{'readOnly':!![],'maxDbs':0x8});try{await _0x162cb1[_0x3068c2(0x156)](_0x5cd565,Boolean(_0xdf65c0));}finally{await _0x162cb1[_0x3068c2(0x44f)]();}}const _0xf851d=()=>new Promise(_0x56002c=>setImmediate(_0x56002c));function _0x3a014e(_0xdae743,_0x5328a7){const _0x13223d=_0x1f7bf3;if(_0xdae743[_0x13223d(0xb6)](_0x5328a7))return Promise[_0x13223d(0x738)]();return new Promise((_0x53a35c,_0x55a010)=>{const _0x641eb0=_0x13223d,_0x1fa091=_0x1a0272=>{const _0x4fe29a=_0x8cd7;_0xdae743[_0x4fe29a(0x567)]?.(_0x4fe29a(0x61b),_0x4ebbc8),_0xdae743[_0x4fe29a(0x567)]?.(_0x4fe29a(0x492),_0x311554),_0xdae743[_0x4fe29a(0x567)]?.(_0x4fe29a(0x44f),_0x4e8b3b);if(_0x1a0272)_0x55a010(_0x1a0272);else _0x53a35c();},_0x4ebbc8=()=>_0x1fa091(),_0x311554=_0x614242=>_0x1fa091(_0x614242),_0x4e8b3b=()=>_0x1fa091(new Error('export:\x20stream\x20closed\x20before\x20drain'));_0xdae743[_0x641eb0(0x375)](_0x641eb0(0x61b),_0x4ebbc8),_0xdae743[_0x641eb0(0x375)]('error',_0x311554),_0xdae743[_0x641eb0(0x375)]('close',_0x4e8b3b);});}async function _0xb018ea(_0x54266a,_0x5a3764,_0x405ddd){const _0xa0358c=_0x1f7bf3;let _0x446551=0x0,_0x9987a2,_0x1d217f=!![];for(;;){const _0x21a187={'snapshot':!![],'limit':_0x249d9f};!_0x1d217f&&(_0x21a187[_0xa0358c(0x570)]=_0x9987a2,_0x21a187[_0xa0358c(0x15a)]=!![]);_0x1d217f=![];const _0x62ecd7=Array['from'](_0x5a3764[_0xa0358c(0x1c1)](_0x21a187));if(_0x62ecd7[_0xa0358c(0x39d)]===0x0)break;let _0x1ea81b='';for(const _0x233496 of _0x62ecd7)_0x1ea81b+=_0x405ddd(_0x233496)+'\x0a';_0x9987a2=_0x62ecd7[_0x62ecd7[_0xa0358c(0x39d)]-0x1][_0xa0358c(0x466)],_0x446551+=_0x62ecd7[_0xa0358c(0x39d)],await _0x3a014e(_0x54266a,_0x1ea81b);if(_0x62ecd7[_0xa0358c(0x39d)]<_0x249d9f)break;await _0xf851d();}return _0x446551;}class _0x4c2aa4{constructor(_0x47956e){const _0x5b7e15=_0x1f7bf3;this[_0x5b7e15(0x229)]=_0x47956e;}[_0x1f7bf3(0x158)](_0xb1b0da=_0x1f7bf3(0x3e8)){const _0x346cc0=_0x1f7bf3;return this[_0x346cc0(0x229)]['env'](_0xb1b0da);}async[_0x1f7bf3(0x76a)](_0x5704c5=_0x1f7bf3(0x3e8)){const _0x2aa0a2=_0x1f7bf3;return!this[_0x2aa0a2(0x229)][_0x2aa0a2(0x64c)][_0x2aa0a2(0x469)](_0x5704c5)&&await this['okdb'][_0x2aa0a2(0x758)](_0x5704c5,{'sync':!![]}),this[_0x2aa0a2(0x229)]['env'](_0x5704c5);}[_0x1f7bf3(0x278)](_0x22b3ba,_0x16122d){const _0x503abe=_0x1f7bf3,_0x2173b4=[..._0x22b3ba[_0x503abe(0x5e0)][_0x503abe(0x680)]()][_0x503abe(0x293)](_0x581219=>!_0x581219[_0x503abe(0x42e)]('~')&&!_0x581219['startsWith'](_0x503abe(0x53c)));if(!_0x16122d)return _0x2173b4;return _0x2173b4['filter'](_0x21df88=>_0x16122d[_0x503abe(0x8f)](_0x21df88));}[_0x1f7bf3(0x457)](_0x5da1d3,_0x3a0386){const _0x285e9c=_0x1f7bf3,_0x18721a=_0x5da1d3[_0x285e9c(0x105)][_0x285e9c(0x6a)](_0x3a0386),_0x49cec7=_0x5da1d3[_0x285e9c(0x5e0)]['get'](_0x3a0386)||{},_0xc12b65=[];for(const [,_0x2cdc2a]of _0x18721a?.[_0x285e9c(0x149)]??new Map()){const _0x57d480={'fields':_0x2cdc2a[_0x285e9c(0x3cb)]};if(_0x2cdc2a[_0x285e9c(0x6ce)])_0x57d480[_0x285e9c(0x420)]=_0x2cdc2a[_0x285e9c(0x6ce)];if(_0x2cdc2a[_0x285e9c(0x71b)])_0x57d480[_0x285e9c(0x71b)]=!![];_0xc12b65[_0x285e9c(0x2f9)](_0x57d480);}const _0x5dde19={};for(const [_0x4f5e8a,_0xca8960]of Object[_0x285e9c(0x61d)](_0x49cec7['ftsIndexes']||{})){_0x5dde19[_0x4f5e8a]={'fields':_0xca8960[_0x285e9c(0x3f4)]?.['fields'],'tokenizer':_0xca8960['config']?.[_0x285e9c(0x106)]};}const _0x27183b={'indexes':_0xc12b65,'ftsIndexes':_0x5dde19};return _0x49cec7['schema']&&(_0x27183b[_0x285e9c(0x2b7)]=_0x49cec7[_0x285e9c(0x2b7)]),_0x27183b;}async['exportToStream'](_0x555361,_0x590400={}){const _0x19051c=_0x1f7bf3,{envName:envName=_0x19051c(0x3e8),types:types=null,includeChanges:includeChanges=![],_noHeader:_noHeader=![]}=_0x590400,_0x34cfc3=this[_0x19051c(0x158)](envName),_0x1c6dcd=this[_0x19051c(0x278)](_0x34cfc3,types);let _0x2224cb=0x0,_0x26ab52=0x0;!_noHeader&&await _0x3a014e(_0x555361,JSON[_0x19051c(0x5c1)]({'r':_0x6046be,'kdbVersion':require$$3[_0x19051c(0x3e1)],'exportedAt':Date[_0x19051c(0x127)](),'envName':envName})+'\x0a');for(const _0x39e12c of _0x1c6dcd){const _0x5432bf=_0x34cfc3[_0x19051c(0x105)][_0x19051c(0x6a)](_0x39e12c);if(!_0x5432bf)continue;const _0x3b3346=this[_0x19051c(0x457)](_0x34cfc3,_0x39e12c);await _0x3a014e(_0x555361,JSON[_0x19051c(0x5c1)]({'r':_0x1c72c8,'type':_0x39e12c,..._0x3b3346})+'\x0a'),_0x2224cb+=await _0xb018ea(_0x555361,_0x5432bf['data'],({key:_0x5a0157,value:_0x298967,version:_0x268710})=>JSON[_0x19051c(0x5c1)]({'r':_0x4c2baf,'t':_0x39e12c,'k':_0x5a0157,'v':_0x298967,'ver':_0x268710}));}return includeChanges&&_0x34cfc3['_sync']&&(_0x26ab52=await _0xb018ea(_0x555361,_0x34cfc3[_0x19051c(0x4eb)],({key:_0x4292ff,value:_0x273731})=>JSON['stringify']({'r':_0x5cefbc,'clock':_0x4292ff,'event':_0x273731}))),{'types':_0x1c6dcd[_0x19051c(0x39d)],'records':_0x2224cb,'changes':_0x26ab52};}async['exportToFile'](_0x2a1e71,_0x578eef={}){const _0x23dc5f=_0x1f7bf3;_0x268cb0[_0x23dc5f(0x2ad)](_0x3909fa[_0x23dc5f(0x195)](_0x2a1e71),{'recursive':!![]});const _0x3da2c0=_0x268cb0[_0x23dc5f(0x1ff)](_0x2a1e71),_0x565fb0=await this[_0x23dc5f(0x500)](_0x3da2c0,_0x578eef);return await new Promise((_0x23f31e,_0x3c2e08)=>{const _0x1323e4=_0x23dc5f;_0x3da2c0[_0x1323e4(0xe5)](),_0x3da2c0[_0x1323e4(0x375)](_0x1323e4(0x47b),_0x23f31e),_0x3da2c0[_0x1323e4(0x375)](_0x1323e4(0x492),_0x3c2e08);}),{..._0x565fb0,'filePath':_0x2a1e71};}async['exportEnvsToStream'](_0x3e281a,_0xf425ac={}){const _0x545a95=_0x1f7bf3,{envNames:envNames=null,types:types=null,includeChanges:includeChanges=![]}=_0xf425ac,_0x37c1ca=[...this['okdb'][_0x545a95(0x64c)][_0x545a95(0x6d8)]()][_0x545a95(0x293)](_0x31a309=>!_0x31a309[_0x545a95(0x42e)]('~')),_0x3d9024=envNames?_0x37c1ca[_0x545a95(0x293)](_0x37cd34=>envNames[_0x545a95(0x8f)](_0x37cd34)):_0x37c1ca;await _0x3a014e(_0x3e281a,JSON[_0x545a95(0x5c1)]({'r':_0x6046be,'kdbVersion':require$$3['version'],'exportedAt':Date['now'](),'envNames':_0x3d9024})+'\x0a');let _0x34662b=0x0,_0x19e676=0x0,_0x18f5f9=0x0;for(const _0x38893d of _0x3d9024){await _0x3a014e(_0x3e281a,JSON['stringify']({'r':_0x4c7be3,'name':_0x38893d})+'\x0a');const _0x1bf34e=await this[_0x545a95(0x500)](_0x3e281a,{'envName':_0x38893d,'types':types,'includeChanges':includeChanges,'_noHeader':!![]});_0x34662b+=_0x1bf34e[_0x545a95(0x429)],_0x19e676+=_0x1bf34e[_0x545a95(0x3ee)],_0x18f5f9+=_0x1bf34e['changes'];}return{'envs':_0x3d9024[_0x545a95(0x39d)],'types':_0x34662b,'records':_0x19e676,'changes':_0x18f5f9};}async[_0x1f7bf3(0xd2)](_0x52d7c5,_0x22063d={}){const _0x106707=_0x1f7bf3,{envName:_0x24bbf1=null,types:_0xd0a7e1=null,dropExisting:dropExisting=![],batchSize:batchSize=_0x7e630b,includeChanges:includeChanges=![],onProgress:onProgress=null}=_0x22063d;let _0x43874a=_0x24bbf1??_0x106707(0x3e8),_0x59f48a=null,_0x50f892=0x0,_0x2d6fb0=0x0,_0x4acd2a=0x0,_0xd9452b=null,_0x21753b=[];const _0x386a87=[],_0x296139=async()=>{const _0x341da5=_0x106707;if(!_0x21753b[_0x341da5(0x39d)]||!_0xd9452b||!_0x59f48a)return;await _0x59f48a['_writer'][_0x341da5(0x4f9)](()=>{const _0x197cb=_0x341da5;for(const {k:_0x205e70,v:_0x35460e,ver:_0x5167e6}of _0x21753b){_0x59f48a[_0x197cb(0x483)](null,_0xd9452b,_0x205e70,_0x35460e,{'version':_0x5167e6,'origin':_0x197cb(0x1e2)});}}),_0x2d6fb0+=_0x21753b[_0x341da5(0x39d)],onProgress?.({'type':_0xd9452b,'count':_0x2d6fb0}),_0x21753b=[];};await this[_0x106707(0x75)](_0x52d7c5,async _0xc71cb0=>{const _0x47d57a=_0x106707,_0x33bf3b=_0xc71cb0['r'];if(_0x33bf3b===_0x6046be){if(!_0x24bbf1&&_0xc71cb0['envName'])_0x43874a=_0xc71cb0[_0x47d57a(0x30b)];_0x59f48a=await this[_0x47d57a(0x76a)](_0x43874a);return;}if(!_0x59f48a)_0x59f48a=await this[_0x47d57a(0x76a)](_0x43874a);if(_0x33bf3b===_0x4c7be3){await _0x296139(),_0xd9452b=null,_0x43874a=_0x24bbf1??_0xc71cb0[_0x47d57a(0x707)],_0x59f48a=await this[_0x47d57a(0x76a)](_0x43874a);return;}if(_0x33bf3b===_0x1c72c8){const {type:_0x3007e8,indexes:indexes=[],ftsIndexes:ftsIndexes={},schema:_0x499d60}=_0xc71cb0;if(_0xd0a7e1&&!_0xd0a7e1[_0x47d57a(0x8f)](_0x3007e8))return;await _0x296139(),_0xd9452b=_0x3007e8;dropExisting&&_0x59f48a[_0x47d57a(0x753)](_0x3007e8)&&await _0x59f48a[_0x47d57a(0x729)](_0x3007e8);!_0x59f48a[_0x47d57a(0x753)](_0x3007e8)&&(await _0x59f48a['registerType'](_0x3007e8),_0x50f892++);for(const _0x4fa0a6 of indexes){if(!_0x59f48a['hasIndex'](_0x3007e8,_0x4fa0a6[_0x47d57a(0x6b0)])){const _0x2a39e0={};_0x4fa0a6[_0x47d57a(0x420)]&&(_0x2a39e0[_0x47d57a(0x66f)]=_0x47d57a(0x420),_0x2a39e0['precision']=_0x4fa0a6[_0x47d57a(0x420)][_0x47d57a(0x69f)]);if(_0x4fa0a6['unique'])_0x2a39e0['unique']=!![];await _0x59f48a['registerIndex'](_0x3007e8,_0x4fa0a6[_0x47d57a(0x6b0)],_0x2a39e0);}}for(const [_0x3a77e4,_0x37b652]of Object['entries'](ftsIndexes)){!this[_0x47d57a(0x229)][_0x47d57a(0x2c1)][_0x47d57a(0x469)](_0x3007e8,_0x3a77e4,_0x59f48a)&&await this[_0x47d57a(0x229)]['fts'][_0x47d57a(0x44e)](_0x3007e8,_0x3a77e4,{'fields':_0x37b652['fields'],'tokenizer':_0x37b652[_0x47d57a(0x106)]},undefined,_0x59f48a);}_0x499d60?.[_0x47d57a(0xb8)]&&_0x386a87[_0x47d57a(0x2f9)]({'env':_0x59f48a,'type':_0x3007e8,'schema':_0x499d60});return;}if(_0x33bf3b===_0x4c2baf){if(_0xd0a7e1&&!_0xd0a7e1[_0x47d57a(0x8f)](_0xc71cb0['t']))return;_0xc71cb0['t']!==_0xd9452b&&(await _0x296139(),_0xd9452b=_0xc71cb0['t']);_0x21753b['push']({'k':_0xc71cb0['k'],'v':_0xc71cb0['v'],'ver':_0xc71cb0[_0x47d57a(0x4a6)]});if(_0x21753b[_0x47d57a(0x39d)]>=batchSize)await _0x296139();return;}_0x33bf3b===_0x5cefbc&&includeChanges&&_0x59f48a[_0x47d57a(0x731)]&&(_0x59f48a[_0x47d57a(0x4eb)][_0x47d57a(0x16c)](_0xc71cb0[_0x47d57a(0x73d)],_0xc71cb0['event']),_0x4acd2a++);}),await _0x296139();for(const {env:_0x12d821,type:_0x1bbf23,schema:_0x50085e}of _0x386a87){try{await _0x12d821[_0x106707(0x2e1)](_0x1bbf23,_0x50085e);}catch{if(_0x50085e[_0x106707(0x213)])try{await _0x12d821[_0x106707(0x2e1)](_0x1bbf23,{..._0x50085e,'enforce':![]});}catch{}}}return{'types':_0x50f892,'records':_0x2d6fb0,'changes':_0x4acd2a};}async[_0x1f7bf3(0x1be)](_0x55a215,_0x10fd62={}){const _0x3cd7c9=_0x1f7bf3,_0x13038e=_0x268cb0['createReadStream'](_0x55a215,{'encoding':_0x3cd7c9(0x320)});return this['importFromStream'](_0x13038e,_0x10fd62);}[_0x1f7bf3(0x75)](_0x44489e,_0x880628){return new Promise((_0x4bbc36,_0x26e040)=>{const _0x16aaa7=_0x8cd7;let _0x1601c4='',_0x2614a8=Promise[_0x16aaa7(0x738)]();const _0x517c0f=async _0x5df4f5=>{const _0x52924c=_0x16aaa7;_0x1601c4+=_0x5df4f5;const _0x43ede9=_0x1601c4[_0x52924c(0x2aa)]('\x0a');_0x1601c4=_0x43ede9[_0x52924c(0x76e)]();for(const _0x388743 of _0x43ede9){const _0x3537a5=_0x388743['trim']();if(!_0x3537a5)continue;let _0x5af514;try{_0x5af514=JSON[_0x52924c(0xc3)](_0x3537a5);}catch{continue;}await _0x880628(_0x5af514);}};_0x44489e['on'](_0x16aaa7(0x32e),_0x5b73b1=>{const _0x31661f=_0x16aaa7;_0x2614a8=_0x2614a8[_0x31661f(0xad)](()=>_0x517c0f(String(_0x5b73b1)));}),_0x44489e['on'](_0x16aaa7(0xe5),()=>{const _0x3611fd=_0x16aaa7;_0x2614a8[_0x3611fd(0xad)](async()=>{const _0xef430a=_0x3611fd,_0x49cacd=_0x1601c4['trim']();if(_0x49cacd)try{await _0x880628(JSON[_0xef430a(0xc3)](_0x49cacd));}catch{}_0x4bbc36();})[_0x3611fd(0x618)](_0x26e040);}),_0x44489e['on']('error',_0x26e040);});}async[_0x1f7bf3(0x156)](_0xfa9ed8,_0x7c28a8={}){const _0x46c3c5=_0x1f7bf3,{envNames:envNames=null,compact:compact=!![]}=_0x7c28a8,_0x19de55=this[_0x46c3c5(0x229)],_0x451e24=_0x3909fa[_0x46c3c5(0x738)](_0x19de55[_0x46c3c5(0x4c5)]),_0x24d366=_0x3909fa[_0x46c3c5(0x738)](_0xfa9ed8),_0x3602c6=_0x3909fa['relative'](_0x451e24,_0x24d366);if(_0x3602c6===''||!(_0x3602c6['startsWith']('..')||_0x3909fa[_0x46c3c5(0x65d)](_0x3602c6)))throw new _0x4c4660(_0x46c3c5(0x444)+_0x24d366+_0x46c3c5(0x5f1)+_0x451e24+_0x46c3c5(0x265),_0x46c3c5(0x360));if(_0x268cb0[_0x46c3c5(0x1c9)](_0x24d366)&&_0x268cb0[_0x46c3c5(0x1ed)](_0x24d366)['length']>0x0)throw new _0x4c4660(_0x46c3c5(0x444)+_0x24d366+_0x46c3c5(0x649),_0x46c3c5(0x4b9));_0x268cb0[_0x46c3c5(0x2ad)](_0x24d366,{'recursive':!![]});const _0x5a4b18=envNames?new Set([...envNames,_0x46c3c5(0x668)]):null,_0x169f38=[],_0x1e0922=[],_0x35c8db=[];for(const [_0x4a272a,_0x460cc8]of[..._0x19de55['_envs'][_0x46c3c5(0x61d)]()]){if(_0x5a4b18&&!_0x5a4b18[_0x46c3c5(0x469)](_0x4a272a))continue;if(_0x4a272a===_0x46c3c5(0x63c))continue;if(!_0x460cc8[_0x46c3c5(0x550)]||!_0x460cc8['db']){_0x1e0922[_0x46c3c5(0x2f9)]({'name':_0x4a272a,'reason':_0x46c3c5(0x1c0)});continue;}const _0x11bdb4=_0x3909fa['resolve'](_0x460cc8['path']),_0x56b475=_0x3909fa[_0x46c3c5(0x61e)](_0x451e24,_0x11bdb4),_0x47345a=_0x56b475===''||_0x56b475['startsWith']('..')||_0x3909fa[_0x46c3c5(0x65d)](_0x56b475),_0x3774a6=_0x47345a?_0x19de55['_safeEnvDirName'](_0x4a272a):_0x56b475,_0x168027=_0x3909fa[_0x46c3c5(0x10b)](_0x24d366,_0x3774a6);_0x268cb0[_0x46c3c5(0x2ad)](_0x168027,{'recursive':!![]});const _0x501607=_0x3909fa[_0x46c3c5(0x10b)](_0x11bdb4,_0x46c3c5(0x60f));let _0x141357=![];if(_0x268cb0[_0x46c3c5(0x1c9)](_0x3909fa[_0x46c3c5(0x10b)](_0x501607,_0x46c3c5(0x192)))){const _0x226c7e=_0x3909fa['join'](_0x168027,_0x46c3c5(0x60f));_0x268cb0['mkdirSync'](_0x226c7e,{'recursive':!![]}),await _0x5a4efc(_0x460cc8[_0x46c3c5(0x121)]?.['_store']?.['db'],_0x501607,_0x226c7e,compact),_0x141357=!![];}let _0x5a2e02=0x0;try{_0x5a2e02=_0x268cb0[_0x46c3c5(0x52d)](_0x3909fa[_0x46c3c5(0x10b)](_0x11bdb4,_0x46c3c5(0x192)))['size'];}catch{}await _0x460cc8['db'][_0x46c3c5(0x156)](_0x168027,Boolean(compact));let _0x2abb0c=0x0;try{_0x2abb0c=_0x268cb0[_0x46c3c5(0x52d)](_0x3909fa[_0x46c3c5(0x10b)](_0x168027,_0x46c3c5(0x192)))[_0x46c3c5(0x35f)];}catch{}_0x169f38[_0x46c3c5(0x2f9)]({'name':_0x4a272a,'dest':_0x168027,'sizeBefore':_0x5a2e02,'sizeAfter':_0x2abb0c,'timeMachine':_0x141357}),_0x35c8db[_0x46c3c5(0x2f9)]({'name':_0x4a272a,'dir':_0x3774a6,'timeMachine':_0x141357,..._0x47345a?{'outOfTree':_0x47345a,'sourcePath':_0x11bdb4}:{}});}for(const [_0x5e28ff,_0x2d1893]of _0x19de55[_0x46c3c5(0xf7)]??[]){if(_0x5a4b18&&!_0x5a4b18['has'](_0x5e28ff))continue;_0x1e0922[_0x46c3c5(0x2f9)]({'name':_0x5e28ff,'reason':'quarantined:\x20'+(_0x2d1893?.[_0x46c3c5(0x492)]??_0x46c3c5(0xd0))});}const _0x3bf353={'count':0x0,'bytes':0x0},_0x5ca520=_0x19de55[_0x46c3c5(0x4e4)]?.['_blobsDir'];_0x5ca520&&_0x268cb0[_0x46c3c5(0x1c9)](_0x5ca520)&&await this[_0x46c3c5(0x1cc)](_0x5ca520,_0x3909fa[_0x46c3c5(0x10b)](_0x24d366,_0x46c3c5(0x6ea)),_0x3bf353,(_0x418c43,_0xc42c9)=>_0xc42c9===0x0&&_0x418c43===_0x46c3c5(0x6d7));const _0x25f265=_0x3909fa[_0x46c3c5(0x10b)](_0x24d366,_0x3fe4af),_0x28f3a1={'format':0x1,'okdbVersion':require$$3[_0x46c3c5(0x3e1)],'createdAt':new Date()[_0x46c3c5(0x261)](),'source':_0x451e24,'compact':Boolean(compact),'envs':_0x35c8db,'blobs':_0x3bf353,'skipped':_0x1e0922,'excluded':{'~fts':_0x46c3c5(0x474),'~processes':'live\x20process\x20registry;\x20disposable'}};return _0x268cb0[_0x46c3c5(0x188)](_0x25f265,JSON['stringify'](_0x28f3a1,null,0x2)+'\x0a'),{'ok':!![],'dest':_0x24d366,'envs':_0x169f38,'blobs':_0x3bf353,'skipped':_0x1e0922,'manifest':_0x25f265};}['backupRoot'](){const _0x19b9eb=_0x1f7bf3,_0x47cbcc=this[_0x19b9eb(0x229)][_0x19b9eb(0x518)]?.[_0x19b9eb(0x156)]?.['root'];if(_0x47cbcc)return _0x3909fa[_0x19b9eb(0x738)](_0x47cbcc);const _0x593ca7=_0x3909fa[_0x19b9eb(0x738)](this[_0x19b9eb(0x229)]['path']);return _0x3909fa[_0x19b9eb(0x10b)](_0x3909fa[_0x19b9eb(0x195)](_0x593ca7),_0x3909fa['basename'](_0x593ca7)+_0x19b9eb(0x5c6));}[_0x1f7bf3(0x1a1)](_0x346166){const _0x2182a8=_0x1f7bf3,_0x1e2fb0=this['backupRoot']();_0x268cb0['mkdirSync'](_0x1e2fb0,{'recursive':!![]});const _0x1942dc=_0x268cb0['realpathSync'](_0x1e2fb0),_0x5597aa=_0x346166==null||String(_0x346166)[_0x2182a8(0x471)]()===''?_0x2182a8(0x3d2)+new Date()[_0x2182a8(0x261)]()[_0x2182a8(0x416)](/[:.]/g,'-'):String(_0x346166)['trim'](),_0x54fb26=_0x3909fa['resolve'](_0x1e2fb0,_0x5597aa);let _0x250769=_0x54fb26;const _0x5845f0=[];while(!_0x268cb0[_0x2182a8(0x1c9)](_0x250769)){_0x5845f0[_0x2182a8(0x232)](_0x3909fa[_0x2182a8(0x699)](_0x250769));const _0x5ef6d1=_0x3909fa['dirname'](_0x250769);if(_0x5ef6d1===_0x250769)break;_0x250769=_0x5ef6d1;}const _0x4a964f=_0x3909fa['join'](_0x268cb0[_0x2182a8(0x279)](_0x250769),..._0x5845f0),_0x45c929=_0x3909fa[_0x2182a8(0x61e)](_0x1942dc,_0x4a964f);if(_0x45c929===''||_0x45c929[_0x2182a8(0x42e)]('..')||_0x3909fa['isAbsolute'](_0x45c929))throw new _0x4c4660('backup\x20destination\x20\x22'+_0x5597aa+_0x2182a8(0x2b9)+_0x1e2fb0+_0x2182a8(0x430),_0x2182a8(0x4bc),{'root':_0x1e2fb0,'destDir':_0x5597aa});return{'root':_0x1e2fb0,'dest':_0x4a964f};}async[_0x1f7bf3(0x1cc)](_0x5c5505,_0x6fa817,_0xd0051b={'count':0x0,'bytes':0x0},_0x1f687b=null,_0x4f9fd3=0x0){const _0x1ffe53=_0x1f7bf3;_0x268cb0[_0x1ffe53(0x2ad)](_0x6fa817,{'recursive':!![]});for(const _0xa6bc25 of _0x268cb0[_0x1ffe53(0x1ed)](_0x5c5505,{'withFileTypes':!![]})){if(_0x1f687b?.(_0xa6bc25[_0x1ffe53(0x707)],_0x4f9fd3))continue;const _0x10e866=_0x3909fa['join'](_0x5c5505,_0xa6bc25['name']),_0x183232=_0x3909fa[_0x1ffe53(0x10b)](_0x6fa817,_0xa6bc25[_0x1ffe53(0x707)]);if(_0xa6bc25[_0x1ffe53(0x6e0)]())await this[_0x1ffe53(0x1cc)](_0x10e866,_0x183232,_0xd0051b,_0x1f687b,_0x4f9fd3+0x1);else{try{await _0x268cb0[_0x1ffe53(0x242)][_0x1ffe53(0x99)](_0x10e866,_0x183232);}catch(_0x1f2e66){if(_0x1f2e66?.[_0x1ffe53(0x25b)]===_0x1ffe53(0x109))continue;throw _0x1f2e66;}_0xd0051b[_0x1ffe53(0x6ad)]++;try{_0xd0051b['bytes']+=_0x268cb0['statSync'](_0x183232)[_0x1ffe53(0x35f)];}catch{}}}return _0xd0051b;}async[_0x1f7bf3(0x23a)](_0x1ef8b5={}){const _0x1da115=_0x1f7bf3,{envName:envName=_0x1da115(0x3e8),types:types=null,includeChanges:includeChanges=![]}=_0x1ef8b5,_0x2b48ad={'types':{},'changes':[]},_0x366178=[],_0xf41cb6=new require$$5[(_0x1da115(0xd3))]({'write'(_0xdf1eb0,_0x745a56,_0xda2b9){const _0x5dcf32=_0x1da115;_0x366178[_0x5dcf32(0x2f9)](String(_0xdf1eb0)),_0xda2b9();}});await this[_0x1da115(0x500)](_0xf41cb6,{'envName':envName,'types':types,'includeChanges':includeChanges});for(const _0x574387 of _0x366178['join']('')[_0x1da115(0x2aa)]('\x0a')){const _0x3cb3dc=_0x574387[_0x1da115(0x471)]();if(!_0x3cb3dc)continue;let _0xcfc91e;try{_0xcfc91e=JSON['parse'](_0x3cb3dc);}catch{continue;}if(_0xcfc91e['r']===_0x1c72c8){if(!_0x2b48ad[_0x1da115(0x429)][_0xcfc91e['type']])_0x2b48ad[_0x1da115(0x429)][_0xcfc91e[_0x1da115(0x66f)]]={'entries':[]};if(_0xcfc91e[_0x1da115(0x21f)])_0x2b48ad['types'][_0xcfc91e[_0x1da115(0x66f)]][_0x1da115(0x21f)]=_0xcfc91e[_0x1da115(0x21f)];if(_0xcfc91e[_0x1da115(0x73)])_0x2b48ad[_0x1da115(0x429)][_0xcfc91e[_0x1da115(0x66f)]][_0x1da115(0x73)]=_0xcfc91e['ftsIndexes'];if(_0xcfc91e[_0x1da115(0x2b7)])_0x2b48ad[_0x1da115(0x429)][_0xcfc91e[_0x1da115(0x66f)]][_0x1da115(0x2b7)]=_0xcfc91e['schema'];}else{if(_0xcfc91e['r']===_0x4c2baf){if(!_0x2b48ad[_0x1da115(0x429)][_0xcfc91e['t']])_0x2b48ad[_0x1da115(0x429)][_0xcfc91e['t']]={'entries':[]};_0x2b48ad[_0x1da115(0x429)][_0xcfc91e['t']][_0x1da115(0x61d)][_0x1da115(0x2f9)]({'key':_0xcfc91e['k'],'value':_0xcfc91e['v'],'version':_0xcfc91e['ver']});}else _0xcfc91e['r']===_0x5cefbc&&_0x2b48ad[_0x1da115(0x6b8)][_0x1da115(0x2f9)]({'clock':_0xcfc91e[_0x1da115(0x73d)],'event':_0xcfc91e[_0x1da115(0x6bf)]});}}return _0x2b48ad;}async['import'](_0x186fc3,_0xe100fd={}){const _0x3b410b=_0x1f7bf3,_0x13e849=[];for(const [_0x30d1eb,_0x2a7d29]of Object[_0x3b410b(0x61d)](_0x186fc3[_0x3b410b(0x429)]||{})){const _0x3b7f79={'r':_0x1c72c8,'type':_0x30d1eb,'indexes':_0x2a7d29['indexes']||[],'ftsIndexes':_0x2a7d29['ftsIndexes']||{}};if(_0x2a7d29[_0x3b410b(0x2b7)])_0x3b7f79[_0x3b410b(0x2b7)]=_0x2a7d29['schema'];_0x13e849[_0x3b410b(0x2f9)](JSON[_0x3b410b(0x5c1)](_0x3b7f79));for(const {key:_0x32947c,value:_0x1654fa,version:_0x13c5c6}of _0x2a7d29['entries']||[]){_0x13e849[_0x3b410b(0x2f9)](JSON[_0x3b410b(0x5c1)]({'r':_0x4c2baf,'t':_0x30d1eb,'k':_0x32947c,'v':_0x1654fa,'ver':_0x13c5c6}));}}for(const {clock:_0x453d20,event:_0x54f9de}of _0x186fc3[_0x3b410b(0x6b8)]||[]){_0x13e849[_0x3b410b(0x2f9)](JSON[_0x3b410b(0x5c1)]({'r':_0x5cefbc,'clock':_0x453d20,'event':_0x54f9de}));}const {Readable:_0x2ed81a}=require$$5,_0x16b810=_0x2ed81a[_0x3b410b(0x690)](_0x13e849['join']('\x0a')+'\x0a');return this['importFromStream'](_0x16b810,{..._0xe100fd,'dropExisting':_0xe100fd[_0x3b410b(0x468)]??!![]});}async[_0x1f7bf3(0x5b2)]({pretty:pretty=![]}={}){const _0x54732f=_0x1f7bf3,_0x214802=await this[_0x54732f(0x23a)]();return JSON['stringify'](_0x214802,null,pretty?0x2:0x0);}async[_0x1f7bf3(0x482)](_0xfc766){const _0x4fea7d=_0x1f7bf3,_0x50e0af=JSON[_0x4fea7d(0xc3)](_0xfc766);return this['import'](_0x50e0af);}async['exportBlobs'](_0x32ee62){const _0x154305=_0x1f7bf3;if(!this['okdb']['files'])throw new Error(_0x154305(0x6a1));const _0x1cda8c=this['okdb'][_0x154305(0x4e4)][_0x154305(0x18c)];let _0x5d1250=0x0,_0x70ad90=0x0;const _0x5a0b10=_0x52ac16=>{const _0x1969d2=_0x154305;if(!_0x268cb0[_0x1969d2(0x1c9)](_0x52ac16))return;for(const _0x3fc7fe of _0x268cb0['readdirSync'](_0x52ac16,{'withFileTypes':!![]})){const _0xf6fb87=_0x3909fa['join'](_0x52ac16,_0x3fc7fe[_0x1969d2(0x707)]);if(_0x3fc7fe[_0x1969d2(0x6e0)]()){if(_0x3fc7fe[_0x1969d2(0x707)]===_0x1969d2(0x6d7))continue;_0x5a0b10(_0xf6fb87);}else{const _0x8d1723=_0x3909fa[_0x1969d2(0x699)](_0x3909fa[_0x1969d2(0x195)](_0xf6fb87)),_0x594999=_0x8d1723+_0x3fc7fe['name'],_0x44fe7=_0x3909fa[_0x1969d2(0x10b)](_0x32ee62,_0x594999['slice'](0x0,0x2)),_0x218ace=_0x3909fa[_0x1969d2(0x10b)](_0x44fe7,_0x594999[_0x1969d2(0x13a)](0x2));_0x268cb0[_0x1969d2(0x2ad)](_0x44fe7,{'recursive':!![]}),_0x268cb0[_0x1969d2(0x326)](_0xf6fb87,_0x218ace),_0x5d1250++;try{_0x70ad90+=_0x268cb0['statSync'](_0xf6fb87)['size'];}catch{}}}};return _0x268cb0[_0x154305(0x2ad)](_0x32ee62,{'recursive':!![]}),_0x5a0b10(_0x1cda8c),{'count':_0x5d1250,'bytes':_0x70ad90};}async[_0x1f7bf3(0x2d0)](_0x1d6343){const _0x1f722e=_0x1f7bf3;if(!this[_0x1f722e(0x229)][_0x1f722e(0x4e4)])throw new Error(_0x1f722e(0x6a1));await this['okdb']['files'][_0x1f722e(0x5ac)]();let _0x179091=0x0,_0x4fbb26=0x0;const _0x2ffd7f=_0x578d5d=>{const _0x2a13a6=_0x1f722e;if(!_0x268cb0[_0x2a13a6(0x1c9)](_0x578d5d))return;for(const _0x319aba of _0x268cb0[_0x2a13a6(0x1ed)](_0x578d5d,{'withFileTypes':!![]})){const _0x25a0e7=_0x3909fa[_0x2a13a6(0x10b)](_0x578d5d,_0x319aba[_0x2a13a6(0x707)]);if(_0x319aba[_0x2a13a6(0x6e0)]())_0x2ffd7f(_0x25a0e7);else{const _0x1ef230=_0x3909fa[_0x2a13a6(0x699)](_0x3909fa[_0x2a13a6(0x195)](_0x25a0e7)),_0x5c6dc6=_0x1ef230+_0x319aba[_0x2a13a6(0x707)],_0x581615=this[_0x2a13a6(0x229)]['files'][_0x2a13a6(0x6f2)](_0x5c6dc6);if(_0x268cb0[_0x2a13a6(0x1c9)](_0x581615)){_0x4fbb26++;continue;}const _0x200443=_0x3909fa[_0x2a13a6(0x195)](_0x581615);_0x268cb0[_0x2a13a6(0x2ad)](_0x200443,{'recursive':!![]}),_0x268cb0[_0x2a13a6(0x326)](_0x25a0e7,_0x581615);const _0x4e73ba=this[_0x2a13a6(0x229)][_0x2a13a6(0x4e4)][_0x2a13a6(0x308)](_0x5c6dc6);this['okdb'][_0x2a13a6(0x4e4)][_0x2a13a6(0xeb)]?.[_0x2a13a6(0x16c)](_0x5c6dc6,{'refs':_0x4e73ba}),_0x179091++;}}};return _0x2ffd7f(_0x1d6343),{'imported':_0x179091,'skipped':_0x4fbb26};}[_0x1f7bf3(0x5d8)](){const _0x139a86=_0x1f7bf3,_0x3ed248=[];for(const [,_0xfa81cd]of this[_0x139a86(0x229)]['_envs']){if(_0xfa81cd['_sync']&&_0xfa81cd['hasType']('~files'))_0x3ed248[_0x139a86(0x2f9)](_0xfa81cd);}return _0x3ed248;}async[_0x1f7bf3(0x5d2)](){const _0x4beef5=_0x1f7bf3;if(!this[_0x4beef5(0x229)]['files'])throw new Error(_0x4beef5(0x6a1));await this[_0x4beef5(0x229)][_0x4beef5(0x4e4)]['_ensure']();const _0x433adc=[],_0x384cbe=this[_0x4beef5(0x229)][_0x4beef5(0x4e4)];for(const _0x35ee80 of this[_0x4beef5(0x5d8)]()){for(const {key:_0x243e73,value:_0x41fe3c}of _0x35ee80['getRange'](_0x4beef5(0xba))){if(!_0x41fe3c[_0x4beef5(0x357)])continue;const _0x104479=_0x384cbe[_0x4beef5(0x6f2)](_0x41fe3c[_0x4beef5(0x357)]);!_0x268cb0[_0x4beef5(0x1c9)](_0x104479)&&_0x433adc['push']({'type':_0x4beef5(0x120),'env':_0x35ee80[_0x4beef5(0x707)],'id':String(_0x243e73),'hash':_0x41fe3c[_0x4beef5(0x357)],'message':_0x4beef5(0x3be)+_0x243e73+_0x4beef5(0x378)+_0x35ee80[_0x4beef5(0x707)]+_0x4beef5(0x407)+_0x41fe3c[_0x4beef5(0x357)][_0x4beef5(0x13a)](0x0,0x8)+'…)'});const _0x1b5f02=_0x384cbe[_0x4beef5(0xeb)]?.[_0x4beef5(0x6a)](_0x41fe3c['hash']);(!_0x1b5f02||_0x1b5f02[_0x4beef5(0x47f)]<=0x0)&&_0x433adc[_0x4beef5(0x2f9)]({'type':_0x4beef5(0x2f5),'env':_0x35ee80[_0x4beef5(0x707)],'id':String(_0x243e73),'hash':_0x41fe3c['hash'],'message':_0x4beef5(0x65a)+_0x243e73+'\x22\x20in\x20env\x20\x22'+_0x35ee80[_0x4beef5(0x707)]+'\x22\x20(hash:\x20'+_0x41fe3c[_0x4beef5(0x357)][_0x4beef5(0x13a)](0x0,0x8)+'…)'});}}const _0x11077c=new Set();for(const _0x394900 of this[_0x4beef5(0x5d8)]()){for(const {value:_0x52bbf2}of _0x394900['getRange'](_0x4beef5(0xba))){if(_0x52bbf2[_0x4beef5(0x357)])_0x11077c['add'](_0x52bbf2[_0x4beef5(0x357)]);}}const _0x230491=_0x1acd17=>{const _0x58b2c1=_0x4beef5;if(!_0x268cb0[_0x58b2c1(0x1c9)](_0x1acd17))return;for(const _0x7362ce of _0x268cb0[_0x58b2c1(0x1ed)](_0x1acd17,{'withFileTypes':!![]})){const _0x4918c5=_0x3909fa[_0x58b2c1(0x10b)](_0x1acd17,_0x7362ce[_0x58b2c1(0x707)]);if(_0x7362ce[_0x58b2c1(0x6e0)]()){if(_0x7362ce[_0x58b2c1(0x707)]===_0x58b2c1(0x6d7))continue;_0x230491(_0x4918c5);}else{const _0xb09963=_0x3909fa[_0x58b2c1(0x699)](_0x3909fa[_0x58b2c1(0x195)](_0x4918c5)),_0x57fe6b=_0xb09963+_0x7362ce[_0x58b2c1(0x707)];!_0x11077c['has'](_0x57fe6b)&&_0x433adc[_0x58b2c1(0x2f9)]({'type':_0x58b2c1(0x117),'hash':_0x57fe6b,'message':_0x58b2c1(0x49f)+_0x57fe6b[_0x58b2c1(0x13a)](0x0,0x8)+'…)'});}}};return _0x230491(_0x384cbe[_0x4beef5(0x18c)]),_0x433adc;}async['repairBlobRefs'](){const _0x4367bd=_0x1f7bf3;if(!this[_0x4367bd(0x229)]['files'])throw new Error(_0x4367bd(0x6a1));await this['okdb'][_0x4367bd(0x4e4)]['_ensure']();const _0x475312=this[_0x4367bd(0x229)][_0x4367bd(0x4e4)]['_blobStatusDb'];if(!_0x475312)throw new Error(_0x4367bd(0x6bc));const _0x57e945=[];for(const {key:_0x1a54e0}of _0x475312[_0x4367bd(0x1c1)]())_0x57e945[_0x4367bd(0x2f9)](_0x1a54e0);for(const _0x2fd84c of _0x57e945)_0x475312[_0x4367bd(0x59e)](_0x2fd84c);const _0x5d1e12=new Map();for(const _0x638a0c of this[_0x4367bd(0x5d8)]()){for(const {value:_0x27a27f}of _0x638a0c[_0x4367bd(0x1c1)](_0x4367bd(0xba))){_0x27a27f['hash']&&_0x5d1e12[_0x4367bd(0x49d)](_0x27a27f['hash'],(_0x5d1e12['get'](_0x27a27f[_0x4367bd(0x357)])??0x0)+0x1);}}for(const [_0x38bb08,_0x1b4c2c]of _0x5d1e12){_0x475312[_0x4367bd(0x16c)](_0x38bb08,{'refs':_0x1b4c2c});}return{'rebuilt':_0x5d1e12[_0x4367bd(0x35f)]};}}return okdbMigrate['exports']=_0x4c2aa4,okdbMigrate[_0x1f7bf3(0x71d)][_0x1f7bf3(0x585)]=_0x3fe4af,okdbMigrate['exports'];}var okdbAuthTokens,hasRequiredOkdbAuthTokens;function requireOkdbAuthTokens(){if(hasRequiredOkdbAuthTokens)return okdbAuthTokens;hasRequiredOkdbAuthTokens=0x1;const _0x28cc93=require$$2$1;function _0x10557a(_0x59fc74,_0x5b4acb){const _0x3f22e7=_0x8cd7;return _0x28cc93[_0x3f22e7(0x6d5)](_0x3f22e7(0x647),_0x5b4acb)['update'](_0x59fc74)[_0x3f22e7(0x674)](_0x3f22e7(0x1bf));}function _0x16e986(_0x24554a,_0x1abcca){const _0x325b3c=_0x8cd7;if(typeof _0x24554a!=='string'||typeof _0x1abcca!=='string')return![];if(Buffer[_0x325b3c(0x32c)](_0x24554a)!==Buffer[_0x325b3c(0x32c)](_0x1abcca))return![];return _0x28cc93[_0x325b3c(0xa8)](Buffer[_0x325b3c(0x690)](_0x24554a),Buffer[_0x325b3c(0x690)](_0x1abcca));}function _0x32e4a5(_0x217c9c){const _0x18a853=_0x8cd7;if(!_0x217c9c?.[_0x18a853(0x42e)](_0x18a853(0x557)))return null;return _0x217c9c[_0x18a853(0x13a)](0x7);}function _0x492f49(_0x4515b5=0x20){const _0x3ceb75=_0x8cd7;return _0x28cc93[_0x3ceb75(0x122)](_0x4515b5)[_0x3ceb75(0x240)](_0x3ceb75(0x1bf));}function _0x17eca6(_0x690ffd){const _0x532d6a=_0x8cd7;return _0x28cc93[_0x532d6a(0x3cc)](_0x532d6a(0x647))[_0x532d6a(0x29f)](_0x690ffd)[_0x532d6a(0x674)](_0x532d6a(0x31b));}function _0x3e9cb4(_0x5107bf,_0x2c963a,_0x286562=0x36ee80){const _0x4f30c1=_0x8cd7;if(!_0x2c963a)throw new Error(_0x4f30c1(0x1dc));const _0x213a4a=Date[_0x4f30c1(0x127)](),_0x2b2458=Buffer[_0x4f30c1(0x690)](JSON['stringify']({'iat':_0x213a4a,'exp':_0x213a4a+_0x286562,'sub':_0x5107bf?.['id']??_0x5107bf?.['sub']??null,'username':_0x5107bf?.[_0x4f30c1(0x573)]??_0x5107bf?.[_0x4f30c1(0x707)]??null,'roles':Array[_0x4f30c1(0x339)](_0x5107bf?.['roles'])?_0x5107bf[_0x4f30c1(0x733)]:[]}))[_0x4f30c1(0x240)](_0x4f30c1(0x1bf)),_0x5479f0=_0x10557a(_0x2b2458,_0x2c963a);return _0x2b2458+'.'+_0x5479f0;}function _0x12b462(_0x20c854,_0x1e0785){const _0x26a7ae=_0x8cd7;if(!_0x1e0785||typeof _0x20c854!==_0x26a7ae(0xe7))return null;const [_0x11cd76,_0x54f663]=_0x20c854[_0x26a7ae(0x2aa)]('.');if(!_0x11cd76||!_0x54f663)return null;const _0x71f2e=_0x10557a(_0x11cd76,_0x1e0785);if(!_0x16e986(_0x54f663,_0x71f2e))return null;try{const _0x4ee268=JSON['parse'](Buffer['from'](_0x11cd76,_0x26a7ae(0x1bf))['toString']()),_0x55a389=0x7530;if(Date[_0x26a7ae(0x127)]()>Number(_0x4ee268?.['exp']??0x0)+_0x55a389)return null;return _0x4ee268;}catch{return null;}}async function _0x54062a(_0x4091e5){return new Promise((_0x5c7351,_0x202e8f)=>{const _0x29908a=_0x8cd7,_0x5f2397=_0x28cc93[_0x29908a(0x122)](0x10);_0x28cc93[_0x29908a(0x6ec)](_0x4091e5,_0x5f2397,0x40,(_0x427dd2,_0x36d9d6)=>{const _0x1fdde3=_0x29908a;if(_0x427dd2)return _0x202e8f(_0x427dd2);_0x5c7351(_0x5f2397[_0x1fdde3(0x240)](_0x1fdde3(0x31b))+':'+_0x36d9d6[_0x1fdde3(0x240)](_0x1fdde3(0x31b)));});});}async function _0x294e22(_0x42c165,_0x144b2e){const _0x555212=_0x8cd7;if(typeof _0x144b2e!==_0x555212(0xe7))return![];const [_0x3e0866,_0x3a9572]=_0x144b2e[_0x555212(0x2aa)](':');if(!_0x3e0866||!_0x3a9572)return![];const _0x17287b=Buffer[_0x555212(0x690)](_0x3e0866,_0x555212(0x31b)),_0x563093=Buffer[_0x555212(0x690)](_0x3a9572,_0x555212(0x31b));if(_0x563093[_0x555212(0x39d)]!==0x40)return![];return new Promise((_0x118775,_0x5257ce)=>{_0x28cc93['scrypt'](_0x42c165,_0x17287b,0x40,(_0x49ee41,_0x26fb37)=>{const _0x1d8b23=_0x8cd7;if(_0x49ee41)return _0x5257ce(_0x49ee41);_0x118775(_0x28cc93[_0x1d8b23(0xa8)](_0x26fb37,_0x563093));});});}return okdbAuthTokens={'hmac':_0x10557a,'timingSafeEqual':_0x16e986,'parseBearer':_0x32e4a5,'randomToken':_0x492f49,'hashToken':_0x17eca6,'issueToken':_0x3e9cb4,'authenticateToken':_0x12b462,'hashPassword':_0x54062a,'verifyPassword':_0x294e22},okdbAuthTokens;}var okdbLicenseCodec,hasRequiredOkdbLicenseCodec;function requireOkdbLicenseCodec(){const _0x27036c=_0x3d20e4;if(hasRequiredOkdbLicenseCodec)return okdbLicenseCodec;hasRequiredOkdbLicenseCodec=0x1;const _0x10bdc8=require$$0$2,_0xcac285='0123456789ABCDEFGHJKMNPQRSTVWXYZ',_0x5ba0db=new Uint8Array(0x100)['fill'](0xff);for(let _0xca850f=0x0;_0xca850f<_0xcac285[_0x27036c(0x39d)];_0xca850f++){_0x5ba0db[_0xcac285[_0x27036c(0x641)](_0xca850f)]=_0xca850f,_0x5ba0db[_0xcac285[_0x27036c(0x641)](_0xca850f)+0x20]=_0xca850f;}_0x5ba0db['O'[_0x27036c(0x641)](0x0)]=0x0,_0x5ba0db['o'[_0x27036c(0x641)](0x0)]=0x0,_0x5ba0db['I'['charCodeAt'](0x0)]=0x1,_0x5ba0db['i'[_0x27036c(0x641)](0x0)]=0x1,_0x5ba0db['L'['charCodeAt'](0x0)]=0x1,_0x5ba0db['l'[_0x27036c(0x641)](0x0)]=0x1;function _0x2d3bff(_0x10ce1a){const _0xd9bae3=_0x27036c;let _0x47a569=0x0,_0x1c7788=0x0,_0x234445='';for(let _0xdaa13a=0x0;_0xdaa13a<_0x10ce1a[_0xd9bae3(0x39d)];_0xdaa13a++){_0x1c7788=_0x1c7788<<0x8|_0x10ce1a[_0xdaa13a],_0x47a569+=0x8;while(_0x47a569>=0x5){_0x47a569-=0x5,_0x234445+=_0xcac285[_0x1c7788>>>_0x47a569&0x1f];}}return _0x47a569>0x0&&(_0x234445+=_0xcac285[_0x1c7788<<0x5-_0x47a569&0x1f]),_0x234445;}function _0x893c60(_0x35857f){const _0x5c3149=_0x27036c;_0x35857f=_0x35857f[_0x5c3149(0x416)](/-/g,'')[_0x5c3149(0x419)]();let _0x4188dd=0x0,_0x5a8463=0x0;const _0x2fd04d=[];for(let _0x3448c7=0x0;_0x3448c7<_0x35857f['length'];_0x3448c7++){const _0x4e6257=_0x5ba0db[_0x35857f[_0x5c3149(0x641)](_0x3448c7)];if(_0x4e6257===0xff)continue;_0x5a8463=_0x5a8463<<0x5|_0x4e6257,_0x4188dd+=0x5,_0x4188dd>=0x8&&(_0x4188dd-=0x8,_0x2fd04d[_0x5c3149(0x2f9)](_0x5a8463>>>_0x4188dd&0xff));}return Buffer[_0x5c3149(0x690)](_0x2fd04d);}const _0x590562=['sync',_0x27036c(0x6ac),_0x27036c(0x39c),_0x27036c(0x2c1),_0x27036c(0x121),_0x27036c(0x3f8),_0x27036c(0x3a2),'files'],_0x5def1b=0x0,_0x1f469d=0x1,_0xdb160d=0x2,_0x243b05=0x6*0x1e*0x18*0x3c*0x3c*0x3e8;function _0x2e8617({issuedAt:_0x4aff63,expiresAt:_0x350843,licensee:licensee='',features:features={},limits:limits={},licenseType:licenseType=_0x5def1b}){const _0x53863b=_0x27036c,_0x319f6e=Buffer[_0x53863b(0x690)](licensee,'utf8')[_0x53863b(0x13a)](0x0,0x40),_0x244444=0x1+0x1+0x4+0x4+0x1+_0x319f6e[_0x53863b(0x39d)]+0x2+0x10,_0x300ee2=Buffer[_0x53863b(0x547)](_0x244444);let _0x24d415=0x0;_0x300ee2[_0x53863b(0x1aa)](0x1,_0x24d415++),_0x300ee2[_0x53863b(0x1aa)](licenseType,_0x24d415++),_0x300ee2[_0x53863b(0x78)](Math[_0x53863b(0x5e9)](_0x4aff63/0x3e8),_0x24d415),_0x24d415+=0x4,_0x300ee2[_0x53863b(0x78)](Math['floor'](_0x350843/0x3e8),_0x24d415),_0x24d415+=0x4,_0x300ee2[_0x53863b(0x1aa)](_0x319f6e[_0x53863b(0x39d)],_0x24d415++),_0x319f6e[_0x53863b(0x593)](_0x300ee2,_0x24d415),_0x24d415+=_0x319f6e[_0x53863b(0x39d)];let _0x2e3645=0x0;for(let _0x492bf3=0x0;_0x492bf3<_0x590562[_0x53863b(0x39d)];_0x492bf3++){if(features[_0x590562[_0x492bf3]])_0x2e3645|=0x1<<_0x492bf3;}_0x300ee2[_0x53863b(0x3da)](_0x2e3645,_0x24d415),_0x24d415+=0x2;const _0xa01b88=[_0x53863b(0x5cb),_0x53863b(0x490),_0x53863b(0x6fa),'maxWrites'];for(const _0x421cc2 of _0xa01b88){_0x300ee2['writeUInt32BE'](limits[_0x421cc2]||0x0,_0x24d415),_0x24d415+=0x4;}return _0x300ee2;}function _0x1c754d(_0x1173ef){const _0x14ae21=_0x27036c;let _0x5b69ca=0x0;const _0x30d778=_0x1173ef[_0x14ae21(0x3dc)](_0x5b69ca++),_0x1f188b=_0x1173ef[_0x14ae21(0x3dc)](_0x5b69ca++),_0x7b480e=_0x1173ef[_0x14ae21(0x473)](_0x5b69ca);_0x5b69ca+=0x4;const _0x3ddbfd=_0x1173ef['readUInt32BE'](_0x5b69ca);_0x5b69ca+=0x4;const _0x1dd704=_0x1173ef[_0x14ae21(0x3dc)](_0x5b69ca++),_0x5c39bd=_0x1173ef[_0x14ae21(0x13a)](_0x5b69ca,_0x5b69ca+_0x1dd704)[_0x14ae21(0x240)](_0x14ae21(0x320));_0x5b69ca+=_0x1dd704;const _0x577806=_0x1173ef[_0x14ae21(0x765)](_0x5b69ca);_0x5b69ca+=0x2;const _0x4536a8={};for(let _0x5d7349=0x0;_0x5d7349<_0x590562['length'];_0x5d7349++){_0x4536a8[_0x590562[_0x5d7349]]=Boolean(_0x577806&0x1<<_0x5d7349);}const _0x54dc55=[_0x14ae21(0x5cb),_0x14ae21(0x490),_0x14ae21(0x6fa),_0x14ae21(0x425)],_0x2175b5={};for(const _0xa1c40b of _0x54dc55){const _0x1252cb=_0x1173ef[_0x14ae21(0x473)](_0x5b69ca);_0x5b69ca+=0x4,_0x2175b5[_0xa1c40b]=_0x1252cb===0x0?null:_0x1252cb;}return{'v':_0x30d778,'licenseType':_0x1f188b,'issuedAt':_0x7b480e*0x3e8,'expiresAt':_0x3ddbfd*0x3e8,'licensee':_0x5c39bd,'features':_0x4536a8,'limits':_0x2175b5};}function _0x5f360a(_0x4528e7,_0x4f3980){const _0x224e43=_0x27036c,_0x3d68b0=Buffer[_0x224e43(0x123)]([_0x4528e7,_0x4f3980]),_0xba8ea9=_0x2d3bff(_0x3d68b0),_0x1bc2b8=[];for(let _0x452dd8=0x0;_0x452dd8<_0xba8ea9['length'];_0x452dd8+=0x8){_0x1bc2b8[_0x224e43(0x2f9)](_0xba8ea9['slice'](_0x452dd8,_0x452dd8+0x8));}return _0x1bc2b8['join']('-');}function _0x4b57c5(_0x581767){const _0x28a4e3=_0x27036c;if(typeof _0x581767!==_0x28a4e3(0xe7))throw new Error(_0x28a4e3(0x43d));const _0x19dc63=_0x893c60(_0x581767[_0x28a4e3(0x416)](/-/g,''));if(_0x19dc63[_0x28a4e3(0x39d)]<0x41)throw new Error(_0x28a4e3(0x4c1)+_0x19dc63[_0x28a4e3(0x39d)]+_0x28a4e3(0x358));const _0x14e7cc=_0x19dc63[_0x28a4e3(0x13a)](0x0,_0x19dc63[_0x28a4e3(0x39d)]-0x40),_0x512577=_0x19dc63[_0x28a4e3(0x13a)](_0x19dc63[_0x28a4e3(0x39d)]-0x40);let _0x55846d;try{_0x55846d=_0x1c754d(_0x14e7cc);}catch(_0x4dcb43){throw new Error(_0x28a4e3(0x2e9)+_0x4dcb43['message']);}return{'rawBuf':_0x19dc63,'payload':_0x14e7cc,'sig':_0x512577,'decoded':_0x55846d};}function _0x35b83e(_0x42f6f1){const _0x5c64c8=_0x27036c;return _0x10bdc8[_0x5c64c8(0x3cc)](_0x5c64c8(0x647))[_0x5c64c8(0x29f)](_0x42f6f1)[_0x5c64c8(0x674)]()[_0x5c64c8(0x13a)](0x0,0x8);}function _0x26200f(_0x24a220,_0x135730,_0x1c7008){const _0x19206e=_0x27036c,_0x5601e5=_0x19206e(0x219)+_0x1c7008,_0x37dc7c=Buffer[_0x19206e(0x123)]([Buffer[_0x19206e(0x690)](_0x24a220,_0x19206e(0x320)),_0x135730]),_0x1ab931=_0x10bdc8[_0x19206e(0x6d5)](_0x19206e(0x647),_0x5601e5)[_0x19206e(0x29f)](_0x37dc7c)[_0x19206e(0x674)](),_0x3448fd=_0x2d3bff(_0x1ab931[_0x19206e(0x13a)](0x0,0x5));return{'pin':_0x3448fd,'pinHmac':_0x1ab931};}function _0x41bb1e(_0x1a1bba,_0x3f53e5,_0xc6419a){const _0x31e5c4=_0x27036c,_0x29bc1a=Buffer[_0x31e5c4(0x547)](0x4d);let _0x1e5b04=0x0;_0x29bc1a['writeUInt8'](0x1,_0x1e5b04++),_0x1a1bba[_0x31e5c4(0x593)](_0x29bc1a,_0x1e5b04),_0x1e5b04+=0x8,_0x29bc1a[_0x31e5c4(0x78)](_0x3f53e5,_0x1e5b04),_0x1e5b04+=0x4,_0xc6419a[_0x31e5c4(0x593)](_0x29bc1a,_0x1e5b04);const _0x1f5994=_0x2d3bff(_0x29bc1a),_0x3ed0ea=[];for(let _0x23282f=0x0;_0x23282f<_0x1f5994['length'];_0x23282f+=0x6){_0x3ed0ea[_0x31e5c4(0x2f9)](_0x1f5994[_0x31e5c4(0x13a)](_0x23282f,_0x23282f+0x6));}return _0x3ed0ea['join']('-');}function _0x22afe4(_0x1f3115){const _0x527aa0=_0x27036c;if(typeof _0x1f3115!==_0x527aa0(0xe7))throw new Error('decodeActivationToken:\x20input\x20must\x20be\x20a\x20string');const _0x13501c=_0x893c60(_0x1f3115[_0x527aa0(0x416)](/-/g,''));if(_0x13501c[_0x527aa0(0x39d)]!==0x4d)throw new Error(_0x527aa0(0x6ba)+_0x13501c['length']);let _0xf966d8=0x0;const _0x1e8373=_0x13501c[_0x527aa0(0x3dc)](_0xf966d8++),_0x52138b=_0x13501c[_0x527aa0(0x13a)](_0xf966d8,_0xf966d8+0x8);_0xf966d8+=0x8;const _0x305062=_0x13501c['readUInt32BE'](_0xf966d8);_0xf966d8+=0x4;const _0x32e993=_0x13501c['slice'](_0xf966d8);return{'v':_0x1e8373,'licenseHash':_0x52138b,'expiry':_0x305062,'sig':_0x32e993};}const _0x115c36=0x100,_0x18a794=new Set(),_0x6e9e68=new Map();function _0x2326e1(_0x1390e9,_0x5e718e,_0x5424d8){const _0x44d660=_0x27036c;if(typeof _0x5424d8!==_0x44d660(0xe7)||!Buffer[_0x44d660(0x365)](_0x1390e9)||!Buffer['isBuffer'](_0x5e718e))return _0x10bdc8[_0x44d660(0x6de)](null,_0x1390e9,_0x5424d8,_0x5e718e);const _0x4306f7=_0x5424d8+'\x0a'+_0x1390e9['toString']('base64')+'\x0a'+_0x5e718e[_0x44d660(0x240)](_0x44d660(0x154));if(_0x18a794[_0x44d660(0x469)](_0x4306f7))return!![];let _0x233e11=_0x6e9e68[_0x44d660(0x6a)](_0x5424d8);if(!_0x233e11){_0x233e11=_0x10bdc8[_0x44d660(0x9c)](_0x5424d8);if(_0x6e9e68[_0x44d660(0x35f)]>=0x10)_0x6e9e68[_0x44d660(0x209)]();_0x6e9e68[_0x44d660(0x49d)](_0x5424d8,_0x233e11);}const _0x3d2938=_0x10bdc8[_0x44d660(0x6de)](null,_0x1390e9,_0x233e11,_0x5e718e)===!![];if(_0x3d2938){if(_0x18a794[_0x44d660(0x35f)]>=_0x115c36)_0x18a794[_0x44d660(0x209)]();_0x18a794[_0x44d660(0x3e9)](_0x4306f7);}return _0x3d2938;}function _0x5e7167({tokenString:_0x11200a,nodeId:_0xf4f9e0,rawBlobBuf:_0x32ec12,pubKeyPem:_0x2a7d6c,pubFingerprint:_0x557025}){const _0x544e2a=_0x27036c;let _0x551e2f;try{_0x551e2f=_0x22afe4(_0x11200a);}catch(_0x3fd9bd){return{'valid':![],'reason':_0x544e2a(0x621)};}const _0x3ebbe9=_0x35b83e(_0x32ec12);if(!_0x3ebbe9['equals'](_0x551e2f['licenseHash']))return{'valid':![],'reason':_0x544e2a(0x4cc)};const {pinHmac:_0x2f32e9}=_0x26200f(_0xf4f9e0,_0x3ebbe9,_0x557025),_0x4e25fe=Buffer['allocUnsafe'](0x4);_0x4e25fe[_0x544e2a(0x78)](_0x551e2f[_0x544e2a(0x144)],0x0);const _0x294579=Buffer[_0x544e2a(0x123)]([Buffer[_0x544e2a(0x690)]([_0x551e2f['v']]),_0x2f32e9['slice'](0x0,0x5),_0x551e2f[_0x544e2a(0x58c)],_0x4e25fe]);try{const _0x39e279=_0x2326e1(_0x294579,_0x551e2f['sig'],_0x2a7d6c);if(!_0x39e279)return{'valid':![],'reason':_0x544e2a(0x77a)};}catch(_0x1a4da5){return{'valid':![],'reason':_0x544e2a(0x77a)};}if(_0x551e2f[_0x544e2a(0x144)]<Date[_0x544e2a(0x127)]()/0x3e8)return{'valid':![],'reason':_0x544e2a(0x305)};return{'valid':!![],'reason':'ok'};}function _0x174578(_0x10fbb9){const _0x561912=_0x27036c;if(typeof _0x10fbb9!==_0x561912(0xe7))return _0x561912(0x14a);const _0x4076ff=_0x10fbb9['trim']();if(_0x4076ff[_0x561912(0x42e)]('/')||_0x4076ff[_0x561912(0x42e)]('./')||_0x4076ff[_0x561912(0x42e)](_0x561912(0x24c))||/^[A-Za-z]:[\\/]/[_0x561912(0x155)](_0x4076ff))return'path';if(/^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/i[_0x561912(0x155)](_0x4076ff))return'uuid';const _0x2eceae=_0x4076ff[_0x561912(0x416)](/[\s-]+/g,'')['length'];if(_0x2eceae===0x7c)return _0x561912(0x552);if(_0x2eceae>=0x95&&_0x2eceae<=0xfc)return _0x561912(0x712);return _0x561912(0x14a);}return okdbLicenseCodec={'toBase32':_0x2d3bff,'fromBase32':_0x893c60,'encodeLicensePayload':_0x2e8617,'decodeLicensePayload':_0x1c754d,'encodeLicenseBlob':_0x5f360a,'decodeLicenseBlob':_0x4b57c5,'licenseHash':_0x35b83e,'derivePin':_0x26200f,'encodeActivationToken':_0x41bb1e,'decodeActivationToken':_0x22afe4,'verifyActivation':_0x5e7167,'verifySignature':_0x2326e1,'detectInputType':_0x174578,'FEATURE_NAMES':_0x590562,'LICENSE_TYPE_STANDARD':_0x5def1b,'LICENSE_TYPE_OPEN':_0x1f469d,'LICENSE_TYPE_INTERNAL':_0xdb160d,'OPEN_LICENSE_MAX_DURATION_MS':_0x243b05},okdbLicenseCodec;}var okdbEnums,hasRequiredOkdbEnums;function requireOkdbEnums(){const _0x604437=_0x3d20e4;if(hasRequiredOkdbEnums)return okdbEnums;hasRequiredOkdbEnums=0x1;const _0xf8bffa={'PUT':_0x604437(0x463),'REMOVE':_0x604437(0x34e),'INDEX_DROP':'dropIndex','INDEX_REGISTER':_0x604437(0x13e),'INDEX_RESET':_0x604437(0x3c4),'TYPE_REGISTER':_0x604437(0xbc),'TYPE_DROP':_0x604437(0x729),'FTS_REGISTER':_0x604437(0x4d4),'FTS_DROP':_0x604437(0x743),'FTS_RESET':_0x604437(0x11b),'SCHEMA_SET':_0x604437(0x2e1),'SCHEMA_DROP':_0x604437(0x730),'TTL_SET':_0x604437(0x3e0),'TTL_CLEAR':_0x604437(0x624)},_0x2caf0e={'SYSTEM_READY':_0x604437(0x77),'FIELD_RESOLVER_REGISTERED':_0x604437(0x3d1),'SYSTEM_STOPPED':_0x604437(0xf3),'SYSTEM_CLOCK_CHANGE':_0x604437(0x15c),'SYSTEM_POKE':'system:poke','SYSTEM_DRAIN':'system:drain','SYSTEM_TYPE_DROP':_0x604437(0x190),'SYSTEM_PROC':_0x604437(0x6a6),'SYSTEM_BUS_STATE_CHANGE':_0x604437(0x584),'ITEM_CREATE':_0x604437(0x6d6),'ITEM_UPDATE':_0x604437(0x34d),'ITEM_REMOVE':_0x604437(0x5fd),'ITEM_PENDING':_0x604437(0xf8),'INDEX_RESET':'index:reset','INDEX_READY':'index:ready','INDEX_PROGRESS':_0x604437(0x4ed),'VIEW_PROGRESS':_0x604437(0x4ca),'INDEX_DROP':_0x604437(0x460),'INDEX_REGISTERED':'index:registered','FTS_REGISTERED':_0x604437(0x3cd),'FTS_DROP':_0x604437(0x534),'FTS_RESET':_0x604437(0x65b),'SCHEMA_SET':'schema:set','SCHEMA_DROP':_0x604437(0x3c3),'UNIQUE_VIOLATION':_0x604437(0x3e4),'UNIQUE_VIOLATION_RESOLVED':_0x604437(0x5c0),'REF_VIOLATION':_0x604437(0x2b4),'REF_VIOLATION_RESOLVED':'ref:violation_resolved','SYNC_APPLY':'sync:apply','TXN_START':_0x604437(0x740),'TXN_END':'txn:end','TXN_ROLLBACK':'txn:rollback','TYPE_REGISTERED':_0x604437(0x72b),'TYPE_DROP':'type:drop','ENV_OPENED':_0x604437(0x6fc),'ENV_REMOVED':'env:removed','SYSTEM_ENV_RELEASE':_0x604437(0x160),'TTL_EXPIRED':_0x604437(0x33c),'TTL_SET':_0x604437(0x1d4),'TTL_CLEAR':_0x604437(0x68b),'LICENSE_INVALID':'license:invalid','LICENSE_ADDED':_0x604437(0x136),'LICENSE_ACTIVATED':'license:activated','LICENSE_REMOVED':_0x604437(0x515)},_0x4d0f1a={'CREATING':_0x604437(0x344),'RESETTING':'resetting','READY':'ready','DROPPING':_0x604437(0x771),'WAITING':'waiting','ERROR':_0x604437(0x492)},_0x1d601c={'CREATED':'created','STARTING':_0x604437(0x62f),'STARTED':'started','STOPPING':_0x604437(0x147),'STOPPED':_0x604437(0x780)},_0x7d8d0={'CREATING':'creating','READY':_0x604437(0x4c9),'HALTED':_0x604437(0x328),'STOPPED':_0x604437(0x780),'RESETTING':'resetting'},_0x1d945e=Object[_0x604437(0xc0)]({'POKE':_0x604437(0x755),'DRAIN':'bus:drain','TYPE_DROP':_0x604437(0x69d),'PROC':_0x604437(0x143),'ENV_RELEASE':_0x604437(0x70a)});return okdbEnums={'BUS_EVENTS':_0x1d945e,'CHANGE_ACTIONS':_0xf8bffa,'EVENTS':_0x2caf0e,'INDEX_STATE':_0x4d0f1a,'OKDB_STATE':_0x1d601c,'VIEW_STATE':_0x7d8d0},okdbEnums;}var okdbPubkey,hasRequiredOkdbPubkey;function requireOkdbPubkey(){const _0x3000b9=_0x3d20e4;if(hasRequiredOkdbPubkey)return okdbPubkey;hasRequiredOkdbPubkey=0x1;const _0x38c4df=require$$0$1,_0x5c5fb6=require$$1,_0x850354=require$$2$1,_0x28c948=_0x38c4df[_0x3000b9(0x418)](_0x5c5fb6[_0x3000b9(0x10b)](__dirname,_0x3000b9(0x610)),_0x3000b9(0x320))['trim'](),_0x197a3f=_0x850354[_0x3000b9(0x9c)](_0x28c948)[_0x3000b9(0x23a)]({'type':'spki','format':_0x3000b9(0x2a3)}),_0x5098ce=_0x850354['createHash'](_0x3000b9(0x647))[_0x3000b9(0x29f)](_0x197a3f)[_0x3000b9(0x674)](_0x3000b9(0x31b))[_0x3000b9(0x13a)](0x0,0x10);return okdbPubkey={'PUBLIC_KEY_PEM':_0x28c948,'PUB_FINGERPRINT':_0x5098ce},okdbPubkey;}var okdbLicense,hasRequiredOkdbLicense;function requireOkdbLicense(){const _0x278556=_0x3d20e4;if(hasRequiredOkdbLicense)return okdbLicense;hasRequiredOkdbLicense=0x1;const _0x20cad5=require$$2$1,{OKDBError:_0x3457e2}=requireOkdbError(),{EVENTS:_0x21e9c5}=requireOkdbEnums(),_0x540d63=requireOkdbLicenseCodec(),{LICENSE_TYPE_OPEN:_0x31bdd8,LICENSE_TYPE_INTERNAL:_0x42c9d1,OPEN_LICENSE_MAX_DURATION_MS:_0x42139e}=_0x540d63,_0x1c10f2=requireOkdbPubkey(),_0x5e7623={'LICENSED_BUILD':_0x278556(0x727),'PUBLIC_KEY_PEM':_0x1c10f2[_0x278556(0x5e4)],'PUB_FINGERPRINT':_0x1c10f2[_0x278556(0x4e0)],'LICENSE_EXPIRED_ACTION':_0x278556(0x24e)},_0x41ce94=_0x278556(0x506),_0x351771={'features':{'sync':![],'embeddings':!![],'engines':![],'fts':!![],'timeMachine':![],'views':!![],'mcp':!![],'files':!![]},'limits':{'envs':0x5,'typesPerEnv':0xa,'syncPeers':0x0,'maxWrites':0xf4240,'pipelinesPerEnv':0x2},'_isFree':!![]};async function _0x244e5e(_0x1a0065){await _0x1a0065['ensureType'](_0x41ce94);}class _0x3affac{constructor(_0x3ce46a){const _0x444373=_0x278556;this[_0x444373(0x229)]=_0x3ce46a,this[_0x444373(0x65c)]=null;}async['reload'](){const _0x35f11f=_0x278556,_0x1b849f=this['okdb'][_0x35f11f(0x5bc)];if(!_0x1b849f||!_0x1b849f[_0x35f11f(0x753)](_0x41ce94)){this[_0x35f11f(0x65c)]=null;return;}const _0xf4bcaa=this['okdb']['id'];let _0x35d54f=null;for(const {key:_0x11bde1,value:_0x54c6ce}of _0x1b849f[_0x35f11f(0x1c1)](_0x41ce94)){const _0x155c97=this[_0x35f11f(0x6a0)](_0x54c6ce,_0xf4bcaa);_0x155c97==='active'&&!_0x35d54f&&(_0x35d54f={..._0x54c6ce,'id':_0x11bde1,'status':_0x155c97});}this[_0x35f11f(0x65c)]=_0x35d54f;if(this['_active']&&this['_active']['licenseType']===_0x31bdd8){const _0x3dd70e=Math[_0x35f11f(0x6c3)]((this[_0x35f11f(0x65c)][_0x35f11f(0x57a)]-Date['now']())/0x5265c00);this['okdb'][_0x35f11f(0x24e)]?.[_0x35f11f(0x6a7)](_0x35f11f(0x70e)+_0x3dd70e+_0x35f11f(0x54f),{'feature':_0x35f11f(0x39b),'licensee':this[_0x35f11f(0x65c)][_0x35f11f(0x22b)],'expiresAt':new Date(this[_0x35f11f(0x65c)][_0x35f11f(0x57a)])[_0x35f11f(0x261)]()});}this[_0x35f11f(0x65c)]&&this['_active']['licenseType']===_0x42c9d1&&this['okdb'][_0x35f11f(0x24e)]?.['warn'](_0x35f11f(0x36d),{'feature':_0x35f11f(0x39b),'licensee':this['_active'][_0x35f11f(0x22b)]});}[_0x278556(0x6a0)](_0x22a63f,_0x86321e){const _0x505ecb=_0x278556;if(!_0x22a63f[_0x505ecb(0x712)])return'invalid';let _0x741f50;try{_0x741f50=_0x540d63['decodeLicenseBlob'](_0x22a63f['blob']);}catch(_0x507598){return _0x505ecb(0x50f);}try{const _0x188fcc=_0x540d63[_0x505ecb(0x628)](_0x741f50['payload'],_0x741f50[_0x505ecb(0x467)],_0x5e7623[_0x505ecb(0x5e4)]);if(!_0x188fcc)return _0x505ecb(0x50f);}catch(_0x2530f1){return _0x505ecb(0x50f);}if(_0x741f50[_0x505ecb(0x6eb)][_0x505ecb(0x60a)]===_0x42c9d1)return _0x505ecb(0x1b3);if(_0x741f50['decoded']['expiresAt']<=Date[_0x505ecb(0x127)]())return'expired';if(_0x741f50['decoded'][_0x505ecb(0x60a)]===_0x31bdd8)return _0x505ecb(0x1b3);if(!_0x22a63f['activation'])return'pending';const _0x261e4e=_0x540d63[_0x505ecb(0xb2)]({'tokenString':_0x22a63f[_0x505ecb(0x552)],'nodeId':_0x86321e,'rawBlobBuf':_0x741f50[_0x505ecb(0x4a7)],'pubKeyPem':_0x5e7623['PUBLIC_KEY_PEM'],'pubFingerprint':_0x5e7623['PUB_FINGERPRINT']});if(_0x261e4e['reason']==='LICENSE_HASH_MISMATCH'||_0x261e4e[_0x505ecb(0x37c)]===_0x505ecb(0x77a))return _0x505ecb(0x1c8);if(_0x261e4e[_0x505ecb(0x37c)]===_0x505ecb(0x305))return'expired';if(!_0x261e4e[_0x505ecb(0x3b2)])return _0x505ecb(0x1c8);return _0x505ecb(0x1b3);}get[_0x278556(0x1b3)](){const _0xde7b82=_0x278556;return this[_0xde7b82(0x65c)];}get[_0x278556(0x12d)](){const _0x1102e2=_0x278556;return this[_0x1102e2(0x65c)]??_0x351771;}[_0x278556(0x48f)](_0x48e141){const _0x125c71=_0x278556;if(_0x5e7623['LICENSED_BUILD']!=='true')return;const _0x4b5271=this[_0x125c71(0x12d)];if(!_0x4b5271['features']?.[_0x48e141]){const _0xf1b353=_0x4b5271['_isFree']?_0x125c71(0x773)+_0x48e141+_0x125c71(0x2c4)+_0x48e141+'\x22\x20to\x20enable\x20it.':_0x125c71(0xd5)+_0x48e141+'.\x20The\x20active\x20license\x20does\x20not\x20enable\x20\x22'+_0x48e141+'\x22.';throw new _0x3457e2(_0xf1b353,_0x125c71(0x535),{'feature':_0x48e141});}}[_0x278556(0x5c4)](_0xdd38fd){const _0x41274f=_0x278556;if(_0x5e7623[_0x41274f(0x3c5)]!=='true')return!![];return!!this[_0x41274f(0x12d)]['features']?.[_0xdd38fd];}[_0x278556(0x398)](_0x15d6fb){const _0x1349dd=_0x278556;if(_0x5e7623[_0x1349dd(0x3c5)]!=='true')return![];const _0x49a519=this[_0x1349dd(0x12d)][_0x1349dd(0x260)]?.[_0x15d6fb];return!(_0x49a519===null||_0x49a519===undefined||_0x49a519===0x0);}[_0x278556(0x331)](_0xdfad9f,_0x589145){const _0x1648da=_0x278556;if(_0x5e7623[_0x1648da(0x3c5)]!==_0x1648da(0x727))return;const _0x519e3d=this[_0x1648da(0x12d)],_0x9f9dcd=_0x519e3d[_0x1648da(0x260)]?.[_0xdfad9f];if(_0x9f9dcd===null||_0x9f9dcd===undefined||_0x9f9dcd===0x0)return;if(_0x589145>=_0x9f9dcd)throw new _0x3457e2(_0x1648da(0x49e)+_0xdfad9f+'\x20('+_0x589145+'/'+_0x9f9dcd+')',_0x1648da(0xe4),{'limit':_0xdfad9f,'current':_0x589145,'max':_0x9f9dcd});}async[_0x278556(0x267)](_0x3fed34){const _0x316cfd=_0x278556;let _0x384bcb;try{_0x384bcb=_0x540d63[_0x316cfd(0x5a7)](_0x3fed34);}catch(_0x40daa3){throw new _0x3457e2(_0x316cfd(0x6ae)+_0x40daa3['message'],_0x316cfd(0x602));}let _0x4276a0;try{_0x4276a0=_0x540d63[_0x316cfd(0x628)](_0x384bcb['payload'],_0x384bcb[_0x316cfd(0x467)],_0x5e7623['PUBLIC_KEY_PEM']);}catch(_0x450ebe){throw new _0x3457e2(_0x316cfd(0x16e)+_0x450ebe[_0x316cfd(0x5e6)],_0x316cfd(0x602));}if(!_0x4276a0)throw new _0x3457e2(_0x316cfd(0x495)+('Build\x20expects\x20public\x20key\x20fingerprint\x20'+_0x5e7623['PUB_FINGERPRINT']+'.\x20')+_0x316cfd(0x236),_0x316cfd(0x602),{'expectedFingerprint':_0x5e7623['PUB_FINGERPRINT']});if(_0x384bcb[_0x316cfd(0x6eb)][_0x316cfd(0x60a)]===_0x31bdd8){const _0x2a56e1=_0x384bcb[_0x316cfd(0x6eb)][_0x316cfd(0x57a)]-_0x384bcb[_0x316cfd(0x6eb)][_0x316cfd(0x312)];if(_0x2a56e1>_0x42139e)throw new _0x3457e2(_0x316cfd(0x352)+Math[_0x316cfd(0x6c3)](_0x2a56e1/(0x1e*0x5265c00))+_0x316cfd(0x2ff),_0x316cfd(0x602));}const _0x5b7a05=this[_0x316cfd(0x229)]['_systemEnv'];await _0x244e5e(_0x5b7a05);const _0x237b09=_0x540d63[_0x316cfd(0x58c)](_0x384bcb['rawBuf'])[_0x316cfd(0x240)](_0x316cfd(0x31b));for(const {key:_0x4fa353,value:_0x551baa}of _0x5b7a05[_0x316cfd(0x1c1)](_0x41ce94)){if(_0x551baa[_0x316cfd(0x2f8)]===_0x237b09)throw new _0x3457e2(_0x316cfd(0x516),_0x316cfd(0x10e),{'id':_0x4fa353});}const _0x3337fe=_0x20cad5[_0x316cfd(0x3cc)](_0x316cfd(0x647))[_0x316cfd(0x29f)](_0x316cfd(0x4ba))['update'](_0x384bcb[_0x316cfd(0x4a7)])[_0x316cfd(0x674)](_0x316cfd(0x31b)),_0x3fcbf9=_0x3337fe['slice'](0x0,0x8)+'-'+_0x3337fe['slice'](0x8,0xc)+'-5'+_0x3337fe['slice'](0xd,0x10)+'-'+(parseInt(_0x3337fe[0x10],0x10)&0x3|0x8)['toString'](0x10)+_0x3337fe['slice'](0x11,0x14)+'-'+_0x3337fe['slice'](0x14,0x20),_0x2af606={'blob':_0x3fed34,'activation':null,'addedAt':Date[_0x316cfd(0x127)](),'_licenseHash':_0x237b09,'licensee':_0x384bcb['decoded'][_0x316cfd(0x22b)],'expiresAt':_0x384bcb[_0x316cfd(0x6eb)][_0x316cfd(0x57a)],'features':_0x384bcb['decoded'][_0x316cfd(0x5de)],'limits':_0x384bcb['decoded'][_0x316cfd(0x260)],'licenseType':_0x384bcb[_0x316cfd(0x6eb)][_0x316cfd(0x60a)]};return await _0x5b7a05['put'](_0x41ce94,_0x3fcbf9,_0x2af606),{'id':_0x3fcbf9,..._0x2af606};}async[_0x278556(0x76c)](_0x20a121){const _0xd2bf89=_0x278556;let _0x37597d;try{_0x37597d=_0x540d63[_0xd2bf89(0x29d)](_0x20a121);}catch(_0x2c60d5){throw new _0x3457e2('Invalid\x20activation\x20token:\x20'+_0x2c60d5[_0xd2bf89(0x5e6)],_0xd2bf89(0x19b));}const _0x413559=_0x37597d[_0xd2bf89(0x58c)][_0xd2bf89(0x240)]('hex'),_0x4ddbf9=this[_0xd2bf89(0x229)][_0xd2bf89(0x5bc)];if(!_0x4ddbf9||!_0x4ddbf9[_0xd2bf89(0x753)](_0x41ce94))throw new _0x3457e2(_0xd2bf89(0x5b4),_0xd2bf89(0x19b));let _0x4100a2=null,_0x308c4e=null;for(const {key:_0x76980b,value:_0x4f9766}of _0x4ddbf9[_0xd2bf89(0x1c1)](_0x41ce94)){if(_0x4f9766['_licenseHash']===_0x413559){_0x4100a2=_0x76980b,_0x308c4e=_0x4f9766;break;}}if(!_0x4100a2)throw new _0x3457e2(_0xd2bf89(0x5b4),_0xd2bf89(0x19b));const {rawBuf:_0x34c5b7}=_0x540d63[_0xd2bf89(0x5a7)](_0x308c4e[_0xd2bf89(0x712)]),_0x2cff40=_0x540d63[_0xd2bf89(0xb2)]({'tokenString':_0x20a121,'nodeId':this[_0xd2bf89(0x229)]['id'],'rawBlobBuf':_0x34c5b7,'pubKeyPem':_0x5e7623[_0xd2bf89(0x5e4)],'pubFingerprint':_0x5e7623[_0xd2bf89(0x4e0)]});if(!_0x2cff40[_0xd2bf89(0x3b2)])throw new _0x3457e2(_0xd2bf89(0x44a)+_0x2cff40['reason'],_0xd2bf89(0x19b),{'reason':_0x2cff40['reason']});const _0x5b1721={..._0x308c4e,'activation':_0x20a121};return await _0x4ddbf9[_0xd2bf89(0x29f)](_0x41ce94,_0x4100a2,_0x5b1721),{'id':_0x4100a2,..._0x5b1721};}async[_0x278556(0x1d3)](_0x9d81c1){const _0x28e381=_0x278556,_0xedfbcc=this['okdb'][_0x28e381(0x5bc)];if(!_0xedfbcc||!_0xedfbcc[_0x28e381(0x753)](_0x41ce94))return;await _0xedfbcc[_0x28e381(0x34e)](_0x41ce94,_0x9d81c1);}async[_0x278556(0x441)](){const _0x5ee283=_0x278556,_0x4e1c85=this[_0x5ee283(0x229)][_0x5ee283(0x5bc)];if(!_0x4e1c85||!_0x4e1c85[_0x5ee283(0x753)](_0x41ce94))return[];const _0x508b07=this[_0x5ee283(0x229)]['id'],_0x3336cb=[];for(const {key:_0x2d0ed1,value:_0x1999fb}of _0x4e1c85[_0x5ee283(0x1c1)](_0x41ce94)){const _0x3817ef=this[_0x5ee283(0x6a0)](_0x1999fb,_0x508b07);_0x3336cb[_0x5ee283(0x2f9)]({..._0x1999fb,'id':_0x2d0ed1,'status':_0x3817ef});}return _0x3336cb;}[_0x278556(0x6fd)](){const _0x24551e=_0x278556,_0x4ad516=this[_0x24551e(0x229)][_0x24551e(0x5bc)];if(!_0x4ad516||!_0x4ad516[_0x24551e(0x753)](_0x41ce94))return[];const _0x2d0c75=this[_0x24551e(0x229)]['id'],_0x9979e3=[];for(const {key:_0x40cf84,value:_0x4fe90a}of _0x4ad516[_0x24551e(0x1c1)](_0x41ce94)){if(_0x4fe90a[_0x24551e(0x2f8)]){if(_0x4fe90a['licenseType']===_0x31bdd8)_0x9979e3[_0x24551e(0x2f9)]({'licenseId':_0x40cf84,'pin':null});else{const _0x12f8df=Buffer[_0x24551e(0x690)](_0x4fe90a[_0x24551e(0x2f8)],_0x24551e(0x31b)),{pin:_0x420599}=_0x540d63[_0x24551e(0x51b)](_0x2d0c75,_0x12f8df,_0x5e7623[_0x24551e(0x4e0)]);_0x9979e3['push']({'licenseId':_0x40cf84,'pin':_0x420599});}}}return _0x9979e3;}async['recheck'](){const _0x36c7b9=_0x278556,_0x3de1a4=this[_0x36c7b9(0x65c)];await this['reload']();if(this[_0x36c7b9(0x65c)]&&this[_0x36c7b9(0x65c)]['licenseType']===_0x31bdd8){const _0x33a1ee=Math[_0x36c7b9(0x6c3)]((this['_active'][_0x36c7b9(0x57a)]-Date[_0x36c7b9(0x127)]())/0x5265c00);this[_0x36c7b9(0x229)][_0x36c7b9(0x24e)]?.[_0x36c7b9(0x6a7)](_0x36c7b9(0x70e)+_0x33a1ee+'\x20day(s).',{'feature':_0x36c7b9(0x39b),'licensee':this['_active'][_0x36c7b9(0x22b)],'expiresAt':new Date(this[_0x36c7b9(0x65c)][_0x36c7b9(0x57a)])[_0x36c7b9(0x261)]()});}this[_0x36c7b9(0x65c)]&&this[_0x36c7b9(0x65c)][_0x36c7b9(0x60a)]===_0x42c9d1&&this[_0x36c7b9(0x229)][_0x36c7b9(0x24e)]?.[_0x36c7b9(0x6a7)](_0x36c7b9(0x36d),{'feature':_0x36c7b9(0x39b),'licensee':this[_0x36c7b9(0x65c)]['licensee']});if(_0x3de1a4&&!this['_active']){this[_0x36c7b9(0x229)][_0x36c7b9(0x24e)]?.[_0x36c7b9(0x6a7)](_0x36c7b9(0x402),{'feature':_0x36c7b9(0x39b)}),this['okdb'][_0x36c7b9(0x194)]?.['emit'](_0x21e9c5['LICENSE_INVALID'],{'previous':_0x3de1a4});const _0x458608=this[_0x36c7b9(0x229)][_0x36c7b9(0x518)]?.[_0x36c7b9(0x461)]??_0x5e7623[_0x36c7b9(0x15f)];_0x458608===_0x36c7b9(0x119)&&(this[_0x36c7b9(0x229)][_0x36c7b9(0x24e)]?.[_0x36c7b9(0x492)](_0x36c7b9(0x49b),{'feature':_0x36c7b9(0x39b)}),this[_0x36c7b9(0x229)][_0x36c7b9(0x44f)]()[_0x36c7b9(0x618)](()=>{})['finally'](()=>process[_0x36c7b9(0x4e7)](0x1)));}}}return okdbLicense={'LicenseChecker':_0x3affac,'_C':_0x5e7623,'FREE_TIER':_0x351771},okdbLicense;}var okdbShell,hasRequiredOkdbShell;function requireOkdbShell(){const _0x26a86f=_0x3d20e4;if(hasRequiredOkdbShell)return okdbShell;hasRequiredOkdbShell=0x1;const _0x52889e=require$$0$3,_0x22358a=require$$0$1,_0x40451e=require$$0,_0x47bfbe=require$$1,_0x3d347d=_0x47bfbe[_0x26a86f(0x10b)](_0x40451e[_0x26a86f(0x74)](),_0x26a86f(0x40a)),_0x2f1774=0x3e8,_0x4bb7aa={'reset':_0x26a86f(0x2cc),'bold':_0x26a86f(0x5a9),'dim':'\x1b[2m','red':_0x26a86f(0x3c1),'green':_0x26a86f(0x6fb),'yellow':_0x26a86f(0x29e),'blue':_0x26a86f(0x355),'magenta':_0x26a86f(0x487),'cyan':_0x26a86f(0x1cb),'white':_0x26a86f(0x6ed),'gray':_0x26a86f(0x2a7)},_0x6c0532=!process[_0x26a86f(0x11c)]['isTTY']||!!process.env.NO_COLOR,_0x43d25e=(_0x24e8b1,_0x33d2d3)=>_0x6c0532?_0x33d2d3:''+_0x24e8b1+_0x33d2d3+_0x4bb7aa[_0x26a86f(0x478)],_0x568e10={'error':_0x4bb7aa[_0x26a86f(0x356)],'warn':_0x4bb7aa[_0x26a86f(0x1bd)],'info':_0x4bb7aa[_0x26a86f(0x3aa)],'debug':_0x4bb7aa[_0x26a86f(0x701)]},_0xa81c21={'debug':0x0,'info':0x1,'warn':0x2,'error':0x3};function _0x13c223(_0x106402,_0x12ec8f=_0x26a86f(0x2cf)){const _0x5a8df8=_0x26a86f,{level:_0x8d05a6,msg:_0xaee619,meta:_0x1ddc32,context:_0x5eaa88,ts:_0xd2edb2}=_0x106402;if((_0xa81c21[_0x8d05a6]??0x1)<(_0xa81c21[_0x12ec8f]??0x1))return;const _0x51393c=_0x43d25e(_0x4bb7aa[_0x5a8df8(0x701)],new Date(_0xd2edb2)[_0x5a8df8(0x261)]()),_0x16a571=_0x43d25e(_0x568e10[_0x8d05a6]??_0x4bb7aa[_0x5a8df8(0x206)],_0x8d05a6['padEnd'](0x5));let _0x35c020='\x20\x20'+_0x51393c+'\x20'+_0x43d25e(_0x4bb7aa[_0x5a8df8(0x3ef)],_0x16a571)+'\x20'+_0xaee619;if(_0x1ddc32&&Object[_0x5a8df8(0x6d8)](_0x1ddc32)[_0x5a8df8(0x39d)]>0x0){const _0x318da4=Object[_0x5a8df8(0x61d)](_0x1ddc32)[_0x5a8df8(0x757)](([_0x25ea72,_0x12507c])=>_0x25ea72+'='+_0x12507c)[_0x5a8df8(0x10b)]('\x20');_0x35c020+=_0x43d25e(_0x4bb7aa[_0x5a8df8(0x775)],_0x5a8df8(0x759)+_0x318da4+']');}if(_0x5eaa88!==undefined){const _0x2e70e5=typeof _0x5eaa88===_0x5a8df8(0x5d4)?JSON[_0x5a8df8(0x5c1)](_0x5eaa88):String(_0x5eaa88);_0x35c020+=_0x43d25e(_0x4bb7aa[_0x5a8df8(0x775)],'\x20\x20'+_0x2e70e5);}const _0x6a74a6=_0x8d05a6===_0x5a8df8(0x492)||_0x8d05a6==='warn'?process['stderr']['write'][_0x5a8df8(0x245)](process[_0x5a8df8(0x705)]):process[_0x5a8df8(0x11c)]['write'][_0x5a8df8(0x245)](process[_0x5a8df8(0x11c)]);_0x6a74a6(_0x35c020+'\x0a');}function _0x4cd5fd(_0x5bf4c6,_0x10c931){const _0x4021b9=_0x26a86f;if(_0x5bf4c6===0xcc||_0x5bf4c6>=0xc8&&_0x5bf4c6<0x12c&&!_0x10c931){console[_0x4021b9(0x24e)]('\x0a\x20\x20'+_0x43d25e(_0x4bb7aa[_0x4021b9(0x404)],'✓')+'\x0a');return;}if(_0x5bf4c6>=0x190||_0x10c931?.[_0x4021b9(0x492)]){const _0x3e8b67=_0x10c931?.[_0x4021b9(0x492)]??_0x10c931?.[_0x4021b9(0x5e6)]??_0x4021b9(0x1e1)+_0x5bf4c6;console[_0x4021b9(0x24e)](_0x4021b9(0x82)+_0x43d25e(_0x4bb7aa['red'],'✗')+'\x20'+_0x43d25e(_0x4bb7aa['bold']+_0x4bb7aa[_0x4021b9(0x356)],String(_0x5bf4c6))+'\x20\x20'+_0x3e8b67+'\x0a');return;}const _0x19999e=Object[_0x4021b9(0x568)][_0x4021b9(0x1fa)][_0x4021b9(0x3c6)](_0x10c931??{},_0x4021b9(0x5a1))?_0x10c931['result']:_0x10c931,_0x4abb2d=_0x10c931?.['meta'];console[_0x4021b9(0x24e)](''),_0x103608(_0x19999e,'\x20\x20');if(_0x4abb2d?.[_0x4021b9(0x6ad)]!=null||_0x4abb2d?.[_0x4021b9(0x4ac)]!=null){const _0x6aeba5=[];if(_0x4abb2d['count']!=null)_0x6aeba5[_0x4021b9(0x2f9)](_0x4abb2d[_0x4021b9(0x6ad)]+_0x4021b9(0x29a)+(_0x4abb2d[_0x4021b9(0x6ad)]!==0x1?'s':''));if(_0x4abb2d['time']!=null)_0x6aeba5['push'](_0x4abb2d['time']+'ms');console[_0x4021b9(0x24e)](_0x4021b9(0x82)+_0x43d25e(_0x4bb7aa[_0x4021b9(0x775)],_0x6aeba5[_0x4021b9(0x10b)](_0x4021b9(0x586))));}console[_0x4021b9(0x24e)]('');}function _0x103608(_0x1c612a,_0x29d03c=''){const _0x114162=_0x26a86f;if(_0x1c612a===null||_0x1c612a===undefined){console['log'](_0x29d03c+_0x43d25e(_0x4bb7aa[_0x114162(0x775)],_0x114162(0x427)));return;}if(Array[_0x114162(0x339)](_0x1c612a)){if(_0x1c612a[_0x114162(0x39d)]===0x0){console[_0x114162(0x24e)](_0x29d03c+_0x43d25e(_0x4bb7aa[_0x114162(0x775)],'(empty)'));return;}if(_0x1c612a[_0x114162(0x6be)](_0x14fbf3=>_0x14fbf3&&typeof _0x14fbf3===_0x114162(0x5d4)&&_0x114162(0x466)in _0x14fbf3&&_0x114162(0x101)in _0x14fbf3)){_0x16235f(_0x1c612a,_0x29d03c);return;}if(_0x1c612a[_0x114162(0x6be)](_0x507d0a=>_0x507d0a&&typeof _0x507d0a===_0x114162(0x5d4)&&_0x114162(0x66f)in _0x507d0a&&'count'in _0x507d0a)){_0x181782(_0x1c612a,_0x29d03c);return;}if(_0x1c612a[_0x114162(0x6be)](_0x5ce377=>typeof _0x5ce377!==_0x114162(0x5d4)||_0x5ce377===null)){_0x1c612a[_0x114162(0x2e2)]((_0x436d9a,_0xa64d11)=>console[_0x114162(0x24e)](_0x29d03c+_0x43d25e(_0x4bb7aa[_0x114162(0x701)],_0xa64d11+0x1+'.')+'\x20'+_0x43d25e(_0x4bb7aa[_0x114162(0x206)],String(_0x436d9a))));return;}_0x1c612a['forEach']((_0x2010f4,_0x246601)=>{const _0x228d8b=_0x114162;console['log'](_0x29d03c+_0x43d25e(_0x4bb7aa[_0x228d8b(0x775)],'['+_0x246601+']'));if(typeof _0x2010f4===_0x228d8b(0x5d4)&&_0x2010f4!==null)_0x550618(_0x2010f4,_0x29d03c+'\x20\x20');else console['log'](_0x29d03c+'\x20\x20'+String(_0x2010f4));});return;}if(typeof _0x1c612a===_0x114162(0x5d4)){if('key'in _0x1c612a&&_0x114162(0x101)in _0x1c612a&&Object[_0x114162(0x6d8)](_0x1c612a)[_0x114162(0x39d)]<=0x3){console['log'](_0x29d03c+_0x43d25e(_0x4bb7aa[_0x114162(0x3ef)]+_0x4bb7aa[_0x114162(0x3aa)],String(_0x1c612a[_0x114162(0x466)])));const _0x40aeeb=_0x1c612a[_0x114162(0x101)];if(_0x40aeeb&&typeof _0x40aeeb===_0x114162(0x5d4))_0x550618(_0x40aeeb,_0x29d03c);else console['log'](_0x29d03c+_0x43d25e(_0x4bb7aa['white'],String(_0x40aeeb)));return;}_0x550618(_0x1c612a,_0x29d03c);return;}console[_0x114162(0x24e)](_0x29d03c+_0x43d25e(_0x4bb7aa['white'],String(_0x1c612a)));}function _0x550618(_0x5c0463,_0x48fe78=''){const _0x554339=_0x26a86f,_0x320872=Object[_0x554339(0x61d)](_0x5c0463);if(_0x320872['length']===0x0){console[_0x554339(0x24e)](_0x48fe78+_0x43d25e(_0x4bb7aa[_0x554339(0x775)],'{}'));return;}const _0x115cfd=Math['min'](0x1c,Math[_0x554339(0x68c)](..._0x320872[_0x554339(0x757)](([_0xe69e4f])=>_0xe69e4f[_0x554339(0x39d)])));for(const [_0x528107,_0x2889cc]of _0x320872){const _0x117d81=_0x43d25e(_0x4bb7aa[_0x554339(0x3aa)],_0x528107['padEnd'](_0x115cfd));if(_0x2889cc===null||_0x2889cc===undefined)console[_0x554339(0x24e)](_0x48fe78+_0x117d81+'\x20\x20'+_0x43d25e(_0x4bb7aa[_0x554339(0x775)],_0x554339(0x359)));else{if(typeof _0x2889cc==='object'){const _0x2be1c2=JSON[_0x554339(0x5c1)](_0x2889cc);_0x2be1c2[_0x554339(0x39d)]<=0x50?console[_0x554339(0x24e)](_0x48fe78+_0x117d81+'\x20\x20'+_0x43d25e(_0x4bb7aa[_0x554339(0x775)],_0x2be1c2)):(console[_0x554339(0x24e)](_0x48fe78+_0x117d81),_0x103608(_0x2889cc,_0x48fe78+'\x20\x20'));}else{const _0x304a8f=typeof _0x2889cc==='boolean'?_0x43d25e(_0x2889cc?_0x4bb7aa[_0x554339(0x404)]:_0x4bb7aa[_0x554339(0x1bd)],String(_0x2889cc)):typeof _0x2889cc===_0x554339(0x6af)?_0x43d25e(_0x4bb7aa[_0x554339(0x1ba)],String(_0x2889cc)):_0x43d25e(_0x4bb7aa['white'],String(_0x2889cc));console['log'](_0x48fe78+_0x117d81+'\x20\x20'+_0x304a8f);}}}}function _0x16235f(_0x442cf5,_0x1c28e3=''){const _0x5d12d3=_0x26a86f,_0x2cd3ab=Math['min'](0x20,Math[_0x5d12d3(0x68c)](..._0x442cf5['map'](_0x45651d=>String(_0x45651d[_0x5d12d3(0x466)])[_0x5d12d3(0x39d)])));for(const {key:_0x15fa81,value:_0x5dedee,score:_0x411207,clock:_0x1fdba9}of _0x442cf5){const _0x2e1780=_0x43d25e(_0x4bb7aa[_0x5d12d3(0x3ef)]+_0x4bb7aa[_0x5d12d3(0x3aa)],String(_0x15fa81)[_0x5d12d3(0x485)](_0x2cd3ab)),_0x997229=_0x5dedee==null?_0x43d25e(_0x4bb7aa[_0x5d12d3(0x775)],_0x5d12d3(0x359)):typeof _0x5dedee===_0x5d12d3(0x5d4)?_0x43d25e(_0x4bb7aa['dim'],JSON[_0x5d12d3(0x5c1)](_0x5dedee)):_0x43d25e(_0x4bb7aa['white'],String(_0x5dedee)),_0x5f36d0=_0x411207!=null?_0x43d25e(_0x4bb7aa[_0x5d12d3(0x701)],'\x20\x20score:'+_0x411207[_0x5d12d3(0x72c)](0x4)):'',_0x38977f=_0x1fdba9!=null?_0x43d25e(_0x4bb7aa['gray'],'\x20\x20@'+_0x1fdba9):'';console[_0x5d12d3(0x24e)](_0x1c28e3+_0x2e1780+'\x20\x20'+_0x997229+_0x5f36d0+_0x38977f);}}function _0x181782(_0x1c66bc,_0x368e1a=''){const _0x532408=_0x26a86f,_0x2f44fd=Math[_0x532408(0x268)](0x20,Math[_0x532408(0x68c)](..._0x1c66bc[_0x532408(0x757)](_0x114f2c=>_0x114f2c[_0x532408(0x66f)]['length'])));for(const {type:_0x17f297,count:_0x309fb7,fields:_0x56cfb1}of _0x1c66bc){if(_0x17f297[_0x532408(0x42e)]('~'))continue;const _0x40b758=_0x43d25e(_0x4bb7aa[_0x532408(0x3ef)]+_0x4bb7aa[_0x532408(0x3aa)],_0x17f297['padEnd'](_0x2f44fd)),_0x4f8755=_0x43d25e(_0x4bb7aa[_0x532408(0x1ba)],String(_0x309fb7)[_0x532408(0x6b6)](0x6))+_0x43d25e(_0x4bb7aa[_0x532408(0x775)],_0x532408(0x749)),_0x1e28e2=_0x56cfb1&&Object['keys'](_0x56cfb1)[_0x532408(0x39d)]?_0x43d25e(_0x4bb7aa[_0x532408(0x775)],_0x532408(0x205)+Object['keys'](_0x56cfb1)[_0x532408(0x13a)](0x0,0x6)[_0x532408(0x10b)](',\x20')+(Object[_0x532408(0x6d8)](_0x56cfb1)['length']>0x6?'…':'')):'';console['log'](_0x368e1a+_0x40b758+'\x20\x20'+_0x4f8755+_0x1e28e2);}}const _0x4eb1c6=[_0x26a86f(0x429),_0x26a86f(0x2f4),'queue/',_0x26a86f(0x19e),_0x26a86f(0x4f9),_0x26a86f(0x2b8)];function _0x42538c(_0x157cb3,_0x35a59b){const _0x3cb546=_0x26a86f;if(_0x157cb3[_0x3cb546(0x42e)]('/api/'))return _0x157cb3;if(_0x157cb3['startsWith']('/'))return _0x3cb546(0x126)+_0x157cb3;if(_0x157cb3[_0x3cb546(0x42e)](_0x3cb546(0x7c)))return'/api/'+_0x157cb3;const _0x29a108=_0x4eb1c6['some'](_0x420a28=>_0x157cb3===_0x420a28[_0x3cb546(0x416)](/\/$/,'')||_0x157cb3[_0x3cb546(0x42e)](_0x420a28));return _0x29a108?'/api/env/'+_0x35a59b+'/'+_0x157cb3:_0x3cb546(0x6b3)+_0x157cb3;}function _0x3e2f5d(_0x309e52){const _0x38fb78=_0x26a86f,_0xdc34d8={},_0x3967a5=[];let _0x33ac95=0x0;while(_0x33ac95<_0x309e52[_0x38fb78(0x39d)]){if((_0x309e52[_0x33ac95]===_0x38fb78(0x488)||_0x309e52[_0x33ac95]==='-e')&&_0x309e52[_0x33ac95+0x1]&&!_0x309e52[_0x33ac95+0x1]['startsWith']('-'))_0xdc34d8[_0x38fb78(0x124)]=_0x309e52[++_0x33ac95];else _0x309e52[_0x33ac95]==='--help'||_0x309e52[_0x33ac95]==='-h'?_0xdc34d8['help']=!![]:_0x3967a5[_0x38fb78(0x2f9)](_0x309e52[_0x33ac95]);_0x33ac95++;}return{'flags':_0xdc34d8,'rest':_0x3967a5};}const _0x1c2a7c={'system':_0x26a86f(0x68f),'envs':'Environments','types':_0x26a86f(0x56f),'data':_0x26a86f(0xd9),'indexes':_0x26a86f(0x399),'fts':'Full-text\x20search','sync':'Sync','queue':_0x26a86f(0x12c),'files':_0x26a86f(0x6a8),'embeddings':'Embeddings','engines':_0x26a86f(0x582),'admin':_0x26a86f(0x770),'event':_0x26a86f(0x2a5),'processor':_0x26a86f(0x697)},_0xd6c566=[_0x26a86f(0x619),_0x26a86f(0x5cb),_0x26a86f(0x429),_0x26a86f(0x32e),_0x26a86f(0x21f),_0x26a86f(0x2c1),'sync','queue',_0x26a86f(0x4e4),'embeddings',_0x26a86f(0x39c),_0x26a86f(0x270)];function _0x3cd9e5(_0x4924a4){const _0x7cf014=_0x26a86f;return _0x4924a4[_0x7cf014(0x416)](/^\/api/,'')['replace'](/^\[\/env\/:env=[^\]]*\]/,_0x7cf014(0x614))[_0x7cf014(0x416)](/^\/env\/:env/,_0x7cf014(0x3db))['replace'](/^\//,'');}function _0x4fad5c(_0x5c3963,_0x25ae69=''){const _0x581451=_0x26a86f,_0x112a58=_0x5c3963[_0x581451(0x91)][_0x581451(0x562)]()['filter'](_0x3f5530=>!_0x3f5530[_0x581451(0xc9)]?.[_0x581451(0x4f4)]),_0x5c1962=_0x25ae69?_0x112a58[_0x581451(0x293)](_0x5e1f8f=>_0x5e1f8f[_0x581451(0x4c5)][_0x581451(0x8d)]()[_0x581451(0x8f)](_0x25ae69[_0x581451(0x8d)]())||(_0x9eddb5(_0x5e1f8f)??'')[_0x581451(0x8d)]()['includes'](_0x25ae69[_0x581451(0x8d)]())||_0x2c3099(_0x5e1f8f)[_0x581451(0x35c)](_0x327ab8=>_0x327ab8[_0x581451(0x8d)]()[_0x581451(0x8f)](_0x25ae69[_0x581451(0x8d)]()))):_0x112a58;if(!_0x5c1962[_0x581451(0x39d)]){console['log'](_0x43d25e(_0x4bb7aa['yellow'],_0x581451(0x381)+_0x25ae69+'\x22\x0a'));return;}const _0x56b367=new Map();for(const _0x45370e of _0x5c1962){const _0x38743c=_0x2c3099(_0x45370e)[0x0]??_0x581451(0x3b0);if(!_0x56b367[_0x581451(0x469)](_0x38743c))_0x56b367[_0x581451(0x49d)](_0x38743c,[]);_0x56b367['get'](_0x38743c)[_0x581451(0x2f9)](_0x45370e);}const _0x29b80b=[..._0xd6c566[_0x581451(0x293)](_0x417e5c=>_0x56b367[_0x581451(0x469)](_0x417e5c)),...[..._0x56b367[_0x581451(0x6d8)]()][_0x581451(0x293)](_0x4cc975=>!_0xd6c566['includes'](_0x4cc975))];console[_0x581451(0x24e)]('');for(const _0x198b91 of _0x29b80b){const _0x1f09d5=_0x56b367[_0x581451(0x6a)](_0x198b91);if(!_0x1f09d5?.[_0x581451(0x39d)])continue;console['log'](_0x43d25e(_0x4bb7aa['bold'],'\x20\x20'+(_0x1c2a7c[_0x198b91]??_0x198b91)));for(const _0x373940 of _0x1f09d5){const _0xa8ea74=_0x43d25e(_0x4bb7aa[_0x581451(0x1ba)],_0x373940[_0x581451(0xdf)][_0x581451(0x485)](0x7)),_0xc73376=_0x43d25e(_0x4bb7aa[_0x581451(0x3aa)],_0x3cd9e5(_0x373940[_0x581451(0x4c5)])),_0x444ffb=_0x9eddb5(_0x373940)?_0x43d25e(_0x4bb7aa[_0x581451(0x775)],'\x20\x20'+_0x9eddb5(_0x373940)):'',_0x579de7=_0x373940[_0x581451(0x396)]?.['id']?_0x43d25e(_0x4bb7aa[_0x581451(0x701)],_0x581451(0x759)+_0x373940[_0x581451(0x396)]['id']+']'):'';console[_0x581451(0x24e)]('\x20\x20\x20\x20'+_0xa8ea74+'\x20'+_0xc73376+_0x444ffb+_0x579de7);}console['log']('');}}function _0x56c906(_0x40f2f9,_0xf282f4){const _0x910539=_0x26a86f,_0x4d766d=_0xf282f4[_0x910539(0x416)](/^\/api(\/env\/[^/]+)?\//,'')[_0x910539(0x2aa)]('/')[0x0],_0x1b5ac2=_0x40f2f9['http'][_0x910539(0x562)]()[_0x910539(0x293)](_0x48aec2=>_0x48aec2[_0x910539(0x4c5)][_0x910539(0x8d)]()[_0x910539(0x8f)](_0x4d766d[_0x910539(0x8d)]()));if(!_0x1b5ac2[_0x910539(0x39d)]){console[_0x910539(0x24e)](_0x43d25e(_0x4bb7aa[_0x910539(0x1bd)],_0x910539(0x675)+_0xf282f4+'\x0a'));return;}console['log']('');for(const _0x2450b3 of _0x1b5ac2[_0x910539(0x13a)](0x0,0xc)){for(const _0x5a4cb2 of _0x20d4ae(_0x2450b3)){console[_0x910539(0x24e)](_0x5a4cb2);}console[_0x910539(0x24e)]('');}}function _0x9eddb5(_0xbffe57){const _0x22cda0=_0x26a86f;return _0xbffe57['operation']?.[_0x22cda0(0x4d1)]??_0xbffe57['meta']?.[_0x22cda0(0x4d1)]??'';}function _0x1a5fcc(_0xf7db69){const _0x4a5496=_0x26a86f;return _0xf7db69[_0x4a5496(0x396)]?.['description']??_0xf7db69['meta']?.[_0x4a5496(0x13c)]??'';}function _0x2c3099(_0x40ed8e){const _0x420615=_0x26a86f;return _0x40ed8e[_0x420615(0x396)]?.[_0x420615(0x5bd)]?.[_0x420615(0x39d)]?_0x40ed8e['operation'][_0x420615(0x5bd)]:_0x40ed8e[_0x420615(0xc9)]?.['tags']??[];}function _0x20d4ae(_0x183c02){const _0x37a42e=_0x26a86f,_0x4cbfcd=[];_0x4cbfcd[_0x37a42e(0x2f9)]('\x20\x20'+_0x43d25e(_0x4bb7aa[_0x37a42e(0x3ef)]+_0x4bb7aa[_0x37a42e(0x1ba)],_0x183c02[_0x37a42e(0xdf)][_0x37a42e(0x485)](0x7))+'\x20'+_0x43d25e(_0x4bb7aa[_0x37a42e(0x3ef)]+_0x4bb7aa[_0x37a42e(0x3aa)],_0x183c02['path']));_0x183c02[_0x37a42e(0x396)]?.['id']&&_0x4cbfcd[_0x37a42e(0x2f9)](_0x37a42e(0x90)+_0x43d25e(_0x4bb7aa[_0x37a42e(0x701)],_0x37a42e(0x607)+_0x183c02[_0x37a42e(0x396)]['id']));_0x9eddb5(_0x183c02)&&_0x4cbfcd[_0x37a42e(0x2f9)](_0x37a42e(0x90)+_0x43d25e(_0x4bb7aa[_0x37a42e(0x206)],_0x9eddb5(_0x183c02)));_0x1a5fcc(_0x183c02)&&_0x4cbfcd[_0x37a42e(0x2f9)](_0x37a42e(0x90)+_0x43d25e(_0x4bb7aa[_0x37a42e(0x775)],_0x1a5fcc(_0x183c02)));_0x2c3099(_0x183c02)[_0x37a42e(0x39d)]&&_0x4cbfcd[_0x37a42e(0x2f9)]('\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20'+_0x43d25e(_0x4bb7aa['gray'],'tags:\x20'+_0x2c3099(_0x183c02)[_0x37a42e(0x10b)](',\x20')));_0x183c02['operation']?.['safety']?.[_0x37a42e(0x2af)]&&_0x4cbfcd[_0x37a42e(0x2f9)](_0x37a42e(0x90)+_0x43d25e(_0x4bb7aa[_0x37a42e(0x701)],'access:\x20'+_0x183c02[_0x37a42e(0x396)][_0x37a42e(0x1d1)][_0x37a42e(0x2af)]));_0x183c02[_0x37a42e(0x396)]?.[_0x37a42e(0x91)]?.[_0x37a42e(0x601)]&&_0x183c02[_0x37a42e(0x396)][_0x37a42e(0x91)][_0x37a42e(0x601)]!==_0x37a42e(0x63e)&&_0x4cbfcd[_0x37a42e(0x2f9)]('\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20'+_0x43d25e(_0x4bb7aa[_0x37a42e(0x701)],_0x37a42e(0x530)+_0x183c02[_0x37a42e(0x396)][_0x37a42e(0x91)][_0x37a42e(0x601)]));if(_0x183c02['operation']?.[_0x37a42e(0x2f6)]){const _0x5442a2=Object[_0x37a42e(0x6d8)](_0x183c02[_0x37a42e(0x396)][_0x37a42e(0x2f6)][_0x37a42e(0x9d)]||{});if(_0x5442a2[_0x37a42e(0x39d)])_0x4cbfcd[_0x37a42e(0x2f9)](_0x37a42e(0x90)+_0x43d25e(_0x4bb7aa[_0x37a42e(0x701)],'input:\x20'+_0x5442a2[_0x37a42e(0x10b)](',\x20')));}return _0x183c02[_0x37a42e(0xc9)]?.['body']&&_0x4cbfcd[_0x37a42e(0x2f9)](_0x37a42e(0x90)+_0x43d25e(_0x4bb7aa[_0x37a42e(0x701)],'body:\x20'+JSON[_0x37a42e(0x5c1)](_0x183c02['meta'][_0x37a42e(0x4fc)]))),_0x4cbfcd;}async function _0x32005a(_0x2cef0f,_0x52e256,_0x576906,_0x157818=null){const _0x3a7a4b=_0x26a86f,_0x1d6e8d=_0x576906[_0x3a7a4b(0x380)]('?'),_0x1a3629=_0x1d6e8d>=0x0?_0x576906[_0x3a7a4b(0x13a)](0x0,_0x1d6e8d):_0x576906,_0x2599bc=_0x1d6e8d>=0x0?_0x576906[_0x3a7a4b(0x13a)](_0x1d6e8d+0x1):'',_0x1608b8=Object[_0x3a7a4b(0x66e)](new URLSearchParams(_0x2599bc)[_0x3a7a4b(0x61d)]());return _0x2cef0f['http']['handle'](_0x52e256,_0x1a3629,{'body':_0x157818,'query':_0x1608b8,'headers':{'content-type':_0x3a7a4b(0x754)}},{'internal':!![]});}function _0x158ef8(_0x1fb89f){const _0x360cc5=_0x26a86f;if(!_0x1fb89f)return null;const _0x89c3b6=_0x1fb89f[_0x360cc5(0x471)]();if(!_0x89c3b6)return null;try{return JSON[_0x360cc5(0xc3)](_0x89c3b6);}catch{}try{return JSON[_0x360cc5(0xc3)](_0x52a5a1(_0x89c3b6));}catch(_0x33123a){throw new SyntaxError(_0x33123a[_0x360cc5(0x5e6)],{'cause':_0x33123a});}}function _0x52a5a1(_0xe896ee){const _0x162db7=_0x26a86f;let _0x232c96='',_0x3135a0=0x0;while(_0x3135a0<_0xe896ee[_0x162db7(0x39d)]){const _0x3e9a8c=_0xe896ee[_0x3135a0];if(_0x3e9a8c==='\x22'){_0x232c96+='\x22',_0x3135a0++;while(_0x3135a0<_0xe896ee['length']&&_0xe896ee[_0x3135a0]!=='\x22'){if(_0xe896ee[_0x3135a0]==='\x5c'){_0x232c96+=_0xe896ee[_0x3135a0++];if(_0x3135a0<_0xe896ee['length'])_0x232c96+=_0xe896ee[_0x3135a0++];}else _0x232c96+=_0xe896ee[_0x3135a0++];}_0x232c96+='\x22';if(_0x3135a0<_0xe896ee[_0x162db7(0x39d)])_0x3135a0++;continue;}if(_0x3e9a8c==='\x27'){_0x232c96+='\x22',_0x3135a0++;while(_0x3135a0<_0xe896ee[_0x162db7(0x39d)]&&_0xe896ee[_0x3135a0]!=='\x27'){if(_0xe896ee[_0x3135a0]==='\x5c'&&_0xe896ee[_0x3135a0+0x1]==='\x27')_0x232c96+='\x27',_0x3135a0+=0x2;else _0xe896ee[_0x3135a0]==='\x22'?(_0x232c96+='\x5c\x22',_0x3135a0++):_0x232c96+=_0xe896ee[_0x3135a0++];}_0x232c96+='\x22';if(_0x3135a0<_0xe896ee[_0x162db7(0x39d)])_0x3135a0++;continue;}if('{}[]:,\x0a\x0d\x09\x20'[_0x162db7(0x8f)](_0x3e9a8c)){_0x232c96+=_0x3e9a8c,_0x3135a0++;continue;}let _0x1f0005='';while(_0x3135a0<_0xe896ee[_0x162db7(0x39d)]&&!'{}[]:,\x27\x22'['includes'](_0xe896ee[_0x3135a0])&&_0xe896ee[_0x3135a0]!=='\x20'&&_0xe896ee[_0x3135a0]!=='\x09'&&_0xe896ee[_0x3135a0]!=='\x0a'&&_0xe896ee[_0x3135a0]!=='\x0d'){_0x1f0005+=_0xe896ee[_0x3135a0++];}let _0x2ba7af=_0x3135a0;while(_0x2ba7af<_0xe896ee[_0x162db7(0x39d)]&&(_0xe896ee[_0x2ba7af]==='\x20'||_0xe896ee[_0x2ba7af]==='\x09'))_0x2ba7af++;if(_0xe896ee[_0x2ba7af]===':')_0x232c96+='\x22'+_0x1f0005+'\x22';else _0x1f0005===_0x162db7(0x727)||_0x1f0005===_0x162db7(0x779)||_0x1f0005==='null'||/^-?\d+(\.\d+)?([eE][+-]?\d+)?$/[_0x162db7(0x155)](_0x1f0005)?_0x232c96+=_0x1f0005:_0x232c96+='\x22'+_0x1f0005+'\x22';}return _0x232c96[_0x162db7(0x416)](/,(\s*[}\]])/g,'$1');}function _0x8fe228(_0x234d3e){const _0x205fcd=_0x26a86f,_0x481c30=[];let _0x2d1d77=0x0;while(_0x2d1d77<_0x234d3e['length']){while(_0x2d1d77<_0x234d3e[_0x205fcd(0x39d)]&&(_0x234d3e[_0x2d1d77]==='\x20'||_0x234d3e[_0x2d1d77]==='\x09'))_0x2d1d77++;if(_0x2d1d77>=_0x234d3e[_0x205fcd(0x39d)])break;const _0x2e862b=_0x234d3e[_0x2d1d77];if(_0x2e862b==='{'||_0x2e862b==='['){const _0x7988bf=_0x2e862b==='{'?'}':']',_0x589745=_0x2d1d77++;let _0x32bec4=0x1,_0x4c81b3=![],_0x1f356b='';while(_0x2d1d77<_0x234d3e[_0x205fcd(0x39d)]&&_0x32bec4>0x0){const _0x17036f=_0x234d3e[_0x2d1d77];if(_0x4c81b3){if(_0x17036f==='\x5c')_0x2d1d77++;else{if(_0x17036f===_0x1f356b)_0x4c81b3=![];}}else{if(_0x17036f==='\x22'||_0x17036f==='\x27')_0x4c81b3=!![],_0x1f356b=_0x17036f;else{if(_0x17036f===_0x2e862b)_0x32bec4++;else{if(_0x17036f===_0x7988bf)_0x32bec4--;}}}_0x2d1d77++;}_0x481c30[_0x205fcd(0x2f9)](_0x234d3e[_0x205fcd(0x13a)](_0x589745,_0x2d1d77));continue;}if(_0x2e862b==='\x22'||_0x2e862b==='\x27'){const _0x271549=_0x2e862b;_0x2d1d77++;let _0x5e9ad5='';while(_0x2d1d77<_0x234d3e['length']&&_0x234d3e[_0x2d1d77]!==_0x271549){if(_0x234d3e[_0x2d1d77]==='\x5c'&&_0x2d1d77+0x1<_0x234d3e[_0x205fcd(0x39d)])_0x2d1d77++,_0x5e9ad5+=_0x234d3e[_0x2d1d77++];else _0x5e9ad5+=_0x234d3e[_0x2d1d77++];}if(_0x2d1d77<_0x234d3e[_0x205fcd(0x39d)])_0x2d1d77++;_0x481c30[_0x205fcd(0x2f9)](_0x5e9ad5);continue;}let _0x3d96e4='';while(_0x2d1d77<_0x234d3e[_0x205fcd(0x39d)]&&_0x234d3e[_0x2d1d77]!=='\x20'&&_0x234d3e[_0x2d1d77]!=='\x09'&&_0x234d3e[_0x2d1d77]!=='{'&&_0x234d3e[_0x2d1d77]!=='['){_0x3d96e4+=_0x234d3e[_0x2d1d77++];}if(_0x3d96e4)_0x481c30[_0x205fcd(0x2f9)](_0x3d96e4);}return _0x481c30;}function _0x1c3ad0(_0x7df442,_0x4d1d48){const _0x1e1de1=_0x26a86f,_0x3f588d=[..._0x7df442[_0x1e1de1(0x64c)]['keys']()][_0x1e1de1(0x293)](_0x4e451f=>!_0x4e451f[_0x1e1de1(0x42e)]('~'));console['log'](['',_0x43d25e(_0x4bb7aa[_0x1e1de1(0x3ef)]+_0x4bb7aa[_0x1e1de1(0x3aa)],'\x20\x20╔═══════════════════════════╗'),_0x43d25e(_0x4bb7aa[_0x1e1de1(0x3ef)]+_0x4bb7aa[_0x1e1de1(0x3aa)],_0x1e1de1(0x26c))+_0x43d25e(_0x4bb7aa[_0x1e1de1(0x3ef)],_0x1e1de1(0x93))+_0x43d25e(_0x4bb7aa[_0x1e1de1(0x3ef)]+_0x4bb7aa[_0x1e1de1(0x3aa)],'║'),_0x43d25e(_0x4bb7aa[_0x1e1de1(0x3ef)]+_0x4bb7aa[_0x1e1de1(0x3aa)],'\x20\x20╚═══════════════════════════╝'),'','\x20\x20'+_0x43d25e(_0x4bb7aa[_0x1e1de1(0x404)],'✓')+'\x20'+_0x43d25e(_0x4bb7aa[_0x1e1de1(0x3ef)],_0x1e1de1(0x33d))+_0x1e1de1(0x59b)+_0x4d1d48[_0x1e1de1(0x255)],..._0x4d1d48[_0x1e1de1(0x616)]>0x1?['\x20\x20'+_0x43d25e(_0x4bb7aa[_0x1e1de1(0x404)],'✓')+'\x20'+_0x43d25e(_0x4bb7aa[_0x1e1de1(0x3ef)],_0x1e1de1(0x2bd))+'\x20'+_0x4d1d48['clusterWorkers']+_0x1e1de1(0x335)+_0x43d25e(_0x4bb7aa['gray'],_0x1e1de1(0xef))]:[],'\x20\x20'+_0x43d25e(_0x4bb7aa[_0x1e1de1(0x404)],'✓')+'\x20'+_0x43d25e(_0x4bb7aa[_0x1e1de1(0x3ef)],'api')+_0x1e1de1(0x5ea)+_0x4d1d48[_0x1e1de1(0x255)]+_0x1e1de1(0x126),'\x20\x20'+_0x43d25e(_0x4bb7aa['green'],'✓')+'\x20'+_0x43d25e(_0x4bb7aa[_0x1e1de1(0x3ef)],_0x1e1de1(0x4c5))+_0x1e1de1(0x75b)+_0x4d1d48[_0x1e1de1(0x361)],'\x20\x20'+_0x43d25e(_0x4bb7aa[_0x1e1de1(0x404)],'✓')+'\x20'+_0x43d25e(_0x4bb7aa[_0x1e1de1(0x3ef)],'id')+_0x1e1de1(0x15b)+_0x43d25e(_0x4bb7aa['gray'],_0x7df442['id']),'\x20\x20'+_0x43d25e(_0x4bb7aa[_0x1e1de1(0x404)],'✓')+'\x20'+_0x43d25e(_0x4bb7aa[_0x1e1de1(0x3ef)],'envs')+_0x1e1de1(0x75b)+_0x3f588d[_0x1e1de1(0x757)](_0xe199eb=>_0x43d25e(_0x4bb7aa[_0x1e1de1(0x3aa)],_0xe199eb))[_0x1e1de1(0x10b)]('\x20\x20'),..._0x4d1d48[_0x1e1de1(0x116)]?[]:['\x20\x20'+_0x43d25e(_0x4bb7aa[_0x1e1de1(0x404)],'✓')+'\x20'+_0x43d25e(_0x4bb7aa['bold'],'admin')+_0x1e1de1(0x40d)+_0x4d1d48[_0x1e1de1(0x255)]+_0x1e1de1(0xc8)],'',_0x43d25e(_0x4bb7aa[_0x1e1de1(0x775)],'\x20\x20Type\x20'+_0x43d25e(_0x4bb7aa[_0x1e1de1(0x3ef)],_0x1e1de1(0x353))+_0x1e1de1(0x246)+_0x43d25e(_0x4bb7aa['bold'],_0x1e1de1(0x249))+_0x1e1de1(0xfc)+_0x43d25e(_0x4bb7aa[_0x1e1de1(0x3ef)],_0x1e1de1(0x4e7))+_0x1e1de1(0x2f2)),''][_0x1e1de1(0x10b)]('\x0a'));}function _0x101f46(_0x5588e5){const _0x46495e=_0x26a86f;console[_0x46495e(0x24e)]('\x0a'+_0x43d25e(_0x4bb7aa[_0x46495e(0x3ef)],'\x20\x20Path\x20access')+'\x20\x20'+_0x43d25e(_0x4bb7aa[_0x46495e(0x775)],'—\x20/api/\x20is\x20auto-prefixed,\x20env\x20is\x20auto-injected')+_0x46495e(0x4d8)+_0x43d25e(_0x4bb7aa[_0x46495e(0x3aa)],_0x46495e(0x108))+_0x46495e(0x750)+_0x43d25e(_0x4bb7aa[_0x46495e(0x3aa)],'<path>')+'\x20'+_0x43d25e(_0x4bb7aa['yellow'],'<json-body>')+_0x46495e(0x665)+_0x43d25e(_0x4bb7aa['cyan'],_0x46495e(0x654))+'\x20'+_0x43d25e(_0x4bb7aa['cyan'],_0x46495e(0x108))+'\x20'+_0x43d25e(_0x4bb7aa['yellow'],_0x46495e(0x28e))+_0x46495e(0x3b9)+_0x43d25e(_0x4bb7aa[_0x46495e(0x775)],_0x46495e(0x50e))+_0x46495e(0x2fd)+_0x43d25e(_0x4bb7aa['gray'],_0x46495e(0x2cf))+_0x46495e(0x440)+_0x43d25e(_0x4bb7aa['gray'],_0x46495e(0x5cb))+_0x46495e(0x68d)+_0x43d25e(_0x4bb7aa[_0x46495e(0x701)],_0x46495e(0x429))+_0x46495e(0x3f0)+_0x5588e5[_0x46495e(0x124)]+_0x46495e(0x503)+_0x43d25e(_0x4bb7aa[_0x46495e(0x701)],_0x46495e(0x413))+'\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20→\x20GET\x20/api/env/'+_0x5588e5['env']+_0x46495e(0x66d)+_0x43d25e(_0x4bb7aa[_0x46495e(0x701)],_0x46495e(0x325))+_0x46495e(0x531)+_0x5588e5[_0x46495e(0x124)]+_0x46495e(0x130)+_0x43d25e(_0x4bb7aa[_0x46495e(0x701)],_0x46495e(0x247))+'\x20→\x20POST\x20/api/env/'+_0x5588e5[_0x46495e(0x124)]+_0x46495e(0x73c)+_0x43d25e(_0x4bb7aa[_0x46495e(0x701)],'PUT\x20type/users/item/x\x20{\x22n\x22:1}')+_0x46495e(0x2fd)+_0x43d25e(_0x4bb7aa[_0x46495e(0x701)],_0x46495e(0x284))+_0x46495e(0x2fd)+_0x43d25e(_0x4bb7aa[_0x46495e(0x701)],'env/staging/info')+_0x46495e(0x76b)+_0x43d25e(_0x4bb7aa[_0x46495e(0x3ef)],'\x20\x20Flags')+'\x20\x20'+_0x43d25e(_0x4bb7aa[_0x46495e(0x775)],'(on\x20any\x20path\x20command)')+_0x46495e(0x4d8)+_0x43d25e(_0x4bb7aa[_0x46495e(0x3aa)],'--env\x20<name>')+'\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20override\x20active\x20environment\x20for\x20this\x20call\x0a\x20\x20'+_0x43d25e(_0x4bb7aa[_0x46495e(0x3aa)],_0x46495e(0x14b))+_0x46495e(0x1c3)+_0x43d25e(_0x4bb7aa[_0x46495e(0x775)],_0x46495e(0x50e))+_0x46495e(0x2fd)+_0x43d25e(_0x4bb7aa[_0x46495e(0x701)],_0x46495e(0x5ca))+_0x46495e(0x2fd)+_0x43d25e(_0x4bb7aa[_0x46495e(0x701)],_0x46495e(0x5f8))+_0x46495e(0x2fd)+_0x43d25e(_0x4bb7aa[_0x46495e(0x701)],_0x46495e(0x392))+'\x0a\x0a'+_0x43d25e(_0x4bb7aa[_0x46495e(0x3ef)],_0x46495e(0x522))+'\x0a\x0a\x20\x20'+_0x43d25e(_0x4bb7aa[_0x46495e(0x3aa)],_0x46495e(0x1b6))+_0x46495e(0x3d9)+_0x43d25e(_0x4bb7aa[_0x46495e(0x3aa)],'env')+_0x46495e(0x231)+_0x43d25e(_0x4bb7aa['cyan'],_0x46495e(0x249))+'\x20'+_0x43d25e(_0x4bb7aa[_0x46495e(0x775)],_0x46495e(0x1d6))+_0x46495e(0x66c)+_0x43d25e(_0x4bb7aa[_0x46495e(0x3aa)],'logs')+'\x20'+_0x43d25e(_0x4bb7aa[_0x46495e(0x775)],_0x46495e(0x348))+_0x46495e(0x77e)+_0x43d25e(_0x4bb7aa[_0x46495e(0x3aa)],_0x46495e(0x1fd))+_0x46495e(0x5ae)+_0x43d25e(_0x4bb7aa[_0x46495e(0x3aa)],'help')+_0x46495e(0x599)+_0x43d25e(_0x4bb7aa[_0x46495e(0x3aa)],_0x46495e(0x4e7))+'\x20'+_0x43d25e(_0x4bb7aa[_0x46495e(0x775)],_0x46495e(0x48c))+_0x46495e(0x453));}let _0x204f39=![];async function _0x3950bd(_0x272dda,_0xe2cc4d=0x0,_0x36116a=null){const _0x1913b9=_0x26a86f;_0x204f39&&(process['stderr'][_0x1913b9(0xb6)](_0x43d25e(_0x4bb7aa['red'],_0x1913b9(0x2fa))),process[_0x1913b9(0x4e7)](0x82));_0x204f39=!![],process[_0x1913b9(0x11c)][_0x1913b9(0xb6)]('\x0a'),process['stderr'][_0x1913b9(0xb6)](_0x43d25e(_0x4bb7aa[_0x1913b9(0x1bd)],'\x20\x20[okdb]\x20'+(_0x36116a?_0x1913b9(0x4ce)+_0x36116a+',\x20':'')+'shutting\x20down…\x0a'));const _0x5f5a36=setTimeout(()=>{const _0x4e79ec=_0x1913b9;process[_0x4e79ec(0x705)][_0x4e79ec(0xb6)](_0x43d25e(_0x4bb7aa['red'],_0x4e79ec(0x526))),process['exit'](0x1);},0x1388);try{await _0x272dda[_0x1913b9(0x44f)]();}catch(_0x34cb41){console[_0x1913b9(0x492)](_0x43d25e(_0x4bb7aa['red'],'\x20\x20'+_0x34cb41[_0x1913b9(0x5e6)]));}clearTimeout(_0x5f5a36),process[_0x1913b9(0x705)][_0x1913b9(0xb6)](_0x43d25e(_0x4bb7aa[_0x1913b9(0x775)],'\x20\x20[okdb]\x20closed\x20cleanly\x0a')),process['exit'](_0xe2cc4d);}function _0x53c343(_0x15690f){const _0x3dcdea=_0x26a86f,_0x4a5d7e=_0x15690f[_0x3dcdea(0x124)]!==_0x3dcdea(0x3e8)?_0x43d25e(_0x4bb7aa[_0x3dcdea(0x1bd)],'['+_0x15690f[_0x3dcdea(0x124)]+']'):'';return _0x43d25e(_0x4bb7aa['bold']+_0x4bb7aa[_0x3dcdea(0x3aa)],'okdb')+_0x4a5d7e+_0x43d25e(_0x4bb7aa[_0x3dcdea(0x701)],'>\x20');}const _0x42e204=new Set([_0x26a86f(0x248),_0x26a86f(0x2ed),_0x26a86f(0x6ff),_0x26a86f(0x689),_0x26a86f(0x3ed)]);async function _0x295ed4(_0x209328,_0x142524,_0x578afa,_0x2589a6,_0x6a8e88,_0x4a7979){const _0x3a1d3b=_0x26a86f;_0x209328=_0x209328['trim']();if(!_0x209328||_0x209328[_0x3a1d3b(0x42e)]('#'))return;const _0xd10ef=_0x8fe228(_0x209328),{flags:_0x1c9c46,rest:_0x43001d}=_0x3e2f5d(_0xd10ef);if(!_0x43001d[_0x3a1d3b(0x39d)])return;const _0x2eec3e=_0x43001d[0x0],_0x5c7f5f=_0x2eec3e[_0x3a1d3b(0x419)]();if(_0x5c7f5f==='HELP'){if(_0x43001d[0x1])_0x56c906(_0x142524,_0x42538c(_0x43001d[0x1],_0x1c9c46[_0x3a1d3b(0x124)]??_0x6a8e88['env']));else _0x101f46(_0x6a8e88);return;}if(_0x5c7f5f===_0x3a1d3b(0x16d)){const _0x29255c=_0x43001d[0x1];if(!_0x29255c){console[_0x3a1d3b(0x24e)](_0x43d25e(_0x4bb7aa[_0x3a1d3b(0x356)],_0x3a1d3b(0x25f)));return;}try{_0x142524[_0x3a1d3b(0x124)](_0x29255c),_0x6a8e88['env']=_0x29255c,_0x4a7979?.[_0x3a1d3b(0x13b)](_0x53c343(_0x6a8e88)),console[_0x3a1d3b(0x24e)](_0x3a1d3b(0x82)+_0x43d25e(_0x4bb7aa['green'],'✓')+_0x3a1d3b(0x3e3)+_0x43d25e(_0x4bb7aa[_0x3a1d3b(0x3ef)]+_0x4bb7aa[_0x3a1d3b(0x3aa)],_0x29255c)+'\x0a');}catch{console[_0x3a1d3b(0x24e)](_0x3a1d3b(0x82)+_0x43d25e(_0x4bb7aa[_0x3a1d3b(0x356)],'✗')+_0x3a1d3b(0x5a4)+_0x43d25e(_0x4bb7aa[_0x3a1d3b(0x3ef)],_0x29255c)+_0x3a1d3b(0x1e9)+_0x43d25e(_0x4bb7aa[_0x3a1d3b(0x775)],_0x3a1d3b(0x292)));}return;}if(_0x5c7f5f===_0x3a1d3b(0x5b1)){const _0xbcb40b=[..._0x142524[_0x3a1d3b(0x64c)][_0x3a1d3b(0x6d8)]()]['filter'](_0x2af308=>!_0x2af308[_0x3a1d3b(0x42e)]('~'));console[_0x3a1d3b(0x24e)]('');for(const _0x292eba of _0xbcb40b){const _0x5bbb8b=_0x292eba===_0x6a8e88[_0x3a1d3b(0x124)];console['log']('\x20\x20'+(_0x5bbb8b?_0x43d25e(_0x4bb7aa[_0x3a1d3b(0x404)],'●'):_0x43d25e(_0x4bb7aa[_0x3a1d3b(0x775)],'○'))+'\x20\x20'+(_0x5bbb8b?_0x43d25e(_0x4bb7aa[_0x3a1d3b(0x3ef)]+_0x4bb7aa[_0x3a1d3b(0x3aa)],_0x292eba):_0x43d25e(_0x4bb7aa['dim'],_0x292eba)));}console[_0x3a1d3b(0x24e)]('\x0a\x20\x20'+_0x43d25e(_0x4bb7aa['dim'],_0x3a1d3b(0x46b))+'\x20'+_0x43d25e(_0x4bb7aa[_0x3a1d3b(0x3aa)],_0x6a8e88['env'])),console[_0x3a1d3b(0x24e)]('');return;}if(_0x5c7f5f===_0x3a1d3b(0x4b3)){const _0x120783=[..._0x142524[_0x3a1d3b(0x64c)][_0x3a1d3b(0x591)]()][_0x3a1d3b(0x293)](_0x22b5cf=>!_0x22b5cf[_0x3a1d3b(0x707)][_0x3a1d3b(0x42e)]('~'));console[_0x3a1d3b(0x24e)]('');const _0x5589c4=Math[_0x3a1d3b(0x68c)](..._0x120783[_0x3a1d3b(0x757)](_0x490e47=>_0x490e47[_0x3a1d3b(0x707)]['length']));for(const _0x59ec4b of _0x120783){const _0xdf617a=_0x59ec4b[_0x3a1d3b(0x707)]===_0x6a8e88[_0x3a1d3b(0x124)],_0x276209=_0xdf617a?_0x43d25e(_0x4bb7aa[_0x3a1d3b(0x404)],'●'):_0x43d25e(_0x4bb7aa[_0x3a1d3b(0x775)],'○'),_0x2a7603=_0xdf617a?_0x43d25e(_0x4bb7aa[_0x3a1d3b(0x3ef)]+_0x4bb7aa[_0x3a1d3b(0x3aa)],_0x59ec4b['name'][_0x3a1d3b(0x485)](_0x5589c4)):_0x43d25e(_0x4bb7aa[_0x3a1d3b(0x775)],_0x59ec4b[_0x3a1d3b(0x707)][_0x3a1d3b(0x485)](_0x5589c4)),_0x25e400=[..._0x59ec4b[_0x3a1d3b(0x105)][_0x3a1d3b(0x6d8)]()][_0x3a1d3b(0x293)](_0x273bf8=>!_0x273bf8[_0x3a1d3b(0x42e)]('~')),_0x5e0b49=_0x25e400[_0x3a1d3b(0x39d)]?_0x43d25e(_0x4bb7aa[_0x3a1d3b(0x775)],_0x25e400[_0x3a1d3b(0x13a)](0x0,0x5)[_0x3a1d3b(0x10b)](',\x20')+(_0x25e400['length']>0x5?'\x20\x20+'+(_0x25e400[_0x3a1d3b(0x39d)]-0x5)+'\x20more':'')):_0x43d25e(_0x4bb7aa[_0x3a1d3b(0x775)],'(no\x20types)');console[_0x3a1d3b(0x24e)]('\x20\x20'+_0x276209+'\x20\x20'+_0x2a7603+'\x20\x20'+_0x5e0b49);}console[_0x3a1d3b(0x24e)]('');return;}if(_0x5c7f5f===_0x3a1d3b(0x110)){const _0x5d7852=_0x1c9c46[_0x3a1d3b(0x124)]??_0x43001d[0x1]??_0x6a8e88['env'];try{const _0x248530=_0x142524[_0x3a1d3b(0x124)](_0x5d7852),_0x396d3d=[..._0x248530[_0x3a1d3b(0x105)][_0x3a1d3b(0x6d8)]()][_0x3a1d3b(0x293)](_0x3f3b45=>!_0x3f3b45[_0x3a1d3b(0x42e)]('~'))['sort']();console[_0x3a1d3b(0x24e)](_0x3a1d3b(0x82)+_0x43d25e(_0x4bb7aa[_0x3a1d3b(0x775)],_0x396d3d[_0x3a1d3b(0x39d)]+'\x20type'+(_0x396d3d[_0x3a1d3b(0x39d)]!==0x1?'s':'')+_0x3a1d3b(0x644)+_0x5d7852));for(const _0x4cd742 of _0x396d3d){const _0x1a279f=_0x248530['typeSubDbs']['get'](_0x4cd742),_0x9cd513=_0x1a279f?.[_0x3a1d3b(0x32e)]?.['getCount']?.()??0x0,_0x206a21=_0x43d25e(_0x4bb7aa[_0x3a1d3b(0x3ef)]+_0x4bb7aa[_0x3a1d3b(0x3aa)],_0x4cd742['padEnd'](0x1c));console[_0x3a1d3b(0x24e)](_0x3a1d3b(0x75b)+_0x206a21+'\x20\x20'+_0x43d25e(_0x4bb7aa[_0x3a1d3b(0x1ba)],String(_0x9cd513)[_0x3a1d3b(0x6b6)](0x6))+'\x20'+_0x43d25e(_0x4bb7aa[_0x3a1d3b(0x775)],_0x3a1d3b(0x3ee)));}console['log']('');}catch(_0x2413ad){console[_0x3a1d3b(0x492)](_0x43d25e(_0x4bb7aa[_0x3a1d3b(0x356)],'\x0a\x20\x20'+_0x2413ad[_0x3a1d3b(0x5e6)]+'\x0a'));}return;}if(_0x5c7f5f===_0x3a1d3b(0x6fe)){_0x4fad5c(_0x142524,_0x43001d[_0x3a1d3b(0x13a)](0x1)['join']('\x20'));return;}if(_0x5c7f5f==='LOGS'){const _0x521e04=(_0x43001d[0x1]??'')[_0x3a1d3b(0x8d)]();if(!_0x521e04||_0x521e04==='on')_0x2589a6[_0x3a1d3b(0x1f9)]=!![],_0x2589a6[_0x3a1d3b(0x67c)]=_0x3a1d3b(0x2cf),console[_0x3a1d3b(0x24e)](_0x3a1d3b(0x82)+_0x43d25e(_0x4bb7aa['green'],'✓')+_0x3a1d3b(0x4c2)+_0x43d25e(_0x4bb7aa['dim'],_0x3a1d3b(0x1af))+'\x0a');else{if(_0x521e04===_0x3a1d3b(0x567))_0x2589a6[_0x3a1d3b(0x1f9)]=![],console[_0x3a1d3b(0x24e)](_0x3a1d3b(0x82)+_0x43d25e(_0x4bb7aa[_0x3a1d3b(0x1bd)],'○')+'\x20logs\x20off\x0a');else _0xa81c21[_0x521e04]!==undefined?(_0x2589a6['enabled']=!![],_0x2589a6['level']=_0x521e04,console[_0x3a1d3b(0x24e)](_0x3a1d3b(0x82)+_0x43d25e(_0x4bb7aa[_0x3a1d3b(0x404)],'✓')+_0x3a1d3b(0x6a2)+_0x43d25e(_0x4bb7aa['bold'],_0x521e04)+'\x0a')):console['error'](_0x43d25e(_0x4bb7aa[_0x3a1d3b(0x356)],_0x3a1d3b(0x5a8)));}return;}if(_0x5c7f5f==='EXIT'||_0x5c7f5f===_0x3a1d3b(0x61c)){await _0x3950bd(_0x142524,0x0);return;}if(_0x5c7f5f==='OPEN'){const _0x4be530='http://localhost:'+_0x578afa[_0x3a1d3b(0x255)]+'/admin/index.html',_0x3d4d89=process['platform']===_0x3a1d3b(0x73f)?_0x3a1d3b(0x74a)+_0x4be530:process[_0x3a1d3b(0x379)]===_0x3a1d3b(0x551)?'open\x20'+_0x4be530:_0x3a1d3b(0x46f)+_0x4be530;require$$4[_0x3a1d3b(0xb1)](_0x3d4d89),console[_0x3a1d3b(0x24e)]('\x0a\x20\x20'+_0x43d25e(_0x4bb7aa[_0x3a1d3b(0x404)],'✓')+_0x3a1d3b(0x2d2)+_0x43d25e(_0x4bb7aa['cyan'],_0x4be530)+'\x0a');return;}let _0x576672,_0x427108,_0x1de7d4;if(_0x42e204['has'](_0x5c7f5f)){_0x576672=_0x5c7f5f,_0x427108=_0x43001d[0x1],_0x1de7d4=_0x43001d[_0x3a1d3b(0x13a)](0x2);if(!_0x427108){console[_0x3a1d3b(0x492)](_0x43d25e(_0x4bb7aa[_0x3a1d3b(0x356)],_0x3a1d3b(0xf5)+_0x2eec3e+_0x3a1d3b(0x2c3)));return;}}else _0x576672=null,_0x427108=_0x43001d[0x0],_0x1de7d4=_0x43001d[_0x3a1d3b(0x13a)](0x1);const _0x3accbd=_0x1c9c46[_0x3a1d3b(0x124)]??_0x6a8e88[_0x3a1d3b(0x124)],_0x417ee0=_0x42538c(_0x427108,_0x3accbd);if(_0x1c9c46[_0x3a1d3b(0x353)]){_0x56c906(_0x142524,_0x417ee0);return;}let _0xd7fc8f=null;if(_0x1de7d4[_0x3a1d3b(0x39d)]){const _0x2357e4=_0x1de7d4[_0x3a1d3b(0x10b)]('\x20');try{_0xd7fc8f=_0x158ef8(_0x2357e4);}catch(_0x5ec380){console[_0x3a1d3b(0x492)](_0x43d25e(_0x4bb7aa['red'],_0x3a1d3b(0x1ea)+_0x2357e4+_0x3a1d3b(0x82)+_0x43d25e(_0x4bb7aa[_0x3a1d3b(0x775)],_0x5ec380[_0x3a1d3b(0x5e6)])+'\x0a'));return;}}if(!_0x576672)_0x576672=_0xd7fc8f!==null?_0x3a1d3b(0x2ed):_0x3a1d3b(0x248);try{const _0x3a8e81=await _0x32005a(_0x142524,_0x576672,_0x417ee0,_0xd7fc8f);_0x4cd5fd(_0x3a8e81[_0x3a1d3b(0x170)],_0x3a8e81[_0x3a1d3b(0x4fc)]);}catch(_0x24384d){console[_0x3a1d3b(0x492)](_0x3a1d3b(0x82)+_0x43d25e(_0x4bb7aa[_0x3a1d3b(0x356)],'✗')+'\x20'+_0x24384d[_0x3a1d3b(0x5e6)]+'\x0a');}}class _0x188a15{constructor(){const _0x1bdbe0=_0x26a86f;this['children']=new Map(),this[_0x1bdbe0(0x77f)]=null,this[_0x1bdbe0(0x250)]=![];}}function _0x2ff1a9(_0x1908df){const _0x45b474=_0x26a86f,_0x4e2aff=new _0x188a15();for(const _0x363551 of _0x1908df){if(_0x363551[_0x45b474(0xc9)]?.[_0x45b474(0x4f4)])continue;const _0x577b99=_0x363551[_0x45b474(0x4c5)][_0x45b474(0x416)](/^\/api/,'')[_0x45b474(0x416)](/^\[\/env\/:env=[^\]]*\]/,'')[_0x45b474(0x416)](/^\//,'');if(!_0x577b99)continue;let _0x4cc5fc=_0x4e2aff;for(const _0x1c374f of _0x577b99[_0x45b474(0x2aa)]('/')['filter'](Boolean)){if(_0x1c374f['startsWith'](':')){const _0x35c4d4=_0x1c374f[_0x45b474(0x13a)](0x1);if(!_0x4cc5fc['dynamic'])_0x4cc5fc[_0x45b474(0x77f)]={'param':_0x35c4d4,'node':new _0x188a15()};_0x4cc5fc=_0x4cc5fc['dynamic'][_0x45b474(0x68e)];}else{if(!_0x4cc5fc[_0x45b474(0x5ff)]['has'](_0x1c374f))_0x4cc5fc[_0x45b474(0x5ff)][_0x45b474(0x49d)](_0x1c374f,new _0x188a15());_0x4cc5fc=_0x4cc5fc[_0x45b474(0x5ff)]['get'](_0x1c374f);}}_0x4cc5fc['terminal']=!![];}return _0x4e2aff;}const _0x267af9=new Map();function _0x24db31(_0x22bbc9,_0x46a443,_0x562763){const _0x51def0=_0x26a86f,_0x49e7a5=_0x267af9['get'](_0x22bbc9);if(_0x49e7a5&&_0x49e7a5[_0x51def0(0x69e)]>Date['now']())return _0x49e7a5[_0x51def0(0x20d)];const _0x40e850=_0x562763();return _0x267af9['set'](_0x22bbc9,{'val':_0x40e850,'exp':Date[_0x51def0(0x127)]()+_0x46a443}),_0x40e850;}function _0x32b0d7(_0x5d8e3b,_0x22d2a6,_0x103af3,_0x32df9b){const _0x56ec6f=_0x26a86f,_0x28efdb=_0x22d2a6[_0x56ec6f(0x124)]??_0x32df9b[_0x56ec6f(0x124)];switch(_0x5d8e3b){case _0x56ec6f(0x124):return[..._0x103af3[_0x56ec6f(0x64c)][_0x56ec6f(0x6d8)]()][_0x56ec6f(0x293)](_0x1844c6=>!_0x1844c6['startsWith']('~'));case'type':return _0x24db31(_0x56ec6f(0x642)+_0x28efdb,0x7d0,()=>{const _0x1484c4=_0x56ec6f;try{return[..._0x103af3[_0x1484c4(0x124)](_0x28efdb)[_0x1484c4(0x105)][_0x1484c4(0x6d8)]()][_0x1484c4(0x293)](_0x4d2948=>!_0x4d2948[_0x1484c4(0x42e)]('~'));}catch{return[];}});case'key':if(!_0x22d2a6[_0x56ec6f(0x66f)])return[];return _0x24db31('keys:'+_0x28efdb+':'+_0x22d2a6['type'],0x5dc,()=>{const _0x284aa4=_0x56ec6f;try{const _0x42d984=_0x103af3[_0x284aa4(0x124)](_0x28efdb)[_0x284aa4(0x105)][_0x284aa4(0x6a)](_0x22d2a6[_0x284aa4(0x66f)]);if(!_0x42d984?.[_0x284aa4(0x32e)])return[];const _0x518d4b=[];for(const {key:_0x4aa6c5}of _0x42d984['data'][_0x284aa4(0x1c1)]({'limit':0x32})){_0x518d4b[_0x284aa4(0x2f9)](String(_0x4aa6c5));if(_0x518d4b['length']>=0x32)break;}return _0x518d4b;}catch{return[];}});case'index':if(!_0x22d2a6[_0x56ec6f(0x66f)])return[];return _0x24db31('idx:'+_0x28efdb+':'+_0x22d2a6[_0x56ec6f(0x66f)],0x7d0,()=>{const _0x2f3580=_0x56ec6f;try{const _0x3e62cf=_0x103af3[_0x2f3580(0x124)](_0x28efdb)[_0x2f3580(0x105)]['get'](_0x22d2a6[_0x2f3580(0x66f)]);return _0x3e62cf?[..._0x3e62cf[_0x2f3580(0x149)]?.[_0x2f3580(0x6d8)]()??[]]:[];}catch{return[];}});case _0x56ec6f(0x1a6):if(!_0x22d2a6[_0x56ec6f(0x66f)])return[];return _0x24db31(_0x56ec6f(0x1f3)+_0x28efdb+':'+_0x22d2a6[_0x56ec6f(0x66f)],0x7d0,()=>{const _0x45243b=_0x56ec6f;try{return _0x103af3[_0x45243b(0x2c1)]?.['list']?.(_0x22d2a6[_0x45243b(0x66f)],_0x103af3['env'](_0x28efdb))?.[_0x45243b(0x757)](_0x454a1b=>_0x454a1b['name'])??[];}catch{return[];}});default:return[];}}function _0xdf744a(_0x1de48e,_0x6c6d46,_0x1876ea,_0x4574be){const _0xf13f83=_0x26a86f,_0x31ff4b=_0x1de48e[_0xf13f83(0x113)]('/'),_0x3cb57f=_0x1de48e[_0xf13f83(0x2aa)]('/'),_0x2a68bd=_0x31ff4b?_0x3cb57f['slice'](0x0,-0x1):_0x3cb57f['slice'](0x0,-0x1),_0x58c5e8=_0x31ff4b?'':_0x3cb57f[_0x3cb57f[_0xf13f83(0x39d)]-0x1];let _0x154a17=_0x6c6d46;const _0x4cebbc={};for(const _0x7f8cde of _0x2a68bd){if(!_0x7f8cde)continue;if(_0x154a17[_0xf13f83(0x5ff)][_0xf13f83(0x469)](_0x7f8cde))_0x154a17=_0x154a17[_0xf13f83(0x5ff)]['get'](_0x7f8cde);else{if(_0x154a17[_0xf13f83(0x77f)])_0x4cebbc[_0x154a17[_0xf13f83(0x77f)][_0xf13f83(0x32f)]]=_0x7f8cde,_0x154a17=_0x154a17[_0xf13f83(0x77f)][_0xf13f83(0x68e)];else return[];}}const _0xa154ec=_0x2a68bd[_0xf13f83(0x293)](Boolean),_0x3a9f5a=_0xa154ec[_0xf13f83(0x39d)]?_0xa154ec[_0xf13f83(0x10b)]('/')+'/':'',_0x465051=[];for(const [_0x4cb457]of _0x154a17[_0xf13f83(0x5ff)]){if(_0x4cb457[_0xf13f83(0x42e)](_0x58c5e8))_0x465051[_0xf13f83(0x2f9)](_0x3a9f5a+_0x4cb457);}if(_0x154a17[_0xf13f83(0x77f)])for(const _0x224ce8 of _0x32b0d7(_0x154a17[_0xf13f83(0x77f)][_0xf13f83(0x32f)],_0x4cebbc,_0x1876ea,_0x4574be)){if(String(_0x224ce8)[_0xf13f83(0x42e)](_0x58c5e8))_0x465051[_0xf13f83(0x2f9)](_0x3a9f5a+_0x224ce8);}return _0x465051[_0xf13f83(0x13a)](0x0,0x64);}const _0x58f62c=[_0x26a86f(0x353),_0x26a86f(0x724),_0x26a86f(0x124),_0x26a86f(0x5cb),_0x26a86f(0x429),_0x26a86f(0x249),_0x26a86f(0x5fc),_0x26a86f(0x1fd),'exit',_0x26a86f(0x28d)];function _0x527660(_0x1ab475,_0x19920a,_0x2ea2c9){return function _0x127833(_0x2ca06c){const _0x4c3f47=_0x8cd7;try{const _0x2861cc=_0x2ca06c[_0x4c3f47(0x41c)](/\s[{[]/),_0x13bf75=_0x2861cc>=0x0?_0x2ca06c[_0x4c3f47(0x13a)](0x0,_0x2861cc):_0x2ca06c,_0x2dd505=_0x13bf75[_0x4c3f47(0x251)]();if(!_0x2dd505){const _0x447f6d=[..._0x58f62c,...[..._0x1ab475['children'][_0x4c3f47(0x6d8)]()]][_0x4c3f47(0x13a)](0x0,0x64);return[_0x447f6d,''];}const _0x2a4788=_0x2dd505[_0x4c3f47(0x2aa)](/\s+/),_0x43cd7f=_0x2a4788[0x0],_0x1baf18=_0x43cd7f[_0x4c3f47(0x419)]();if(_0x2a4788[_0x4c3f47(0x39d)]===0x1){const _0x878dc4=_0x43cd7f[_0x4c3f47(0x8d)](),_0xd39a1f=_0x58f62c[_0x4c3f47(0x293)](_0x29df2e=>_0x29df2e['startsWith'](_0x878dc4)),_0x1e043d=_0xdf744a(_0x43cd7f,_0x1ab475,_0x19920a,_0x2ea2c9),_0x17398e=[...new Set([..._0xd39a1f,..._0x1e043d])][_0x4c3f47(0x13a)](0x0,0x64);return[_0x17398e,_0x43cd7f];}if(_0x42e204[_0x4c3f47(0x469)](_0x1baf18)&&_0x2a4788[_0x4c3f47(0x39d)]===0x2){const _0x573335=_0x2a4788[0x1],_0x5344fa=_0xdf744a(_0x573335,_0x1ab475,_0x19920a,_0x2ea2c9);return[_0x5344fa[_0x4c3f47(0x757)](_0xa30773=>_0x43cd7f+'\x20'+_0xa30773),_0x43cd7f+'\x20'+_0x573335];}if(!_0x42e204[_0x4c3f47(0x469)](_0x1baf18)&&_0x2a4788[_0x4c3f47(0x39d)]>0x1){const _0x5bea81=_0xdf744a(_0x43cd7f,_0x1ab475,_0x19920a,_0x2ea2c9),_0x2f12c3='\x20'+_0x2a4788[_0x4c3f47(0x13a)](0x1)[_0x4c3f47(0x10b)]('\x20');return[_0x5bea81[_0x4c3f47(0x757)](_0x3be5e4=>_0x3be5e4+_0x2f12c3),_0x43cd7f+_0x2f12c3];}return[[],_0x2ca06c];}catch{return[[],_0x2ca06c];}};}async function _0x16d1b7(_0x577470,_0x482c7c){const _0x359c8f=_0x26a86f,_0x36f6c9={'enabled':!![],'level':_0x482c7c[_0x359c8f(0x4a0)]??_0x359c8f(0x2cf)},_0x1f9eea={'env':_0x359c8f(0x3e8)},_0x14d19a={'current':null},_0x2617ae=_0x2ff1a9(_0x577470[_0x359c8f(0x91)][_0x359c8f(0x562)]()),_0x3b2154=_0x527660(_0x2617ae,_0x577470,_0x1f9eea);_0x577470[_0x359c8f(0x24e)]['attach'](_0x4c9dee=>{const _0x5e82b0=_0x359c8f;if(!_0x36f6c9[_0x5e82b0(0x1f9)])return;_0x13c223(_0x4c9dee,_0x36f6c9['level']),_0x14d19a[_0x5e82b0(0x2ef)]?.[_0x5e82b0(0x33e)](!![]);}),_0x1c3ad0(_0x577470,_0x482c7c);const _0x306123=_0x52889e[_0x359c8f(0x3d7)]({'input':process[_0x359c8f(0x40c)],'output':process[_0x359c8f(0x11c)],'terminal':!![],'completer':_0x3b2154,'prompt':_0x53c343(_0x1f9eea),'historySize':_0x2f1774});try{const _0x42ff0a=_0x22358a[_0x359c8f(0x418)](_0x3d347d,_0x359c8f(0x320))[_0x359c8f(0x2aa)]('\x0a')['filter'](Boolean);_0x306123[_0x359c8f(0x5ad)]=_0x42ff0a[_0x359c8f(0x693)]()['slice'](0x0,_0x2f1774);}catch{}_0x14d19a[_0x359c8f(0x2ef)]=_0x306123,_0x306123['on']('line',async _0x36afd6=>{const _0x544edd=_0x359c8f;_0x306123['pause']();try{await _0x295ed4(_0x36afd6,_0x577470,_0x482c7c,_0x36f6c9,_0x1f9eea,_0x306123);}catch(_0x4349b9){console[_0x544edd(0x492)](_0x43d25e(_0x4bb7aa[_0x544edd(0x356)],_0x544edd(0xae)+_0x4349b9[_0x544edd(0x5e6)]));}finally{_0x306123[_0x544edd(0x2a4)](),_0x306123[_0x544edd(0x33e)]();}}),_0x306123['on'](_0x359c8f(0x44f),()=>{const _0x267a06=_0x359c8f;try{const _0x4ee92b=[..._0x306123[_0x267a06(0x5ad)]]['reverse']()[_0x267a06(0x293)](Boolean)['slice'](0x0,_0x2f1774);_0x22358a[_0x267a06(0x188)](_0x3d347d,_0x4ee92b[_0x267a06(0x10b)]('\x0a')+'\x0a');}catch{}_0x3950bd(_0x577470,0x0);});let _0x5f5b9b=0x0;return process['on'](_0x359c8f(0xe2),()=>{const _0x28b7d3=_0x359c8f;if(_0x204f39)return _0x3950bd(_0x577470,0x82,'SIGINT');if(_0x306123[_0x28b7d3(0x1c4)]==='')return _0x3950bd(_0x577470,0x0,'SIGINT');const _0x10a65d=Date['now']();if(_0x10a65d-_0x5f5b9b<0x5dc)return _0x3950bd(_0x577470,0x0,'SIGINT\x20(double-tap)');_0x5f5b9b=_0x10a65d,process['stdout'][_0x28b7d3(0xb6)]('\x0a'),_0x306123[_0x28b7d3(0x169)](0x0),_0x306123[_0x28b7d3(0x33e)](),process[_0x28b7d3(0x705)]['write'](_0x43d25e(_0x4bb7aa[_0x28b7d3(0x775)],_0x28b7d3(0x5bb)));}),process['on'](_0x359c8f(0x196),()=>_0x3950bd(_0x577470,0x0,_0x359c8f(0x196))),process['on'](_0x359c8f(0x583),()=>_0x3950bd(_0x577470,0x0,_0x359c8f(0x583))),_0x306123[_0x359c8f(0x33e)](),_0x306123;}return okdbShell={'start':_0x16d1b7,'colorLog':_0x13c223,'lenientParse':_0x158ef8,'_splitLine':_0x8fe228,'_formatRouteHelpLines':_0x20d4ae,'_routeSummary':_0x9eddb5,'_routeTags':_0x2c3099},okdbShell;}var okdbLoopMonitor,hasRequiredOkdbLoopMonitor;function requireOkdbLoopMonitor(){const _0xb64380=_0x3d20e4;if(hasRequiredOkdbLoopMonitor)return okdbLoopMonitor;hasRequiredOkdbLoopMonitor=0x1;const {monitorEventLoopDelay:_0x4b9ef2,performance:_0x1ab312}=require$$0$4,_0x2d6788=process.env.OKDB_LOOP_LAG==='1'||process.env.OKDB_LOOP_LAG===_0xb64380(0x727),_0x5b8ec6=Number(process.env.OKDB_LOOP_LAG_MS)||0x7d0,_0x5dfe4f=process.env.OKDB_LOOP_LAG_ALL==='1',_0x5e834a=Number(process.env.OKDB_LOOP_LAG_MIN_MS)||0x64;class _0x12544d{constructor(){const _0x4601ab=_0xb64380;this[_0x4601ab(0x1f9)]=_0x2d6788,this[_0x4601ab(0x84)]=new Map(),this['_h']=null,this[_0x4601ab(0x577)]=null,this[_0x4601ab(0x589)]=![],this[_0x4601ab(0x42a)]=(_0x3393a5,_0x4c5cc2)=>process['stderr'][_0x4601ab(0xb6)](_0x3393a5+(_0x4c5cc2?'\x20'+JSON[_0x4601ab(0x5c1)](_0x4c5cc2):'')+'\x0a');}[_0xb64380(0x127)](){const _0x15de53=_0xb64380;return _0x1ab312[_0x15de53(0x127)]();}['setLogger'](_0xcc0208){const _0x11775e=_0xb64380;if(typeof _0xcc0208===_0x11775e(0x372))this[_0x11775e(0x42a)]=_0xcc0208;}[_0xb64380(0x79)](_0x346fa4,_0x3efb30,_0x56ce5e){const _0x242a90=_0xb64380;if(!this[_0x242a90(0x1f9)])return;let _0x337f73=this[_0x242a90(0x84)][_0x242a90(0x6a)](_0x346fa4);!_0x337f73&&(_0x337f73={'ms':0x0,'count':0x0,'maxMs':0x0,'maxExtra':''},this[_0x242a90(0x84)][_0x242a90(0x49d)](_0x346fa4,_0x337f73)),_0x337f73['ms']+=_0x3efb30,_0x337f73['count']+=0x1,_0x3efb30>_0x337f73[_0x242a90(0x17a)]&&(_0x337f73[_0x242a90(0x17a)]=_0x3efb30,_0x337f73[_0x242a90(0x9e)]=_0x56ce5e||'');}['start'](_0x3d50ea){const _0x543f78=_0xb64380;if(!this[_0x543f78(0x1f9)]||this[_0x543f78(0x589)])return;this['_started']=!![];if(_0x3d50ea)this['_log']=_0x3d50ea;this['_h']=_0x4b9ef2({'resolution':0xa}),this['_h']['enable'](),this['_timer']=setInterval(()=>this[_0x543f78(0x72a)](),_0x5b8ec6);if(this[_0x543f78(0x577)][_0x543f78(0xe9)])this[_0x543f78(0x577)][_0x543f78(0xe9)]();}[_0xb64380(0x600)](_0x2ff297){const _0x54b32e=_0xb64380;if(!this[_0x54b32e(0x677)])this[_0x54b32e(0x677)]=new Set();this[_0x54b32e(0x677)][_0x54b32e(0x3e9)](_0x2ff297);if(!this[_0x54b32e(0x589)])this[_0x54b32e(0x578)]();}[_0xb64380(0x3ab)](_0x51ad45){const _0x71791e=_0xb64380;this[_0x71791e(0x677)]?.['delete'](_0x51ad45);}[_0xb64380(0x578)](){const _0x44ed84=_0xb64380;if(this['_admissionStarted'])return;this[_0x44ed84(0x713)]=!![];!this['_h']&&(this['_h']=_0x4b9ef2({'resolution':0xa}),this['_h'][_0x44ed84(0x17c)]());const _0x5b645a=_0x5b8ec6;this[_0x44ed84(0x643)]=setInterval(()=>{const _0x4b6e03=_0x44ed84,_0xf6f09c=this['_h'];if(!_0xf6f09c)return;const _0x52a55d=_0xf6f09c['percentile'](0x63)/0xf4240,_0x471a27=_0xf6f09c[_0x4b6e03(0x68c)]/0xf4240,_0x4a2a22=_0xf6f09c[_0x4b6e03(0x72f)]/0xf4240;_0xf6f09c[_0x4b6e03(0x478)]();if(this[_0x4b6e03(0x677)])for(const _0x5e48d6 of this[_0x4b6e03(0x677)]){try{_0x5e48d6({'p99Ms':_0x52a55d,'maxMs':_0x471a27,'meanMs':_0x4a2a22,'reportMs':_0x5b645a});}catch{}}},_0x5b645a);if(this[_0x44ed84(0x643)]['unref'])this['_admissionTimer'][_0x44ed84(0xe9)]();}[_0xb64380(0x72a)](){const _0x45cfc1=_0xb64380,_0x41fa05=this['_h'],_0x44da3f=_0x41fa05['max']/0xf4240,_0x156668=_0x41fa05[_0x45cfc1(0x721)](0x63)/0xf4240,_0x3cc160=_0x41fa05[_0x45cfc1(0x72f)]/0xf4240;_0x41fa05[_0x45cfc1(0x478)]();const _0x106de9=[...this[_0x45cfc1(0x84)]['entries']()][_0x45cfc1(0x757)](([_0x50ce35,_0x549a7e])=>({'label':_0x50ce35,..._0x549a7e}))[_0x45cfc1(0x774)]((_0x32747e,_0x2fc856)=>_0x2fc856['ms']-_0x32747e['ms'])[_0x45cfc1(0x13a)](0x0,0x8);this['_buckets'][_0x45cfc1(0x209)]();const _0x58e7f0=_0x106de9[_0x45cfc1(0x47e)]((_0x2bb518,_0x58f985)=>_0x2bb518+_0x58f985['ms'],0x0),_0x21b2ee=_0x106de9['map'](_0x22877a=>_0x22877a[_0x45cfc1(0x313)]+'='+_0x22877a['ms'][_0x45cfc1(0x72c)](0x0)+_0x45cfc1(0xda)+_0x22877a[_0x45cfc1(0x6ad)]+(_0x22877a[_0x45cfc1(0x17a)]>0x5?'(worst\x20'+_0x22877a['maxMs'][_0x45cfc1(0x72c)](0x0)+'ms'+(_0x22877a['maxExtra']?'\x20'+_0x22877a[_0x45cfc1(0x9e)]:'')+')':''));(_0x5dfe4f||_0x44da3f>=_0x5e834a)&&this[_0x45cfc1(0x42a)]('loop-lag\x20'+_0x5b8ec6+_0x45cfc1(0x354)+_0x44da3f['toFixed'](0x0)+_0x45cfc1(0x42c)+_0x156668[_0x45cfc1(0x72c)](0x0)+_0x45cfc1(0x63f)+_0x3cc160[_0x45cfc1(0x72c)](0x0)+_0x45cfc1(0x291)+_0x58e7f0[_0x45cfc1(0x72c)](0x0)+'ms'+(_0x21b2ee[_0x45cfc1(0x39d)]?_0x45cfc1(0x367)+_0x21b2ee['join']('\x20\x20'):''),{'feature':'loop-lag'});if(this['_windowCbs'])for(const _0x1eaaf1 of this[_0x45cfc1(0x677)]){try{_0x1eaaf1({'p99Ms':_0x156668,'maxMs':_0x44da3f,'meanMs':_0x3cc160,'reportMs':_0x5b8ec6});}catch{}}}[_0xb64380(0x226)](){const _0x1996d8=_0xb64380;if(this[_0x1996d8(0x577)])clearInterval(this[_0x1996d8(0x577)]);if(this['_h'])this['_h'][_0x1996d8(0xa4)]();this[_0x1996d8(0x577)]=null,this['_h']=null,this['_started']=![];}}const _0x2eb4ba=new _0x12544d();if(_0x2eb4ba[_0xb64380(0x1f9)])_0x2eb4ba[_0xb64380(0x570)]();return okdbLoopMonitor={'LOOP':_0x2eb4ba},okdbLoopMonitor;}var okdbWriter={'exports':{}},okdbDiag,hasRequiredOkdbDiag;function requireOkdbDiag(){if(hasRequiredOkdbDiag)return okdbDiag;hasRequiredOkdbDiag=0x1;const _0x402fd4=require$$0$1,_0x5d11aa=require$$1;let _0x3211d3,_0x3ae21f,_0x59aa73,_0x4f646c,_0x4fc8da,_0x444485,_0x26cc5c,_0x11ee7a=![];const _0xb9dbbe=new Set();let _0x5ba2bb=null;const _0x17a51f=new Map();function _0x1166b8(){const _0x247ca5=_0x8cd7;if(_0x3211d3!==undefined)return _0x3211d3;_0x3211d3=process.env.OKDB_DIAG==='1';if(!_0x3211d3)return![];_0x3ae21f=process.env.OKDB_DIAG_STACK==='1',_0x4f646c=Math['max'](0x10,Number(process.env.OKDB_DIAG_RING)||0x100),_0x59aa73=new Array(_0x4f646c),_0x4fc8da=0x0,_0x444485=0x0,_0x26cc5c=process.env.OKDB_DIAG_DIR||null;if(_0x26cc5c)try{_0x402fd4[_0x247ca5(0x2ad)](_0x26cc5c,{'recursive':!![]});}catch{}return!![];}function _0x3101e0(){return _0x3211d3===undefined?_0x1166b8():_0x3211d3;}function _0x35ca33(_0xbbc73b,_0xc146d){const _0x532fa4=_0x8cd7;if(_0x3211d3===undefined?!_0x1166b8():!_0x3211d3)return;let _0x2eb918;if(_0x3ae21f){const _0x1676dc=new Error()[_0x532fa4(0x5ed)]||'';_0x2eb918=_0x1676dc['split']('\x0a')[_0x532fa4(0x13a)](0x3)['map'](_0x2bfcab=>_0x2bfcab[_0x532fa4(0x471)]())[_0x532fa4(0x293)](Boolean)[_0x532fa4(0x13a)](0x0,0x8);}_0x59aa73[_0x4fc8da]={'seq':_0x444485++,'t':Date[_0x532fa4(0x127)](),'env':_0xbbc73b,'kind':_0xc146d||'commit','stack':_0x2eb918},_0x4fc8da=(_0x4fc8da+0x1)%_0x4f646c;}function _0x382166(_0x1dbd1e){const _0x4a7d43=_0x8cd7,_0x35c929=[];for(let _0x1d2c2e=0x0;_0x1d2c2e<_0x4f646c;_0x1d2c2e++){const _0x1906be=_0x59aa73[(_0x4fc8da-0x1-_0x1d2c2e+_0x4f646c*0x2)%_0x4f646c];if(!_0x1906be)continue;_0x35c929[_0x4a7d43(0x2f9)](_0x1906be);if(_0x35c929[_0x4a7d43(0x39d)]>=_0x1dbd1e)break;}return _0x35c929;}function _0x69fb1d(_0x1ca1b9){const _0x1ae2dd=_0x8cd7;try{process[_0x1ae2dd(0x705)]['write'](_0x1ca1b9+'\x0a');}catch{}if(_0x26cc5c)try{_0x402fd4[_0x1ae2dd(0xfb)](_0x5d11aa['join'](_0x26cc5c,'okdb-diag.'+process['pid']+_0x1ae2dd(0x30f)),_0x1ca1b9+'\x0a');}catch{}}function _0x3f1696(_0x4ac17b){const _0x45c7ae=_0x8cd7,_0x5207de=_0x382166(_0x4ac17b);if(!_0x5207de[_0x45c7ae(0x39d)])return _0x45c7ae(0xfe);const _0x599b99=Date[_0x45c7ae(0x127)]();return _0x5207de[_0x45c7ae(0x757)](_0x412687=>{const _0x279832=_0x45c7ae,_0x23be15=_0x279832(0x5f2)+_0x412687['seq']+'\x20-'+(_0x599b99-_0x412687['t'])+_0x279832(0x637)+_0x412687[_0x279832(0x124)]+'\x20'+_0x412687[_0x279832(0xaa)];return _0x412687['stack']&&_0x412687[_0x279832(0x5ed)]['length']?_0x23be15+'\x0a\x20\x20\x20\x20\x20\x20'+_0x412687[_0x279832(0x5ed)][_0x279832(0x10b)](_0x279832(0x33b)):_0x23be15;})[_0x45c7ae(0x10b)]('\x0a');}function _0x48b9a7(_0x358039,_0x53b3dd){const _0x3266cf=_0x8cd7,_0x295509='\x0a===\x20OKDB_DIAG\x20'+_0x358039+_0x3266cf(0x2b1)+new Date()[_0x3266cf(0x261)]()+'\x20pid='+process['pid']+_0x3266cf(0x71f),_0x4ad973=[_0x295509,_0x3266cf(0x85)+(_0x53b3dd&&_0x53b3dd['stack']?_0x53b3dd['stack'][_0x3266cf(0x2aa)]('\x0a')[0x0]:_0x53b3dd),'recent\x20writes\x20(newest\x20first)'+(_0x3ae21f?'':_0x3266cf(0x215))+':',_0x3f1696(0x18),_0x57e79d(),'='[_0x3266cf(0x4d9)](_0x295509[_0x3266cf(0x39d)]-0x1)];_0x69fb1d(_0x4ad973[_0x3266cf(0x10b)]('\x0a'));}function _0x4a072d(_0x178837){const _0x1db119=_0x8cd7;if(!_0x3101e0())return;const _0x219849=String(_0x178837&&_0x178837[_0x1db119(0x5e6)]||_0x178837||''),_0x24f45e=/already closed|environment is already|invalid read txn|reset an invalid/i['test'](_0x219849);_0x48b9a7(_0x24f45e?_0x1db119(0x135):_0x1db119(0x509),_0x178837);if(process.env.OKDB_DIAG_SURVIVE==='1'&&_0x24f45e)return;try{console[_0x1db119(0x492)](_0x178837&&_0x178837[_0x1db119(0x5ed)]?_0x178837[_0x1db119(0x5ed)]:_0x178837);}catch{}process['exit'](0x1);}function _0x435fe5(_0x361ccf){const _0x1ac2e2=_0x8cd7;if(!_0x3101e0())return;const _0x43a054=String(_0x361ccf&&_0x361ccf[_0x1ac2e2(0x5e6)]||_0x361ccf||'');/already closed|environment is already|invalid read txn|reset an invalid/i[_0x1ac2e2(0x155)](_0x43a054)&&_0x48b9a7(_0x1ac2e2(0x4af),_0x361ccf);}function _0x57e79d(){const _0x5e3966=_0x8cd7,_0x8fe059=[_0x5e3966(0x66a)];let _0x151638=![];for(const _0x2c29cf of _0xb9dbbe){const _0x24b220=_0x2c29cf&&_0x2c29cf[_0x5e3966(0x64c)];if(!_0x24b220)continue;for(const [_0x495615,_0x5416dd]of _0x24b220){const _0x43ee37=_0x5416dd&&_0x5416dd['_coordinator']&&_0x5416dd['_coordinator']['view'];if(!_0x43ee37)continue;let _0x242b1b,_0x34785e;try{_0x242b1b=Atomics[_0x5e3966(0x776)](_0x43ee37,0x0),_0x34785e=Atomics[_0x5e3966(0x776)](_0x43ee37,0x1);}catch{continue;}if(_0x242b1b===0x0)continue;_0x151638=!![];const _0x4fcd09=_0x242b1b>0x0?_0x5e3966(0x363):_0x5e3966(0x593),_0x199019=Date[_0x5e3966(0x127)]()-Math[_0x5e3966(0x369)](_0x242b1b)*0x3e8,_0x17f5ba=((()=>{const _0x5285f9=_0x5e3966;try{return _0x5416dd[_0x5285f9(0x385)]&&_0x5416dd[_0x5285f9(0x385)][_0x5285f9(0x170)]?_0x5416dd[_0x5285f9(0x385)][_0x5285f9(0x170)]():null;}catch{return null;}})());_0x8fe059[_0x5e3966(0x2f9)](_0x5e3966(0x608)+_0x495615+_0x5e3966(0x3c7)+_0x4fcd09+_0x5e3966(0x480)+_0x199019+_0x5e3966(0x6e8)+_0x34785e+(_0x17f5ba?'\x20writer{depth='+_0x17f5ba[_0x5e3966(0x5c7)]+_0x5e3966(0x152)+_0x17f5ba[_0x5e3966(0x3f9)]+_0x5e3966(0x2e3)+_0x17f5ba[_0x5e3966(0x228)]+'}':''));}}if(!_0x151638)_0x8fe059['push'](_0x5e3966(0x4cd));return _0x8fe059[_0x5e3966(0x10b)]('\x0a');}function _0x482f65(){const _0x1ef437=_0x8cd7;if(!_0x3101e0())return;const _0x54f5a8=Math[_0x1ef437(0x68c)](0x3e8,Number(process.env.OKDB_DIAG_STALL_MS)||0x1f40),_0x4121ea=Date['now']();for(const _0x103328 of _0xb9dbbe){const _0x26e821=_0x103328&&_0x103328[_0x1ef437(0x64c)];if(!_0x26e821)continue;for(const [_0x322cc0,_0x347ef7]of _0x26e821){const _0x2d5fc5=_0x347ef7&&_0x347ef7[_0x1ef437(0x6c7)]&&_0x347ef7[_0x1ef437(0x6c7)][_0x1ef437(0xf6)];if(!_0x2d5fc5)continue;let _0x1bb272;try{_0x1bb272=Atomics[_0x1ef437(0x776)](_0x2d5fc5,0x0);}catch{continue;}const _0x325f3b=_0x103328[_0x1ef437(0x4c5)]+'|'+_0x322cc0;if(_0x1bb272<=0x0){_0x17a51f[_0x1ef437(0x95)](_0x325f3b);continue;}const _0x4ee649=_0x4121ea-_0x1bb272*0x3e8,_0xbeee5c=_0x17a51f['get'](_0x325f3b);if(_0x4ee649<_0x54f5a8)continue;if(_0xbeee5c&&_0x4121ea-_0xbeee5c[_0x1ef437(0xbe)]<_0x54f5a8)continue;_0x17a51f[_0x1ef437(0x49d)](_0x325f3b,{'firstTs':_0xbeee5c?_0xbeee5c['firstTs']:_0x1bb272,'dumpedAt':_0x4121ea});const _0x917209=_0x1ef437(0x71e)+_0x4ee649+'ms\x20on\x20env='+_0x322cc0+_0x1ef437(0x2b1)+new Date()[_0x1ef437(0x261)]()+_0x1ef437(0x431)+process[_0x1ef437(0xee)]+_0x1ef437(0x71f);_0x69fb1d([_0x917209,_0x57e79d(),'='[_0x1ef437(0x4d9)](_0x917209[_0x1ef437(0x39d)]-0x1)][_0x1ef437(0x10b)]('\x0a'));}}}function _0x572982(){const _0x4ffb9e=_0x8cd7;if(!_0x3101e0()||_0x11ee7a)return;_0x11ee7a=!![],process['prependListener']('uncaughtException',_0x4a072d),process[_0x4ffb9e(0x193)](_0x4ffb9e(0x569),_0x435fe5);const _0x39d557=Math[_0x4ffb9e(0x68c)](0xfa,Number(process.env.OKDB_DIAG_WATCH_MS)||0x7d0);_0x5ba2bb=setInterval(_0x482f65,_0x39d557);if(_0x5ba2bb['unref'])_0x5ba2bb['unref']();}function _0x506d85(_0x388014){const _0x60ba1d=_0x8cd7;if(!_0x3101e0()||!_0x388014)return;_0xb9dbbe[_0x60ba1d(0x3e9)](_0x388014),_0x572982();}function _0x157e11(_0x5af868){const _0x551249=_0x8cd7;_0xb9dbbe[_0x551249(0x95)](_0x5af868);}function _0x388d75(){const _0x13d8d5=_0x8cd7;if(!_0x3101e0())return{'enabled':![],'hint':_0x13d8d5(0x5ec)};return{'enabled':!![],'stackCapture':!!_0x3ae21f,'recentWrites':_0x382166(0x10),'drain':_0x57e79d()};}return okdbDiag={'isEnabled':_0x3101e0,'recordWrite':_0x35ca33,'installDiag':_0x572982,'registerOkdb':_0x506d85,'unregisterOkdb':_0x157e11,'snapshot':_0x388d75},okdbDiag;}function _0x166e(){const _0x4a4ee1=[')\x20—\x20this\x20process\x20will\x20not\x20appear\x20in\x20the\x20process\x20census','listenAddr','dataBytes','title','peers=','syncPeers','\x1b[32m','env:opened','getPins','ROUTES','PUT','discoveryTtlMs','gray',':\x20key\x20[','_cookieName','[okdb]\x20error:\x20join\x20requires\x20a\x20remote\x20address.\x20Usage:\x20okdb\x20join\x20<address>\x20--token\x20<t>','stderr','hasDesired','name','API\x20tokens,\x20users,\x20and\x20credentials.','\x27:\x20','bus:env_release','\x20\x20matching\x20prefix\x20\x20\x20\x20','protected:read','nodeKey','⚠\x20OPEN\x20LICENSE\x20ACTIVE\x20—\x20this\x20license\x20is\x20not\x20node-bound\x20and\x20is\x20intended\x20for\x20POC/demo\x20use\x20only.\x20Expires\x20in\x20','--ttl','Invalid\x20primary\x20key\x20type:\x20','addRaw','blob','_admissionStarted','_clusterOnMessage','jwks_uri','[okdb-cluster]\x20','authorization_endpoint','_children','243858pqUWRX','GONE','unique','\x20\x20(','exports','\x0a===\x20OKDB_DIAG\x20STALL:\x20swap\x20drain\x20held\x20','\x20===','readSync','percentile','dedupeMax','\x20\x20\x20\x20•\x20a\x20path\x20to\x20a\x20.license\x20file','use','_caps','\x20\x20\x20\x20addedAt:\x20\x20\x20','true','List\x20tokens\x20and\x20users.','dropType','_report','type:registered','toFixed','OKDBInvalidPrimaryKeyError','msg','mean','dropSchema','_sync','\x0a\x20\x20✓\x20License\x20added','roles','_buildProcessingFacet','\x20envs','sab','INDEX_READY','resolve','\x20deleted','okdb-writer[','primary','/type/users/query\x0a\x20\x20\x20\x20','clock','_onTick','win32','txn:start','UNIQUE_CONSTRAINT','reads','dropFts','View\x20peer\x20status\x20and\x20replication\x20stats.','.\x20Only\x20primitives,\x20null,\x20Buffers,\x20and\x20arrays\x20are\x20allowed.\x20Got:\x20','_ownMeta','closeAllConnections','Environment\x20lifecycle.\x20Listing\x20and\x20creating\x20envs\x20is\x20system-level.','\x20records','start\x20','okdb.pid','[okdb-cluster]\x20recommissioned\x20worker\x20slot=','tokenSecret','building','candidateBytes','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20GET\x20(implicit)\x0a\x20\x20','_nodeDead','sizeAfter','hasType','application/json','bus:poke','onClaimed','map','createEnvironment','\x20\x20[','processor:resumed','\x20\x20\x20\x20','_heldTotal','yes','oauth','updatedAt','process\x20','\x20\x20\x20\x20licensee:\x20\x20','origins','FTS_RESET','\x0a\x20\x20Joined.\x20Remote\x20tokens\x20replicated.\x20You\x20can\x20now\x20log\x20in\x20with\x20cluster\x20credentials.\x0a','readUInt16BE','hashed','\x20\x20Envs:\x20\x20\x20\x20','\x20\x20skipped:\x20','clusterStatusView','_resolveOrCreateEnv','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20→\x20GET\x20/api/env/staging/info\x0a\x0a','activateLicense','\x20env','pop',',\x20which\x20still\x20exists\x20—\x20the\x20restored\x20','Admin','dropping','consecutiveFailures','Feature\x20not\x20available\x20on\x20free\x20tier:\x20','sort','dim','load','--port','\x20\x20\x20\x20admin:\x20\x20\x20http://localhost:','false','SIG_INVALID','Blob\x20storage:\x20large\x20file\x20uploads\x20attached\x20to\x20records\x20or\x20stored\x20standalone.','\x0a\x20\x20Raw\x20token\x20(shown\x20once,\x20save\x20it\x20now):\x0a','supervisorKey','\x20\x20\x20\x20\x20control\x20log\x20verbosity\x0a\x20\x20','dynamic','stopped','acquiredAt','BAD_GATEWAY','_validateOidcAccessToken','http.workers','error\x20','get','permission','\x20binding\x20references\x20missing\x20input\x20field:\x20','\x20\x20\x20\x20admin:\x20http://localhost:','OKDBSchemaValidationError','\x20\x20errors\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','newIdentity','guard','attached','ftsIndexes','homedir','_readNDJSON','_isWriter','system:ready','writeUInt32BE','note','_done','_pending','env/','_okdb','\x20+\x20','sourcePath','Type\x20definitions,\x20all\x20index\x20registrations\x20(byIndex,\x20FTS,\x20vector),\x20and\x20TTL\x20policy.','.okdb-write-test','\x0a\x20\x20','find','_buckets','error:\x20','STATUS','destroyed','[okdb]\x20importing\x20','\x20(expires\x20','auth','cursorKey','HTTP_CLUSTER_REMOVED','toLowerCase','Schema\x20&\x20Indexes','includes','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','http','_handleInProcess','\x20\x20\x20\x20\x20\x20\x20\x20\x20OKDB\x20SHELL\x20\x20\x20\x20\x20\x20\x20\x20','[okdb]\x20invalid\x20','delete','_lockDbOf','config\x20http.workers',';\x20Secure','copyFile','_onStop','user','createPublicKey','properties','maxExtra','(?:','Write','fstatSync','socket','recordWrite','disable','\x20license(s)',')\x20→\x20','\x20worker(s)\x20remaining','timingSafeEqual','application/x-www-form-urlencoded','kind','setFlagsFromString','[okdb]\x20reset:\x20','then','\x20\x20Error:\x20','\x20cannot\x20be\x20MCP-exposed\x20without\x20an\x20explicit\x20adapter\x20because\x20it\x20uses\x20','\x22\x20already\x20exists','exec','verifyActivation','context',';\x20shmbuf\x20native\x20missing\x20→\x20forced\x20single-process','[okdb]\x20http\x20workers:\x20','write','_clusterWorkerAttached','definition','_totalRequests','~files','rawResponse','registerType','\x20\x20\x20\x20•\x20an\x20activation\x20token\x20\x20(124\x20chars)','dumpedAt','toLocaleString','freeze','OKDBSchemaCollectionError','PAYLOAD_TOO_LARGE','parse','maxBodyBytes','UNSUPPORTED_MEDIA_TYPE','createdAt','\x20\x20deleted\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','/admin/index.html','meta','commitsPerSec','--username','\x20\x20\x20\x20license:\x20free\x20tier\x20—\x20add\x20a\x20license\x20to\x20unlock\x20sync,\x20embeddings,\x20engines,\x20time-machine','(code=','May\x20read\x20system\x20types\x20when\x20also\x20granted\x20the\x20underlying\x20read\x20permission.','shmbuf','failed\x20to\x20open','\x20\x20\x20\x20pin:\x20\x20\x20\x20\x20','importFromStream','Writable','_hbTimer','Feature\x20not\x20licensed:\x20','prefix','_key','\x20has\x20ambiguous\x20query/path\x20field:\x20','Records','ms/','RS256','data:\x20','--test','\x0a\x20\x20okdb\x20—\x20standalone\x20OKDB\x20server\x0a\x0a\x20\x20Usage:\x0a\x20\x20\x20\x20okdb\x20[options]\x0a\x20\x20\x20\x20okdb\x20<command>\x0a\x0a\x20\x20Options:\x0a\x20\x20\x20\x20-p,\x20--port\x20<port>\x20\x20\x20\x20\x20\x20\x20\x20HTTP\x20port\x20(default:\x208484)\x0a\x20\x20\x20\x20-d,\x20--path\x20<dir>\x20\x20\x20\x20\x20\x20\x20\x20\x20Database\x20directory\x20(default:\x20./okdb-data)\x0a\x20\x20\x20\x20-k,\x20--key\x20\x20<secret>\x20\x20\x20\x20\x20\x20Encryption\x20key\x20for\x20data\x20at\x20rest\x0a\x20\x20\x20\x20-c,\x20--config\x20<file>\x20\x20\x20\x20\x20\x20Config\x20file\x20path\x20(default:\x20.kdbconfig)\x0a\x20\x20\x20\x20\x20\x20\x20\x20--log-level\x20<level>\x20\x20Log\x20level:\x20debug\x20|\x20info\x20|\x20warn\x20|\x20error\x20(default:\x20info)\x0a\x20\x20\x20\x20\x20\x20\x20\x20--no-repl\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Start\x20server\x20without\x20interactive\x20shell\x0a\x20\x20\x20\x20\x20\x20\x20\x20--no-admin\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Disable\x20admin\x20UI\x0a\x20\x20\x20\x20\x20\x20\x20\x20--open\x20[ip\x20...]\x20\x20\x20\x20\x20\x20Open\x20mode:\x20bypass\x20auth\x20for\x20listed\x20IPs\x20(default:\x20localhost).\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Examples:\x20--open\x20\x20--open\x20192.168.1.0/24\x20\x20--open\x20*\x0a\x20\x20\x20\x20\x20\x20\x20\x20--log-requests\x20\x20\x20\x20\x20\x20\x20Print\x20every\x20HTTP\x20request\x20to\x20stdout\x20(for\x20debugging)\x0a\x20\x20\x20\x20\x20\x20\x20\x20--workers\x20<n>\x20\x20\x20\x20\x20\x20\x20\x20Number\x20of\x20capable\x20worker\x20processes\x20sharing\x20the\x20listen\x20socket\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20(default:\x20cores\x20−\x201).\x20Each\x20worker\x20serves\x20HTTP\x20+\x20SSE\x20AND\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20processes\x20(claims\x20leases,\x20drains\x20on\x20its\x20own\x20loop);\x20the\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20cluster\x20primary\x20is\x20a\x20thin\x20passive\x20supervisor.\x0a\x20\x20\x20\x20\x20\x20\x20\x20--no-cluster\x20\x20\x20\x20\x20\x20\x20\x20\x20Run\x20single-process\x20(equivalent\x20to\x20--workers\x201)\x0a\x20\x20\x20\x20-v,\x20--version\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Print\x20version\x20and\x20exit\x0a\x20\x20\x20\x20-h,\x20--help\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Show\x20this\x20help\x0a\x0a\x20\x20Commands:\x0a\x20\x20\x20\x20version\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Print\x20version\x20and\x20exit\x0a\x20\x20\x20\x20doctor\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Run\x20health\x20checks\x0a\x20\x20\x20\x20init\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Create\x20.kdbconfig\x20and\x20okdb-data/\x0a\x20\x20\x20\x20token\x20create\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Create\x20a\x20token\x20in\x20the\x20local\x20DB\x20(direct\x20access,\x20no\x20HTTP)\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20--name\x20<name>\x20\x20\x20\x20\x20\x20For\x20password\x20login\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20--password\x20<pass>\x20\x20Password\x20(requires\x20--name)\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20--label\x20<text>\x20\x20\x20\x20\x20Human\x20description\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20--permissions\x20<l>\x20\x20Comma-separated\x20baseline\x20permissions\x20(e.g.\x20\x22*\x22\x20or\x20\x22data:read\x22)\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20--grants\x20<json>\x20\x20\x20\x20Per-env\x20grants\x20as\x20JSON\x20(e.g.\x20\x27{\x22orders\x22:[\x22data:*\x22]}\x27)\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20--ttl\x20<ms>\x20\x20\x20\x20\x20\x20\x20\x20\x20Optional\x20TTL\x20in\x20milliseconds\x0a\x20\x20\x20\x20token\x20list\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20List\x20all\x20tokens\x20in\x20the\x20local\x20DB\x0a\x20\x20\x20\x20token\x20revoke\x20<id>\x20\x20\x20\x20\x20\x20\x20\x20Revoke\x20(delete)\x20a\x20token\x20by\x20id\x20(full\x20uuid\x20or\x20unique\x20prefix)\x0a\x20\x20\x20\x20join\x20<address>\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Join\x20an\x20existing\x20cluster\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20--token\x20<t>\x20\x20\x20\x20\x20\x20\x20\x20Bearer\x20token\x20from\x20the\x20cluster\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20--username\x20<u>\x20\x20\x20\x20\x20Or,\x20username\x20for\x20login\x20exchange\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20--password\x20<p>\x20\x20\x20\x20\x20Password\x20for\x20login\x20exchange\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20--address\x20<addr>\x20\x20\x20This\x20node\x27s\x20reachable\x20sync\x20address\x20(required)\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20--path\x20<dir>\x20\x20\x20\x20\x20\x20\x20Local\x20DB\x20path\x0a\x20\x20\x20\x20backup\x20[dir]\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Hot\x20backup:\x20LMDB\x20snapshot\x20copy\x20of\x20every\x20env\x20+\x20time-machine\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20history\x20+\x20file\x20blobs\x20into\x20a\x20NEW\x20dir\x20(default:\x20./okdb-backup);\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20full-text\x20indexes\x20are\x20rebuilt\x20on\x20first\x20open,\x20not\x20copied\x0a\x20\x20\x20\x20restore\x20<dir>\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Restore\x20a\x20backup\x20dir\x20into\x20--path\x20(must\x20not\x20exist\x20or\x20be\x20empty)\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20--new-identity\x20\x20\x20\x20bring\x20the\x20copy\x20up\x20as\x20a\x20NEW\x20node\x20(fresh\x20id,\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20no\x20sync\x20membership)\x20instead\x20of\x20replacing\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20the\x20original\x20—\x20see\x20docs/migration.md\x0a\x20\x20\x20\x20export\x20<file>\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Streaming\x20NDJSON\x20logical\x20export\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20--env\x20<name>\x20\x20\x20\x20\x20\x20env\x20to\x20export\x20(default:\x20default)\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20--types\x20<a,b,...>\x20comma-separated\x20type\x20filter\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20--changes\x20\x20\x20\x20\x20\x20\x20\x20\x20include\x20changelog\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20--blobs\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20also\x20export\x20blob\x20files\x20alongside\x0a\x20\x20\x20\x20import\x20<file>\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Streaming\x20NDJSON\x20logical\x20import\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20--env\x20<name>\x20\x20\x20\x20\x20\x20target\x20env\x20override\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20--types\x20<a,b,...>\x20import\x20only\x20these\x20types\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20--drop\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20drop\x20&\x20recreate\x20existing\x20types\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20--changes\x20\x20\x20\x20\x20\x20\x20\x20\x20restore\x20changelog\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20--blobs\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20also\x20import\x20blob\x20files\x20alongside\x0a\x20\x20\x20\x20reset\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Delete\x20and\x20recreate\x20database\x20(with\x20confirmation);\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20node\x20identity\x20and\x20licenses\x20are\x20preserved\x0a\x20\x20\x20\x20license\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20List\x20stored\x20licenses,\x20current\x20tier,\x20and\x20usage\x0a\x20\x20\x20\x20license\x20<blob|path>\x20\x20\x20\x20\x20\x20Add\x20a\x20license\x20blob\x20(or\x20read\x20from\x20a\x20.license\x20file)\x0a\x20\x20\x20\x20license\x20<activation>\x20\x20\x20\x20\x20Activate\x20a\x20previously-added\x20license\x20with\x20the\x20vendor\x27s\x20token\x0a\x20\x20\x20\x20license\x20<id>\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Show\x20details\x20for\x20one\x20stored\x20license\x20(by\x20uuid\x20or\x20prefix)\x0a\x20\x20\x20\x20license\x20remove\x20<id>\x20\x20\x20\x20\x20\x20Remove\x20a\x20stored\x20license\x0a\x20\x20\x20\x20shm-gc\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Delete\x20leaked\x20okdb\x20shared-memory\x20segments\x20no\x20process\x20uses\x20(Linux)\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20--dry-run\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20report\x20only\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20--prefix\x20<p>\x20\x20\x20\x20\x20\x20\x20only\x20names\x20starting\x20with\x20<p>\x20(default\x20\x22-tmp-\x22)\x0a\x0a\x20\x20Environment\x20variables:\x0a\x20\x20\x20\x20OKDB_PORT\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20HTTP\x20port\x0a\x20\x20\x20\x20OKDB_PATH\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Database\x20directory\x0a\x20\x20\x20\x20OKDB_LOG_LEVEL\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Log\x20level\x20(debug|info|warn|error)\x0a\x20\x20\x20\x20OKDB_KEY\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Encryption\x20key\x0a\x20\x20\x20\x20OKDB_NO_REPL=1\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Disable\x20REPL\x0a\x20\x20\x20\x20OKDB_NO_ADMIN=1\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Disable\x20admin\x20UI\x0a\x20\x20\x20\x20OKDB_HTTP_WORKERS\x20\x20\x20\x20\x20\x20\x20\x20\x20Number\x20of\x20passive\x20HTTP\x20worker\x20processes\x20(default:\x20cores\x20−\x201;\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20forced\x20to\x201\x20if\x20the\x20shmbuf\x20native\x20binding\x20is\x20unavailable)\x0a\x0a\x20\x20Config\x20file\x20(.kdbconfig)\x20—\x20JSON,\x20all\x20keys\x20optional:\x0a\x20\x20\x20\x20{\x0a\x20\x20\x20\x20\x20\x20\x22port\x22:\x20\x20\x20\x20\x208484,\x0a\x20\x20\x20\x20\x20\x20\x22path\x22:\x20\x20\x20\x20\x20\x22./okdb-data\x22,\x0a\x20\x20\x20\x20\x20\x20\x22key\x22:\x20\x20\x20\x20\x20\x20\x22...\x22,\x0a\x20\x20\x20\x20\x20\x20\x22logLevel\x22:\x20\x22info\x22,\x0a\x20\x20\x20\x20\x20\x20\x22noAdmin\x22:\x20\x20false,\x0a\x20\x20\x20\x20\x20\x20\x22noRepl\x22:\x20\x20\x20false,\x0a\x20\x20\x20\x20\x20\x20\x22auth\x22:\x20{\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x22open\x22:\x20false\x0a\x20\x20\x20\x20\x20\x20}\x0a\x20\x20\x20\x20}\x0a\x0a\x20\x20Examples:\x0a\x20\x20\x20\x20okdb\x0a\x20\x20\x20\x20okdb\x20--port\x209000\x20--path\x20./mydb\x0a\x20\x20\x20\x20okdb\x20--no-repl\x20--port\x208080\x0a\x20\x20\x20\x20okdb\x20--open\x0a\x20\x20\x20\x20okdb\x20--open\x20192.168.1.0/24\x0a\x20\x20\x20\x20okdb\x20doctor\x0a\x20\x20\x20\x20okdb\x20backup\x20./my-backup\x0a\x20\x20\x20\x20okdb\x20restore\x20./my-backup\x20--path\x20./okdb-data\x0a','method','[okdb]\x20invalid\x20log\x20level:\x20\x22','_bucketIdx','SIGINT','writeMs','LICENSE_LIMIT_EXCEEDED','end','_flushTimer','string','_isClusterController','unref','okdb_session','_blobStatusDb','--print','isFile','pid','(primary\x20=\x20processor)','allSettled','authenticateRequest','cookie','system:stopped','beforeWrite','\x20\x20Usage:\x20','view','_quarantinedEnvs','item:pending','openSync','shift','appendFileSync','\x20to\x20browse\x20the\x20API,\x20','shmbufNative','\x20\x20(write\x20ring\x20empty\x20—\x20was\x20OKDB_DIAG\x20set\x20before\x20any\x20write?)',',\x20closing…\x0a','_dedupeMax','value','OKDBError','legacy','List\x20jobs,\x20view\x20stats,\x20list\x20buckets.','typeSubDbs','tokenizer','processorsView','<path>','ENOENT','\x20\x20\x20\x20id:\x20\x20\x20\x20','join','\x0a\x20\x20Run\x20okdb\x20to\x20start\x20the\x20server.\x0a','Index\x20\x22','LICENSE_ALREADY_STORED','defaults','TYPES','\x20origin=','\x20<\x20','endsWith','treeView','\x20has\x20invalid\x20http.bodyMode:\x20','noAdmin','orphan_blob','credentials','shutdown','\x20fetching\x20','resetFts','stdout','workersConfigured','\x20MB\x20→\x20','_kind','missing_blob','timeMachine','randomBytes','concat','env','envsOpen','/api','now','blindPids','token','_startedAt','_jwksNegativeCache','Queue','effective','cli','unlink','/type/users/item/alice\x0a\x20\x20\x20\x20','selfKey','role','attach','\x20\x20Usage:','ORPHAN\x20(env-closed\x20write)','license:added','examples','[okdb]\x20primary\x20okdb\x20close\x20error:\x20','round','slice','setPrompt','description','isSetupMode','registerIndex','--grants','Index\x20\x27','[okdb]\x20shutdown\x20took\x20too\x20long,\x20force-exiting\x0a','email','bus:proc','expiry','access-control-allow-credentials','\x20(expires\x20in\x20','stopping','\x0a[okdb]\x20error:\x20','indexToDb','unknown','--help','Lax','memoryUsage','exposeHeaders','exportBlobs','workers','[okdb]\x20blobs:\x20imported=','\x20oldestPendingMs=','\x0a\x20\x20✓\x20License\x20already\x20stored\x20(no\x20change)','base64','test','backup','__OKDB_PUB_FINGERPRINT__','_resolveEnv','\x20\x20\x20\x20•\x20a\x20license\x20id\x20\x20\x20\x20\x20(uuid)','exclusiveStart','\x20\x20\x20\x20\x20\x20','system:clock_change','searchParams','_lastTick','LICENSE_EXPIRED_ACTION','system:env_release','[okdb]\x20error:\x20--grants\x20must\x20be\x20valid\x20JSON\x20object','\x27\x20on\x20type\x20\x27','1558350Ordchh','OKDBInvalidValueError','headers','killable','signalWant','_userRouteCount','clearLine','pathParams','scanned','putSync','USE','License\x20signature\x20invalid:\x20','closed','status','FOREIGN_KEY_DELETE_RESTRICTED','sub','BAD_HOST','_nodeDbFor','\x20file','isEnabled','segments\x20(','[okdb]\x20restoring\x20','[okdb]\x20invalid\x20config\x20\x22http.host\x22:\x20','maxMs','\x20\x20✓\x20marked\x20for\x20a\x20new\x20identity\x20—\x20the\x20first\x20open\x20gives\x20this\x20copy\x20its\x20own\x20node\x20id','enable','x-requested-with','runInNewContext','_startHeartbeat','_bpWaiters','getAuthOptions','1ofN:','\x20worker\x20slot=','main','_maybePublish','\x22:\x20','detectInputType','writeFileSync','INTERNAL_ERROR','_totalReads','\x20—\x20','_blobsDir','FTS_DROP',';\x20Expires=','x5c','system:type_drop','authenticateToken','data.mdb','prependListener','events','dirname','SIGTERM','setDesired','cors','pipe','INDEX_ALREADY_REGISTERED','LICENSE_ACTIVATION_INVALID','cpus','integer','files/','tokenUrl','\x20\x20changes=','resolveBackupDest','--prefix','state','VALIDATION_ERROR','Validation\x20failed','ftsName','Create,\x20delete,\x20and\x20compact\x20environments.','./okdb-export.ndjson','\x20\x20\x20\x20-\x20The\x20activation\x20token\x20has\x20expired\x20—\x20request\x20a\x20fresh\x20one.','writeUInt8','_rootDb','__vocab/version','is\x20required','\x20\x20scanned\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','level:\x20info','configureAuth','\x20named\x20by\x20okdb\x20≤\x202.4.0)','\x20\x20\x20\x20status:\x20\x20\x20\x20active','active','--password','(none)','use\x20<env>','_enforceOperationAccess','--force','reidentify','magenta','\x20allocated','_oidcDiscoveryCache','yellow','importFromFile','base64url','not\x20open','getRange','_refreshDesiredSnapshot','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20show\x20API\x20docs\x20for\x20a\x20path\x0a\x0a\x20\x20','line','init','kdb_admin_oauth_state','[okdb]\x20cluster\x20close\x20error:\x20','wrong_node','existsSync','\x20\x20Build:\x20\x20\x20key\x20fingerprint\x20','\x1b[36m','_copyDir',',\x20signal=','RSA-SHA256','\x20\x20Some\x20checks\x20failed.\x0a','https:','safety','capable\x20HTTP\x20worker(s)\x20serving\x20:','removeLicense','ttl:set','Pause/resume\x20processor,\x20trigger\x20backups,\x20restore.','[filter]','_dedupeKey','\x27\x20doesn\x27t\x20exist','claimGated','_heartbeatTimer','internal','Token\x20secret\x20not\x20configured','\x20\x20\x20\x20expires:\x20\x20\x20','\x0a\x20\x20Delete\x20ALL\x20data\x20in\x20','\x22\x20matches\x20','responseStatuses','HTTP\x20','import','\x20\x20✗','onThreadExit','[okdb-cluster]\x20worker\x20pid=','querySchema','REQUEST_TIMEOUT','include','\x20not\x20found','\x0a\x20\x20Invalid\x20JSON:\x20','\x0d[okdb]\x20blobs:\x20','UNAUTHORIZED','readdirSync','/([^/]+)','bodyMode','_wantDb','Cannot\x20set\x20enforce\x20schema\x20on\x20','\x20\x20\x20\x20permissions:\x20','fts:','permissions','\x22.\x20Use:\x20create,\x20list,\x20revoke','\x20\x20Usage:\x20okdb\x20license\x20[<blob|path|uuid|activation-token>]','?\x0a\x20\x20(node\x20identity\x20and\x20licenses\x20are\x20preserved)\x0a\x20\x20Type\x20\x22yes\x22\x20to\x20confirm:\x20','--eval','enabled','hasOwnProperty','Register/update/delete\x20types,\x20register/drop/rebuild\x20indexes,\x20set\x20TTL\x20policy.','Peer','open','columns','createWriteStream','boolean','licenses','pending','ITEM_REMOVE','isDead','\x20\x20·\x20','white','JWT\x20expired','_committed','clear','sourceType','\x20\x20\x20\x203.\x20Run:\x20\x20okdb\x20license\x20<activation-token>','envs=','val','handle','LABEL','Type\x20\x27','.\x20Move\x20it\x20away\x20first\x20to\x20use\x20the\x20copy.','foreignOwner','enforce','race','\x20—\x20set\x20OKDB_DIAG_STACK=1\x20to\x20name\x20the\x20call\x20site','create','must\x20be\x20','_nodeDb','OKDB-PIN-V1:','(unset)','--name','unclaimed','List,\x20download,\x20and\x20inspect\x20file\x20metadata.','requests','indexes','work','att','Unique\x20constraint\x20violated\x20on\x20','\x20\x20✓\x20database\x20opened\x0a','x-okdb-raw-response','isActive','stop','signingInput','parkedNow','okdb','_draining','licensee','pathname','_listenAddr','ms\x20—\x20giving\x20up\x20on\x20this\x20slot;\x20','protected:write','loadEnvFile','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20show\x20active\x20environment\x20+\x20list\x20all\x20envs\x0a\x20\x20','unshift','content-type','INDEX_PROGRESS','~lock','Either\x20the\x20build\x20was\x20made\x20with\x20a\x20different\x20keypair,\x20or\x20the\x20license\x20was\x20issued\x20with\x20a\x20different\x20private\x20key.','groups','single','already\x20in\x20use','export','targetKey','\x20\x20\x20\x202.\x20The\x20vendor\x20returns\x20an\x20activation\x20token.','Hint:\x20',':want','node:events','toString','doctor','promises','Protected\x20(gate)','port\x20','bind','\x20for\x20commands,\x20','type/users/query\x20{\x22active\x22:true}','GET','routes','ALREADY_EXISTS','setupPrimary','../','\x22\x20is\x20used\x20by:\x20','log','hostname','terminal','trimStart','node:crypto','namespace','_rowKey','port','LICENSEE','slot','\x20writes\x20(','worker','retiring','code','emit','SHM_SEGMENT_RETIRING','processingSig','\x0a\x20\x20Usage:\x20use\x20<env-name>\x0a','limits','toISOString','_db','childTransaction','set-cookie','\x22\x20—\x20choose\x20a\x20directory\x20outside\x20it','_drainOne','addLicense','min','NOT_FOUND','_processStartedAt','migrate','\x20\x20║','shmbuf.node','[okdb]\x20export\x20complete','__okdbSlot','admin','_desiredOverlay','listDesired','METHOD_NOT_ALLOWED','[okdb]\x20failed\x20to\x20parse\x20config\x20file\x20','params','crypto','preferred_username','_listTypes','realpathSync','forceAfterMs','removeSupervisedChild','_nestedTotal','OKDBIndexNotRegisteredError','_singletonLock','\x20\x20\x20\x20status:\x20\x20\x20\x20active\x20\x20(','Forbidden\x20—\x20requires\x20','items','[okdb]\x20backing\x20up\x20to\x20','_normalizeOAuthAuthResult','DELETE\x20type/users/item/x','processorId','\x20\x20\x20\x20path:\x20\x20\x20\x20','\x20licenses','guards','listen','OKDBUniqueConstraintError','\x20\x20\x20\x20name:\x20\x20\x20\x20\x20\x20\x20\x20','cookies','quit','[body]','OKDBTypeNotRegisteredError','56898iirYDc','ms\x20busy=','\x20—\x20type\x20env\x20to\x20list\x20available\x0a','filter','verifyCookie','commitP99Ms','HTTP_','instances','\x20(okdb\x20','hint','\x20result','\x20\x20\x20\x20features:\x20\x20','noRepl','decodeActivationToken','\x1b[33m','update',',\x20got\x20','library\x20(okdb\x20node-model\x202.0).\x20For\x20multi-process\x20HTTP\x20serving\x20use\x20the\x20okdb\x20','[okdb]\x20invalid\x20port:\x20','der','resume','Events','details','\x1b[90m','--no-admin','\x0a\x20\x20okdb\x20doctor\x0a','split','Views','decommission','mkdirSync','sync','access','alloc','\x20@\x20','_shouldWrapResponse','alg','ref:violation','SERVICE_UNAVAILABLE','extend','schema','processors/','\x22\x20resolves\x20outside\x20the\x20backup\x20root\x20\x22','_singletonLocks','sizeBefore','api','cluster',':\x20expected\x20','disconnect','_authOptions','fts','[okdb]\x20preserved:\x20','\x20<path>\x20[json-body]','.\x20Add\x20a\x20license\x20that\x20includes\x20\x22','_fetchJwks','\x0a[okdb]\x20received\x20','revoke','usage:\x20okdb\x20restore\x20<backup-dir>\x20--path\x20<target-data-dir>','removeNode','flushDebounce','Token\x20must\x20be\x20a\x20JWT','\x1b[0m','processor:error','Content-Type','info','importBlobs','_onProcEvent','\x20opening\x20','\x20files)','\x20\x20(licensee:\x20','search:query','SYSTEM_STOPPED','[okdb]\x20.kdbconfig\x20already\x20exists\x20—\x20skipping','cpuPct','\x22\x20→\x20','readMs','node:perf_hooks','\x20entries\x20in\x20','withPoolHold','OKDBInvalidIndexKeyError','lost','[okdb]\x20error:\x20no\x20license\x20with\x20id\x20\x22','setSchema','forEach','\x20parkedNow=','\x20\x20✓\x20joined\x20and\x20reconciliation\x20initiated','\x20\x20✓\x20Removed\x20license\x20','shm-gc:\x20unknown\x20argument\x20','issueToken','middlewares','decodeLicenseBlob:\x20failed\x20to\x20decode\x20payload:\x20','\x0a[okdb]\x20force-exiting\x20(second\x20interrupt)\x0a','Read','Sync','POST','isBusy','current','closeIdleConnections','token_endpoint','\x20to\x20quit.','./okdb-data','type/','zero_refs','inputSchema','operations','_licenseHash','push','\x0a\x20\x20[okdb]\x20force-exiting\x20(second\x20interrupt)\x0a',';\x20Max-Age=','\x20freed','\x0a\x20\x20\x20\x20','[okdb]\x20closed\x20cleanly\x0a','\x20months\x20from\x20issuance)','cause','release','claims','publishChildRow','\x22\x20on\x20\x22','ACTIVATION_EXPIRED','dest','--log-requests','_countFileRefs','--address','shell','envName','processes:\x20','tierList','_enableChangelog','.log','_totalReadMs','[okdb]\x20unknown\x20token\x20action:\x20\x22','issuedAt','label','Release','Access-Control-Request-Headers','noteListenAddr','\x20\x20(need\x20≥\x2018)','_activateProcessesReader','Internal\x20error','lstatSync','hex','INDEX_HAS_CONSUMERS','_sandbox','CONFLICT','--permissions','utf8','node/','functions','required','is\x20invalid','type/users/item/alice','copyFileSync','/dev/shm','halted','[okdb]\x20opening\x20','matched','CHANGEFEED_QUANTUM','byteLength','[okdb]\x20created\x20./okdb-data','data','param','decommissioned','assertLimit','is\x20not\x20allowed','\x20\x20skipped=','\x20stays\x20down\x20on\x20boot\x20(durable\x20decommission)','\x20HTTP\x20workers\x20','Unsupported\x20JWT\x20alg:\x20','licensed','\x20\x20\x20\x20id:\x20\x20\x20\x20\x20\x20\x20\x20','isArray','reportThreadStats','\x0a\x20\x20\x20\x20\x20\x20','ttl:expired','server','prompt','Payload\x20too\x20large','http://','SCHEMA_COLLECTION_INVALID','cluster:\x20unavailable\x20(shmbuf\x20native\x20missing)\x20—\x20running\x20single-process','splice','creating','_buildOwnRow','_flushDebounce','BAD_REQUEST','[on|off|level]','raw','isWanted','Enqueue,\x20cancel,\x20retry,\x20remove\x20jobs;\x20manage\x20buckets;\x20reconcile\x20and\x20rebuild\x20stats.','NOT_IMPLEMENTED','item:update','remove','mcp-session-id','\x20\x20\x20\x20envs:\x20\x20\x20\x20\x20\x20','_buildChildRow','Open\x20licenses\x20cannot\x20exceed\x206\x20months\x20duration\x20(this\x20license\x20expires\x20','help','ms\x20max=','\x1b[34m','red','hash','\x20bytes,\x20need\x20>=\x2065)','null','decommissioning','[okdb-cluster]\x20primary\x20pid=','some','http-server','_lastPublishAt','size','BACKUP_DEST_INSIDE_STORE','dbPath','[okdb]\x20nothing\x20to\x20reset\x20—\x20','SWAP','running','isBuffer','config\x20file\x20invalid:\x20','\x20│\x20','dead','abs','\x20HTTP\x20workers,\x20each\x20serves\x20+\x20processes)','[okdb]\x20error:\x20ambiguous\x20prefix\x20\x22','\x20statusEnv=','⚠\x20INTERNAL\x20LICENSE\x20ACTIVE\x20—\x20all\x20features\x20and\x20limits\x20are\x20unlocked.\x20For\x20vendor/internal\x20use\x20only.','\x20tokens:','isSystem','Version\x20mismatch\x20for\x20','\x20(slot=','function','bootstrapBlocked','[res]\x20','once','authMode','_outstanding','\x22\x20in\x20env\x20\x22','platform','blobs','JWT\x20not\x20yet\x20valid','reason','_supervisorKey','_released','signature','indexOf','\x0a\x20\x20No\x20routes\x20matching\x20\x22','\x20(durable\x20desired-state)','REMOVE','parseInt','_writer','hasCanonical','Background\x20job\x20queue:\x20enqueue\x20work,\x20observe\x20state,\x20and\x20process\x20jobs.','run','CREATED','noCluster','mode','_instanceId','req','_lookupByName','\x20uses\x20raw\x20bodyMode\x20without\x20addRaw/raw\x20route\x20metadata','stop\x20every\x20okdb\x20process\x20on\x20this\x20path\x20and\x20run\x20`okdb\x20shm-gc`.','holder','type/users\x20--help','\x20\x20→\x20\x20','cookieName','randomUUID','operation','listening','hasLimit','Indexes','change','license','engines','length','candidatesLegacyNamed','\x20\x20✓\x20Revoked\x20token\x20','slotKey','matcher','mcp','unlinkSync','created','paused','compaction','send','\x20license\x20—\x20no\x20activation\x20needed)','isAuthenticated','cyan','offWindow',']:\x20transaction\x20ran\x20nested\x20inside\x20a\x20write\x20txn\x20held\x20open\x20by\x20a\x20non-writer\x20caller','_getType','allowMethods','_onPoke','other','_onItem','valid','_collectWriterFacet','_ensureDesired','OKDB_HTTP_WORKERS','caps','content-length','draining','\x20\x20\x20\x20\x20explicit\x20method\x0a\x0a\x20\x20','--label','procmode/','isHeld','workersFlag','Blob\x20file\x20missing\x20for\x20~files\x20record\x20\x22','GATEWAY_TIMEOUT','[okdb]\x20import\x20complete','\x1b[31m','--config','schema:drop','resetIndex','LICENSED_BUILD','call','\x20phase=','cf-ray',';\x20Max-Age=0;\x20Expires=Thu,\x2001\x20Jan\x201970\x2000:00:00\x20GMT','ensureType','parts','createHash','fts:registered','https','Forbidden','\x20worker(s)\x20still\x20serving','field:resolver_registered','okdb-backup-','process','_heartbeatInFlight','\x20does\x20not\x20exist','jwk','createInterface','_wantDbOf','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20set\x20active\x20environment\x20(persists\x20in\x20session)\x0a\x20\x20','writeUInt16BE','env/:env','readUInt8','internalOnly','Operator\x20surface:\x20server\x20info,\x20logs,\x20event\x20streams,\x20processor\x20status,\x20backups.','tryAcquire','setTtl','version','\x20\x20Common\x20causes:','\x20active\x20env:\x20','unique:violation','\x20worker','statusCode','singletonClaims','default','add','[okdb]\x20shutdown\x20drain\x20exceeded\x203000ms\x20—\x20hard-exiting\x0a','query.','\x20has\x20canonical\x20metadata\x20but\x20missing\x20valid\x20inputSchema','DELETE','records','bold','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20→\x20GET\x20/api/env/','_desired','\x20size,\x20','\x22\x20has\x20been\x20retiring\x20for\x20','config','(workers\x20can\x27t\x20share\x20the\x20cross-process\x20HLC/clock).\x20Forcing\x20single-process\x20(was\x20','drop','_totalWriteMs','views','oldestPendingMs','authRequired','x-forwarded-for','Run','_activateProcesses','\x20\x20\x20\x20port:\x20\x20','isFinite','argv','list','License\x20expired\x20or\x20invalidated','\x20more)','green','VERSION_MISMATCH','\x20records…','\x22\x20(hash:\x20','\x20\x20⚠','[okdb-cluster]\x20slot=','.kdb_history','_lockDb','stdin','\x20\x20\x20http://localhost:','stopHeartbeat','processing','notOkdbShaped','identity',':\x20connected\x0a\x0a','type/users','putNode','May\x20write\x20system\x20types\x20when\x20also\x20granted\x20the\x20underlying\x20write\x20permission.','replace','uptime','readFileSync','toUpperCase','host','read','search','\x27\x20is\x20already\x20registered','\x20\x20✓\x20OKDB\x20server\x20running','authorizationUrl','geo',').\x20If\x20none\x20of\x20them\x20runs\x20okdb,\x20pass\x20--force;\x20','errors','net','_clusterOrphanWatch','maxWrites','_userPhase','(null)','--log-level','types','_log','isWorker','ms\x20p99=','\x20has\x20illegal\x20binding\x20target\x20for\x20','startsWith','regex','\x22\x20—\x20pass\x20a\x20path\x20relative\x20to\x20it\x20(configure\x20with\x20the\x20`backup.root`\x20option)','\x20pid=','cluster:','bindings','Environments','kill','onRetiring','[okdb]\x20imported\x20\x20types=','all','audiences','\x20has\x20ambiguous\x20binding\x20for\x20query\x20field:\x20','okdb-writer:\x20env\x20closing\x20—\x20retry','_lock','decodeLicenseBlob:\x20input\x20must\x20be\x20a\x20string','processors','OPTIONS','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20→\x20GET\x20/api/info\x0a\x20\x20\x20\x20','listLicenses','_totalErrors','closeSync','backup\x20destination\x20\x22','\x20\x20note:\x20','isInteger','quantum','flushed','Work','Activation\x20invalid:\x20','JWT\x20audience\x20mismatch','\x20\x20\x20\x20api:\x20\x20\x20http://localhost:','publishOwnRow','register','close',');\x20','cf-connecting-ip','_selfKey','\x20\x20\x20\x20graceful\x20shutdown\x0a','--key','\x20cf-ray=','Unauthorized','_typeSchema','[okdb]\x20error:\x20token\x20with\x20name\x20\x22','_putRowAsync','epoch','\x20\x20(+\x20time-machine)','_changefeed','store','params.','debug','index:drop','onLicenseExpired','clearCookie','put','Foreign\x20key\x20violation:\x20','array','key','sig','dropExisting','has','external','active:','\x20\x20\x20\x20port:\x20\x20\x20\x20','\x20document(s)\x20reference\x20it\x20with\x20onDelete:restrict','field','xdg-open\x20','\x20\x20\x20\x20usage:\x20\x20\x20','trim','--types','readUInt32BE','derived;\x20rebuilt\x20from\x20source\x20docs\x20on\x20first\x20open\x20of\x20the\x20restored\x20store','\x20\x20unused\x20(deletable)\x20','SIGKILL','participate','reset','/.well-known/openid-configuration','[okdb]\x20error:\x20revoke\x20requires\x20an\x20id\x20argument','finish','\x20(dry\x20run)','_bestMatch','reduce','refs','\x20drainAge=','HEAD','importJSON','_put','entry','padEnd','mixed\x20versions\x20on\x20one\x20store\x20are\x20unsafe\x20across\x20storage\x20migrations;\x20align\x20versions\x20before\x20upgrading\x20further.','\x1b[35m','--env','\x20\x20\x20\x20writes:\x20\x20\x20\x20','address','types/env=','/\x20quit\x20/\x20Ctrl+C','[okdb-cluster]\x20change-feed\x20init\x20failed:\x20','\x20\x20\x20\x20-\x20The\x20activation\x20token\x20was\x20issued\x20for\x20a\x20different\x20node\x20—\x20share\x20this\x20node\x27s\x20PIN\x20with\x20the\x20vendor.','assertFeature','typesPerEnv','EXPIRES','error','--any-size','processKey','License\x20signature\x20invalid\x20—\x20this\x20license\x20was\x20not\x20signed\x20by\x20the\x20key\x20paired\x20with\x20this\x20build.\x20','execArgv','heapUsed','scope','LENGTH_REQUIRED','\x20(must\x20be\x20an\x20integer\x20>=\x201)\x20—\x20using\x201','Shutting\x20down\x20due\x20to\x20license\x20expiry','getCmd','set','License\x20limit\x20exceeded:\x20','Blob\x20on\x20disk\x20has\x20no\x20~files\x20record\x20in\x20any\x20env\x20(hash:\x20','logLevel','__identity','skip\x20','-----BEGIN\x20CERTIFICATE-----\x0a','_matchRoute','ITEM_PENDING','ver','rawBuf','\x20\x20Expected\x20one\x20of:','Auth','_publishFailWarned','\x0d[okdb]\x20','time','uuid','\x20(passive),\x20','ORPHAN\x20(env-closed\x20write,\x20unhandledRejection)','pin','ephemeral','inflightAgesMs','ENVS','\x20documents\x20fail\x20validation','tokenTtl','updateSupervisedChildStats','processor:progress','--prefix=','BACKUP_DEST_NOT_EMPTY','okdb-license-id:','linux','BACKUP_PATH_OUTSIDE_ROOT','verbose','undefined','node\x20','getDesired','decodeLicenseBlob:\x20blob\x20too\x20short\x20(','\x20logs\x20on\x20\x20','readlinkSync','\x20process(es)\x20that\x20could\x20map\x20these\x20','path',',\x20label:\x20','none','markClosed','ready','view:progress','reap','LICENSE_HASH_MISMATCH','\x20\x20(no\x20env\x20draining)','received\x20','no\x20.kdbconfig\x20(using\x20defaults)','committed','summary','remoteAddress','\x20\x20\x20\x20pin:\x20\x20\x20\x20\x20\x20\x20','registerFts','cpuUsage','sse','remaining-fields','\x0a\x0a\x20\x20','repeat','must\x20not\x20be\x20null','setOwnMeta','OKDBForeignKeyDeleteError','\x20\x20Example:\x20okdb\x20join\x20https://node-a.example.com\x20--token\x20<t>\x20--address\x20http://myhost:8484\x0a','ieee-p1363','~processes:desired','PUB_FINGERPRINT','../okdb','detachConsole','SCHEMA_VALIDATION_FAILED','files','jwksTtlMs','_handlePending','exit','readInt32LE','listAll','pushEphemeral','clockToChangeDb','payload','index:progress','handler','INDEX_REGISTERED','--open',']\x20already\x20maps\x20to\x20\x27','Route\x20',';\x20HttpOnly','hidden','Records\x20inside\x20your\x20types\x20—\x20the\x20actual\x20rows\x20you\x20store.','_highWater','_getOidcDiscovery','writes=','transaction','List\x20functions\x20and\x20inspect\x20their\x20source.','__okdbCluster','body','_closed','INVALID_INDEX_KEY','kid','exportToStream','\x0a\x20\x20✓\x20Token\x20created','_wrapApiResponse','/types\x0a\x20\x20\x20\x20','connection','1083548bETSHj','~licenses','\x20\x20\x20\x20license:\x20⚠\x20OPEN\x20—\x20','\x20\x20\x20\x20status:\x20\x20\x20\x20','uncaughtException','_dispatch','[okdb]\x20error:\x20--password\x20requires\x20--name','standalone','no-cache,\x20no-transform','Examples','invalid','inst:','_license','ITEM_CREATE','_rawDb','Server-side\x20user-defined\x20functions\x20registered\x20per\x20environment.','license:removed','License\x20already\x20stored','closing','options','okdb.http.listen(port)\x20in\x20each\x20worker.','_assertUsable','derivePin','FOREIGN_KEY_VIOLATION','parseBearer','\x20\x20in\x20use\x20(mapped/fd)\x20','restore','_baselines','(?:/(.*))?$','\x20\x20Shell\x20commands','processor:paused','registry\x20publish\x20failing:\x20','node\x20identity','\x20\x20[okdb]\x20shutdown\x20took\x20too\x20long,\x20force-exiting\x0a','\x20\x20\x20\x20label:\x20\x20\x20\x20\x20\x20\x20','shm-gc','failures','toUTCString','_cmd','~tokens','statSync','ttlMs','\x20\x20\x20\x20id:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','transport:\x20','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20→\x20GET\x20/api/env/','\x20days\x20—\x20POC/demo\x20only,\x20not\x20node-bound)','constructor','fts:drop','LICENSE_FEATURE_DISABLED','\x20\x20(unlimited)','fast','Validation\x20failed:\x20','--path','[okdb]\x20error:\x20','config\x20file\x20valid:\x20','__fts:','rows=','--version','OKDBAlreadyExistsError','threadId','attachFeed',',\x20stopping\x20workers…\x0a','[okdb]\x20error:\x20unrecognized\x20input:\x20\x22','Invalid\x20index\x20key\x20type\x20for\x20\x27','outputSchema','_cursors','allocUnsafe','--workers','opendirSync','anySize','password','OKDBForeignKeyError','record','Server\x20is\x20in\x20bootstrap\x20mode\x20and\x20only\x20accepts\x20localhost\x20connections\x20until\x20the\x20first\x20token\x20is\x20created.','\x20day(s).','_isOpen','darwin','activation','The\x20following\x20routes\x20require\x20auth\x20but\x20declare\x20no\x20permission:\x0a\x20\x20','/proc','[req]\x20','_groupByProcess','Bearer\x20','unlinked','_scheduleFlush','expired','_validateOperationRequest',';\x20Path=','--dry-run','allowHeaders','--token','[okdb]\x20invalid\x20config\x20\x22','procmodeack/','listRoutes','sourceKey','\x20SECURITY\x20NOTICE','destroy','\x20\x20⚠\x20\x20','off','prototype','unhandledRejection','openDB','TiB','\x20supervised)','_durs','ppid','Types','start','\x27\x20already\x20registered','[okdb]\x20backup\x20complete','username','\x20(deleting\x20requires\x20--force\x20if\x20none\x20of\x20them\x20is\x20okdb)','free\x20tier','\x0a[okdb]\x20fatal\x20error:','_timer','_startAdmission','\x20(must\x20be\x201–65535)','expiresAt','child_process','_runGuards','INDEX_RESET','_quantum','_publishNow','MAX_POOL_HOLDS','match','Engines','SIGBREAK','system:bus_state_change','BACKUP_MANIFEST','\x20\x20·\x20\x20','_openEnvLazy','scopes','_started','Unknown\x20error','_inflight','licenseHash',':\x20ping\x0a\x0a','_lastCpuAt','processor:ready','candidateAllocated','values','SYNC_COMMITS','copy','blocks','never','otherwise\x20rerun\x20as\x20root.','_sampleOwnStats','compareExchange','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20show\x20this\x20help\x0a\x20\x20','allowedAlgs','\x20\x20http://localhost:','\x20bytes','_handlePoke','removeSync','present','inUse','result','makeOkdb','known\x20field','\x20environment\x20','consumeLoginState','_isStale','decodeLicenseBlob','\x20\x20Usage:\x20logs\x20[on|off|debug|info|warn|error]','\x1b[1m','target\x20','liveThreadStats','_ensure','history','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20open\x20admin\x20UI\x20in\x20browser\x0a\x20\x20','auth=','params.env','ENV','exportJSON','clearThreadStats','No\x20license\x20found\x20matching\x20this\x20activation\x20token','uid','Origin','isConnected','\x27,\x20cannot\x20map\x20to\x20\x27','__writeCounter','getSecurityNotices','\x20\x20(press\x20Ctrl+C\x20again\x20to\x20exit)\x0a','_systemEnv','tags','onMapped','shm\x20segment\x20','unique:violation_resolved','stringify','[okdb]\x20error:\x20failed\x20to\x20read\x20','available','isFeatureEnabled','next','-backups','depth','\x20\x20\x20\x20•\x20a\x20license\x20blob\x20\x20\x20(Crockford\x20base32,\x20~150–250\x20chars)','processes','types\x20--env\x20staging','envs','Usage:\x20okdb\x20shm-gc\x20[--dry-run]\x20[--prefix\x20<p>]\x20[--any-size]\x20[--force]\x20[--verbose]\x0a\x0aDelete\x20okdb\x20shared-memory\x20segments\x20in\x20/dev/shm\x20that\x20no\x20live\x20process\x20maps\x20or\x20holds\x20open\x0a(older\x20okdb\x20versions\x20never\x20unlinked\x20them).\x20Recognises\x20both\x20the\x20current\x20hashed\x20names\x0a(<path>-<hash>)\x20and\x20the\x20bare-path\x20names\x20of\x20okdb\x20<=\x202.4.0.\x20Linux\x20only.\x0a\x0a\x20\x20--dry-run,\x20-n\x20\x20\x20report\x20what\x20would\x20be\x20deleted,\x20delete\x20nothing\x0a\x20\x20--prefix\x20<p>\x20\x20\x20\x20only\x20names\x20starting\x20with\x20<p>\x20(default\x20\x22-tmp-\x22:\x20stores\x20under\x20/tmp;\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x22\x22\x20=\x20every\x20okdb-shaped\x20name)\x0a\x20\x20--any-size\x20\x20\x20\x20\x20\x20don\x27t\x20require\x20an\x20okdb\x20segment\x20size\x0a\x20\x20--force\x20\x20\x20\x20\x20\x20\x20\x20\x20delete\x20even\x20if\x20some\x20same-user\x20process\x27s\x20maps\x20could\x20not\x20be\x20read\x0a\x20\x20--verbose,\x20-v\x20\x20\x20print\x20every\x20kept\x20segment\x20and\x20why','~processes:cmd','\x20\x20kept\x20(attached/retiring\x20when\x20retired)\x20','\x20\x20✗\x20','[okdb]\x20reset\x20aborted','\x20(other\x20users;\x20cannot\x20map\x200600\x20segments)','validateBlobIntegrity','issuer','object','_rotateBucket','_held','\x20which\x20does\x20not\x20exist','_allEnvsWithFiles','registry\x20heartbeat\x20skipped\x20(writer=','No\x20tokens.','category','okdbVersion','sync-node','features','maxAge','typesDb','access-control-max-age','fanout','segmentNameFor:\x20canonicalPath\x20must\x20be\x20a\x20non-empty\x20string','PUBLIC_KEY_PEM',':\x20mapped\x20','message','instanceId','\x20MB)','floor','\x20\x20\x20\x20\x20http://localhost:',')\x20to\x20your\x20license\x20vendor.','set\x20OKDB_DIAG=1\x20(and\x20OKDB_DIAG_STACK=1\x20to\x20name\x20write\x20sites)','stack','hdr','cpSync','_drain','\x22\x20is\x20inside\x20the\x20store\x20\x22','\x20\x20#','2.6.0','_adminRelay','GiB','_versionSkewWarned','\x20\x20No\x20licenses\x20stored.\x20Use\x20`okdb\x20license\x20<blob>`\x20to\x20add\x20one.','type/users/item/alice\x20--env\x20staging','EADDRINUSE','\x20\x20✓\x20','\x20/\x20','logs','item:remove','\x20\x20Next\x20step\x20—\x20activate\x20the\x20license:','children','onWindow','transport','LICENSE_INVALID','audience','ttl','OKDB_CODE_TO_HTTP_STATUS','ITEM_UPDATE','id:\x20','\x20\x20env=','stats','licenseType','_totalWrites','payload-or-self','rss','\x20\x20\x20\x20\x20\x20\x20','time-machine','keys/public.pem','rowKey','ES256','revived','[env]','12UGDXxs','clusterWorkers','PIN','catch','system','ms\x0a','drain','QUIT','entries','relative','_onPending','\x20lived\x20outside\x20the\x20store\x20at\x20','MALFORMED_TOKEN','\x22\x20(must\x20be\x20debug|info|warn|error)','connected','clearTtl','\x20\x20Writes:\x20\x20','_nodeDbCache','_markSeen','verifySignature','processor:retry','[okdb]\x20warning:\x20could\x20not\x20read\x20node\x20identity/licenses\x20before\x20reset\x20(','confirm','online','url','OKDBIndexHasConsumersError','starting','\x20sync','migrations','header','origin','token_use','setHeader','Invalid\x20token','ms\x20env=','UNPROCESSABLE_ENTITY','\x20\x20Tier:\x20\x20\x20\x20','ENV_CLOSING_RETRY','servers','~processes','busy','standard','ms\x20mean=','assign','charCodeAt','types:','_admissionTimer','\x20in\x20','_lastCpuPct','613180HYVslG','sha256','OKDBVersionMismatchError','\x22\x20is\x20not\x20empty\x20—\x20backups\x20never\x20overwrite;\x20choose\x20a\x20new\x20directory','\x20has\x20unbound\x20input\x20fields\x20with\x20bodyMode:none:\x20','[okdb]\x20error:\x20no\x20token\x20with\x20id\x20\x22','_envs','queue-worker','Machine-to-machine\x20cluster\x20protocol\x20(join\x20handshake,\x20replication\x20channel,\x20traffic).\x20Grant\x20only\x20to\x20peer\x20nodes\x20—\x20not\x20to\x20humans.','[okdb]\x20warning:\x20failed\x20to\x20restore\x20identity/licenses\x20after\x20reset:\x20','-tmp-','respawnTimer','\x20\x20Note:\x20this\x20node\x20has\x20existing\x20tokens.\x20They\x20will\x20coexist\x20with\x20cluster\x20tokens\x0a','--no-cluster','VERB','_pendingLocal','\x20\x20\x20\x20path:\x20\x20','[okdb]\x20./okdb-data\x20already\x20exists\x20—\x20skipping','_putRowSync','ftruncateSync','Blob\x20ref-count\x20is\x20zero\x20for\x20~files\x20record\x20\x22','fts:reset','_active','isAbsolute','Functions','KiB','grants','uri','resetReadTxn','3816MzJaug','Cannot\x20delete\x20','\x20\x20\x20\x20\x20\x20\x20POST\x20(body\x20implies\x20POST)\x0a\x20\x20','\x0a\x20\x20✓\x20License\x20activated','stream','~system','[okdb]\x20error:\x20show\x20requires\x20an\x20id\x20argument','drain\x20state\x20(envs\x20with\x20a\x20non-zero\x20drain):','_bpParkedTotal','\x20\x20\x20\x20\x20\x20\x20\x20\x20browse\x20API\x20routes,\x20grouped\x20by\x20area\x0a\x20\x20','/type/users\x0a\x20\x20\x20\x20','fromEntries','type','getClock','_statusEnv','7820491USXovf','FTS_REGISTERED','digest','\x0a\x20\x20No\x20documentation\x20found\x20for:\x20','ingest','_windowCbs','_isFree','_acquiredAt','targetType','getuid','level','\x20on\x20this\x20data\x20path\x20runs\x20okdb\x20','%),\x20','route','getKeys','_threadStats','_lastCpuWindowMs','feed:','query','createServer','primaryOkdb','dryRun','logRequests','PATCH','_isReader','ttl:clear','max','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20→\x20GET\x20/api/envs\x0a\x20\x20\x20\x20','node','System','from','methods','gate','reverse','\x20\x20(name:\x20','[okdb]\x20created\x20.kdbconfig','ESRCH','Processors','startedAt','basename','_collectSingletonClaims','_jwksCache','\x20\x20\x20\x20api:\x20\x20\x20\x20\x20http://localhost:','bus:type_drop','exp','precision','_computeStatus','files\x20feature\x20not\x20available','\x20log\x20level:\x20','\x20(+','--new-identity','event:\x20','system:proc','warn','Files','\x20\x20after\x20sync.\x20Duplicate\x20names\x20will\x20surface\x20as\x20ambiguous\x20logins\x20to\x20clean\x20up.','\x20(deleted)','afterWrite','embeddings','count','Invalid\x20license\x20blob:\x20','number','fields','\x20is\x20not\x20empty\x20—\x20restore\x20only\x20into\x20a\x20new\x20or\x20empty\x20directory','metrics','/api/','127.0.0.1','\x20\x20not\x20okdb-shaped\x20\x20\x20\x20','padStart','threads','changes','shmbuf/package.json','decodeActivationToken:\x20expected\x2077\x20bytes,\x20got\x20','nbf','blob\x20status\x20db\x20not\x20available','flatMap','every','event','_enqueuedAt','cpuWindowMs','[okdb]\x20error:\x20--address\x20is\x20required\x20for\x20join\x20(this\x20node\x27s\x20reachable\x20sync\x20address).\x0a','ceil','--inspect','lmdb','_runMiddlewares','_coordinator','comm','[okdb]\x20close\x20error:\x20','_lastCpuUsage','writerStatus','\x20already\x20in\x20use','INVALID_VALUE','geoConfig','JWT\x20is\x20missing\x20kid','_sockets','\x20\x20\x20\x20limits:\x20\x20\x20\x20','deletedAllocated','128487XHQvmC','Register,\x20update,\x20and\x20delete\x20function\x20definitions.','createHmac','item:create','tmp','keys','_nestedWarned','_loginStates','\x20\x20\x20\x201.\x20Send\x20the\x20PIN\x20above\x20(','blindCommands','deaths','verify','--no-repl','isDirectory','Not\x20Found','Gate\x20flag\x20required\x20to\x20touch\x20system\x20types\x20(those\x20whose\x20name\x20starts\x20with\x20\x22~\x22).\x20Combined\x20with\x20the\x20underlying\x20namespace\x20permission.','listNodes','_wantDbHandle','SYSTEM_POKE','ms\x20(pid\x20','writes','ms\x20activeWriters=','authorization','~blobs','decoded','scrypt','\x1b[37m','references','response','SYSTEM_PROC','heapTotal','_blobPath','.kdbconfig','_seen'];_0x166e=function(){return _0x4a4ee1;};return _0x166e();}var hasRequiredOkdbWriter;function requireOkdbWriter(){const _0x13c5b4=_0x3d20e4;if(hasRequiredOkdbWriter)return okdbWriter[_0x13c5b4(0x71d)];hasRequiredOkdbWriter=0x1;const {performance:_0x28955f}=require$$0$5,_0x4369fd=requireOkdbDiag(),_0x1ea970=process.env.OKDB_COMMIT_MODE===_0x13c5b4(0x2ae);class _0x130396{constructor(_0x387347){const _0x53e5e3=_0x13c5b4;this['env']=_0x387347,this['_inflight']=new Set(),this[_0x53e5e3(0x6c0)]=new Map(),this[_0x53e5e3(0x208)]=0x0,this[_0x53e5e3(0x56d)]=[],this['_done']=[],this[_0x53e5e3(0x4f6)]=Math[_0x53e5e3(0x68c)](0x0,Number(process.env.OKDB_WRITER_HIGH_WATER??0x400)),this['_outstanding']=0x0,this[_0x53e5e3(0x180)]=[],this[_0x53e5e3(0x66b)]=0x0,this[_0x53e5e3(0x5d6)]=null,this[_0x53e5e3(0x75c)]=0x0,this[_0x53e5e3(0x27c)]=0x0,this[_0x53e5e3(0x6d9)]=![];}async['transaction'](_0x517c7f,_0x1a8c5c,{admitted:admitted=![]}={}){const _0x51ce03=_0x13c5b4;if(_0x4369fd[_0x51ce03(0x176)]())_0x4369fd[_0x51ce03(0xa3)](this['env']?.[_0x51ce03(0x707)],_0x1a8c5c);if(this[_0x51ce03(0x4fd)]){const _0x170d2c=new Error(_0x51ce03(0x43b));_0x170d2c[_0x51ce03(0x25b)]=_0x51ce03(0x63a);throw _0x170d2c;}if(this[_0x51ce03(0x4f6)]>0x0){let _0xcb353d=![];while(this[_0x51ce03(0x377)]>=this[_0x51ce03(0x4f6)]&&!this[_0x51ce03(0x4fd)]){!_0xcb353d&&(_0xcb353d=!![],this[_0x51ce03(0x66b)]++),await new Promise(_0x5d37c0=>this['_bpWaiters'][_0x51ce03(0x2f9)](_0x5d37c0));}if(this[_0x51ce03(0x4fd)]){const _0x249a0d=new Error('okdb-writer:\x20env\x20closing\x20—\x20retry');_0x249a0d[_0x51ce03(0x25b)]=_0x51ce03(0x63a);throw _0x249a0d;}}this['_outstanding']++;const _0x38d8cd=admitted?null:this[_0x51ce03(0x124)][_0x51ce03(0x6c7)];for(;;){while(this['_held'])await this[_0x51ce03(0x5d6)];if(_0x38d8cd)try{await _0x38d8cd[_0x51ce03(0xf4)]();}catch(_0x735dc){this[_0x51ce03(0x377)]--;if(this['_bpWaiters']['length']&&this[_0x51ce03(0x377)]<this[_0x51ce03(0x4f6)])this['_bpWaiters']['shift']()();throw _0x735dc;}if(!this[_0x51ce03(0x5d6)])break;if(_0x38d8cd)_0x38d8cd[_0x51ce03(0x6ab)]();}if(this['_closed']){if(_0x38d8cd)_0x38d8cd[_0x51ce03(0x6ab)]();this['_outstanding']--;if(this['_bpWaiters'][_0x51ce03(0x39d)]&&this[_0x51ce03(0x377)]<this[_0x51ce03(0x4f6)])this[_0x51ce03(0x180)][_0x51ce03(0xfa)]()();const _0x3d5627=new Error(_0x51ce03(0x43b));_0x3d5627['code']=_0x51ce03(0x63a);throw _0x3d5627;}const _0x1c8c9d=_0x28955f[_0x51ce03(0x127)]();if(_0x1ea970)try{const _0x4f0886=this[_0x51ce03(0x124)]['db']['transactionSync'](_0x517c7f);this[_0x51ce03(0x208)]++;if(this[_0x51ce03(0x56d)][_0x51ce03(0x2f9)](_0x28955f[_0x51ce03(0x127)]()-_0x1c8c9d)>0x100)this[_0x51ce03(0x56d)][_0x51ce03(0xfa)]();if(this[_0x51ce03(0x7a)]['push'](_0x28955f[_0x51ce03(0x127)]())>0x800)this[_0x51ce03(0x7a)][_0x51ce03(0xfa)]();return _0x4f0886;}finally{this[_0x51ce03(0x377)]--;if(this[_0x51ce03(0x180)][_0x51ce03(0x39d)]&&this[_0x51ce03(0x377)]<this[_0x51ce03(0x4f6)])this[_0x51ce03(0x180)][_0x51ce03(0xfa)]()();if(_0x38d8cd)_0x38d8cd[_0x51ce03(0x6ab)]();}let _0x5286e7=null;const _0xc90c00=()=>{const _0x241db4=_0x51ce03,_0x31c276=_0x517c7f();if(_0x31c276&&typeof _0x31c276['then']===_0x241db4(0x372)&&!_0x5286e7){this[_0x241db4(0x75c)]++;let _0x43c9ea;const _0x2d1eb6=new Promise(_0x2c0eca=>_0x43c9ea=_0x2c0eca);this[_0x241db4(0x5d6)]=_0x2d1eb6,_0x5286e7=()=>{const _0x559d68=_0x241db4;if(this[_0x559d68(0x5d6)]===_0x2d1eb6)this[_0x559d68(0x5d6)]=null;_0x43c9ea();};}return _0x31c276;};let _0x257ba3;try{_0x257ba3=this[_0x51ce03(0x124)]['db'][_0x51ce03(0x263)](_0xc90c00);}catch(_0x1dd900){_0x257ba3=Promise['reject'](_0x1dd900);}(!_0x257ba3||typeof _0x257ba3['then']!==_0x51ce03(0x372))&&(this[_0x51ce03(0x27c)]++,!this[_0x51ce03(0x6d9)]&&(this[_0x51ce03(0x6d9)]=!![],console[_0x51ce03(0x6a7)](_0x51ce03(0x73a)+(this['env']?.[_0x51ce03(0x707)]??'?')+_0x51ce03(0x3ac))),_0x257ba3=Promise['resolve'](_0x257ba3));const _0x3fa521=()=>{if(_0x5286e7)_0x5286e7();};_0x257ba3[_0x51ce03(0xad)](_0x3fa521,_0x3fa521),this['_inflight'][_0x51ce03(0x3e9)](_0x257ba3),this[_0x51ce03(0x6c0)]['set'](_0x257ba3,_0x1c8c9d);const _0x33c997=()=>{const _0x550dbb=_0x51ce03;this['_inflight'][_0x550dbb(0x95)](_0x257ba3),this[_0x550dbb(0x6c0)]['delete'](_0x257ba3),this[_0x550dbb(0x208)]++,this[_0x550dbb(0x377)]--;this[_0x550dbb(0x180)]['length']&&this[_0x550dbb(0x377)]<this[_0x550dbb(0x4f6)]&&this[_0x550dbb(0x180)][_0x550dbb(0xfa)]()();if(this[_0x550dbb(0x56d)][_0x550dbb(0x2f9)](_0x28955f[_0x550dbb(0x127)]()-_0x1c8c9d)>0x100)this[_0x550dbb(0x56d)]['shift']();if(this[_0x550dbb(0x7a)]['push'](_0x28955f['now']())>0x800)this[_0x550dbb(0x7a)][_0x550dbb(0xfa)]();};_0x257ba3['then'](_0x33c997,_0x33c997);try{return await _0x257ba3;}finally{if(_0x38d8cd)_0x38d8cd[_0x51ce03(0x6ab)]();}}['status'](){const _0x1c9a31=_0x13c5b4,_0x2c709b=_0x28955f[_0x1c9a31(0x127)]();let _0x42882b=0x0;for(const _0x38e7f2 of this['_enqueuedAt']['values']()){const _0xe06ab3=_0x2c709b-_0x38e7f2;if(_0xe06ab3>_0x42882b)_0x42882b=_0xe06ab3;}let _0x4de4ba=0x0;for(let _0x4e0d27=this['_done'][_0x1c9a31(0x39d)]-0x1;_0x4e0d27>=0x0;_0x4e0d27--){if(_0x2c709b-this[_0x1c9a31(0x7a)][_0x4e0d27]>0x3e8)break;_0x4de4ba++;}let _0x1499f9=0x0;if(this[_0x1c9a31(0x56d)][_0x1c9a31(0x39d)]){const _0x2cf4f8=[...this['_durs']]['sort']((_0x5aa859,_0x19af29)=>_0x5aa859-_0x19af29);_0x1499f9=_0x2cf4f8[Math[_0x1c9a31(0x268)](_0x2cf4f8[_0x1c9a31(0x39d)]-0x1,Math[_0x1c9a31(0x5e9)](_0x2cf4f8[_0x1c9a31(0x39d)]*0.99))];}return{'depth':this[_0x1c9a31(0x58b)][_0x1c9a31(0x35f)],'oldestPendingMs':Math['round'](_0x42882b),'committed':this['_committed'],'commitsPerSec':_0x4de4ba,'commitP99Ms':Math[_0x1c9a31(0x139)](_0x1499f9),'parkedNow':this[_0x1c9a31(0x180)]['length'],'parkedTotal':this[_0x1c9a31(0x66b)],'highWater':this[_0x1c9a31(0x4f6)]};}[_0x13c5b4(0x4b2)](){const _0x33adf2=_0x13c5b4,_0x5e22da=_0x28955f[_0x33adf2(0x127)]();return[...this['_enqueuedAt'][_0x33adf2(0x591)]()][_0x33adf2(0x757)](_0x5e19b9=>Math[_0x33adf2(0x139)](_0x5e22da-_0x5e19b9))[_0x33adf2(0x774)]((_0x43b681,_0x5a5d38)=>_0x5a5d38-_0x43b681);}[_0x13c5b4(0x4c8)](){const _0x1db940=_0x13c5b4;this[_0x1db940(0x4fd)]=!![];for(const _0xa4757d of this[_0x1db940(0x180)][_0x1db940(0x343)](0x0))_0xa4757d();}async['drain'](){const _0x58fcc2=_0x13c5b4;let _0x41c7ab=0x0;while(this[_0x58fcc2(0x58b)][_0x58fcc2(0x35f)]&&_0x41c7ab++<0x3e8){await Promise[_0x58fcc2(0xf0)]([...this['_inflight']]);}}async[_0x13c5b4(0x463)](_0x530fcb,_0x3e2153,_0x37649b,_0xee0e0a){const _0xf883cb=_0x13c5b4;return this[_0xf883cb(0x4f9)](()=>{const _0x39b856=_0xf883cb;if(_0xee0e0a===undefined)_0x530fcb['putSync'](_0x3e2153,_0x37649b);else _0x530fcb[_0x39b856(0x16c)](_0x3e2153,_0x37649b,_0xee0e0a);},'raw-put');}async[_0x13c5b4(0x34e)](_0x36edcc,_0x5c7dbf){const _0x277d02=_0x13c5b4;return this[_0x277d02(0x4f9)](()=>_0x36edcc[_0x277d02(0x59e)](_0x5c7dbf),'raw-remove');}}async function _0x530c1e(_0x17df84,_0x4acf37){const _0x10e5c4=_0x13c5b4;if(_0x4acf37==null)_0x4acf37=Math[_0x10e5c4(0x68c)](0x3e8,Number(process.env.OKDB_FLUSH_BEFORE_CLOSE_MS)||0x1d4c0);try{const _0x35b649=_0x17df84?.[_0x10e5c4(0x448)];if(!_0x35b649||typeof _0x35b649[_0x10e5c4(0xad)]!==_0x10e5c4(0x372))return;await Promise[_0x10e5c4(0x214)]([Promise[_0x10e5c4(0x738)](_0x35b649)['catch'](()=>{}),new Promise(_0x5be166=>{const _0x48ec10=_0x10e5c4,_0x377b77=setTimeout(_0x5be166,_0x4acf37);if(_0x377b77[_0x48ec10(0xe9)])_0x377b77[_0x48ec10(0xe9)]();})]);}catch{}}function _0x3a73e0(_0x200cad){const _0x43b46e=_0x13c5b4;if(_0x1ea970)return Promise[_0x43b46e(0x738)]();const _0x1522a4=_0x200cad?.[_0x43b46e(0x4d0)];return _0x1522a4&&typeof _0x1522a4[_0x43b46e(0xad)]===_0x43b46e(0x372)?_0x1522a4:Promise[_0x43b46e(0x738)]();}const _0x1cd804=Math[_0x13c5b4(0x68c)](0x1,Math[_0x13c5b4(0x5e9)](Number(process.env.UV_THREADPOOL_SIZE))||0x4),_0x450731=Math[_0x13c5b4(0x68c)](0x1,_0x1cd804-0x2);let _0x632bd=0x0;const _0x3f543b=[];async function _0x5cae7c(_0x39cb2c){const _0x25f72f=_0x13c5b4;if(_0x632bd<_0x450731)_0x632bd++;else await new Promise(_0x1eddf4=>_0x3f543b['push'](_0x1eddf4));try{return await _0x39cb2c();}finally{const _0x4b2ebc=_0x3f543b[_0x25f72f(0xfa)]();if(_0x4b2ebc)_0x4b2ebc();else _0x632bd--;}}return okdbWriter[_0x13c5b4(0x71d)]=_0x130396,okdbWriter[_0x13c5b4(0x71d)][_0x13c5b4(0x2dd)]=_0x5cae7c,okdbWriter[_0x13c5b4(0x71d)][_0x13c5b4(0x580)]=_0x450731,okdbWriter[_0x13c5b4(0x71d)]['flushLmdb']=_0x530c1e,okdbWriter[_0x13c5b4(0x71d)]['committed']=_0x3a73e0,okdbWriter[_0x13c5b4(0x71d)][_0x13c5b4(0x592)]=_0x1ea970,okdbWriter[_0x13c5b4(0x71d)];}var okdbLock,hasRequiredOkdbLock;function requireOkdbLock(){const _0x2946ee=_0x3d20e4;if(hasRequiredOkdbLock)return okdbLock;hasRequiredOkdbLock=0x1;const _0x51ec14=require$$0,{SYNC_COMMITS:_0x25a7b8}=requireOkdbWriter(),_0x3caa46=_0x2946ee(0x235);class _0x2aa42c{constructor(_0x449be6,_0x985e73,_0x58e838){const _0x1a57de=_0x2946ee;this[_0x1a57de(0x43c)]=_0x449be6,this['_key']=_0x985e73,this[_0x1a57de(0x679)]=_0x58e838,this['_released']=![],this['_heartbeatTimer']=null,this[_0x1a57de(0x3d4)]=null;}[_0x2946ee(0x3bc)](){const _0x4fae50=_0x2946ee;if(this[_0x4fae50(0x37e)])return![];try{const _0x5d2619=this['_lock']['_db']()['get'](this[_0x4fae50(0xd7)]);if(!_0x5d2619||_0x5d2619[_0x4fae50(0x781)]!==this[_0x4fae50(0x679)])return![];const _0x24fad7=_0x5d2619[_0x4fae50(0x75f)]??_0x5d2619[_0x4fae50(0x781)];if(_0x24fad7+_0x5d2619[_0x4fae50(0x52e)]<Date[_0x4fae50(0x127)]())return![];return!![];}catch{return!this[_0x4fae50(0x37e)];}}[_0x2946ee(0x391)](){const _0x3cf293=_0x2946ee;if(this[_0x3cf293(0x37e)])return null;try{return this[_0x3cf293(0x43c)][_0x3cf293(0x262)]()[_0x3cf293(0x6a)](this[_0x3cf293(0xd7)])??null;}catch{return null;}}async[_0x2946ee(0x2b6)](_0x4e8439){const _0x1d3d48=_0x2946ee;if(this['_released'])return;try{if(this[_0x1d3d48(0x43c)]['_closed']())return;const _0x160d22=this['_lock'][_0x1d3d48(0x262)]()[_0x1d3d48(0x6a)](this[_0x1d3d48(0xd7)]);if(!_0x160d22||_0x160d22[_0x1d3d48(0x781)]!==this[_0x1d3d48(0x679)])return;if(_0x25a7b8)this[_0x1d3d48(0x43c)]['_db']()[_0x1d3d48(0x16c)](this['_key'],{..._0x160d22,'ttlMs':_0x160d22['ttlMs']+_0x4e8439});else await this[_0x1d3d48(0x43c)]['_db']()[_0x1d3d48(0x463)](this[_0x1d3d48(0xd7)],{..._0x160d22,'ttlMs':_0x160d22[_0x1d3d48(0x52e)]+_0x4e8439});}catch{}}async[_0x2946ee(0x301)](){const _0x5d83b1=_0x2946ee;if(this[_0x5d83b1(0x37e)])return;if(this[_0x5d83b1(0x3d4)])try{await this['_heartbeatInFlight'];}catch{}clearInterval(this[_0x5d83b1(0x1da)]),this['_heartbeatTimer']=null,this[_0x5d83b1(0x37e)]=!![];try{if(this['_lock'][_0x5d83b1(0x4fd)]())return;const _0x2663f7=this[_0x5d83b1(0x43c)]['_db']()['get'](this[_0x5d83b1(0xd7)]);if(_0x2663f7&&_0x2663f7[_0x5d83b1(0x781)]===this[_0x5d83b1(0x679)]){if(_0x25a7b8)this[_0x5d83b1(0x43c)]['_db']()[_0x5d83b1(0x59e)](this[_0x5d83b1(0xd7)]);else await this[_0x5d83b1(0x43c)][_0x5d83b1(0x262)]()[_0x5d83b1(0x34e)](this[_0x5d83b1(0xd7)]);}}catch{}}['_startHeartbeat'](_0x3da7ff,_0x5a617f){const _0x6b8d64=_0x2946ee,_0x24ea3b=_0x5a617f??Math[_0x6b8d64(0x5e9)](_0x3da7ff/0x3);this['_heartbeatTimer']=setInterval(()=>{const _0x1299d8=_0x6b8d64;if(this[_0x1299d8(0x37e)])return;this[_0x1299d8(0x3d4)]=((async()=>{const _0x40a78d=_0x1299d8;try{if(this['_lock']['_closed']())return;const _0x29dda7=this[_0x40a78d(0x43c)][_0x40a78d(0x262)]()['get'](this[_0x40a78d(0xd7)]);if(!_0x29dda7||_0x29dda7[_0x40a78d(0x781)]!==this['_acquiredAt']){this[_0x40a78d(0x37e)]=!![],clearInterval(this[_0x40a78d(0x1da)]),this['_heartbeatTimer']=null;return;}if(_0x25a7b8)this[_0x40a78d(0x43c)][_0x40a78d(0x262)]()[_0x40a78d(0x16c)](this[_0x40a78d(0xd7)],{..._0x29dda7,'updatedAt':Date[_0x40a78d(0x127)]()});else await this['_lock'][_0x40a78d(0x262)]()[_0x40a78d(0x463)](this[_0x40a78d(0xd7)],{..._0x29dda7,'updatedAt':Date[_0x40a78d(0x127)]()});}catch{}this[_0x40a78d(0x3d4)]=null;})());},_0x24ea3b);if(this[_0x6b8d64(0x1da)][_0x6b8d64(0xe9)])this[_0x6b8d64(0x1da)][_0x6b8d64(0xe9)]();}}class _0xf34329{constructor(_0x433b27,{namespace:_0x35e923,ttlMs:ttlMs=0x7530,heartbeatMs:heartbeatMs=null}={}){const _0x59aa01=_0x2946ee;this[_0x59aa01(0x513)]=_0x433b27,this[_0x59aa01(0x253)]=_0x35e923,this['ttlMs']=ttlMs,this['heartbeatMs']=heartbeatMs,this[_0x59aa01(0x40b)]=null;}[_0x2946ee(0x262)](){const _0x206f69=_0x2946ee;return this[_0x206f69(0x51a)](),(!this[_0x206f69(0x40b)]||this['_lockDbOf']!==this[_0x206f69(0x513)])&&(this[_0x206f69(0x40b)]=this['_rawDb'][_0x206f69(0x56a)](_0x3caa46,{'dupSort':![]}),this[_0x206f69(0x96)]=this[_0x206f69(0x513)]),this['_lockDb'];}[_0x2946ee(0x1f0)](){const _0x359b08=_0x2946ee;return this[_0x359b08(0x51a)](),(!this[_0x359b08(0x6e4)]||this[_0x359b08(0x3d8)]!==this[_0x359b08(0x513)])&&(this[_0x359b08(0x6e4)]=this['_rawDb']['openDB'](_0x3caa46+_0x359b08(0x23e),{'dupSort':![]}),this[_0x359b08(0x3d8)]=this['_rawDb']),this[_0x359b08(0x6e4)];}[_0x2946ee(0x4fd)](){const _0x4b7f99=_0x2946ee,_0x2c8a71=this[_0x4b7f99(0x513)]?.[_0x4b7f99(0x170)];return _0x2c8a71===_0x4b7f99(0x517)||_0x2c8a71===_0x4b7f99(0x16f);}[_0x2946ee(0x51a)](){if(this['_closed']())throw new Error('okdb-lock:\x20env\x20closed');}[_0x2946ee(0xd7)](_0x320091){const _0x9577b4=_0x2946ee;return this[_0x9577b4(0x253)]+':'+_0x320091;}[_0x2946ee(0x167)](_0x38758a){const _0xe5d16e=_0x2946ee;try{if(this[_0xe5d16e(0x4fd)]())return;_0x25a7b8?this[_0xe5d16e(0x1f0)]()[_0xe5d16e(0x16c)](this[_0xe5d16e(0xd7)](_0x38758a),Date['now']()):this[_0xe5d16e(0x1f0)]()[_0xe5d16e(0x463)](this[_0xe5d16e(0xd7)](_0x38758a),Date[_0xe5d16e(0x127)]())?.[_0xe5d16e(0x618)]?.(()=>{});}catch{}}[_0x2946ee(0x34a)](_0x32b793,_0x1ca333=0x3e8){const _0x4545e9=_0x2946ee;try{const _0x11b37c=this[_0x4545e9(0x1f0)]()[_0x4545e9(0x6a)](this[_0x4545e9(0xd7)](_0x32b793));return typeof _0x11b37c===_0x4545e9(0x6af)&&Date['now']()-_0x11b37c<_0x1ca333;}catch{return![];}}[_0x2946ee(0x5a6)](_0x29182d){const _0x2dcbc3=_0x2946ee,_0x34051e=_0x29182d['updatedAt']??_0x29182d[_0x2dcbc3(0x781)];return _0x34051e+_0x29182d['ttlMs']<Date[_0x2dcbc3(0x127)]();}static['_holderDead'](_0x2bb296){const _0x5d8ae6=_0x2946ee,_0x3651eb=_0x2bb296?.[_0x5d8ae6(0x391)];if(!_0x3651eb||typeof _0x3651eb[_0x5d8ae6(0xee)]!==_0x5d8ae6(0x6af))return![];if(_0x3651eb[_0x5d8ae6(0x24f)]!==_0x51ec14[_0x5d8ae6(0x24f)]())return![];if(_0x3651eb['pid']===process['pid'])return![];try{return process[_0x5d8ae6(0x435)](_0x3651eb[_0x5d8ae6(0xee)],0x0),![];}catch(_0xd13a2b){return _0xd13a2b[_0x5d8ae6(0x25b)]===_0x5d8ae6(0x696);}}async[_0x2946ee(0x3df)](_0x8b6bbe,_0x3ff246={},_0x584968={}){const _0x99e604=_0x2946ee,_0x32fd77=this[_0x99e604(0xd7)](_0x8b6bbe),_0x280f58=_0x584968[_0x99e604(0x52e)]??this[_0x99e604(0x52e)],_0x5a2092=Date[_0x99e604(0x127)](),_0x5b6507={'holder':{'pid':process['pid'],'hostname':_0x51ec14['hostname'](),..._0x3ff246},'acquiredAt':_0x5a2092,'updatedAt':_0x5a2092,'ttlMs':_0x280f58};let _0x347aa4=![],_0x6f3a9b=null;if(this[_0x99e604(0x4fd)]())return{'acquired':![],'handle':null,'current':null};try{const _0x52b943=()=>{const _0x21d557=_0x99e604,_0x2b18bc=this[_0x21d557(0x262)]()[_0x21d557(0x6a)](_0x32fd77);if(_0x2b18bc&&!this[_0x21d557(0x5a6)](_0x2b18bc)&&!_0xf34329['_holderDead'](_0x2b18bc)){const _0x19ea73=_0x3ff246['processorId']!=null&&_0x2b18bc[_0x21d557(0x391)]['pid']===process[_0x21d557(0xee)]&&_0x2b18bc['holder']['processorId']===_0x3ff246[_0x21d557(0x285)];if(!_0x19ea73){_0x347aa4=![],_0x6f3a9b=_0x2b18bc;return;}_0x5b6507[_0x21d557(0x781)]<=_0x2b18bc[_0x21d557(0x781)]&&(_0x5b6507[_0x21d557(0x781)]=_0x2b18bc[_0x21d557(0x781)]+0x1,_0x5b6507[_0x21d557(0x75f)]=_0x5b6507[_0x21d557(0x781)]);}this['_db']()['put'](_0x32fd77,_0x5b6507),_0x347aa4=!![],_0x6f3a9b=_0x5b6507;};if(_0x25a7b8)this[_0x99e604(0x262)]()['transactionSync'](_0x52b943);else await this[_0x99e604(0x262)]()['childTransaction'](_0x52b943);}catch{return{'acquired':![],'handle':null,'current':null};}if(!_0x347aa4)return{'acquired':![],'handle':null,'current':_0x6f3a9b};const _0x2823f7=new _0x2aa42c(this,_0x32fd77,_0x5b6507[_0x99e604(0x781)]);return _0x2823f7[_0x99e604(0x17f)](_0x280f58,this['heartbeatMs']),{'acquired':!![],'handle':_0x2823f7,'current':_0x6f3a9b};}['inspect'](_0x1d4323){const _0x1d54c7=_0x2946ee;try{return this[_0x1d54c7(0x262)]()[_0x1d54c7(0x6a)](this[_0x1d54c7(0xd7)](_0x1d4323))??null;}catch{return null;}}[_0x2946ee(0x401)](){const _0x573b18=_0x2946ee,_0xa00d1b=this[_0x573b18(0x253)]+':',_0x26f651=[];try{for(const {key:_0x3edd17,value:_0x4631a8}of this[_0x573b18(0x262)]()[_0x573b18(0x1c1)]({'start':_0xa00d1b,'end':_0xa00d1b+'\xff'})){typeof _0x3edd17==='string'&&_0x3edd17[_0x573b18(0x42e)](_0xa00d1b)&&_0x26f651[_0x573b18(0x2f9)]({'id':_0x3edd17[_0x573b18(0x13a)](_0xa00d1b[_0x573b18(0x39d)]),'entry':_0x4631a8});}}catch{}return _0x26f651;}static[_0x2946ee(0x4e9)](_0x1ef531){const _0x51f817=_0x2946ee,_0x422710=[];try{const _0x567366=_0x1ef531[_0x51f817(0x56a)](_0x3caa46,{'dupSort':![]});for(const {key:_0x2e06a0,value:_0x115611}of _0x567366[_0x51f817(0x1c1)]({})){if(typeof _0x2e06a0!==_0x51f817(0xe7))continue;const _0x1f39ee=_0x2e06a0[_0x51f817(0x380)](':');if(_0x1f39ee<0x1)continue;_0x422710[_0x51f817(0x2f9)]({'namespace':_0x2e06a0[_0x51f817(0x13a)](0x0,_0x1f39ee),'id':_0x2e06a0['slice'](_0x1f39ee+0x1),'entry':_0x115611});}}catch{}return _0x422710;}}return okdbLock={'OKDBLock':_0xf34329},okdbLock;}var okdbProcessRegistry,hasRequiredOkdbProcessRegistry;function requireOkdbProcessRegistry(){const _0x16b568=_0x3d20e4;if(hasRequiredOkdbProcessRegistry)return okdbProcessRegistry;hasRequiredOkdbProcessRegistry=0x1;const _0x2f5a30=require$$0,_0x6abccb=require$$1$1,_0x5c98a6=require$$2$1,{LOOP:_0x3b727a}=requireOkdbLoopMonitor(),{OKDBLock:_0x1de777}=requireOkdbLock(),{SYNC_COMMITS:_0x4ac07b}=requireOkdbWriter(),_0x600417='~processes',_0x109a13=_0x16b568(0x68e),_0x4e41c6=_0x16b568(0x4df),_0x17db9f=_0x16b568(0x5cd),_0x4d5519=(_0x258d69,_0x5ad7d0)=>_0x258d69+':'+_0x5ad7d0,_0x3fb6d6=(_0x133a3b,_0x5939a5)=>_0x133a3b+'::'+_0x5939a5,_0x3bd861=(_0x5f0226,_0x46e437)=>_0x5f0226+'/'+_0x46e437,_0x8257a7=(_0x17958c,_0x23630e)=>_0x17958c+'#'+_0x23630e,_0x196db6=_0x288eb5=>{const _0x56364d=_0x16b568;if(_0x288eb5?.['processKey'])return _0x288eb5[_0x56364d(0x494)];const _0x2481af=_0x288eb5?.[_0x56364d(0x70d)];return typeof _0x2481af==='string'&&_0x2481af[_0x56364d(0x8f)]('#')?_0x2481af[_0x56364d(0x13a)](0x0,_0x2481af[_0x56364d(0x380)]('#')):_0x2481af;},_0xc80032=Number(process.env.OKDB_WORKERS_HEARTBEAT_MS)||0x2710,_0x1e6bd6=Number(process.env.OKDB_WORKERS_PUBLISH_MS)||0x3e8,_0x141854=_0xc80032*0x3,_0x4c8eb3=Number(process.env.OKDB_PID_REUSE_HORIZON_MS)||Math[_0x16b568(0x68c)](0x927c0,_0x141854*0x14),_0x4aacd3=['processor:progress',_0x16b568(0x58f),'processor:retry',_0x16b568(0x2cd),_0x16b568(0x523),_0x16b568(0x75a)];let _0x47285c=null;function _0x5cb54a(){const _0x44e28e=_0x16b568;if(_0x47285c==null)_0x47285c=Math['round']((Date[_0x44e28e(0x127)]()-process[_0x44e28e(0x417)]()*0x3e8)/0x3e8)*0x3e8;return _0x47285c;}function _0x28bf91(_0x124bff){const _0x461f6b=_0x16b568;if(process.env.OKDB_PROCESS_KILL===_0x461f6b(0x567))return![];if(_0x124bff?.[_0x461f6b(0x518)]?.['processes']&&typeof _0x124bff['options'][_0x461f6b(0x5c9)]===_0x461f6b(0x5d4)&&_0x124bff[_0x461f6b(0x518)]['processes'][_0x461f6b(0x435)]===![])return![];return!![];}function _0x151ca7(_0x2c9947,_0x3373f9){const _0x119895=_0x16b568,_0x3f9f3b=!!_0x3373f9?.[_0x119895(0x43e)];switch(_0x2c9947){case _0x119895(0x73b):return{'controllable':_0x3f9f3b,'decommissionable':![],'killable':!![],'killConfirm':'cluster-wide'};case _0x119895(0x12e):case _0x119895(0x50c):return{'controllable':_0x3f9f3b,'decommissionable':![],'killable':!![],'killConfirm':_0x119895(0x62b)};case'embedded':return{'controllable':![],'decommissionable':![],'killable':![]};case'http-server':case _0x119895(0x64d):case'fn-runner':case _0x119895(0x259):return{'controllable':![],'decommissionable':!![],'killable':!![],'killConfirm':'force'};default:return{'controllable':![],'decommissionable':![],'killable':![]};}}class _0x1cfcfa{constructor(_0x2ecc25){const _0x4997c9=_0x16b568;this['okdb']=_0x2ecc25,this['_statusEnv']=null,this[_0x4997c9(0x3f1)]=null,this[_0x4997c9(0x271)]=new Map(),this[_0x4997c9(0x52b)]=null,this[_0x4997c9(0x76)]=![],this[_0x4997c9(0x68a)]=![],this[_0x4997c9(0x26a)]=_0x5cb54a(),this[_0x4997c9(0x452)]=_0x4d5519(process['pid'],this[_0x4997c9(0x26a)]),this[_0x4997c9(0x38c)]=_0x5c98a6['randomUUID']()[_0x4997c9(0x13a)](0x0,0x8),this[_0x4997c9(0x254)]=_0x8257a7(this['_selfKey'],this[_0x4997c9(0x38c)]),this[_0x4997c9(0x12a)]=Date[_0x4997c9(0x127)](),this[_0x4997c9(0x11f)]=null,this['_supervisorKey']=null,this['_listenAddr']=null,this[_0x4997c9(0xd4)]=null,this[_0x4997c9(0x2d1)]=null,this['_onTick']=null,this[_0x4997c9(0x35e)]=0x0,this[_0x4997c9(0x746)]={},this[_0x4997c9(0x718)]=new Map(),this[_0x4997c9(0x6ca)]=process[_0x4997c9(0x4d5)](),this['_lastCpuAt']=Date['now'](),this[_0x4997c9(0x645)]=0x0,this['_threadStats']=new Map();}get[_0x16b568(0x131)](){return this['_selfKey'];}get[_0x16b568(0x611)](){return this['_rowKey'];}['_caps'](_0x2479ab,_0x15297d){const _0x3f870f=_0x16b568,_0x5b2b2d=_0x151ca7(_0x2479ab,_0x15297d);if(_0x5b2b2d[_0x3f870f(0x166)]&&!_0x28bf91(this[_0x3f870f(0x229)]))return{..._0x5b2b2d,'killable':![],'killConfirm':undefined};return _0x5b2b2d;}[_0x16b568(0x225)](){const _0xee40ae=_0x16b568;return!!this[_0xee40ae(0x671)];}[_0x16b568(0x4db)](_0x138d27){const _0x1d958e=_0x16b568;Object['assign'](this[_0x1d958e(0x746)],_0x138d27||{});}[_0x16b568(0x316)](_0x57731b){const _0x56677d=_0x16b568;if(_0x57731b)this[_0x56677d(0x22d)]=_0x57731b;}[_0x16b568(0x44e)](_0x35017d={}){const _0x2ecd8f=_0x16b568;return this['okdb'][_0x2ecd8f(0x3fd)](_0x35017d);}['processingStatusView'](){const _0x440408=_0x16b568,_0x2bb2d6={};let _0x4780f3=0x0,_0x541117=0x0;const _0x34f54c=new Set();for(const _0x15568e of this['listNodes']()){_0x541117++;const _0x1aa2c8=_0x15568e[_0x440408(0x40f)];if(!_0x1aa2c8)continue;if(_0x1aa2c8[_0x440408(0x477)])_0x4780f3++;for(const _0x1d77a6 of _0x1aa2c8[_0x440408(0x43e)]||[]){if(![_0x440408(0x238),'fanout'][_0x440408(0x8f)](_0x1d77a6[_0x440408(0x38b)]))continue;(_0x1d77a6[_0x440408(0x1a3)]==='online'||_0x1d77a6[_0x440408(0x1a3)]===_0x440408(0x74e))&&_0x1d77a6[_0x440408(0x8b)]&&_0x34f54c[_0x440408(0x3e9)]((_0x1d77a6[_0x440408(0x124)]||_0x440408(0x3e8))+':'+_0x1d77a6[_0x440408(0x8b)]);const _0x5d4604=_0x1d77a6[_0x440408(0x124)]||_0x440408(0x3e8);(_0x2bb2d6[_0x5d4604]||=[])[_0x440408(0x2f9)]({..._0x1d77a6,'env':_0x5d4604,'owner':{'pid':_0x15568e[_0x440408(0xee)]??null,'kind':_0x15568e[_0x440408(0xaa)]??null}});}}for(const [_0x6d758a,_0x365b6f]of Object['entries'](_0x2bb2d6)){for(const _0x3d641a of _0x365b6f){if(_0x3d641a[_0x440408(0x38b)]===_0x440408(0x238)&&!_0x3d641a[_0x440408(0x1d9)]){const _0x50d0e8=_0x6d758a+':'+(_0x3d641a[_0x440408(0x8b)]??'');if(!_0x34f54c['has'](_0x50d0e8))_0x3d641a[_0x440408(0x21c)]=!![];}}}return{'envs':_0x2bb2d6,'policy':null,'participation':{'participating':_0x4780f3,'total':_0x541117},'source':_0x440408(0x150)};}[_0x16b568(0x107)](){const _0x178273=_0x16b568,_0x4e13c0=_0x4f577d=>{const _0x46f137=_0x8cd7;if(_0x4f577d['state']==='online'||_0x4f577d[_0x46f137(0x1a3)]===_0x46f137(0x74e)||_0x4f577d[_0x46f137(0x1a3)]===_0x46f137(0x492))return 0x3;if(_0x4f577d['claimGated'])return 0x1;return 0x2;},_0x4a4771=new Map();for(const _0x5bd4a4 of this[_0x178273(0x6e3)]()){for(const _0x57c1e3 of _0x5bd4a4[_0x178273(0x40f)]?.[_0x178273(0x43e)]||[]){const _0x1cf6f9={..._0x57c1e3,'owner':{'pid':_0x5bd4a4[_0x178273(0xee)]??null,'kind':_0x5bd4a4[_0x178273(0xaa)]??null,'host':_0x5bd4a4['host']??null}},_0xee0805=_0x57c1e3[_0x178273(0x38b)]==='single'?_0x178273(0x182)+(_0x57c1e3[_0x178273(0x124)]??'')+'::'+(_0x57c1e3[_0x178273(0x8b)]??_0x57c1e3['type']??_0x57c1e3['id']):_0x178273(0x510)+(_0x5bd4a4['nodeKey']??_0x5bd4a4[_0x178273(0x494)]??'')+'::'+(_0x57c1e3[_0x178273(0x124)]??'')+'::'+_0x57c1e3['id'],_0x33f434=_0x4a4771[_0x178273(0x6a)](_0xee0805);if(!_0x33f434||_0x4e13c0(_0x1cf6f9)>_0x4e13c0(_0x33f434))_0x4a4771['set'](_0xee0805,_0x1cf6f9);}}return[..._0x4a4771['values']()];}[_0x16b568(0x769)](){const _0x121c2c=_0x16b568,_0x1fd030=Date[_0x121c2c(0x127)](),_0x573a64=this[_0x121c2c(0x6e3)](),_0x20ca79=_0x33c760=>Math[_0x121c2c(0x68c)](0x0,Math['round']((_0x1fd030-(_0x33c760[_0x121c2c(0x698)]||_0x1fd030))/0x3e8)),_0x4543e9=_0x573a64['find'](_0x352738=>_0x352738[_0x121c2c(0xaa)]===_0x121c2c(0x73b)),_0x30d93d=_0x573a64['filter'](_0xac39e3=>_0xac39e3['kind']===_0x121c2c(0x35d));if(_0x4543e9||_0x30d93d[_0x121c2c(0x39d)])return{'primary':_0x4543e9?{'pid':_0x4543e9['pid'],'uptime':_0x20ca79(_0x4543e9)}:null,'workers':_0x30d93d[_0x121c2c(0x757)](_0x56413a=>({'pid':_0x56413a[_0x121c2c(0xee)],'uptime':_0x20ca79(_0x56413a)})),'workersConfigured':_0x4543e9?.['meta']?.[_0x121c2c(0x11d)]??_0x30d93d['length'],'mode':_0x121c2c(0x2bd)};const _0x1fc0ee=_0x573a64[_0x121c2c(0x83)](_0x26af74=>_0x26af74['kind']===_0x121c2c(0x12e)||_0x26af74[_0x121c2c(0xaa)]===_0x121c2c(0x50c)||_0x26af74[_0x121c2c(0xaa)]==='embedded'),_0x1939ec=_0x1fc0ee?{'pid':_0x1fc0ee['pid'],'uptime':_0x20ca79(_0x1fc0ee)}:{'pid':process[_0x121c2c(0xee)],'uptime':Math[_0x121c2c(0x68c)](0x0,Math[_0x121c2c(0x139)](process[_0x121c2c(0x417)]()))};return{'primary':_0x1939ec,'workers':[_0x1939ec],'workersConfigured':0x1,'mode':'single'};}['nodesView'](){const _0x4cc0ad=_0x16b568;return this[_0x4cc0ad(0x556)]();}[_0x16b568(0x114)](){const _0x4bd523=_0x16b568,_0x211ce3=new Map();for(const _0x41ae22 of this[_0x4bd523(0x556)]())_0x211ce3[_0x4bd523(0x49d)](_0x41ae22['processKey'],{..._0x41ae22,'children':[]});const _0x4c0672=[];for(const _0x4e29ef of _0x211ce3['values']()){const _0x57e08b=_0x4e29ef[_0x4bd523(0x77d)]?_0x211ce3[_0x4bd523(0x6a)](_0x4e29ef['supervisorKey']):null;if(_0x57e08b&&_0x57e08b!==_0x4e29ef)_0x57e08b['children'][_0x4bd523(0x2f9)](_0x4e29ef);else _0x4c0672[_0x4bd523(0x2f9)](_0x4e29ef);}const _0x3fbbc0=(_0x5db2d4,_0x3e3a90)=>_0x5db2d4[_0x4bd523(0xaa)]===_0x3e3a90[_0x4bd523(0xaa)]?(_0x5db2d4[_0x4bd523(0xee)]||0x0)-(_0x3e3a90[_0x4bd523(0xee)]||0x0):(_0x5db2d4['kind']??'')<(_0x3e3a90['kind']??'')?-0x1:0x1,_0x4b959d=_0x1fb8e3=>{const _0x880fcf=_0x4bd523;_0x1fb8e3[_0x880fcf(0x774)](_0x3fbbc0);for(const _0x406d7a of _0x1fb8e3)if(_0x406d7a[_0x880fcf(0x5ff)][_0x880fcf(0x39d)])_0x4b959d(_0x406d7a[_0x880fcf(0x5ff)]);};return _0x4b959d(_0x4c0672),_0x4c0672;}['getProcess'](_0x4d380f){const _0x17aa18=_0x16b568;return this[_0x17aa18(0x556)]()['find'](_0x4457fd=>_0x4457fd[_0x17aa18(0x494)]===_0x4d380f)??null;}[_0x16b568(0x556)](_0x33198e=Date[_0x16b568(0x127)]()){const _0x831fae=_0x16b568,_0x599124=new Map();for(const _0x5aa9e2 of this[_0x831fae(0x6e3)]()){const _0xbf7b30=_0x196db6(_0x5aa9e2);let _0x56e878=_0x599124['get'](_0xbf7b30);!_0x56e878&&(_0x56e878={'processKey':_0xbf7b30,'nodeKey':_0xbf7b30,'pid':_0x5aa9e2[_0x831fae(0xee)],'ppid':_0x5aa9e2[_0x831fae(0x56e)]??null,'host':_0x5aa9e2[_0x831fae(0x41a)]??null,'kind':_0x5aa9e2[_0x831fae(0xaa)],'role':null,'supervisorKey':_0x5aa9e2[_0x831fae(0x77d)]??null,'slot':_0x5aa9e2[_0x831fae(0x257)]??null,'slotKey':_0x5aa9e2[_0x831fae(0x3a0)]??null,'caps':_0x5aa9e2[_0x831fae(0x3b6)]??null,'lifecycle':_0x5aa9e2['lifecycle']??null,'uptime':Math[_0x831fae(0x68c)](0x0,Math[_0x831fae(0x139)]((_0x33198e-(_0x5aa9e2[_0x831fae(0x698)]||_0x33198e))/0x3e8)),'startedAt':_0x5aa9e2[_0x831fae(0x698)]??null,'meta':_0x5aa9e2[_0x831fae(0xc9)]??null,'listenAddr':null,'processing':null,'engines':null,'singletonClaims':null,'stats':null,'instances':[]},_0x599124['set'](_0xbf7b30,_0x56e878));_0x56e878[_0x831fae(0x297)]['push']({'instanceId':_0x5aa9e2[_0x831fae(0x5e7)]??null,'role':_0x5aa9e2[_0x831fae(0x132)]??null,'listenAddr':_0x5aa9e2[_0x831fae(0x6f6)]??null,'lifecycle':_0x5aa9e2['lifecycle']??null,'processing':_0x5aa9e2['processing']??null});if(!_0x56e878[_0x831fae(0x132)]&&_0x5aa9e2[_0x831fae(0x132)])_0x56e878[_0x831fae(0x132)]=_0x5aa9e2[_0x831fae(0x132)];if(!_0x56e878['listenAddr']&&_0x5aa9e2[_0x831fae(0x6f6)])_0x56e878['listenAddr']=_0x5aa9e2[_0x831fae(0x6f6)];if(!_0x56e878[_0x831fae(0x40f)]&&_0x5aa9e2[_0x831fae(0x40f)])_0x56e878[_0x831fae(0x40f)]=_0x5aa9e2['processing'];if(!_0x56e878[_0x831fae(0x39c)]&&_0x5aa9e2[_0x831fae(0x39c)])_0x56e878[_0x831fae(0x39c)]=_0x5aa9e2[_0x831fae(0x39c)];if(!_0x56e878[_0x831fae(0x3e7)]&&_0x5aa9e2[_0x831fae(0x3e7)])_0x56e878[_0x831fae(0x3e7)]=_0x5aa9e2[_0x831fae(0x3e7)];if(_0x56e878[_0x831fae(0x3b6)]==null&&_0x5aa9e2['caps'])_0x56e878[_0x831fae(0x3b6)]=_0x5aa9e2[_0x831fae(0x3b6)];if(_0x5aa9e2[_0x831fae(0x609)]&&(!_0x56e878[_0x831fae(0x609)]||(_0x5aa9e2['stats']['at']??0x0)>(_0x56e878['stats']['at']??0x0)))_0x56e878[_0x831fae(0x609)]=_0x5aa9e2[_0x831fae(0x609)];}return[..._0x599124[_0x831fae(0x591)]()];}['runtimeProcessesView'](){const _0x2201dc=_0x16b568,_0x2e5878=[],_0x3204c5={'rss':0x0,'heapUsed':0x0,'processes':0x0,'threads':{'count':0x0,'sandbox':0x0,'busy':0x0}};for(const _0x12093e of this[_0x2201dc(0x556)]()){_0x2e5878[_0x2201dc(0x2f9)]({'processKey':_0x12093e[_0x2201dc(0x494)],'kind':_0x12093e[_0x2201dc(0xaa)],'pid':_0x12093e[_0x2201dc(0xee)],'supervisorKey':_0x12093e[_0x2201dc(0x77d)],'meta':_0x12093e[_0x2201dc(0xc9)]??null,'uptime':_0x12093e[_0x2201dc(0x417)],'stats':_0x12093e[_0x2201dc(0x609)]??null}),_0x3204c5[_0x2201dc(0x5c9)]++;if(_0x12093e[_0x2201dc(0x609)]){_0x3204c5[_0x2201dc(0x60d)]+=_0x12093e['stats']['rss']||0x0,_0x3204c5[_0x2201dc(0x497)]+=(_0x12093e[_0x2201dc(0x609)][_0x2201dc(0x497)]||0x0)+(_0x12093e[_0x2201dc(0x609)][_0x2201dc(0x6b7)]?.['heapUsed']||0x0);const _0x1fdeee=_0x12093e[_0x2201dc(0x609)][_0x2201dc(0x6b7)];_0x1fdeee&&(_0x3204c5['threads'][_0x2201dc(0x6ad)]+=_0x1fdeee['count']||0x0,_0x3204c5['threads']['sandbox']+=_0x1fdeee['sandbox']||0x0,_0x3204c5['threads'][_0x2201dc(0x63d)]+=_0x1fdeee['busy']||0x0);}}return{'totals':_0x3204c5,'nodes':_0x2e5878};}async['open']({writer:writer=![],reader:reader=![],kind:kind=null,supervisorKey:supervisorKey=null,listenAddr:listenAddr=null}={}){const _0x1f8a3f=_0x16b568;this[_0x1f8a3f(0x76)]=this['_isWriter']||!!writer,this[_0x1f8a3f(0x68a)]=this[_0x1f8a3f(0x68a)]||!!reader,this[_0x1f8a3f(0x11f)]=kind||this[_0x1f8a3f(0x11f)]||(_0x6abccb['isWorker']?_0x1f8a3f(0x35d):_0x1f8a3f(0x12e)),this[_0x1f8a3f(0x37d)]=supervisorKey??this[_0x1f8a3f(0x37d)],this[_0x1f8a3f(0x22d)]=listenAddr??this[_0x1f8a3f(0x22d)],this[_0x1f8a3f(0x3b4)](),await this['_migrateVocab']();if(!writer&&!reader)return null;if(!this[_0x1f8a3f(0x671)]){const _0x411d9e=await this['okdb']['createEnvironment'](_0x600417,{'sync':![],'durability':_0x1f8a3f(0x537)});await _0x411d9e[_0x1f8a3f(0x3ca)](_0x109a13),this['_statusEnv']=_0x411d9e;}return this['_statusEnv'];}[_0x16b568(0x218)](){const _0x2ff8b9=_0x16b568;return this[_0x2ff8b9(0x174)]!==this[_0x2ff8b9(0x671)]&&(this[_0x2ff8b9(0x174)]=this[_0x2ff8b9(0x671)],this[_0x2ff8b9(0x626)]=this[_0x2ff8b9(0x671)][_0x2ff8b9(0x3ad)](_0x109a13)[_0x2ff8b9(0x32e)]),this[_0x2ff8b9(0x626)];}[_0x16b568(0x459)](_0x44cfb1){const _0x47a7f0=_0x16b568;if(_0x4ac07b)return this['_nodeDb']()['putSync'](_0x44cfb1[_0x47a7f0(0x70d)],_0x44cfb1,0x1);const _0x11aca0=this[_0x47a7f0(0x218)]()['put'](_0x44cfb1[_0x47a7f0(0x70d)],_0x44cfb1,0x1);if(_0x11aca0&&typeof _0x11aca0[_0x47a7f0(0xad)]===_0x47a7f0(0x372))_0x11aca0[_0x47a7f0(0xad)](undefined,()=>{});return _0x11aca0;}['_putRowSync'](_0x5918f0){const _0x308ebf=_0x16b568;return this[_0x308ebf(0x218)]()[_0x308ebf(0x16c)](_0x5918f0['nodeKey'],_0x5918f0,0x1);}['_removeRowAsync'](_0x146ab7){const _0x200eb6=_0x16b568;if(_0x4ac07b)try{return this[_0x200eb6(0x218)]()[_0x200eb6(0x59e)](_0x146ab7);}catch{return![];}const _0x36d04e=this[_0x200eb6(0x218)]()[_0x200eb6(0x34e)](_0x146ab7);if(_0x36d04e&&typeof _0x36d04e[_0x200eb6(0xad)]===_0x200eb6(0x372))_0x36d04e[_0x200eb6(0xad)](undefined,()=>{});return _0x36d04e;}async[_0x16b568(0x414)](_0x18e037){const _0x146f80=_0x16b568;if(!this['_statusEnv']||!this['_isWriter']||!_0x18e037?.[_0x146f80(0x70d)])return;return this['_putRowAsync'](_0x18e037);}async[_0x16b568(0x2c9)](_0x23c7cf){const _0x987e65=_0x16b568;if(!this[_0x987e65(0x671)]||!this[_0x987e65(0x76)]||!_0x23c7cf)return;const _0x5efb22=_0x23c7cf['includes']('#'),_0x56f36f=[];for(const {key:_0x2852cf}of this[_0x987e65(0x671)][_0x987e65(0x1c1)](_0x109a13)){if(_0x2852cf===_0x23c7cf||!_0x5efb22&&typeof _0x2852cf==='string'&&_0x2852cf['startsWith'](_0x23c7cf+'#'))_0x56f36f[_0x987e65(0x2f9)](_0x2852cf);}for(const _0x4a2b02 of _0x56f36f){try{this['_nodeDb']()['removeSync'](_0x4a2b02);}catch{}}}[_0x16b568(0x751)](_0x3d18f3){const _0x5060e8=_0x16b568;if(typeof _0x3d18f3?.[_0x5060e8(0xee)]!=='number')return![];if(_0x3d18f3[_0x5060e8(0x41a)]!==_0x2f5a30[_0x5060e8(0x24f)]())return![];if(_0x3d18f3[_0x5060e8(0xee)]===process[_0x5060e8(0xee)])return![];if(_0x3d18f3[_0x5060e8(0x57a)]!=null&&_0x3d18f3['expiresAt']<Date[_0x5060e8(0x127)]()-_0x4c8eb3)return!![];try{return process[_0x5060e8(0x435)](_0x3d18f3[_0x5060e8(0xee)],0x0),![];}catch(_0x3c7f0b){return _0x3c7f0b['code']===_0x5060e8(0x696);}}[_0x16b568(0x6e3)](){const _0x4439be=_0x16b568;if(!this['_statusEnv'])return[];try{this['_statusEnv']['db']?.[_0x4439be(0x662)]?.();}catch{}const _0x41799d=Date[_0x4439be(0x127)](),_0x354876=_0x2f5a30['hostname'](),_0xe67c71=[];for(const {value:_0x364f09}of this[_0x4439be(0x671)][_0x4439be(0x1c1)](_0x109a13)){if(!_0x364f09)continue;let _0x158e18=null;_0x364f09[_0x4439be(0x41a)]===_0x354876&&typeof _0x364f09['pid']===_0x4439be(0x6af)&&(_0x158e18=!this[_0x4439be(0x751)](_0x364f09));if(_0x158e18===![])continue;const _0xbbc2f3=_0x364f09[_0x4439be(0x57a)]==null||_0x364f09[_0x4439be(0x57a)]>=_0x41799d;if(_0x158e18===!![]||_0xbbc2f3)_0xe67c71[_0x4439be(0x2f9)](_0x364f09);}return _0xe67c71;}async[_0x16b568(0x4cb)](_0x457fd4=0x0){const _0x459c84=_0x16b568;if(!this['_statusEnv']||!this[_0x459c84(0x76)])return;const _0x3fcc50=Date[_0x459c84(0x127)]()-_0x457fd4,_0x4e6305=new Set(),_0x598218=[],_0x38a7fd=_0x2f5a30[_0x459c84(0x24f)](),_0x198101=require$$3[_0x459c84(0x3e1)];for(const {key:_0x332710,value:_0x35fb00}of this[_0x459c84(0x671)][_0x459c84(0x1c1)](_0x109a13)){if(!_0x35fb00)continue;const _0x443b7b=_0x35fb00[_0x459c84(0x41a)]===_0x38a7fd&&typeof _0x35fb00[_0x459c84(0xee)]===_0x459c84(0x6af),_0x257603=_0x443b7b?this[_0x459c84(0x751)](_0x35fb00):_0x35fb00[_0x459c84(0x57a)]!=null&&_0x35fb00[_0x459c84(0x57a)]<_0x3fcc50;if(_0x257603)_0x598218[_0x459c84(0x2f9)](_0x332710);else{_0x4e6305[_0x459c84(0x3e9)](_0x196db6(_0x35fb00)??_0x332710);if(_0x35fb00[_0x459c84(0x3e1)]&&_0x35fb00['version']!==_0x198101){if(!this['_versionSkewWarned'])this[_0x459c84(0x5f6)]=new Set();!this[_0x459c84(0x5f6)]['has'](_0x35fb00['version'])&&(this[_0x459c84(0x5f6)][_0x459c84(0x3e9)](_0x35fb00[_0x459c84(0x3e1)]),this[_0x459c84(0x229)][_0x459c84(0x24e)]?.[_0x459c84(0x6a7)]?.(_0x459c84(0x760)+(_0x35fb00['pid']??'?')+_0x459c84(0x67d)+_0x35fb00[_0x459c84(0x3e1)]+'\x20while\x20this\x20process\x20runs\x20'+_0x198101+'\x20—\x20'+_0x459c84(0x486),{'feature':_0x459c84(0x631)}));}}}for(const _0x58215a of _0x598218)this['_removeRowAsync'](_0x58215a);if(this['_ensureDesired']()){const _0x3f9fcf=[];for(const {key:_0x3ffb90}of this[_0x459c84(0x272)](_0x459c84(0x68e))){if(!_0x4e6305[_0x459c84(0x469)](_0x3ffb90)){if(_0x4ac07b)try{this['_desired'][_0x459c84(0x59e)](_0x459c84(0x321)+_0x3ffb90);}catch{}else _0x3f9fcf['push'](this[_0x459c84(0x3f1)][_0x459c84(0x34e)](_0x459c84(0x321)+_0x3ffb90));}}if(_0x3f9fcf['length'])await Promise[_0x459c84(0xf0)](_0x3f9fcf);}}['startHeartbeat'](_0x35cbeb=null){const _0x388be5=_0x16b568;if(this[_0x388be5(0xd4)])return;if(!this[_0x388be5(0x76)]||!this['_statusEnv']){this[_0x388be5(0x229)]?.['log']?.[_0x388be5(0x6a7)]?.(_0x388be5(0x5d9)+this['_isWriter']+_0x388be5(0x36c)+!!this['_statusEnv']+_0x388be5(0x6f5),{'feature':_0x388be5(0x5c9)});return;}this[_0x388be5(0x73e)]=_0x35cbeb,this[_0x388be5(0x2d1)]=()=>this[_0x388be5(0x185)]();for(const _0x3bc066 of _0x4aacd3)this[_0x388be5(0x229)]['events']['on'](_0x3bc066,this[_0x388be5(0x2d1)]);this['_publishNow']();const _0x2c3242=Number(process.env.OKDB_WORKERS_HEARTBEAT_MS)||_0xc80032;this[_0x388be5(0xd4)]=setInterval(()=>{const _0x514cf4=_0x388be5;if(this['_onTick'])try{this['_onTick']();}catch{}this[_0x514cf4(0x57f)](),this[_0x514cf4(0x4cb)]()[_0x514cf4(0x618)](()=>{});},_0x2c3242);if(this[_0x388be5(0xd4)][_0x388be5(0xe9)])this[_0x388be5(0xd4)][_0x388be5(0xe9)]();}['_maybePublish'](){const _0x12068c=_0x16b568;if(!this['_isWriter']||!this[_0x12068c(0x671)])return;if(Date[_0x12068c(0x127)]()-this[_0x12068c(0x35e)]<_0x1e6bd6)return;this['_publishNow']();}[_0x16b568(0x57f)](){const _0x575f9e=_0x16b568;if(!this[_0x575f9e(0x76)]||!this[_0x575f9e(0x671)])return;this[_0x575f9e(0x35e)]=Date[_0x575f9e(0x127)]();try{const _0x54e466=[this[_0x575f9e(0x345)]()];for(const _0x5e1dfd of this[_0x575f9e(0x718)][_0x575f9e(0x591)]())_0x54e466[_0x575f9e(0x2f9)](this[_0x575f9e(0x351)](_0x5e1dfd));const _0x56e995=_0x3b727a[_0x575f9e(0x1f9)]?_0x3b727a['now']():0x0;for(const _0x4cd4dd of _0x54e466){try{this[_0x575f9e(0x658)](_0x4cd4dd),this[_0x575f9e(0x4aa)]=![];}catch(_0x2bde63){!this[_0x575f9e(0x4aa)]&&(this[_0x575f9e(0x4aa)]=!![],this[_0x575f9e(0x229)]?.[_0x575f9e(0x24e)]?.['warn']?.(_0x575f9e(0x524)+_0x2bde63['message'],{'feature':'processes'}));}}if(_0x3b727a[_0x575f9e(0x1f9)])_0x3b727a[_0x575f9e(0x79)]('registry-publish',_0x3b727a['now']()-_0x56e995,_0x575f9e(0x53d)+_0x54e466[_0x575f9e(0x39d)]+_0x575f9e(0x630));}catch(_0x11dac3){!this[_0x575f9e(0x4aa)]&&(this['_publishFailWarned']=!![],this[_0x575f9e(0x229)]?.[_0x575f9e(0x24e)]?.[_0x575f9e(0x6a7)]?.('registry\x20publish\x20failing:\x20'+_0x11dac3[_0x575f9e(0x5e6)],{'feature':_0x575f9e(0x5c9)}));}}async[_0x16b568(0x40e)](){const _0x5378b2=_0x16b568;if(this[_0x5378b2(0x2d1)]){for(const _0x167e5f of _0x4aacd3){try{this['okdb']['events'][_0x5378b2(0x567)](_0x167e5f,this[_0x5378b2(0x2d1)]);}catch{}}this[_0x5378b2(0x2d1)]=null;}this['_hbTimer']&&(clearInterval(this['_hbTimer']),this[_0x5378b2(0xd4)]=null);try{if(this[_0x5378b2(0x671)]&&this[_0x5378b2(0x76)])await this[_0x5378b2(0x2c9)](this[_0x5378b2(0x254)]);}catch{}}async['deregisterSelf'](){const _0x29a1c8=_0x16b568;if(!this[_0x29a1c8(0x671)]||!this[_0x29a1c8(0x76)])return;try{await this[_0x29a1c8(0x2c9)](this[_0x29a1c8(0x254)]);}catch{}try{const _0x46f295=[];for(const {value:_0x416a82}of this[_0x29a1c8(0x671)][_0x29a1c8(0x1c1)](_0x109a13)){if(_0x416a82?.[_0x29a1c8(0x56e)]===process['pid']&&_0x416a82['nodeKey'])_0x46f295['push'](_0x416a82[_0x29a1c8(0x70d)]);}for(const _0x185186 of _0x46f295){try{await this[_0x29a1c8(0x2c9)](_0x185186);}catch{}}}catch{}}async[_0x16b568(0x44d)](){const _0x593df7=_0x16b568;return this['putNode'](this[_0x593df7(0x345)]());}async['publishChildRow'](_0x530d14){const _0x407f62=_0x16b568;if(!this['_statusEnv']||!this[_0x407f62(0x76)])return;return this[_0x407f62(0x414)](this[_0x407f62(0x351)](_0x530d14));}[_0x16b568(0x351)]({pid:_0x306691,startedAt:_0x1b88ad,kind:_0x5cd041,supervisorKey:_0x602293,slot:slot=null,slotKey:slotKey=null,role:role={},listenAddr:listenAddr=null,processing:processing=null,lifecycle:lifecycle=_0x16b568(0x364),meta:meta=null,stats:stats=null}){const _0x3a4f7d=_0x16b568,_0xb926e=Date[_0x3a4f7d(0x127)](),_0x1eb6c5=_0x4d5519(_0x306691,_0x1b88ad);return{'nodeKey':_0x8257a7(_0x1eb6c5,'0'),'processKey':_0x1eb6c5,'instanceId':'0','pid':_0x306691,'startedAt':_0x1b88ad,'ppid':process['pid'],'host':_0x2f5a30[_0x3a4f7d(0x24f)](),'supervisorKey':_0x602293,'slot':slot,'slotKey':slotKey,'kind':_0x5cd041,'role':role,'listenAddr':listenAddr,'heartbeatAt':_0xb926e,'expiresAt':_0xb926e+_0x141854,'caps':this[_0x3a4f7d(0x725)](_0x5cd041,role),'lifecycle':{'state':lifecycle,'desiredVersionApplied':null},'processing':processing,'meta':meta,'stats':stats};}async['addSupervisedChild'](_0x3ea9ca){const _0x3da7fc=_0x16b568;if(!_0x3ea9ca?.[_0x3da7fc(0xee)])return null;const _0xaa846e=_0x4d5519(_0x3ea9ca[_0x3da7fc(0xee)],_0x3ea9ca['startedAt']);this[_0x3da7fc(0x718)][_0x3da7fc(0x49d)](_0xaa846e,{..._0x3ea9ca,'supervisorKey':_0x3ea9ca[_0x3da7fc(0x77d)]??this[_0x3da7fc(0x452)]});if(this[_0x3da7fc(0x76)])await this[_0x3da7fc(0x303)](this[_0x3da7fc(0x718)][_0x3da7fc(0x6a)](_0xaa846e))[_0x3da7fc(0x618)]?.(()=>{});return _0xaa846e;}[_0x16b568(0x27b)](_0x21fd17){const _0x26c76c=_0x16b568;if(!_0x21fd17)return;return this['_children']['delete'](_0x21fd17),this[_0x26c76c(0x2c9)](_0x21fd17);}[_0x16b568(0x597)](){const _0x697404=_0x16b568,_0x56916e=Date[_0x697404(0x127)](),_0x4f4412=process[_0x697404(0x4d5)](),_0x148db6=(_0x56916e-this[_0x697404(0x58e)])*0x3e8;if(_0x148db6>=0x3d090){const _0xa24ba9=_0x4f4412[_0x697404(0x9b)]-this[_0x697404(0x6ca)][_0x697404(0x9b)]+(_0x4f4412[_0x697404(0x619)]-this[_0x697404(0x6ca)][_0x697404(0x619)]),_0x2793d7=_0x2f5a30[_0x697404(0x19c)]()[_0x697404(0x39d)]||0x1;this['_lastCpuPct']=Math[_0x697404(0x268)](0x64,Math[_0x697404(0x139)](_0xa24ba9/(_0x148db6*_0x2793d7)*0x64)),this[_0x697404(0x682)]=Math['round'](_0x148db6/0x3e8),this[_0x697404(0x6ca)]=_0x4f4412,this[_0x697404(0x58e)]=_0x56916e;}const _0x30839f=process[_0x697404(0x14d)](),_0x5d13b8=this['_threadStats'][_0x697404(0x35f)];let _0x12cfa8=0x0;if(_0x5d13b8>0x0){const _0x7c2895=[this['okdb'],...this[_0x697404(0x229)][_0x697404(0x64c)]?.['values']?.()??[]];for(const _0x3ae5ae of _0x7c2895){const _0x19f71a=_0x3ae5ae[_0x697404(0x322)]?.[_0x697404(0x31d)];if(_0x19f71a)_0x12cfa8+=_0x19f71a[_0x697404(0x5ab)][_0x697404(0x63d)];}}let _0x25f0e6=null;const _0x5c2f9e=_0x5d13b8;if(_0x5c2f9e>0x0){let _0x3df7b4=0x0;for(const _0x2357fb of this[_0x697404(0x681)][_0x697404(0x591)]())_0x3df7b4+=_0x2357fb[_0x697404(0x497)]||0x0;_0x25f0e6={'count':_0x5c2f9e,'heapUsed':_0x3df7b4,'sandbox':_0x5d13b8,'busy':_0x12cfa8};}return{'rss':_0x30839f[_0x697404(0x60d)],'heapUsed':_0x30839f[_0x697404(0x497)],'heapTotal':_0x30839f['heapTotal'],'external':_0x30839f[_0x697404(0x46a)],'cpuPct':this[_0x697404(0x645)],'cpuWindowMs':this[_0x697404(0x682)]??null,'threads':_0x25f0e6,'at':_0x56916e};}[_0x16b568(0x33a)](_0x488bb1,_0x457c19){const _0x3105cb=_0x16b568;if(!_0x488bb1||!_0x457c19)return;this['_threadStats'][_0x3105cb(0x49d)](_0x488bb1,_0x457c19);}[_0x16b568(0x5b3)](_0x4da0a3){const _0x9b2196=_0x16b568;this[_0x9b2196(0x681)][_0x9b2196(0x95)](_0x4da0a3);}[_0x16b568(0x4b6)](_0x39ed7f,_0x57a32c,_0x380863=undefined){const _0x237ec9=_0x16b568,_0x1d9d1e=this[_0x237ec9(0x718)]['get'](_0x39ed7f);if(!_0x1d9d1e||!_0x57a32c)return;if(_0x380863!==undefined)_0x1d9d1e[_0x237ec9(0x40f)]=_0x380863;_0x1d9d1e[_0x237ec9(0x609)]={'rss':_0x57a32c['rss']??null,'heapUsed':_0x57a32c[_0x237ec9(0x497)]??null,'heapTotal':_0x57a32c[_0x237ec9(0x6f1)]??null,'external':_0x57a32c[_0x237ec9(0x46a)]??null,'cpuPct':_0x57a32c[_0x237ec9(0x2d8)]??null,'cpuWindowMs':_0x57a32c[_0x237ec9(0x6c1)]??null,'threads':_0x57a32c[_0x237ec9(0x6b7)]??null,'claims':_0x57a32c[_0x237ec9(0x302)]??null,'envsOpen':_0x57a32c[_0x237ec9(0x125)]??null,'at':Date['now']()};}[_0x16b568(0x345)](){const _0x84e3b8=_0x16b568,_0x1fe5eb=Date[_0x84e3b8(0x127)](),_0x22ff2e=this['okdb']['_role']||{},_0x175cdc=this['_kind']||_0x84e3b8(0x12e);return{'nodeKey':this[_0x84e3b8(0x254)],'processKey':this[_0x84e3b8(0x452)],'instanceId':this['_instanceId'],'pid':process['pid'],'startedAt':this[_0x84e3b8(0x26a)],'instanceStartedAt':this['_startedAt'],'ppid':typeof process[_0x84e3b8(0x56e)]===_0x84e3b8(0x6af)?process[_0x84e3b8(0x56e)]:null,'host':_0x2f5a30['hostname'](),'supervisorKey':this[_0x84e3b8(0x37d)]??null,'version':require$$3[_0x84e3b8(0x3e1)],'kind':_0x175cdc,'role':{'engines':!!_0x22ff2e['engines'],'processors':!!_0x22ff2e[_0x84e3b8(0x43e)],'compaction':_0x22ff2e[_0x84e3b8(0x3a6)],'http':_0x22ff2e[_0x84e3b8(0x91)]},'listenAddr':this[_0x84e3b8(0x22d)]??null,'heartbeatAt':_0x1fe5eb,'expiresAt':_0x1fe5eb+_0x141854,'caps':this[_0x84e3b8(0x725)](_0x175cdc,_0x22ff2e),'lifecycle':{'state':'running','desiredVersionApplied':null},'meta':{...this[_0x84e3b8(0x746)]},'processing':_0x22ff2e[_0x84e3b8(0x43e)]?this[_0x84e3b8(0x734)]():null,'engines':_0x22ff2e[_0x84e3b8(0x39c)]?[...this[_0x84e3b8(0x229)]['_servingEngines']??[]]:null,'singletonClaims':this['_collectSingletonClaims'](),'stats':this[_0x84e3b8(0x597)](),'writers':this['_collectWriterFacet']()};}[_0x16b568(0x3b3)](){const _0x5b0462=_0x16b568,_0x15eb9f={};try{for(const [_0x530a77,_0x3f6164]of this[_0x5b0462(0x229)][_0x5b0462(0x64c)]){try{const _0x589e9e=_0x3f6164[_0x5b0462(0x6cb)]?.();if(!_0x589e9e)continue;if(!_0x589e9e['depth']&&!_0x589e9e[_0x5b0462(0x4d0)]&&!(_0x589e9e[_0x5b0462(0x228)]??0x0)&&!_0x589e9e[_0x5b0462(0x3b8)])continue;_0x15eb9f[_0x530a77]={'depth':_0x589e9e[_0x5b0462(0x5c7)],'oldestPendingMs':_0x589e9e['oldestPendingMs'],'committed':_0x589e9e[_0x5b0462(0x4d0)],'commitsPerSec':_0x589e9e[_0x5b0462(0xca)],'commitP99Ms':_0x589e9e[_0x5b0462(0x295)],'parkedNow':_0x589e9e[_0x5b0462(0x228)]??0x0,'draining':!!_0x589e9e['draining']};}catch{}}}catch{}return Object['keys'](_0x15eb9f)[_0x5b0462(0x39d)]?_0x15eb9f:null;}[_0x16b568(0x69a)](){const _0x4af914=_0x16b568,_0x49385b=process[_0x4af914(0xee)],_0x4f4498=Date['now'](),_0x27084a=_0x147f70=>{const _0x14f729=_0x4af914;if(!_0x147f70)return[];const _0x5c0edd=[];try{for(const {id:_0x1cee04,entry:_0x34aee5}of _0x147f70['list']()){if(_0x34aee5?.['holder']?.[_0x14f729(0xee)]!==_0x49385b)continue;const _0x273ba9=_0x34aee5[_0x14f729(0x75f)]??_0x34aee5[_0x14f729(0x781)]??0x0;if(_0x273ba9+(_0x34aee5[_0x14f729(0x52e)]??0x0)<_0x4f4498)continue;_0x5c0edd['push'](_0x1cee04);}}catch{}return _0x5c0edd;},_0x8188a9=_0x27084a(this[_0x4af914(0x27e)]('compact')),_0x2501ab=_0x27084a(this['_singletonLock'](_0x4af914(0x2ae)));if(!_0x8188a9[_0x4af914(0x39d)]&&!_0x2501ab[_0x4af914(0x39d)])return null;return{'compact':_0x8188a9,'replicate':_0x2501ab};}[_0x16b568(0x27e)](_0x192607){const _0x5c1cfe=_0x16b568;if(!this[_0x5c1cfe(0x229)]?.[_0x5c1cfe(0x1ab)])return null;if(!this[_0x5c1cfe(0x2ba)])this['_singletonLocks']=new Map();let _0x1d7191=this[_0x5c1cfe(0x2ba)][_0x5c1cfe(0x6a)](_0x192607);if(!_0x1d7191)try{_0x1d7191=new _0x1de777(this['okdb'][_0x5c1cfe(0x1ab)],{'namespace':_0x192607}),this['_singletonLocks'][_0x5c1cfe(0x49d)](_0x192607,_0x1d7191);}catch{return null;}return _0x1d7191;}['_buildProcessingFacet'](){const _0xe64b1f=_0x16b568,_0x178b56=[];try{for(const [_0x4cba1c,_0x3f6d55]of this[_0xe64b1f(0x229)][_0xe64b1f(0x64c)]){if(_0x4cba1c[_0xe64b1f(0x42e)]('~'))continue;for(const _0x40e4c5 of _0x3f6d55['processor'][_0xe64b1f(0x30d)]())_0x178b56[_0xe64b1f(0x2f9)]({..._0x40e4c5,'env':_0x4cba1c});}}catch{}return{'participate':this[_0xe64b1f(0x229)][_0xe64b1f(0x43e)]?.['_participate']??![],'processors':_0x178b56};}['_ensureDesired'](){const _0x51f7e7=_0x16b568;if(this[_0x51f7e7(0x3f1)])return!![];const _0x1abd00=this[_0x51f7e7(0x229)][_0x51f7e7(0x1ab)];if(!_0x1abd00)return![];return this['_desired']=_0x1abd00[_0x51f7e7(0x56a)](_0x4e41c6,{'dupSort':![]}),this[_0x51f7e7(0x52b)]=_0x1abd00['openDB'](_0x17db9f,{'dupSort':![]}),!![];}async['_migrateVocab'](){const _0x3c84d2=_0x16b568;if(!this[_0x3c84d2(0x3b4)]())return;const _0x5a6a31=_0x3c84d2(0x1ac),_0x2dfa11=0x1,_0x16582a=this[_0x3c84d2(0x3f1)]['get'](_0x5a6a31)??0x0;if(_0x16582a>=_0x2dfa11)return;const _0x2b9cf6=_0x14960a=>{const _0x12da23=_0x3c84d2;if(_0x14960a===_0x12da23(0x259))return'single';if(_0x14960a==='async')return _0x12da23(0x5e2);return _0x14960a;};await this['okdb'][_0x3c84d2(0x5bc)][_0x3c84d2(0x385)][_0x3c84d2(0x4f9)](()=>{const _0x581b5d=_0x3c84d2;for(const _0x1f8956 of[_0x581b5d(0x3bb),_0x581b5d(0x561)]){for(const {key:_0xf388d5,value:_0x2659f8}of this[_0x581b5d(0x3f1)][_0x581b5d(0x1c1)]({'start':_0x1f8956,'end':_0x1f8956+'\xff'})){if(typeof _0xf388d5!=='string'||!_0xf388d5[_0x581b5d(0x42e)](_0x1f8956))break;const _0x305b68=_0x2b9cf6(_0x2659f8[_0x581b5d(0x38b)]);if(_0x305b68!==_0x2659f8[_0x581b5d(0x38b)])this[_0x581b5d(0x3f1)]['put'](_0xf388d5,{..._0x2659f8,'mode':_0x305b68});}}this[_0x581b5d(0x3f1)][_0x581b5d(0x463)](_0x5a6a31,_0x2dfa11);});}[_0x16b568(0x706)](){const _0x579ec0=_0x16b568;return!!this[_0x579ec0(0x3f1)];}[_0x16b568(0x4c0)](_0x1e572b,_0xa9a8a){const _0xdfec0d=_0x16b568;if(!this[_0xdfec0d(0x3b4)]())return null;const _0x234431=_0x1e572b+'/'+_0xa9a8a;return this['_refreshDesiredSnapshot'](),this[_0xdfec0d(0x271)][_0xdfec0d(0x6a)](_0x234431)??this[_0xdfec0d(0x3f1)]['get'](_0x234431)??null;}['_refreshDesiredSnapshot'](){const _0x141e14=_0x16b568;if(!_0x4ac07b)return;try{this[_0x141e14(0x229)][_0x141e14(0x5bc)]?.['db']?.[_0x141e14(0x662)]?.();}catch{}}async[_0x16b568(0x197)](_0x5bdb64,_0x397652,_0x2223a){const _0x2b80d7=_0x16b568;if(!this[_0x2b80d7(0x3b4)]())return null;const _0x2f53be=_0x5bdb64+'/'+_0x397652;this[_0x2b80d7(0x1c2)]();const _0x41721a=this['_desiredOverlay']['get'](_0x2f53be)??this['_desired'][_0x2b80d7(0x6a)](_0x2f53be)??{'version':0x0},_0x1a2a6b=(_0x41721a[_0x2b80d7(0x3e1)]||0x0)+0x1,_0x1af576={..._0x41721a,..._0x2223a,'version':_0x1a2a6b,'updatedAt':Date[_0x2b80d7(0x127)]()};this[_0x2b80d7(0x271)]['set'](_0x2f53be,_0x1af576);try{await this[_0x2b80d7(0x229)]['_systemEnv']['_writer'][_0x2b80d7(0x4f9)](()=>{const _0x141188=_0x2b80d7;this['_desired'][_0x141188(0x463)](_0x2f53be,_0x1af576);});}finally{if(this['_desiredOverlay'][_0x2b80d7(0x6a)](_0x2f53be)===_0x1af576)this[_0x2b80d7(0x271)]['delete'](_0x2f53be);}return _0x1a2a6b;}[_0x16b568(0x272)](_0xe9a767){const _0x171b6e=_0x16b568;if(!this['_ensureDesired']())return[];this[_0x171b6e(0x1c2)]();const _0x4ac355=_0xe9a767+'/',_0x2e7209=[];for(const {key:_0x4d992c,value:_0x125cb6}of this[_0x171b6e(0x3f1)][_0x171b6e(0x1c1)]({'start':_0x4ac355,'end':_0x4ac355+'\xff'})){if(typeof _0x4d992c!==_0x171b6e(0xe7)||!_0x4d992c['startsWith'](_0x4ac355))break;_0x2e7209['push']({'key':_0x4d992c[_0x171b6e(0x13a)](_0x4ac355[_0x171b6e(0x39d)]),'value':_0x125cb6});}return _0x2e7209;}[_0x16b568(0x49c)](_0x40429d){const _0x207a02=_0x16b568;if(!this[_0x207a02(0x3b4)]())return null;return this[_0x207a02(0x52b)]['get'](_0x40429d)??null;}async['bumpCmd'](_0x191e35,_0x126099,_0x5d8ca3={}){const _0x26c707=_0x16b568;if(!this[_0x26c707(0x3b4)]())return null;let _0x42b593;return await this[_0x26c707(0x229)]['_systemEnv'][_0x26c707(0x385)][_0x26c707(0x4f9)](()=>{const _0x4de7e9=_0x26c707,_0x22cbbc=this[_0x4de7e9(0x52b)]['get'](_0x191e35)||{'epoch':0x0};_0x42b593=(_0x22cbbc[_0x4de7e9(0x45a)]||0x0)+0x1,this['_cmd'][_0x4de7e9(0x463)](_0x191e35,{..._0x22cbbc,..._0x5d8ca3,'cmd':_0x126099,'epoch':_0x42b593,'updatedAt':Date[_0x4de7e9(0x127)]()});}),_0x42b593;}}return okdbProcessRegistry={'OKDBProcessRegistry':_0x1cfcfa,'nodeKey':_0x4d5519,'logicalKey':_0x3fb6d6,'slotKey':_0x3bd861,'PROCESS_ENV':_0x600417,'NODE_TYPE':_0x109a13},okdbProcessRegistry;}var okdbChangefeed,hasRequiredOkdbChangefeed;function _0x8cd7(_0x1cbba2,_0x26366c){_0x1cbba2=_0x1cbba2-0x67;const _0x166efe=_0x166e();let _0x8cd74e=_0x166efe[_0x1cbba2];return _0x8cd74e;}function requireOkdbChangefeed(){const _0x1c2419=_0x3d20e4;if(hasRequiredOkdbChangefeed)return okdbChangefeed;hasRequiredOkdbChangefeed=0x1;const _0x5c820d=require$$0$6,{EVENTS:_0x5f2dd8,CHANGE_ACTIONS:_0x2fbc26}=requireOkdbEnums(),{LOOP:_0x2a1d9e}=requireOkdbLoopMonitor(),_0x258028=Number(process.env.OKDB_CHANGEFEED_QUANTUM)||0x3e8,_0x215a38=0x5,_0x46fcd2=0x2710;class _0x527f6d extends _0x5c820d{constructor(_0x2446b2,_0x32e254={}){const _0x1ab7d0=_0x8cd7;super(),this['okdb']=_0x2446b2,this[_0x1ab7d0(0x57e)]=_0x32e254[_0x1ab7d0(0x447)]??_0x258028,this[_0x1ab7d0(0x346)]=_0x32e254[_0x1ab7d0(0x2ca)]??_0x215a38,this['_dedupeMax']=_0x32e254[_0x1ab7d0(0x722)]??_0x46fcd2,this[_0x1ab7d0(0x589)]=![],this[_0x1ab7d0(0x546)]=new Map(),this['_baselines']=new Map(),this['_pending']=new Map(),this[_0x1ab7d0(0xe6)]=null,this[_0x1ab7d0(0x22a)]=![],this[_0x1ab7d0(0x6f4)]=new Set(),this[_0x1ab7d0(0x655)]=new Set(),this[_0x1ab7d0(0x3b1)]=_0x5df90f=>this[_0x1ab7d0(0x92)](_0x5df90f),this[_0x1ab7d0(0x61f)]=_0x3b7615=>this[_0x1ab7d0(0x4e6)](_0x3b7615),this[_0x1ab7d0(0x3af)]=_0x1e81cd=>this['_handlePoke'](_0x1e81cd),this['_onStop']=()=>this[_0x1ab7d0(0x226)]();}[_0x1c2419(0x570)](){const _0x292596=_0x1c2419;if(this[_0x292596(0x589)])return;this[_0x292596(0x589)]=!![];for(const [_0x47110a,_0x53f841]of this['okdb']['_envs']){if(_0x47110a[_0x292596(0x42e)]('~'))continue;try{_0x53f841[_0x292596(0x30e)]();}catch{}}for(const [_0x5c0cff,_0x2b1bce]of this[_0x292596(0x229)][_0x292596(0x64c)]){if(_0x5c0cff['startsWith']('~'))continue;try{this[_0x292596(0x520)]['set'](_0x5c0cff,_0x2b1bce[_0x292596(0x670)]()||0x0);}catch{}}const {events:_0x4b5aa3}=this[_0x292596(0x229)];_0x4b5aa3['on'](_0x5f2dd8['ITEM_PENDING'],this[_0x292596(0x61f)]),_0x4b5aa3['on'](_0x5f2dd8[_0x292596(0x512)],this['_onItem']),_0x4b5aa3['on'](_0x5f2dd8['ITEM_UPDATE'],this[_0x292596(0x3b1)]),_0x4b5aa3['on'](_0x5f2dd8['ITEM_REMOVE'],this[_0x292596(0x3b1)]),_0x4b5aa3['on'](_0x5f2dd8[_0x292596(0x6e5)],this[_0x292596(0x3af)]),_0x4b5aa3[_0x292596(0x375)](_0x5f2dd8['SYSTEM_STOPPED'],this[_0x292596(0x9a)]);}[_0x1c2419(0x226)](){const _0x340cea=_0x1c2419;if(!this['_started'])return;this['_started']=![];const {events:_0x2c7cf7}=this[_0x340cea(0x229)];_0x2c7cf7[_0x340cea(0x567)](_0x5f2dd8[_0x340cea(0x4a5)],this[_0x340cea(0x61f)]),_0x2c7cf7['off'](_0x5f2dd8['ITEM_CREATE'],this[_0x340cea(0x3b1)]),_0x2c7cf7[_0x340cea(0x567)](_0x5f2dd8[_0x340cea(0x606)],this[_0x340cea(0x3b1)]),_0x2c7cf7[_0x340cea(0x567)](_0x5f2dd8[_0x340cea(0x203)],this[_0x340cea(0x3b1)]),_0x2c7cf7[_0x340cea(0x567)](_0x5f2dd8['SYSTEM_POKE'],this[_0x340cea(0x3af)]);try{_0x2c7cf7['off'](_0x5f2dd8[_0x340cea(0x2d6)],this[_0x340cea(0x9a)]);}catch{}this[_0x340cea(0xe6)]&&(clearTimeout(this[_0x340cea(0xe6)]),this[_0x340cea(0xe6)]=null),this[_0x340cea(0x7b)][_0x340cea(0x209)](),this[_0x340cea(0x546)][_0x340cea(0x209)](),this[_0x340cea(0x520)][_0x340cea(0x209)](),this[_0x340cea(0x6f4)][_0x340cea(0x209)](),this['_pendingLocal'][_0x340cea(0x209)]();}[_0x1c2419(0x1d7)](_0x32bed2,_0x22d34a,_0x1b465b,_0x1069d7){return _0x32bed2+'\x00'+_0x22d34a+'\x00'+_0x1b465b+'\x00'+_0x1069d7;}[_0x1c2419(0x627)](_0x9ff229,_0x36f7f8,_0x48e05f,_0x401c20){const _0x3a9926=_0x1c2419,_0x57b1cd=this[_0x3a9926(0x1d7)](_0x9ff229,_0x36f7f8,_0x48e05f,_0x401c20);if(this[_0x3a9926(0x6f4)][_0x3a9926(0x469)](_0x57b1cd))return![];this['_seen'][_0x3a9926(0x3e9)](_0x57b1cd);if(this[_0x3a9926(0x6f4)]['size']>this[_0x3a9926(0x100)]){const _0x4f2b79=this['_seen'][_0x3a9926(0x591)]()[_0x3a9926(0x5c5)]()['value'];this[_0x3a9926(0x6f4)][_0x3a9926(0x95)](_0x4f2b79);}return!![];}[_0x1c2419(0x4e6)](_0x41595c){const _0x7a7e2e=_0x1c2419;if(!this[_0x7a7e2e(0x589)]||!_0x41595c)return;const {env:_0x44fa9d,type:_0x41351f,key:_0x51b061,clock:_0x5ec30b}=_0x41595c;if(_0x44fa9d==null||_0x41351f==null||_0x51b061==null)return;if(typeof _0x44fa9d==='string'&&_0x44fa9d['startsWith']('~'))return;if(typeof _0x41351f===_0x7a7e2e(0xe7)&&_0x41351f[_0x7a7e2e(0x42e)]('~'))return;this['_pendingLocal'][_0x7a7e2e(0x3e9)](this[_0x7a7e2e(0x1d7)](_0x44fa9d,_0x41351f,_0x51b061,_0x5ec30b)),this[_0x7a7e2e(0x655)][_0x7a7e2e(0x35f)]>this['_dedupeMax']&&this[_0x7a7e2e(0x655)][_0x7a7e2e(0x95)](this['_pendingLocal'][_0x7a7e2e(0x591)]()[_0x7a7e2e(0x5c5)]()[_0x7a7e2e(0x101)]);}[_0x1c2419(0x92)](_0x169acf){const _0x4c60f1=_0x1c2419;if(!this[_0x4c60f1(0x589)]||!_0x169acf)return;const {env:_0x5d5e4a,type:_0x526711,key:_0x3c0630,clock:_0x138d52,origin:_0x465c92,action:_0x72741c,newValue:_0x3cbdbf,oldValue:_0x38d446}=_0x169acf;if(_0x5d5e4a==null||_0x526711==null||_0x3c0630==null)return;if(typeof _0x5d5e4a==='string'&&_0x5d5e4a[_0x4c60f1(0x42e)]('~'))return;if(typeof _0x526711===_0x4c60f1(0xe7)&&_0x526711['startsWith']('~'))return;this[_0x4c60f1(0x655)][_0x4c60f1(0x95)](this[_0x4c60f1(0x1d7)](_0x5d5e4a,_0x526711,_0x3c0630,_0x138d52));if(!this[_0x4c60f1(0x627)](_0x5d5e4a,_0x526711,_0x3c0630,_0x138d52))return;const _0x116297=_0x72741c===_0x2fbc26[_0x4c60f1(0x383)]?_0x4c60f1(0x34e):'put';this[_0x4c60f1(0x25c)](_0x4c60f1(0x39a),{'env':_0x5d5e4a,'type':_0x526711,'key':_0x3c0630,'op':_0x116297,'clock':_0x138d52,'origin':_0x465c92,'value':_0x116297==='remove'?null:_0x3cbdbf,'prevValue':_0x38d446});}[_0x1c2419(0x59d)](_0x2374f0){const _0x10efd9=_0x1c2419;if(!this['_started'])return;if(!_0x2374f0||typeof _0x2374f0[_0x10efd9(0x124)]!==_0x10efd9(0xe7)||typeof _0x2374f0[_0x10efd9(0x66f)]!==_0x10efd9(0xe7))return;const {env:_0x1714d0,type:_0x17debf}=_0x2374f0;if(_0x1714d0[_0x10efd9(0x42e)]('~')||_0x17debf['startsWith']('~'))return;this[_0x10efd9(0x7b)][_0x10efd9(0x49d)](_0x1714d0+'\x00'+_0x17debf,{'env':_0x1714d0,'type':_0x17debf}),this[_0x10efd9(0x559)]();}[_0x1c2419(0x559)](){const _0x59e8db=_0x1c2419;if(this['_flushTimer'])return;const _0x37ef46=()=>{const _0x40e1c6=_0x8cd7;this[_0x40e1c6(0xe6)]=null,this[_0x40e1c6(0x5f0)]()['catch'](()=>{});};this[_0x59e8db(0xe6)]=setTimeout(_0x37ef46,this[_0x59e8db(0x346)]>0x0?this['_flushDebounce']:0x0);}async[_0x1c2419(0x5f0)](){const _0x28e808=_0x1c2419;if(this[_0x28e808(0x22a)]){this[_0x28e808(0x559)]();return;}this[_0x28e808(0x22a)]=!![];try{const _0x281294=[...this[_0x28e808(0x7b)][_0x28e808(0x591)]()];this['_pending']['clear']();let _0x575db8=![];for(const {env:_0x1d6e6a,type:_0x1fa8b7}of _0x281294){try{const _0x483d8d=await this['_drainOne'](_0x1d6e6a,_0x1fa8b7);if(_0x483d8d)_0x575db8=!![];}catch{this[_0x28e808(0x7b)][_0x28e808(0x49d)](_0x1d6e6a+'\x00'+_0x1fa8b7,{'env':_0x1d6e6a,'type':_0x1fa8b7}),_0x575db8=!![];}}if(_0x575db8||this[_0x28e808(0x7b)][_0x28e808(0x35f)]>0x0)this[_0x28e808(0x559)]();}finally{this[_0x28e808(0x22a)]=![];}}async[_0x1c2419(0x266)](_0x118af9,_0x48fa7a){const _0x291a58=_0x1c2419,_0x2d5053=await this['okdb'][_0x291a58(0x587)](_0x118af9),_0xdb648=_0x118af9+'\x00'+_0x48fa7a;!this[_0x291a58(0x546)][_0x291a58(0x469)](_0xdb648)&&(!this[_0x291a58(0x520)][_0x291a58(0x469)](_0x118af9)&&(_0x2d5053[_0x291a58(0x30e)](),this['_baselines'][_0x291a58(0x49d)](_0x118af9,_0x2d5053['getClock']()||0x0)),this[_0x291a58(0x546)][_0x291a58(0x49d)](_0xdb648,this['_baselines'][_0x291a58(0x6a)](_0x118af9)));const _0x23fb12=this[_0x291a58(0x546)]['get'](_0xdb648),_0x24b75e=_0x2d5053[_0x291a58(0x670)](_0x48fa7a)||0x0;if(_0x24b75e<=_0x23fb12)return![];const _0x1ca2ae=_0x23fb12+this[_0x291a58(0x57e)],_0x221677=Math[_0x291a58(0x268)](_0x24b75e,_0x1ca2ae),_0x28e2e2=_0x2a1d9e[_0x291a58(0x1f9)]?_0x2a1d9e[_0x291a58(0x127)]():0x0,_0x73e2cd=Array[_0x291a58(0x690)](_0x2d5053['getChanges'](_0x48fa7a,_0x23fb12+0x1,_0x221677));let _0x20fdd6=_0x23fb12;for(const _0x14e89c of _0x73e2cd){const {clock:_0x10f06d,key:_0x569227,action:_0x50e277,origin:_0x531fc2}=_0x14e89c;if(_0x10f06d>_0x20fdd6)_0x20fdd6=_0x10f06d;if(_0x569227==null)continue;if(this[_0x291a58(0x655)][_0x291a58(0x469)](this[_0x291a58(0x1d7)](_0x118af9,_0x48fa7a,_0x569227,_0x10f06d)))continue;if(!this['_markSeen'](_0x118af9,_0x48fa7a,_0x569227,_0x10f06d))continue;let _0x7ee219,_0x2f862e;if(_0x50e277===_0x2fbc26[_0x291a58(0x383)])_0x7ee219=_0x291a58(0x34e),_0x2f862e=null;else{const _0x1f2b62=_0x2d5053[_0x291a58(0x6a)](_0x48fa7a,_0x569227);_0x1f2b62==null?(_0x7ee219='remove',_0x2f862e=null):(_0x7ee219=_0x291a58(0x463),_0x2f862e=_0x1f2b62);}this[_0x291a58(0x25c)](_0x291a58(0x39a),{'env':_0x118af9,'type':_0x48fa7a,'key':_0x569227,'op':_0x7ee219,'clock':_0x10f06d,'origin':_0x531fc2,'value':_0x2f862e});}if(_0x2a1d9e[_0x291a58(0x1f9)])_0x2a1d9e['note'](_0x291a58(0x683)+_0x118af9+':'+_0x48fa7a,_0x2a1d9e['now']()-_0x28e2e2,'n='+_0x73e2cd[_0x291a58(0x39d)]);return this['_cursors']['set'](_0xdb648,Math[_0x291a58(0x68c)](_0x20fdd6,_0x221677)),_0x2d5053[_0x291a58(0x670)](_0x48fa7a)>_0x221677;}[_0x1c2419(0x170)](){const _0x2f3882=_0x1c2419;return{'started':this['_started'],'quantum':this[_0x2f3882(0x57e)],'flushDebounce':this['_flushDebounce'],'cursors':Object[_0x2f3882(0x66e)]([...this['_cursors'][_0x2f3882(0x61d)]()]['map'](([_0x549ecb,_0x35a76c])=>[_0x549ecb[_0x2f3882(0x416)]('\x00',':'),_0x35a76c])),'pending':this[_0x2f3882(0x7b)][_0x2f3882(0x35f)],'seen':this[_0x2f3882(0x6f4)]['size']};}}return _0x527f6d[_0x1c2419(0x32b)]=_0x258028,okdbChangefeed={'OKDBChangefeed':_0x527f6d},okdbChangefeed;}var okdbCluster,hasRequiredOkdbCluster;function requireOkdbCluster(){const _0x32d610=_0x3d20e4;if(hasRequiredOkdbCluster)return okdbCluster;hasRequiredOkdbCluster=0x1;const _0x3f10fd=require$$1$1,_0x43552c=require$$1,{EVENTS:_0x3dbb06}=requireOkdbEnums(),_0x1255e5=require$$0,{slotKey:_0x9cb5b4}=requireOkdbProcessRegistry(),_0x3bd560=Number(process.env.OKDB_CLUSTER_RESPAWN_BACKOFF_MS)||0xfa,_0x5c3569=0xfa0,_0x58c971=0x5,_0x190832=0x2710,_0x59677c=0xbb8,_0x225072=0x7d0,_0x5705b5=_0x32d610(0x4fb),_0x4ac35b=_0x32d610(0x4b1),_0xb8e8e5=_0x32d610(0x24e),_0x434999=_0x32d610(0x609),_0x141e3e=[_0x3dbb06['VIEW_PROGRESS'],_0x3dbb06[_0x32d610(0x673)],_0x3dbb06[_0x32d610(0x18d)],_0x3dbb06[_0x32d610(0x763)],_0x3dbb06[_0x32d610(0x234)],_0x3dbb06[_0x32d610(0x737)],_0x3dbb06[_0x32d610(0x57d)],_0x3dbb06[_0x32d610(0x4ef)],_0x32d610(0x58f),_0x32d610(0x4b7),_0x32d610(0x2cd),_0x32d610(0x523),_0x32d610(0x75a),_0x32d610(0x629)],_0x29dcc0=Number(process.env.OKDB_CLUSTER_STATUS_MS)||0x7d0,_0x2930b4=0x64;function _0x345a37(_0x49c622){const _0x37ad85=_0x32d610;if(!_0x49c622)return _0x37ad85(0x359);const _0x420b2b=(_0x49c622[_0x37ad85(0x43e)]||[])[_0x37ad85(0x757)](_0x3cf349=>[_0x3cf349[_0x37ad85(0x124)],_0x3cf349['id'],_0x3cf349[_0x37ad85(0x38b)],_0x3cf349[_0x37ad85(0x1a3)],!!_0x3cf349[_0x37ad85(0x3a5)],!!_0x3cf349[_0x37ad85(0x21c)],!!_0x3cf349[_0x37ad85(0x1d9)],_0x3cf349['heldBy']?.[_0x37ad85(0xee)]??null,_0x3cf349[_0x37ad85(0x492)]?String(_0x3cf349[_0x37ad85(0x492)]?.[_0x37ad85(0x5e6)]??_0x3cf349['error']):null]);return JSON['stringify']([!!_0x49c622['participate'],_0x420b2b]);}function _0x5c8d36({workers:_0x886655,makeOkdb:_0x17b1a8,port:_0x59085f,primaryOkdb:_0x3780de,childEntry:childEntry=![],workerEnv:workerEnv=null,workerRole:workerRole=null,listenAddr:listenAddr=null}={}){const _0x2bf7dd=_0x32d610;if(_0x3f10fd['isPrimary'])return childEntry&&_0x3f10fd[_0x2bf7dd(0x24b)]({'exec':_0x43552c[_0x2bf7dd(0x10b)](__dirname,'okdb-http-worker-child.js'),'args':[],'execArgv':((()=>{const _0xf90b5a=_0x2bf7dd,_0x2b907f=[];for(let _0x8e6858=0x0;_0x8e6858<process[_0xf90b5a(0x496)][_0xf90b5a(0x39d)];_0x8e6858++){const _0x5490c2=process[_0xf90b5a(0x496)][_0x8e6858];if(_0x5490c2[_0xf90b5a(0x42e)](_0xf90b5a(0xdd))||_0x5490c2[_0xf90b5a(0x42e)]('--watch')||_0x5490c2[_0xf90b5a(0x42e)](_0xf90b5a(0x6c4)))continue;if(_0x5490c2==='-e'||_0x5490c2===_0xf90b5a(0x1f8)||_0x5490c2==='-p'||_0x5490c2===_0xf90b5a(0xec)){_0x8e6858++;continue;}_0x2b907f[_0xf90b5a(0x2f9)](_0x5490c2);}return _0x2b907f;})())}),_0x10e97b({'workers':_0x886655,'port':_0x59085f,'primaryOkdb':_0x3780de,'workerEnv':workerEnv,'workerRole':workerRole,'listenAddr':listenAddr??':'+_0x59085f});return _0x10352c({'makeOkdb':_0x17b1a8,'port':_0x59085f});}function _0x10e97b({workers:_0x427246,port:_0x2df4c8,primaryOkdb:_0x51b18f,workerEnv:_0x500f4d,workerRole:_0x544d34,listenAddr:_0x5b99a2}){const _0x41fa2f=_0x32d610,_0x2a85df=new Map(),_0x5eb382=new Map();let _0x338143=![];const _0x562465=_0x10fcc5=>_0x10fcc5?.[_0x41fa2f(0x26f)],_0x48a9b0=_0x38096d=>{const _0x2569e5=_0x41fa2f,_0xeeacea=_0x3f10fd['fork']({...process.env,..._0x500f4d||{},'OKDB_CLUSTER_SLOT':String(_0x38096d)});return _0xeeacea[_0x2569e5(0x26f)]=_0x38096d,_0x2a85df[_0x2569e5(0x49d)](_0xeeacea[_0x2569e5(0x3d3)]['pid'],{'worker':_0xeeacea,'startedAt':Date[_0x2569e5(0x127)](),'slot':_0x38096d}),_0xeeacea['on']('error',_0x2778bf=>{const _0x4ad0f1=_0x2569e5;console[_0x4ad0f1(0x24e)](_0x4ad0f1(0x1e5)+_0xeeacea[_0x4ad0f1(0x3d3)]['pid']+'\x20ipc\x20error:\x20'+(_0x2778bf?.['message']??_0x2778bf));}),_0xeeacea['on'](_0x2569e5(0x62c),()=>_0x52f2d5()),_0xeeacea;},_0x3c3361=_0x1f1f64=>{const _0xde3acb=_0x41fa2f;for(const {worker:_0x4ecca7}of _0x2a85df[_0xde3acb(0x591)]()){if(_0x4ecca7[_0xde3acb(0x204)]()||!_0x4ecca7['isConnected']())continue;try{_0x4ecca7[_0xde3acb(0x3a7)](_0x1f1f64);}catch{}}};_0x51b18f?.[_0x41fa2f(0x3fd)]?.({'kind':_0x41fa2f(0x73b),'listenAddr':_0x5b99a2})[_0x41fa2f(0x618)](()=>{}),_0x51b18f?.[_0x41fa2f(0x5c9)]?.[_0x41fa2f(0x4db)]?.({'workersConfigured':_0x427246});const _0x11bf2e={'engines':!![],'processors':!![],'compaction':!![],..._0x544d34,'http':!![]},_0x52f2d5=()=>{const _0x4895e4=_0x41fa2f,_0x2e815d=_0x51b18f?.[_0x4895e4(0x5c9)];if(!_0x2e815d||!_0x2e815d[_0x4895e4(0x76)])return;const _0x3756c3=_0x2e815d[_0x4895e4(0x131)];for(const {worker:_0x55eb17,startedAt:_0x3a71e3,slot:_0x21f1d7,stats:_0x3821f8,processing:_0x1fd6d2}of _0x2a85df[_0x4895e4(0x591)]()){if(_0x55eb17[_0x4895e4(0x204)]())continue;const _0x402942=_0x2e815d[_0x4895e4(0x706)]?.()&&_0x2e815d['getDesired'](_0x4895e4(0x257),_0x250a68(_0x21f1d7))?.[_0x4895e4(0x2ac)]===!![];_0x2e815d[_0x4895e4(0x303)]({'pid':_0x55eb17['process']['pid'],'startedAt':_0x3a71e3,'kind':_0x4895e4(0x35d),'supervisorKey':_0x3756c3,'slot':_0x21f1d7,'slotKey':_0x250a68(_0x21f1d7),'role':_0x11bf2e,'listenAddr':_0x5b99a2,'lifecycle':_0x402942?_0x4895e4(0x35a):_0x4895e4(0x364),'processing':_0x1fd6d2??null,'stats':_0x3821f8??null})['catch'](()=>{});}},_0x250a68=_0x5c5e2a=>_0x9cb5b4(_0x41fa2f(0x432)+_0x2df4c8,_0x5c5e2a),_0x250097=_0x241d7c=>{const _0x30c1db=_0x41fa2f,_0x453245=_0x51b18f?.[_0x30c1db(0x5c9)];if(!_0x453245?.[_0x30c1db(0x706)]?.())return![];return _0x453245[_0x30c1db(0x4c0)]('slot',_0x250a68(_0x241d7c))?.[_0x30c1db(0x2ac)]===!![];};for(let _0x4c8c62=0x0;_0x4c8c62<_0x427246;_0x4c8c62++){const _0x1ce94b=_0x250097(_0x4c8c62);_0x5eb382[_0x41fa2f(0x49d)](_0x4c8c62,{'deaths':[],'consecutiveFailures':0x0,'dead':_0x1ce94b,'respawnTimer':null}),_0x1ce94b?console[_0x41fa2f(0x24e)](_0x41fa2f(0x409)+_0x4c8c62+_0x41fa2f(0x334)):_0x48a9b0(_0x4c8c62);}const _0x4bd21c=()=>{const _0x422ee9=_0x41fa2f,_0x18fc64=_0x51b18f?.[_0x422ee9(0x5c9)];if(!_0x18fc64?.[_0x422ee9(0x76)]||!_0x18fc64[_0x422ee9(0x706)]?.())return;for(const [_0x222d3c,_0x447d66]of _0x5eb382[_0x422ee9(0x61d)]()){const _0x4f6985=_0x18fc64[_0x422ee9(0x4c0)](_0x422ee9(0x257),_0x250a68(_0x222d3c)),_0x3aaf05=_0x4f6985?.['decommission']===!![],_0x35a99e=_0x4f6985?.[_0x422ee9(0x435)]===!![];if(_0x3aaf05&&!_0x447d66['dead']){_0x447d66[_0x422ee9(0x368)]=!![];_0x447d66[_0x422ee9(0x651)]&&(clearTimeout(_0x447d66['respawnTimer']),_0x447d66['respawnTimer']=null);for(const {worker:_0x3b19ee}of _0x2a85df[_0x422ee9(0x591)]()){if(_0x562465(_0x3b19ee)!==_0x222d3c||_0x3b19ee[_0x422ee9(0x204)]())continue;try{if(_0x35a99e)_0x3b19ee[_0x422ee9(0x3d3)]['kill'](_0x422ee9(0x476));else _0x3b19ee[_0x422ee9(0x5b7)]()&&_0x3b19ee[_0x422ee9(0x2bf)]();}catch{}}console[_0x422ee9(0x24e)](_0x422ee9(0x716)+(_0x35a99e?'hard-killed':_0x422ee9(0x330))+_0x422ee9(0x183)+_0x222d3c+_0x422ee9(0x382));}else{if(!_0x3aaf05&&_0x447d66[_0x422ee9(0x368)]&&_0x4f6985){_0x447d66[_0x422ee9(0x368)]=![],_0x447d66[_0x422ee9(0x6dd)]=[],_0x447d66[_0x422ee9(0x772)]=0x0;const _0x616370=[..._0x2a85df[_0x422ee9(0x591)]()][_0x422ee9(0x35c)](({worker:_0x212893})=>_0x562465(_0x212893)===_0x222d3c&&!_0x212893[_0x422ee9(0x204)]());!_0x616370&&!_0x338143&&(_0x48a9b0(_0x222d3c),console[_0x422ee9(0x24e)](_0x422ee9(0x74c)+_0x222d3c));}}}},_0x126b93=()=>{try{_0x4bd21c();}catch{}};_0x51b18f?.['events']?.['on']?.(_0x3dbb06['SYSTEM_PROC'],_0x126b93);const _0x5b8f4a=[];if(_0x51b18f?.[_0x41fa2f(0x194)]?.['on'])for(const _0x4b204a of _0x141e3e){const _0x5b581d=_0x7fd832=>{_0x3c3361({[_0x5705b5]:_0x4ac35b,'event':_0x4b204a,'data':_0x7fd832??{}});};_0x51b18f['events']['on'](_0x4b204a,_0x5b581d),_0x5b8f4a['push']({'event':_0x4b204a,'handler':_0x5b581d});}const _0x5ce293=setInterval(()=>{_0x4bd21c(),_0x52f2d5();},_0x29dcc0);_0x5ce293[_0x41fa2f(0xe9)]?.();const _0x2b02f6=(_0x1cf89a,_0x2b90b1)=>{const _0x3274b7=_0x41fa2f;if(!_0x2b90b1||typeof _0x2b90b1!==_0x3274b7(0x5d4)||_0x2b90b1[_0x5705b5]!==_0xb8e8e5)return;if(!_0x51b18f?.[_0x3274b7(0x24e)]?.[_0x3274b7(0x676)])return;const _0x5e3002=_0x2b90b1[_0x3274b7(0x484)]||{};_0x51b18f[_0x3274b7(0x24e)][_0x3274b7(0x676)]({..._0x5e3002,'msg':'[w'+_0x2b90b1[_0x3274b7(0x257)]+']\x20'+(_0x5e3002[_0x3274b7(0x72e)]??''),'meta':{..._0x5e3002[_0x3274b7(0xc9)]||{},'worker':_0x2b90b1[_0x3274b7(0x257)],'workerPid':_0x2b90b1['pid']}});};_0x3f10fd['on'](_0x41fa2f(0x5e6),_0x2b02f6);const _0x3ef83f=(_0x4d0302,_0x571d55)=>{const _0x221f50=_0x41fa2f;if(!_0x571d55||typeof _0x571d55!==_0x221f50(0x5d4)||_0x571d55[_0x5705b5]!==_0x434999)return;const _0x1bb621=_0x2a85df['get'](_0x4d0302[_0x221f50(0x3d3)]['pid']);if(_0x1bb621){_0x1bb621[_0x221f50(0x609)]={..._0x571d55['stats'],'at':Date['now']()};if(_0x571d55['processing']!==undefined){const _0x2f767a=_0x345a37(_0x571d55[_0x221f50(0x40f)]);_0x2f767a!==_0x1bb621[_0x221f50(0x25e)]&&(_0x1bb621['processingSig']=_0x2f767a,_0x3674b6()),_0x1bb621['processing']=_0x571d55[_0x221f50(0x40f)];}}};let _0x370b8f=null;const _0x3674b6=()=>{const _0x73ee18=_0x41fa2f;if(_0x370b8f||_0x338143)return;_0x370b8f=setTimeout(()=>{_0x370b8f=null;if(!_0x338143)_0x52f2d5();},_0x2930b4),_0x370b8f[_0x73ee18(0xe9)]?.();};_0x3f10fd['on'](_0x41fa2f(0x5e6),_0x3ef83f),_0x3f10fd['on'](_0x41fa2f(0x4e7),(_0x4d5aec,_0x350dfe,_0x44b6d5)=>{const _0x84a5de=_0x41fa2f,_0x2e24fe=_0x4d5aec['process'][_0x84a5de(0xee)],_0x138285=_0x562465(_0x4d5aec),_0x483f21=_0x2a85df['get'](_0x2e24fe);if(_0x483f21&&_0x51b18f?.[_0x84a5de(0x5c9)])_0x51b18f[_0x84a5de(0x5c9)][_0x84a5de(0x2c9)](_0x2e24fe+':'+_0x483f21[_0x84a5de(0x698)])[_0x84a5de(0x618)](()=>{});_0x2a85df['delete'](_0x2e24fe),console[_0x84a5de(0x24e)](_0x84a5de(0x1e5)+_0x2e24fe+_0x84a5de(0x371)+(_0x138285??'?')+')\x20exited\x20'+(_0x84a5de(0xcd)+_0x350dfe+_0x84a5de(0x1cd)+(_0x44b6d5??_0x84a5de(0x4c7))+_0x84a5de(0x450)+_0x2a85df['size']+_0x84a5de(0xa7))),_0x52f2d5();if(_0x338143||_0x138285==null)return;const _0x15a593=_0x5eb382['get'](_0x138285);if(!_0x15a593||_0x15a593[_0x84a5de(0x368)])return;const _0x19fb50=Date[_0x84a5de(0x127)]();_0x15a593[_0x84a5de(0x6dd)][_0x84a5de(0x2f9)](_0x19fb50),_0x15a593[_0x84a5de(0x6dd)]=_0x15a593[_0x84a5de(0x6dd)][_0x84a5de(0x293)](_0x3cc6e5=>_0x19fb50-_0x3cc6e5<=_0x190832);if(_0x15a593[_0x84a5de(0x6dd)][_0x84a5de(0x39d)]>=_0x58c971){_0x15a593[_0x84a5de(0x368)]=!![],console[_0x84a5de(0x492)]('[okdb-cluster]\x20CRASH-LOOP:\x20worker\x20slot='+_0x138285+'\x20died\x20'+_0x15a593[_0x84a5de(0x6dd)]['length']+'\x20times\x20in\x20'+(_0x190832+_0x84a5de(0x22e)+_0x2a85df['size']+_0x84a5de(0x3d0)));return;}_0x15a593['consecutiveFailures']++;const _0x498ba2=Math[_0x84a5de(0x268)](_0x5c3569,_0x3bd560*0x2**(_0x15a593[_0x84a5de(0x772)]-0x1));console[_0x84a5de(0x24e)]('[okdb-cluster]\x20respawning\x20worker\x20slot='+_0x138285+_0x84a5de(0x644)+_0x498ba2+'ms\x20(attempt\x20'+_0x15a593[_0x84a5de(0x772)]+')'),_0x15a593[_0x84a5de(0x651)]=setTimeout(()=>{const _0x150cb7=_0x84a5de;_0x15a593[_0x150cb7(0x651)]=null;if(_0x338143||_0x15a593[_0x150cb7(0x368)])return;const _0x177f96=_0x48a9b0(_0x138285);_0x177f96[_0x150cb7(0x375)](_0x150cb7(0x397),()=>{const _0x343fd7=_0x150cb7;if(_0x5eb382['get'](_0x138285)===_0x15a593)_0x15a593[_0x343fd7(0x772)]=0x0;});},_0x498ba2),_0x15a593[_0x84a5de(0x651)]['unref']?.();});const _0x148bb2=[..._0x2a85df[_0x41fa2f(0x6d8)]()];console[_0x41fa2f(0x24e)](_0x41fa2f(0x35b)+process[_0x41fa2f(0xee)]+'\x20forked\x20'+_0x427246+'\x20HTTP\x20server(s)\x20on\x20port\x20'+_0x2df4c8+':\x20'+('['+_0x148bb2[_0x41fa2f(0x10b)](',\x20')+']'));const _0x3fa56c={'_isClusterController':!![],'port':_0x2df4c8,'primaryOkdb':_0x51b18f??null,'status'(){const _0x20e815=_0x41fa2f;return{'clustered':!![],'primaryPid':process[_0x20e815(0xee)],'port':_0x2df4c8,'primaryRole':_0x51b18f?.[_0x20e815(0x132)]??null,'processorPid':null,'supervisorPid':process[_0x20e815(0xee)],'workers':[..._0x2a85df['values']()][_0x20e815(0x757)](({worker:_0x5360e8})=>({'pid':_0x5360e8[_0x20e815(0x3d3)]['pid'],'id':_0x5360e8['id'],'dead':_0x5360e8[_0x20e815(0x204)]()}))};},async 'close'(){const _0x5c1979=_0x41fa2f;_0x338143=!![];for(const _0x2f957c of _0x5eb382[_0x5c1979(0x591)]()){_0x2f957c[_0x5c1979(0x368)]=!![],_0x2f957c[_0x5c1979(0x651)]&&(clearTimeout(_0x2f957c[_0x5c1979(0x651)]),_0x2f957c[_0x5c1979(0x651)]=null);}clearInterval(_0x5ce293);_0x370b8f&&(clearTimeout(_0x370b8f),_0x370b8f=null);_0x3f10fd[_0x5c1979(0x567)](_0x5c1979(0x5e6),_0x2b02f6),_0x3f10fd[_0x5c1979(0x567)]('message',_0x3ef83f),_0x51b18f?.['events']?.[_0x5c1979(0x567)]?.(_0x3dbb06[_0x5c1979(0x6f0)],_0x126b93);if(_0x51b18f?.[_0x5c1979(0x194)]?.[_0x5c1979(0x567)])for(const {event:_0x46c782,handler:_0x29c24d}of _0x5b8f4a){try{_0x51b18f[_0x5c1979(0x194)][_0x5c1979(0x567)](_0x46c782,_0x29c24d);}catch{}}_0x5b8f4a[_0x5c1979(0x39d)]=0x0;const _0x285138=[..._0x2a85df['values']()][_0x5c1979(0x757)](({worker:_0xa45c7a})=>_0xa45c7a);if(_0x285138['length']===0x0)return;await Promise[_0x5c1979(0x438)](_0x285138[_0x5c1979(0x757)](_0x10b51d=>new Promise(_0xdc7d1d=>{const _0x273b9c=_0x5c1979;if(_0x10b51d[_0x273b9c(0x204)]()){_0xdc7d1d();return;}let _0x5a597a=![];const _0x5061a5=()=>{if(_0x5a597a)return;_0x5a597a=!![];if(_0x2d1ee0)clearTimeout(_0x2d1ee0);_0xdc7d1d();};_0x10b51d[_0x273b9c(0x375)]('exit',_0x5061a5);const _0x2d1ee0=setTimeout(()=>{const _0x4bbf1a=_0x273b9c;try{_0x10b51d[_0x4bbf1a(0x3d3)][_0x4bbf1a(0x435)]();}catch{}},_0x59677c+0x1f4);_0x2d1ee0[_0x273b9c(0xe9)]?.();try{_0x10b51d['disconnect']();}catch{try{_0x10b51d['process'][_0x273b9c(0x435)]();}catch{}}})));}};return _0x3fa56c;}async function _0x10352c({makeOkdb:_0x6bbc0a,port:_0x3e0625}){const _0x3b5a22=_0x32d610,_0xd9b76a=await _0x6bbc0a();return _0x39d9a2(_0xd9b76a),_0xd9b76a['http'][_0x3b5a22(0x289)](_0x3e0625);}function _0x39d9a2(_0x3c6e8b){const _0xd8973=_0x32d610;if(!_0x3c6e8b||_0x3c6e8b[_0xd8973(0xb7)])return;_0x3c6e8b[_0xd8973(0xb7)]=!![];try{const {OKDBChangefeed:_0x19ee78}=requireOkdbChangefeed(),_0x5c9cc9=_0x3c6e8b[_0xd8973(0x5f4)];if(_0x5c9cc9&&typeof _0x5c9cc9[_0xd8973(0x541)]===_0xd8973(0x372)){const _0x57e311=new _0x19ee78(_0x3c6e8b);_0x57e311[_0xd8973(0x570)](),_0x5c9cc9[_0xd8973(0x541)](_0x57e311),_0x3c6e8b[_0xd8973(0x45c)]=_0x57e311;}}catch(_0x401f0c){_0x3c6e8b[_0xd8973(0x24e)]?.[_0xd8973(0x6a7)]?.(_0xd8973(0x48d)+(_0x401f0c?.['message']??_0x401f0c),{'feature':_0xd8973(0x2bd)});}const _0x4098aa=_0x4e655a=>{const _0x549f35=_0xd8973;if(!_0x4e655a||typeof _0x4e655a!==_0x549f35(0x5d4)||_0x4e655a[_0x5705b5]==null)return;if(_0x4e655a[_0x5705b5]===_0x4ac35b)try{_0x3c6e8b['_adminRelay']?.[_0x549f35(0x4ea)]?.(_0x4e655a[_0x549f35(0x6bf)],_0x4e655a[_0x549f35(0x32e)]);}catch{}};process['on'](_0xd8973(0x5e6),_0x4098aa),_0x3c6e8b[_0xd8973(0x714)]=_0x4098aa;{let _0x5ed782=process[_0xd8973(0x4d5)](),_0x50a42c=Date[_0xd8973(0x127)]();const _0x3ea162=()=>{const _0x201adb=_0xd8973;if(typeof process[_0x201adb(0x3a7)]!==_0x201adb(0x372)||!process[_0x201adb(0x623)])return;const _0x3e8f93=Date[_0x201adb(0x127)](),_0x5754a6=process['cpuUsage'](),_0x1c684c=(_0x3e8f93-_0x50a42c)*0x3e8,_0x1d426e=_0x5754a6[_0x201adb(0x9b)]-_0x5ed782[_0x201adb(0x9b)]+(_0x5754a6['system']-_0x5ed782[_0x201adb(0x619)]),_0x225149=_0x1c684c>0x0?Math[_0x201adb(0x268)](0x64,Math[_0x201adb(0x139)](_0x1d426e/(_0x1c684c*(_0x1255e5[_0x201adb(0x19c)]()[_0x201adb(0x39d)]||0x1))*0x64)):0x0;_0x5ed782=_0x5754a6,_0x50a42c=_0x3e8f93;const _0x347db2=process[_0x201adb(0x14d)]();let _0x37987e=null;try{_0x37987e=_0x3c6e8b[_0x201adb(0x132)]?.[_0x201adb(0x43e)]?_0x3c6e8b[_0x201adb(0x5c9)]?.[_0x201adb(0x734)]?.()??null:null;}catch{}try{process[_0x201adb(0x3a7)]({[_0x5705b5]:_0x434999,'stats':{'rss':_0x347db2[_0x201adb(0x60d)],'heapUsed':_0x347db2[_0x201adb(0x497)],'heapTotal':_0x347db2[_0x201adb(0x6f1)],'external':_0x347db2[_0x201adb(0x46a)],'cpuPct':_0x225149,'cpuWindowMs':Math['round'](_0x1c684c/0x3e8)||null},'processing':_0x37987e});}catch{}},_0x324c9d=Math[_0xd8973(0x68c)](0x3e8,Number(process.env.OKDB_STATS_INTERVAL_MS)||0x1388),_0x3a3228=setInterval(_0x3ea162,_0x324c9d);_0x3a3228[_0xd8973(0xe9)]?.(),_0x3ea162();for(const _0xb4ed2b of[_0xd8973(0x523),_0xd8973(0x75a)]){_0x3c6e8b['events']?.['on']?.(_0xb4ed2b,()=>{try{_0x3ea162();}catch{}});}}let _0x35aa08=![];const _0x24bc87=async _0x2ba6fb=>{const _0x18115c=_0xd8973;if(_0x35aa08)return;_0x35aa08=!![];const _0x9efa9e=setTimeout(()=>process[_0x18115c(0x4e7)](_0x2ba6fb),_0x59677c);_0x9efa9e['unref']?.();try{await _0x3c6e8b['close']?.();}catch{}process[_0x18115c(0x4e7)](_0x2ba6fb);};process['on']('disconnect',()=>_0x24bc87(0x0));if(process[_0xd8973(0x3a7)]&&!process[_0xd8973(0x623)])_0x24bc87(0x0);if(process[_0xd8973(0x379)]!==_0xd8973(0x73f)){const _0x1fd34a=setInterval(()=>{if(process['ppid']===0x1)_0x24bc87(0x0);},_0x225072);_0x1fd34a[_0xd8973(0xe9)]?.(),_0x3c6e8b[_0xd8973(0x424)]=_0x1fd34a;}}return okdbCluster={'runClustered':_0x5c8d36,'attachWorkerCluster':_0x39d9a2},okdbCluster;}var okdbHttp={'exports':{}},okdbMetrics,hasRequiredOkdbMetrics;function requireOkdbMetrics(){const _0x5858de=_0x3d20e4;if(hasRequiredOkdbMetrics)return okdbMetrics;hasRequiredOkdbMetrics=0x1;const _0x22235=0x3c;function _0x23e0f8(){return{'requests':0x0,'reads':0x0,'writes':0x0,'errors':0x0,'readMs':0x0,'writeMs':0x0};}class _0x5bfba7{constructor(){const _0x44afb7=_0x8cd7;this['_totalRequests']=0x0,this[_0x44afb7(0x18a)]=0x0,this['_totalWrites']=0x0,this[_0x44afb7(0x442)]=0x0,this[_0x44afb7(0x310)]=0x0,this[_0x44afb7(0x3f7)]=0x0,this[_0x44afb7(0x84)]=Array['from']({'length':_0x22235},_0x23e0f8),this['_bucketIdx']=0x0,this['_lastTick']=Date[_0x44afb7(0x127)](),this[_0x44afb7(0x577)]=setInterval(()=>this['_rotateBucket'](),0x3e8);if(this['_timer'][_0x44afb7(0xe9)])this['_timer']['unref']();}[_0x5858de(0x5d5)](){const _0xee5ac1=_0x5858de;this[_0xee5ac1(0xe1)]=(this[_0xee5ac1(0xe1)]+0x1)%_0x22235,this['_buckets'][this['_bucketIdx']]=_0x23e0f8(),this[_0xee5ac1(0x15e)]=Date[_0xee5ac1(0x127)]();}[_0x5858de(0x54d)](_0x340ecf,_0x26201b,_0x4ca55d){const _0x32cc7a=_0x5858de,_0x336bd4=/^(POST|PUT|PATCH|DELETE)$/i[_0x32cc7a(0x155)](_0x340ecf),_0x5aeb81=this[_0x32cc7a(0x84)][this[_0x32cc7a(0xe1)]];this[_0x32cc7a(0xb9)]++,_0x5aeb81['requests']++,_0x4ca55d&&(this[_0x32cc7a(0x442)]++,_0x5aeb81[_0x32cc7a(0x422)]++),_0x336bd4?(this[_0x32cc7a(0x60b)]++,this[_0x32cc7a(0x3f7)]+=_0x26201b,_0x5aeb81[_0x32cc7a(0x6e7)]++,_0x5aeb81[_0x32cc7a(0xe3)]+=_0x26201b):(this['_totalReads']++,this[_0x32cc7a(0x310)]+=_0x26201b,_0x5aeb81[_0x32cc7a(0x742)]++,_0x5aeb81[_0x32cc7a(0x2da)]+=_0x26201b);}[_0x5858de(0x609)](){const _0x471a96=_0x5858de;let _0x51c2e2=0x0,_0x183710=0x0,_0x124382=0x0,_0x67b58=0x0,_0x450ba8=0x0,_0xd81342=0x0;for(const _0x1d9b85 of this[_0x471a96(0x84)]){_0x51c2e2+=_0x1d9b85[_0x471a96(0x21e)],_0x183710+=_0x1d9b85[_0x471a96(0x742)],_0x124382+=_0x1d9b85[_0x471a96(0x6e7)],_0x67b58+=_0x1d9b85[_0x471a96(0x422)],_0x450ba8+=_0x1d9b85[_0x471a96(0x2da)],_0xd81342+=_0x1d9b85[_0x471a96(0xe3)];}const _0x47f084=_0x22235;return{'lifetime':{'requests':this[_0x471a96(0xb9)],'reads':this[_0x471a96(0x18a)],'writes':this['_totalWrites'],'errors':this[_0x471a96(0x442)],'avgReadMs':this['_totalReads']>0x0?+(this[_0x471a96(0x310)]/this[_0x471a96(0x18a)])[_0x471a96(0x72c)](0x2):null,'avgWriteMs':this['_totalWrites']>0x0?+(this[_0x471a96(0x3f7)]/this[_0x471a96(0x60b)])[_0x471a96(0x72c)](0x2):null},'window':{'seconds':_0x47f084,'requests':_0x51c2e2,'reads':_0x183710,'writes':_0x124382,'errors':_0x67b58,'reqPerSec':+(_0x51c2e2/_0x47f084)[_0x471a96(0x72c)](0x2),'readPerSec':+(_0x183710/_0x47f084)['toFixed'](0x2),'writePerSec':+(_0x124382/_0x47f084)[_0x471a96(0x72c)](0x2),'avgReadMs':_0x183710>0x0?+(_0x450ba8/_0x183710)['toFixed'](0x2):null,'avgWriteMs':_0x124382>0x0?+(_0xd81342/_0x124382)[_0x471a96(0x72c)](0x2):null}};}[_0x5858de(0x44f)](){const _0xf84bf9=_0x5858de;clearInterval(this[_0xf84bf9(0x577)]);}}return okdbMetrics=_0x5bfba7,okdbMetrics;}var okdbAuthNamespaces,hasRequiredOkdbAuthNamespaces;function requireOkdbAuthNamespaces(){const _0x270a48=_0x3d20e4;if(hasRequiredOkdbAuthNamespaces)return okdbAuthNamespaces;hasRequiredOkdbAuthNamespaces=0x1;const _0x5c0d3f={'data':{'label':'Data','scope':_0x270a48(0x124),'description':_0x270a48(0x4f5),'operations':{'read':{'label':'Read','summary':'Get\x20and\x20list\x20records,\x20run\x20byIndex\x20queries.'},'write':{'label':'Write','summary':'Create,\x20update,\x20and\x20delete\x20records\x20(including\x20bulk\x20import).'}}},'schema':{'label':_0x270a48(0x8e),'scope':_0x270a48(0x124),'description':_0x270a48(0x80),'operations':{'read':{'label':'Read','summary':'List\x20types,\x20get\x20type\x20schema,\x20list\x20registered\x20indexes.'},'write':{'label':_0x270a48(0xa0),'summary':_0x270a48(0x1fb)}}},'search':{'label':'Search','scope':_0x270a48(0x124),'description':'Run\x20searches\x20against\x20registered\x20FTS\x20and\x20vector\x20indexes.','operations':{'query':{'label':'Query','summary':'Execute\x20full-text\x20and\x20vector\x20searches.'}}},'queue':{'label':_0x270a48(0x12c),'scope':_0x270a48(0x124),'description':_0x270a48(0x387),'operations':{'read':{'label':_0x270a48(0x2eb),'summary':_0x270a48(0x104)},'write':{'label':'Write','summary':_0x270a48(0x34b)},'work':{'label':_0x270a48(0x449),'summary':'Worker-side:\x20claim,\x20heartbeat,\x20complete,\x20fail,\x20progress.'}}},'files':{'label':_0x270a48(0x6a8),'scope':_0x270a48(0x124),'description':_0x270a48(0x77b),'operations':{'read':{'label':_0x270a48(0x2eb),'summary':_0x270a48(0x21d)},'write':{'label':_0x270a48(0xa0),'summary':'Upload,\x20update\x20metadata,\x20and\x20delete\x20files.'}}},'functions':{'label':_0x270a48(0x65e),'scope':_0x270a48(0x124),'description':_0x270a48(0x514),'operations':{'read':{'label':_0x270a48(0x2eb),'summary':_0x270a48(0x4fa)},'write':{'label':_0x270a48(0xa0),'summary':_0x270a48(0x6d4)},'run':{'label':_0x270a48(0x3fc),'summary':'Execute\x20functions\x20over\x20HTTP/MCP/shell.'}}},'views':{'label':_0x270a48(0x2ab),'scope':_0x270a48(0x124),'description':'Materialized\x20views:\x20query\x20definitions\x20that\x20are\x20continuously\x20maintained\x20and\x20queryable.','operations':{'read':{'label':_0x270a48(0x2eb),'summary':'List\x20views,\x20query\x20view\x20output,\x20inspect\x20metadata\x20and\x20definition.'},'write':{'label':'Write','summary':'Create\x20and\x20delete\x20views,\x20start,\x20stop,\x20and\x20rebuild\x20them.'}}},'env':{'label':_0x270a48(0x434),'scope':'env','description':_0x270a48(0x748),'operations':{'read':{'label':_0x270a48(0x2eb),'summary':'List\x20environments\x20and\x20read\x20environment\x20info.'},'write':{'label':_0x270a48(0xa0),'summary':_0x270a48(0x1a7)}}},'auth':{'label':_0x270a48(0x4a9),'scope':_0x270a48(0x619),'description':_0x270a48(0x708),'operations':{'read':{'label':_0x270a48(0x2eb),'summary':_0x270a48(0x728)},'write':{'label':'Write','summary':'Create,\x20update,\x20and\x20delete\x20tokens\x20and\x20users;\x20rotate\x20keys.'}}},'system':{'label':_0x270a48(0x68f),'scope':'system','description':_0x270a48(0x3de),'operations':{'read':{'label':_0x270a48(0x2eb),'summary':'View\x20server\x20info,\x20logs,\x20SSE\x20event\x20streams,\x20processor\x20status,\x20backup\x20list.'},'write':{'label':'Write','summary':_0x270a48(0x1d5)}}},'sync':{'label':_0x270a48(0x2ec),'scope':_0x270a48(0x619),'description':'Cluster\x20replication.\x20The\x20\x22peer\x22\x20op\x20is\x20for\x20cluster\x20nodes,\x20not\x20human\x20users.','operations':{'read':{'label':'Read','summary':_0x270a48(0x744)},'write':{'label':_0x270a48(0xa0),'summary':'Register,\x20configure,\x20and\x20remove\x20cluster\x20peers.'},'peer':{'label':_0x270a48(0x1fc),'summary':_0x270a48(0x64e),'machineOnly':!![]}}},'protected':{'label':_0x270a48(0x243),'scope':_0x270a48(0x692),'description':_0x270a48(0x6e2),'operations':{'read':{'label':'Read','summary':_0x270a48(0xce)},'write':{'label':_0x270a48(0xa0),'summary':_0x270a48(0x415)}}}},_0x29f4ac={'schema:read':['data:read','data:write',_0x270a48(0x2d5)]},_0x1ecdf6=[_0x270a48(0x41b),_0x270a48(0x684),_0x270a48(0x388),'write',_0x270a48(0x220),'peer'];function _0x38c599(){const _0x3349f0=_0x270a48,_0x45e968=[];for(const [_0x4915ce,_0x581e53]of Object[_0x3349f0(0x61d)](_0x5c0d3f)){for(const _0x527c2e of Object[_0x3349f0(0x6d8)](_0x581e53[_0x3349f0(0x2f7)])){_0x45e968[_0x3349f0(0x2f9)](_0x4915ce+':'+_0x527c2e);}}return _0x45e968;}function _0x2d88f2(_0xbf25b6){return _0x5c0d3f[_0xbf25b6]||null;}function _0x7ccb14(_0x3d8a23,_0x37769b){const _0x4a9c20=_0x270a48;return _0x5c0d3f[_0x3d8a23]?.[_0x4a9c20(0x2f7)][_0x37769b]||null;}return okdbAuthNamespaces={'NAMESPACES':_0x5c0d3f,'IMPLIED_BY':_0x29f4ac,'OP_ORDER':_0x1ecdf6,'listAllPermissions':_0x38c599,'getNamespaceMeta':_0x2d88f2,'getOperationMeta':_0x7ccb14},okdbAuthNamespaces;}var okdbAuthPermissions,hasRequiredOkdbAuthPermissions;function requireOkdbAuthPermissions(){const _0x10d35d=_0x3d20e4;if(hasRequiredOkdbAuthPermissions)return okdbAuthPermissions;hasRequiredOkdbAuthPermissions=0x1;const {IMPLIED_BY:_0x3a609f}=requireOkdbAuthNamespaces(),_0x5b03a2=new Set([_0x10d35d(0x41b),'query']);function _0x5e4cc2(_0x5e568a,_0xba93bd){const _0x14499c=_0x10d35d;if(!Array[_0x14499c(0x339)](_0x5e568a)||_0x5e568a[_0x14499c(0x39d)]===0x0)return![];for(const _0x235ac1 of _0x5e568a){if(typeof _0x235ac1!==_0x14499c(0xe7)||!_0x235ac1['includes'](':')){if(_0x235ac1==='*')return!![];continue;}const [_0x5d6683,_0x4efcc9]=_0x235ac1[_0x14499c(0x2aa)](':'),[_0x3b2560,_0x5914b7]=_0xba93bd[_0x14499c(0x2aa)](':'),_0x48105d=_0x5d6683==='*'||_0x5d6683===_0x3b2560,_0x560b3c=_0x4efcc9==='*'||_0x4efcc9===_0x5914b7;if(_0x48105d&&_0x560b3c)return!![];}const _0xaec9fa=_0x3a609f[_0xba93bd];if(_0xaec9fa)for(const _0x42f703 of _0xaec9fa){if(_0x5e4cc2(_0x5e568a,_0x42f703))return!![];}return![];}function _0x5478b3(_0x58f19a,_0x5e0e73){const _0x8ed23d=_0x10d35d,_0x39702e=new Set();if(Array[_0x8ed23d(0x339)](_0x58f19a)){for(const _0x85eda2 of _0x58f19a)_0x39702e[_0x8ed23d(0x3e9)](_0x85eda2);}if(Array[_0x8ed23d(0x339)](_0x5e0e73)){for(const _0x11e923 of _0x5e0e73)_0x39702e[_0x8ed23d(0x3e9)](_0x11e923);}return Array[_0x8ed23d(0x690)](_0x39702e);}function _0x6f1e08(_0x5bc743){const _0x2ab403=_0x10d35d;if(typeof _0x5bc743!==_0x2ab403(0xe7))return![];const [,_0x1c1a26]=_0x5bc743['split'](':');return _0x5b03a2[_0x2ab403(0x469)](_0x1c1a26);}function _0x556569(_0x495a67){const _0x543c69=_0x10d35d;return _0x6f1e08(_0x495a67)?_0x543c69(0x70c):_0x543c69(0x22f);}function _0x4b875c(_0x2937f5,_0x358524){const _0x2cf2e8=_0x10d35d;return _0x5478b3(_0x2937f5[_0x2cf2e8(0x1f4)]||[],_0x358524?(_0x2937f5['grants']||{})[_0x358524]||[]:[]);}function _0x17ac42(_0x2a1d94){const _0x43c386=_0x10d35d,_0x3bd3bb=[];for(const _0x46f9a5 of _0x2a1d94[_0x43c386(0x562)]()){const _0x582d93=_0x46f9a5['operation']?.[_0x43c386(0x2af)];if(!_0x582d93)continue;_0x582d93[_0x43c386(0x3fa)]&&!_0x582d93[_0x43c386(0x6b)]&&_0x3bd3bb['push'](_0x46f9a5['method']+'\x20'+_0x46f9a5[_0x43c386(0x4c5)]+'\x20(id:\x20'+(_0x46f9a5['operation']['id']??'?')+')');}if(_0x3bd3bb[_0x43c386(0x39d)])throw new Error(_0x43c386(0x553)+_0x3bd3bb['join'](_0x43c386(0x82)));}return okdbAuthPermissions={'hasPermission':_0x5e4cc2,'unionPermissions':_0x5478b3,'isReadOperation':_0x6f1e08,'resolveProtectedGate':_0x556569,'getEffectivePermissions':_0x4b875c,'assertEveryRouteHasPermission':_0x17ac42},okdbAuthPermissions;}var okdbJwtUtils,hasRequiredOkdbJwtUtils;function requireOkdbJwtUtils(){if(hasRequiredOkdbJwtUtils)return okdbJwtUtils;hasRequiredOkdbJwtUtils=0x1;const _0x350e6d=require$$0$7,_0x536b05=require$$1$2,_0x27d487=require$$2$1;function _0x19bac0(_0x474627){const _0x1d697a=_0x8cd7,_0x362865=String(_0x474627||'')[_0x1d697a(0x416)](/-/g,'+')['replace'](/_/g,'/'),_0x98dffb=_0x362865+'='[_0x1d697a(0x4d9)]((0x4-(_0x362865[_0x1d697a(0x39d)]%0x4||0x4))%0x4);return Buffer[_0x1d697a(0x690)](_0x98dffb,_0x1d697a(0x154));}function _0xca284e(_0x9fabfb){const _0x1a9b6a=_0x8cd7;if(typeof _0x9fabfb!==_0x1a9b6a(0xe7))throw new Error(_0x1a9b6a(0x636));const _0x511df8=_0x9fabfb[_0x1a9b6a(0x2aa)]('.');if(_0x511df8[_0x1a9b6a(0x39d)]!==0x3)throw new Error(_0x1a9b6a(0x2cb));const [_0x4f8101,_0x45dd9f,_0x2ffcc5]=_0x511df8,_0x53db6e=JSON['parse'](_0x19bac0(_0x4f8101)[_0x1a9b6a(0x240)](_0x1a9b6a(0x320))),_0x286d55=JSON[_0x1a9b6a(0xc3)](_0x19bac0(_0x45dd9f)['toString'](_0x1a9b6a(0x320)));return{'header':_0x53db6e,'payload':_0x286d55,'signature':_0x19bac0(_0x2ffcc5),'signingInput':Buffer[_0x1a9b6a(0x690)](_0x4f8101+'.'+_0x45dd9f),'encodedHeader':_0x4f8101,'encodedPayload':_0x45dd9f};}function _0x50a060(_0x4e6ff1){const _0x5aee7d=_0x8cd7;if(Array[_0x5aee7d(0x339)](_0x4e6ff1))return _0x4e6ff1;if(_0x4e6ff1==null)return[];return[_0x4e6ff1];}function _0x4e28cb(_0x23eaed){const _0x390076=_0x8cd7,_0x28833c=String(_0x23eaed||'')[_0x390076(0x581)](/.{1,64}/g)||[];return _0x390076(0x4a3)+_0x28833c[_0x390076(0x10b)]('\x0a')+'\x0a-----END\x20CERTIFICATE-----\x0a';}function _0x254aa6(_0x2e57e9={}){const _0x49848b=_0x8cd7;if(_0x2e57e9[_0x49848b(0x18f)]?.[0x0])return _0x27d487[_0x49848b(0x9c)](_0x4e28cb(_0x2e57e9['x5c'][0x0]));return _0x27d487[_0x49848b(0x9c)]({'key':_0x2e57e9,'format':_0x49848b(0x3d6)});}function _0x44c2f2(_0x18b914,_0x566551,_0x279abb,_0x3ca101){const _0x563f3e=_0x8cd7;if(_0x18b914==='RS256')return _0x27d487[_0x563f3e(0x6de)](_0x563f3e(0x1ce),_0x279abb,_0x566551,_0x3ca101);if(_0x18b914===_0x563f3e(0x612))return _0x27d487[_0x563f3e(0x6de)]('sha256',_0x279abb,{'key':_0x566551,'dsaEncoding':_0x563f3e(0x4de)},_0x3ca101);return![];}function _0x38cb41(_0xf422e1){const _0x149bb6=_0x8cd7;if(typeof commonjsGlobal['fetch']===_0x149bb6(0x372))return commonjsGlobal['fetch'](_0xf422e1,{'headers':{'accept':_0x149bb6(0x754)}})[_0x149bb6(0xad)](async _0x1c0492=>{const _0x4bc870=_0x149bb6;if(!_0x1c0492['ok']){const _0x301b22=new Error(_0x4bc870(0x1e1)+_0x1c0492[_0x4bc870(0x170)]+_0x4bc870(0x11a)+_0xf422e1);_0x301b22[_0x4bc870(0x170)]=_0x1c0492[_0x4bc870(0x170)];throw _0x301b22;}return _0x1c0492['json']();});return new Promise((_0x5528b0,_0x959c30)=>{const _0x3cd19c=_0x149bb6,_0x583fed=String(_0xf422e1)[_0x3cd19c(0x42e)](_0x3cd19c(0x1d0))?_0x536b05:_0x350e6d,_0x3bf647=_0x583fed['get'](_0xf422e1,{'headers':{'accept':_0x3cd19c(0x754)}},_0x226682=>{const _0x4ad874=_0x3cd19c;let _0x526b64='';_0x226682['setEncoding'](_0x4ad874(0x320)),_0x226682['on'](_0x4ad874(0x32e),_0x9f172e=>{_0x526b64+=_0x9f172e;}),_0x226682['on'](_0x4ad874(0xe5),()=>{const _0x468319=_0x4ad874;if(_0x226682['statusCode']<0xc8||_0x226682[_0x468319(0x3e6)]>=0x12c){const _0x70d032=new Error(_0x468319(0x1e1)+_0x226682[_0x468319(0x3e6)]+_0x468319(0x11a)+_0xf422e1);return _0x70d032['status']=_0x226682[_0x468319(0x3e6)],_0x959c30(_0x70d032);}try{_0x5528b0(JSON['parse'](_0x526b64||'{}'));}catch(_0x4e2a24){_0x959c30(_0x4e2a24);}});});_0x3bf647['on']('error',_0x959c30),_0x3bf647[_0x3cd19c(0xe5)]();});}return okdbJwtUtils={'base64UrlDecode':_0x19bac0,'parseJwt':_0xca284e,'normalizeAudience':_0x50a060,'normalizePemCertificate':_0x4e28cb,'jwkToKeyObject':_0x254aa6,'verifyJwtSignature':_0x44c2f2,'fetchJson':_0x38cb41},okdbJwtUtils;}var hasRequiredOkdbHttp;function requireOkdbHttp(){const _0x398641=_0x3d20e4;if(hasRequiredOkdbHttp)return okdbHttp[_0x398641(0x71d)];hasRequiredOkdbHttp=0x1;const _0x1a5019=require$$0$7,{URL:_0x1d8af8}=require$$2$2,_0x1c47b3=requireOkdbMetrics(),_0x42d881=requireOkdbAuthTokens(),{hasPermission:_0x1d012a,unionPermissions:_0x1cd758,resolveProtectedGate:_0x32f72e}=requireOkdbAuthPermissions(),_0x341cf6={0x190:_0x398641(0x347),0x191:_0x398641(0x1ec),0x193:'FORBIDDEN',0x194:'NOT_FOUND',0x195:_0x398641(0x273),0x198:_0x398641(0x1e7),0x199:_0x398641(0x31e),0x19a:_0x398641(0x71a),0x19b:_0x398641(0x499),0x19d:_0x398641(0xc2),0x19f:_0x398641(0xc5),0x1a6:_0x398641(0x638),0x1ad:'TOO_MANY_REQUESTS',0x1f4:_0x398641(0x189),0x1f5:_0x398641(0x34c),0x1f6:_0x398641(0x782),0x1f7:_0x398641(0x2b5),0x1f8:_0x398641(0x3bf)},_0x544ce8={'INVALID_VALUE':0x190,'BAD_CONFIG':0x190,'INVALID_PRIMARY_KEY':0x190,'INVALID_INDEX_KEY':0x190,'TYPE_NOT_REGISTERED':0x194,'INDEX_NOT_REGISTERED':0x194,'NOT_FOUND':0x194,'ALREADY_EXISTS':0x199,'VERSION_MISMATCH':0x199,'UNIQUE_CONSTRAINT':0x199,'TYPE_ALREADY_REGISTERED':0x199,'INDEX_ALREADY_REGISTERED':0x199,'FK_ERROR':0x199,'FK_DELETE_ERROR':0x199,'FOREIGN_KEY_VIOLATION':0x199,'FOREIGN_KEY_DELETE_RESTRICTED':0x199,'ENV_NOT_FOUND':0x194,'ENV_PROTECTED':0x193,'ENGINE_CONFIG_PATCH_UNSUPPORTED':0x190,'QUEUE_WORKER_JOB_TYPE_CONFLICT':0x199,'SCHEMA_VALIDATION_FAILED':0x1a6,'SCHEMA_COLLECTION_INVALID':0x199,'INVALID_SCHEMA':0x190,'QUERY_OPERATOR_FORBIDDEN':0x190,'BUCKET_CONFIG_INVALID':0x190,'BUCKET_INVALID_TIME_VALUE':0x1a6,'BUCKET_PROJECT_NOT_PERSISTABLE':0x190,'BUCKET_PROJECT_UNKNOWN':0x190,'VIEW_UNKNOWN_REDUCER':0x190,'RESERVED_VIEW_NAME':0x190,'VIEW_NOT_BUCKETED':0x190,'VIEW_NOT_FOUND':0x194,'VIEW_RANGE_GRANULARITY_MISMATCH':0x190,'VIEW_RANGE_GRANULARITY_REQUIRED':0x190,'VIEW_REF_UNSUPPORTED_REDUCER':0x190},{hmac:_0x4ed188,timingSafeEqual:_0x218fe9,parseBearer:_0x270045,randomToken:_0x392ef6,issueToken:_0x4ee366,authenticateToken:_0x3ac6d1}=_0x42d881,{base64UrlDecode:_0x5de891,parseJwt:_0x4ba030,normalizeAudience:_0x21824d,normalizePemCertificate:_0x35390c,jwkToKeyObject:_0x399aec,verifyJwtSignature:_0x2be05e,fetchJson:_0xfc123b}=requireOkdbJwtUtils();function _0x2ba097(_0x41cce6){const _0x507a09=_0x398641;return(_0x41cce6||_0x507a09(0x248))[_0x507a09(0x419)]();}function _0x39f960(_0x1dc196){const _0x1c7754=_0x398641;if(Array[_0x1c7754(0x339)](_0x1dc196))return _0x1dc196[_0x1c7754(0x6bd)](_0x39f960);return String(_0x1dc196||'')[_0x1c7754(0x2aa)](',')[_0x1c7754(0x757)](_0x593d68=>_0x593d68[_0x1c7754(0x471)]())['filter'](Boolean);}function _0x53c872(..._0x19f9c0){const _0x38d78c=_0x398641;return[...new Set(_0x19f9c0[_0x38d78c(0x6bd)](_0x39f960))][_0x38d78c(0x10b)](',\x20');}function _0x4de1f8(_0x9f4e63,_0x2e21f3){const _0x52011a=_0x398641;if(!_0x9f4e63)return![];if(_0x2e21f3==='*')return!![];if(_0x2e21f3 instanceof RegExp)return _0x2e21f3[_0x52011a(0x155)](_0x9f4e63);if(typeof _0x2e21f3==='function')return!!_0x2e21f3(_0x9f4e63);if(Array[_0x52011a(0x339)](_0x2e21f3))return _0x2e21f3[_0x52011a(0x8f)](_0x9f4e63);return _0x2e21f3===_0x9f4e63;}function _0xa37337(_0xa70bd1={},_0x4bf707={},_0x24c79c=null){const _0x5f45e0=_0x398641;if(!_0x4bf707)return null;const _0x2421c3=_0xa70bd1[_0x5f45e0(0x633)],_0x4f388e=_0x4bf707[_0x5f45e0(0x762)]??_0x4bf707['origin']??'*',_0x23c29d=_0x4f388e==='*'?'*':_0x4de1f8(_0x2421c3,_0x4f388e)?_0x2421c3:null;if(!_0x23c29d)return null;const _0x188c07=_0xa70bd1['access-control-request-headers'],_0x3d90f3=_0x4bf707[_0x5f45e0(0x165)]??_0x4bf707[_0x5f45e0(0x55e)]??['content-type','authorization',_0x5f45e0(0x34f),'last-event-id',_0x5f45e0(0x17d)],_0x411b1f=_0x4bf707[_0x5f45e0(0x691)]??_0x4bf707[_0x5f45e0(0x3ae)]??(_0x24c79c?[_0x24c79c,'OPTIONS']:['GET',_0x5f45e0(0x2ed),_0x5f45e0(0x43f)]),_0xf15a7d=_0x4bf707[_0x5f45e0(0x14e)]??[_0x5f45e0(0x34f)],_0x2578dd={'access-control-allow-origin':_0x23c29d,'access-control-allow-methods':Array[_0x5f45e0(0x339)](_0x411b1f)?_0x411b1f[_0x5f45e0(0x10b)](',\x20'):String(_0x411b1f),'access-control-allow-headers':_0x188c07?_0x53c872(_0x3d90f3,_0x188c07):Array['isArray'](_0x3d90f3)?_0x3d90f3[_0x5f45e0(0x10b)](',\x20'):String(_0x3d90f3),'access-control-expose-headers':Array[_0x5f45e0(0x339)](_0xf15a7d)?_0xf15a7d[_0x5f45e0(0x10b)](',\x20'):String(_0xf15a7d),'vary':_0x53c872(_0x5f45e0(0x5b6),_0x23c29d==='*'?'':_0x5f45e0(0x5b6),_0x188c07?_0x5f45e0(0x315):'')};if(_0x4bf707[_0x5f45e0(0x118)])_0x2578dd[_0x5f45e0(0x145)]=_0x5f45e0(0x727);if(Number['isFinite'](_0x4bf707['maxAge']))_0x2578dd[_0x5f45e0(0x5e1)]=String(_0x4bf707[_0x5f45e0(0x5df)]);return _0x2578dd;}function _0x800295(_0x536fb1){const _0x19c516=_0x398641,_0x11e463=[],_0x5089b1={};let _0x4bee30=![];_0x536fb1[_0x19c516(0x113)]('/*')&&(_0x4bee30=!![],_0x536fb1=_0x536fb1['slice'](0x0,-0x2),_0x11e463[_0x19c516(0x2f9)]('*'));let _0x3e1a04=_0x536fb1[_0x19c516(0x416)](/\/+$/,'')[_0x19c516(0x416)](/\[([^\]]*)\]/g,(_0x55602b,_0x4e548e)=>{const _0x34b6cb=_0x19c516,_0x5abbd8=_0x4e548e[_0x34b6cb(0x416)](/\/:(\w+)(?:=([^/\]\s]*))?/g,(_0x13e0c7,_0x27c402,_0x4adf26)=>{const _0x4fee48=_0x34b6cb;_0x11e463[_0x4fee48(0x2f9)](_0x27c402);if(_0x4adf26!==undefined)_0x5089b1[_0x27c402]=_0x4adf26;return'/([^/]+)';});return _0x34b6cb(0x9f)+_0x5abbd8+')?';})[_0x19c516(0x416)](/\/:(\w+)/g,(_0x4c93e2,_0x5c6b6b)=>{const _0x32c290=_0x19c516;return _0x11e463[_0x32c290(0x2f9)](_0x5c6b6b),_0x32c290(0x1ee);});if(_0x3e1a04==='')_0x3e1a04='/';return{'keys':_0x11e463,'defaults':_0x5089b1,'wildcard':_0x4bee30,'regex':new RegExp(_0x4bee30?'^'+_0x3e1a04+_0x19c516(0x521):'^'+_0x3e1a04+'$')};}function _0x30edd9(_0x54ccef){const _0x554a17=_0x398641;if(_0x54ccef==null)return _0x54ccef;return JSON[_0x554a17(0xc3)](JSON[_0x554a17(0x5c1)](_0x54ccef));}function _0x5d3d3d(_0x32141a){const _0x3e8bf8=_0x398641;if(_0x32141a==null)return null;if(_0x32141a['type']===_0x3e8bf8(0x5d4)&&_0x32141a[_0x3e8bf8(0x9d)]&&!Array[_0x3e8bf8(0x339)](_0x32141a[_0x3e8bf8(0x9d)]))return _0x30edd9(_0x32141a);const _0x4caae7=Object['values'](_0x32141a),_0x33f604=_0x4caae7[_0x3e8bf8(0x39d)]>0x0&&_0x4caae7[_0x3e8bf8(0x6be)](_0x4f6871=>{const _0xa088e2=_0x3e8bf8;return _0x4f6871&&typeof _0x4f6871==='object'&&!Array[_0xa088e2(0x339)](_0x4f6871)&&(Object[_0xa088e2(0x568)][_0xa088e2(0x1fa)]['call'](_0x4f6871,_0xa088e2(0x66f))||Object['prototype']['hasOwnProperty']['call'](_0x4f6871,_0xa088e2(0x9d))||Object[_0xa088e2(0x568)][_0xa088e2(0x1fa)]['call'](_0x4f6871,_0xa088e2(0x281))||Object[_0xa088e2(0x568)][_0xa088e2(0x1fa)][_0xa088e2(0x3c6)](_0x4f6871,_0xa088e2(0x3e8)));});if(_0x33f604)return{'type':'object','properties':_0x30edd9(_0x32141a),'required':[],'additionalProperties':![]};const _0x4b9cb9={},_0x362bed=[];for(const [_0x1ceb6c,_0x2ebb51]of Object[_0x3e8bf8(0x61d)](_0x32141a)){_0x4b9cb9[_0x1ceb6c]=_0x4c9408(_0x2ebb51);if(_0x2ebb51!==null&&_0x2ebb51!==undefined)_0x362bed[_0x3e8bf8(0x2f9)](_0x1ceb6c);}return{'type':_0x3e8bf8(0x5d4),'properties':_0x4b9cb9,'required':_0x362bed,'additionalProperties':![]};}function _0x4c9408(_0x3ca0bd){const _0x22d42c=_0x398641;if(_0x3ca0bd===null)return{'type':[_0x22d42c(0x359),'string','number','boolean',_0x22d42c(0x5d4),'array']};if(Array[_0x22d42c(0x339)](_0x3ca0bd))return{'type':_0x22d42c(0x465),'items':_0x3ca0bd['length']>0x0?_0x4c9408(_0x3ca0bd[0x0]):{}};switch(typeof _0x3ca0bd){case _0x22d42c(0xe7):return{'type':_0x22d42c(0xe7),'default':_0x3ca0bd};case _0x22d42c(0x6af):return{'type':Number[_0x22d42c(0x446)](_0x3ca0bd)?_0x22d42c(0x19d):_0x22d42c(0x6af),'default':_0x3ca0bd};case'boolean':return{'type':_0x22d42c(0x200),'default':_0x3ca0bd};case'object':{const _0x2fe0a8={};for(const [_0x2df685,_0x24685d]of Object['entries'](_0x3ca0bd))_0x2fe0a8[_0x2df685]=_0x4c9408(_0x24685d);return{'type':'object','properties':_0x2fe0a8,'additionalProperties':!![],'default':_0x30edd9(_0x3ca0bd)};}default:return{};}}function _0x40a72f(_0x212e34,_0x27c19b){const _0x56e515=_0x398641,_0x5ce2ab=[];for(const _0x3d1e71 of _0x27c19b[_0x56e515(0x6d8)]){if(_0x3d1e71==='*')continue;_0x5ce2ab[_0x56e515(0x2f9)]({'name':_0x3d1e71,'required':!Object[_0x56e515(0x568)][_0x56e515(0x1fa)][_0x56e515(0x3c6)](_0x27c19b['defaults'],_0x3d1e71),'default':_0x27c19b[_0x56e515(0x10f)][_0x3d1e71]});}return _0x5ce2ab;}function _0x4a4ba9(_0x361478={},_0x53ffb5){const _0x5ca94c=_0x398641,_0x321008=_0x5d3d3d(_0x361478['http']?.[_0x5ca94c(0x1e6)]??_0x361478[_0x5ca94c(0x684)]??null),_0x873051=_0x361478[_0x5ca94c(0x91)]?.[_0x5ca94c(0x1ef)]??(_0x361478['raw']?_0x5ca94c(0x349):_0x53ffb5[_0x5ca94c(0xdf)]===_0x5ca94c(0x248)||_0x53ffb5[_0x5ca94c(0xdf)]===_0x5ca94c(0x481)?_0x5ca94c(0x4c7):_0x5ca94c(0x4d7));return{'querySchema':_0x321008,'bodyMode':_0x873051,'bindings':_0x30edd9(_0x361478[_0x5ca94c(0x91)]?.[_0x5ca94c(0x433)]??{}),'statuses':_0x30edd9(_0x361478[_0x5ca94c(0x91)]?.['statuses']??(_0x361478[_0x5ca94c(0x1e0)]||[])),'transport':_0x361478[_0x5ca94c(0x91)]?.[_0x5ca94c(0x601)]??(_0x361478[_0x5ca94c(0x4d6)]?'sse':_0x361478[_0x5ca94c(0x349)]?'raw':_0x5ca94c(0x63e)),'rawResponse':_0x361478[_0x5ca94c(0x91)]?.['rawResponse']??!!_0x361478[_0x5ca94c(0xbb)],'cors':_0x30edd9(_0x361478[_0x5ca94c(0x91)]?.['cors']??_0x361478['cors']??null)};}function _0x2da795(_0x219b2e){const _0x27cf56=_0x398641,_0x31b29b=_0x219b2e['meta']||{},_0x75a26d=_0x40a72f(_0x219b2e['path'],_0x219b2e['matcher']),_0x26a9d4=!!(_0x31b29b['id']||_0x31b29b[_0x27cf56(0x2f6)]||_0x31b29b[_0x27cf56(0x545)]||_0x31b29b[_0x27cf56(0x91)]||_0x31b29b[_0x27cf56(0x3a2)]||_0x31b29b[_0x27cf56(0x12e)]||_0x31b29b[_0x27cf56(0x2af)]||_0x31b29b['safety']),_0x246af9=_0x4a4ba9(_0x31b29b,_0x219b2e),_0x5ac47d=_0x31b29b[_0x27cf56(0x2f6)]?_0x30edd9(_0x31b29b['inputSchema']):null;return{'id':_0x31b29b['id']??null,'summary':_0x31b29b[_0x27cf56(0x4d1)]??null,'description':_0x31b29b[_0x27cf56(0x13c)]??null,'tags':_0x30edd9(_0x31b29b['tags']??[]),'category':_0x31b29b[_0x27cf56(0x5db)]??null,'safety':_0x30edd9(_0x31b29b['safety']??null),'access':_0x30edd9(_0x31b29b[_0x27cf56(0x2af)]??null),'inputSchema':_0x5ac47d,'outputSchema':_0x30edd9(_0x31b29b[_0x27cf56(0x545)]??null),'examples':_0x30edd9(_0x31b29b[_0x27cf56(0x137)]??[]),'pathParams':_0x75a26d,'http':_0x246af9,'cli':_0x30edd9(_0x31b29b['cli']??null),'mcp':_0x30edd9(_0x31b29b[_0x27cf56(0x3a2)]??null),'legacy':{'params':_0x30edd9(_0x31b29b[_0x27cf56(0x275)]??null),'query':_0x30edd9(_0x31b29b[_0x27cf56(0x684)]??null),'body':_0x30edd9(_0x31b29b['body']??null),'response':_0x30edd9(_0x31b29b[_0x27cf56(0x6ef)]??null)},'transport':{'raw':!!_0x31b29b[_0x27cf56(0x349)],'sse':!!_0x31b29b[_0x27cf56(0x4d6)],'rawResponse':!!_0x31b29b[_0x27cf56(0xbb)],'cors':_0x30edd9(_0x31b29b[_0x27cf56(0x198)]??null)},'hasCanonical':_0x26a9d4};}function _0x3e3e8c(_0x47a166,_0x42db5f){const _0x4f33f7=_0x398641;if(!_0x42db5f?.[_0x4f33f7(0x386)])return;if(!_0x42db5f[_0x4f33f7(0x2f6)]||_0x42db5f[_0x4f33f7(0x2f6)]['type']!=='object'||!_0x42db5f[_0x4f33f7(0x2f6)][_0x4f33f7(0x9d)])throw new Error(_0x4f33f7(0x4f2)+_0x47a166[_0x4f33f7(0xdf)]+'\x20'+_0x47a166[_0x4f33f7(0x4c5)]+_0x4f33f7(0x3ec));const _0x1eddb1=_0x42db5f['inputSchema'][_0x4f33f7(0x9d)]||{},_0x335453=new Set(_0x42db5f[_0x4f33f7(0x16a)][_0x4f33f7(0x757)](_0x721773=>_0x721773['name'])),_0x35f4de=new Set(Object[_0x4f33f7(0x6d8)](_0x42db5f[_0x4f33f7(0x91)]?.[_0x4f33f7(0x1e6)]?.[_0x4f33f7(0x9d)]||{})),_0x362da9=new Set(Object[_0x4f33f7(0x6d8)](_0x42db5f['http']?.['bindings']||{}));for(const _0x527dc5 of _0x42db5f[_0x4f33f7(0x16a)]){if(!_0x1eddb1[_0x527dc5[_0x4f33f7(0x707)]])throw new Error(_0x4f33f7(0x4f2)+_0x47a166[_0x4f33f7(0xdf)]+'\x20'+_0x47a166[_0x4f33f7(0x4c5)]+'\x20missing\x20path\x20field\x20in\x20inputSchema:\x20'+_0x527dc5[_0x4f33f7(0x707)]);}for(const _0x35227c of _0x35f4de){if(!_0x1eddb1[_0x35227c])throw new Error(_0x4f33f7(0x4f2)+_0x47a166[_0x4f33f7(0xdf)]+'\x20'+_0x47a166[_0x4f33f7(0x4c5)]+'\x20querySchema\x20references\x20missing\x20input\x20field:\x20'+_0x35227c);}for(const _0x405f36 of _0x362da9){if(!_0x1eddb1[_0x405f36])throw new Error(_0x4f33f7(0x4f2)+_0x47a166[_0x4f33f7(0xdf)]+'\x20'+_0x47a166[_0x4f33f7(0x4c5)]+_0x4f33f7(0x6c)+_0x405f36);}for(const _0x191188 of _0x362da9){if(_0x335453[_0x4f33f7(0x469)](_0x191188))throw new Error('Route\x20'+_0x47a166['method']+'\x20'+_0x47a166[_0x4f33f7(0x4c5)]+'\x20has\x20ambiguous\x20binding\x20for\x20path\x20field:\x20'+_0x191188);if(_0x35f4de[_0x4f33f7(0x469)](_0x191188))throw new Error(_0x4f33f7(0x4f2)+_0x47a166['method']+'\x20'+_0x47a166[_0x4f33f7(0x4c5)]+_0x4f33f7(0x43a)+_0x191188);const _0x5cf610=_0x42db5f['http'][_0x4f33f7(0x433)][_0x191188];if(!/^params\.[A-Za-z0-9_*.-]+$/[_0x4f33f7(0x155)](_0x5cf610)&&!/^query\.[A-Za-z0-9_*.-]+$/[_0x4f33f7(0x155)](_0x5cf610)&&!/^body(?:\.[A-Za-z0-9_*.-]+)?$/[_0x4f33f7(0x155)](_0x5cf610)&&!/^headers\.[A-Za-z0-9_*.-]+$/[_0x4f33f7(0x155)](_0x5cf610))throw new Error(_0x4f33f7(0x4f2)+_0x47a166[_0x4f33f7(0xdf)]+'\x20'+_0x47a166[_0x4f33f7(0x4c5)]+_0x4f33f7(0x42d)+_0x191188+':\x20'+_0x5cf610);}for(const _0x2235ab of _0x35f4de){if(_0x335453[_0x4f33f7(0x469)](_0x2235ab))throw new Error(_0x4f33f7(0x4f2)+_0x47a166[_0x4f33f7(0xdf)]+'\x20'+_0x47a166[_0x4f33f7(0x4c5)]+_0x4f33f7(0xd8)+_0x2235ab);}const _0x24491e=_0x42db5f[_0x4f33f7(0x91)]?.[_0x4f33f7(0x1ef)],_0x4cb329=new Set([_0x4f33f7(0x4c7),_0x4f33f7(0x4d7),'object',_0x4f33f7(0x60c),'array',_0x4f33f7(0x349)]);if(!_0x4cb329[_0x4f33f7(0x469)](_0x24491e))throw new Error(_0x4f33f7(0x4f2)+_0x47a166[_0x4f33f7(0xdf)]+'\x20'+_0x47a166[_0x4f33f7(0x4c5)]+_0x4f33f7(0x115)+_0x24491e);if(_0x24491e===_0x4f33f7(0x349)&&!_0x47a166[_0x4f33f7(0xc9)]?.[_0x4f33f7(0x349)])throw new Error('Route\x20'+_0x47a166[_0x4f33f7(0xdf)]+'\x20'+_0x47a166['path']+_0x4f33f7(0x38f));if(_0x42db5f[_0x4f33f7(0x3a2)]?.[_0x4f33f7(0x1e8)]!==![]&&(_0x47a166[_0x4f33f7(0xc9)]?.[_0x4f33f7(0x349)]||_0x47a166['meta']?.[_0x4f33f7(0x4d6)]||_0x42db5f[_0x4f33f7(0x91)]?.[_0x4f33f7(0x601)]===_0x4f33f7(0x667)))throw new Error(_0x4f33f7(0x4f2)+_0x47a166[_0x4f33f7(0xdf)]+'\x20'+_0x47a166['path']+_0x4f33f7(0xaf)+_0x42db5f[_0x4f33f7(0x91)]?.[_0x4f33f7(0x601)]);const _0x2d482b=Object['keys'](_0x1eddb1)[_0x4f33f7(0x293)](_0x3c0bc8=>{const _0x3d1dab=_0x4f33f7;if(_0x335453['has'](_0x3c0bc8))return![];if(_0x35f4de[_0x3d1dab(0x469)](_0x3c0bc8))return![];if(_0x362da9[_0x3d1dab(0x469)](_0x3c0bc8))return![];return!![];});if(_0x24491e===_0x4f33f7(0x4c7)&&_0x2d482b[_0x4f33f7(0x39d)]>0x0)throw new Error(_0x4f33f7(0x4f2)+_0x47a166[_0x4f33f7(0xdf)]+'\x20'+_0x47a166[_0x4f33f7(0x4c5)]+_0x4f33f7(0x64a)+_0x2d482b[_0x4f33f7(0x10b)](',\x20'));if(_0x24491e===_0x4f33f7(0x465)&&_0x2d482b['filter'](_0xb9d86a=>_0x4760cd(_0x1eddb1[_0xb9d86a],'array'))[_0x4f33f7(0x39d)]!==0x1)throw new Error(_0x4f33f7(0x4f2)+_0x47a166[_0x4f33f7(0xdf)]+'\x20'+_0x47a166['path']+'\x20uses\x20bodyMode:array\x20but\x20does\x20not\x20have\x20exactly\x20one\x20unbound\x20array\x20input\x20field');}function _0x2a2dec(_0x39bdce,_0x1b3dec,_0x508e04,_0x45fd72){const _0x3a8572=_0x398641;for(const [_0x423e2d,_0x3ca391]of Object['entries'](_0x39bdce)){if(_0x1b3dec[_0x3a8572(0x469)](_0x423e2d)||_0x508e04['has'](_0x423e2d)||Object['prototype']['hasOwnProperty'][_0x3a8572(0x3c6)](_0x45fd72,_0x423e2d))continue;if(_0x4760cd(_0x3ca391,_0x3a8572(0x465)))return _0x423e2d;}return null;}function _0x3cc20f(_0x420baa){const _0xe77a57=_0x398641;if(Array[_0xe77a57(0x339)](_0x420baa))return _0x420baa;if(_0x420baa==null)return[];return[_0x420baa];}function _0x4760cd(_0x33852e,_0x167053){const _0x20eb61=_0x398641;return _0x3cc20f(_0x33852e?.['type'])[_0x20eb61(0x8f)](_0x167053);}function _0x50d0ef(_0x5212c5,_0x155ed2){const _0x1e1b0b=_0x398641;if(_0x5212c5==null||typeof _0x5212c5!=='string')return _0x5212c5;const _0x280dd4=_0x3cc20f(_0x155ed2?.['type']);if(_0x280dd4[_0x1e1b0b(0x39d)]===0x0)return _0x5212c5;if(_0x280dd4[_0x1e1b0b(0x8f)](_0x1e1b0b(0x359))&&_0x5212c5===_0x1e1b0b(0x359))return null;if(_0x280dd4[_0x1e1b0b(0x8f)](_0x1e1b0b(0x200))){if(_0x5212c5===_0x1e1b0b(0x727))return!![];if(_0x5212c5===_0x1e1b0b(0x779))return![];}if(_0x280dd4[_0x1e1b0b(0x8f)](_0x1e1b0b(0x19d))&&/^-?\d+$/[_0x1e1b0b(0x155)](_0x5212c5))return Number[_0x1e1b0b(0x384)](_0x5212c5,0xa);if(_0x280dd4['includes'](_0x1e1b0b(0x6af))&&/^-?(?:\d+|\d*\.\d+)$/[_0x1e1b0b(0x155)](_0x5212c5))return Number(_0x5212c5);return _0x5212c5;}function _0x3b3ea3(_0x3abe0a){return _0x30edd9(_0x3abe0a);}function _0x496ca0(_0x2f1aa7,_0x4b9e66={},_0x373a47={},_0x359bc4=null,_0x4c3f14={}){const _0x1ceca6=_0x398641,_0x3387ff=_0x2f1aa7?.[_0x1ceca6(0x396)];if(!_0x3387ff?.[_0x1ceca6(0x386)]||!_0x3387ff['inputSchema'])return null;const _0x3e56f5=_0x3387ff[_0x1ceca6(0x2f6)]['properties']||{},_0x356ea4=_0x3387ff['http']?.[_0x1ceca6(0x1e6)]?.[_0x1ceca6(0x9d)]||{},_0x154d4e=_0x3387ff[_0x1ceca6(0x91)]?.[_0x1ceca6(0x433)]||{},_0x226330=new Set((_0x3387ff[_0x1ceca6(0x16a)]||[])[_0x1ceca6(0x757)](_0x5af62f=>_0x5af62f[_0x1ceca6(0x707)])),_0x3c9e7a=new Set(Object[_0x1ceca6(0x6d8)](_0x356ea4)),_0x329f5b={};for(const [_0x13a7e9,_0x56f422]of Object[_0x1ceca6(0x61d)](_0x3e56f5)){Object[_0x1ceca6(0x568)][_0x1ceca6(0x1fa)][_0x1ceca6(0x3c6)](_0x56f422||{},_0x1ceca6(0x3e8))&&(_0x329f5b[_0x13a7e9]=_0x3b3ea3(_0x56f422[_0x1ceca6(0x3e8)]));}for(const _0x26280e of _0x3387ff[_0x1ceca6(0x16a)]||[]){if(!Object[_0x1ceca6(0x568)][_0x1ceca6(0x1fa)][_0x1ceca6(0x3c6)](_0x4b9e66,_0x26280e[_0x1ceca6(0x707)]))continue;const _0x4e81b5=_0x3e56f5[_0x26280e[_0x1ceca6(0x707)]]||{};_0x329f5b[_0x26280e[_0x1ceca6(0x707)]]=_0x50d0ef(_0x4b9e66[_0x26280e[_0x1ceca6(0x707)]],_0x4e81b5);}for(const [_0x162b93,_0x50a27d]of Object['entries'](_0x356ea4)){if(!Object[_0x1ceca6(0x568)][_0x1ceca6(0x1fa)][_0x1ceca6(0x3c6)](_0x373a47,_0x162b93))continue;_0x329f5b[_0x162b93]=_0x50d0ef(_0x373a47[_0x162b93],_0x50a27d||_0x3e56f5[_0x162b93]||{});}for(const [_0x23a097,_0x3fd25d]of Object[_0x1ceca6(0x61d)](_0x154d4e)){if(typeof _0x3fd25d!==_0x1ceca6(0xe7))continue;let _0x28d988;if(_0x3fd25d[_0x1ceca6(0x42e)](_0x1ceca6(0x45e)))_0x28d988=_0x4b9e66[_0x3fd25d[_0x1ceca6(0x13a)](0x7)];else{if(_0x3fd25d['startsWith'](_0x1ceca6(0x3eb)))_0x28d988=_0x373a47[_0x3fd25d[_0x1ceca6(0x13a)](0x6)];else{if(_0x3fd25d===_0x1ceca6(0x4fc))_0x28d988=_0x359bc4;else{if(_0x3fd25d[_0x1ceca6(0x42e)]('body.'))_0x28d988=_0x359bc4?.[_0x3fd25d[_0x1ceca6(0x13a)](0x5)];else{if(_0x3fd25d[_0x1ceca6(0x42e)]('headers.'))_0x28d988=_0x4c3f14?.[_0x3fd25d[_0x1ceca6(0x13a)](0x8)[_0x1ceca6(0x8d)]()]??_0x4c3f14?.[_0x3fd25d[_0x1ceca6(0x13a)](0x8)];}}}}if(_0x28d988!==undefined)_0x329f5b[_0x23a097]=_0x28d988;}const _0x1fe070=_0x3387ff[_0x1ceca6(0x91)]?.['bodyMode'];if(_0x1fe070!==_0x1ceca6(0x4c7)&&_0x1fe070!=='raw'&&_0x359bc4!=null){if(_0x1fe070===_0x1ceca6(0x465)&&Array[_0x1ceca6(0x339)](_0x359bc4)){const _0x2dce6d=_0x2a2dec(_0x3e56f5,_0x226330,_0x3c9e7a,_0x154d4e);if(_0x2dce6d)_0x329f5b[_0x2dce6d]=_0x359bc4;}else{if(_0x1fe070===_0x1ceca6(0x5d4))for(const [_0x31c729,_0x145663]of Object[_0x1ceca6(0x61d)](_0x3e56f5)){if(_0x226330[_0x1ceca6(0x469)](_0x31c729)||_0x3c9e7a[_0x1ceca6(0x469)](_0x31c729)||Object['prototype'][_0x1ceca6(0x1fa)][_0x1ceca6(0x3c6)](_0x154d4e,_0x31c729))continue;if(Object['prototype'][_0x1ceca6(0x1fa)][_0x1ceca6(0x3c6)](_0x359bc4,_0x31c729))_0x329f5b[_0x31c729]=_0x359bc4[_0x31c729];else{if(_0x4760cd(_0x145663,'object'))_0x329f5b[_0x31c729]=_0x359bc4;}}else for(const [_0x14fde8,_0x412c2f]of Object[_0x1ceca6(0x61d)](_0x359bc4)){if(_0x226330['has'](_0x14fde8)||_0x3c9e7a[_0x1ceca6(0x469)](_0x14fde8)||Object[_0x1ceca6(0x568)][_0x1ceca6(0x1fa)][_0x1ceca6(0x3c6)](_0x154d4e,_0x14fde8))continue;_0x329f5b[_0x14fde8]=_0x412c2f;}}}return _0x329f5b;}function _0x320501(_0x47179b,_0x1dbb93,_0x78ac1,_0xbbfb82){const _0x4541fa=_0x398641;if(!_0x1dbb93)return;const _0x13343f=_0x3cc20f(_0x1dbb93[_0x4541fa(0x66f)]);if(_0x47179b===undefined)return;if(_0x47179b===null){_0x13343f['length']>0x0&&!_0x13343f['includes']('null')&&_0xbbfb82[_0x4541fa(0x2f9)]({'field':_0x78ac1,'message':_0x4541fa(0x4da),'expected':_0x13343f[_0x4541fa(0x10b)]('|'),'actual':null});return;}if(_0x13343f[_0x4541fa(0x39d)]===0x0)return;const _0xaaa84e=_0x13343f[_0x4541fa(0x35c)](_0x26ea52=>{const _0x33b690=_0x4541fa;switch(_0x26ea52){case'string':return typeof _0x47179b===_0x33b690(0xe7);case _0x33b690(0x19d):return Number[_0x33b690(0x446)](_0x47179b);case _0x33b690(0x6af):return typeof _0x47179b===_0x33b690(0x6af)&&Number[_0x33b690(0x3ff)](_0x47179b);case _0x33b690(0x200):return typeof _0x47179b==='boolean';case _0x33b690(0x5d4):return _0x47179b&&typeof _0x47179b===_0x33b690(0x5d4)&&!Array[_0x33b690(0x339)](_0x47179b);case'array':return Array[_0x33b690(0x339)](_0x47179b);case'null':return _0x47179b===null;default:return!![];}});if(!_0xaaa84e){_0xbbfb82[_0x4541fa(0x2f9)]({'field':_0x78ac1,'message':_0x4541fa(0x217)+_0x13343f[_0x4541fa(0x10b)]('|'),'expected':_0x13343f[_0x4541fa(0x10b)]('|'),'actual':_0x47179b});return;}Array[_0x4541fa(0x339)](_0x47179b)&&_0x1dbb93[_0x4541fa(0x281)]&&_0x47179b[_0x4541fa(0x2e2)]((_0x24aa51,_0x24edca)=>_0x320501(_0x24aa51,_0x1dbb93[_0x4541fa(0x281)],_0x78ac1+'['+_0x24edca+']',_0xbbfb82));}function _0xcc0250(_0x9bb484,_0x1baab0){const _0x299415=_0x398641,_0x162dba=_0x9bb484?.[_0x299415(0x396)];if(!_0x162dba?.['hasCanonical']||!_0x162dba['inputSchema'])return null;const _0x1bb320=_0x162dba['inputSchema'],_0x2d795f=_0x1bb320['properties']||{},_0x86277e=new Set(_0x1bb320[_0x299415(0x323)]||[]),_0x5155ab=[];for(const _0x38cf6a of _0x86277e){_0x1baab0[_0x38cf6a]===undefined&&_0x5155ab['push']({'field':_0x38cf6a,'message':_0x299415(0x1ad),'expected':_0x299415(0x59f),'actual':undefined});}if(_0x1bb320['additionalProperties']===![])for(const _0x45a435 of Object['keys'](_0x1baab0||{})){!Object[_0x299415(0x568)][_0x299415(0x1fa)]['call'](_0x2d795f,_0x45a435)&&_0x5155ab[_0x299415(0x2f9)]({'field':_0x45a435,'message':_0x299415(0x332),'expected':_0x299415(0x5a3),'actual':_0x1baab0[_0x45a435]});}for(const [_0x2dcd70,_0x2f6a12]of Object[_0x299415(0x61d)](_0x2d795f)){_0x320501(_0x1baab0[_0x2dcd70],_0x2f6a12,_0x2dcd70,_0x5155ab);}if(_0x5155ab[_0x299415(0x39d)]===0x0)return null;return{'code':_0x299415(0x1a4),'errors':_0x5155ab};}function _0x4dad28(_0x136509=[]){const _0x570e8a=_0x398641;if(!Array[_0x570e8a(0x339)](_0x136509)||_0x136509['length']===0x0)return null;const _0x2e4fbb=_0x136509['slice'](0x0,0x3)[_0x570e8a(0x757)]((_0x20be1d={})=>{const _0x38e9c7=_0x570e8a,_0x46b4e1=_0x20be1d[_0x38e9c7(0x46e)]?_0x20be1d['field']+'\x20':'';return(''+_0x46b4e1+(_0x20be1d[_0x38e9c7(0x5e6)]||_0x38e9c7(0x324)))[_0x38e9c7(0x471)]();})[_0x570e8a(0x10b)](';\x20');return _0x136509['length']>0x3?_0x2e4fbb+_0x570e8a(0x6a3)+(_0x136509['length']-0x3)+_0x570e8a(0x403):_0x2e4fbb;}function _0x23db35(_0x45952e,_0x4157a0={}){const _0x38e6f2=_0x398641,_0x2a56da=_0x4157a0?.[_0x38e6f2(0x5a1)]?.[_0x38e6f2(0x492)]??_0x4157a0?.[_0x38e6f2(0x492)]??_0x38e6f2(0x58a),_0x316ef6=_0x4157a0?.[_0x38e6f2(0x5a1)]?.['details']??_0x4157a0?.[_0x38e6f2(0x2a6)]??_0x2a56da?.['details']??null,_0x9c0b8=_0x4157a0?.[_0x38e6f2(0x5a1)]?.['code']??_0x4157a0?.[_0x38e6f2(0x25b)]??_0x2a56da?.['code']??null,_0xc5c72b=_0x4157a0?.[_0x38e6f2(0x5a1)]?.['message']??_0x4157a0?.[_0x38e6f2(0x5e6)]??_0x2a56da?.['message']??null,_0x1b974d=typeof _0x2a56da==='string'?_0x2a56da:null,_0x53e19c=typeof _0x1b974d===_0x38e6f2(0xe7)&&/^[A-Z0-9_]+$/[_0x38e6f2(0x155)](_0x1b974d),_0x273994=_0x9c0b8??(_0x53e19c?_0x1b974d:null)??(_0x341cf6[_0x45952e]||'HTTP_'+_0x45952e);let _0x2a81e4=_0xc5c72b;!_0x2a81e4&&typeof _0x1b974d===_0x38e6f2(0xe7)&&!_0x53e19c&&(_0x2a81e4=_0x1b974d);if(!_0x2a81e4&&_0x273994===_0x38e6f2(0x1a4)){const _0x252bad=_0x4dad28(_0x316ef6);_0x2a81e4=_0x252bad?_0x38e6f2(0x538)+_0x252bad:_0x38e6f2(0x1a5);}if(!_0x2a81e4&&Array[_0x38e6f2(0x339)](_0x316ef6)&&_0x316ef6[_0x38e6f2(0x39d)]>0x0){const _0x1b5457=_0x4dad28(_0x316ef6);if(_0x1b5457)_0x2a81e4=_0x1b5457;}if(!_0x2a81e4)_0x2a81e4=_0x341cf6[_0x45952e]||_0x38e6f2(0x58a);const _0x35bf50={'code':_0x273994,'message':_0x2a81e4};if(_0x316ef6!=null)_0x35bf50[_0x38e6f2(0x2a6)]=_0x316ef6;return _0x35bf50;}function _0x342723(_0x525d9e){const _0x192a8c=_0x398641,_0x1fb9c2={};if(!_0x525d9e)return _0x1fb9c2;for(const _0x378c02 of _0x525d9e['split'](';')){const _0x107f44=_0x378c02[_0x192a8c(0x380)]('=');if(_0x107f44===-0x1)continue;const _0x423b0a=_0x378c02[_0x192a8c(0x13a)](0x0,_0x107f44)[_0x192a8c(0x471)](),_0x490c10=_0x378c02[_0x192a8c(0x13a)](_0x107f44+0x1)[_0x192a8c(0x471)]();_0x1fb9c2[_0x423b0a]=decodeURIComponent(_0x490c10);}return _0x1fb9c2;}function _0x5c600f(_0x3cde92,_0x39bf5d){const _0x34043b=_0x398641;return _0x39bf5d=_0x5b9500(_0x39bf5d),{'status':_0x39bf5d[_0x34043b(0x170)]??_0x3cde92[_0x34043b(0x170)],'headers':{..._0x3cde92['headers']||{},..._0x39bf5d['headers']||{}},'body':_0x39bf5d[_0x34043b(0x4fc)]??_0x3cde92[_0x34043b(0x4fc)]};}function _0x59eb41(_0x4462bb={}){const _0x31de8b=_0x398641;return _0x4462bb[_0x31de8b(0x601)]||(_0x4462bb[_0x31de8b(0x1db)]?_0x31de8b(0x1db):_0x31de8b(0x91));}function _0x1aa987(_0x45fcfe){const _0x406393=_0x398641;if(_0x45fcfe['context']?.[_0x406393(0x1db)]===!![])return!![];if(_0x45fcfe[_0x406393(0xb3)]?.[_0x406393(0x8a)]?.[_0x406393(0x3a9)]===!![])return!![];if(_0x45fcfe[_0x406393(0xb3)]?.[_0x406393(0x8a)]?.['ok']===!![])return!![];return![];}function _0x341aba(_0x53bee,_0x2f9d3c){const _0x4d0d55=_0x2f9d3c['split']('.');let _0x2c8fa1=_0x53bee;for(const _0xdd52a7 of _0x4d0d55){_0x2c8fa1=_0x2c8fa1?.[_0xdd52a7];}return _0x2c8fa1||null;}class _0x1fe4c0{constructor(){const _0x4ea8ea=_0x398641;this[_0x4ea8ea(0x2e8)]=[],this['guards']=[],this[_0x4ea8ea(0x249)]=[],this[_0x4ea8ea(0xc4)]=0x5*0x400*0x400,this[_0x4ea8ea(0x33d)]=null,this[_0x4ea8ea(0x63b)]=[],this[_0x4ea8ea(0x6d0)]=new Set(),this[_0x4ea8ea(0x8a)]={'cookieName':_0x4ea8ea(0xea),'stateCookieName':_0x4ea8ea(0x1c6),'csrfCookieName':'kdb_admin_csrf'},this[_0x4ea8ea(0x2c0)]={},this['_loginStates']=new Map(),this['_oidcDiscoveryCache']=null,this['_jwksCache']=null,this['_jwksNegativeCache']=new Map(),this['metrics']=new _0x1c47b3(),this[_0x4ea8ea(0x426)]=![],this[_0x4ea8ea(0x168)]=0x0;}[_0x398641(0x1b0)](_0x1fdb35={}){const _0x55c7f4=_0x398641;return this[_0x55c7f4(0x2c0)]=_0x1fdb35||{},this[_0x55c7f4(0x376)]=_0x1fdb35[_0x55c7f4(0x38b)]??_0x55c7f4(0x1fd),this[_0x55c7f4(0x2c0)];}get[_0x398641(0x13d)](){const _0x25aa43=_0x398641;if(this[_0x25aa43(0x7d)]?.[_0x25aa43(0x8a)])return this['_okdb']['auth'][_0x25aa43(0x13d)];return![];}[_0x398641(0x181)](){const _0x48d46a=_0x398641;if(this[_0x48d46a(0x7d)]?.[_0x48d46a(0x8a)])return this['_okdb']['auth'][_0x48d46a(0x181)]();return this[_0x48d46a(0x2c0)]||{};}[_0x398641(0x724)](_0x434924){const _0x51eb09=_0x398641;this[_0x51eb09(0x2e8)]['push'](_0x434924);}[_0x398641(0x71)](_0x351b8f,_0xcc9842){const _0x306ad0=_0x398641;this[_0x306ad0(0x288)][_0x306ad0(0x2f9)]({'match':_0x351b8f,'handler':_0xcc9842});}[_0x398641(0x3e9)](_0x42806b,_0x48f426,_0x2abc8d,_0x5ea677={}){const _0x33624e=_0x398641,_0x1c85c4={'method':_0x2ba097(_0x42806b),'path':_0x48f426,'matcher':_0x800295(_0x48f426),'handler':_0x2abc8d,'meta':_0x5ea677||{}},_0x3b7434=_0x2da795(_0x1c85c4);_0x3e3e8c(_0x1c85c4,_0x3b7434),_0x1c85c4[_0x33624e(0x396)]=_0x3b7434,_0x1c85c4['userAdded']=this[_0x33624e(0x426)]===!![];if(_0x1c85c4['userAdded'])this[_0x33624e(0x168)]++;this[_0x33624e(0x249)][_0x33624e(0x2f9)](_0x1c85c4);}[_0x398641(0x711)](_0xbd0ab1,_0x5a9d61,_0xf49f8d,_0x1bf5cb={}){this['add'](_0xbd0ab1,_0x5a9d61,_0xf49f8d,{..._0x1bf5cb,'raw':!![]});}['_bestMatch'](_0x29ea40,_0x4fb337,{corsOnly:corsOnly=![]}={}){const _0x2f21ba=_0x398641;let _0x529d9a=null,_0x412099=Infinity;for(const _0x1834aa of this[_0x2f21ba(0x249)]){if(corsOnly){if(!_0x1834aa['meta']?.[_0x2f21ba(0x198)])continue;}else{if(_0x1834aa[_0x2f21ba(0xdf)]!==_0x29ea40)continue;}if(!_0x1834aa[_0x2f21ba(0x3a1)][_0x2f21ba(0x42f)][_0x2f21ba(0x155)](_0x4fb337))continue;const _0xc809e=_0x1834aa[_0x2f21ba(0x3a1)][_0x2f21ba(0x6d8)]?.['length']??0x0;if(_0xc809e<_0x412099){_0x529d9a=_0x1834aa,_0x412099=_0xc809e;if(_0xc809e===0x0)break;}}return _0x529d9a;}['_matchRoute'](_0x3a00dd,_0x80ef4){const _0x456e81=_0x398641,_0x39da8a=_0x2ba097(_0x3a00dd),_0x5899db=this[_0x456e81(0x47d)](_0x39da8a,_0x80ef4);if(_0x5899db)return _0x5899db;if(_0x39da8a===_0x456e81(0x43f))return this[_0x456e81(0x47d)](_0x39da8a,_0x80ef4,{'corsOnly':!![]});return null;}[_0x398641(0x2b2)](_0x4ba781,_0xeabc64){const _0x59b8ba=_0x398641;if(_0x4ba781?.[_0x59b8ba(0xc9)]?.[_0x59b8ba(0xbb)])return![];if(_0xeabc64?.[_0x59b8ba(0x165)]?.[_0x59b8ba(0x224)])return![];return!![];}['listRoutes'](){const _0x15fad5=_0x398641;return this[_0x15fad5(0x249)][_0x15fad5(0x293)](_0x5cb474=>!_0x5cb474['meta']?.[_0x15fad5(0x4f4)])[_0x15fad5(0x757)](_0x45da79=>({'method':_0x45da79['method'],'path':_0x45da79[_0x15fad5(0x4c5)],'defaults':_0x45da79[_0x15fad5(0x3a1)][_0x15fad5(0x10f)],'meta':_0x45da79[_0x15fad5(0xc9)],'operation':_0x45da79[_0x15fad5(0x396)]}));}['addSSE'](_0x599f08,_0x51ab39,_0x3cd3c0={}){const _0x5555c9=_0x398641,{PassThrough:_0x2a22eb}=require$$5;this[_0x5555c9(0x3e9)](_0x5555c9(0x248),_0x599f08,({params:_0x3ee3c6,query:_0x191b29,headers:_0x1c207d,context:_0x5008fd})=>{const _0x119ad8=_0x5555c9,_0x2371df=new _0x2a22eb();let _0x37fdff=null;const _0x507222={};try{_0x5008fd?.[_0x119ad8(0x38d)]?.['socket']?.['setNoDelay'](!![]);}catch{}_0x2371df[_0x119ad8(0xb6)](_0x119ad8(0x412)),_0x37fdff=setInterval(()=>{const _0x158d3f=_0x119ad8;try{_0x2371df[_0x158d3f(0xb6)](_0x158d3f(0x58d));}catch{}},0x3a98);const _0x5245ae=(_0x24a5f3,_0xf9513b,_0xa4ed4={})=>{const _0x4f4ebc=_0x119ad8;try{const _0x31a484=_0xa4ed4[_0x4f4ebc(0x349)]?String(_0xf9513b??''):JSON[_0x4f4ebc(0x5c1)](_0xf9513b);_0xa4ed4['id']!=null&&_0x2371df[_0x4f4ebc(0xb6)](_0x4f4ebc(0x607)+_0xa4ed4['id']+'\x0a');_0x2371df[_0x4f4ebc(0xb6)](_0x4f4ebc(0x6a5)+_0x24a5f3+'\x0a');for(const _0x58d53a of _0x31a484[_0x4f4ebc(0x2aa)]('\x0a')){_0x2371df[_0x4f4ebc(0xb6)](_0x4f4ebc(0xdc)+_0x58d53a+'\x0a');}_0x2371df['write']('\x0a');}catch{}},_0x573696=()=>{const _0x20e770=_0x119ad8;_0x37fdff&&(clearInterval(_0x37fdff),_0x37fdff=null);try{_0x2371df[_0x20e770(0x565)]();}catch{}},_0x2dd4fd=(_0x1a7d6d,_0x1cde30)=>{_0x507222[_0x1a7d6d]=_0x1cde30;};_0x5008fd?.[_0x119ad8(0x38d)]?.['on'](_0x119ad8(0x44f),_0x573696),_0x2371df['on'](_0x119ad8(0x44f),_0x573696);if(_0x5008fd?.[_0x119ad8(0x8a)]&&_0x5008fd[_0x119ad8(0x8a)][_0x119ad8(0x1fd)]!==!![]&&_0x5008fd[_0x119ad8(0x8a)][_0x119ad8(0x3a9)]){const _0x147cca={'headers':_0x1c207d??{},'cookies':_0x342723(_0x1c207d?.[_0x119ad8(0xf2)]),'context':{},'socket':_0x5008fd?.[_0x119ad8(0x38d)]?.[_0x119ad8(0xa2)]??{'remoteAddress':null}},_0x3d87aa=setInterval(async()=>{const _0x4a924e=_0x119ad8;try{const _0x5e9906=await this[_0x4a924e(0xf1)](_0x147cca);if(_0x5e9906?.[_0x4a924e(0x1fd)]===!![]||_0x5e9906?.[_0x4a924e(0x3a9)])return;_0x5245ae(_0x4a924e(0x8a),{'expired':!![]}),_0x573696();}catch{_0x573696();}},0xea60);_0x3d87aa[_0x119ad8(0xe9)]?.(),_0x2371df['on'](_0x119ad8(0x44f),()=>clearInterval(_0x3d87aa));}const _0x480536=_0x51ab39({'send':_0x5245ae,'close':_0x573696,'params':_0x3ee3c6??{},'query':_0x191b29??{},'headers':_0x1c207d??{},'context':_0x5008fd,'setHeader':_0x2dd4fd});return typeof _0x480536==='function'&&_0x2371df['on'](_0x119ad8(0x44f),_0x480536),{'status':0xc8,'headers':{'content-type':'text/event-stream;\x20charset=utf-8','cache-control':_0x119ad8(0x50d),'connection':'keep-alive','x-accel-buffering':'no',..._0x507222},'body':_0x2371df};},{..._0x3cd3c0,'sse':!![]});}async[_0x398641(0x57c)](_0xba1e23,_0x58626f){const _0x46b37c=_0x398641;for(const _0x20266c of this['guards']){if(!_0x20266c['match'](_0xba1e23))continue;const _0x5cfdd1=await _0x20266c[_0x46b37c(0x4ee)](_0xba1e23,_0x58626f);if(_0x5cfdd1===![])return![];}return!![];}async[_0x398641(0x6c6)](_0x344ff1,_0x45b57e,_0x48fc7d){let _0x13d0c0=0x0;const _0x536176=async()=>{const _0x283814=_0x8cd7,_0x2c9a94=this[_0x283814(0x2e8)][_0x13d0c0++];if(!_0x2c9a94)return _0x48fc7d();return _0x2c9a94(_0x344ff1,_0x45b57e,_0x536176);};return _0x536176();}[_0x398641(0x502)](_0x2d5ae7,_0x5c343a){const _0x4f2096=_0x398641,{status:status=0xc8,headers:headers={},body:_0x1243dc}=_0x2d5ae7;if(status>=0x12c&&status<0x190)return _0x2d5ae7;if(_0x8fc7b4(_0x1243dc))return _0x2d5ae7;if(Buffer[_0x4f2096(0x365)](_0x1243dc))return _0x2d5ae7;if(typeof _0x1243dc===_0x4f2096(0xe7))return _0x2d5ae7;const _0xd19f76={'time':+_0x5c343a[_0x4f2096(0x72c)](0x2)};if(_0x1243dc?.[_0x4f2096(0xc9)]&&typeof _0x1243dc[_0x4f2096(0xc9)]==='object'){const {time:_0x5bf29d,..._0x1bc60c}=_0x1243dc[_0x4f2096(0xc9)];Object[_0x4f2096(0x640)](_0xd19f76,_0x1bc60c);}let _0x32a5bd;if(status>=0x190){const _0x505cda=_0x23db35(status,_0x1243dc);_0x32a5bd={'data':null,'error':_0x505cda,'meta':_0xd19f76};}else{if(status===0xcc||_0x1243dc==null)_0x32a5bd={'data':null,'error':null,'meta':_0xd19f76};else{let _0x30d254;if('result'in _0x1243dc)_0x30d254=_0x1243dc[_0x4f2096(0x5a1)];else{const {meta:_0x31a2cf,..._0x3c7372}=_0x1243dc;_0x30d254=Object['keys'](_0x3c7372)[_0x4f2096(0x39d)]>0x0?_0x3c7372:null;}_0x32a5bd={'data':_0x30d254,'error':null,'meta':_0xd19f76};}}return{'status':status===0xcc?0xc8:status,'headers':headers,'body':_0x32a5bd};}async[_0x398641(0x20e)](_0x292112,_0x346188,_0xe04488={},_0x1cd35b={}){const _0x2af299=_0x398641;_0x292112=_0x2ba097(_0x292112);const _0x3548cb=this['_matchRoute'](_0x292112,_0x346188),_0x31386e={'method':_0x292112,'path':_0x346188,'headers':_0xe04488['headers']??{},'body':_0xe04488[_0x2af299(0x4fc)]??null,'query':_0xe04488[_0x2af299(0x684)]??{},'context':_0x1cd35b,'cookies':_0x342723(_0xe04488[_0x2af299(0x165)]?.[_0x2af299(0xf2)]),'route':_0x3548cb,'socket':{'remoteAddress':_0xe04488[_0x2af299(0x4d2)]??_0x2af299(0x6b4)}};_0x31386e[_0x2af299(0xb3)]=_0x31386e['context']||{};!_0x31386e['context'][_0x2af299(0x8a)]&&(_0x31386e[_0x2af299(0xb3)][_0x2af299(0x8a)]=await this[_0x2af299(0xf1)](_0x31386e));if(_0x31386e['context']['auth']?.[_0x2af299(0x373)])return _0x5b9500({'status':0x193,'body':{'error':{'code':'BOOTSTRAP_LOCALHOST_ONLY','message':_0x2af299(0x54e)}}});_0x31386e[_0x2af299(0xb3)][_0x2af299(0x8a)]?.[_0x2af299(0x9b)]&&!_0x31386e[_0x2af299(0xb3)][_0x2af299(0x9b)]&&(_0x31386e[_0x2af299(0xb3)][_0x2af299(0x9b)]=_0x31386e[_0x2af299(0xb3)][_0x2af299(0x8a)][_0x2af299(0x9b)]);let _0x5dbaed=null;const _0x36bac0={'status'(_0x10ea44){const _0x2e4795=_0x2af299;_0x5dbaed=_0x5dbaed||{},_0x5dbaed[_0x2e4795(0x170)]=_0x10ea44;},'setHeader'(_0x46bdd3,_0x7e10c5){const _0x48a7cd=_0x2af299;_0x5dbaed=_0x5dbaed||{},_0x5dbaed[_0x48a7cd(0x165)]=_0x5dbaed[_0x48a7cd(0x165)]||{};const _0x2c5b9b=String(_0x46bdd3)['toLowerCase']();if(_0x2c5b9b===_0x48a7cd(0x264)){const _0x39dea0=_0x5dbaed[_0x48a7cd(0x165)][_0x46bdd3];if(!_0x39dea0)_0x5dbaed[_0x48a7cd(0x165)][_0x46bdd3]=_0x7e10c5;else{if(Array[_0x48a7cd(0x339)](_0x39dea0))_0x39dea0['push'](_0x7e10c5);else _0x5dbaed[_0x48a7cd(0x165)][_0x46bdd3]=[_0x39dea0,_0x7e10c5];}return;}_0x5dbaed[_0x48a7cd(0x165)][_0x46bdd3]=_0x7e10c5;},'send'(_0x193ab2){const _0x47e990=_0x2af299;_0x5dbaed=_0x5dbaed||{},_0x5dbaed[_0x47e990(0x4fc)]=_0x193ab2;}},_0x44dcf9=await this[_0x2af299(0x57c)](_0x31386e,_0x36bac0);if(!_0x44dcf9)return _0x5b9500(_0x5dbaed??{'status':0x193});const _0x112e2a=this[_0x2af299(0x1b7)](_0x31386e);if(_0x112e2a)return _0x5b9500(_0x112e2a);const _0xc6246c=this[_0x2af299(0x55b)](_0x31386e);if(_0xc6246c)return _0x5b9500(_0xc6246c);return await this['_runMiddlewares'](_0x31386e,_0x36bac0,async()=>{const _0x41d99c=_0x2af299,_0x1d393b=await this[_0x41d99c(0x50a)](_0x31386e);if(_0x5dbaed==null){_0x5dbaed=_0x1d393b;return;}_0x5dbaed=_0x5c600f(_0x5dbaed,_0x1d393b);}),_0x5b9500(_0x5dbaed);}[_0x398641(0x1b7)](_0xddca9){const _0xd6e502=_0x398641,_0x32048e=_0xddca9[_0xd6e502(0x67f)]?.[_0xd6e502(0x396)],_0x4080f3=_0x32048e?.[_0xd6e502(0x2af)];if(!_0x32048e?.['hasCanonical']||!_0x4080f3)return null;if(_0xddca9[_0xd6e502(0xb3)]?.[_0xd6e502(0x8a)]?.[_0xd6e502(0x1fd)]===!![]||_0xddca9[_0xd6e502(0xb3)]?.[_0xd6e502(0x8a)]?.[_0xd6e502(0x36f)]===!![])return null;const _0x5a1b92=_0x59eb41(_0xddca9['context']),_0x5062e5=Array['isArray'](_0x4080f3['audiences'])?_0x4080f3[_0xd6e502(0x439)]:null;if(_0x4080f3[_0xd6e502(0x3dd)]&&_0xddca9[_0xd6e502(0xb3)]?.['internal']!==!![])return{'status':0x193,'body':{'error':'Forbidden'}};if(_0x5062e5&&_0x5062e5[_0xd6e502(0x39d)]>0x0&&!_0x5062e5[_0xd6e502(0x8f)](_0x5a1b92)&&!(_0x5a1b92===_0xd6e502(0x1db)&&_0x5062e5[_0xd6e502(0x8f)](_0xd6e502(0x30a))))return{'status':0x193,'body':{'error':_0xd6e502(0x3cf)}};if(_0x4080f3['authRequired']&&!_0x1aa987(_0xddca9))return{'status':0x191,'body':{'error':_0xd6e502(0x456)}};const _0x28e734=_0x4080f3[_0xd6e502(0x6b)];if(!_0x28e734)return null;if(_0xddca9['context']?.[_0xd6e502(0x8a)]?.[_0xd6e502(0x66f)]===_0xd6e502(0x5dd))return null;const _0xc38e58=_0xddca9[_0xd6e502(0xb3)]?.[_0xd6e502(0x8a)]?.[_0xd6e502(0x129)];if(!_0xc38e58){if(_0xddca9['context']?.[_0xd6e502(0x8a)]?.['ok']===!![])return null;return{'status':0x193,'body':{'error':'Forbidden\x20—\x20no\x20permissions\x20available'}};}if(!_0xddca9[_0xd6e502(0x275)]&&_0xddca9['route']?.[_0xd6e502(0x3a1)]){const _0x5b16da=_0xddca9[_0xd6e502(0x67f)]['matcher']['regex'][_0xd6e502(0xb1)](_0xddca9[_0xd6e502(0x4c5)]);_0x5b16da&&(_0xddca9[_0xd6e502(0x275)]={},_0xddca9[_0xd6e502(0x67f)][_0xd6e502(0x3a1)]['keys'][_0xd6e502(0x2e2)]((_0x1e23a4,_0x40e0ba)=>{const _0x518460=_0xd6e502,_0x5a5221=_0x5b16da[_0x40e0ba+0x1];_0xddca9['params'][_0x1e23a4]=_0x5a5221?decodeURIComponent(_0x5a5221):_0xddca9['route']['matcher'][_0x518460(0x10f)][_0x1e23a4]??undefined;}));}let _0x2a4670=null;const _0x19014b=_0x4080f3[_0xd6e502(0x498)]===_0xd6e502(0x124)?_0xd6e502(0x5b0):_0x4080f3[_0xd6e502(0x498)]?.[_0xd6e502(0x124)];_0x19014b&&(_0x2a4670=_0x341aba(_0xddca9,_0x19014b));if(_0x2a4670&&_0x2a4670[_0xd6e502(0x42e)]('~')){const _0x1ab43c=_0x32f72e(_0x28e734),_0x483237=_0x1cd758(_0xc38e58[_0xd6e502(0x1f4)]||[],(_0xc38e58[_0xd6e502(0x660)]||{})[_0x2a4670]||[]);if(!_0x1d012a(_0x483237,_0x1ab43c))return{'status':0x193,'body':{'error':_0xd6e502(0x280)+_0x1ab43c+'\x20for\x20system\x20env'}};}const _0x1ddb7f=_0x1cd758(_0xc38e58[_0xd6e502(0x1f4)]||[],_0x2a4670?(_0xc38e58['grants']||{})[_0x2a4670]||[]:[]);if(!_0x1d012a(_0x1ddb7f,_0x28e734))return{'status':0x193,'body':{'error':_0xd6e502(0x280)+_0x28e734}};return null;}['_validateOperationRequest'](_0x128968){const _0x3f7f63=_0x398641,_0x169b2b=_0x128968[_0x3f7f63(0x67f)],_0x104b1e=_0x169b2b?.[_0x3f7f63(0x396)];if(!_0x104b1e?.[_0x3f7f63(0x386)]||!_0x104b1e[_0x3f7f63(0x2f6)])return null;let _0x3bebf6=_0x128968[_0x3f7f63(0x275)]??null;if(!_0x3bebf6&&_0x169b2b?.[_0x3f7f63(0x3a1)]){const _0x581a02=_0x169b2b[_0x3f7f63(0x3a1)]['regex']['exec'](_0x128968[_0x3f7f63(0x4c5)]);_0x581a02&&(_0x3bebf6={},_0x169b2b[_0x3f7f63(0x3a1)]['keys'][_0x3f7f63(0x2e2)]((_0x2f45c3,_0x6dbe98)=>{const _0x25220b=_0x3f7f63,_0x2bac58=_0x581a02[_0x6dbe98+0x1];_0x3bebf6[_0x2f45c3]=_0x2bac58?decodeURIComponent(_0x2bac58):_0x169b2b[_0x25220b(0x3a1)][_0x25220b(0x10f)][_0x2f45c3]??undefined;}));}const _0x8f3bc0=_0x496ca0(_0x169b2b,_0x3bebf6??{},_0x128968[_0x3f7f63(0x684)]??{},_0x128968[_0x3f7f63(0x4fc)],_0x128968[_0x3f7f63(0x165)]??{}),_0x41f30a=_0xcc0250(_0x169b2b,_0x8f3bc0||{});if(!_0x41f30a)return null;const _0x5f2af7=_0x4dad28(_0x41f30a[_0x3f7f63(0x422)]);return{'status':0x190,'body':{'error':_0x41f30a[_0x3f7f63(0x25b)],'code':_0x41f30a[_0x3f7f63(0x25b)],'message':_0x5f2af7?_0x3f7f63(0x538)+_0x5f2af7:_0x3f7f63(0x1a5),'details':_0x41f30a[_0x3f7f63(0x422)]}};}['validateRouteInput'](_0x5dcb9b,_0x5413b3){const _0x10d42b=_0x398641,_0x527ecb=_0xcc0250(_0x5dcb9b,_0x5413b3||{});if(!_0x527ecb)return null;return{'code':_0x527ecb[_0x10d42b(0x25b)],'message':_0x4dad28(_0x527ecb[_0x10d42b(0x422)])?_0x10d42b(0x538)+_0x4dad28(_0x527ecb[_0x10d42b(0x422)]):_0x10d42b(0x1a5),'details':_0x527ecb['errors']};}async[_0x398641(0x50a)](_0x2dce10){const _0x30584f=_0x398641;if(_0x2dce10[_0x30584f(0xdf)]===_0x30584f(0x43f)){const _0xb0bf7f=this['_bestMatch'](_0x30584f(0x43f),_0x2dce10[_0x30584f(0x4c5)],{'corsOnly':!![]});if(_0xb0bf7f)return{'status':0xcc,'headers':_0xa37337(_0x2dce10[_0x30584f(0x165)],_0xb0bf7f[_0x30584f(0xc9)]['cors'],_0xb0bf7f['method'])||{}};}const _0x382430=this[_0x30584f(0x47d)](_0x2dce10[_0x30584f(0xdf)],_0x2dce10['path']);if(_0x382430){const _0x4b0712=_0x382430[_0x30584f(0x3a1)][_0x30584f(0x42f)]['exec'](_0x2dce10[_0x30584f(0x4c5)]),_0x5cb0d7={};_0x382430[_0x30584f(0x3a1)]['keys']['forEach']((_0x164932,_0x4eab89)=>{const _0x51e336=_0x30584f,_0x3fd9dc=_0x4b0712[_0x4eab89+0x1];_0x5cb0d7[_0x164932]=_0x3fd9dc?decodeURIComponent(_0x3fd9dc):_0x382430[_0x51e336(0x3a1)][_0x51e336(0x10f)][_0x164932]??undefined;}),_0x2dce10[_0x30584f(0x275)]=_0x5cb0d7;try{const _0x2b4c95=await _0x382430[_0x30584f(0x4ee)]({'params':_0x5cb0d7,'body':_0x2dce10[_0x30584f(0x4fc)],'query':_0x2dce10[_0x30584f(0x684)],'headers':_0x2dce10['headers'],'context':_0x2dce10[_0x30584f(0xb3)]}),_0x560e7f=_0x5b9500(_0x2b4c95),_0x7f6642=_0xa37337(_0x2dce10[_0x30584f(0x165)],_0x382430[_0x30584f(0xc9)]?.[_0x30584f(0x198)],_0x382430[_0x30584f(0xdf)]);if(!_0x7f6642)return _0x560e7f;return{..._0x560e7f,'headers':{..._0x560e7f['headers']||{},..._0x7f6642}};}catch(_0x11b2c1){const _0x20c79b=_0x11b2c1?.['status']||_0x544ce8[_0x11b2c1?.[_0x30584f(0x25b)]]||0x1f4;return{'status':_0x20c79b,'body':{'error':_0x11b2c1[_0x30584f(0x5e6)]||_0x30584f(0x319),'code':_0x11b2c1?.[_0x30584f(0x25b)]||_0x341cf6[_0x20c79b]||_0x30584f(0x296)+_0x20c79b,'message':_0x11b2c1?.[_0x30584f(0x5e6)]||_0x30584f(0x319),..._0x11b2c1?.['details']!=null?{'details':_0x11b2c1[_0x30584f(0x2a6)]}:{}}};}}return{'status':0x194,'body':{'error':_0x30584f(0x6e1)}};}[_0x398641(0x289)](_0x203825,_0x43a70e={}){const _0x3fbb61=_0x398641;if(typeof _0x43a70e===_0x3fbb61(0xe7)||Array[_0x3fbb61(0x339)](_0x43a70e))_0x43a70e={'host':_0x43a70e};_0x43a70e=_0x43a70e??{};const _0x37b2d2=Number(_0x43a70e[_0x3fbb61(0x150)])||0x0;if(_0x37b2d2>=0x1||_0x43a70e[_0x3fbb61(0x5a2)]!=null||_0x43a70e[_0x3fbb61(0x686)]!=null){const _0x59fde4=new Error('http.listen({workers/makeOkdb/primaryOkdb})\x20is\x20no\x20longer\x20supported\x20in\x20the\x20'+_0x3fbb61(0x2a1)+'CLI\x20(`okdb\x20listen`),\x20or\x20use\x20Node\x27s\x20built-in\x20`cluster`\x20module\x20and\x20call\x20'+_0x3fbb61(0x519));_0x59fde4['code']=_0x3fbb61(0x8c);throw _0x59fde4;}if(this[_0x3fbb61(0x33d)])throw new Error('HTTP\x20server\x20already\x20running');const _0x10269b=_0x43a70e['host']==null?[undefined]:[][_0x3fbb61(0x123)](_0x43a70e[_0x3fbb61(0x41a)]);if(!_0x10269b['length']||_0x10269b[_0x3fbb61(0x35c)](_0x201245=>_0x201245!==undefined&&(typeof _0x201245!=='string'||!_0x201245))){const _0x3deeab=new Error('http.listen:\x20host\x20must\x20be\x20a\x20non-empty\x20string\x20or\x20an\x20array\x20of\x20them');_0x3deeab[_0x3fbb61(0x25b)]=_0x3fbb61(0x173);throw _0x3deeab;}_0x203825&&this[_0x3fbb61(0x8a)][_0x3fbb61(0x394)]==='okdb_session'&&(this[_0x3fbb61(0x8a)][_0x3fbb61(0x394)]='okdb_session_'+_0x203825,this[_0x3fbb61(0x7d)]?.['auth']&&(this[_0x3fbb61(0x7d)]['auth'][_0x3fbb61(0x703)]=this[_0x3fbb61(0x8a)][_0x3fbb61(0x394)]));const _0x10c66d=this[_0x3fbb61(0x7d)]?.[_0x3fbb61(0x518)]?.['debug']?.[_0x3fbb61(0x688)]??![],_0xd17da1=async(_0x276d09,_0x2fb16)=>{const _0x3ada12=_0x3fbb61,_0x402a80=Date[_0x3ada12(0x127)]();if(_0x10c66d){const _0x4e3ea4=_0x276d09[_0x3ada12(0x62d)]||'/',_0x1b7872=_0x276d09[_0x3ada12(0x165)]?.[_0x3ada12(0x6e9)]?_0x276d09[_0x3ada12(0x165)][_0x3ada12(0x6e9)][_0x3ada12(0x416)](/^Bearer\s+(\S{0,8})\S*/i,'Bearer\x20$1…'):'-',_0x5bca76=_0x276d09[_0x3ada12(0x165)]?.[_0x3ada12(0x3c8)]||'-',_0x2b7295=_0x276d09['headers']?.[_0x3ada12(0x451)]||_0x276d09['headers']?.[_0x3ada12(0x3fb)]||'-',_0x66d03e=_0x276d09[_0x3ada12(0x165)]?.[_0x3ada12(0x633)]||'-';process[_0x3ada12(0x11c)][_0x3ada12(0xb6)](_0x3ada12(0x555)+_0x276d09[_0x3ada12(0xdf)]['padEnd'](0x7)+'\x20'+_0x4e3ea4[_0x3ada12(0x485)](0x2d)+'\x20'+(_0x3ada12(0x5af)+_0x1b7872+_0x3ada12(0x111)+_0x66d03e+_0x3ada12(0x455)+_0x5bca76+'\x20cf-ip='+_0x2b7295+'\x0a'));}try{const _0x4612d2=new _0x1d8af8(_0x276d09['url'],_0x3ada12(0x340)+_0x276d09[_0x3ada12(0x165)][_0x3ada12(0x41a)]),_0x1bd0a6=this[_0x3ada12(0x4a4)](_0x276d09['method'],_0x4612d2[_0x3ada12(0x22c)]),_0x13290e=_0x1bd0a6?.[_0x3ada12(0xc9)]?.[_0x3ada12(0x349)]===!![];if(_0x13290e){const _0x9f1d3d=_0x276d09['headers']?.[_0x3ada12(0x3b7)];if(_0x9f1d3d!=null){const _0x41cb74=Number(_0x9f1d3d);if(Number['isFinite'](_0x41cb74)&&_0x41cb74>this[_0x3ada12(0xc4)]){_0x2fb16[_0x3ada12(0x3e6)]=0x19d,_0x2fb16['end'](_0x3ada12(0x33f));return;}}}const _0x52a9c8=_0x13290e?null:await _0xcf7450(_0x276d09,this[_0x3ada12(0xc4)]),_0x5c6f1c=_0x13290e?_0x251ad8(_0x276d09,this[_0x3ada12(0xc4)]):undefined,_0x5aecaf=await this[_0x3ada12(0x20e)](_0x276d09['method'],_0x4612d2[_0x3ada12(0x22c)],{'body':_0x52a9c8,'query':Object[_0x3ada12(0x66e)](_0x4612d2[_0x3ada12(0x15d)][_0x3ada12(0x61d)]()),'headers':_0x276d09[_0x3ada12(0x165)]},{'req':_0x276d09,'res':_0x2fb16,'rawStream':_0x5c6f1c}),_0x5511be=this[_0x3ada12(0x4a4)](_0x276d09[_0x3ada12(0xdf)],_0x4612d2['pathname']),_0x43f45e=Date['now']()-_0x402a80,_0x143e10=this[_0x3ada12(0x2b2)](_0x5511be,_0x5aecaf)?this['_wrapApiResponse'](_0x5aecaf,_0x43f45e):_0x5b9500(_0x5aecaf),_0x5b1c67=(_0x143e10[_0x3ada12(0x170)]||0xc8)>=0x190;this['metrics']['record'](_0x276d09[_0x3ada12(0xdf)],_0x43f45e,_0x5b1c67),_0xcdda3e(_0x2fb16,_0x143e10);if(_0x10c66d){const _0x428d0f=_0x143e10[_0x3ada12(0x170)]||0xc8,_0x4d6624=Date['now']()-_0x402a80;process[_0x3ada12(0x11c)][_0x3ada12(0xb6)](_0x3ada12(0x374)+_0x276d09['method'][_0x3ada12(0x485)](0x7)+'\x20'+_0x4612d2[_0x3ada12(0x22c)][_0x3ada12(0x485)](0x2d)+'\x20'+_0x428d0f+'\x20\x20'+_0x4d6624+_0x3ada12(0x61a));}}catch(_0x27b522){const _0x43765a=Date[_0x3ada12(0x127)]()-_0x402a80;this[_0x3ada12(0x6b2)]['record'](_0x276d09[_0x3ada12(0xdf)],_0x43765a,!![]);const _0x4dcec8=_0x27b522?.[_0x3ada12(0x170)]||0x1f4;_0x2fb16[_0x3ada12(0x3e6)]=_0x4dcec8,_0x4dcec8===0x19d?_0x2fb16['end'](_0x3ada12(0x33f)):_0x2fb16['end'](_0x27b522[_0x3ada12(0x5e6)]||_0x3ada12(0x319));}};this[_0x3fbb61(0x63b)]=_0x10269b[_0x3fbb61(0x757)](_0x18bc0d=>{const _0x1f2859=_0x3fbb61,_0x5c06eb=_0x1a5019[_0x1f2859(0x685)](_0xd17da1);_0x5c06eb['on'](_0x1f2859(0x504),_0x507f3c=>{const _0x187a5e=_0x1f2859;this['_sockets'][_0x187a5e(0x3e9)](_0x507f3c),_0x507f3c['on'](_0x187a5e(0x44f),()=>this['_sockets'][_0x187a5e(0x95)](_0x507f3c));});if(_0x18bc0d===undefined)_0x5c06eb[_0x1f2859(0x289)](_0x203825);else _0x5c06eb[_0x1f2859(0x289)](_0x203825,_0x18bc0d);return _0x5c06eb;}),this[_0x3fbb61(0x33d)]=this[_0x3fbb61(0x63b)][0x0];for(const _0x3cc1e1 of this[_0x3fbb61(0x63b)]['slice'](0x1))_0x3cc1e1['on'](_0x3fbb61(0x492),_0x38a335=>this['server']?.[_0x3fbb61(0x25c)](_0x3fbb61(0x492),_0x38a335));const _0xcb85fa=_0x138376(_0x203825,_0x43a70e[_0x3fbb61(0x41a)]),_0x28b61d=this[_0x3fbb61(0x7d)];return _0x28b61d?.[_0x3fbb61(0x5c9)]&&(_0x28b61d[_0x3fbb61(0x5c9)][_0x3fbb61(0x316)](_0xcb85fa),require$$1$1['isWorker']?_0x28b61d[_0x3fbb61(0x318)]?.({'kind':'http-server'})[_0x3fbb61(0x618)](()=>{}):_0x28b61d[_0x3fbb61(0x3fd)]?.({'kind':_0x3fbb61(0x50c),'listenAddr':_0xcb85fa})[_0x3fbb61(0x618)](()=>{})),this[_0x3fbb61(0x33d)];}async[_0x398641(0x44f)](_0xea6a2b={}){const _0x536255=_0x398641,_0x201ab7=this[_0x536255(0x33d)];this[_0x536255(0x33d)]=null;const _0x204de3=this['servers']['includes'](_0x201ab7)?this['servers']:_0x201ab7?[_0x201ab7]:[];this['servers']=[];if(_0x201ab7&&_0x201ab7[_0x536255(0xe8)]){try{await _0x201ab7[_0x536255(0x44f)]();}catch{}this['metrics']&&this['metrics']['close']();return;}if(_0x204de3[_0x536255(0x39d)]){const _0x17dcc3=Number[_0x536255(0x3ff)](_0xea6a2b[_0x536255(0x27a)])?Math['max'](0x0,_0xea6a2b[_0x536255(0x27a)]):0x3e8,_0x2fbc55=_0x2b7569=>new Promise(_0x412a91=>{const _0x230f73=_0x536255;let _0x1d58f5=![],_0x3f1030=null,_0x3e5e00=null;const _0x542ad3=()=>{if(_0x1d58f5)return;_0x1d58f5=!![];if(_0x3f1030)clearTimeout(_0x3f1030);if(_0x3e5e00)clearTimeout(_0x3e5e00);_0x412a91();};try{_0x2b7569[_0x230f73(0x44f)](_0x542ad3);}catch{_0x542ad3();return;}try{_0x2b7569[_0x230f73(0x2f0)]?.();}catch{}_0x3f1030=setTimeout(()=>{const _0x2fb7b0=_0x230f73;try{_0x2b7569[_0x2fb7b0(0x747)]?.();}catch{}for(const _0xce39d5 of this[_0x2fb7b0(0x6d0)]){try{_0xce39d5[_0x2fb7b0(0x565)]();}catch{}}_0x3e5e00=setTimeout(_0x542ad3,0x64),_0x3e5e00['unref']?.();},_0x17dcc3),_0x3f1030[_0x230f73(0xe9)]?.();});await Promise[_0x536255(0x438)](_0x204de3[_0x536255(0x757)](_0x2fbc55));}this[_0x536255(0x6b2)]&&this[_0x536255(0x6b2)][_0x536255(0x44f)]();}['signCookie'](_0x269bf7,_0x1e29c2,_0x46b622=0x36ee80){const _0x409313=_0x398641,_0x2d0953=Date[_0x409313(0x127)](),_0x856995=Buffer[_0x409313(0x690)](JSON[_0x409313(0x5c1)]({'iat':_0x2d0953,'exp':_0x2d0953+_0x46b622,..._0x269bf7}))[_0x409313(0x240)](_0x409313(0x1bf)),_0x15a223=_0x4ed188(_0x856995,_0x1e29c2);return _0x856995+'.'+_0x15a223;}['formatCookie'](_0x35ce90,_0x4e39e9={}){const _0x1717ff=_0x398641,{httpOnly:httpOnly=!![],sameSite:sameSite=_0x1717ff(0x14c),path:path='/',secure:secure=![],maxAge:maxAge=null,expires:expires=null}=_0x4e39e9;let _0x237b42=this[_0x1717ff(0x8a)][_0x1717ff(0x394)]+'='+_0x35ce90;if(httpOnly)_0x237b42+=_0x1717ff(0x4f3);if(sameSite)_0x237b42+=';\x20SameSite='+sameSite;if(path)_0x237b42+=_0x1717ff(0x55c)+path;if(secure)_0x237b42+=_0x1717ff(0x98);if(Number[_0x1717ff(0x3ff)](maxAge))_0x237b42+=_0x1717ff(0x2fb)+Math[_0x1717ff(0x68c)](0x0,Math[_0x1717ff(0x5e9)](maxAge));if(expires instanceof Date)_0x237b42+=_0x1717ff(0x18e)+expires[_0x1717ff(0x52a)]();return _0x237b42;}[_0x398641(0x462)](_0x4d15ae=this[_0x398641(0x8a)][_0x398641(0x394)],_0x39b3ea={}){const _0x579765=_0x398641,{path:path='/',sameSite:sameSite=_0x579765(0x14c),secure:secure=![],httpOnly:httpOnly=!![]}=_0x39b3ea;let _0x43243a=_0x4d15ae+'=';if(httpOnly)_0x43243a+=_0x579765(0x4f3);if(sameSite)_0x43243a+=';\x20SameSite='+sameSite;if(path)_0x43243a+=_0x579765(0x55c)+path;if(secure)_0x43243a+=_0x579765(0x98);return _0x43243a+=_0x579765(0x3c9),_0x43243a;}[_0x398641(0x294)](_0x3e1a00,_0x448807){const _0x454182=_0x398641;if(!_0x3e1a00)return null;const [_0x5cdd49,_0x258608]=String(_0x3e1a00)[_0x454182(0x2aa)]('.');if(!_0x5cdd49||!_0x258608)return null;const _0x1d84b5=_0x4ed188(_0x5cdd49,_0x448807);if(!_0x218fe9(_0x258608,_0x1d84b5))return null;try{const _0x44aec5=JSON['parse'](Buffer[_0x454182(0x690)](_0x5cdd49,_0x454182(0x1bf))[_0x454182(0x240)]());if(_0x44aec5[_0x454182(0x69e)]<=Date[_0x454182(0x127)]())return null;return _0x44aec5;}catch{return null;}}['parseBearer'](_0x3eabe2){const _0x399e24=_0x398641;if(this[_0x399e24(0x7d)]?.['auth'])return this[_0x399e24(0x7d)]['auth'][_0x399e24(0x51d)](_0x3eabe2);return _0x270045(_0x3eabe2);}[_0x398641(0x2e7)](_0x38653e){const _0x1b552f=_0x398641;if(this[_0x1b552f(0x7d)]?.[_0x1b552f(0x8a)])return this[_0x1b552f(0x7d)]['auth'][_0x1b552f(0x2e7)](_0x38653e);const _0x2c0e16=this[_0x1b552f(0x2c0)]?.[_0x1b552f(0x4b5)]??0x36ee80,_0x3cf921=this[_0x1b552f(0x2c0)]?.[_0x1b552f(0x74d)];return _0x4ee366(_0x38653e,_0x3cf921,_0x2c0e16);}[_0x398641(0x191)](_0x1e37e9){const _0x17a805=_0x398641;if(this['_okdb']?.[_0x17a805(0x8a)])return this[_0x17a805(0x7d)][_0x17a805(0x8a)][_0x17a805(0x191)](_0x1e37e9);const _0x3d0014=this[_0x17a805(0x2c0)]?.[_0x17a805(0x74d)];return _0x3ac6d1(_0x1e37e9,_0x3d0014);}async['authenticateRequest'](_0x327f27){const _0x21bf40=_0x398641;if(this[_0x21bf40(0x7d)]?.[_0x21bf40(0x8a)])return this[_0x21bf40(0x7d)][_0x21bf40(0x8a)][_0x21bf40(0xf1)](_0x327f27);if(_0x327f27['context']?.[_0x21bf40(0x1db)]===!![]||this[_0x21bf40(0x376)]===_0x21bf40(0x1fd))return{'id':_0x21bf40(0x619),'username':_0x21bf40(0x619),'roles':[_0x21bf40(0x270)],'isAuthenticated':!![],'isSystem':!![],'user':{'id':_0x21bf40(0x619),'username':_0x21bf40(0x619),'roles':['admin'],'isAuthenticated':!![],'isSystem':!![]}};const _0x2a05b7=this[_0x21bf40(0x51d)](_0x327f27[_0x21bf40(0x165)]?.[_0x21bf40(0x6e9)]),_0x4a94cf=_0x327f27[_0x21bf40(0x28c)]?.[this[_0x21bf40(0x8a)][_0x21bf40(0x394)]],_0x225577=_0x2a05b7||_0x4a94cf;if(!_0x225577)return{'isAuthenticated':![],'isSystem':![],'user':null};const _0x15dbb0=this[_0x21bf40(0x191)](_0x225577);if(!_0x15dbb0)return{'isAuthenticated':![],'isSystem':![],'user':null};const _0x30e168={'id':_0x15dbb0[_0x21bf40(0x172)]??null,'username':_0x15dbb0['username']??null,'roles':Array[_0x21bf40(0x339)](_0x15dbb0[_0x21bf40(0x733)])?_0x15dbb0['roles']:[],'isAuthenticated':!![],'isSystem':![]};return{'id':_0x30e168['id'],'username':_0x30e168[_0x21bf40(0x573)],'roles':_0x30e168[_0x21bf40(0x733)],'isAuthenticated':!![],'isSystem':![],'user':_0x30e168,'claims':_0x15dbb0,'subject':_0x30e168['id']};}async[_0x398641(0x67)](_0x5438a4,_0x2e4be8={}){const _0x2bb927=_0x398641,_0x163bb2=_0x4ba030(_0x5438a4),_0x3bd29d=Array[_0x2bb927(0x339)](_0x2e4be8[_0x2bb927(0x59a)])&&_0x2e4be8[_0x2bb927(0x59a)][_0x2bb927(0x39d)]>0x0?_0x2e4be8[_0x2bb927(0x59a)]:[_0x2bb927(0xdb),'ES256'],_0x2d8e2a=_0x163bb2[_0x2bb927(0x632)]?.[_0x2bb927(0x2b3)];if(!_0x3bd29d[_0x2bb927(0x8f)](_0x2d8e2a))throw new Error(_0x2bb927(0x336)+_0x2d8e2a);if(!_0x163bb2[_0x2bb927(0x632)]?.[_0x2bb927(0x4ff)])throw new Error(_0x2bb927(0x6cf));const _0x226f2b=await this['_getOidcDiscovery'](_0x2e4be8);if(!_0x226f2b?.[_0x2bb927(0x715)])throw new Error('OIDC\x20discovery\x20missing\x20jwks_uri');const _0x4d00c7=await this['_getJwkKey'](_0x226f2b['jwks_uri'],_0x163bb2[_0x2bb927(0x632)][_0x2bb927(0x4ff)],_0x2e4be8);if(!_0x2be05e(_0x2d8e2a,_0x4d00c7,_0x163bb2[_0x2bb927(0x227)],_0x163bb2[_0x2bb927(0x37f)]))throw new Error('JWT\x20signature\x20verification\x20failed');const _0x3cce62=Math[_0x2bb927(0x5e9)](Date[_0x2bb927(0x127)]()/0x3e8),_0xbf4ecd=_0x163bb2[_0x2bb927(0x4ec)]||{};if(_0xbf4ecd['iss']!==_0x226f2b[_0x2bb927(0x5d3)])throw new Error('JWT\x20issuer\x20mismatch');const _0x5b1160=_0x2e4be8[_0x2bb927(0x603)];if(_0x5b1160){const _0x5718ea=_0x21824d(_0xbf4ecd['aud']);if(!_0x5718ea[_0x2bb927(0x8f)](_0x5b1160))throw new Error(_0x2bb927(0x44b));}if(typeof _0xbf4ecd[_0x2bb927(0x69e)]!=='number'||_0xbf4ecd['exp']<=_0x3cce62)throw new Error(_0x2bb927(0x207));if(_0xbf4ecd[_0x2bb927(0x6bb)]!=null&&_0xbf4ecd[_0x2bb927(0x6bb)]>_0x3cce62)throw new Error(_0x2bb927(0x37b));if(_0xbf4ecd[_0x2bb927(0x634)]==='id')throw new Error('ID\x20token\x20is\x20not\x20accepted');return{'subject':_0xbf4ecd[_0x2bb927(0x172)]??null,'email':_0xbf4ecd[_0x2bb927(0x142)]??null,'scopes':typeof _0xbf4ecd[_0x2bb927(0x498)]===_0x2bb927(0xe7)?_0xbf4ecd[_0x2bb927(0x498)][_0x2bb927(0x2aa)](/\s+/)[_0x2bb927(0x293)](Boolean):[],'claims':_0xbf4ecd,'tokenType':_0x2bb927(0x2af)};}async[_0x398641(0x4f7)](_0x10d718={}){const _0x1f00cf=_0x398641,_0x40138a=String(_0x10d718[_0x1f00cf(0x5d3)]||'')[_0x1f00cf(0x416)](/\/+$/,'');if(!_0x40138a)return null;const _0x4d007c=Number[_0x1f00cf(0x3ff)](_0x10d718['discoveryTtlMs'])?_0x10d718[_0x1f00cf(0x700)]:0xa*0x3c*0x3e8;if(this[_0x1f00cf(0x1bc)]?.['issuer']===_0x40138a&&this[_0x1f00cf(0x1bc)][_0x1f00cf(0x57a)]>Date[_0x1f00cf(0x127)]())return this[_0x1f00cf(0x1bc)][_0x1f00cf(0x101)];const _0x1b1c80=await _0xfc123b(_0x40138a+_0x1f00cf(0x479)),_0x36e488={'issuer':_0x1b1c80[_0x1f00cf(0x5d3)]||_0x40138a,'authorization_endpoint':_0x10d718[_0x1f00cf(0x41f)]||_0x1b1c80[_0x1f00cf(0x717)],'token_endpoint':_0x10d718[_0x1f00cf(0x19f)]||_0x1b1c80[_0x1f00cf(0x2f1)],'jwks_uri':_0x10d718['jwksUri']||_0x1b1c80['jwks_uri']};return this[_0x1f00cf(0x1bc)]={'issuer':_0x40138a,'value':_0x36e488,'expiresAt':Date[_0x1f00cf(0x127)]()+_0x4d007c},_0x36e488;}async[_0x398641(0x2c5)](_0x2357d9,_0x3bdb83=0x5*0x3c*0x3e8){const _0x96b216=_0x398641,_0x6fb24e=await _0xfc123b(_0x2357d9),_0x233fb5=new Map();for(const _0x3d9f54 of _0x6fb24e[_0x96b216(0x6d8)]||[]){if(!_0x3d9f54?.['kid'])continue;_0x233fb5[_0x96b216(0x49d)](_0x3d9f54['kid'],_0x399aec(_0x3d9f54));}return this[_0x96b216(0x69b)]={'uri':_0x2357d9,'keys':_0x233fb5,'expiresAt':Date['now']()+_0x3bdb83},this[_0x96b216(0x69b)];}async['_getJwkKey'](_0x5d1750,_0x203dc9,_0x30a88a={}){const _0x4d8ab6=_0x398641,_0x3daa7d=Number['isFinite'](_0x30a88a[_0x4d8ab6(0x4e5)])?_0x30a88a[_0x4d8ab6(0x4e5)]:0x5*0x3c*0x3e8,_0x461c04=0x1e*0x3e8,_0xcf7bbf=this[_0x4d8ab6(0x12b)]['get'](_0x203dc9);if(_0xcf7bbf!==undefined&&_0xcf7bbf>Date[_0x4d8ab6(0x127)]())throw new Error('Unknown\x20JWKS\x20kid:\x20'+_0x203dc9);(!this[_0x4d8ab6(0x69b)]||this['_jwksCache'][_0x4d8ab6(0x661)]!==_0x5d1750||this['_jwksCache'][_0x4d8ab6(0x57a)]<=Date[_0x4d8ab6(0x127)]())&&await this[_0x4d8ab6(0x2c5)](_0x5d1750,_0x3daa7d);let _0xdef50=this['_jwksCache']?.[_0x4d8ab6(0x6d8)]?.[_0x4d8ab6(0x6a)](_0x203dc9);if(_0xdef50)return _0xdef50;await this[_0x4d8ab6(0x2c5)](_0x5d1750,_0x3daa7d),_0xdef50=this[_0x4d8ab6(0x69b)]?.['keys']?.[_0x4d8ab6(0x6a)](_0x203dc9);if(!_0xdef50){this[_0x4d8ab6(0x12b)][_0x4d8ab6(0x49d)](_0x203dc9,Date['now']()+_0x461c04);throw new Error('Unknown\x20JWKS\x20kid:\x20'+_0x203dc9);}return _0xdef50;}[_0x398641(0x283)](_0x3a1bd0){const _0x2e61fb=_0x398641;if(this[_0x2e61fb(0x7d)]?.[_0x2e61fb(0x8a)])return this[_0x2e61fb(0x7d)][_0x2e61fb(0x8a)]['_normalizeOAuthAuthResult'](_0x3a1bd0);const _0x6f24b4=_0x3a1bd0?.[_0x2e61fb(0x302)]||{},_0x4a6183={'sub':_0x3a1bd0?.['subject']??_0x6f24b4[_0x2e61fb(0x172)]??null,'email':_0x3a1bd0?.[_0x2e61fb(0x142)]??_0x6f24b4[_0x2e61fb(0x142)]??null,'name':_0x3a1bd0?.[_0x2e61fb(0x707)]??_0x6f24b4['name']??_0x6f24b4[_0x2e61fb(0x277)]??null,'groups':_0x3a1bd0?.[_0x2e61fb(0x237)]??_0x6f24b4[_0x2e61fb(0x237)]??[],'roles':_0x3a1bd0?.['roles']??_0x6f24b4['roles']??[]};return{'type':_0x2e61fb(0x75e),'tokenType':_0x3a1bd0?.['tokenType']??_0x2e61fb(0x2af),'subject':_0x4a6183[_0x2e61fb(0x172)],'email':_0x4a6183[_0x2e61fb(0x142)],'scopes':_0x3a1bd0?.[_0x2e61fb(0x588)]??_0x6f24b4[_0x2e61fb(0x498)]?.['split']?.('\x20')?.[_0x2e61fb(0x293)](Boolean)??[],'claims':_0x6f24b4,'user':_0x4a6183,'isAuthenticated':!![]};}['createLoginState'](_0x80be6c={},_0x5c3313=0x927c0){const _0x2a0d5b=_0x398641;if(this['_okdb']?.[_0x2a0d5b(0x8a)])return this[_0x2a0d5b(0x7d)]['auth']['createLoginState'](_0x80be6c,_0x5c3313);const _0x2125e3=_0x392ef6(0x18);this[_0x2a0d5b(0x6da)]['set'](_0x2125e3,{..._0x80be6c,'exp':Date[_0x2a0d5b(0x127)]()+_0x5c3313});if(this['_loginStates']['size']%0x32===0x0){const _0x5955d7=Date[_0x2a0d5b(0x127)]();for(const [_0x284104,_0x432d40]of this['_loginStates']){if(_0x432d40[_0x2a0d5b(0x69e)]<=_0x5955d7)this[_0x2a0d5b(0x6da)][_0x2a0d5b(0x95)](_0x284104);}}return _0x2125e3;}[_0x398641(0x5a5)](_0x3ecde0){const _0x2177ae=_0x398641;if(this[_0x2177ae(0x7d)]?.[_0x2177ae(0x8a)])return this[_0x2177ae(0x7d)][_0x2177ae(0x8a)]['consumeLoginState'](_0x3ecde0);if(!_0x3ecde0)return null;const _0x2a581d=this['_loginStates'][_0x2177ae(0x6a)](_0x3ecde0);this['_loginStates'][_0x2177ae(0x95)](_0x3ecde0);if(!_0x2a581d)return null;if(_0x2a581d[_0x2177ae(0x69e)]<=Date['now']())return null;return _0x2a581d;}}function _0x5b9500(_0x856313){const _0xfcbb4d=_0x398641;if(_0x856313==null)return{'status':0xcc};if(Buffer[_0xfcbb4d(0x365)](_0x856313)||_0x8fc7b4(_0x856313))return{'status':0xc8,'body':_0x856313};if(typeof _0x856313===_0xfcbb4d(0x5d4)&&_0xfcbb4d(0x170)in _0x856313){if(!('body'in _0x856313)&&!_0x8fc7b4(_0x856313[_0xfcbb4d(0x4fc)])){const {status:_0x4d67d0,headers:_0x38a27f,..._0x3bc078}=_0x856313;if(Object[_0xfcbb4d(0x6d8)](_0x3bc078)['length']>0x0)return{'status':_0x4d67d0,'headers':_0x38a27f,'body':_0x3bc078};}return _0x856313;}return{'status':0xc8,'body':_0x856313};}function _0x8fc7b4(_0x4b26e2){const _0x41cbeb=_0x398641;return _0x4b26e2&&typeof _0x4b26e2[_0x41cbeb(0x199)]===_0x41cbeb(0x372);}function _0x251ad8(_0x557298,_0x522ec4){const _0x5e06e6=_0x398641,{PassThrough:_0xbb0669}=require$$5;let _0x474724=0x0,_0x92b83b=![];const _0x2af554=new _0xbb0669();return _0x557298['on'](_0x5e06e6(0x32e),_0x55bd8e=>{const _0x58c03e=_0x5e06e6;if(_0x92b83b)return;_0x474724+=_0x55bd8e['length'];if(_0x474724>_0x522ec4){_0x92b83b=!![];const _0x247547=new Error(_0x58c03e(0x33f));_0x247547[_0x58c03e(0x170)]=0x19d,_0x2af554[_0x58c03e(0x565)](_0x247547);return;}if(!_0x2af554[_0x58c03e(0x87)])_0x2af554['push'](_0x55bd8e);}),_0x557298['on']('end',()=>{const _0x53f3e7=_0x5e06e6;!_0x92b83b&&!_0x2af554[_0x53f3e7(0x87)]&&(_0x92b83b=!![],_0x2af554['end']());}),_0x557298['on']('error',_0x4c8fd2=>{const _0xe01aa9=_0x5e06e6;if(!_0x2af554[_0xe01aa9(0x87)])_0x2af554[_0xe01aa9(0x565)](_0x4c8fd2);}),_0x557298['pause'](),_0x2af554['on'](_0x5e06e6(0x2a4),()=>{const _0x54bae3=_0x5e06e6;if(!_0x2af554[_0x54bae3(0x87)])_0x557298[_0x54bae3(0x2a4)]();}),_0x2af554;}function _0xcf7450(_0x1e91dd,_0xc2f626){const _0x2a9f7f=_0x398641;if(_0x1e91dd[_0x2a9f7f(0xdf)]==='GET'||_0x1e91dd[_0x2a9f7f(0xdf)]===_0x2a9f7f(0x481))return null;const _0x45dada=_0x1e91dd[_0x2a9f7f(0x165)]?.[_0x2a9f7f(0x3b7)];if(_0x45dada!=null){const _0x4cbf2c=Number(_0x45dada);if(Number[_0x2a9f7f(0x3ff)](_0x4cbf2c)&&_0x4cbf2c>_0xc2f626){const _0x1c4638=new Error('Payload\x20too\x20large');_0x1c4638[_0x2a9f7f(0x170)]=0x19d;throw _0x1c4638;}}return new Promise((_0x2e6cf0,_0x17696d)=>{const _0x4a67be=_0x2a9f7f;let _0x10eeff='',_0x4a6e51=0x0;_0x1e91dd['on'](_0x4a67be(0x32e),_0x522c3e=>{const _0x310cca=_0x4a67be;_0x4a6e51+=_0x522c3e[_0x310cca(0x39d)];if(_0x4a6e51>_0xc2f626){try{_0x1e91dd[_0x310cca(0x565)]();}catch{}const _0x1bd5ba=new Error(_0x310cca(0x33f));_0x1bd5ba[_0x310cca(0x170)]=0x19d,_0x17696d(_0x1bd5ba);return;}_0x10eeff+=_0x522c3e;}),_0x1e91dd['on'](_0x4a67be(0xe5),()=>{const _0x5759c1=_0x4a67be;if(!_0x10eeff)return _0x2e6cf0(null);const _0x57a5fe=_0x1e91dd[_0x5759c1(0x165)]?.[_0x5759c1(0x233)]||'';if(_0x57a5fe[_0x5759c1(0x8f)](_0x5759c1(0xa9))){const _0x40e8f0={};for(const [_0xc09d57,_0x4ab9f3]of new URLSearchParams(_0x10eeff))_0x40e8f0[_0xc09d57]=_0x4ab9f3;return _0x2e6cf0(_0x40e8f0);}try{_0x2e6cf0(JSON['parse'](_0x10eeff));}catch(_0x3ca01d){_0x17696d(_0x3ca01d);}}),_0x1e91dd['on']('error',_0x17696d);});}function _0xcdda3e(_0x4ea726,_0x37ae9b){const _0x467c67=_0x398641,{status:status=0xc8,headers:headers={},body:_0x50dd36}=_0x37ae9b;_0x4ea726[_0x467c67(0x3e6)]=status;for(const [_0x1e9acb,_0x5d9a63]of Object['entries'](headers)){_0x4ea726[_0x467c67(0x635)](_0x1e9acb,_0x5d9a63);}if(_0x50dd36==null){_0x4ea726[_0x467c67(0xe5)]();return;}if(_0x8fc7b4(_0x50dd36)){_0x50dd36[_0x467c67(0x199)](_0x4ea726);return;}if(Buffer[_0x467c67(0x365)](_0x50dd36)){_0x4ea726['end'](_0x50dd36);return;}if(typeof _0x50dd36===_0x467c67(0x5d4)){!_0x4ea726['getHeader'](_0x467c67(0x2ce))&&_0x4ea726[_0x467c67(0x635)](_0x467c67(0x2ce),'application/json');_0x4ea726['end'](JSON['stringify'](_0x50dd36));return;}_0x4ea726[_0x467c67(0xe5)](String(_0x50dd36));}function _0x138376(_0x1c6280,_0x91d55e){const _0xedfe9=_0x398641;if(_0x91d55e==null)return':'+_0x1c6280;return[][_0xedfe9(0x123)](_0x91d55e)[_0xedfe9(0x757)](_0x487fa4=>(_0x487fa4[_0xedfe9(0x8f)](':')?'['+_0x487fa4+']':_0x487fa4)+':'+_0x1c6280)[_0xedfe9(0x10b)](',\x20');}return okdbHttp[_0x398641(0x71d)]=_0x1fe4c0,okdbHttp[_0x398641(0x71d)]['formatListenAddr']=_0x138376,okdbHttp[_0x398641(0x71d)][_0x398641(0x605)]=_0x544ce8,okdbHttp[_0x398641(0x71d)];}var okdbShmSegment,hasRequiredOkdbShmSegment;function requireOkdbShmSegment(){const _0x199e2d=_0x3d20e4;if(hasRequiredOkdbShmSegment)return okdbShmSegment;hasRequiredOkdbShmSegment=0x1;const _0x59491f=require$$0$1,_0x257a62=require$$2$1,_0x2b0396=0x80,_0x28a4c6=0x0,_0x90f5b2=0x1,_0x2cbaa7=0x2,_0x233eb4=0x3,_0x704d52=0x4,_0x5cfbea=_0x704d52+_0x2b0396,_0x27f174=_0x5cfbea+_0x2b0396,_0x4b5f40=require$$2$3[_0x199e2d(0x540)],_0x494dc5=_0x27f174*0x4,_0x97c722=process[_0x199e2d(0x379)]!==_0x199e2d(0x73f),_0x2b4bc1=0xc,_0x319988=process['platform']===_0x199e2d(0x551)?0x1f:0xa0,_0x592ed9=/^[A-Za-z0-9-]+(?:_boot)?$/,_0x5419c8=/^[A-Za-z0-9-]*-[0-9a-f]{12}(?:_boot)?$/,_0x1bd306=_0x27f013=>_0x27f013[_0x199e2d(0x416)](/[^a-zA-Z0-9]/g,'-');function _0x1563f7(_0x85a546,_0x3bd172=''){const _0x52e0a3=_0x199e2d;if(typeof _0x85a546!==_0x52e0a3(0xe7)||_0x85a546==='')throw new TypeError(_0x52e0a3(0x5e3));if(_0x3bd172!==''&&!/^_[A-Za-z0-9]+$/['test'](_0x3bd172))throw new TypeError('segmentNameFor:\x20suffix\x20must\x20look\x20like\x20\x22_name\x22\x20(got\x20'+JSON['stringify'](_0x3bd172)+')');const _0x24fc98=_0x257a62[_0x52e0a3(0x3cc)](_0x52e0a3(0x647))[_0x52e0a3(0x29f)](_0x85a546)['digest'](_0x52e0a3(0x31b))[_0x52e0a3(0x13a)](0x0,_0x2b4bc1),_0x1bbee9=Math['max'](0x0,_0x319988-0x1-_0x2b4bc1-_0x3bd172[_0x52e0a3(0x39d)]);return _0x1bd306(_0x85a546)[_0x52e0a3(0x13a)](0x0,_0x1bbee9)+'-'+_0x24fc98+_0x3bd172;}function _0x7aa27a(_0x2dceed,_0x5cd874=''){return''+_0x1bd306(_0x2dceed)+_0x5cd874;}function _0x3ee61c(_0x2c5f50){const _0x1712cc=_0x199e2d;if(_0x5419c8[_0x1712cc(0x155)](_0x2c5f50))return _0x1712cc(0x766);if(_0x592ed9[_0x1712cc(0x155)](_0x2c5f50))return'legacy';return null;}const _0x56a07b={'onMapped':null,'onClaimed':null,'onRetiring':null},_0x73b7bb=_0x1dd8cf=>Math[_0x199e2d(0x6c3)](_0x1dd8cf/0x8)*0x8,_0x57274f=_0x37ebd3=>_0x73b7bb(_0x37ebd3)+_0x494dc5;function _0x3e5f3b(_0xf32e26){const _0x56b5af=_0x199e2d;try{return process['kill'](_0xf32e26,0x0),![];}catch(_0x183b19){return _0x183b19[_0x56b5af(0x25b)]==='ESRCH';}}const _0x42c1cc=new Int32Array(new SharedArrayBuffer(0x4));function _0x4ff30f(_0x27029c){if(_0x27029c>0x0)Atomics['wait'](_0x42c1cc,0x0,0x0,_0x27029c);}function _0x3cada9(_0x4a4f60,_0x2ff04c){const _0xad5912=_0x199e2d;if(process['platform']!==_0xad5912(0x4bb))return;let _0x209484;try{_0x209484=_0x59491f[_0xad5912(0xf9)]('/dev/shm/'+_0x4a4f60,'r+');if(_0x59491f[_0xad5912(0xa1)](_0x209484)[_0xad5912(0x35f)]<_0x2ff04c)_0x59491f[_0xad5912(0x659)](_0x209484,_0x2ff04c);}catch{}finally{if(_0x209484!==undefined)try{_0x59491f[_0xad5912(0x443)](_0x209484);}catch{}}}function _0x3d1e18(_0x18f0df,_0x39d55f){const _0x132a4a=_0x199e2d,_0x5df139=require$$3$1;for(let _0x206054=0x0;;_0x206054++){try{return _0x5df139['open'](_0x18f0df,_0x39d55f);}catch(_0xda959e){if(_0x206054>=0x3e8||!/No such file or directory/[_0x132a4a(0x155)](_0xda959e?.[_0x132a4a(0x5e6)]??''))throw _0xda959e;}}}function _0x3d15a4(_0x2c81f8,_0x5b3535){const _0x4a10f6=_0x199e2d,_0x55c269=_0x57274f(_0x5b3535),_0x2c4fb7=_0x3d1e18(_0x2c81f8,_0x55c269);_0x3cada9(_0x2c81f8,_0x55c269);if(_0x2c4fb7[_0x4a10f6(0x32c)]<_0x55c269)throw new Error(_0x4a10f6(0x5bf)+_0x2c81f8+_0x4a10f6(0x5e5)+_0x2c4fb7['byteLength']+_0x4a10f6(0x112)+_0x55c269+_0x4a10f6(0x59c));return{'sab':_0x2c4fb7,'hdr':new Int32Array(_0x2c4fb7,_0x73b7bb(_0x5b3535),_0x27f174)};}function _0x34a7a5(_0x5430c8){const _0x2495e5=_0x199e2d;try{require('shmbuf')[_0x2495e5(0x44f)](_0x5430c8);}catch{}}function _0x31d91d(_0x250fd4){const _0x2ac0f9=_0x199e2d;try{require(_0x2ac0f9(0xcf))[_0x2ac0f9(0x12f)](_0x250fd4);}catch{}}function _0x2ae63d(_0x35f37a){const _0x1c8975=_0x199e2d;if(Atomics[_0x1c8975(0x776)](_0x35f37a,_0x2cbaa7)!==0x0&&Atomics[_0x1c8975(0x776)](_0x35f37a,_0x233eb4)!==0x0)return;const _0x5ac665=_0x257a62['randomBytes'](0x8),_0x3846e2=_0x5ac665[_0x1c8975(0x4e8)](0x0)||0x1,_0x47191b=_0x5ac665[_0x1c8975(0x4e8)](0x4)||0x1;Atomics[_0x1c8975(0x598)](_0x35f37a,_0x2cbaa7,0x0,_0x3846e2),Atomics[_0x1c8975(0x598)](_0x35f37a,_0x233eb4,0x0,_0x47191b);}function _0x1f0b7d(_0x833521){const _0x125ee1=_0x199e2d,_0x1f8445=process['pid'];for(let _0x412b83=0x0;_0x412b83<_0x2b0396;_0x412b83++){const _0x1693a6=Atomics[_0x125ee1(0x776)](_0x833521,_0x704d52+_0x412b83);if(_0x1693a6===0x0||_0x1693a6===_0x1f8445)continue;if(!_0x3e5f3b(_0x1693a6))continue;Atomics[_0x125ee1(0x45d)](_0x833521,_0x5cfbea+_0x412b83,0x0),Atomics['compareExchange'](_0x833521,_0x704d52+_0x412b83,_0x1693a6,0x0);}}function _0x5a5181(_0x8694f6){const _0x53ba02=_0x199e2d;if(Atomics[_0x53ba02(0x776)](_0x8694f6,_0x90f5b2)!==0x0)return!![];for(let _0x1d4f89=0x0;_0x1d4f89<_0x2b0396;_0x1d4f89++)if(Atomics[_0x53ba02(0x776)](_0x8694f6,_0x704d52+_0x1d4f89)!==0x0)return!![];return![];}function _0x42228b(_0x3b78a8){const _0x12cdb7=_0x199e2d,_0x2f1db3=process['pid'];for(let _0x26c1af=0x0;_0x26c1af<0x2;_0x26c1af++){for(let _0x1d47b3=0x0;_0x1d47b3<_0x2b0396;_0x1d47b3++){if(Atomics[_0x12cdb7(0x598)](_0x3b78a8,_0x704d52+_0x1d47b3,0x0,_0x2f1db3)===0x0)return Atomics['store'](_0x3b78a8,_0x5cfbea+_0x1d47b3,_0x4b5f40),_0x1d47b3;}_0x1f0b7d(_0x3b78a8);}return Atomics['add'](_0x3b78a8,_0x90f5b2,0x1),-0x1;}function _0x5d2f63(_0x39632e,_0x40ba75){const _0x3e73fb=_0x199e2d;if(_0x40ba75>=0x0)Atomics[_0x3e73fb(0x45d)](_0x39632e,_0x5cfbea+_0x40ba75,0x0),Atomics[_0x3e73fb(0x598)](_0x39632e,_0x704d52+_0x40ba75,process[_0x3e73fb(0xee)],0x0);else Atomics['sub'](_0x39632e,_0x90f5b2,0x1);}function _0x3767f7(_0x53102c,_0xfaaee3,_0x1fa7c3,_0x47f03a){const _0x4667f8=_0x199e2d,_0x5c33c6=process[_0x4667f8(0xee)];if(Atomics['compareExchange'](_0x1fa7c3,_0x28a4c6,_0x47f03a,_0x5c33c6)!==_0x47f03a)return _0x4667f8(0x2df);const _0x5bd41c=Atomics[_0x4667f8(0x776)](_0x1fa7c3,_0x2cbaa7),_0x5ba5d6=Atomics[_0x4667f8(0x776)](_0x1fa7c3,_0x233eb4);let _0x4d59e0;try{_0x4d59e0=_0x3d15a4(_0x53102c,_0xfaaee3)[_0x4667f8(0x5ee)];}catch{return'orphan';}if(Atomics[_0x4667f8(0x776)](_0x4d59e0,_0x2cbaa7)!==_0x5bd41c||Atomics['load'](_0x4d59e0,_0x233eb4)!==_0x5ba5d6)return'orphan';_0x1f0b7d(_0x1fa7c3);if(_0x5a5181(_0x1fa7c3))return Atomics[_0x4667f8(0x598)](_0x1fa7c3,_0x28a4c6,_0x5c33c6,0x0),_0x4667f8(0x613);return _0x31d91d(_0x53102c),_0x4667f8(0x558);}function _0x53ee8c(_0x1fe8de,_0x5a853d,{timeoutMs:_0x32e878}={}){const _0x344756=_0x199e2d;_0x32e878=_0x32e878??(Number(process.env.OKDB_SHM_ATTACH_TIMEOUT_MS)||0x7530);const _0x63fbe5=process[_0x344756(0xee)],_0x2a6e07=Date[_0x344756(0x127)]()+_0x32e878;for(let _0x4bfbb3=0x0;;_0x4bfbb3++){const {sab:_0x594767,hdr:_0x476705}=_0x3d15a4(_0x1fe8de,_0x5a853d);_0x56a07b[_0x344756(0x5be)]?.(_0x1fe8de,_0x4bfbb3),_0x2ae63d(_0x476705);const _0x2d443c=_0x42228b(_0x476705);_0x56a07b[_0x344756(0x756)]?.(_0x1fe8de,_0x4bfbb3);const _0x9993e3=Atomics[_0x344756(0x776)](_0x476705,_0x28a4c6);if(_0x9993e3===0x0||!_0x97c722){if(_0x4bfbb3===0x0)_0x1f0b7d(_0x476705);return{'sab':_0x594767,'hdr':_0x476705,'slot':_0x2d443c};}_0x5d2f63(_0x476705,_0x2d443c);if(_0x9993e3!==_0x63fbe5&&_0x3e5f3b(_0x9993e3))_0x3767f7(_0x1fe8de,_0x5a853d,_0x476705,_0x9993e3);_0x34a7a5(_0x1fe8de);if(Date['now']()>_0x2a6e07){const {OKDBError:_0x7af30e}=requireOkdbError();throw new _0x7af30e('shared-memory\x20segment\x20\x22'+_0x1fe8de+_0x344756(0x3f3)+_0x32e878+_0x344756(0x6e6)+_0x9993e3+_0x344756(0x450)+_0x344756(0x390),_0x344756(0x25d));}_0x4ff30f(_0x4bfbb3<0x14?0x0:0x1);}}function _0x2655b2(_0x3ed8ad,_0x4d5991,_0x24fd15,_0x5184c5){const _0xa5e8c2=_0x199e2d,{hdr:_0x488dcf,slot:_0x5128cb}=_0x24fd15;if(_0x5128cb!==null)_0x5d2f63(_0x488dcf,_0x5128cb);let _0x1e5061=![];try{if(!_0x97c722)return![];const _0x530e0e=process[_0xa5e8c2(0xee)];_0x1f0b7d(_0x488dcf);if(_0x5a5181(_0x488dcf)||_0x5184c5?.(_0x24fd15[_0xa5e8c2(0x736)]))return![];if(Atomics[_0xa5e8c2(0x598)](_0x488dcf,_0x28a4c6,0x0,_0x530e0e)!==0x0)return![];let _0x317cc6=!![];try{_0x56a07b[_0xa5e8c2(0x436)]?.(_0x3ed8ad),!_0x5a5181(_0x488dcf)&&!_0x5184c5?.(_0x24fd15[_0xa5e8c2(0x736)])&&(_0x317cc6=![],_0x31d91d(_0x3ed8ad),_0x1e5061=!![]);}finally{if(_0x317cc6)Atomics[_0xa5e8c2(0x598)](_0x488dcf,_0x28a4c6,_0x530e0e,0x0);}return _0x1e5061;}finally{_0x34a7a5(_0x3ed8ad);}}function _0x192eb9(_0x1bf12a,_0x38f62a,{isBusy:_0x3eb7fa}={}){const _0x3755e5=_0x199e2d,_0x5232a6=process[_0x3755e5(0xee)],{sab:_0x1e55fb,hdr:_0x497b2d}=_0x3d15a4(_0x1bf12a,_0x38f62a);try{_0x1f0b7d(_0x497b2d);const _0x62a5e8=Atomics[_0x3755e5(0x776)](_0x497b2d,_0x28a4c6);if(_0x62a5e8!==0x0){if(_0x62a5e8===_0x5232a6||!_0x3e5f3b(_0x62a5e8))return _0x3755e5(0x25a);return _0x3767f7(_0x1bf12a,_0x38f62a,_0x497b2d,_0x62a5e8);}if(_0x5a5181(_0x497b2d))return _0x3755e5(0x72);if(_0x3eb7fa?.(_0x1e55fb))return _0x3755e5(0x63d);if(Atomics['compareExchange'](_0x497b2d,_0x28a4c6,0x0,_0x5232a6)!==0x0)return _0x3755e5(0x25a);if(_0x5a5181(_0x497b2d)||_0x3eb7fa?.(_0x1e55fb))return Atomics[_0x3755e5(0x598)](_0x497b2d,_0x28a4c6,_0x5232a6,0x0),'attached';return _0x31d91d(_0x1bf12a),_0x3755e5(0x558);}finally{_0x34a7a5(_0x1bf12a);}}const _0x27ab7b=new Map(),_0x1d7c5b=new Set();function _0x56e05c(_0x32d637){const _0x57d4ed=_0x199e2d,_0x14dcf7=process[_0x57d4ed(0xee)];for(let _0x265f21=0x0;_0x265f21<_0x2b0396;_0x265f21++){if(Atomics[_0x57d4ed(0x776)](_0x32d637,_0x704d52+_0x265f21)===_0x14dcf7&&Atomics['load'](_0x32d637,_0x5cfbea+_0x265f21)!==_0x4b5f40)return!![];}return![];}function _0x3f66dd(_0x185d03,_0x10dcba,_0x2517ba={}){const _0x4bf3ac=_0x199e2d;let _0x5459b6=_0x27ab7b[_0x4bf3ac(0x6a)](_0x185d03);if(!_0x5459b6){const _0x4acf16=_0x53ee8c(_0x185d03,_0x10dcba,_0x2517ba);_0x5459b6={'att':_0x4acf16,'dataBytes':_0x10dcba,'refs':0x0,'isBusy':_0x2517ba[_0x4bf3ac(0x2ee)]??null,'onThreadExit':_0x2517ba[_0x4bf3ac(0x1e4)]??null},_0x27ab7b[_0x4bf3ac(0x49d)](_0x185d03,_0x5459b6);}if(_0x2517ba[_0x4bf3ac(0x2ee)])_0x5459b6[_0x4bf3ac(0x2ee)]=_0x2517ba[_0x4bf3ac(0x2ee)];if(_0x2517ba[_0x4bf3ac(0x1e4)])_0x5459b6[_0x4bf3ac(0x1e4)]=_0x2517ba[_0x4bf3ac(0x1e4)];_0x5459b6['refs']++;let _0x2f9e84=![];return{'sab':_0x5459b6['att'][_0x4bf3ac(0x736)],'name':_0x185d03,'release'(){const _0x3134df=_0x4bf3ac;if(_0x2f9e84)return![];_0x2f9e84=!![];if(--_0x5459b6[_0x3134df(0x47f)]>0x0)return![];if(_0x27ab7b['get'](_0x185d03)===_0x5459b6)_0x27ab7b[_0x3134df(0x95)](_0x185d03);const _0x540f23=_0x2655b2(_0x185d03,_0x5459b6[_0x3134df(0x6f7)],_0x5459b6[_0x3134df(0x221)],_0x5459b6['isBusy']);!_0x540f23&&_0x97c722&&_0x56e05c(_0x5459b6[_0x3134df(0x221)][_0x3134df(0x5ee)])&&_0x1d7c5b[_0x3134df(0x3e9)]({'name':_0x185d03,'dataBytes':_0x5459b6[_0x3134df(0x6f7)],'att':{..._0x5459b6[_0x3134df(0x221)],'slot':null},'isBusy':_0x5459b6[_0x3134df(0x2ee)],'onThreadExit':_0x5459b6[_0x3134df(0x1e4)]});if(_0x1d7c5b[_0x3134df(0x35f)])_0x46f2eb();return _0x540f23;}};}function _0x5e3014(_0x24e06c){const _0x124dec=_0x199e2d;if(!(_0x24e06c>0x0))return 0x0;const _0x4387e0=process[_0x124dec(0xee)];let _0x471c8a=0x0;const _0x5e8285=({att:_0x472d83,onThreadExit:_0x22dfd7})=>{const _0xcb48b4=_0x124dec;try{_0x22dfd7?.(_0x472d83['sab'],_0x24e06c);}catch{}const {hdr:_0x418722}=_0x472d83;for(let _0x28eba7=0x0;_0x28eba7<_0x2b0396;_0x28eba7++){if(Atomics[_0xcb48b4(0x776)](_0x418722,_0x704d52+_0x28eba7)!==_0x4387e0||Atomics[_0xcb48b4(0x776)](_0x418722,_0x5cfbea+_0x28eba7)!==_0x24e06c)continue;Atomics[_0xcb48b4(0x45d)](_0x418722,_0x5cfbea+_0x28eba7,0x0);if(Atomics[_0xcb48b4(0x598)](_0x418722,_0x704d52+_0x28eba7,_0x4387e0,0x0)===_0x4387e0)_0x471c8a++;}};for(const _0xcda6a6 of _0x27ab7b[_0x124dec(0x591)]())_0x5e8285(_0xcda6a6);for(const _0x5b9001 of _0x1d7c5b)_0x5e8285(_0x5b9001);return _0x46f2eb(),_0x471c8a;}function _0x46f2eb(){const _0x1727b8=_0x199e2d;for(const _0x242c84 of[..._0x1d7c5b]){if(_0x56e05c(_0x242c84[_0x1727b8(0x221)][_0x1727b8(0x5ee)]))continue;_0x1d7c5b['delete'](_0x242c84),_0x2655b2(_0x242c84['name'],_0x242c84[_0x1727b8(0x6f7)],_0x242c84[_0x1727b8(0x221)],_0x242c84[_0x1727b8(0x2ee)]);}}return okdbShmSegment={'attachSegment':_0x3f66dd,'releaseThreadSlots':_0x5e3014,'segmentNameFor':_0x1563f7,'legacySegmentNameFor':_0x7aa27a,'segmentNameStyle':_0x3ee61c,'SEG_NAME_MAX':_0x319988,'retireIfUnused':_0x192eb9,'totalBytes':_0x57274f,'headerOffset':_0x73b7bb,'MAX_SLOTS':_0x2b0396,'_attachRaw':_0x53ee8c,'_detachRaw':_0x2655b2,'_takeover':_0x3767f7,'_mapByName':_0x3d15a4,'_hooks':_0x56a07b,'_registry':_0x27ab7b,'_lingering':_0x1d7c5b,'_H':{'STATE':_0x28a4c6,'OVERFLOW':_0x90f5b2,'NONCE_A':_0x2cbaa7,'NONCE_B':_0x233eb4,'SLOTS':_0x704d52,'TIDS':_0x5cfbea}},okdbShmSegment;}var okdbShmGc,hasRequiredOkdbShmGc;function requireOkdbShmGc(){const _0x5b3e9d=_0x3d20e4;if(hasRequiredOkdbShmGc)return okdbShmGc;hasRequiredOkdbShmGc=0x1;const _0x154d03=require$$0$1,_0x5936c8=require$$1,_0x174ffe=_0x5b3e9d(0x327),_0x235b14=0x18+0x3*0x100*0x4,_0x11bec4=0x18+0x2*0x100*0x4,_0x208411=0xc;function _0x836fe3(){const {totalBytes:_0x24a71b}=requireOkdbShmSegment();return new Set([0x0,0x8,0x18,_0x11bec4,_0x208411,_0x24a71b(_0x11bec4),_0x24a71b(_0x235b14),_0x24a71b(_0x208411)]);}function _0x28bdbe(_0x52d9b8,_0x5559d4,_0x3a244d){const _0x35b74d=_0x5b3e9d,{totalBytes:_0x44f0eb}=requireOkdbShmSegment();if(_0x52d9b8['endsWith']('_boot')||_0x5559d4===_0x208411||_0x5559d4===_0x44f0eb(_0x208411))return _0x208411;if(_0x5559d4===_0x44f0eb(_0x235b14))return _0x235b14;if(_0x5559d4===_0x44f0eb(_0x11bec4))return _0x11bec4;return _0x3a244d===_0x35b74d(0x766)?_0x235b14:_0x11bec4;}function _0x335229(){const _0xcfbd97=_0x5b3e9d,_0x38b5a4=new Set(),_0x2ed101=[],_0x250035=_0x174ffe+'/';let _0x474887;try{_0x474887=_0x154d03[_0xcfbd97(0x1ed)](_0xcfbd97(0x554))[_0xcfbd97(0x293)](_0x33eed4=>/^\d+$/[_0xcfbd97(0x155)](_0x33eed4));}catch{throw new Error('shm-gc:\x20/proc\x20is\x20not\x20readable\x20—\x20cannot\x20tell\x20which\x20segments\x20are\x20in\x20use');}for(const _0x3c29ab of _0x474887){const _0x538cbc=_0x5936c8[_0xcfbd97(0x10b)]('/proc',_0x3c29ab);let _0x42fe5c=!![];try{const _0xcac326=_0x154d03[_0xcfbd97(0x418)](_0x5936c8[_0xcfbd97(0x10b)](_0x538cbc,'maps'),_0xcfbd97(0x320));let _0x81d510=_0xcac326[_0xcfbd97(0x380)](_0x250035);while(_0x81d510!==-0x1){const _0x59e431=_0xcac326['indexOf']('\x0a',_0x81d510),_0x41f72d=_0xcac326['slice'](_0x81d510+_0x250035[_0xcfbd97(0x39d)],_0x59e431===-0x1?undefined:_0x59e431);if(!_0x41f72d[_0xcfbd97(0x113)](_0xcfbd97(0x6aa)))_0x38b5a4[_0xcfbd97(0x3e9)](_0x41f72d);_0x81d510=_0xcac326[_0xcfbd97(0x380)](_0x250035,_0x81d510+0x1);}}catch(_0x40f48e){if(_0x40f48e['code']!=='ENOENT'&&_0x40f48e[_0xcfbd97(0x25b)]!==_0xcfbd97(0x696))_0x42fe5c=![];}try{for(const _0x40301e of _0x154d03['readdirSync'](_0x5936c8[_0xcfbd97(0x10b)](_0x538cbc,'fd'))){let _0x5f55ad;try{_0x5f55ad=_0x154d03[_0xcfbd97(0x4c3)](_0x5936c8[_0xcfbd97(0x10b)](_0x538cbc,'fd',_0x40301e));}catch{continue;}if(_0x5f55ad[_0xcfbd97(0x42e)](_0x250035)&&!_0x5f55ad[_0xcfbd97(0x113)](_0xcfbd97(0x6aa)))_0x38b5a4['add'](_0x5f55ad[_0xcfbd97(0x13a)](_0x250035[_0xcfbd97(0x39d)]));}}catch(_0x41bbbc){if(_0x41bbbc[_0xcfbd97(0x25b)]!==_0xcfbd97(0x109)&&_0x41bbbc[_0xcfbd97(0x25b)]!==_0xcfbd97(0x696))_0x42fe5c=![];}if(!_0x42fe5c){let _0x3f9bec=null;try{_0x3f9bec=_0x154d03['statSync'](_0x538cbc)[_0xcfbd97(0x5b5)];}catch{}let _0x587c5d='?';try{_0x587c5d=_0x154d03[_0xcfbd97(0x418)](_0x5936c8[_0xcfbd97(0x10b)](_0x538cbc,_0xcfbd97(0x6c8)),_0xcfbd97(0x320))['trim']();}catch{}if(_0x3f9bec!==null)_0x2ed101[_0xcfbd97(0x2f9)]({'pid':Number(_0x3c29ab),'uid':_0x3f9bec,'comm':_0x587c5d});}}return{'inUse':_0x38b5a4,'unreadable':_0x2ed101};}function _0x54b95b({prefix:prefix=_0x5b3e9d(0x650),dryRun:dryRun=![],anySize:anySize=![],force:force=![],log:log=()=>{}}={}){const _0x1ab2ad=_0x5b3e9d;if(process[_0x1ab2ad(0x379)]!==_0x1ab2ad(0x4bb)||!_0x154d03[_0x1ab2ad(0x1c9)](_0x174ffe))throw new Error('shm-gc:\x20Linux\x20only\x20(POSIX\x20shared\x20memory\x20under\x20/dev/shm)');const _0x30be64=process[_0x1ab2ad(0x67b)](),_0x2cd0f1=_0x30be64===0x0,_0x338aa7=_0x836fe3(),{inUse:_0xd6f01c,unreadable:_0x52929b}=_0x335229(),_0x2ed7ec=_0x52929b[_0x1ab2ad(0x293)](_0x3b5505=>_0x2cd0f1||_0x3b5505[_0x1ab2ad(0x5b5)]===_0x30be64),_0x1c20b7={'dryRun':dryRun,'prefix':prefix,'scanned':0x0,'matched':0x0,'inUse':0x0,'notOkdbShaped':0x0,'foreignOwner':0x0,'candidates':0x0,'candidatesLegacyNamed':0x0,'candidateBytes':0x0,'candidateAllocated':0x0,'deleted':0x0,'deletedAllocated':0x0,'skippedByProtocol':0x0,'errors':0x0,'unreadablePids':_0x52929b['length'],'blindPids':_0x2ed7ec[_0x1ab2ad(0x757)](_0x207f9f=>_0x207f9f[_0x1ab2ad(0xee)]),'blindCommands':_0x4d010e(_0x2ed7ec)};if(_0x2ed7ec['length']&&!dryRun&&!force)throw new Error('shm-gc:\x20cannot\x20read\x20the\x20memory\x20maps\x20of\x20'+_0x2ed7ec[_0x1ab2ad(0x39d)]+_0x1ab2ad(0x4c4)+(_0x1ab2ad(0x177)+_0x1c20b7['blindCommands']+_0x1ab2ad(0x421))+_0x1ab2ad(0x596));const {retireIfUnused:_0x3358e4,segmentNameStyle:_0x241f16,_registry:_0x3f7d16}=requireOkdbShmSegment();let _0x4ff5df=null;if(!dryRun)try{require('v8')[_0x1ab2ad(0xab)]('--expose-gc'),_0x4ff5df=require('vm')[_0x1ab2ad(0x17e)]('gc');}catch{}const _0x62496b=_0x154d03[_0x1ab2ad(0x549)](_0x174ffe);try{let _0x4c6004,_0x321ee1=0x0;while(_0x4c6004=_0x62496b[_0x1ab2ad(0x720)]()){_0x1c20b7[_0x1ab2ad(0x16b)]++;const _0x2a5b0e=_0x4c6004[_0x1ab2ad(0x707)];if(!_0x2a5b0e[_0x1ab2ad(0x42e)](prefix))continue;_0x1c20b7[_0x1ab2ad(0x32a)]++;if(_0x3f7d16[_0x1ab2ad(0x469)](_0x2a5b0e)){_0x1c20b7['inUse']++;continue;}if(_0xd6f01c['has'](_0x2a5b0e)){_0x1c20b7[_0x1ab2ad(0x5a0)]++;continue;}let _0x5b988e;try{_0x5b988e=_0x154d03[_0x1ab2ad(0x31a)](_0x5936c8[_0x1ab2ad(0x10b)](_0x174ffe,_0x2a5b0e));}catch{continue;}if(!_0x5b988e[_0x1ab2ad(0xed)]())continue;const _0xb06388=_0x241f16(_0x2a5b0e);if(!_0xb06388||!anySize&&!_0x338aa7['has'](_0x5b988e[_0x1ab2ad(0x35f)])){_0x1c20b7[_0x1ab2ad(0x410)]++;continue;}if(!_0x2cd0f1&&_0x5b988e[_0x1ab2ad(0x5b5)]!==_0x30be64){_0x1c20b7[_0x1ab2ad(0x212)]++;continue;}_0x1c20b7['candidates']++;if(_0xb06388===_0x1ab2ad(0x103))_0x1c20b7[_0x1ab2ad(0x39e)]++;_0x1c20b7[_0x1ab2ad(0x74f)]+=_0x5b988e[_0x1ab2ad(0x35f)],_0x1c20b7[_0x1ab2ad(0x590)]+=_0x5b988e[_0x1ab2ad(0x594)]*0x200;if(dryRun)continue;const _0x641eb1=_0x28bdbe(_0x2a5b0e,_0x5b988e[_0x1ab2ad(0x35f)],_0xb06388);try{const _0x4387d7=_0x3358e4(_0x2a5b0e,_0x641eb1);_0x4387d7===_0x1ab2ad(0x558)?(_0x1c20b7['deleted']++,_0x1c20b7[_0x1ab2ad(0x6d2)]+=_0x5b988e[_0x1ab2ad(0x594)]*0x200):(_0x1c20b7['skippedByProtocol']++,log(_0x1ab2ad(0x4a2)+_0x2a5b0e+':\x20'+_0x4387d7));}catch(_0x289255){_0x1c20b7['errors']++,log(_0x1ab2ad(0x69)+_0x2a5b0e+':\x20'+_0x289255[_0x1ab2ad(0x5e6)]);}_0x4ff5df&&++_0x321ee1>=0x200&&(_0x321ee1=0x0,_0x4ff5df());}}finally{_0x62496b[_0x1ab2ad(0x443)]();}return _0x1c20b7;}function _0x4d010e(_0x59f374){const _0x4cafe3=_0x5b3e9d,_0xaed3d8=new Map();for(const _0x5f2e32 of _0x59f374)_0xaed3d8[_0x4cafe3(0x49d)](_0x5f2e32['comm'],(_0xaed3d8[_0x4cafe3(0x6a)](_0x5f2e32[_0x4cafe3(0x6c8)])??0x0)+0x1);return[..._0xaed3d8]['map'](([_0x902c0a,_0x520b8b])=>_0x520b8b>0x1?_0x902c0a+'×'+_0x520b8b:_0x902c0a)[_0x4cafe3(0x10b)](',\x20');}function _0x4c2eca(_0x54cb42){const _0x440f3c=_0x5b3e9d,_0x5c6ea0=['B',_0x440f3c(0x65f),'MiB',_0x440f3c(0x5f5),_0x440f3c(0x56b)];let _0x1260fc=0x0;while(_0x54cb42>=0x400&&_0x1260fc<_0x5c6ea0[_0x440f3c(0x39d)]-0x1){_0x54cb42/=0x400,_0x1260fc++;}return _0x54cb42['toFixed'](_0x1260fc?0x1:0x0)+'\x20'+_0x5c6ea0[_0x1260fc];}function _0x1d3a0b(_0x48e60e){const _0x35c0f9=_0x5b3e9d,_0x8863f2=[_0x35c0f9(0x528)+(_0x48e60e[_0x35c0f9(0x687)]?_0x35c0f9(0x47c):'')+':\x20prefix\x20'+JSON[_0x35c0f9(0x5c1)](_0x48e60e[_0x35c0f9(0xd6)]),_0x35c0f9(0x1ae)+_0x48e60e[_0x35c0f9(0x16b)]+_0x35c0f9(0x2dc)+_0x174ffe,_0x35c0f9(0x70b)+_0x48e60e[_0x35c0f9(0x32a)],_0x35c0f9(0x51e)+_0x48e60e[_0x35c0f9(0x5a0)],_0x35c0f9(0x6b5)+_0x48e60e[_0x35c0f9(0x410)],'\x20\x20other\x20owner\x20\x20\x20\x20\x20\x20\x20\x20'+_0x48e60e[_0x35c0f9(0x212)],_0x35c0f9(0x475)+_0x48e60e['candidates']+'\x20—\x20'+_0x4c2eca(_0x48e60e['candidateBytes'])+_0x35c0f9(0x3f2)+_0x4c2eca(_0x48e60e[_0x35c0f9(0x590)])+_0x35c0f9(0x1bb)+(_0x48e60e['candidatesLegacyNamed']?'\x20('+_0x48e60e[_0x35c0f9(0x39e)]+_0x35c0f9(0x1b1):'')];if(!_0x48e60e['dryRun']){_0x8863f2[_0x35c0f9(0x2f9)](_0x35c0f9(0xc7)+_0x48e60e['deleted']+_0x35c0f9(0x18b)+_0x4c2eca(_0x48e60e[_0x35c0f9(0x6d2)])+_0x35c0f9(0x2fc));if(_0x48e60e['skippedByProtocol'])_0x8863f2[_0x35c0f9(0x2f9)](_0x35c0f9(0x5ce)+_0x48e60e['skippedByProtocol']);if(_0x48e60e[_0x35c0f9(0x422)])_0x8863f2['push'](_0x35c0f9(0x6f)+_0x48e60e[_0x35c0f9(0x422)]);}return _0x48e60e['unreadablePids']&&_0x8863f2[_0x35c0f9(0x2f9)](_0x35c0f9(0x445)+_0x48e60e['unreadablePids']+'\x20process(es)\x20had\x20unreadable\x20maps'+(_0x48e60e[_0x35c0f9(0x128)][_0x35c0f9(0x39d)]?_0x35c0f9(0x18b)+_0x48e60e[_0x35c0f9(0x128)]['length']+'\x20of\x20them\x20run\x20as\x20this\x20user\x20and\x20could\x20map\x20these\x20segments:\x20'+(_0x48e60e[_0x35c0f9(0x6dc)]+_0x35c0f9(0x574)):_0x35c0f9(0x5d1))),_0x8863f2[_0x35c0f9(0x10b)]('\x0a');}function _0x407368(_0x2b1e87){const _0x1712ac=_0x5b3e9d,_0x6490f5={'prefix':_0x1712ac(0x650),'dryRun':![],'anySize':![],'force':![],'verbose':![]};for(let _0x343189=0x0;_0x343189<_0x2b1e87[_0x1712ac(0x39d)];_0x343189++){const _0x378cba=_0x2b1e87[_0x343189];if(_0x378cba===_0x1712ac(0x55d)||_0x378cba==='-n')_0x6490f5[_0x1712ac(0x687)]=!![];else{if(_0x378cba===_0x1712ac(0x493))_0x6490f5[_0x1712ac(0x54a)]=!![];else{if(_0x378cba===_0x1712ac(0x1b8))_0x6490f5['force']=!![];else{if(_0x378cba==='--verbose'||_0x378cba==='-v')_0x6490f5[_0x1712ac(0x4bd)]=!![];else{if(_0x378cba===_0x1712ac(0x1a2))_0x6490f5['prefix']=_0x2b1e87[++_0x343189]??'';else{if(_0x378cba[_0x1712ac(0x42e)](_0x1712ac(0x4b8)))_0x6490f5[_0x1712ac(0xd6)]=_0x378cba[_0x1712ac(0x13a)](_0x1712ac(0x4b8)[_0x1712ac(0x39d)]);else{if(_0x378cba==='--help'||_0x378cba==='-h')_0x6490f5['help']=!![];else throw new Error(_0x1712ac(0x2e6)+_0x378cba);}}}}}}}return _0x6490f5;}const _0x2669d0=_0x5b3e9d(0x5cc);function _0x27ad31(_0x51a232){const _0x319060=_0x5b3e9d;let _0x3a48e8;try{_0x3a48e8=_0x407368(_0x51a232);}catch(_0x9c3ab8){return console[_0x319060(0x492)](_0x9c3ab8[_0x319060(0x5e6)]),console[_0x319060(0x492)](_0x2669d0),0x2;}if(_0x3a48e8[_0x319060(0x353)])return console[_0x319060(0x24e)](_0x2669d0),0x0;const _0x4d3b3f=_0x54b95b({..._0x3a48e8,'log':_0x3a48e8['verbose']?_0x357525=>console[_0x319060(0x24e)](_0x357525):undefined});return console[_0x319060(0x24e)](_0x1d3a0b(_0x4d3b3f)),_0x4d3b3f['errors']?0x1:0x0;}return okdbShmGc={'shmGc':_0x54b95b,'formatReport':_0x1d3a0b,'main':_0x27ad31,'scanInUse':_0x335229,'ENV_DATA_BYTES':_0x235b14,'LEGACY_ENV_DATA_BYTES':_0x11bec4,'BOOT_DATA_BYTES':_0x208411},okdbShmGc;}var hasRequiredOkdb;function requireOkdb(){const _0x2480b7=_0x3d20e4;if(hasRequiredOkdb)return okdb$1;hasRequiredOkdb=0x1;try{process[_0x2480b7(0x230)]();}catch{}const _0x9b04e6=require$$1,_0xf79001=require$$0$1,{resolveWorkers:_0x102e3e,isShmbufNative:_0x44736a}=requireOkdbWorkers();function _0x4bd009(_0x374ca0){const _0xcde2d9=_0x2480b7,_0x1e3c74=_0x374ca0[_0xcde2d9(0x13a)](0x2),_0x3439dd={};let _0x2d6092=0x0;while(_0x2d6092<_0x1e3c74[_0xcde2d9(0x39d)]){const _0x50f50e=_0x1e3c74[_0x2d6092];if(_0x50f50e==='--port'||_0x50f50e==='-p')_0x3439dd[_0xcde2d9(0x255)]=Number(_0x1e3c74[++_0x2d6092]);else{if(_0x50f50e===_0xcde2d9(0x539)||_0x50f50e==='-d')_0x3439dd[_0xcde2d9(0x4c5)]=_0x1e3c74[++_0x2d6092];else{if(_0x50f50e==='--key'||_0x50f50e==='-k')_0x3439dd[_0xcde2d9(0x466)]=_0x1e3c74[++_0x2d6092];else{if(_0x50f50e===_0xcde2d9(0x3c2)||_0x50f50e==='-c')_0x3439dd['config']=_0x1e3c74[++_0x2d6092];else{if(_0x50f50e===_0xcde2d9(0x428))_0x3439dd['logLevel']=_0x1e3c74[++_0x2d6092];else{if(_0x50f50e===_0xcde2d9(0x6df))_0x3439dd[_0xcde2d9(0x29c)]=!![];else{if(_0x50f50e===_0xcde2d9(0x2a8))_0x3439dd[_0xcde2d9(0x116)]=!![];else{if(_0x50f50e===_0xcde2d9(0x548))_0x3439dd[_0xcde2d9(0x150)]=_0x1e3c74[++_0x2d6092];else{if(_0x50f50e==='--no-cluster')_0x3439dd[_0xcde2d9(0x38a)]=!![];else{if(_0x50f50e===_0xcde2d9(0x488)||_0x50f50e==='-e')_0x3439dd[_0xcde2d9(0x124)]=_0x1e3c74[++_0x2d6092];else{if(_0x50f50e===_0xcde2d9(0x472))_0x3439dd[_0xcde2d9(0x429)]=_0x1e3c74[++_0x2d6092];else{if(_0x50f50e==='--changes')_0x3439dd[_0xcde2d9(0x6b8)]=!![];else{if(_0x50f50e==='--blobs')_0x3439dd[_0xcde2d9(0x37a)]=!![];else{if(_0x50f50e===_0xcde2d9(0x6a4))_0x3439dd['newIdentity']=!![];else{if(_0x50f50e==='--drop')_0x3439dd[_0xcde2d9(0x3f6)]=!![];else{if(_0x50f50e===_0xcde2d9(0x4f0)){const _0x203c99=[];while(_0x2d6092+0x1<_0x1e3c74[_0xcde2d9(0x39d)]&&!_0x1e3c74[_0x2d6092+0x1]['startsWith']('--')){_0x203c99[_0xcde2d9(0x2f9)](_0x1e3c74[++_0x2d6092]);}_0x3439dd[_0xcde2d9(0x1fd)]=_0x203c99['length']>0x0?_0x203c99:!![];}else{if(_0x50f50e===_0xcde2d9(0x307))_0x3439dd['logRequests']=!![];else{if(_0x50f50e===_0xcde2d9(0x21b))_0x3439dd[_0xcde2d9(0x707)]=_0x1e3c74[++_0x2d6092];else{if(_0x50f50e===_0xcde2d9(0x1b4))_0x3439dd[_0xcde2d9(0x54b)]=_0x1e3c74[++_0x2d6092];else{if(_0x50f50e==='--label')_0x3439dd['label']=_0x1e3c74[++_0x2d6092];else{if(_0x50f50e==='--permissions')_0x3439dd[_0xcde2d9(0x1f4)]=_0x1e3c74[++_0x2d6092];else{if(_0x50f50e===_0xcde2d9(0x13f))_0x3439dd[_0xcde2d9(0x660)]=_0x1e3c74[++_0x2d6092];else{if(_0x50f50e===_0xcde2d9(0x70f))_0x3439dd[_0xcde2d9(0x604)]=_0x1e3c74[++_0x2d6092];else{if(_0x50f50e==='--token')_0x3439dd[_0xcde2d9(0x129)]=_0x1e3c74[++_0x2d6092];else{if(_0x50f50e==='--username'||_0x50f50e==='-u')_0x3439dd[_0xcde2d9(0x573)]=_0x1e3c74[++_0x2d6092];else{if(_0x50f50e===_0xcde2d9(0x309))_0x3439dd['selfAddress']=_0x1e3c74[++_0x2d6092];else{if(_0x50f50e===_0xcde2d9(0x53e)||_0x50f50e==='-v'){const _0x3a0dfd=require$$3;console[_0xcde2d9(0x24e)](_0x3a0dfd[_0xcde2d9(0x3e1)]),process[_0xcde2d9(0x4e7)](0x0);}else(_0x50f50e==='--help'||_0x50f50e==='-h')&&(_0x313f59(),process[_0xcde2d9(0x4e7)](0x0));}}}}}}}}}}}}}}}}}}}}}}}}}}_0x2d6092++;}return _0x3439dd;}function _0x313f59(){const _0x1ff632=_0x2480b7;console[_0x1ff632(0x24e)](_0x1ff632(0xde));}const _0x1eae6f=new Set([_0x2480b7(0x45f),_0x2480b7(0x2cf),'warn',_0x2480b7(0x492)]);function _0x117dd0(_0x17511e){const _0x8c5dcc=_0x2480b7,_0x49b32f=_0x17511e['config']?_0x9b04e6[_0x8c5dcc(0x738)](_0x17511e[_0x8c5dcc(0x3f4)]):_0x9b04e6[_0x8c5dcc(0x738)](_0x8c5dcc(0x6f3));let _0x51d17c={};if(_0xf79001[_0x8c5dcc(0x1c9)](_0x49b32f))try{const _0x3d1966=_0xf79001['readFileSync'](_0x49b32f,'utf8')[_0x8c5dcc(0x416)](/^\uFEFF/,'');_0x51d17c=JSON[_0x8c5dcc(0xc3)](_0x3d1966),console[_0x8c5dcc(0x24e)]('[okdb]\x20loaded\x20config:\x20'+_0x49b32f);}catch(_0x109e05){console[_0x8c5dcc(0x492)](_0x8c5dcc(0x274)+_0x49b32f+':\x20'+_0x109e05['message']),process[_0x8c5dcc(0x4e7)](0x1);}const _0x20c627={'port':process.env.OKDB_PORT?Number(process.env.OKDB_PORT):undefined,'path':process.env.OKDB_PATH??undefined,'key':process.env.OKDB_KEY??undefined,'logLevel':process.env.OKDB_LOG_LEVEL??undefined,'noRepl':process.env.OKDB_NO_REPL==='1'?!![]:undefined,'noAdmin':process.env.OKDB_NO_ADMIN==='1'?!![]:undefined},_0x20c55f={'port':_0x17511e[_0x8c5dcc(0x255)]??_0x51d17c['port']??_0x20c627['port']??0x2124,'dbPath':_0x17511e[_0x8c5dcc(0x4c5)]??_0x51d17c[_0x8c5dcc(0x4c5)]??_0x20c627['path']??_0x8c5dcc(0x2f3),'key':_0x17511e['key']??_0x51d17c[_0x8c5dcc(0x466)]??_0x20c627[_0x8c5dcc(0x466)]??undefined,'logLevel':_0x17511e[_0x8c5dcc(0x4a0)]??_0x51d17c['logLevel']??_0x20c627['logLevel']??_0x8c5dcc(0x2cf),'noRepl':_0x17511e[_0x8c5dcc(0x29c)]??_0x51d17c[_0x8c5dcc(0x29c)]??_0x20c627[_0x8c5dcc(0x29c)]??![],'noAdmin':_0x17511e['noAdmin']??_0x51d17c[_0x8c5dcc(0x116)]??_0x20c627[_0x8c5dcc(0x116)]??![],'admin':_0x51d17c[_0x8c5dcc(0x270)]??{},'api':_0x51d17c[_0x8c5dcc(0x2bc)]??undefined,'auth':_0x51d17c[_0x8c5dcc(0x8a)]??undefined,'mcp':_0x51d17c[_0x8c5dcc(0x3a2)]??undefined,'http':_0x51d17c['http']??undefined,'backup':_0x51d17c[_0x8c5dcc(0x156)]??undefined,'timeMachine':_0x51d17c[_0x8c5dcc(0x121)]!==![]?_0x51d17c[_0x8c5dcc(0x121)]??{}:![],'processors':_0x51d17c[_0x8c5dcc(0x43e)],'engines':_0x51d17c[_0x8c5dcc(0x39c)],'compaction':_0x51d17c['compaction']};if(_0x17511e[_0x8c5dcc(0x38a)])_0x20c55f[_0x8c5dcc(0x38a)]=!![];if(_0x17511e[_0x8c5dcc(0x150)]!==undefined)_0x20c55f[_0x8c5dcc(0x3bd)]=_0x17511e[_0x8c5dcc(0x150)];_0x17511e['open']!==undefined&&(_0x20c55f[_0x8c5dcc(0x8a)]=_0x20c55f[_0x8c5dcc(0x8a)]||{},_0x20c55f[_0x8c5dcc(0x8a)][_0x8c5dcc(0x1fd)]=_0x17511e['open']);_0x17511e['logRequests']&&(_0x20c55f[_0x8c5dcc(0x45f)]=_0x20c55f['debug']||{},_0x20c55f[_0x8c5dcc(0x45f)]['logRequests']=!![]);(!Number[_0x8c5dcc(0x446)](_0x20c55f[_0x8c5dcc(0x255)])||_0x20c55f['port']<0x1||_0x20c55f[_0x8c5dcc(0x255)]>0xffff)&&(console[_0x8c5dcc(0x492)](_0x8c5dcc(0x2a2)+_0x20c55f['port']+_0x8c5dcc(0x579)),process[_0x8c5dcc(0x4e7)](0x1));!_0x1eae6f[_0x8c5dcc(0x469)](_0x20c55f[_0x8c5dcc(0x4a0)])&&(console[_0x8c5dcc(0x492)](_0x8c5dcc(0xe0)+_0x20c55f['logLevel']+_0x8c5dcc(0x622)),process[_0x8c5dcc(0x4e7)](0x1));const _0x1607ee=_0x20c55f[_0x8c5dcc(0x91)]?.[_0x8c5dcc(0x41a)];_0x1607ee!==undefined&&!(typeof _0x1607ee===_0x8c5dcc(0xe7)&&_0x1607ee)&&!(Array[_0x8c5dcc(0x339)](_0x1607ee)&&_0x1607ee[_0x8c5dcc(0x39d)]&&_0x1607ee['every'](_0x29e141=>typeof _0x29e141===_0x8c5dcc(0xe7)&&_0x29e141))&&(console[_0x8c5dcc(0x492)](_0x8c5dcc(0x179)+JSON[_0x8c5dcc(0x5c1)](_0x1607ee)+'\x20(must\x20be\x20a\x20string\x20or\x20array\x20of\x20strings)'),process['exit'](0x1));for(const _0x35495f of _0x360f83){_0x20c55f[_0x35495f]!==undefined&&typeof _0x20c55f[_0x35495f]!==_0x8c5dcc(0x200)&&(console[_0x8c5dcc(0x492)](_0x8c5dcc(0x560)+_0x35495f+_0x8c5dcc(0x186)+JSON[_0x8c5dcc(0x5c1)](_0x20c55f[_0x35495f])+'\x20(must\x20be\x20true\x20or\x20false)'),process['exit'](0x1));}return _0x20c55f;}const _0x360f83=[_0x2480b7(0x43e),'engines',_0x2480b7(0x3a6)];function _0x3e7e17(_0x5c75b4){const _0x24329e=_0x2480b7;return!!(_0x5c75b4&&typeof _0x5c75b4===_0x24329e(0x5d4)&&!Array[_0x24329e(0x339)](_0x5c75b4)&&Object[_0x24329e(0x6d8)](_0x5c75b4)[_0x24329e(0x39d)]>0x0);}function _0x288e37(_0x1e0911){return{..._0x1e0911['key']?{'encryptionKey':_0x1e0911['key']}:{},'engines':![],'processors':![],'compaction':![]};}const _0x47f2b8=!process[_0x2480b7(0x11c)]['isTTY']||!!process.env.NO_COLOR;function _0x8cdc79(_0x5eda06,_0x239c3d){const _0x4f559b=_0x2480b7;return _0x47f2b8?_0x239c3d:'\x1b['+_0x5eda06+'m'+_0x239c3d+_0x4f559b(0x2cc);}function _0x229da7(_0x1bc95f){const _0x2717b5=_0x2480b7;if(!_0x1bc95f||_0x1bc95f['length']===0x0)return;const _0x54276c='─'['repeat'](0x38);process[_0x2717b5(0x705)]['write']('\x0a'),process[_0x2717b5(0x705)][_0x2717b5(0xb6)](_0x8cdc79('33',_0x2717b5(0x566)+_0x1bc95f['length']+_0x2717b5(0x564)+(_0x1bc95f[_0x2717b5(0x39d)]>0x1?'S':'')+'\x0a')),process['stderr'][_0x2717b5(0xb6)]('\x20\x20'+_0x54276c+'\x0a');for(const _0x1e8243 of _0x1bc95f){const _0x5c3902=_0x1e8243[_0x2717b5(0x67c)]===_0x2717b5(0x492)?_0x8cdc79('31',_0x2717b5(0x1e3)):_0x8cdc79('33',_0x2717b5(0x408));process['stderr'][_0x2717b5(0xb6)](_0x5c3902+'\x20\x20'+_0x8cdc79('1',_0x1e8243[_0x2717b5(0x6f8)])+'\x0a'),process[_0x2717b5(0x705)][_0x2717b5(0xb6)](_0x2717b5(0x60e)+_0x1e8243['message']+'\x0a');if(_0x1e8243[_0x2717b5(0x299)])process[_0x2717b5(0x705)][_0x2717b5(0xb6)]('\x20\x20\x20\x20\x20\x20\x20'+_0x8cdc79('2',_0x2717b5(0x23d)+_0x1e8243[_0x2717b5(0x299)])+'\x0a');process[_0x2717b5(0x705)][_0x2717b5(0xb6)]('\x0a');}process['stderr'][_0x2717b5(0xb6)]('\x20\x20'+_0x54276c+'\x0a\x0a');}function _0x2bebd9(_0x4bf3db,_0x3bd47b,_0x9366de={}){const _0x23c90d=_0x2480b7,_0x403529=_0x4bf3db[_0x23c90d(0x91)][_0x23c90d(0x289)](_0x3bd47b,_0x9366de);if(_0x403529&&_0x403529['_isClusterController'])return Promise[_0x23c90d(0x738)](_0x403529);const _0x2c86e3=_0x4bf3db[_0x23c90d(0x91)]['servers']?.[_0x23c90d(0x39d)]?_0x4bf3db[_0x23c90d(0x91)][_0x23c90d(0x63b)]:[_0x403529];return new Promise((_0x150ebc,_0x7ec229)=>{const _0x35843d=_0x23c90d;_0x403529[_0x35843d(0x375)](_0x35843d(0x492),_0x7ec229),Promise['all'](_0x2c86e3['map'](_0x319a3b=>_0x319a3b[_0x35843d(0x397)]?null:new Promise(_0x3d89c5=>_0x319a3b['once'](_0x35843d(0x397),_0x3d89c5))))[_0x35843d(0xad)](()=>_0x150ebc(_0x403529));});}function _0x313d09(_0x462b6a){const _0x386170=_0x2480b7;return _0x462b6a[_0x386170(0x91)]?.[_0x386170(0x41a)]!==undefined?{'host':_0x462b6a[_0x386170(0x91)][_0x386170(0x41a)]}:{};}async function _0x4e2758(_0x22e21b){const _0x32d97f=_0x2480b7,_0x1075b6=require$$4$1;console[_0x32d97f(0x24e)](_0x32d97f(0x2a9));let _0x2ca77c=!![];const _0x430b9e=(_0x471378,_0x1f8470)=>{const _0x45c451=_0x32d97f;console[_0x45c451(0x24e)]('\x20\x20'+(_0x471378?'✓':'✗')+'\x20'+_0x1f8470);if(!_0x471378)_0x2ca77c=![];},_0x1be8f3=Number(process[_0x32d97f(0x3e1)][_0x32d97f(0x416)]('v','')[_0x32d97f(0x2aa)]('.')[0x0]);_0x430b9e(_0x1be8f3>=0x12,_0x32d97f(0x4bf)+process[_0x32d97f(0x3e1)]+(_0x1be8f3<0x12?_0x32d97f(0x317):''));const _0x3a582b=_0x9b04e6[_0x32d97f(0x738)](_0x22e21b[_0x32d97f(0x361)]);try{_0xf79001[_0x32d97f(0x2ad)](_0x3a582b,{'recursive':!![]});const _0x17d98b=_0x9b04e6[_0x32d97f(0x10b)](_0x3a582b,_0x32d97f(0x81));_0xf79001[_0x32d97f(0x188)](_0x17d98b,''),_0xf79001[_0x32d97f(0x3a3)](_0x17d98b),_0x430b9e(!![],'database\x20path\x20writable:\x20'+_0x3a582b);}catch(_0x5266d6){_0x430b9e(![],'database\x20path\x20not\x20writable:\x20'+_0x3a582b+'\x20\x20('+_0x5266d6[_0x32d97f(0x5e6)]+')');}const _0x2348fa=await new Promise(_0x997ba9=>{const _0x188a4f=_0x32d97f,_0x42fbc1=_0x1075b6[_0x188a4f(0x685)]();_0x42fbc1['once']('error',()=>_0x997ba9(![])),_0x42fbc1['once'](_0x188a4f(0x397),()=>{const _0x57b687=_0x188a4f;_0x42fbc1[_0x57b687(0x44f)](),_0x997ba9(!![]);}),_0x42fbc1[_0x188a4f(0x289)](_0x22e21b[_0x188a4f(0x255)],'127.0.0.1');});_0x430b9e(_0x2348fa,_0x32d97f(0x244)+_0x22e21b[_0x32d97f(0x255)]+'\x20'+(_0x2348fa?_0x32d97f(0x5c3):_0x32d97f(0x239)));const _0x596d5a=_0x9b04e6['resolve'](_0x32d97f(0x6f3));if(_0xf79001[_0x32d97f(0x1c9)](_0x596d5a))try{JSON[_0x32d97f(0xc3)](_0xf79001[_0x32d97f(0x418)](_0x596d5a,_0x32d97f(0x320))['replace'](/^\uFEFF/,'')),_0x430b9e(!![],_0x32d97f(0x53b)+_0x596d5a);}catch(_0x5ad8cc){_0x430b9e(![],_0x32d97f(0x366)+_0x5ad8cc[_0x32d97f(0x5e6)]);}else _0x430b9e(!![],_0x32d97f(0x4cf));if(_0x44736a()){const _0x31fa57=_0x102e3e(_0x22e21b,{'shmbufNative':!![]});_0x430b9e(!![],'cluster:\x20ready\x20('+_0x31fa57+_0x32d97f(0x3e5)+(_0x31fa57===0x1?'':'s')+')');}else _0x430b9e(!![],_0x32d97f(0x342));if(!_0x2348fa)try{const _0x2dd94d=require(_0x32d97f(0x4e1)),_0x5e9f7b=new _0x2dd94d(_0x3a582b,{'engines':![],'processors':![],'compaction':![],'auth':{'open':!![]}});await _0x5e9f7b['open']();try{await _0x5e9f7b['processes']['open']({'reader':!![]});const _0x379e36=_0x5e9f7b[_0x32d97f(0x5c9)][_0x32d97f(0x6e3)](),_0x197452=_0x379e36[_0x32d97f(0x293)](_0x26dd9d=>_0x26dd9d[_0x32d97f(0x77d)]!=null)[_0x32d97f(0x39d)];_0x430b9e(!![],_0x32d97f(0x30c)+_0x379e36[_0x32d97f(0x39d)]+'\x20process'+(_0x379e36[_0x32d97f(0x39d)]===0x1?'':'es')+'\x20('+_0x197452+_0x32d97f(0x56c));}finally{await _0x5e9f7b[_0x32d97f(0x44f)]();}}catch{}console[_0x32d97f(0x24e)](''),_0x2ca77c?console[_0x32d97f(0x24e)]('\x20\x20All\x20checks\x20passed.\x0a'):(console[_0x32d97f(0x24e)](_0x32d97f(0x1cf)),process[_0x32d97f(0x4e7)](0x1));}async function _0x27c8f0(){const _0x13ef0f=_0x2480b7,_0x3a6124=_0x9b04e6['resolve']('.kdbconfig');!_0xf79001[_0x13ef0f(0x1c9)](_0x3a6124)?(_0xf79001[_0x13ef0f(0x188)](_0x3a6124,JSON[_0x13ef0f(0x5c1)]({'port':0x2124,'path':'./okdb-data','logLevel':_0x13ef0f(0x2cf),'noRepl':![],'noAdmin':![]},null,0x2)+'\x0a'),console['log'](_0x13ef0f(0x695))):console['log'](_0x13ef0f(0x2d7));const _0xddeaa6=_0x9b04e6['resolve']('./okdb-data');!_0xf79001[_0x13ef0f(0x1c9)](_0xddeaa6)?(_0xf79001[_0x13ef0f(0x2ad)](_0xddeaa6,{'recursive':!![]}),console[_0x13ef0f(0x24e)](_0x13ef0f(0x32d))):console['log'](_0x13ef0f(0x657)),console[_0x13ef0f(0x24e)](_0x13ef0f(0x10c));}async function _0x3a6768(_0xb642d2){const _0x1d823c=_0x2480b7,_0xe95c30=_0x9b04e6[_0x1d823c(0x738)](_0xb642d2['dbPath']);if(!_0xf79001['existsSync'](_0xe95c30)){console['log'](_0x1d823c(0x362)+_0xe95c30+_0x1d823c(0x3d5));return;}const _0x2be87d=require$$0$3,_0x35db9a=_0x2be87d['createInterface']({'input':process[_0x1d823c(0x40c)],'output':process['stdout']}),_0x5fd147=await new Promise(_0x407091=>_0x35db9a['question'](_0x1d823c(0x1de)+_0xe95c30+_0x1d823c(0x1f7),_0x407091));_0x35db9a[_0x1d823c(0x44f)](),console['log']('');if(_0x5fd147[_0x1d823c(0x471)]()['toLowerCase']()!==_0x1d823c(0x75d)){console[_0x1d823c(0x24e)](_0x1d823c(0x5d0));return;}let _0x150d06=null;try{_0x150d06=await _0x147d58(_0xe95c30,_0xb642d2,async _0xf7b834=>{const _0x59aeb2=_0x1d823c,_0x525b17=_0xf7b834[_0x59aeb2(0x5bc)],_0x422b14=_0x525b17?.['db']?.[_0x59aeb2(0x6a)](_0x59aeb2(0x4a1))??null,_0x22aab8=[];if(_0x525b17?.[_0x59aeb2(0x753)]('~licenses'))for(const {key:_0x3d1c77,value:_0x3828fb}of _0x525b17[_0x59aeb2(0x1c1)](_0x59aeb2(0x506))){_0x22aab8[_0x59aeb2(0x2f9)]({'key':_0x3d1c77,'value':_0x3828fb});}return{'identity':_0x422b14,'licenses':_0x22aab8};});}catch(_0x2bad55){console[_0x1d823c(0x24e)](_0x1d823c(0x62a)+_0x2bad55[_0x1d823c(0x5e6)]+')\x20—\x20they\x20will\x20NOT\x20be\x20preserved');}_0xf79001['rmSync'](_0xe95c30,{'recursive':!![],'force':!![]}),console[_0x1d823c(0x24e)](_0x1d823c(0xac)+_0xe95c30+_0x1d823c(0x739));if(_0x150d06&&(_0x150d06[_0x1d823c(0x411)]||_0x150d06[_0x1d823c(0x201)]['length']>0x0))try{await _0x147d58(_0xe95c30,_0xb642d2,async _0x138334=>{const _0x50e9b0=_0x1d823c,_0xa5d70c=_0x138334['_systemEnv'];_0x150d06[_0x50e9b0(0x411)]&&_0xa5d70c['db'][_0x50e9b0(0x16c)](_0x50e9b0(0x4a1),_0x150d06['identity']);if(_0x150d06[_0x50e9b0(0x201)]['length']>0x0){if(!_0xa5d70c[_0x50e9b0(0x753)]('~licenses'))await _0xa5d70c[_0x50e9b0(0xbc)](_0x50e9b0(0x506));for(const {key:_0x256f5e,value:_0x1cdeeb}of _0x150d06[_0x50e9b0(0x201)]){await _0xa5d70c[_0x50e9b0(0x463)](_0x50e9b0(0x506),_0x256f5e,_0x1cdeeb);}}});const _0x4f7692=[];if(_0x150d06['identity'])_0x4f7692['push'](_0x1d823c(0x525));if(_0x150d06[_0x1d823c(0x201)]['length']>0x0)_0x4f7692['push'](_0x150d06['licenses'][_0x1d823c(0x39d)]+_0x1d823c(0xa5));console['log'](_0x1d823c(0x2c2)+_0x4f7692[_0x1d823c(0x10b)](_0x1d823c(0x7e)));}catch(_0xcee68d){console[_0x1d823c(0x24e)](_0x1d823c(0x64f)+_0xcee68d[_0x1d823c(0x5e6)]);}}async function _0x147d58(_0x11cae4,_0x352f7b,_0x53287f){const _0x4b4128=_0x2480b7,_0x16fa33=require$$5$1,_0x426f20=new _0x16fa33(_0x11cae4,{'admin':![],'mcp':![],'timeMachine':![],'engines':![],'processors':![],'compaction':![],'_skipBootRuntime':!![],..._0x288e37(_0x352f7b)});await _0x426f20['open']();try{return await _0x53287f(_0x426f20);}finally{await _0x426f20[_0x4b4128(0x44f)]();}}async function _0x3f91a5(_0x4d88e4,_0xeebaa6){const _0x11d68a=_0x2480b7,_0x59a9e7=require$$5$1,_0x2e5410=_0x9b04e6[_0x11d68a(0x738)](_0xeebaa6[_0x11d68a(0x361)]);console['log'](_0x11d68a(0x329)+_0x2e5410+'…');const _0x26d374=new _0x59a9e7(_0x2e5410,_0x288e37(_0xeebaa6));await _0x26d374['open'](),console[_0x11d68a(0x24e)](_0x11d68a(0x282)+_0x4d88e4+'…');const {envs:_0x2e8809,blobs:_0x25e1cd,skipped:_0x5cd86e}=await _0x26d374[_0x11d68a(0x26b)][_0x11d68a(0x156)](_0x4d88e4);for(const _0x38abbe of _0x2e8809){const _0x487406=_0x38abbe[_0x11d68a(0x2bb)]>0x0?_0x11d68a(0x71c)+(_0x38abbe['sizeBefore']/0x400/0x400)['toFixed'](0x2)+_0x11d68a(0x11e)+(_0x38abbe[_0x11d68a(0x752)]/0x400/0x400)[_0x11d68a(0x72c)](0x2)+_0x11d68a(0x5e8):'';console[_0x11d68a(0x24e)]('\x20\x20✓\x20'+_0x38abbe[_0x11d68a(0x707)]+_0x11d68a(0x393)+_0x38abbe[_0x11d68a(0x306)]+_0x487406+(_0x38abbe['timeMachine']?_0x11d68a(0x45b):''));}if(_0x25e1cd[_0x11d68a(0x6ad)]>0x0)console['log']('\x20\x20✓\x20~blobs\x20\x20('+_0x25e1cd[_0x11d68a(0x6ad)]+_0x11d68a(0x2d3));for(const _0x1ee3d5 of _0x5cd86e)console[_0x11d68a(0x24e)](_0x11d68a(0x5cf)+_0x1ee3d5[_0x11d68a(0x707)]+_0x11d68a(0x768)+_0x1ee3d5[_0x11d68a(0x37c)]);await _0x26d374[_0x11d68a(0x44f)](),console[_0x11d68a(0x24e)](_0x11d68a(0x572));}async function _0x56e7f2(_0x36da9c,_0x4b7b34,_0x16a99b={}){const _0x1ace2e=_0x2480b7,{BACKUP_MANIFEST:_0x17308d}=requireOkdbMigrate(),_0x3f26f6=_0x9b04e6['resolve'](_0x4b7b34[_0x1ace2e(0x361)]),_0x2b5290=_0x9b04e6[_0x1ace2e(0x10b)](_0x36da9c,_0x17308d);if(!_0xf79001[_0x1ace2e(0x1c9)](_0x2b5290))throw new Error(_0x36da9c+'\x20is\x20not\x20a\x20complete\x20okdb\x20backup\x20(no\x20'+_0x17308d+')');const _0x25191d=JSON[_0x1ace2e(0xc3)](_0xf79001[_0x1ace2e(0x418)](_0x2b5290,'utf8')),_0x5c9c54=_0x9b04e6['relative'](_0x36da9c,_0x3f26f6);if(_0x5c9c54===''||!(_0x5c9c54[_0x1ace2e(0x42e)]('..')||_0x9b04e6['isAbsolute'](_0x5c9c54)))throw new Error(_0x1ace2e(0x5aa)+_0x3f26f6+'\x20is\x20inside\x20the\x20backup\x20'+_0x36da9c);if(_0xf79001[_0x1ace2e(0x1c9)](_0x3f26f6)&&_0xf79001[_0x1ace2e(0x1ed)](_0x3f26f6)[_0x1ace2e(0x39d)]>0x0)throw new Error(_0x1ace2e(0x5aa)+_0x3f26f6+_0x1ace2e(0x6b1));console[_0x1ace2e(0x24e)](_0x1ace2e(0x178)+_0x36da9c+_0x1ace2e(0x298)+_0x25191d[_0x1ace2e(0x5dc)]+',\x20'+_0x25191d[_0x1ace2e(0xc6)]+_0x1ace2e(0xa6)+_0x3f26f6+'…'),_0xf79001[_0x1ace2e(0x5ef)](_0x36da9c,_0x3f26f6,{'recursive':!![],'errorOnExist':!![]});for(const _0x25e035 of _0x25191d[_0x1ace2e(0x5cb)]??[]){console[_0x1ace2e(0x24e)](_0x1ace2e(0x5fa)+_0x25e035['name']+(_0x25e035[_0x1ace2e(0x121)]?_0x1ace2e(0x45b):'')),_0x25e035['outOfTree']&&_0x25e035[_0x1ace2e(0x7f)]&&_0xf79001[_0x1ace2e(0x1c9)](_0x25e035[_0x1ace2e(0x7f)])&&console[_0x1ace2e(0x24e)]('\x20\x20!\x20'+_0x25e035[_0x1ace2e(0x707)]+_0x1ace2e(0x620)+_0x25e035[_0x1ace2e(0x7f)]+_0x1ace2e(0x76f)+('store\x20will\x20open\x20THAT\x20directory,\x20not\x20the\x20copy\x20in\x20'+_0x25e035['dir']+_0x1ace2e(0x211)));}_0x16a99b[_0x1ace2e(0x70)]&&(require$$5$1[_0x1ace2e(0x1b9)](_0x3f26f6),console[_0x1ace2e(0x24e)](_0x1ace2e(0x17b))),console['log']('[okdb]\x20restore\x20complete\x20—\x20full-text\x20indexes\x20rebuild\x20on\x20first\x20open');}async function _0x484629(_0x31e3d9,_0x11e014,_0x3f0c41){const _0x4fcef4=_0x2480b7,_0x7fa83e=require$$5$1,_0x102a8c=_0x9b04e6[_0x4fcef4(0x738)](_0x11e014[_0x4fcef4(0x361)]),_0x1aef7e=_0x3f0c41['env']??'default',_0x5c465b=_0x3f0c41[_0x4fcef4(0x429)]?_0x3f0c41[_0x4fcef4(0x429)][_0x4fcef4(0x2aa)](',')[_0x4fcef4(0x757)](_0x4481ae=>_0x4481ae[_0x4fcef4(0x471)]()):null;console[_0x4fcef4(0x24e)]('[okdb]\x20opening\x20'+_0x102a8c+'…');const _0x487b59=new _0x7fa83e(_0x102a8c,_0x288e37(_0x11e014));await _0x487b59['open'](),console[_0x4fcef4(0x24e)]('[okdb]\x20exporting\x20env\x20\x22'+_0x1aef7e+_0x4fcef4(0x2d9)+_0x31e3d9+'…');const _0x1b0f61=await _0x487b59['migrate']['exportToFile'](_0x31e3d9,{'envName':_0x1aef7e,'types':_0x5c465b,'includeChanges':!!_0x3f0c41[_0x4fcef4(0x6b8)]});console['log']('[okdb]\x20exported\x20\x20types='+_0x1b0f61['types']+'\x20\x20records='+_0x1b0f61[_0x4fcef4(0x3ee)]+_0x4fcef4(0x1a0)+_0x1b0f61[_0x4fcef4(0x6b8)]);if(_0x3f0c41['blobs']){const _0x52e6e3=_0x9b04e6[_0x4fcef4(0x10b)](_0x9b04e6[_0x4fcef4(0x195)](_0x31e3d9),_0x4fcef4(0x37a));process['stdout'][_0x4fcef4(0xb6)]('[okdb]\x20exporting\x20blobs…');const {count:_0x2af539,bytes:_0xb0b328}=await _0x487b59[_0x4fcef4(0x26b)][_0x4fcef4(0x14f)](_0x52e6e3);console[_0x4fcef4(0x24e)](_0x4fcef4(0x1eb)+_0x52e6e3+_0x4fcef4(0x71c)+_0x2af539+_0x4fcef4(0x175)+(_0x2af539!==0x1?'s':'')+',\x20'+(_0xb0b328/0x400/0x400)['toFixed'](0x2)+_0x4fcef4(0x5e8));}await _0x487b59[_0x4fcef4(0x44f)](),console[_0x4fcef4(0x24e)](_0x4fcef4(0x26e));}async function _0x5b20b7(_0x44e204,_0x465d72,_0x41f00c){const _0x987c8b=_0x2480b7,_0x4b8442=require$$5$1,_0x42f769=_0x9b04e6['resolve'](_0x465d72[_0x987c8b(0x361)]),_0x71d620=_0x41f00c['env']??null,_0x1ec8eb=_0x41f00c['types']?_0x41f00c[_0x987c8b(0x429)]['split'](',')[_0x987c8b(0x757)](_0xb7cfeb=>_0xb7cfeb[_0x987c8b(0x471)]()):null,_0x148f6c=!!_0x41f00c['drop'];console[_0x987c8b(0x24e)](_0x987c8b(0x329)+_0x42f769+'…');const _0x32663f=new _0x4b8442(_0x42f769,_0x288e37(_0x465d72));await _0x32663f[_0x987c8b(0x1fd)](),console[_0x987c8b(0x24e)](_0x987c8b(0x88)+_0x44e204+'…');const _0x3c2f3a=await _0x32663f[_0x987c8b(0x26b)]['importFromFile'](_0x44e204,{'envName':_0x71d620,'types':_0x1ec8eb,'dropExisting':_0x148f6c,'includeChanges':!!_0x41f00c['changes'],'onProgress':({type:_0xe5cf78,count:_0x1227bb})=>{const _0x4bbcbc=_0x987c8b;process[_0x4bbcbc(0x11c)][_0x4bbcbc(0xb6)](_0x4bbcbc(0x4ab)+_0xe5cf78+':\x20'+_0x1227bb+_0x4bbcbc(0x406));}});process[_0x987c8b(0x11c)][_0x987c8b(0xb6)]('\x0a'),console[_0x987c8b(0x24e)](_0x987c8b(0x437)+_0x3c2f3a[_0x987c8b(0x429)]+'\x20\x20records='+_0x3c2f3a[_0x987c8b(0x3ee)]+_0x987c8b(0x1a0)+_0x3c2f3a['changes']);if(_0x41f00c[_0x987c8b(0x37a)]){const _0x202d4c=_0x9b04e6[_0x987c8b(0x10b)](_0x9b04e6[_0x987c8b(0x195)](_0x44e204),_0x987c8b(0x37a));if(_0xf79001[_0x987c8b(0x1c9)](_0x202d4c)){const {imported:_0x34625d,skipped:_0x301b98}=await _0x32663f[_0x987c8b(0x26b)][_0x987c8b(0x2d0)](_0x202d4c);console[_0x987c8b(0x24e)](_0x987c8b(0x151)+_0x34625d+_0x987c8b(0x333)+_0x301b98);}}await _0x32663f[_0x987c8b(0x44f)](),console['log'](_0x987c8b(0x3c0));}async function _0x37089e(_0x2b29da,_0x22acf3){const _0x3602a1=_0x2480b7;_0x22acf3[_0x3602a1(0x54b)]&&!_0x22acf3[_0x3602a1(0x707)]&&(console['error'](_0x3602a1(0x50b)),process['exit'](0x1));const _0x528b8e=_0x22acf3[_0x3602a1(0x1f4)]?_0x22acf3[_0x3602a1(0x1f4)][_0x3602a1(0x2aa)](',')[_0x3602a1(0x757)](_0x254481=>_0x254481['trim']())['filter'](Boolean):[];let _0x5c9fe3={};if(_0x22acf3[_0x3602a1(0x660)])try{_0x5c9fe3=JSON[_0x3602a1(0xc3)](_0x22acf3[_0x3602a1(0x660)]);if(typeof _0x5c9fe3!=='object'||Array[_0x3602a1(0x339)](_0x5c9fe3)||_0x5c9fe3===null)throw new Error();}catch{console['error'](_0x3602a1(0x161)),process[_0x3602a1(0x4e7)](0x1);}const _0x5383c2=require$$5$1,{randomToken:_0x43fde5,hashToken:_0xec2973,hashPassword:_0x38d3f5}=requireOkdbAuthTokens(),_0x122a32=require$$2$1,_0x3e7d65=_0x9b04e6[_0x3602a1(0x738)](_0x2b29da['dbPath']),_0x20248b=new _0x5383c2(_0x3e7d65,_0x288e37(_0x2b29da));await _0x20248b[_0x3602a1(0x1fd)]();try{await _0x20248b['auth']['_ensureTokensType']();if(_0x22acf3[_0x3602a1(0x707)]){const _0x1fca4b=await _0x20248b[_0x3602a1(0x8a)][_0x3602a1(0x38e)](_0x22acf3[_0x3602a1(0x707)]);_0x1fca4b&&(console[_0x3602a1(0x492)](_0x3602a1(0x458)+_0x22acf3[_0x3602a1(0x707)]+_0x3602a1(0xb0)),process[_0x3602a1(0x4e7)](0x1));}const _0x48d87d=_0x43fde5(0x20),_0x404414=_0xec2973(_0x48d87d),_0x44d59e=_0x22acf3[_0x3602a1(0x54b)]?await _0x38d3f5(_0x22acf3[_0x3602a1(0x54b)]):null,_0x1de465=_0x122a32[_0x3602a1(0x395)](),_0x6e854b={'tokenHash':_0x404414,'name':_0x22acf3['name']||null,'passwordHash':_0x44d59e,'label':_0x22acf3[_0x3602a1(0x313)]||null,'permissions':_0x528b8e,'grants':_0x5c9fe3,'createdAt':Date['now'](),'lastUsedAt':null},_0x40481d=_0x22acf3[_0x3602a1(0x604)]?{'ttl':Number(_0x22acf3[_0x3602a1(0x604)])}:undefined;await _0x20248b[_0x3602a1(0x5bc)][_0x3602a1(0x463)](_0x3602a1(0x52c),_0x1de465,_0x6e854b,_0x40481d),console[_0x3602a1(0x24e)](_0x3602a1(0x501)),console['log'](_0x3602a1(0x52f)+_0x1de465),console[_0x3602a1(0x24e)](_0x3602a1(0x28b)+(_0x22acf3[_0x3602a1(0x707)]||_0x3602a1(0x21a))),console[_0x3602a1(0x24e)](_0x3602a1(0x527)+(_0x22acf3['label']||_0x3602a1(0x21a))),console[_0x3602a1(0x24e)](_0x3602a1(0x1f2)+(_0x528b8e['join'](',\x20')||_0x3602a1(0x1b5))),console[_0x3602a1(0x24e)](_0x3602a1(0x77c)),console[_0x3602a1(0x24e)](_0x3602a1(0x75b)+_0x48d87d+'\x0a');}finally{await _0x20248b['close']();}}async function _0x442469(_0x201853){const _0x527a3d=_0x2480b7,_0x55a5c7=require$$5$1,_0x381422=_0x9b04e6[_0x527a3d(0x738)](_0x201853[_0x527a3d(0x361)]),_0x2988c1=new _0x55a5c7(_0x381422,_0x288e37(_0x201853));await _0x2988c1[_0x527a3d(0x1fd)]();try{const _0x3d012f=_0x2988c1[_0x527a3d(0x5bc)];if(!_0x3d012f||!_0x3d012f[_0x527a3d(0x753)](_0x527a3d(0x52c))){console[_0x527a3d(0x24e)](_0x527a3d(0x5da));return;}const _0x235174=[];for(const {key:_0x5243e7,value:_0x180b01}of _0x3d012f['getRange'](_0x527a3d(0x52c))){_0x235174[_0x527a3d(0x2f9)]({'id':_0x5243e7,'name':_0x180b01[_0x527a3d(0x707)]||_0x527a3d(0x21a),'label':_0x180b01[_0x527a3d(0x313)]||_0x527a3d(0x21a),'permissions':Array['isArray'](_0x180b01[_0x527a3d(0x1f4)])?_0x180b01[_0x527a3d(0x1f4)][_0x527a3d(0x10b)](','):'','created':_0x180b01[_0x527a3d(0xc6)]?new Date(_0x180b01[_0x527a3d(0xc6)])['toISOString']()[_0x527a3d(0x13a)](0x0,0xa):''});}if(_0x235174[_0x527a3d(0x39d)]===0x0){console['log'](_0x527a3d(0x5da));return;}const _0x1925e9=!process['stdout']['columns']||process[_0x527a3d(0x11c)][_0x527a3d(0x1fe)]>=0x64,_0x4deb4f=_0x1925e9?0x24:0xa,_0x9ea3db=['ID'['padEnd'](_0x4deb4f),'NAME'['padEnd'](0x10),_0x527a3d(0x20f)[_0x527a3d(0x485)](0x14),'PERMISSIONS'['padEnd'](0x14),_0x527a3d(0x389)][_0x527a3d(0x10b)]('\x20\x20');console[_0x527a3d(0x24e)]('\x0a'+_0x9ea3db),console[_0x527a3d(0x24e)]('-'[_0x527a3d(0x4d9)](_0x9ea3db['length']));for(const _0x5a12ab of _0x235174){const _0x4d9788=_0x1925e9?_0x5a12ab['id']:_0x5a12ab['id'][_0x527a3d(0x13a)](0x0,0x8)+'…';console[_0x527a3d(0x24e)]([_0x4d9788[_0x527a3d(0x485)](_0x4deb4f),_0x5a12ab['name']['slice'](0x0,0x10)[_0x527a3d(0x485)](0x10),_0x5a12ab['label'][_0x527a3d(0x13a)](0x0,0x14)[_0x527a3d(0x485)](0x14),_0x5a12ab[_0x527a3d(0x1f4)][_0x527a3d(0x13a)](0x0,0x14)['padEnd'](0x14),_0x5a12ab[_0x527a3d(0x3a4)]][_0x527a3d(0x10b)]('\x20\x20'));}console[_0x527a3d(0x24e)]('');}finally{await _0x2988c1[_0x527a3d(0x44f)]();}}async function _0xeb5a1e(_0xcad143,_0x4af2d1){const _0x1dd610=_0x2480b7;!_0xcad143&&(console[_0x1dd610(0x492)](_0x1dd610(0x47a)),process[_0x1dd610(0x4e7)](0x1));const _0x58b4c5=require$$5$1,_0x816b56=_0x9b04e6[_0x1dd610(0x738)](_0x4af2d1[_0x1dd610(0x361)]),_0x3ecdf6=new _0x58b4c5(_0x816b56,_0x288e37(_0x4af2d1));await _0x3ecdf6[_0x1dd610(0x1fd)]();try{const _0x5ccde2=_0x3ecdf6[_0x1dd610(0x5bc)];(!_0x5ccde2||!_0x5ccde2['hasType'](_0x1dd610(0x52c)))&&(console[_0x1dd610(0x492)](_0x1dd610(0x64b)+_0xcad143+'\x22'),process['exit'](0x1));let _0x4e8127=null,_0x1bbb36=null;const _0x123705=_0x5ccde2[_0x1dd610(0x6a)]('~tokens',_0xcad143);if(_0x123705)_0x4e8127=_0xcad143,_0x1bbb36=_0x123705;else{const _0x588534=[];for(const {key:_0x54f237,value:_0x289d21}of _0x5ccde2[_0x1dd610(0x1c1)](_0x1dd610(0x52c))){if(_0x54f237[_0x1dd610(0x42e)](_0xcad143))_0x588534['push']({'key':_0x54f237,'value':_0x289d21});}_0x588534[_0x1dd610(0x39d)]===0x0&&(console['error']('[okdb]\x20error:\x20no\x20token\x20with\x20id\x20\x22'+_0xcad143+'\x22'),process['exit'](0x1));if(_0x588534[_0x1dd610(0x39d)]>0x1){console[_0x1dd610(0x492)](_0x1dd610(0x36b)+_0xcad143+_0x1dd610(0x1df)+_0x588534[_0x1dd610(0x39d)]+_0x1dd610(0x36e));for(const _0x3cea32 of _0x588534){console['error']('\x20\x20'+_0x3cea32[_0x1dd610(0x466)]+_0x1dd610(0x694)+(_0x3cea32[_0x1dd610(0x101)][_0x1dd610(0x707)]||_0x1dd610(0x21a))+')');}process[_0x1dd610(0x4e7)](0x1);}_0x4e8127=_0x588534[0x0][_0x1dd610(0x466)],_0x1bbb36=_0x588534[0x0]['value'];}await _0x5ccde2[_0x1dd610(0x34e)](_0x1dd610(0x52c),_0x4e8127),console[_0x1dd610(0x24e)](_0x1dd610(0x39f)+_0x4e8127+_0x1dd610(0x694)+(_0x1bbb36[_0x1dd610(0x707)]||_0x1dd610(0x21a))+_0x1dd610(0x4c6)+(_0x1bbb36['label']||_0x1dd610(0x21a))+')');}finally{await _0x3ecdf6[_0x1dd610(0x44f)]();}}function _0xbb4946(_0x3e079e,_0x385987){const _0x2f0c6d=_0x2480b7;if(!_0x3e079e[_0x2f0c6d(0x552)])return _0x2f0c6d(0x202);const _0xc860c7=_0x3e079e[_0x2f0c6d(0x57a)];if(!_0xc860c7)return _0x2f0c6d(0x1b3);if(_0x385987>_0xc860c7)return _0x2f0c6d(0x55a);return'active';}function _0x3b1ae4(_0x508391){const _0x5aae09=_0x2480b7;if(!_0x508391||typeof _0x508391!==_0x5aae09(0x5d4))return'';const _0x4cc522=Object['entries'](_0x508391)[_0x5aae09(0x293)](([,_0x4f1575])=>_0x4f1575)[_0x5aae09(0x757)](([_0x36bc79])=>_0x36bc79);if(_0x4cc522[_0x5aae09(0x39d)]===0x0)return _0x5aae09(0x1b5);if(_0x4cc522[_0x5aae09(0x39d)]<=0x3)return _0x4cc522[_0x5aae09(0x10b)]('\x20');return _0x4cc522['slice'](0x0,0x3)['join']('\x20')+('\x20+'+(_0x4cc522[_0x5aae09(0x39d)]-0x3));}async function _0x2011ca(_0x1177fd){const _0x27d522=_0x2480b7,_0x1a2ee3=require$$5$1,_0x3a3516=requireOkdbLicenseCodec(),{_C:_0x1e2709}=requireOkdbLicense(),_0x43d121=_0x9b04e6[_0x27d522(0x738)](_0x1177fd[_0x27d522(0x361)]),_0x13eb17=new _0x1a2ee3(_0x43d121,_0x288e37(_0x1177fd));await _0x13eb17['open']();try{const _0x25d0da=_0x13eb17[_0x27d522(0x5bc)],_0x24f1b6=_0x25d0da?.['db']?.[_0x27d522(0x6a)]?.(_0x27d522(0x5b9))??0x0,_0x2cd274=[..._0x13eb17[_0x27d522(0x64c)][_0x27d522(0x6d8)]()][_0x27d522(0x293)](_0x590a98=>!_0x590a98['startsWith']('~'))[_0x27d522(0x39d)],_0x1c23e5=_0x13eb17['_license']?.[_0x27d522(0x12d)];if(_0x1c23e5){const _0x9a1363=_0x1c23e5[_0x27d522(0x678)]===!![],_0x2711d1=_0x9a1363?_0x27d522(0x575):_0x13eb17[_0x27d522(0x511)]['active']?.[_0x27d522(0x22b)]||_0x27d522(0x337);console['log'](''),console[_0x27d522(0x24e)](_0x27d522(0x639)+_0x2711d1);const _0xfc2d8e=_0x1c23e5[_0x27d522(0x260)]||{};if(_0xfc2d8e['maxWrites']){const _0x1799d5=Math[_0x27d522(0x139)](_0x24f1b6/_0xfc2d8e[_0x27d522(0x425)]*0x64);console[_0x27d522(0x24e)](_0x27d522(0x625)+_0x24f1b6[_0x27d522(0xbf)]()+'\x20/\x20'+_0xfc2d8e[_0x27d522(0x425)][_0x27d522(0xbf)]()+'\x20\x20('+_0x1799d5+'%)');}else console['log'](_0x27d522(0x625)+_0x24f1b6[_0x27d522(0xbf)]());_0xfc2d8e[_0x27d522(0x5cb)]?console[_0x27d522(0x24e)]('\x20\x20Envs:\x20\x20\x20\x20'+_0x2cd274+_0x27d522(0x5fb)+_0xfc2d8e[_0x27d522(0x5cb)]):console[_0x27d522(0x24e)](_0x27d522(0x767)+_0x2cd274),_0x1e2709?.[_0x27d522(0x4e0)]&&console[_0x27d522(0x24e)](_0x27d522(0x1ca)+_0x1e2709[_0x27d522(0x4e0)]+'\x20\x20(licenses\x20must\x20be\x20signed\x20by\x20the\x20matching\x20private\x20key)');}if(!_0x25d0da||!_0x25d0da[_0x27d522(0x753)](_0x27d522(0x506))){console[_0x27d522(0x24e)](''),console[_0x27d522(0x24e)](_0x27d522(0x5f7)),console[_0x27d522(0x24e)]('');return;}const _0x33cd56=[],_0x47d1cf=Date['now'](),_0x4d0771=_0x13eb17['id'],_0x3627d3=_0x27d522(0x157);for(const {key:_0x9fa282,value:_0x1cdf4a}of _0x25d0da['getRange'](_0x27d522(0x506))){const _0x5c693a=_0x1cdf4a[_0x27d522(0x2f8)]?Buffer[_0x27d522(0x690)](_0x1cdf4a[_0x27d522(0x2f8)],_0x27d522(0x31b)):Buffer[_0x27d522(0x2b0)](0x8);let _0x42abe7='';try{_0x42abe7=_0x3a3516[_0x27d522(0x51b)](_0x4d0771,_0x5c693a,_0x3627d3)[_0x27d522(0x4b0)];}catch{}_0x33cd56[_0x27d522(0x2f9)]({'id':_0x9fa282,'licensee':_0x1cdf4a[_0x27d522(0x22b)]||'','expires':_0x1cdf4a[_0x27d522(0x57a)]?new Date(_0x1cdf4a[_0x27d522(0x57a)])[_0x27d522(0x261)]()[_0x27d522(0x13a)](0x0,0xa):'','features':_0x3b1ae4(_0x1cdf4a[_0x27d522(0x5de)]),'pin':_0x42abe7,'status':_0xbb4946(_0x1cdf4a,_0x47d1cf)});}if(_0x33cd56[_0x27d522(0x39d)]===0x0){console[_0x27d522(0x24e)](''),console[_0x27d522(0x24e)]('\x20\x20No\x20licenses\x20stored.\x20Use\x20`okdb\x20license\x20<blob>`\x20to\x20add\x20one.'),console[_0x27d522(0x24e)]('');return;}const _0x1e53ec=['\x20\x20'+'ID'[_0x27d522(0x485)](0xe),_0x27d522(0x256)[_0x27d522(0x485)](0xe),_0x27d522(0x491)[_0x27d522(0x485)](0xc),'FEATURES'[_0x27d522(0x485)](0x1e),_0x27d522(0x617)['padEnd'](0xa),_0x27d522(0x86)][_0x27d522(0x10b)]('\x20');console[_0x27d522(0x24e)]('\x0a'+_0x1e53ec);for(const _0x4c8c6d of _0x33cd56){const _0x198d7a=_0x4c8c6d['id']['slice'](0x0,0x8)+'\u2026';console['log'](['\x20\x20'+_0x198d7a['padEnd'](0xe),_0x4c8c6d[_0x27d522(0x22b)][_0x27d522(0x13a)](0x0,0xe)[_0x27d522(0x485)](0xe),_0x4c8c6d['expires'][_0x27d522(0x485)](0xc),_0x4c8c6d[_0x27d522(0x5de)]['slice'](0x0,0x1e)[_0x27d522(0x485)](0x1e),_0x4c8c6d[_0x27d522(0x4b0)][_0x27d522(0x485)](0xa),_0x4c8c6d[_0x27d522(0x170)]][_0x27d522(0x10b)]('\x20'));}console[_0x27d522(0x24e)]('');}finally{await _0x13eb17[_0x27d522(0x44f)]();}}async function _0x3a54e1(_0x358feb,_0x825d30){const _0x17dbb4=_0x2480b7,_0x2e3669=require$$5$1,_0x3c03ab=requireOkdbLicenseCodec();let _0x13e84b=_0x358feb;(_0x3c03ab[_0x17dbb4(0x187)](_0x358feb)==='path'||_0xf79001['existsSync'](_0x358feb)&&_0xf79001['statSync'](_0x358feb)[_0x17dbb4(0xed)]())&&(_0x13e84b=_0xf79001[_0x17dbb4(0x418)](_0x358feb,_0x17dbb4(0x320))[_0x17dbb4(0x471)]());const _0x589fa1=_0x9b04e6[_0x17dbb4(0x738)](_0x825d30[_0x17dbb4(0x361)]),_0x1b2353=new _0x2e3669(_0x589fa1,_0x288e37(_0x825d30));await _0x1b2353[_0x17dbb4(0x1fd)]();try{let _0x5939df;try{_0x5939df=await _0x1b2353['licenses'][_0x17dbb4(0x3e9)]({'blob':_0x13e84b});}catch(_0x262055){console['error'](_0x17dbb4(0x53a)+_0x262055[_0x17dbb4(0x5e6)]),process[_0x17dbb4(0x4e7)](0x1);}const _0x8f45ff=_0x5939df[_0x17dbb4(0x4b0)]||'',_0x235ff6=Object[_0x17dbb4(0x61d)](_0x5939df[_0x17dbb4(0x5de)]||{})[_0x17dbb4(0x293)](([,_0x4eb613])=>_0x4eb613)['map'](([_0x4f37e0])=>_0x4f37e0),_0xb929cf=_0x5939df['limits']||{},_0x52e0c1=[_0xb929cf[_0x17dbb4(0x5cb)]?_0x17dbb4(0x20c)+_0xb929cf[_0x17dbb4(0x5cb)]:null,_0xb929cf['typesPerEnv']?_0x17dbb4(0x48b)+_0xb929cf[_0x17dbb4(0x490)]:null,_0xb929cf[_0x17dbb4(0x6fa)]?_0x17dbb4(0x6f9)+_0xb929cf['syncPeers']:null,_0xb929cf['maxWrites']?_0x17dbb4(0x4f8)+_0xb929cf[_0x17dbb4(0x425)]['toLocaleString']():null][_0x17dbb4(0x293)](Boolean)['join']('\x20\x20'),_0x47eb3a=_0x5939df[_0x17dbb4(0x66f)]!=='standard';console[_0x17dbb4(0x24e)](_0x5939df['changed']?_0x17dbb4(0x732):_0x17dbb4(0x153)),console[_0x17dbb4(0x24e)](_0x17dbb4(0x338)+_0x5939df['id']),console['log'](_0x17dbb4(0x761)+_0x5939df[_0x17dbb4(0x22b)]),console[_0x17dbb4(0x24e)](_0x17dbb4(0x1dd)+(_0x5939df[_0x17dbb4(0x57a)]?new Date(_0x5939df[_0x17dbb4(0x57a)])[_0x17dbb4(0x261)]()['slice'](0x0,0xa):_0x17dbb4(0x595))),console[_0x17dbb4(0x24e)](_0x17dbb4(0x29b)+(_0x235ff6[_0x17dbb4(0x10b)](',\x20')||_0x17dbb4(0x1b5)));if(_0x52e0c1)console[_0x17dbb4(0x24e)](_0x17dbb4(0x6d1)+_0x52e0c1);if(_0x47eb3a)console[_0x17dbb4(0x24e)](_0x17dbb4(0x27f)+_0x5939df[_0x17dbb4(0x66f)]+_0x17dbb4(0x3a8)),console[_0x17dbb4(0x24e)]('');else!_0x5939df['needsActivation']?(console['log'](_0x17dbb4(0x508)+_0x5939df[_0x17dbb4(0x170)]),console['log']('')):(console[_0x17dbb4(0x24e)](_0x17dbb4(0x4d3)+_0x8f45ff),console[_0x17dbb4(0x24e)]('\x20\x20\x20\x20status:\x20\x20\x20\x20pending\x20activation'),console[_0x17dbb4(0x24e)](''),console[_0x17dbb4(0x24e)](_0x17dbb4(0x5fe)),console[_0x17dbb4(0x24e)](_0x17dbb4(0x6db)+_0x8f45ff+_0x17dbb4(0x5eb)),console['log'](_0x17dbb4(0x23c)),console[_0x17dbb4(0x24e)](_0x17dbb4(0x20b)),console[_0x17dbb4(0x24e)](''));}finally{await _0x1b2353[_0x17dbb4(0x44f)]();}}async function _0x532735(_0x4dd151,_0x5cad10){const _0x287fb3=_0x2480b7,_0x1a518c=require$$5$1,_0x1e2c17=_0x9b04e6[_0x287fb3(0x738)](_0x5cad10['dbPath']),_0x188a44=new _0x1a518c(_0x1e2c17,_0x288e37(_0x5cad10));await _0x188a44['open']();try{let _0x532a34;try{_0x532a34=await _0x188a44[_0x287fb3(0x201)]['activate'](_0x4dd151);}catch(_0x42deb3){console[_0x287fb3(0x492)](_0x287fb3(0x53a)+_0x42deb3[_0x287fb3(0x5e6)]),console[_0x287fb3(0x492)](''),console[_0x287fb3(0x492)](_0x287fb3(0x3e2)),console[_0x287fb3(0x492)]('\x20\x20\x20\x20-\x20The\x20license\x20blob\x20has\x20not\x20been\x20added\x20yet\x20—\x20run\x20`okdb\x20license\x20<blob>`\x20first.'),console[_0x287fb3(0x492)](_0x287fb3(0x48e)),console[_0x287fb3(0x492)](_0x287fb3(0x1a9)),console['error'](''),process[_0x287fb3(0x4e7)](0x1);}console[_0x287fb3(0x24e)](_0x287fb3(0x666)),console['log'](_0x287fb3(0x338)+_0x532a34['id']),console[_0x287fb3(0x24e)](_0x287fb3(0x761)+_0x532a34['licensee']),console[_0x287fb3(0x24e)]('\x20\x20\x20\x20expires:\x20\x20\x20'+(_0x532a34[_0x287fb3(0x57a)]?new Date(_0x532a34[_0x287fb3(0x57a)])[_0x287fb3(0x261)]()[_0x287fb3(0x13a)](0x0,0xa):_0x287fb3(0x595))),console['log'](_0x287fb3(0x1b2)),console['log']('');}finally{await _0x188a44[_0x287fb3(0x44f)]();}}async function _0x43b83b(_0x284c53,_0x382aa4){const _0x5b9e5c=_0x2480b7;!_0x284c53&&(console['error'](_0x5b9e5c(0x669)),process[_0x5b9e5c(0x4e7)](0x1));const _0xb3bf13=require$$5$1,_0x4c6e5d=requireOkdbLicenseCodec(),_0x73b2d9=_0x9b04e6[_0x5b9e5c(0x738)](_0x382aa4[_0x5b9e5c(0x361)]),_0x83bea1=new _0xb3bf13(_0x73b2d9,_0x288e37(_0x382aa4));await _0x83bea1['open']();try{const _0x12a13f=_0x83bea1[_0x5b9e5c(0x5bc)];(!_0x12a13f||!_0x12a13f[_0x5b9e5c(0x753)](_0x5b9e5c(0x506)))&&(console[_0x5b9e5c(0x492)]('[okdb]\x20error:\x20no\x20license\x20with\x20id\x20\x22'+_0x284c53+'\x22'),process['exit'](0x1));let _0x1ad261=null,_0x3aac17=null;const _0x39b770=_0x12a13f['get'](_0x5b9e5c(0x506),_0x284c53);if(_0x39b770)_0x1ad261=_0x284c53,_0x3aac17=_0x39b770;else{const _0x6f542b=[];for(const {key:_0x10e54e,value:_0x27fc93}of _0x12a13f[_0x5b9e5c(0x1c1)](_0x5b9e5c(0x506))){if(_0x10e54e[_0x5b9e5c(0x42e)](_0x284c53))_0x6f542b[_0x5b9e5c(0x2f9)]({'key':_0x10e54e,'value':_0x27fc93});}_0x6f542b[_0x5b9e5c(0x39d)]===0x0&&(console[_0x5b9e5c(0x492)](_0x5b9e5c(0x2e0)+_0x284c53+'\x22'),process[_0x5b9e5c(0x4e7)](0x1)),_0x6f542b[_0x5b9e5c(0x39d)]>0x1&&(console['error']('[okdb]\x20error:\x20ambiguous\x20prefix\x20\x22'+_0x284c53+_0x5b9e5c(0x1df)+_0x6f542b[_0x5b9e5c(0x39d)]+_0x5b9e5c(0x287)),process['exit'](0x1)),_0x1ad261=_0x6f542b[0x0][_0x5b9e5c(0x466)],_0x3aac17=_0x6f542b[0x0][_0x5b9e5c(0x101)];}const _0x54a7a2=Date[_0x5b9e5c(0x127)](),_0x250700=_0xbb4946(_0x3aac17,_0x54a7a2),_0x247c01=_0x83bea1['id'],_0x59beba=_0x5b9e5c(0x157);let _0x570514='';try{const _0x54ad44=Buffer[_0x5b9e5c(0x690)](_0x3aac17[_0x5b9e5c(0x2f8)],_0x5b9e5c(0x31b));_0x570514=_0x4c6e5d[_0x5b9e5c(0x51b)](_0x247c01,_0x54ad44,_0x59beba)[_0x5b9e5c(0x4b0)];}catch{}const _0x38d037=_0x3aac17[_0x5b9e5c(0x5de)]?Object[_0x5b9e5c(0x61d)](_0x3aac17['features'])['filter'](([,_0x3814ef])=>_0x3814ef)['map'](([_0x368a6a])=>_0x368a6a):[],_0x137e03=_0x3aac17[_0x5b9e5c(0x260)]||{},_0x204892=_0x12a13f?.['db']?.[_0x5b9e5c(0x6a)]?.('__writeCounter')??0x0,_0x9dd941=[..._0x83bea1[_0x5b9e5c(0x64c)]['keys']()][_0x5b9e5c(0x293)](_0x6ccb37=>!_0x6ccb37[_0x5b9e5c(0x42e)]('~'))['length'];console[_0x5b9e5c(0x24e)]('\x0a\x20\x20License\x20details:'),console[_0x5b9e5c(0x24e)](_0x5b9e5c(0x338)+_0x1ad261),console[_0x5b9e5c(0x24e)](_0x5b9e5c(0x761)+(_0x3aac17['licensee']||'')),console[_0x5b9e5c(0x24e)](_0x5b9e5c(0x1dd)+(_0x3aac17['expiresAt']?new Date(_0x3aac17[_0x5b9e5c(0x57a)])[_0x5b9e5c(0x261)]()[_0x5b9e5c(0x13a)](0x0,0xa):'')),console['log'](_0x5b9e5c(0x29b)+(_0x38d037[_0x5b9e5c(0x10b)](',\x20')||'(none)')),console[_0x5b9e5c(0x24e)]('\x20\x20\x20\x20pin:\x20\x20\x20\x20\x20\x20\x20'+_0x570514),console[_0x5b9e5c(0x24e)]('\x20\x20\x20\x20status:\x20\x20\x20\x20'+_0x250700),console['log'](_0x5b9e5c(0x726)+new Date(_0x3aac17['addedAt'])[_0x5b9e5c(0x261)]());if(_0x250700===_0x5b9e5c(0x1b3)){console['log'](''),console[_0x5b9e5c(0x24e)](_0x5b9e5c(0x134));if(_0x137e03['maxWrites']){const _0xf2c85b=Math[_0x5b9e5c(0x139)](_0x204892/_0x137e03[_0x5b9e5c(0x425)]*0x64);console[_0x5b9e5c(0x24e)](_0x5b9e5c(0x489)+_0x204892[_0x5b9e5c(0xbf)]()+'\x20/\x20'+_0x137e03[_0x5b9e5c(0x425)][_0x5b9e5c(0xbf)]()+_0x5b9e5c(0x71c)+_0xf2c85b+'%)');}else console['log'](_0x5b9e5c(0x489)+_0x204892[_0x5b9e5c(0xbf)]()+_0x5b9e5c(0x536));_0x137e03['envs']?console[_0x5b9e5c(0x24e)](_0x5b9e5c(0x350)+_0x9dd941+_0x5b9e5c(0x5fb)+_0x137e03['envs']):console['log']('\x20\x20\x20\x20envs:\x20\x20\x20\x20\x20\x20'+_0x9dd941+_0x5b9e5c(0x536));}console[_0x5b9e5c(0x24e)]('');}finally{await _0x83bea1[_0x5b9e5c(0x44f)]();}}async function _0x515c3d(_0x154d1b,_0x2a6d30){const _0x5f13a0=_0x2480b7;!_0x154d1b&&(console[_0x5f13a0(0x492)]('[okdb]\x20error:\x20remove\x20requires\x20an\x20id\x20argument'),process[_0x5f13a0(0x4e7)](0x1));const _0xdd87ad=require$$5$1,_0x20f4a8=_0x9b04e6[_0x5f13a0(0x738)](_0x2a6d30[_0x5f13a0(0x361)]),_0x4e4da1=new _0xdd87ad(_0x20f4a8,_0x288e37(_0x2a6d30));await _0x4e4da1[_0x5f13a0(0x1fd)]();try{const _0xeb8372=_0x4e4da1[_0x5f13a0(0x5bc)];(!_0xeb8372||!_0xeb8372[_0x5f13a0(0x753)]('~licenses'))&&(console[_0x5f13a0(0x492)](_0x5f13a0(0x2e0)+_0x154d1b+'\x22'),process[_0x5f13a0(0x4e7)](0x1));let _0x4e52b3=null,_0x3ee159=null;const _0x43324a=_0xeb8372[_0x5f13a0(0x6a)]('~licenses',_0x154d1b);if(_0x43324a)_0x4e52b3=_0x154d1b,_0x3ee159=_0x43324a;else{const _0x207450=[];for(const {key:_0x135b70,value:_0x7f431a}of _0xeb8372[_0x5f13a0(0x1c1)]('~licenses')){if(_0x135b70['startsWith'](_0x154d1b))_0x207450[_0x5f13a0(0x2f9)]({'key':_0x135b70,'value':_0x7f431a});}_0x207450['length']===0x0&&(console['error']('[okdb]\x20error:\x20no\x20license\x20with\x20id\x20\x22'+_0x154d1b+'\x22'),process[_0x5f13a0(0x4e7)](0x1)),_0x207450[_0x5f13a0(0x39d)]>0x1&&(console['error']('[okdb]\x20error:\x20ambiguous\x20prefix\x20\x22'+_0x154d1b+_0x5f13a0(0x1df)+_0x207450[_0x5f13a0(0x39d)]+_0x5f13a0(0x287)),process[_0x5f13a0(0x4e7)](0x1)),_0x4e52b3=_0x207450[0x0][_0x5f13a0(0x466)],_0x3ee159=_0x207450[0x0]['value'];}await _0xeb8372['remove']('~licenses',_0x4e52b3),console[_0x5f13a0(0x24e)](_0x5f13a0(0x2e5)+_0x4e52b3+_0x5f13a0(0x2d4)+(_0x3ee159[_0x5f13a0(0x22b)]||_0x5f13a0(0x21a))+')');}finally{await _0x4e4da1[_0x5f13a0(0x44f)]();}}async function _0x4840da(_0x497b73,_0x388206,_0x264e93){const _0x4b20c8=_0x2480b7;!_0x497b73&&(console[_0x4b20c8(0x492)](_0x4b20c8(0x704)),process[_0x4b20c8(0x4e7)](0x1));!_0x264e93[_0x4b20c8(0x129)]&&!(_0x264e93[_0x4b20c8(0x573)]&&_0x264e93[_0x4b20c8(0x54b)])&&(console[_0x4b20c8(0x492)]('[okdb]\x20error:\x20join\x20requires\x20credentials.\x20Provide\x20--token\x20<t>\x20or\x20--username\x20<u>\x20--password\x20<p>'),process[_0x4b20c8(0x4e7)](0x1));const _0x35aecf=_0x264e93['selfAddress']||_0x388206['sync']?.[_0x4b20c8(0x48a)];!_0x35aecf&&(console[_0x4b20c8(0x492)](_0x4b20c8(0x6c2)+_0x4b20c8(0x4dd)+'\x20\x20Or\x20set\x20sync.address\x20in\x20.kdbconfig'),process['exit'](0x1));const _0xea4721=require$$5$1,_0x3e3ba0=new _0xea4721(_0x388206[_0x4b20c8(0x361)],{'sync':{'address':_0x35aecf,'auto_reconcile':![]}});await _0x3e3ba0[_0x4b20c8(0x1fd)]();try{const _0x2cbbb0=_0x3e3ba0[_0x4b20c8(0x5bc)];if(_0x2cbbb0&&_0x2cbbb0[_0x4b20c8(0x753)]('~tokens')){let _0x2c79a8=![];for(const _0x3fab63 of _0x2cbbb0[_0x4b20c8(0x1c1)](_0x4b20c8(0x52c))){_0x2c79a8=!![];break;}_0x2c79a8&&console[_0x4b20c8(0x24e)](_0x4b20c8(0x652)+_0x4b20c8(0x6a9));}console[_0x4b20c8(0x24e)]('\x0a\x20\x20Joining\x20cluster\x20at\x20'+_0x497b73+'…'),await _0x3e3ba0[_0x4b20c8(0x2ae)][_0x4b20c8(0x10b)](_0x497b73['replace'](/\/+$/,''),{'token':_0x264e93[_0x4b20c8(0x129)],'username':_0x264e93[_0x4b20c8(0x573)],'password':_0x264e93[_0x4b20c8(0x54b)]}),console[_0x4b20c8(0x24e)](_0x4b20c8(0x2e4)),console['log'](_0x4b20c8(0x764));}finally{await _0x3e3ba0[_0x4b20c8(0x44f)]();}}async function _0x298880(){const _0x57b26f=_0x2480b7,_0x3a957f=Date[_0x57b26f(0x127)](),_0x1fbf0a=_0x4bd009(process[_0x57b26f(0x400)]),_0x5e1732=_0x117dd0(_0x1fbf0a),_0x2df244=_0x9b04e6[_0x57b26f(0x738)](_0x5e1732['dbPath']);!_0x5e1732['noRepl']&&!process['stdin']['isTTY']&&(_0x5e1732[_0x57b26f(0x29c)]=!![]);const _0x2c0d40=require$$5$1,{start:_0x3feaca,colorLog:_0x1cd8d7}=requireOkdbShell(),_0x7f77d4=require$$1$1,_0x25f7ba={..._0x5e1732[_0x57b26f(0x466)]?{'encryptionKey':_0x5e1732['key']}:{},..._0x5e1732[_0x57b26f(0x116)]?{'admin':![]}:_0x3e7e17(_0x5e1732['admin'])?{'admin':_0x5e1732[_0x57b26f(0x270)]}:{},..._0x3e7e17(_0x5e1732['api'])?{'api':_0x5e1732[_0x57b26f(0x2bc)]}:{},..._0x3e7e17(_0x5e1732[_0x57b26f(0x8a)])?{'auth':_0x5e1732[_0x57b26f(0x8a)]}:{},..._0x3e7e17(_0x5e1732[_0x57b26f(0x3a2)])?{'mcp':_0x5e1732[_0x57b26f(0x3a2)]}:{},..._0x3e7e17(_0x5e1732[_0x57b26f(0x156)])?{'backup':_0x5e1732['backup']}:{},..._0x5e1732[_0x57b26f(0x121)]!==![]?{'timeMachine':_0x5e1732[_0x57b26f(0x121)]}:{},...Object['fromEntries'](_0x360f83[_0x57b26f(0x293)](_0x24f78d=>_0x5e1732[_0x24f78d]!==undefined)[_0x57b26f(0x757)](_0x5204f2=>[_0x5204f2,_0x5e1732[_0x5204f2]]))},_0x3642d1=_0x102e3e(_0x5e1732);if(!_0x7f77d4[_0x57b26f(0x42b)]){const _0x9ba6c6=_0x44736a(),_0x78e944=_0x5e1732[_0x57b26f(0x38a)]?_0x57b26f(0x653):_0x5e1732[_0x57b26f(0x3bd)]!=null&&_0x5e1732[_0x57b26f(0x3bd)]!==''?_0x57b26f(0x548):process.env.OKDB_HTTP_WORKERS?'OKDB_HTTP_WORKERS\x20env':_0x5e1732[_0x57b26f(0x91)]?.[_0x57b26f(0x150)]!=null?_0x57b26f(0x97):'default:\x20cores−1\x20=\x20'+Math[_0x57b26f(0x68c)](0x1,require$$0[_0x57b26f(0x19c)]()[_0x57b26f(0x39d)]-0x1);process[_0x57b26f(0x11c)][_0x57b26f(0xb6)](_0x57b26f(0xb5)+_0x3642d1+'\x20('+_0x78e944+(!_0x9ba6c6?_0x57b26f(0xb4):'')+')\x0a');}if(_0x7f77d4[_0x57b26f(0x42b)]){const _0x116652={..._0x25f7ba},_0x59f78b=new _0x2c0d40(_0x2df244,_0x116652);_0x59f78b[_0x57b26f(0x24e)][_0x57b26f(0x4e2)]?.();const _0x55d973=process.env.OKDB_CLUSTER_SLOT??'?',_0x177c9b={'debug':0x0,'info':0x1,'warn':0x2,'error':0x3},_0x4540d=_0x177c9b[_0x5e1732[_0x57b26f(0x4a0)]]??_0x177c9b['info'];_0x59f78b[_0x57b26f(0x24e)][_0x57b26f(0x133)](_0x44bcea=>{const _0x5b870b=_0x57b26f;if((_0x177c9b[_0x44bcea[_0x5b870b(0x67c)]]??0x1)<_0x4540d)return;try{process[_0x5b870b(0x3a7)]?.({'__okdbCluster':'log','slot':_0x55d973,'pid':process[_0x5b870b(0xee)],'entry':_0x44bcea});}catch{}}),await _0x59f78b[_0x57b26f(0x1fd)]();const {attachWorkerCluster:_0x5099f2}=requireOkdbCluster();_0x5099f2(_0x59f78b),await _0x2bebd9(_0x59f78b,_0x5e1732[_0x57b26f(0x255)],_0x313d09(_0x5e1732));return;}if(_0x3642d1>0x1){const {runClustered:_0x3a6e67}=requireOkdbCluster(),_0x820826=new _0x2c0d40(_0x2df244,{..._0x25f7ba,'engines':![],'processors':![],'compaction':![]});await _0x820826[_0x57b26f(0x1fd)]();const _0x17fdba=async()=>{const _0x398902=new _0x2c0d40(_0x2df244,{..._0x25f7ba});return await _0x398902['open'](),_0x398902;},_0xaf1b6f=Object['fromEntries'](_0x360f83[_0x57b26f(0x757)](_0x558141=>[_0x558141,_0x25f7ba[_0x558141]??!![]])),{formatListenAddr:_0x3235c0}=requireOkdbHttp(),_0x6a0e2c=_0x3235c0(_0x5e1732[_0x57b26f(0x255)],_0x5e1732[_0x57b26f(0x91)]?.[_0x57b26f(0x41a)]),_0x2f2686=_0x3a6e67({'workers':_0x3642d1,'makeOkdb':_0x17fdba,'port':_0x5e1732['port'],'primaryOkdb':_0x820826,'workerRole':_0xaf1b6f,'listenAddr':_0x6a0e2c});let _0x1e74cc=![];async function _0x4b87f2(_0x3b6b99){const _0xc90e7c=_0x57b26f;_0x1e74cc&&(process[_0xc90e7c(0x705)][_0xc90e7c(0xb6)](_0xc90e7c(0x2ea)),process[_0xc90e7c(0x4e7)](0x82));_0x1e74cc=!![],process['stderr'][_0xc90e7c(0xb6)](_0xc90e7c(0x2c6)+(_0x3b6b99||_0xc90e7c(0x119))+_0xc90e7c(0x542));const _0x1427a9=setTimeout(()=>{const _0x423f0b=_0xc90e7c;process[_0x423f0b(0x705)][_0x423f0b(0xb6)](_0x423f0b(0x3ea)),process[_0x423f0b(0x4e7)](0x0);},0xbb8);_0x1427a9['unref']?.();try{await _0x2f2686[_0xc90e7c(0x44f)]();}catch(_0x4c995b){process['stderr'][_0xc90e7c(0xb6)](_0xc90e7c(0x1c7)+(_0x4c995b?.[_0xc90e7c(0x5e6)]??_0x4c995b)+'\x0a');}try{await _0x820826[_0xc90e7c(0x44f)]();}catch(_0x1735b1){process[_0xc90e7c(0x705)]['write'](_0xc90e7c(0x138)+(_0x1735b1?.[_0xc90e7c(0x5e6)]??_0x1735b1)+'\x0a');}process[_0xc90e7c(0x4e7)](0x0);}_0x5e1732[_0x57b26f(0x616)]=_0x3642d1;if(!_0x5e1732[_0x57b26f(0x29c)]){_0x820826['log'][_0x57b26f(0x4e2)]?.(),_0x229da7(_0x820826[_0x57b26f(0x8a)]?.[_0x57b26f(0x5ba)]?.()??[]),await _0x3feaca(_0x820826,_0x5e1732);return;}process[_0x57b26f(0x11c)][_0x57b26f(0xb6)]('[okdb]\x20cluster\x20supervisor\x20pid='+process[_0x57b26f(0xee)]+_0x57b26f(0x4ae)+_0x3642d1+'\x20'+(_0x57b26f(0x1d2)+_0x5e1732[_0x57b26f(0x255)]+'\x0a')),console[_0x57b26f(0x24e)](''),console[_0x57b26f(0x24e)]('\x20\x20✓\x20OKDB\x20cluster\x20running'),console[_0x57b26f(0x24e)](_0x57b26f(0x46c)+_0x5e1732[_0x57b26f(0x255)]+_0x57b26f(0x71c)+_0x3642d1+_0x57b26f(0x36a)),console[_0x57b26f(0x24e)](_0x57b26f(0x286)+_0x2df244),console[_0x57b26f(0x24e)]('\x20\x20\x20\x20id:\x20\x20\x20\x20\x20\x20'+_0x820826['id']),console[_0x57b26f(0x24e)](_0x57b26f(0x69c)+_0x5e1732['port']+_0x57b26f(0x126));!_0x5e1732[_0x57b26f(0x116)]&&console['log'](_0x57b26f(0x778)+_0x5e1732[_0x57b26f(0x255)]+_0x57b26f(0xc8));console[_0x57b26f(0x24e)](''),_0x229da7(_0x820826['auth']?.[_0x57b26f(0x5ba)]?.()??[]),process['on'](_0x57b26f(0xe2),()=>_0x4b87f2(_0x57b26f(0xe2))),process['on'](_0x57b26f(0x196),()=>_0x4b87f2(_0x57b26f(0x196))),process['on']('SIGBREAK',()=>_0x4b87f2(_0x57b26f(0x583)));return;}const _0x3e9ccc=new _0x2c0d40(_0x2df244,_0x25f7ba);_0x3e9ccc[_0x57b26f(0x24e)][_0x57b26f(0x4e2)]?.();const _0x42dd33=_0x3e9ccc[_0x57b26f(0x24e)][_0x57b26f(0x133)](_0x1c6e96=>_0x1cd8d7(_0x1c6e96,_0x5e1732[_0x57b26f(0x4a0)]));if(_0x5e1732[_0x57b26f(0x29c)])process['stdout'][_0x57b26f(0xb6)]('[okdb]\x20starting…\x0a');await _0x3e9ccc[_0x57b26f(0x1fd)]();if(_0x5e1732[_0x57b26f(0x29c)])process['stdout'][_0x57b26f(0xb6)](_0x57b26f(0x223));try{await _0x2bebd9(_0x3e9ccc,_0x5e1732[_0x57b26f(0x255)],_0x313d09(_0x5e1732));}catch(_0x337e1f){_0x337e1f[_0x57b26f(0x25b)]===_0x57b26f(0x5f9)&&(console[_0x57b26f(0x492)]('[okdb]\x20port\x20'+_0x5e1732[_0x57b26f(0x255)]+_0x57b26f(0x6cc)),process['exit'](0x1));throw _0x337e1f;}if(_0x5e1732[_0x57b26f(0x29c)]){const _0x18ff1e=_0x5e1732[_0x57b26f(0x91)]?.[_0x57b26f(0x41a)]!==undefined?[][_0x57b26f(0x123)](_0x5e1732['http'][_0x57b26f(0x41a)])[_0x57b26f(0x10b)](',\x20')+'\x20':'';process[_0x57b26f(0x11c)][_0x57b26f(0xb6)]('\x20\x20✓\x20http\x20listening\x20on\x20'+_0x18ff1e+':'+_0x5e1732[_0x57b26f(0x255)]+'\x0a');}if(!_0x5e1732[_0x57b26f(0x29c)])_0x3e9ccc[_0x57b26f(0x24e)]['detachConsole']?.(),_0x42dd33?.(),_0x229da7(_0x3e9ccc[_0x57b26f(0x8a)]?.[_0x57b26f(0x5ba)]?.()??[]),await _0x3feaca(_0x3e9ccc,_0x5e1732);else{const _0x26b38=_0x9b04e6[_0x57b26f(0x10b)](_0x2df244,_0x57b26f(0x74b));try{_0xf79001[_0x57b26f(0x188)](_0x26b38,String(process['pid']));}catch{}const _0x51d4bc=Date[_0x57b26f(0x127)]()-_0x3a957f;console[_0x57b26f(0x24e)](''),console['log'](_0x57b26f(0x41e)),console[_0x57b26f(0x24e)](_0x57b26f(0x3fe)+_0x5e1732[_0x57b26f(0x255)]),console[_0x57b26f(0x24e)](_0x57b26f(0x656)+_0x2df244),console[_0x57b26f(0x24e)](_0x57b26f(0x10a)+_0x3e9ccc['id']);{const _0x2b15b5=_0x3e9ccc[_0x57b26f(0x5bc)]?.['db']?.[_0x57b26f(0x6a)]?.(_0x57b26f(0x5b9))??0x0,_0x15714e=[..._0x3e9ccc[_0x57b26f(0x64c)]['keys']()]['filter'](_0x44ba25=>!_0x44ba25['startsWith']('~'))[_0x57b26f(0x39d)];if(_0x3e9ccc['_license']?.[_0x57b26f(0x1b3)]?.[_0x57b26f(0x60a)]===0x1){const _0xc519d5=Math[_0x57b26f(0x6c3)]((_0x3e9ccc['_license']['active']['expiresAt']-Date[_0x57b26f(0x127)]())/0x5265c00);console[_0x57b26f(0x24e)](_0x57b26f(0x507)+_0x3e9ccc['_license'][_0x57b26f(0x1b3)][_0x57b26f(0x22b)]+_0x57b26f(0x146)+_0xc519d5+_0x57b26f(0x532));}else{if(_0x3e9ccc[_0x57b26f(0x511)]?.[_0x57b26f(0x1b3)]){const _0xae740e=_0x3e9ccc[_0x57b26f(0x511)][_0x57b26f(0x1b3)];console['log']('\x20\x20\x20\x20license:\x20'+_0xae740e[_0x57b26f(0x22b)]+_0x57b26f(0x89)+new Date(_0xae740e[_0x57b26f(0x57a)])[_0x57b26f(0x261)]()[_0x57b26f(0x13a)](0x0,0xa)+')');const _0x3bd775=_0xae740e[_0x57b26f(0x260)]||{};if(_0x3bd775['maxWrites']){const _0x1cf4f8=Math[_0x57b26f(0x139)](_0x2b15b5/_0x3bd775[_0x57b26f(0x425)]*0x64);console[_0x57b26f(0x24e)](_0x57b26f(0x470)+_0x2b15b5[_0x57b26f(0xbf)]()+_0x57b26f(0x5fb)+_0x3bd775[_0x57b26f(0x425)][_0x57b26f(0xbf)]()+_0x57b26f(0x258)+_0x1cf4f8+_0x57b26f(0x67e)+_0x15714e+(_0x3bd775[_0x57b26f(0x5cb)]?'/'+_0x3bd775[_0x57b26f(0x5cb)]:'')+_0x57b26f(0x76d)+(_0x15714e===0x1?'':'s'));}}else{if(_0x3e9ccc[_0x57b26f(0x511)]){const _0x27476c=_0x3e9ccc[_0x57b26f(0x511)][_0x57b26f(0x6fd)](),_0x458e14=_0x27476c['length']?_0x27476c[_0x57b26f(0x757)](_0x226935=>_0x226935[_0x57b26f(0x4b0)])[_0x57b26f(0x10b)](',\x20'):'(add\x20a\x20license\x20first)',_0x4e3c61=_0x3e9ccc[_0x57b26f(0x511)]['effective'],_0x4221df=_0x4e3c61[_0x57b26f(0x260)][_0x57b26f(0x425)]?Math['round'](_0x2b15b5/_0x4e3c61[_0x57b26f(0x260)]['maxWrites']*0x64):0x0;console[_0x57b26f(0x24e)](_0x57b26f(0xcc)),console[_0x57b26f(0x24e)](_0x57b26f(0x470)+_0x2b15b5[_0x57b26f(0xbf)]()+_0x57b26f(0x5fb)+_0x4e3c61[_0x57b26f(0x260)][_0x57b26f(0x425)][_0x57b26f(0xbf)]()+_0x57b26f(0x258)+_0x4221df+'%),\x20'+_0x15714e+'\x20/\x20'+_0x4e3c61[_0x57b26f(0x260)][_0x57b26f(0x5cb)]+_0x57b26f(0x735)),console[_0x57b26f(0x24e)](_0x57b26f(0xd1)+_0x458e14);}}}}console[_0x57b26f(0x24e)](_0x57b26f(0x44c)+_0x5e1732['port']+_0x57b26f(0x126));!_0x5e1732[_0x57b26f(0x116)]&&console[_0x57b26f(0x24e)](_0x57b26f(0x6d)+_0x5e1732[_0x57b26f(0x255)]+_0x57b26f(0xc8));console[_0x57b26f(0x24e)](''),console[_0x57b26f(0x24e)]('[okdb]\x20started\x20in\x20'+_0x51d4bc+'ms'),_0x229da7(_0x3e9ccc[_0x57b26f(0x8a)]?.[_0x57b26f(0x5ba)]?.()??[]);let _0xde4cbb=![];async function _0x1ecee2(_0x4d857e){const _0x436c9d=_0x57b26f;_0xde4cbb&&(process['stderr'][_0x436c9d(0xb6)]('\x0a[okdb]\x20force-exiting\x20(second\x20interrupt)\x0a'),process[_0x436c9d(0x4e7)](0x82));_0xde4cbb=!![],process[_0x436c9d(0x705)][_0x436c9d(0xb6)](_0x436c9d(0x2c6)+(_0x4d857e||'shutdown')+_0x436c9d(0xff));const _0x3ae836=setTimeout(()=>{const _0x34f1ba=_0x436c9d;process[_0x34f1ba(0x705)][_0x34f1ba(0xb6)](_0x34f1ba(0x141)),process['exit'](0x1);},0x1388);try{_0xf79001[_0x436c9d(0x3a3)](_0x26b38);}catch{}try{await _0x3e9ccc['close']();}catch(_0xcb8016){process[_0x436c9d(0x705)][_0x436c9d(0xb6)](_0x436c9d(0x6c9)+(_0xcb8016?.[_0x436c9d(0x5e6)]??_0xcb8016)+'\x0a');}clearTimeout(_0x3ae836),process['stderr'][_0x436c9d(0xb6)](_0x436c9d(0x2fe)),process['exit'](0x0);}process['on'](_0x57b26f(0xe2),()=>_0x1ecee2('SIGINT')),process['on'](_0x57b26f(0x196),()=>_0x1ecee2(_0x57b26f(0x196))),process['on'](_0x57b26f(0x583),()=>_0x1ecee2(_0x57b26f(0x583)));}}const _0x60e7e1=new Set([_0x2480b7(0x3e1),_0x2480b7(0x241),_0x2480b7(0x1c5),_0x2480b7(0x156),'restore',_0x2480b7(0x23a),'import','reset',_0x2480b7(0x129),_0x2480b7(0x10b),_0x2480b7(0x39b)]),_0x9d314f=process['argv'][0x2];if(_0x9d314f===_0x2480b7(0x3e1))console[_0x2480b7(0x24e)](require$$3[_0x2480b7(0x3e1)]),process[_0x2480b7(0x4e7)](0x0);else{if(_0x9d314f===_0x2480b7(0x528))process[_0x2480b7(0x4e7)](requireOkdbShmGc()[_0x2480b7(0x184)](process[_0x2480b7(0x400)][_0x2480b7(0x13a)](0x3)));else{if(_0x9d314f&&_0x60e7e1[_0x2480b7(0x469)](_0x9d314f)){const _0x451039=process[_0x2480b7(0x400)]['slice'](0x3),_0x11bbb8=_0x4bd009([_0x2480b7(0x68e),_0x2480b7(0x229),..._0x451039]),_0x15ef20=_0x117dd0(_0x11bbb8),_0x45b2ed=new Set(['--path','-d',_0x2480b7(0x454),'-k',_0x2480b7(0x3c2),'-c',_0x2480b7(0x777),'-p',_0x2480b7(0x428),_0x2480b7(0x488),'-e',_0x2480b7(0x472),_0x2480b7(0x21b),_0x2480b7(0x1b4),_0x2480b7(0x3ba),_0x2480b7(0x31f),_0x2480b7(0x13f),_0x2480b7(0x70f),_0x2480b7(0x55f),_0x2480b7(0xcb),'-u',_0x2480b7(0x309)]);let _0x7112fd=null;for(let _0x113bfe=0x0;_0x113bfe<_0x451039[_0x2480b7(0x39d)];_0x113bfe++){if(_0x45b2ed[_0x2480b7(0x469)](_0x451039[_0x113bfe])){_0x113bfe++;continue;}if(!_0x451039[_0x113bfe][_0x2480b7(0x42e)]('-')){_0x7112fd=_0x451039[_0x113bfe];break;}}(async()=>{const _0x2ae8ee=_0x2480b7;if(_0x9d314f===_0x2ae8ee(0x129)){const _0x8f0ad0=process['argv'][0x3],_0x1643bb=process['argv'][_0x2ae8ee(0x13a)](0x4),_0x5d40c3=_0x4bd009([_0x2ae8ee(0x68e),_0x2ae8ee(0x229),..._0x1643bb]),_0xce8b26=_0x117dd0(_0x5d40c3),_0x2e502f=new Set([_0x2ae8ee(0x539),'-d',_0x2ae8ee(0x454),'-k',_0x2ae8ee(0x3c2),'-c',_0x2ae8ee(0x777),'-p',_0x2ae8ee(0x21b),'--password',_0x2ae8ee(0x3ba),'--permissions',_0x2ae8ee(0x13f),_0x2ae8ee(0x70f),_0x2ae8ee(0x428),_0x2ae8ee(0x488),'-e',_0x2ae8ee(0x472)]),_0x52d9c1=[];for(let _0x3bbc4e=0x0;_0x3bbc4e<_0x1643bb[_0x2ae8ee(0x39d)];_0x3bbc4e++){if(_0x2e502f[_0x2ae8ee(0x469)](_0x1643bb[_0x3bbc4e])){_0x3bbc4e++;continue;}if(_0x1643bb[_0x3bbc4e][_0x2ae8ee(0x42e)]('-'))continue;_0x52d9c1['push'](_0x1643bb[_0x3bbc4e]);}switch(_0x8f0ad0){case _0x2ae8ee(0x216):await _0x37089e(_0xce8b26,_0x5d40c3);break;case _0x2ae8ee(0x401):await _0x442469(_0xce8b26);break;case _0x2ae8ee(0x2c7):await _0xeb5a1e(_0x52d9c1[0x0],_0xce8b26);break;default:console[_0x2ae8ee(0x492)](_0x2ae8ee(0x311)+_0x8f0ad0+_0x2ae8ee(0x1f5)),process[_0x2ae8ee(0x4e7)](0x1);}return;}if(_0x9d314f==='license'){const _0x577ad9=requireOkdbLicenseCodec(),_0x54eb56=process['argv'][_0x2ae8ee(0x13a)](0x3),_0x31ebf8=_0x4bd009([_0x2ae8ee(0x68e),_0x2ae8ee(0x229),..._0x54eb56]),_0x3ef834=_0x117dd0(_0x31ebf8),_0x104d30=new Set([_0x2ae8ee(0x539),'-d',_0x2ae8ee(0x454),'-k',_0x2ae8ee(0x3c2),'-c',_0x2ae8ee(0x777),'-p',_0x2ae8ee(0x428)]),_0x6b7f6b=[];for(let _0x10e2fc=0x0;_0x10e2fc<_0x54eb56[_0x2ae8ee(0x39d)];_0x10e2fc++){if(_0x104d30[_0x2ae8ee(0x469)](_0x54eb56[_0x10e2fc])){_0x10e2fc++;continue;}if(_0x54eb56[_0x10e2fc][_0x2ae8ee(0x42e)]('-'))continue;_0x6b7f6b[_0x2ae8ee(0x2f9)](_0x54eb56[_0x10e2fc]);}const _0xc0388a=_0x6b7f6b[0x0]??null;if(_0xc0388a==='remove')await _0x515c3d(_0x6b7f6b[0x1],_0x3ef834);else{if(!_0xc0388a)await _0x2011ca(_0x3ef834);else{let _0xd780c0=_0x577ad9[_0x2ae8ee(0x187)](_0xc0388a);if(_0xd780c0===_0x2ae8ee(0x14a)&&_0xf79001[_0x2ae8ee(0x1c9)](_0xc0388a))_0xd780c0=_0x2ae8ee(0x4c5);if(_0xd780c0===_0x2ae8ee(0x4c5))try{const _0x33cf5f=_0xf79001[_0x2ae8ee(0x418)](_0xc0388a,_0x2ae8ee(0x320))[_0x2ae8ee(0x471)](),_0x18883f=_0x577ad9['detectInputType'](_0x33cf5f);if(_0x18883f===_0x2ae8ee(0x552)){await _0x532735(_0x33cf5f,_0x3ef834);return;}await _0x3a54e1(_0xc0388a,_0x3ef834);return;}catch(_0x446dbc){console[_0x2ae8ee(0x492)](_0x2ae8ee(0x5c2)+_0xc0388a+':\x20'+_0x446dbc[_0x2ae8ee(0x5e6)]),process['exit'](0x1);}switch(_0xd780c0){case _0x2ae8ee(0x712):await _0x3a54e1(_0xc0388a,_0x3ef834);break;case _0x2ae8ee(0x552):await _0x532735(_0xc0388a,_0x3ef834);break;case _0x2ae8ee(0x4ad):await _0x43b83b(_0xc0388a,_0x3ef834);break;default:console[_0x2ae8ee(0x492)](_0x2ae8ee(0x543)+_0xc0388a+'\x22'),console['error'](''),console['error'](_0x2ae8ee(0x4a8)),console['error'](_0x2ae8ee(0x5c8)),console[_0x2ae8ee(0x492)](_0x2ae8ee(0xbd)),console['error'](_0x2ae8ee(0x159)),console[_0x2ae8ee(0x492)](_0x2ae8ee(0x723)),console[_0x2ae8ee(0x492)](''),console[_0x2ae8ee(0x492)](_0x2ae8ee(0x1f6)),process[_0x2ae8ee(0x4e7)](0x1);}}}return;}switch(_0x9d314f){case _0x2ae8ee(0x241):await _0x4e2758(_0x15ef20);break;case _0x2ae8ee(0x1c5):await _0x27c8f0();break;case _0x2ae8ee(0x478):await _0x3a6768(_0x15ef20);break;case _0x2ae8ee(0x156):await _0x3f91a5(_0x7112fd??_0x9b04e6[_0x2ae8ee(0x738)]('./okdb-backup'),_0x15ef20);break;case _0x2ae8ee(0x51f):if(!_0x7112fd)throw new Error(_0x2ae8ee(0x2c8));await _0x56e7f2(_0x9b04e6[_0x2ae8ee(0x738)](_0x7112fd),_0x15ef20,_0x11bbb8);break;case _0x2ae8ee(0x23a):await _0x484629(_0x7112fd??_0x9b04e6[_0x2ae8ee(0x738)](_0x2ae8ee(0x1a8)),_0x15ef20,_0x11bbb8);break;case _0x2ae8ee(0x1e2):await _0x5b20b7(_0x7112fd??_0x9b04e6[_0x2ae8ee(0x738)]('./okdb-export.ndjson'),_0x15ef20,_0x11bbb8);break;case _0x2ae8ee(0x10b):await _0x4840da(_0x7112fd,_0x15ef20,_0x11bbb8);break;}})()['then'](()=>process[_0x2480b7(0x4e7)](0x0))[_0x2480b7(0x618)](_0x10fafd=>{const _0x312e36=_0x2480b7;console[_0x312e36(0x492)](_0x312e36(0x148)+(_0x10fafd['message']||_0x10fafd)+'\x0a'),process['exit'](0x1);});}else _0x298880()[_0x2480b7(0x618)](_0x23e3e5=>{const _0x4bcbd8=_0x2480b7;console[_0x4bcbd8(0x492)](_0x4bcbd8(0x576)),console[_0x4bcbd8(0x492)](_0x23e3e5[_0x4bcbd8(0x5ed)]||_0x23e3e5),process[_0x4bcbd8(0x4e7)](0x1);});}}return okdb$1;}var okdbExports=requireOkdb(),okdb=getDefaultExportFromCjs(okdbExports);module['exports']=okdb;
|
|
2
|
+
'use strict';const _0x1cb9ed=_0x4ed4;(function(_0x28c802,_0x723b11){const _0x461bad=_0x4ed4,_0x390210=_0x28c802();while(!![]){try{const _0x315721=parseInt(_0x461bad(0x124))/0x1*(parseInt(_0x461bad(0x497))/0x2)+-parseInt(_0x461bad(0x588))/0x3+-parseInt(_0x461bad(0x89))/0x4*(parseInt(_0x461bad(0x233))/0x5)+parseInt(_0x461bad(0x368))/0x6*(-parseInt(_0x461bad(0xf3))/0x7)+-parseInt(_0x461bad(0x4a9))/0x8+parseInt(_0x461bad(0x7a))/0x9+parseInt(_0x461bad(0x1b3))/0xa;if(_0x315721===_0x723b11)break;else _0x390210['push'](_0x390210['shift']());}catch(_0x429d04){_0x390210['push'](_0x390210['shift']());}}}(_0x2196,0xea3a0));var require$$1=require(_0x1cb9ed(0x2cc)),require$$0$1=require('fs'),require$$0=require('os'),require$$4$1=require('net'),require$$5$1=require(_0x1cb9ed(0x8f)),require$$0$3=require(_0x1cb9ed(0x602)),require$$2=require('lmdb'),require$$5=require(_0x1cb9ed(0x5f6)),require$$2$1=require('crypto'),require$$0$2=require(_0x1cb9ed(0x578)),require$$4=require(_0x1cb9ed(0x692)),require$$1$1=require(_0x1cb9ed(0x14a)),require$$0$4=require(_0x1cb9ed(0x22f)),require$$0$5=require(_0x1cb9ed(0x30b)),require$$0$6=require('node:events'),require$$0$7=require('http'),require$$1$2=require(_0x1cb9ed(0x101)),require$$2$2=require(_0x1cb9ed(0x14d)),require$$2$3=require(_0x1cb9ed(0x20b)),require$$3$1=require(_0x1cb9ed(0x6ce)),commonjsGlobal=typeof globalThis!=='undefined'?globalThis:typeof window!==_0x1cb9ed(0x9a)?window:typeof global!==_0x1cb9ed(0x9a)?global:typeof self!==_0x1cb9ed(0x9a)?self:{};function getDefaultExportFromCjs(_0x46d026){const _0x334435=_0x1cb9ed;return _0x46d026&&_0x46d026[_0x334435(0x350)]&&Object[_0x334435(0x62f)]['hasOwnProperty'][_0x334435(0x70d)](_0x46d026,'default')?_0x46d026[_0x334435(0x666)]:_0x46d026;}var okdb$1={},okdbWorkers,hasRequiredOkdbWorkers;function requireOkdbWorkers(){if(hasRequiredOkdbWorkers)return okdbWorkers;hasRequiredOkdbWorkers=0x1;const _0x1bfd65=require$$0,_0x3bff17=require$$0$1,_0x23cc9a=require$$1;let _0x39c9e3;function _0x2837e2(){const _0x4b231c=_0x4ed4;if(process.env.OKDB_FORCE_SHMBUF_FALLBACK==='1')return![];if(_0x39c9e3!==undefined)return _0x39c9e3;try{const _0x59184e=_0x23cc9a['dirname'](require['resolve']('shmbuf/package.json'));_0x39c9e3=_0x3bff17['existsSync'](_0x23cc9a['join'](_0x59184e,_0x4b231c(0x38a),_0x4b231c(0x21f),_0x4b231c(0x2f2)));}catch{_0x39c9e3=![];}return _0x39c9e3;}function _0x1d0f76(){const _0x2437be=_0x4ed4,_0x227324=_0x1bfd65[_0x2437be(0x366)]()['length'];return Math[_0x2437be(0x608)](0x1,_0x227324-0x1);}function _0x4814ec(_0x3fb826,_0x4a40a7={}){const _0x28f747=_0x4ed4,_0x366656=_0x4a40a7['shmbufNative']!==undefined?_0x4a40a7[_0x28f747(0x4f4)]:_0x2837e2();let _0x2ce9fa;if(_0x3fb826?.[_0x28f747(0x330)])_0x2ce9fa=0x1;else{let _0x58e936,_0x5747fc;if(_0x3fb826?.['workersFlag']!==undefined&&_0x3fb826[_0x28f747(0x505)]!==null&&_0x3fb826['workersFlag']!=='')_0x58e936=_0x3fb826['workersFlag'],_0x5747fc='--workers';else{if(process.env.OKDB_HTTP_WORKERS!==undefined&&process.env.OKDB_HTTP_WORKERS!=='')_0x58e936=process.env.OKDB_HTTP_WORKERS,_0x5747fc='OKDB_HTTP_WORKERS';else _0x3fb826?.[_0x28f747(0x1be)]?.[_0x28f747(0x571)]!==undefined&&_0x3fb826['http'][_0x28f747(0x571)]!==null&&_0x3fb826[_0x28f747(0x1be)][_0x28f747(0x571)]!==''&&(_0x58e936=_0x3fb826[_0x28f747(0x1be)][_0x28f747(0x571)],_0x5747fc='http.workers');}if(_0x58e936===undefined)_0x2ce9fa=_0x1d0f76();else{const _0x2b4c50=Number(_0x58e936);!Number['isInteger'](_0x2b4c50)||_0x2b4c50<0x1?(console[_0x28f747(0x27b)](_0x28f747(0x280)+_0x5747fc+'='+JSON['stringify'](_0x58e936)+'\x20(must\x20be\x20an\x20integer\x20>=\x201)\x20—\x20using\x201'),_0x2ce9fa=0x1):_0x2ce9fa=_0x2b4c50;}}return!_0x366656&&_0x2ce9fa>0x1&&(console[_0x28f747(0x27b)](_0x28f747(0x73c)+(_0x28f747(0x687)+_0x2ce9fa+').')),_0x2ce9fa=0x1),_0x2ce9fa;}return okdbWorkers={'isShmbufNative':_0x2837e2,'defaultWorkers':_0x1d0f76,'resolveWorkers':_0x4814ec},okdbWorkers;}var version='2.6.2',require$$3={'version':version},okdbMigrate={'exports':{}},okdbError,hasRequiredOkdbError;function requireOkdbError(){if(hasRequiredOkdbError)return okdbError;hasRequiredOkdbError=0x1;class _0x507bbf extends Error{constructor(_0x25c49a,_0x26fd4c,_0x170054={}){const _0x56c512=_0x4ed4;super(_0x25c49a),this[_0x56c512(0x58e)]=_0x56c512(0xc7),this[_0x56c512(0x72d)]=_0x26fd4c,this[_0x56c512(0x3ed)]=_0x170054,_0x170054['cause']&&(this[_0x56c512(0x3f7)]=_0x170054[_0x56c512(0x3f7)]),Error[_0x56c512(0x75f)](this,this[_0x56c512(0x70f)]);}}class _0x20e4bf extends _0x507bbf{constructor(_0x1b5651,_0x29a244,_0x7157d4,_0x40db50){const _0x218935=_0x4ed4;super(_0x218935(0x2b1)+_0x1b5651+'@'+_0x29a244+':\x20expected\x20'+_0x7157d4+_0x218935(0x5b7)+_0x40db50,'VERSION_MISMATCH',{'type':_0x1b5651,'key':_0x29a244,'expectedVersion':_0x7157d4,'actualVersion':_0x40db50}),this[_0x218935(0x58e)]='OKDBVersionMismatchError';}}class _0x1c5f2a extends _0x507bbf{constructor(_0x315d75,_0x1be69c){const _0x35c76a=_0x4ed4;super(_0x315d75+'@'+_0x1be69c+_0x35c76a(0x26c),_0x35c76a(0x6a7),{'type':_0x315d75,'key':_0x1be69c}),this[_0x35c76a(0x58e)]=_0x35c76a(0x55b);}}class _0x568c1f extends _0x507bbf{constructor(_0x4bceb1,_0x1535d8){const _0x16ebb4=_0x4ed4;super(_0x4bceb1+'@'+_0x1535d8+'\x20already\x20exists',_0x16ebb4(0x5a3),{'type':_0x4bceb1,'key':_0x1535d8}),this[_0x16ebb4(0x58e)]='OKDBAlreadyExistsError';}}class _0x3c82fb extends _0x507bbf{constructor(_0x42c137,_0x644171){const _0x2860ea=_0x4ed4,_0x753ea0=typeof _0x644171;super('Invalid\x20index\x20key\x20type\x20for\x20\x27'+_0x42c137+_0x2860ea(0x6ef)+_0x753ea0+'.\x20Only\x20primitives,\x20null,\x20Buffers,\x20and\x20arrays\x20are\x20allowed.\x20Got:\x20'+_0x644171,_0x2860ea(0x709),{'index':_0x42c137,'key':_0x644171,'keyType':_0x753ea0}),this[_0x2860ea(0x58e)]=_0x2860ea(0x2d9);}}class _0x42bd2d extends _0x507bbf{constructor(_0xc93300){const _0x1751c8=_0x4ed4,_0x1fd97e=typeof _0xc93300;super(_0x1751c8(0x7d)+_0x1fd97e+_0x1751c8(0x4fb)+_0xc93300,'INVALID_PRIMARY_KEY',{'key':_0xc93300,'keyType':_0x1fd97e}),this['name']=_0x1751c8(0x2b6);}}class _0x1a9f80 extends _0x507bbf{constructor(_0x2eab19){const _0x26f38f=_0x4ed4;super(_0x26f38f(0x1c0)+_0x2eab19+_0x26f38f(0x532),_0x26f38f(0x23d),{'type':_0x2eab19}),this[_0x26f38f(0x58e)]='OKDBTypeNotRegisteredError';}}class _0x179004 extends _0x507bbf{constructor(_0x4e8581){const _0xb0b84c=_0x4ed4;super(_0xb0b84c(0x1c0)+_0x4e8581+_0xb0b84c(0x307),_0xb0b84c(0x7a2),{'type':_0x4e8581}),this[_0xb0b84c(0x58e)]=_0xb0b84c(0x211);}}class _0x38fea0 extends _0x507bbf{constructor(_0x15db41,_0x472a87){const _0x4c2d43=_0x4ed4;super(_0x4c2d43(0xd1)+_0x472a87+_0x4c2d43(0x4c1)+_0x15db41+_0x4c2d43(0x532),_0x4c2d43(0x467),{'type':_0x15db41,'index':_0x472a87}),this[_0x4c2d43(0x58e)]=_0x4c2d43(0x759);}}class _0x2cc235 extends _0x507bbf{constructor(_0x28f135,_0x13f924){const _0x51de8e=_0x4ed4;super(_0x51de8e(0xd1)+_0x13f924+_0x51de8e(0x4c1)+_0x28f135+'\x27\x20is\x20already\x20registered',_0x51de8e(0x67a),{'type':_0x28f135,'index':_0x13f924}),this[_0x51de8e(0x58e)]=_0x51de8e(0x5c8);}}class _0x558769 extends _0x507bbf{constructor(_0xbd8878,_0x16cb80={}){const _0x2113cd=_0x4ed4;super(_0xbd8878,_0x2113cd(0x302),_0x16cb80),this[_0x2113cd(0x58e)]=_0x2113cd(0x44b);}}class _0x1eaeb0 extends _0x507bbf{constructor(_0x1ac9bf,_0x26ee96,_0x565a5d,_0x2cbf98,_0x65270){const _0x1f8ac1=_0x4ed4;super(_0x1f8ac1(0x5cf)+_0x1ac9bf+'@'+_0x26ee96+_0x1f8ac1(0x64a)+_0x565a5d+_0x1f8ac1(0x635)+_0x2cbf98+_0x1f8ac1(0x50e)+_0x65270+'\x27',_0x1f8ac1(0x3c8),{'type':_0x1ac9bf,'index':_0x26ee96,'indexKey':_0x565a5d,'existingKey':_0x2cbf98,'conflictingKey':_0x65270}),this[_0x1f8ac1(0x58e)]='OKDBUniqueConstraintError';}}class _0x4468a9 extends _0x507bbf{constructor(_0x3b0f3a,_0xfe804e,_0x333339){const _0x52687c=_0x4ed4;super('Schema\x20validation\x20failed\x20for\x20'+_0x3b0f3a+'@'+_0xfe804e,_0x52687c(0x4f7),{'type':_0x3b0f3a,'key':_0xfe804e,'errors':_0x333339}),this[_0x52687c(0x58e)]=_0x52687c(0x752),this['type']=_0x3b0f3a,this[_0x52687c(0x1cd)]=_0xfe804e,this[_0x52687c(0x6d)]=_0x333339;}}class _0x3a029e extends _0x507bbf{constructor(_0x86c3ce,_0x38d61b){const _0x28472c=_0x4ed4;super(_0x28472c(0x65a)+_0x86c3ce+':\x20'+_0x38d61b[_0x28472c(0x2e8)]+'\x20documents\x20fail\x20validation',_0x28472c(0x337),{'type':_0x86c3ce,'failures':_0x38d61b}),this[_0x28472c(0x58e)]=_0x28472c(0x2fe),this[_0x28472c(0x5be)]=_0x86c3ce,this[_0x28472c(0x28f)]=_0x38d61b;}}class _0x4fa4d4 extends _0x507bbf{constructor(_0x335815,_0x4dc9f4,_0x1f602f,_0x2e3418,_0x264884){const _0xefdcd6=_0x4ed4;super('Foreign\x20key\x20violation:\x20'+_0x335815+'@'+_0x4dc9f4+'.'+_0x1f602f+'\x20references\x20'+_0x2e3418+'@'+_0x264884+_0xefdcd6(0x45a),'FOREIGN_KEY_VIOLATION',{'sourceType':_0x335815,'sourceKey':_0x4dc9f4,'fieldPath':_0x1f602f,'targetType':_0x2e3418,'targetKey':_0x264884}),this[_0xefdcd6(0x58e)]=_0xefdcd6(0x29c),this[_0xefdcd6(0x3be)]=_0x335815,this['sourceKey']=_0x4dc9f4,this[_0xefdcd6(0x72c)]=_0x1f602f,this['targetType']=_0x2e3418,this['targetKey']=_0x264884;}}class _0x4c3836 extends _0x507bbf{constructor(_0x2a2660,_0x387c29,_0x237531){const _0x3385bc=_0x4ed4;super(_0x3385bc(0xd2)+_0x2a2660+'@'+_0x387c29+':\x20'+_0x237531[_0x3385bc(0x2e8)]+_0x3385bc(0x620),_0x3385bc(0x753),{'targetType':_0x2a2660,'targetKey':_0x387c29,'references':_0x237531}),this['name']='OKDBForeignKeyDeleteError',this[_0x3385bc(0x740)]=_0x2a2660,this[_0x3385bc(0x76a)]=_0x387c29,this[_0x3385bc(0x16f)]=_0x237531;}}class _0x2aab7 extends _0x507bbf{constructor(_0x312f19,_0x394508,_0xf3888a){const _0x10c406=_0x4ed4;super(_0x10c406(0x4da)+_0x394508+_0x10c406(0x492)+_0x312f19+'\x22\x20is\x20used\x20by:\x20'+_0xf3888a['map'](_0x11eb45=>_0x11eb45['kind']+':'+_0x11eb45[_0x10c406(0x58e)])['join'](',\x20'),'INDEX_HAS_CONSUMERS',{'type':_0x312f19,'index':_0x394508,'usedBy':_0xf3888a}),this[_0x10c406(0x58e)]='OKDBIndexHasConsumersError';}}return okdbError={'OKDBError':_0x507bbf,'OKDBVersionMismatchError':_0x20e4bf,'OKDBNotFoundError':_0x1c5f2a,'OKDBAlreadyExistsError':_0x568c1f,'OKDBInvalidIndexKeyError':_0x3c82fb,'OKDBInvalidPrimaryKeyError':_0x42bd2d,'OKDBTypeNotRegisteredError':_0x1a9f80,'OKDBTypeAlreadyRegisteredError':_0x179004,'OKDBIndexNotRegisteredError':_0x38fea0,'OKDBIndexAlreadyRegisteredError':_0x2cc235,'OKDBInvalidValueError':_0x558769,'OKDBUniqueConstraintError':_0x1eaeb0,'OKDBSchemaValidationError':_0x4468a9,'OKDBSchemaCollectionError':_0x3a029e,'OKDBForeignKeyError':_0x4fa4d4,'OKDBForeignKeyDeleteError':_0x4c3836,'OKDBIndexHasConsumersError':_0x2aab7},okdbError;}var hasRequiredOkdbMigrate;function requireOkdbMigrate(){const _0x3405da=_0x1cb9ed;if(hasRequiredOkdbMigrate)return okdbMigrate[_0x3405da(0x761)];hasRequiredOkdbMigrate=0x1;const _0x56b878=require$$0$1,_0x51b96c=require$$1,_0x156f86=require$$2,{OKDBError:_0x476661}=requireOkdbError(),_0x31b229='header',_0x2c6735=_0x3405da(0x514),_0x3cb8ab=_0x3405da(0xc9),_0x4e2f92=_0x3405da(0x516),_0x52416d='change',_0x4cb1aa=0x1f4,_0x19f72b=0x3e8,_0x170273=_0x3405da(0x39a);async function _0x22acbb(_0x3608c4,_0x30a3d9,_0x1aee65,_0x3064a4){const _0xd34fb2=_0x3405da;if(_0x3608c4){await _0x3608c4[_0xd34fb2(0xe0)](_0x1aee65,Boolean(_0x3064a4));return;}const _0x21d5b3=_0x156f86['open'](_0x30a3d9,{'readOnly':!![],'maxDbs':0x8});try{await _0x21d5b3[_0xd34fb2(0xe0)](_0x1aee65,Boolean(_0x3064a4));}finally{await _0x21d5b3['close']();}}const _0x3f8eef=()=>new Promise(_0x1cec93=>setImmediate(_0x1cec93));function _0x8ef052(_0x142fd0,_0x9262b3){const _0x98c937=_0x3405da;if(_0x142fd0[_0x98c937(0xc6)](_0x9262b3))return Promise[_0x98c937(0x395)]();return new Promise((_0x297dec,_0xaaeca7)=>{const _0x2ed83f=_0x98c937,_0x1b0be2=_0x519162=>{const _0x230d13=_0x4ed4;_0x142fd0[_0x230d13(0x66f)]?.(_0x230d13(0x25f),_0x3028c1),_0x142fd0[_0x230d13(0x66f)]?.(_0x230d13(0x1da),_0x526ec5),_0x142fd0[_0x230d13(0x66f)]?.(_0x230d13(0x57b),_0x222d40);if(_0x519162)_0xaaeca7(_0x519162);else _0x297dec();},_0x3028c1=()=>_0x1b0be2(),_0x526ec5=_0x19aca1=>_0x1b0be2(_0x19aca1),_0x222d40=()=>_0x1b0be2(new Error(_0x2ed83f(0x80)));_0x142fd0[_0x2ed83f(0x17b)](_0x2ed83f(0x25f),_0x3028c1),_0x142fd0[_0x2ed83f(0x17b)](_0x2ed83f(0x1da),_0x526ec5),_0x142fd0[_0x2ed83f(0x17b)](_0x2ed83f(0x57b),_0x222d40);});}async function _0x3f014a(_0x2f35bb,_0x1a5ca9,_0x41134b){const _0x49da5c=_0x3405da;let _0x45b498=0x0,_0x4d7e0b,_0x3da4d4=!![];for(;;){const _0x11840d={'snapshot':!![],'limit':_0x19f72b};!_0x3da4d4&&(_0x11840d[_0x49da5c(0xfa)]=_0x4d7e0b,_0x11840d[_0x49da5c(0x59e)]=!![]);_0x3da4d4=![];const _0xbaaff5=Array['from'](_0x1a5ca9[_0x49da5c(0x4f6)](_0x11840d));if(_0xbaaff5['length']===0x0)break;let _0x215fff='';for(const _0x30e887 of _0xbaaff5)_0x215fff+=_0x41134b(_0x30e887)+'\x0a';_0x4d7e0b=_0xbaaff5[_0xbaaff5['length']-0x1][_0x49da5c(0x1cd)],_0x45b498+=_0xbaaff5[_0x49da5c(0x2e8)],await _0x8ef052(_0x2f35bb,_0x215fff);if(_0xbaaff5[_0x49da5c(0x2e8)]<_0x19f72b)break;await _0x3f8eef();}return _0x45b498;}class _0x2a320c{constructor(_0xda3515){this['okdb']=_0xda3515;}['_resolveEnv'](_0x5dbe95=_0x3405da(0x666)){const _0x270087=_0x3405da;return this[_0x270087(0x1ea)][_0x270087(0x514)](_0x5dbe95);}async[_0x3405da(0x43e)](_0x424b5b='default'){const _0x147ab1=_0x3405da;return!this['okdb'][_0x147ab1(0x319)][_0x147ab1(0x783)](_0x424b5b)&&await this[_0x147ab1(0x1ea)][_0x147ab1(0x112)](_0x424b5b,{'sync':!![]}),this[_0x147ab1(0x1ea)][_0x147ab1(0x514)](_0x424b5b);}['_listTypes'](_0x452767,_0x2206cb){const _0xfcbdfe=_0x3405da,_0x4bf100=[..._0x452767[_0xfcbdfe(0x750)][_0xfcbdfe(0x4a0)]()][_0xfcbdfe(0x20f)](_0x4ba436=>!_0x4ba436[_0xfcbdfe(0x557)]('~')&&!_0x4ba436[_0xfcbdfe(0x557)](_0xfcbdfe(0x6cc)));if(!_0x2206cb)return _0x4bf100;return _0x4bf100[_0xfcbdfe(0x20f)](_0x51c8e0=>_0x2206cb[_0xfcbdfe(0x243)](_0x51c8e0));}['_typeSchema'](_0x297c6d,_0x1776ac){const _0xa2283a=_0x3405da,_0x3364c2=_0x297c6d[_0xa2283a(0x696)]['get'](_0x1776ac),_0x197211=_0x297c6d[_0xa2283a(0x750)]['get'](_0x1776ac)||{},_0x525a8f=[];for(const [,_0x5b34cc]of _0x3364c2?.[_0xa2283a(0x1d5)]??new Map()){const _0x142026={'fields':_0x5b34cc[_0xa2283a(0x206)]};if(_0x5b34cc[_0xa2283a(0x631)])_0x142026[_0xa2283a(0x528)]=_0x5b34cc[_0xa2283a(0x631)];if(_0x5b34cc[_0xa2283a(0x12b)])_0x142026[_0xa2283a(0x12b)]=!![];_0x525a8f['push'](_0x142026);}const _0x224bf1={};for(const [_0x17dae3,_0x58a4b2]of Object[_0xa2283a(0x377)](_0x197211[_0xa2283a(0x629)]||{})){_0x224bf1[_0x17dae3]={'fields':_0x58a4b2['config']?.[_0xa2283a(0x656)],'tokenizer':_0x58a4b2[_0xa2283a(0xf5)]?.[_0xa2283a(0x26b)]};}const _0x5e4481={'indexes':_0x525a8f,'ftsIndexes':_0x224bf1};return _0x197211['schema']&&(_0x5e4481[_0xa2283a(0xc9)]=_0x197211['schema']),_0x5e4481;}async[_0x3405da(0x6c7)](_0x362613,_0x2b5874={}){const _0x436eb1=_0x3405da,{envName:envName='default',types:types=null,includeChanges:includeChanges=![],_noHeader:_noHeader=![]}=_0x2b5874,_0x72f505=this[_0x436eb1(0x3de)](envName),_0x4029aa=this[_0x436eb1(0xc5)](_0x72f505,types);let _0x1d2878=0x0,_0x2dfb00=0x0;!_noHeader&&await _0x8ef052(_0x362613,JSON['stringify']({'r':_0x31b229,'kdbVersion':require$$3[_0x436eb1(0x512)],'exportedAt':Date[_0x436eb1(0x6f1)](),'envName':envName})+'\x0a');for(const _0x2879ff of _0x4029aa){const _0x41ec0a=_0x72f505['typeSubDbs']['get'](_0x2879ff);if(!_0x41ec0a)continue;const _0x4e15ef=this['_typeSchema'](_0x72f505,_0x2879ff);await _0x8ef052(_0x362613,JSON['stringify']({'r':_0x3cb8ab,'type':_0x2879ff,..._0x4e15ef})+'\x0a'),_0x1d2878+=await _0x3f014a(_0x362613,_0x41ec0a['data'],({key:_0x3730a8,value:_0x105cf2,version:_0x45732c})=>JSON[_0x436eb1(0x5bd)]({'r':_0x4e2f92,'t':_0x2879ff,'k':_0x3730a8,'v':_0x105cf2,'ver':_0x45732c}));}return includeChanges&&_0x72f505[_0x436eb1(0x314)]&&(_0x2dfb00=await _0x3f014a(_0x362613,_0x72f505[_0x436eb1(0x525)],({key:_0x5da709,value:_0x1d6f24})=>JSON[_0x436eb1(0x5bd)]({'r':_0x52416d,'clock':_0x5da709,'event':_0x1d6f24}))),{'types':_0x4029aa[_0x436eb1(0x2e8)],'records':_0x1d2878,'changes':_0x2dfb00};}async['exportToFile'](_0x5dbe2e,_0x47f23a={}){const _0x3580fb=_0x3405da;_0x56b878[_0x3580fb(0x3b8)](_0x51b96c['dirname'](_0x5dbe2e),{'recursive':!![]});const _0x38a6f6=_0x56b878[_0x3580fb(0x799)](_0x5dbe2e),_0x48909e=await this[_0x3580fb(0x6c7)](_0x38a6f6,_0x47f23a);return await new Promise((_0x4e6829,_0x405e42)=>{const _0x11ca68=_0x3580fb;_0x38a6f6[_0x11ca68(0x1a0)](),_0x38a6f6[_0x11ca68(0x17b)](_0x11ca68(0x424),_0x4e6829),_0x38a6f6[_0x11ca68(0x17b)](_0x11ca68(0x1da),_0x405e42);}),{..._0x48909e,'filePath':_0x5dbe2e};}async[_0x3405da(0x349)](_0x1f4f93,_0x2928ae={}){const _0x21871f=_0x3405da,{envNames:envNames=null,types:types=null,includeChanges:includeChanges=![]}=_0x2928ae,_0x167c89=[...this[_0x21871f(0x1ea)]['_envs'][_0x21871f(0x449)]()][_0x21871f(0x20f)](_0x54c71c=>!_0x54c71c[_0x21871f(0x557)]('~')),_0x155dcc=envNames?_0x167c89[_0x21871f(0x20f)](_0x1c23a1=>envNames['includes'](_0x1c23a1)):_0x167c89;await _0x8ef052(_0x1f4f93,JSON[_0x21871f(0x5bd)]({'r':_0x31b229,'kdbVersion':require$$3[_0x21871f(0x512)],'exportedAt':Date[_0x21871f(0x6f1)](),'envNames':_0x155dcc})+'\x0a');let _0x640b45=0x0,_0xc12340=0x0,_0x3212a2=0x0;for(const _0x22a112 of _0x155dcc){await _0x8ef052(_0x1f4f93,JSON[_0x21871f(0x5bd)]({'r':_0x2c6735,'name':_0x22a112})+'\x0a');const _0x51ee7a=await this[_0x21871f(0x6c7)](_0x1f4f93,{'envName':_0x22a112,'types':types,'includeChanges':includeChanges,'_noHeader':!![]});_0x640b45+=_0x51ee7a[_0x21871f(0x4e6)],_0xc12340+=_0x51ee7a[_0x21871f(0x2f6)],_0x3212a2+=_0x51ee7a['changes'];}return{'envs':_0x155dcc[_0x21871f(0x2e8)],'types':_0x640b45,'records':_0xc12340,'changes':_0x3212a2};}async['importFromStream'](_0x42c51e,_0x56ea21={}){const _0x4f12fe=_0x3405da,{envName:_0x1b2ceb=null,types:_0x264e6c=null,dropExisting:dropExisting=![],batchSize:batchSize=_0x4cb1aa,includeChanges:includeChanges=![],onProgress:onProgress=null}=_0x56ea21;let _0x174e5d=_0x1b2ceb??_0x4f12fe(0x666),_0x3cb2ea=null,_0x3db419=0x0,_0x4a0066=0x0,_0x43ea66=0x0,_0x1a0904=null,_0x1a1fe6=[];const _0x947ed3=[],_0x2f43ba=async()=>{const _0x1f9d77=_0x4f12fe;if(!_0x1a1fe6[_0x1f9d77(0x2e8)]||!_0x1a0904||!_0x3cb2ea)return;await _0x3cb2ea[_0x1f9d77(0x43d)][_0x1f9d77(0x2cb)](()=>{const _0x494745=_0x1f9d77;for(const {k:_0x893f5c,v:_0x330fd5,ver:_0x380200}of _0x1a1fe6){_0x3cb2ea[_0x494745(0x4ab)](null,_0x1a0904,_0x893f5c,_0x330fd5,{'version':_0x380200,'origin':'import'});}}),_0x4a0066+=_0x1a1fe6[_0x1f9d77(0x2e8)],onProgress?.({'type':_0x1a0904,'count':_0x4a0066}),_0x1a1fe6=[];};await this[_0x4f12fe(0x98)](_0x42c51e,async _0x30976e=>{const _0x5ac474=_0x4f12fe,_0x4bb288=_0x30976e['r'];if(_0x4bb288===_0x31b229){if(!_0x1b2ceb&&_0x30976e['envName'])_0x174e5d=_0x30976e[_0x5ac474(0x53c)];_0x3cb2ea=await this[_0x5ac474(0x43e)](_0x174e5d);return;}if(!_0x3cb2ea)_0x3cb2ea=await this['_resolveOrCreateEnv'](_0x174e5d);if(_0x4bb288===_0x2c6735){await _0x2f43ba(),_0x1a0904=null,_0x174e5d=_0x1b2ceb??_0x30976e['name'],_0x3cb2ea=await this[_0x5ac474(0x43e)](_0x174e5d);return;}if(_0x4bb288===_0x3cb8ab){const {type:_0x42095d,indexes:indexes=[],ftsIndexes:ftsIndexes={},schema:_0x5ed3c0}=_0x30976e;if(_0x264e6c&&!_0x264e6c[_0x5ac474(0x243)](_0x42095d))return;await _0x2f43ba(),_0x1a0904=_0x42095d;dropExisting&&_0x3cb2ea[_0x5ac474(0x59f)](_0x42095d)&&await _0x3cb2ea['dropType'](_0x42095d);!_0x3cb2ea['hasType'](_0x42095d)&&(await _0x3cb2ea[_0x5ac474(0x624)](_0x42095d),_0x3db419++);for(const _0x1b1a7c of indexes){if(!_0x3cb2ea['hasIndex'](_0x42095d,_0x1b1a7c[_0x5ac474(0x656)])){const _0x5a7270={};_0x1b1a7c[_0x5ac474(0x528)]&&(_0x5a7270['type']=_0x5ac474(0x528),_0x5a7270[_0x5ac474(0xb0)]=_0x1b1a7c['geo'][_0x5ac474(0xb0)]);if(_0x1b1a7c[_0x5ac474(0x12b)])_0x5a7270[_0x5ac474(0x12b)]=!![];await _0x3cb2ea['registerIndex'](_0x42095d,_0x1b1a7c[_0x5ac474(0x656)],_0x5a7270);}}for(const [_0x3962af,_0x3d4a6a]of Object['entries'](ftsIndexes)){!this[_0x5ac474(0x1ea)][_0x5ac474(0x388)]['has'](_0x42095d,_0x3962af,_0x3cb2ea)&&await this[_0x5ac474(0x1ea)][_0x5ac474(0x388)]['register'](_0x42095d,_0x3962af,{'fields':_0x3d4a6a[_0x5ac474(0x656)],'tokenizer':_0x3d4a6a['tokenizer']},undefined,_0x3cb2ea);}_0x5ed3c0?.[_0x5ac474(0x4c3)]&&_0x947ed3[_0x5ac474(0x1c2)]({'env':_0x3cb2ea,'type':_0x42095d,'schema':_0x5ed3c0});return;}if(_0x4bb288===_0x4e2f92){if(_0x264e6c&&!_0x264e6c[_0x5ac474(0x243)](_0x30976e['t']))return;_0x30976e['t']!==_0x1a0904&&(await _0x2f43ba(),_0x1a0904=_0x30976e['t']);_0x1a1fe6['push']({'k':_0x30976e['k'],'v':_0x30976e['v'],'ver':_0x30976e[_0x5ac474(0x6f2)]});if(_0x1a1fe6[_0x5ac474(0x2e8)]>=batchSize)await _0x2f43ba();return;}_0x4bb288===_0x52416d&&includeChanges&&_0x3cb2ea[_0x5ac474(0x314)]&&(_0x3cb2ea[_0x5ac474(0x525)][_0x5ac474(0x4dd)](_0x30976e[_0x5ac474(0x594)],_0x30976e['event']),_0x43ea66++);}),await _0x2f43ba();for(const {env:_0x1131f9,type:_0x1ae3bb,schema:_0xeff0a2}of _0x947ed3){try{await _0x1131f9[_0x4f12fe(0x404)](_0x1ae3bb,_0xeff0a2);}catch{if(_0xeff0a2[_0x4f12fe(0x47b)])try{await _0x1131f9[_0x4f12fe(0x404)](_0x1ae3bb,{..._0xeff0a2,'enforce':![]});}catch{}}}return{'types':_0x3db419,'records':_0x4a0066,'changes':_0x43ea66};}async['importFromFile'](_0x18e0d9,_0x4e36af={}){const _0x477db0=_0x3405da,_0x1232e7=_0x56b878['createReadStream'](_0x18e0d9,{'encoding':_0x477db0(0x84)});return this[_0x477db0(0x4ce)](_0x1232e7,_0x4e36af);}[_0x3405da(0x98)](_0x133962,_0x350655){return new Promise((_0x1f99d8,_0x34d877)=>{const _0x3fb757=_0x4ed4;let _0x3054e4='',_0x32d3ac=Promise[_0x3fb757(0x395)]();const _0xf0fe95=async _0xc870d8=>{const _0x30a80e=_0x3fb757;_0x3054e4+=_0xc870d8;const _0x298e94=_0x3054e4[_0x30a80e(0x527)]('\x0a');_0x3054e4=_0x298e94[_0x30a80e(0x55c)]();for(const _0x5532a7 of _0x298e94){const _0x4aaad5=_0x5532a7['trim']();if(!_0x4aaad5)continue;let _0x9868a7;try{_0x9868a7=JSON[_0x30a80e(0x110)](_0x4aaad5);}catch{continue;}await _0x350655(_0x9868a7);}};_0x133962['on'](_0x3fb757(0x516),_0x166690=>{_0x32d3ac=_0x32d3ac['then'](()=>_0xf0fe95(String(_0x166690)));}),_0x133962['on'](_0x3fb757(0x1a0),()=>{const _0x426301=_0x3fb757;_0x32d3ac[_0x426301(0x257)](async()=>{const _0x448961=_0x426301,_0x44bcd5=_0x3054e4[_0x448961(0x220)]();if(_0x44bcd5)try{await _0x350655(JSON[_0x448961(0x110)](_0x44bcd5));}catch{}_0x1f99d8();})[_0x426301(0x31d)](_0x34d877);}),_0x133962['on'](_0x3fb757(0x1da),_0x34d877);});}async[_0x3405da(0xe0)](_0xe029c9,_0x14aa28={}){const _0x26f640=_0x3405da,{envNames:envNames=null,compact:compact=!![]}=_0x14aa28,_0x42b0e2=this[_0x26f640(0x1ea)],_0x53c2c0=_0x51b96c['resolve'](_0x42b0e2[_0x26f640(0x2cc)]),_0x596b1a=_0x51b96c['resolve'](_0xe029c9),_0x53a337=_0x51b96c['relative'](_0x53c2c0,_0x596b1a);if(_0x53a337===''||!(_0x53a337[_0x26f640(0x557)]('..')||_0x51b96c[_0x26f640(0x539)](_0x53a337)))throw new _0x476661(_0x26f640(0x6b1)+_0x596b1a+_0x26f640(0x4c0)+_0x53c2c0+_0x26f640(0x6c8),_0x26f640(0x52a));if(_0x56b878[_0x26f640(0x26e)](_0x596b1a)&&_0x56b878[_0x26f640(0x40f)](_0x596b1a)[_0x26f640(0x2e8)]>0x0)throw new _0x476661('backup\x20destination\x20\x22'+_0x596b1a+_0x26f640(0x354),'BACKUP_DEST_NOT_EMPTY');_0x56b878['mkdirSync'](_0x596b1a,{'recursive':!![]});const _0x3924b6=envNames?new Set([...envNames,_0x26f640(0xde)]):null,_0x28a390=[],_0x4bb6d3=[],_0x6a47b9=[];for(const [_0x2c3137,_0x3c0b80]of[..._0x42b0e2[_0x26f640(0x319)][_0x26f640(0x377)]()]){if(_0x3924b6&&!_0x3924b6[_0x26f640(0x783)](_0x2c3137))continue;if(_0x2c3137===_0x26f640(0x40e))continue;if(!_0x3c0b80[_0x26f640(0x466)]||!_0x3c0b80['db']){_0x4bb6d3[_0x26f640(0x1c2)]({'name':_0x2c3137,'reason':_0x26f640(0x3ae)});continue;}const _0x5e0b78=_0x51b96c['resolve'](_0x3c0b80[_0x26f640(0x2cc)]),_0x4a6230=_0x51b96c[_0x26f640(0x24a)](_0x53c2c0,_0x5e0b78),_0x2e4c06=_0x4a6230===''||_0x4a6230[_0x26f640(0x557)]('..')||_0x51b96c[_0x26f640(0x539)](_0x4a6230),_0x1c8a42=_0x2e4c06?_0x42b0e2['_safeEnvDirName'](_0x2c3137):_0x4a6230,_0x2b920c=_0x51b96c[_0x26f640(0x546)](_0x596b1a,_0x1c8a42);_0x56b878['mkdirSync'](_0x2b920c,{'recursive':!![]});const _0x3cb3ed=_0x51b96c[_0x26f640(0x546)](_0x5e0b78,'time-machine');let _0x29d001=![];if(_0x56b878[_0x26f640(0x26e)](_0x51b96c['join'](_0x3cb3ed,_0x26f640(0x4f8)))){const _0x305f81=_0x51b96c[_0x26f640(0x546)](_0x2b920c,_0x26f640(0x331));_0x56b878[_0x26f640(0x3b8)](_0x305f81,{'recursive':!![]}),await _0x22acbb(_0x3c0b80[_0x26f640(0x16a)]?.[_0x26f640(0x207)]?.['db'],_0x3cb3ed,_0x305f81,compact),_0x29d001=!![];}let _0x3df4e5=0x0;try{_0x3df4e5=_0x56b878['statSync'](_0x51b96c[_0x26f640(0x546)](_0x5e0b78,_0x26f640(0x4f8)))[_0x26f640(0x54a)];}catch{}await _0x3c0b80['db']['backup'](_0x2b920c,Boolean(compact));let _0x34363f=0x0;try{_0x34363f=_0x56b878[_0x26f640(0x1a4)](_0x51b96c[_0x26f640(0x546)](_0x2b920c,_0x26f640(0x4f8)))['size'];}catch{}_0x28a390['push']({'name':_0x2c3137,'dest':_0x2b920c,'sizeBefore':_0x3df4e5,'sizeAfter':_0x34363f,'timeMachine':_0x29d001}),_0x6a47b9[_0x26f640(0x1c2)]({'name':_0x2c3137,'dir':_0x1c8a42,'timeMachine':_0x29d001,..._0x2e4c06?{'outOfTree':_0x2e4c06,'sourcePath':_0x5e0b78}:{}});}for(const [_0x4477ff,_0x2de248]of _0x42b0e2['_quarantinedEnvs']??[]){if(_0x3924b6&&!_0x3924b6[_0x26f640(0x783)](_0x4477ff))continue;_0x4bb6d3[_0x26f640(0x1c2)]({'name':_0x4477ff,'reason':_0x26f640(0x77)+(_0x2de248?.[_0x26f640(0x1da)]??_0x26f640(0x613))});}const _0x12e84c={'count':0x0,'bytes':0x0},_0x1f585d=_0x42b0e2[_0x26f640(0x567)]?.[_0x26f640(0xa7)];_0x1f585d&&_0x56b878['existsSync'](_0x1f585d)&&await this[_0x26f640(0x76)](_0x1f585d,_0x51b96c[_0x26f640(0x546)](_0x596b1a,_0x26f640(0x1b4)),_0x12e84c,(_0x35a513,_0x1ba2b6)=>_0x1ba2b6===0x0&&_0x35a513===_0x26f640(0xa4));const _0x10e718=_0x51b96c[_0x26f640(0x546)](_0x596b1a,_0x170273),_0x5ba498={'format':0x1,'okdbVersion':require$$3[_0x26f640(0x512)],'createdAt':new Date()['toISOString'](),'source':_0x53c2c0,'compact':Boolean(compact),'envs':_0x6a47b9,'blobs':_0x12e84c,'skipped':_0x4bb6d3,'excluded':{'~fts':_0x26f640(0x6d9),'~processes':_0x26f640(0x135)}};return _0x56b878[_0x26f640(0x24e)](_0x10e718,JSON[_0x26f640(0x5bd)](_0x5ba498,null,0x2)+'\x0a'),{'ok':!![],'dest':_0x596b1a,'envs':_0x28a390,'blobs':_0x12e84c,'skipped':_0x4bb6d3,'manifest':_0x10e718};}[_0x3405da(0x482)](){const _0xd1d2a2=_0x3405da,_0xab1733=this[_0xd1d2a2(0x1ea)][_0xd1d2a2(0x5ba)]?.[_0xd1d2a2(0xe0)]?.['root'];if(_0xab1733)return _0x51b96c[_0xd1d2a2(0x395)](_0xab1733);const _0x27bec0=_0x51b96c[_0xd1d2a2(0x395)](this[_0xd1d2a2(0x1ea)]['path']);return _0x51b96c['join'](_0x51b96c[_0xd1d2a2(0x37a)](_0x27bec0),_0x51b96c[_0xd1d2a2(0x455)](_0x27bec0)+_0xd1d2a2(0x379));}['resolveBackupDest'](_0x3e7f8a){const _0x583478=_0x3405da,_0x3dcab2=this['backupRoot']();_0x56b878['mkdirSync'](_0x3dcab2,{'recursive':!![]});const _0x9e3eed=_0x56b878[_0x583478(0x45f)](_0x3dcab2),_0x31d518=_0x3e7f8a==null||String(_0x3e7f8a)[_0x583478(0x220)]()===''?_0x583478(0x552)+new Date()[_0x583478(0x165)]()['replace'](/[:.]/g,'-'):String(_0x3e7f8a)[_0x583478(0x220)](),_0x9d4723=_0x51b96c[_0x583478(0x395)](_0x3dcab2,_0x31d518);let _0x1d0efc=_0x9d4723;const _0x44be3e=[];while(!_0x56b878[_0x583478(0x26e)](_0x1d0efc)){_0x44be3e[_0x583478(0x76d)](_0x51b96c['basename'](_0x1d0efc));const _0xddc192=_0x51b96c[_0x583478(0x37a)](_0x1d0efc);if(_0xddc192===_0x1d0efc)break;_0x1d0efc=_0xddc192;}const _0x2205cb=_0x51b96c[_0x583478(0x546)](_0x56b878['realpathSync'](_0x1d0efc),..._0x44be3e),_0x6ee96e=_0x51b96c[_0x583478(0x24a)](_0x9e3eed,_0x2205cb);if(_0x6ee96e===''||_0x6ee96e['startsWith']('..')||_0x51b96c[_0x583478(0x539)](_0x6ee96e))throw new _0x476661(_0x583478(0x6b1)+_0x31d518+_0x583478(0x58d)+_0x3dcab2+_0x583478(0x5cd),_0x583478(0x4cf),{'root':_0x3dcab2,'destDir':_0x31d518});return{'root':_0x3dcab2,'dest':_0x2205cb};}async[_0x3405da(0x76)](_0x3c96c3,_0x385530,_0x37475d={'count':0x0,'bytes':0x0},_0x552382=null,_0x5d578b=0x0){const _0x56258c=_0x3405da;_0x56b878[_0x56258c(0x3b8)](_0x385530,{'recursive':!![]});for(const _0x1317e5 of _0x56b878[_0x56258c(0x40f)](_0x3c96c3,{'withFileTypes':!![]})){if(_0x552382?.(_0x1317e5[_0x56258c(0x58e)],_0x5d578b))continue;const _0x52ecfc=_0x51b96c[_0x56258c(0x546)](_0x3c96c3,_0x1317e5['name']),_0x2fc096=_0x51b96c[_0x56258c(0x546)](_0x385530,_0x1317e5[_0x56258c(0x58e)]);if(_0x1317e5[_0x56258c(0x5fd)]())await this['_copyDir'](_0x52ecfc,_0x2fc096,_0x37475d,_0x552382,_0x5d578b+0x1);else{try{await _0x56b878['promises'][_0x56258c(0x183)](_0x52ecfc,_0x2fc096);}catch(_0x35ce9b){if(_0x35ce9b?.[_0x56258c(0x72d)]===_0x56258c(0x412))continue;throw _0x35ce9b;}_0x37475d[_0x56258c(0x6b4)]++;try{_0x37475d[_0x56258c(0x2a2)]+=_0x56b878[_0x56258c(0x1a4)](_0x2fc096)['size'];}catch{}}}return _0x37475d;}async[_0x3405da(0x4e2)](_0xbf7cce={}){const _0x410cae=_0x3405da,{envName:envName=_0x410cae(0x666),types:types=null,includeChanges:includeChanges=![]}=_0xbf7cce,_0x183a57={'types':{},'changes':[]},_0x425e72=[],_0x5bd2c7=new require$$5[(_0x410cae(0x1c6))]({'write'(_0x2e6a09,_0x11132b,_0x58ea72){const _0x5334f6=_0x410cae;_0x425e72[_0x5334f6(0x1c2)](String(_0x2e6a09)),_0x58ea72();}});await this[_0x410cae(0x6c7)](_0x5bd2c7,{'envName':envName,'types':types,'includeChanges':includeChanges});for(const _0x2e270d of _0x425e72[_0x410cae(0x546)]('')[_0x410cae(0x527)]('\x0a')){const _0x119205=_0x2e270d[_0x410cae(0x220)]();if(!_0x119205)continue;let _0x2e6f70;try{_0x2e6f70=JSON[_0x410cae(0x110)](_0x119205);}catch{continue;}if(_0x2e6f70['r']===_0x3cb8ab){if(!_0x183a57[_0x410cae(0x4e6)][_0x2e6f70['type']])_0x183a57[_0x410cae(0x4e6)][_0x2e6f70[_0x410cae(0x5be)]]={'entries':[]};if(_0x2e6f70['indexes'])_0x183a57[_0x410cae(0x4e6)][_0x2e6f70[_0x410cae(0x5be)]][_0x410cae(0x1c8)]=_0x2e6f70[_0x410cae(0x1c8)];if(_0x2e6f70[_0x410cae(0x629)])_0x183a57[_0x410cae(0x4e6)][_0x2e6f70['type']]['ftsIndexes']=_0x2e6f70[_0x410cae(0x629)];if(_0x2e6f70[_0x410cae(0xc9)])_0x183a57[_0x410cae(0x4e6)][_0x2e6f70[_0x410cae(0x5be)]][_0x410cae(0xc9)]=_0x2e6f70[_0x410cae(0xc9)];}else{if(_0x2e6f70['r']===_0x4e2f92){if(!_0x183a57[_0x410cae(0x4e6)][_0x2e6f70['t']])_0x183a57[_0x410cae(0x4e6)][_0x2e6f70['t']]={'entries':[]};_0x183a57[_0x410cae(0x4e6)][_0x2e6f70['t']][_0x410cae(0x377)][_0x410cae(0x1c2)]({'key':_0x2e6f70['k'],'value':_0x2e6f70['v'],'version':_0x2e6f70[_0x410cae(0x6f2)]});}else _0x2e6f70['r']===_0x52416d&&_0x183a57[_0x410cae(0x536)][_0x410cae(0x1c2)]({'clock':_0x2e6f70[_0x410cae(0x594)],'event':_0x2e6f70[_0x410cae(0x33f)]});}}return _0x183a57;}async[_0x3405da(0x67d)](_0x3b4d4b,_0x564cb3={}){const _0x5ef39a=_0x3405da,_0x51aa68=[];for(const [_0x3ca893,_0x43f387]of Object['entries'](_0x3b4d4b[_0x5ef39a(0x4e6)]||{})){const _0x4b1ea3={'r':_0x3cb8ab,'type':_0x3ca893,'indexes':_0x43f387[_0x5ef39a(0x1c8)]||[],'ftsIndexes':_0x43f387[_0x5ef39a(0x629)]||{}};if(_0x43f387[_0x5ef39a(0xc9)])_0x4b1ea3[_0x5ef39a(0xc9)]=_0x43f387['schema'];_0x51aa68[_0x5ef39a(0x1c2)](JSON['stringify'](_0x4b1ea3));for(const {key:_0x405057,value:_0x15ae1e,version:_0x3ec0f9}of _0x43f387[_0x5ef39a(0x377)]||[]){_0x51aa68['push'](JSON['stringify']({'r':_0x4e2f92,'t':_0x3ca893,'k':_0x405057,'v':_0x15ae1e,'ver':_0x3ec0f9}));}}for(const {clock:_0x107d18,event:_0x323dc1}of _0x3b4d4b[_0x5ef39a(0x536)]||[]){_0x51aa68[_0x5ef39a(0x1c2)](JSON['stringify']({'r':_0x52416d,'clock':_0x107d18,'event':_0x323dc1}));}const {Readable:_0x17f3f5}=require$$5,_0x5984c2=_0x17f3f5[_0x5ef39a(0x16b)](_0x51aa68[_0x5ef39a(0x546)]('\x0a')+'\x0a');return this[_0x5ef39a(0x4ce)](_0x5984c2,{..._0x564cb3,'dropExisting':_0x564cb3[_0x5ef39a(0x2a1)]??!![]});}async['exportJSON']({pretty:pretty=![]}={}){const _0x45cac1=_0x3405da,_0x54a397=await this[_0x45cac1(0x4e2)]();return JSON[_0x45cac1(0x5bd)](_0x54a397,null,pretty?0x2:0x0);}async[_0x3405da(0x499)](_0x52c7ba){const _0x2275b1=_0x3405da,_0x27f9f2=JSON[_0x2275b1(0x110)](_0x52c7ba);return this['import'](_0x27f9f2);}async[_0x3405da(0x548)](_0x1972f4){const _0x5a7d05=_0x3405da;if(!this['okdb'][_0x5a7d05(0x567)])throw new Error('files\x20feature\x20not\x20available');const _0x4f2997=this[_0x5a7d05(0x1ea)][_0x5a7d05(0x567)]['_blobsDir'];let _0x211cc2=0x0,_0x2e4ab9=0x0;const _0x51b3da=_0x12ff24=>{const _0x104a1d=_0x5a7d05;if(!_0x56b878[_0x104a1d(0x26e)](_0x12ff24))return;for(const _0x198b55 of _0x56b878[_0x104a1d(0x40f)](_0x12ff24,{'withFileTypes':!![]})){const _0x57241c=_0x51b96c[_0x104a1d(0x546)](_0x12ff24,_0x198b55[_0x104a1d(0x58e)]);if(_0x198b55[_0x104a1d(0x5fd)]()){if(_0x198b55[_0x104a1d(0x58e)]===_0x104a1d(0xa4))continue;_0x51b3da(_0x57241c);}else{const _0x5059c1=_0x51b96c[_0x104a1d(0x455)](_0x51b96c[_0x104a1d(0x37a)](_0x57241c)),_0x38ee3f=_0x5059c1+_0x198b55['name'],_0x1ef976=_0x51b96c[_0x104a1d(0x546)](_0x1972f4,_0x38ee3f[_0x104a1d(0x762)](0x0,0x2)),_0x3d7209=_0x51b96c[_0x104a1d(0x546)](_0x1ef976,_0x38ee3f[_0x104a1d(0x762)](0x2));_0x56b878[_0x104a1d(0x3b8)](_0x1ef976,{'recursive':!![]}),_0x56b878[_0x104a1d(0x655)](_0x57241c,_0x3d7209),_0x211cc2++;try{_0x2e4ab9+=_0x56b878['statSync'](_0x57241c)['size'];}catch{}}}};return _0x56b878[_0x5a7d05(0x3b8)](_0x1972f4,{'recursive':!![]}),_0x51b3da(_0x4f2997),{'count':_0x211cc2,'bytes':_0x2e4ab9};}async[_0x3405da(0x7f)](_0x81c083){const _0x3ac4d8=_0x3405da;if(!this[_0x3ac4d8(0x1ea)]['files'])throw new Error(_0x3ac4d8(0x6e9));await this[_0x3ac4d8(0x1ea)][_0x3ac4d8(0x567)]['_ensure']();let _0x2b3b67=0x0,_0x14e18b=0x0;const _0x55ba14=_0x55f36a=>{const _0x15df52=_0x3ac4d8;if(!_0x56b878[_0x15df52(0x26e)](_0x55f36a))return;for(const _0x5a785e of _0x56b878[_0x15df52(0x40f)](_0x55f36a,{'withFileTypes':!![]})){const _0xfa9f1c=_0x51b96c[_0x15df52(0x546)](_0x55f36a,_0x5a785e[_0x15df52(0x58e)]);if(_0x5a785e[_0x15df52(0x5fd)]())_0x55ba14(_0xfa9f1c);else{const _0xe7ebec=_0x51b96c[_0x15df52(0x455)](_0x51b96c['dirname'](_0xfa9f1c)),_0x160fc7=_0xe7ebec+_0x5a785e[_0x15df52(0x58e)],_0x265976=this['okdb'][_0x15df52(0x567)]['_blobPath'](_0x160fc7);if(_0x56b878[_0x15df52(0x26e)](_0x265976)){_0x14e18b++;continue;}const _0xe570b0=_0x51b96c[_0x15df52(0x37a)](_0x265976);_0x56b878[_0x15df52(0x3b8)](_0xe570b0,{'recursive':!![]}),_0x56b878['copyFileSync'](_0xfa9f1c,_0x265976);const _0x4b70e5=this['okdb'][_0x15df52(0x567)][_0x15df52(0x111)](_0x160fc7);this['okdb'][_0x15df52(0x567)][_0x15df52(0xb9)]?.['putSync'](_0x160fc7,{'refs':_0x4b70e5}),_0x2b3b67++;}}};return _0x55ba14(_0x81c083),{'imported':_0x2b3b67,'skipped':_0x14e18b};}[_0x3405da(0x199)](){const _0x40339d=_0x3405da,_0x2d650b=[];for(const [,_0x5f4dee]of this[_0x40339d(0x1ea)]['_envs']){if(_0x5f4dee[_0x40339d(0x314)]&&_0x5f4dee['hasType']('~files'))_0x2d650b['push'](_0x5f4dee);}return _0x2d650b;}async['validateBlobIntegrity'](){const _0x49ad20=_0x3405da;if(!this[_0x49ad20(0x1ea)][_0x49ad20(0x567)])throw new Error(_0x49ad20(0x6e9));await this[_0x49ad20(0x1ea)][_0x49ad20(0x567)][_0x49ad20(0x369)]();const _0x1a432d=[],_0x111dfc=this[_0x49ad20(0x1ea)][_0x49ad20(0x567)];for(const _0x1301d2 of this[_0x49ad20(0x199)]()){for(const {key:_0xdf59a1,value:_0x535b0f}of _0x1301d2['getRange']('~files')){if(!_0x535b0f[_0x49ad20(0x35d)])continue;const _0x5aab10=_0x111dfc[_0x49ad20(0x652)](_0x535b0f[_0x49ad20(0x35d)]);!_0x56b878[_0x49ad20(0x26e)](_0x5aab10)&&_0x1a432d['push']({'type':_0x49ad20(0x668),'env':_0x1301d2[_0x49ad20(0x58e)],'id':String(_0xdf59a1),'hash':_0x535b0f[_0x49ad20(0x35d)],'message':_0x49ad20(0x15c)+_0xdf59a1+_0x49ad20(0x423)+_0x1301d2[_0x49ad20(0x58e)]+_0x49ad20(0x69e)+_0x535b0f[_0x49ad20(0x35d)]['slice'](0x0,0x8)+'…)'});const _0x39006d=_0x111dfc[_0x49ad20(0xb9)]?.[_0x49ad20(0x741)](_0x535b0f[_0x49ad20(0x35d)]);(!_0x39006d||_0x39006d[_0x49ad20(0x209)]<=0x0)&&_0x1a432d[_0x49ad20(0x1c2)]({'type':_0x49ad20(0x191),'env':_0x1301d2[_0x49ad20(0x58e)],'id':String(_0xdf59a1),'hash':_0x535b0f[_0x49ad20(0x35d)],'message':'Blob\x20ref-count\x20is\x20zero\x20for\x20~files\x20record\x20\x22'+_0xdf59a1+_0x49ad20(0x423)+_0x1301d2['name']+_0x49ad20(0x69e)+_0x535b0f[_0x49ad20(0x35d)]['slice'](0x0,0x8)+'…)'});}}const _0x4c3989=new Set();for(const _0x35517e of this[_0x49ad20(0x199)]()){for(const {value:_0x5a5579}of _0x35517e[_0x49ad20(0x4f6)](_0x49ad20(0x5a4))){if(_0x5a5579['hash'])_0x4c3989[_0x49ad20(0x5f3)](_0x5a5579[_0x49ad20(0x35d)]);}}const _0xe905b5=_0x260fa2=>{const _0x9ed5e4=_0x49ad20;if(!_0x56b878[_0x9ed5e4(0x26e)](_0x260fa2))return;for(const _0x4dc622 of _0x56b878[_0x9ed5e4(0x40f)](_0x260fa2,{'withFileTypes':!![]})){const _0x206651=_0x51b96c[_0x9ed5e4(0x546)](_0x260fa2,_0x4dc622[_0x9ed5e4(0x58e)]);if(_0x4dc622[_0x9ed5e4(0x5fd)]()){if(_0x4dc622[_0x9ed5e4(0x58e)]==='tmp')continue;_0xe905b5(_0x206651);}else{const _0x10824e=_0x51b96c['basename'](_0x51b96c[_0x9ed5e4(0x37a)](_0x206651)),_0x5a8d21=_0x10824e+_0x4dc622[_0x9ed5e4(0x58e)];!_0x4c3989[_0x9ed5e4(0x783)](_0x5a8d21)&&_0x1a432d['push']({'type':'orphan_blob','hash':_0x5a8d21,'message':'Blob\x20on\x20disk\x20has\x20no\x20~files\x20record\x20in\x20any\x20env\x20(hash:\x20'+_0x5a8d21[_0x9ed5e4(0x762)](0x0,0x8)+'…)'});}}};return _0xe905b5(_0x111dfc[_0x49ad20(0xa7)]),_0x1a432d;}async[_0x3405da(0x78e)](){const _0x49b7f6=_0x3405da;if(!this[_0x49b7f6(0x1ea)][_0x49b7f6(0x567)])throw new Error(_0x49b7f6(0x6e9));await this['okdb'][_0x49b7f6(0x567)][_0x49b7f6(0x369)]();const _0x3acc5b=this['okdb'][_0x49b7f6(0x567)][_0x49b7f6(0xb9)];if(!_0x3acc5b)throw new Error(_0x49b7f6(0x17d));const _0x54d4a5=[];for(const {key:_0x55b499}of _0x3acc5b[_0x49b7f6(0x4f6)]())_0x54d4a5[_0x49b7f6(0x1c2)](_0x55b499);for(const _0x1798a3 of _0x54d4a5)_0x3acc5b['removeSync'](_0x1798a3);const _0x2f1ce8=new Map();for(const _0x37285b of this['_allEnvsWithFiles']()){for(const {value:_0x38e891}of _0x37285b[_0x49b7f6(0x4f6)](_0x49b7f6(0x5a4))){_0x38e891[_0x49b7f6(0x35d)]&&_0x2f1ce8[_0x49b7f6(0x543)](_0x38e891['hash'],(_0x2f1ce8['get'](_0x38e891['hash'])??0x0)+0x1);}}for(const [_0x215401,_0x5d998b]of _0x2f1ce8){_0x3acc5b['putSync'](_0x215401,{'refs':_0x5d998b});}return{'rebuilt':_0x2f1ce8[_0x49b7f6(0x54a)]};}}return okdbMigrate['exports']=_0x2a320c,okdbMigrate[_0x3405da(0x761)][_0x3405da(0x5f5)]=_0x170273,okdbMigrate[_0x3405da(0x761)];}var okdbAuthTokens,hasRequiredOkdbAuthTokens;function requireOkdbAuthTokens(){if(hasRequiredOkdbAuthTokens)return okdbAuthTokens;hasRequiredOkdbAuthTokens=0x1;const _0x22938a=require$$2$1;function _0x14949a(_0x3be162,_0x3c6cd8){const _0xd8bfa1=_0x4ed4;return _0x22938a['createHmac'](_0xd8bfa1(0x42f),_0x3c6cd8)['update'](_0x3be162)[_0xd8bfa1(0x586)](_0xd8bfa1(0x638));}function _0x5a630c(_0x256735,_0x3e7ad8){const _0x2369ae=_0x4ed4;if(typeof _0x256735!==_0x2369ae(0x139)||typeof _0x3e7ad8!=='string')return![];if(Buffer['byteLength'](_0x256735)!==Buffer[_0x2369ae(0x592)](_0x3e7ad8))return![];return _0x22938a['timingSafeEqual'](Buffer[_0x2369ae(0x16b)](_0x256735),Buffer['from'](_0x3e7ad8));}function _0x2960b2(_0x1a85e5){const _0x130289=_0x4ed4;if(!_0x1a85e5?.['startsWith'](_0x130289(0x6f8)))return null;return _0x1a85e5['slice'](0x7);}function _0x5b4411(_0x103f47=0x20){const _0x179b20=_0x4ed4;return _0x22938a[_0x179b20(0x269)](_0x103f47)[_0x179b20(0x3cb)](_0x179b20(0x638));}function _0x36f626(_0x4df918){const _0x5963ca=_0x4ed4;return _0x22938a[_0x5963ca(0x6ba)](_0x5963ca(0x42f))[_0x5963ca(0x3ec)](_0x4df918)[_0x5963ca(0x586)](_0x5963ca(0x52c));}function _0x23ee8d(_0x1fbe48,_0xf713ec,_0x5551bb=0x36ee80){const _0x981211=_0x4ed4;if(!_0xf713ec)throw new Error(_0x981211(0x1f4));const _0x377653=Date[_0x981211(0x6f1)](),_0xba163f=Buffer['from'](JSON[_0x981211(0x5bd)]({'iat':_0x377653,'exp':_0x377653+_0x5551bb,'sub':_0x1fbe48?.['id']??_0x1fbe48?.['sub']??null,'username':_0x1fbe48?.['username']??_0x1fbe48?.[_0x981211(0x58e)]??null,'roles':Array[_0x981211(0x259)](_0x1fbe48?.['roles'])?_0x1fbe48[_0x981211(0x5dd)]:[]}))[_0x981211(0x3cb)]('base64url'),_0x5d7678=_0x14949a(_0xba163f,_0xf713ec);return _0xba163f+'.'+_0x5d7678;}function _0x1a0be4(_0x21b1c0,_0x4afab2){const _0x4da60e=_0x4ed4;if(!_0x4afab2||typeof _0x21b1c0!=='string')return null;const [_0x9f4516,_0x2c05c8]=_0x21b1c0[_0x4da60e(0x527)]('.');if(!_0x9f4516||!_0x2c05c8)return null;const _0x479603=_0x14949a(_0x9f4516,_0x4afab2);if(!_0x5a630c(_0x2c05c8,_0x479603))return null;try{const _0x990d6f=JSON[_0x4da60e(0x110)](Buffer[_0x4da60e(0x16b)](_0x9f4516,'base64url')[_0x4da60e(0x3cb)]()),_0x4721e=0x7530;if(Date[_0x4da60e(0x6f1)]()>Number(_0x990d6f?.[_0x4da60e(0x422)]??0x0)+_0x4721e)return null;return _0x990d6f;}catch{return null;}}async function _0x3f025b(_0x1d0dfc){return new Promise((_0x241597,_0x5add9b)=>{const _0x3f2263=_0x4ed4,_0xc04d9e=_0x22938a[_0x3f2263(0x269)](0x10);_0x22938a[_0x3f2263(0x473)](_0x1d0dfc,_0xc04d9e,0x40,(_0x2cde38,_0x42f96c)=>{const _0x6e4867=_0x3f2263;if(_0x2cde38)return _0x5add9b(_0x2cde38);_0x241597(_0xc04d9e[_0x6e4867(0x3cb)](_0x6e4867(0x52c))+':'+_0x42f96c[_0x6e4867(0x3cb)](_0x6e4867(0x52c)));});});}async function _0x2de601(_0x140225,_0x33f7c5){const _0x4f3b03=_0x4ed4;if(typeof _0x33f7c5!=='string')return![];const [_0x19f438,_0x51caa5]=_0x33f7c5[_0x4f3b03(0x527)](':');if(!_0x19f438||!_0x51caa5)return![];const _0x5cbf37=Buffer[_0x4f3b03(0x16b)](_0x19f438,'hex'),_0x21e506=Buffer[_0x4f3b03(0x16b)](_0x51caa5,_0x4f3b03(0x52c));if(_0x21e506['length']!==0x40)return![];return new Promise((_0x561223,_0x754d79)=>{const _0x4c4844=_0x4f3b03;_0x22938a[_0x4c4844(0x473)](_0x140225,_0x5cbf37,0x40,(_0x1a7b2c,_0x4cfa07)=>{if(_0x1a7b2c)return _0x754d79(_0x1a7b2c);_0x561223(_0x22938a['timingSafeEqual'](_0x4cfa07,_0x21e506));});});}return okdbAuthTokens={'hmac':_0x14949a,'timingSafeEqual':_0x5a630c,'parseBearer':_0x2960b2,'randomToken':_0x5b4411,'hashToken':_0x36f626,'issueToken':_0x23ee8d,'authenticateToken':_0x1a0be4,'hashPassword':_0x3f025b,'verifyPassword':_0x2de601},okdbAuthTokens;}var okdbLicenseCodec,hasRequiredOkdbLicenseCodec;function requireOkdbLicenseCodec(){const _0x3cfef6=_0x1cb9ed;if(hasRequiredOkdbLicenseCodec)return okdbLicenseCodec;hasRequiredOkdbLicenseCodec=0x1;const _0x4aef14=require$$0$2,_0x37bbb1='0123456789ABCDEFGHJKMNPQRSTVWXYZ',_0x38ff42=new Uint8Array(0x100)[_0x3cfef6(0x793)](0xff);for(let _0x313934=0x0;_0x313934<_0x37bbb1[_0x3cfef6(0x2e8)];_0x313934++){_0x38ff42[_0x37bbb1[_0x3cfef6(0x439)](_0x313934)]=_0x313934,_0x38ff42[_0x37bbb1[_0x3cfef6(0x439)](_0x313934)+0x20]=_0x313934;}_0x38ff42['O'['charCodeAt'](0x0)]=0x0,_0x38ff42['o'[_0x3cfef6(0x439)](0x0)]=0x0,_0x38ff42['I'[_0x3cfef6(0x439)](0x0)]=0x1,_0x38ff42['i'['charCodeAt'](0x0)]=0x1,_0x38ff42['L'['charCodeAt'](0x0)]=0x1,_0x38ff42['l'[_0x3cfef6(0x439)](0x0)]=0x1;function _0x41c2ac(_0x166144){let _0x4066d8=0x0,_0x5564ea=0x0,_0x2629da='';for(let _0x3b1cf2=0x0;_0x3b1cf2<_0x166144['length'];_0x3b1cf2++){_0x5564ea=_0x5564ea<<0x8|_0x166144[_0x3b1cf2],_0x4066d8+=0x8;while(_0x4066d8>=0x5){_0x4066d8-=0x5,_0x2629da+=_0x37bbb1[_0x5564ea>>>_0x4066d8&0x1f];}}return _0x4066d8>0x0&&(_0x2629da+=_0x37bbb1[_0x5564ea<<0x5-_0x4066d8&0x1f]),_0x2629da;}function _0x4e4654(_0x392ac9){const _0xe2d29f=_0x3cfef6;_0x392ac9=_0x392ac9[_0xe2d29f(0x61f)](/-/g,'')[_0xe2d29f(0x731)]();let _0x257905=0x0,_0x261d89=0x0;const _0x18b4c4=[];for(let _0x5cee48=0x0;_0x5cee48<_0x392ac9['length'];_0x5cee48++){const _0x164e1d=_0x38ff42[_0x392ac9[_0xe2d29f(0x439)](_0x5cee48)];if(_0x164e1d===0xff)continue;_0x261d89=_0x261d89<<0x5|_0x164e1d,_0x257905+=0x5,_0x257905>=0x8&&(_0x257905-=0x8,_0x18b4c4[_0xe2d29f(0x1c2)](_0x261d89>>>_0x257905&0xff));}return Buffer[_0xe2d29f(0x16b)](_0x18b4c4);}const _0x404f4c=[_0x3cfef6(0x15e),_0x3cfef6(0x760),_0x3cfef6(0x1d6),_0x3cfef6(0x388),'timeMachine',_0x3cfef6(0x6ab),_0x3cfef6(0x584),_0x3cfef6(0x567)],_0x4238fb=0x0,_0xa81036=0x1,_0x533eb0=0x2,_0x2a0310=0x6*0x1e*0x18*0x3c*0x3c*0x3e8;function _0x3b4d2c({issuedAt:_0x339dd0,expiresAt:_0x5bb338,licensee:licensee='',features:features={},limits:limits={},licenseType:licenseType=_0x4238fb}){const _0x18d536=_0x3cfef6,_0x324d09=Buffer[_0x18d536(0x16b)](licensee,_0x18d536(0x84))[_0x18d536(0x762)](0x0,0x40),_0x530788=0x1+0x1+0x4+0x4+0x1+_0x324d09[_0x18d536(0x2e8)]+0x2+0x10,_0x3c1303=Buffer[_0x18d536(0x646)](_0x530788);let _0x85c123=0x0;_0x3c1303['writeUInt8'](0x1,_0x85c123++),_0x3c1303[_0x18d536(0x43f)](licenseType,_0x85c123++),_0x3c1303[_0x18d536(0x13e)](Math['floor'](_0x339dd0/0x3e8),_0x85c123),_0x85c123+=0x4,_0x3c1303[_0x18d536(0x13e)](Math['floor'](_0x5bb338/0x3e8),_0x85c123),_0x85c123+=0x4,_0x3c1303[_0x18d536(0x43f)](_0x324d09[_0x18d536(0x2e8)],_0x85c123++),_0x324d09[_0x18d536(0x3cd)](_0x3c1303,_0x85c123),_0x85c123+=_0x324d09[_0x18d536(0x2e8)];let _0x5565ee=0x0;for(let _0x1fce59=0x0;_0x1fce59<_0x404f4c['length'];_0x1fce59++){if(features[_0x404f4c[_0x1fce59]])_0x5565ee|=0x1<<_0x1fce59;}_0x3c1303[_0x18d536(0x3b7)](_0x5565ee,_0x85c123),_0x85c123+=0x2;const _0x556f54=[_0x18d536(0xb1),_0x18d536(0x4f3),'syncPeers',_0x18d536(0x47c)];for(const _0x25591a of _0x556f54){_0x3c1303[_0x18d536(0x13e)](limits[_0x25591a]||0x0,_0x85c123),_0x85c123+=0x4;}return _0x3c1303;}function _0x347a44(_0x354e9c){const _0x13089f=_0x3cfef6;let _0x2f183d=0x0;const _0x320e3e=_0x354e9c[_0x13089f(0x397)](_0x2f183d++),_0x14c176=_0x354e9c[_0x13089f(0x397)](_0x2f183d++),_0x6a434d=_0x354e9c[_0x13089f(0x3dc)](_0x2f183d);_0x2f183d+=0x4;const _0x7272f3=_0x354e9c[_0x13089f(0x3dc)](_0x2f183d);_0x2f183d+=0x4;const _0x1ca57b=_0x354e9c[_0x13089f(0x397)](_0x2f183d++),_0x47e040=_0x354e9c[_0x13089f(0x762)](_0x2f183d,_0x2f183d+_0x1ca57b)[_0x13089f(0x3cb)]('utf8');_0x2f183d+=_0x1ca57b;const _0x5e902c=_0x354e9c[_0x13089f(0x32f)](_0x2f183d);_0x2f183d+=0x2;const _0x252464={};for(let _0x27d9c9=0x0;_0x27d9c9<_0x404f4c[_0x13089f(0x2e8)];_0x27d9c9++){_0x252464[_0x404f4c[_0x27d9c9]]=Boolean(_0x5e902c&0x1<<_0x27d9c9);}const _0x3a5f70=[_0x13089f(0xb1),_0x13089f(0x4f3),_0x13089f(0x2ef),_0x13089f(0x47c)],_0x5c2a8a={};for(const _0x5daf58 of _0x3a5f70){const _0x5c67bc=_0x354e9c[_0x13089f(0x3dc)](_0x2f183d);_0x2f183d+=0x4,_0x5c2a8a[_0x5daf58]=_0x5c67bc===0x0?null:_0x5c67bc;}return{'v':_0x320e3e,'licenseType':_0x14c176,'issuedAt':_0x6a434d*0x3e8,'expiresAt':_0x7272f3*0x3e8,'licensee':_0x47e040,'features':_0x252464,'limits':_0x5c2a8a};}function _0x164240(_0x46c975,_0x460a95){const _0x447837=_0x3cfef6,_0x20b530=Buffer['concat']([_0x46c975,_0x460a95]),_0x1d7a91=_0x41c2ac(_0x20b530),_0x183e70=[];for(let _0x44d1bb=0x0;_0x44d1bb<_0x1d7a91[_0x447837(0x2e8)];_0x44d1bb+=0x8){_0x183e70[_0x447837(0x1c2)](_0x1d7a91['slice'](_0x44d1bb,_0x44d1bb+0x8));}return _0x183e70[_0x447837(0x546)]('-');}function _0x264490(_0x523f47){const _0x5cfa03=_0x3cfef6;if(typeof _0x523f47!==_0x5cfa03(0x139))throw new Error(_0x5cfa03(0x3d8));const _0xf537d3=_0x4e4654(_0x523f47[_0x5cfa03(0x61f)](/-/g,''));if(_0xf537d3[_0x5cfa03(0x2e8)]<0x41)throw new Error(_0x5cfa03(0x1ef)+_0xf537d3['length']+'\x20bytes,\x20need\x20>=\x2065)');const _0x3a4bca=_0xf537d3[_0x5cfa03(0x762)](0x0,_0xf537d3[_0x5cfa03(0x2e8)]-0x40),_0x5e00f5=_0xf537d3['slice'](_0xf537d3[_0x5cfa03(0x2e8)]-0x40);let _0x430494;try{_0x430494=_0x347a44(_0x3a4bca);}catch(_0xb59338){throw new Error('decodeLicenseBlob:\x20failed\x20to\x20decode\x20payload:\x20'+_0xb59338['message']);}return{'rawBuf':_0xf537d3,'payload':_0x3a4bca,'sig':_0x5e00f5,'decoded':_0x430494};}function _0x4484e4(_0x398ac5){const _0x42059b=_0x3cfef6;return _0x4aef14[_0x42059b(0x6ba)](_0x42059b(0x42f))[_0x42059b(0x3ec)](_0x398ac5)[_0x42059b(0x586)]()[_0x42059b(0x762)](0x0,0x8);}function _0x2e2a32(_0x3ef11c,_0x47de19,_0x468877){const _0x498d71=_0x3cfef6,_0x10bca8=_0x498d71(0xc4)+_0x468877,_0x552432=Buffer['concat']([Buffer[_0x498d71(0x16b)](_0x3ef11c,_0x498d71(0x84)),_0x47de19]),_0x108024=_0x4aef14[_0x498d71(0x3b3)]('sha256',_0x10bca8)['update'](_0x552432)['digest'](),_0x35e13b=_0x41c2ac(_0x108024['slice'](0x0,0x5));return{'pin':_0x35e13b,'pinHmac':_0x108024};}function _0x52cbb5(_0x54ae29,_0x1de23e,_0x48cb94){const _0x24fc3d=_0x3cfef6,_0x331952=Buffer[_0x24fc3d(0x646)](0x4d);let _0x5ee7c3=0x0;_0x331952['writeUInt8'](0x1,_0x5ee7c3++),_0x54ae29[_0x24fc3d(0x3cd)](_0x331952,_0x5ee7c3),_0x5ee7c3+=0x8,_0x331952['writeUInt32BE'](_0x1de23e,_0x5ee7c3),_0x5ee7c3+=0x4,_0x48cb94[_0x24fc3d(0x3cd)](_0x331952,_0x5ee7c3);const _0x3085d5=_0x41c2ac(_0x331952),_0x170fe5=[];for(let _0x4fc6c6=0x0;_0x4fc6c6<_0x3085d5[_0x24fc3d(0x2e8)];_0x4fc6c6+=0x6){_0x170fe5[_0x24fc3d(0x1c2)](_0x3085d5['slice'](_0x4fc6c6,_0x4fc6c6+0x6));}return _0x170fe5[_0x24fc3d(0x546)]('-');}function _0x40acf8(_0x5b1397){const _0x544941=_0x3cfef6;if(typeof _0x5b1397!==_0x544941(0x139))throw new Error('decodeActivationToken:\x20input\x20must\x20be\x20a\x20string');const _0x1eb4d5=_0x4e4654(_0x5b1397[_0x544941(0x61f)](/-/g,''));if(_0x1eb4d5[_0x544941(0x2e8)]!==0x4d)throw new Error(_0x544941(0x251)+_0x1eb4d5[_0x544941(0x2e8)]);let _0x33b596=0x0;const _0x3908ce=_0x1eb4d5[_0x544941(0x397)](_0x33b596++),_0x43b8a2=_0x1eb4d5[_0x544941(0x762)](_0x33b596,_0x33b596+0x8);_0x33b596+=0x8;const _0x48053c=_0x1eb4d5[_0x544941(0x3dc)](_0x33b596);_0x33b596+=0x4;const _0x5dc867=_0x1eb4d5[_0x544941(0x762)](_0x33b596);return{'v':_0x3908ce,'licenseHash':_0x43b8a2,'expiry':_0x48053c,'sig':_0x5dc867};}const _0x59815f=0x100,_0x10ec8f=new Set(),_0x2f1c39=new Map();function _0x3df233(_0x1e4fe7,_0x113e51,_0x2344ed){const _0x451ae8=_0x3cfef6;if(typeof _0x2344ed!==_0x451ae8(0x139)||!Buffer['isBuffer'](_0x1e4fe7)||!Buffer[_0x451ae8(0x791)](_0x113e51))return _0x4aef14[_0x451ae8(0x642)](null,_0x1e4fe7,_0x2344ed,_0x113e51);const _0x1ae9d8=_0x2344ed+'\x0a'+_0x1e4fe7[_0x451ae8(0x3cb)]('base64')+'\x0a'+_0x113e51[_0x451ae8(0x3cb)]('base64');if(_0x10ec8f['has'](_0x1ae9d8))return!![];let _0x32d44f=_0x2f1c39[_0x451ae8(0x741)](_0x2344ed);if(!_0x32d44f){_0x32d44f=_0x4aef14[_0x451ae8(0x2a8)](_0x2344ed);if(_0x2f1c39[_0x451ae8(0x54a)]>=0x10)_0x2f1c39['clear']();_0x2f1c39[_0x451ae8(0x543)](_0x2344ed,_0x32d44f);}const _0x438e8f=_0x4aef14['verify'](null,_0x1e4fe7,_0x32d44f,_0x113e51)===!![];if(_0x438e8f){if(_0x10ec8f[_0x451ae8(0x54a)]>=_0x59815f)_0x10ec8f['clear']();_0x10ec8f['add'](_0x1ae9d8);}return _0x438e8f;}function _0x1a42d0({tokenString:_0x4ac79a,nodeId:_0x545106,rawBlobBuf:_0x2bd8db,pubKeyPem:_0x4f9f52,pubFingerprint:_0x2ca9e5}){const _0x4da7f7=_0x3cfef6;let _0x3d5fcb;try{_0x3d5fcb=_0x40acf8(_0x4ac79a);}catch(_0x4694f8){return{'valid':![],'reason':'MALFORMED_TOKEN'};}const _0x4a7f7e=_0x4484e4(_0x2bd8db);if(!_0x4a7f7e[_0x4da7f7(0x6a6)](_0x3d5fcb['licenseHash']))return{'valid':![],'reason':_0x4da7f7(0x63f)};const {pinHmac:_0x595ffc}=_0x2e2a32(_0x545106,_0x4a7f7e,_0x2ca9e5),_0x54e560=Buffer['allocUnsafe'](0x4);_0x54e560['writeUInt32BE'](_0x3d5fcb[_0x4da7f7(0x247)],0x0);const _0x288e3e=Buffer['concat']([Buffer[_0x4da7f7(0x16b)]([_0x3d5fcb['v']]),_0x595ffc['slice'](0x0,0x5),_0x3d5fcb['licenseHash'],_0x54e560]);try{const _0x2cacde=_0x3df233(_0x288e3e,_0x3d5fcb[_0x4da7f7(0x33d)],_0x4f9f52);if(!_0x2cacde)return{'valid':![],'reason':_0x4da7f7(0x31c)};}catch(_0x2fcac7){return{'valid':![],'reason':_0x4da7f7(0x31c)};}if(_0x3d5fcb['expiry']<Date[_0x4da7f7(0x6f1)]()/0x3e8)return{'valid':![],'reason':_0x4da7f7(0x5b4)};return{'valid':!![],'reason':'ok'};}function _0x5983bf(_0x5cc8db){const _0x1f1d6a=_0x3cfef6;if(typeof _0x5cc8db!==_0x1f1d6a(0x139))return _0x1f1d6a(0x5f1);const _0x1f6cef=_0x5cc8db[_0x1f1d6a(0x220)]();if(_0x1f6cef[_0x1f1d6a(0x557)]('/')||_0x1f6cef['startsWith']('./')||_0x1f6cef[_0x1f1d6a(0x557)]('../')||/^[A-Za-z]:[\\/]/['test'](_0x1f6cef))return'path';if(/^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/i[_0x1f1d6a(0x86)](_0x1f6cef))return'uuid';const _0x511a08=_0x1f6cef[_0x1f1d6a(0x61f)](/[\s-]+/g,'')[_0x1f1d6a(0x2e8)];if(_0x511a08===0x7c)return _0x1f1d6a(0x7e);if(_0x511a08>=0x95&&_0x511a08<=0xfc)return _0x1f1d6a(0x409);return _0x1f1d6a(0x5f1);}return okdbLicenseCodec={'toBase32':_0x41c2ac,'fromBase32':_0x4e4654,'encodeLicensePayload':_0x3b4d2c,'decodeLicensePayload':_0x347a44,'encodeLicenseBlob':_0x164240,'decodeLicenseBlob':_0x264490,'licenseHash':_0x4484e4,'derivePin':_0x2e2a32,'encodeActivationToken':_0x52cbb5,'decodeActivationToken':_0x40acf8,'verifyActivation':_0x1a42d0,'verifySignature':_0x3df233,'detectInputType':_0x5983bf,'FEATURE_NAMES':_0x404f4c,'LICENSE_TYPE_STANDARD':_0x4238fb,'LICENSE_TYPE_OPEN':_0xa81036,'LICENSE_TYPE_INTERNAL':_0x533eb0,'OPEN_LICENSE_MAX_DURATION_MS':_0x2a0310},okdbLicenseCodec;}var okdbEnums,hasRequiredOkdbEnums;function requireOkdbEnums(){const _0xe40883=_0x1cb9ed;if(hasRequiredOkdbEnums)return okdbEnums;hasRequiredOkdbEnums=0x1;const _0x1b6325={'PUT':_0xe40883(0x22b),'REMOVE':_0xe40883(0x5ce),'INDEX_DROP':_0xe40883(0x25b),'INDEX_REGISTER':_0xe40883(0x6dd),'INDEX_RESET':_0xe40883(0x4d4),'TYPE_REGISTER':'registerType','TYPE_DROP':_0xe40883(0x4a8),'FTS_REGISTER':_0xe40883(0xc8),'FTS_DROP':'dropFts','FTS_RESET':_0xe40883(0x4d3),'SCHEMA_SET':_0xe40883(0x404),'SCHEMA_DROP':_0xe40883(0x146),'TTL_SET':_0xe40883(0x79f),'TTL_CLEAR':'clearTtl'},_0x4fb1b7={'SYSTEM_READY':_0xe40883(0x55d),'FIELD_RESOLVER_REGISTERED':_0xe40883(0x52b),'SYSTEM_STOPPED':_0xe40883(0x212),'SYSTEM_CLOCK_CHANGE':_0xe40883(0x204),'SYSTEM_POKE':_0xe40883(0x5d9),'SYSTEM_DRAIN':'system:drain','SYSTEM_TYPE_DROP':_0xe40883(0x326),'SYSTEM_PROC':_0xe40883(0x244),'SYSTEM_BUS_STATE_CHANGE':'system:bus_state_change','ITEM_CREATE':'item:create','ITEM_UPDATE':_0xe40883(0x60a),'ITEM_REMOVE':_0xe40883(0xfd),'ITEM_PENDING':'item:pending','INDEX_RESET':_0xe40883(0x40a),'INDEX_READY':_0xe40883(0x387),'INDEX_PROGRESS':_0xe40883(0x506),'VIEW_PROGRESS':_0xe40883(0x22e),'INDEX_DROP':_0xe40883(0x417),'INDEX_REGISTERED':_0xe40883(0x68d),'FTS_REGISTERED':_0xe40883(0x76e),'FTS_DROP':_0xe40883(0x6ed),'FTS_RESET':_0xe40883(0x458),'SCHEMA_SET':_0xe40883(0x3e0),'SCHEMA_DROP':_0xe40883(0xa2),'UNIQUE_VIOLATION':_0xe40883(0x150),'UNIQUE_VIOLATION_RESOLVED':_0xe40883(0x657),'REF_VIOLATION':_0xe40883(0x114),'REF_VIOLATION_RESOLVED':'ref:violation_resolved','SYNC_APPLY':'sync:apply','TXN_START':_0xe40883(0x236),'TXN_END':_0xe40883(0x5f8),'TXN_ROLLBACK':'txn:rollback','TYPE_REGISTERED':_0xe40883(0x45b),'TYPE_DROP':_0xe40883(0x685),'ENV_OPENED':_0xe40883(0x453),'ENV_REMOVED':_0xe40883(0x768),'SYSTEM_ENV_RELEASE':_0xe40883(0x775),'TTL_EXPIRED':_0xe40883(0xfe),'TTL_SET':_0xe40883(0x3b0),'TTL_CLEAR':'ttl:clear','LICENSE_INVALID':_0xe40883(0x712),'LICENSE_ADDED':_0xe40883(0x4d2),'LICENSE_ACTIVATED':'license:activated','LICENSE_REMOVED':_0xe40883(0x1ad)},_0x3f8983={'CREATING':_0xe40883(0x440),'RESETTING':_0xe40883(0x123),'READY':_0xe40883(0x4a5),'DROPPING':_0xe40883(0x1fe),'WAITING':_0xe40883(0x448),'ERROR':'error'},_0x5cdb54={'CREATED':_0xe40883(0x667),'STARTING':_0xe40883(0x62a),'STARTED':_0xe40883(0x1cb),'STOPPING':_0xe40883(0x3ab),'STOPPED':_0xe40883(0x187)},_0x14d78e={'CREATING':'creating','READY':'ready','HALTED':'halted','STOPPED':_0xe40883(0x187),'RESETTING':_0xe40883(0x123)},_0x6a5e0b=Object[_0xe40883(0x23e)]({'POKE':_0xe40883(0x71b),'DRAIN':_0xe40883(0x2e1),'TYPE_DROP':_0xe40883(0xcd),'PROC':_0xe40883(0x182),'ENV_RELEASE':_0xe40883(0x290)});return okdbEnums={'BUS_EVENTS':_0x6a5e0b,'CHANGE_ACTIONS':_0x1b6325,'EVENTS':_0x4fb1b7,'INDEX_STATE':_0x3f8983,'OKDB_STATE':_0x5cdb54,'VIEW_STATE':_0x14d78e},okdbEnums;}var okdbPubkey,hasRequiredOkdbPubkey;function requireOkdbPubkey(){const _0x10ca82=_0x1cb9ed;if(hasRequiredOkdbPubkey)return okdbPubkey;hasRequiredOkdbPubkey=0x1;const _0x4c64c1=require$$0$1,_0x2f780b=require$$1,_0x3789d2=require$$2$1,_0x548f9c=_0x4c64c1['readFileSync'](_0x2f780b['join'](__dirname,_0x10ca82(0x317)),_0x10ca82(0x84))[_0x10ca82(0x220)](),_0x50a0b9=_0x3789d2[_0x10ca82(0x2a8)](_0x548f9c)[_0x10ca82(0x4e2)]({'type':_0x10ca82(0x38c),'format':_0x10ca82(0x6fc)}),_0x55046f=_0x3789d2[_0x10ca82(0x6ba)]('sha256')[_0x10ca82(0x3ec)](_0x50a0b9)[_0x10ca82(0x586)](_0x10ca82(0x52c))[_0x10ca82(0x762)](0x0,0x10);return okdbPubkey={'PUBLIC_KEY_PEM':_0x548f9c,'PUB_FINGERPRINT':_0x55046f},okdbPubkey;}var okdbLicense,hasRequiredOkdbLicense;function requireOkdbLicense(){const _0x3dbb03=_0x1cb9ed;if(hasRequiredOkdbLicense)return okdbLicense;hasRequiredOkdbLicense=0x1;const _0x46a2c7=require$$2$1,{OKDBError:_0x32987e}=requireOkdbError(),{EVENTS:_0x57f20a}=requireOkdbEnums(),_0x4aa288=requireOkdbLicenseCodec(),{LICENSE_TYPE_OPEN:_0x1a2d10,LICENSE_TYPE_INTERNAL:_0x46fe94,OPEN_LICENSE_MAX_DURATION_MS:_0xb95c4d}=_0x4aa288,_0x1655dd=requireOkdbPubkey(),_0x1ecafc={'LICENSED_BUILD':_0x3dbb03(0x509),'PUBLIC_KEY_PEM':_0x1655dd[_0x3dbb03(0x7a0)],'PUB_FINGERPRINT':_0x1655dd[_0x3dbb03(0x398)],'LICENSE_EXPIRED_ACTION':'log'},_0x173688=_0x3dbb03(0x3b4),_0x1d2b78={'features':{'sync':![],'embeddings':!![],'engines':![],'fts':!![],'timeMachine':![],'views':!![],'mcp':!![],'files':!![]},'limits':{'envs':0x5,'typesPerEnv':0xa,'syncPeers':0x0,'maxWrites':0xf4240,'pipelinesPerEnv':0x2},'_isFree':!![]};async function _0x63b37c(_0x139e64){await _0x139e64['ensureType'](_0x173688);}class _0x3aad5a{constructor(_0x5edc39){const _0x2d04e3=_0x3dbb03;this[_0x2d04e3(0x1ea)]=_0x5edc39,this[_0x2d04e3(0x2df)]=null;}async[_0x3dbb03(0x711)](){const _0x53a60d=_0x3dbb03,_0x20f042=this['okdb'][_0x53a60d(0x600)];if(!_0x20f042||!_0x20f042[_0x53a60d(0x59f)](_0x173688)){this['_active']=null;return;}const _0x307be2=this[_0x53a60d(0x1ea)]['id'];let _0x1d9584=null;for(const {key:_0xb23f8f,value:_0x15d7c4}of _0x20f042[_0x53a60d(0x4f6)](_0x173688)){const _0x4fc77d=this[_0x53a60d(0x49d)](_0x15d7c4,_0x307be2);_0x4fc77d===_0x53a60d(0x351)&&!_0x1d9584&&(_0x1d9584={..._0x15d7c4,'id':_0xb23f8f,'status':_0x4fc77d});}this['_active']=_0x1d9584;if(this[_0x53a60d(0x2df)]&&this[_0x53a60d(0x2df)]['licenseType']===_0x1a2d10){const _0x24dc3e=Math[_0x53a60d(0x44d)]((this['_active'][_0x53a60d(0x738)]-Date[_0x53a60d(0x6f1)]())/0x5265c00);this[_0x53a60d(0x1ea)]['log']?.[_0x53a60d(0x27b)](_0x53a60d(0x792)+_0x24dc3e+_0x53a60d(0x5e4),{'feature':'license','licensee':this[_0x53a60d(0x2df)][_0x53a60d(0x511)],'expiresAt':new Date(this[_0x53a60d(0x2df)][_0x53a60d(0x738)])[_0x53a60d(0x165)]()});}this[_0x53a60d(0x2df)]&&this['_active'][_0x53a60d(0x6d3)]===_0x46fe94&&this['okdb'][_0x53a60d(0x219)]?.[_0x53a60d(0x27b)](_0x53a60d(0x158),{'feature':_0x53a60d(0xb2),'licensee':this[_0x53a60d(0x2df)]['licensee']});}['_computeStatus'](_0x405cd4,_0x4d1382){const _0x32fc36=_0x3dbb03;if(!_0x405cd4['blob'])return _0x32fc36(0x6e);let _0x4ec924;try{_0x4ec924=_0x4aa288[_0x32fc36(0xd5)](_0x405cd4['blob']);}catch(_0x517ee0){return _0x32fc36(0x6e);}try{const _0x4cdf35=_0x4aa288[_0x32fc36(0x264)](_0x4ec924[_0x32fc36(0x273)],_0x4ec924[_0x32fc36(0x33d)],_0x1ecafc[_0x32fc36(0x7a0)]);if(!_0x4cdf35)return _0x32fc36(0x6e);}catch(_0x58e5a9){return _0x32fc36(0x6e);}if(_0x4ec924[_0x32fc36(0x224)]['licenseType']===_0x46fe94)return _0x32fc36(0x351);if(_0x4ec924['decoded'][_0x32fc36(0x738)]<=Date['now']())return _0x32fc36(0x2c0);if(_0x4ec924[_0x32fc36(0x224)][_0x32fc36(0x6d3)]===_0x1a2d10)return'active';if(!_0x405cd4[_0x32fc36(0x7e)])return'pending';const _0x1ba367=_0x4aa288[_0x32fc36(0x39c)]({'tokenString':_0x405cd4[_0x32fc36(0x7e)],'nodeId':_0x4d1382,'rawBlobBuf':_0x4ec924[_0x32fc36(0x2bc)],'pubKeyPem':_0x1ecafc[_0x32fc36(0x7a0)],'pubFingerprint':_0x1ecafc[_0x32fc36(0x398)]});if(_0x1ba367[_0x32fc36(0x524)]==='LICENSE_HASH_MISMATCH'||_0x1ba367[_0x32fc36(0x524)]==='SIG_INVALID')return _0x32fc36(0x680);if(_0x1ba367['reason']==='ACTIVATION_EXPIRED')return _0x32fc36(0x2c0);if(!_0x1ba367[_0x32fc36(0x1b8)])return _0x32fc36(0x680);return'active';}get[_0x3dbb03(0x351)](){return this['_active'];}get[_0x3dbb03(0x737)](){return this['_active']??_0x1d2b78;}[_0x3dbb03(0x609)](_0x38b7b6){const _0x23fa4f=_0x3dbb03;if(_0x1ecafc[_0x23fa4f(0x11c)]!==_0x23fa4f(0x509))return;const _0x262e34=this[_0x23fa4f(0x737)];if(!_0x262e34[_0x23fa4f(0x427)]?.[_0x38b7b6]){const _0x400e35=_0x262e34[_0x23fa4f(0x431)]?_0x23fa4f(0x1b0)+_0x38b7b6+'.\x20Add\x20a\x20license\x20that\x20includes\x20\x22'+_0x38b7b6+'\x22\x20to\x20enable\x20it.':_0x23fa4f(0x1df)+_0x38b7b6+'.\x20The\x20active\x20license\x20does\x20not\x20enable\x20\x22'+_0x38b7b6+'\x22.';throw new _0x32987e(_0x400e35,'LICENSE_FEATURE_DISABLED',{'feature':_0x38b7b6});}}[_0x3dbb03(0x166)](_0x3de60c){const _0x406506=_0x3dbb03;if(_0x1ecafc[_0x406506(0x11c)]!==_0x406506(0x509))return!![];return!!this[_0x406506(0x737)][_0x406506(0x427)]?.[_0x3de60c];}[_0x3dbb03(0x6f9)](_0x118265){const _0x174162=_0x3dbb03;if(_0x1ecafc[_0x174162(0x11c)]!==_0x174162(0x509))return![];const _0x144441=this[_0x174162(0x737)]['limits']?.[_0x118265];return!(_0x144441===null||_0x144441===undefined||_0x144441===0x0);}['assertLimit'](_0x548c9b,_0x1448db){const _0x4f4b98=_0x3dbb03;if(_0x1ecafc[_0x4f4b98(0x11c)]!==_0x4f4b98(0x509))return;const _0x422633=this[_0x4f4b98(0x737)],_0x530bf3=_0x422633[_0x4f4b98(0x194)]?.[_0x548c9b];if(_0x530bf3===null||_0x530bf3===undefined||_0x530bf3===0x0)return;if(_0x1448db>=_0x530bf3)throw new _0x32987e(_0x4f4b98(0x118)+_0x548c9b+'\x20('+_0x1448db+'/'+_0x530bf3+')','LICENSE_LIMIT_EXCEEDED',{'limit':_0x548c9b,'current':_0x1448db,'max':_0x530bf3});}async[_0x3dbb03(0x64c)](_0xdfa239){const _0x2c5456=_0x3dbb03;let _0x7b4cb0;try{_0x7b4cb0=_0x4aa288[_0x2c5456(0xd5)](_0xdfa239);}catch(_0x7e2c9f){throw new _0x32987e(_0x2c5456(0x63c)+_0x7e2c9f['message'],_0x2c5456(0x370));}let _0x423362;try{_0x423362=_0x4aa288[_0x2c5456(0x264)](_0x7b4cb0[_0x2c5456(0x273)],_0x7b4cb0['sig'],_0x1ecafc[_0x2c5456(0x7a0)]);}catch(_0x543275){throw new _0x32987e(_0x2c5456(0x74d)+_0x543275[_0x2c5456(0x71d)],_0x2c5456(0x370));}if(!_0x423362)throw new _0x32987e(_0x2c5456(0x607)+(_0x2c5456(0x421)+_0x1ecafc['PUB_FINGERPRINT']+'.\x20')+'Either\x20the\x20build\x20was\x20made\x20with\x20a\x20different\x20keypair,\x20or\x20the\x20license\x20was\x20issued\x20with\x20a\x20different\x20private\x20key.','LICENSE_INVALID',{'expectedFingerprint':_0x1ecafc[_0x2c5456(0x398)]});if(_0x7b4cb0[_0x2c5456(0x224)]['licenseType']===_0x1a2d10){const _0x398e6c=_0x7b4cb0[_0x2c5456(0x224)][_0x2c5456(0x738)]-_0x7b4cb0[_0x2c5456(0x224)][_0x2c5456(0x163)];if(_0x398e6c>_0xb95c4d)throw new _0x32987e(_0x2c5456(0x263)+Math['ceil'](_0x398e6c/(0x1e*0x5265c00))+'\x20months\x20from\x20issuance)','LICENSE_INVALID');}const _0x5690d2=this[_0x2c5456(0x1ea)]['_systemEnv'];await _0x63b37c(_0x5690d2);const _0x4857f7=_0x4aa288['licenseHash'](_0x7b4cb0[_0x2c5456(0x2bc)])['toString'](_0x2c5456(0x52c));for(const {key:_0x4845a6,value:_0x5b8a4b}of _0x5690d2[_0x2c5456(0x4f6)](_0x173688)){if(_0x5b8a4b[_0x2c5456(0x221)]===_0x4857f7)throw new _0x32987e(_0x2c5456(0x74a),_0x2c5456(0x5c9),{'id':_0x4845a6});}const _0x2162c5=_0x46a2c7['createHash']('sha256')[_0x2c5456(0x3ec)]('okdb-license-id:')[_0x2c5456(0x3ec)](_0x7b4cb0[_0x2c5456(0x2bc)])[_0x2c5456(0x586)](_0x2c5456(0x52c)),_0x55d5ea=_0x2162c5[_0x2c5456(0x762)](0x0,0x8)+'-'+_0x2162c5[_0x2c5456(0x762)](0x8,0xc)+'-5'+_0x2162c5[_0x2c5456(0x762)](0xd,0x10)+'-'+(parseInt(_0x2162c5[0x10],0x10)&0x3|0x8)[_0x2c5456(0x3cb)](0x10)+_0x2162c5[_0x2c5456(0x762)](0x11,0x14)+'-'+_0x2162c5[_0x2c5456(0x762)](0x14,0x20),_0x26ba74={'blob':_0xdfa239,'activation':null,'addedAt':Date['now'](),'_licenseHash':_0x4857f7,'licensee':_0x7b4cb0['decoded'][_0x2c5456(0x511)],'expiresAt':_0x7b4cb0[_0x2c5456(0x224)][_0x2c5456(0x738)],'features':_0x7b4cb0[_0x2c5456(0x224)][_0x2c5456(0x427)],'limits':_0x7b4cb0[_0x2c5456(0x224)]['limits'],'licenseType':_0x7b4cb0[_0x2c5456(0x224)][_0x2c5456(0x6d3)]};return await _0x5690d2[_0x2c5456(0x22b)](_0x173688,_0x55d5ea,_0x26ba74),{'id':_0x55d5ea,..._0x26ba74};}async[_0x3dbb03(0x703)](_0x5b18af){const _0x38eb37=_0x3dbb03;let _0x3f0b6d;try{_0x3f0b6d=_0x4aa288[_0x38eb37(0x570)](_0x5b18af);}catch(_0x1f103b){throw new _0x32987e(_0x38eb37(0x200)+_0x1f103b[_0x38eb37(0x71d)],_0x38eb37(0x19a));}const _0x316aa8=_0x3f0b6d[_0x38eb37(0x373)][_0x38eb37(0x3cb)](_0x38eb37(0x52c)),_0x21793b=this[_0x38eb37(0x1ea)][_0x38eb37(0x600)];if(!_0x21793b||!_0x21793b[_0x38eb37(0x59f)](_0x173688))throw new _0x32987e(_0x38eb37(0x11a),_0x38eb37(0x19a));let _0x5a06ff=null,_0x438325=null;for(const {key:_0x159959,value:_0x463379}of _0x21793b['getRange'](_0x173688)){if(_0x463379[_0x38eb37(0x221)]===_0x316aa8){_0x5a06ff=_0x159959,_0x438325=_0x463379;break;}}if(!_0x5a06ff)throw new _0x32987e(_0x38eb37(0x11a),'LICENSE_ACTIVATION_INVALID');const {rawBuf:_0x46fb39}=_0x4aa288[_0x38eb37(0xd5)](_0x438325['blob']),_0x36dbdb=_0x4aa288[_0x38eb37(0x39c)]({'tokenString':_0x5b18af,'nodeId':this['okdb']['id'],'rawBlobBuf':_0x46fb39,'pubKeyPem':_0x1ecafc[_0x38eb37(0x7a0)],'pubFingerprint':_0x1ecafc[_0x38eb37(0x398)]});if(!_0x36dbdb['valid'])throw new _0x32987e('Activation\x20invalid:\x20'+_0x36dbdb[_0x38eb37(0x524)],_0x38eb37(0x19a),{'reason':_0x36dbdb[_0x38eb37(0x524)]});const _0x1a9831={..._0x438325,'activation':_0x5b18af};return await _0x21793b[_0x38eb37(0x3ec)](_0x173688,_0x5a06ff,_0x1a9831),{'id':_0x5a06ff,..._0x1a9831};}async[_0x3dbb03(0x6ca)](_0xce3462){const _0x5985e1=_0x3dbb03,_0x8a03f7=this[_0x5985e1(0x1ea)][_0x5985e1(0x600)];if(!_0x8a03f7||!_0x8a03f7[_0x5985e1(0x59f)](_0x173688))return;await _0x8a03f7['remove'](_0x173688,_0xce3462);}async[_0x3dbb03(0x2c1)](){const _0x44d663=_0x3dbb03,_0x554a9f=this['okdb'][_0x44d663(0x600)];if(!_0x554a9f||!_0x554a9f['hasType'](_0x173688))return[];const _0x2afabe=this[_0x44d663(0x1ea)]['id'],_0x1229ba=[];for(const {key:_0x202d9f,value:_0x349c25}of _0x554a9f[_0x44d663(0x4f6)](_0x173688)){const _0xcdc588=this['_computeStatus'](_0x349c25,_0x2afabe);_0x1229ba['push']({..._0x349c25,'id':_0x202d9f,'status':_0xcdc588});}return _0x1229ba;}[_0x3dbb03(0x490)](){const _0xc731e1=_0x3dbb03,_0x4562fa=this['okdb'][_0xc731e1(0x600)];if(!_0x4562fa||!_0x4562fa[_0xc731e1(0x59f)](_0x173688))return[];const _0x3dd671=this[_0xc731e1(0x1ea)]['id'],_0x1ddfa0=[];for(const {key:_0x4ef66a,value:_0x1ee3da}of _0x4562fa['getRange'](_0x173688)){if(_0x1ee3da['_licenseHash']){if(_0x1ee3da[_0xc731e1(0x6d3)]===_0x1a2d10)_0x1ddfa0[_0xc731e1(0x1c2)]({'licenseId':_0x4ef66a,'pin':null});else{const _0x52cb51=Buffer[_0xc731e1(0x16b)](_0x1ee3da[_0xc731e1(0x221)],_0xc731e1(0x52c)),{pin:_0x20eb53}=_0x4aa288[_0xc731e1(0x79a)](_0x3dd671,_0x52cb51,_0x1ecafc[_0xc731e1(0x398)]);_0x1ddfa0['push']({'licenseId':_0x4ef66a,'pin':_0x20eb53});}}}return _0x1ddfa0;}async[_0x3dbb03(0x1a9)](){const _0x5a83f=_0x3dbb03,_0x5ad7e0=this[_0x5a83f(0x2df)];await this[_0x5a83f(0x711)]();if(this[_0x5a83f(0x2df)]&&this[_0x5a83f(0x2df)][_0x5a83f(0x6d3)]===_0x1a2d10){const _0x5dd18c=Math[_0x5a83f(0x44d)]((this['_active']['expiresAt']-Date[_0x5a83f(0x6f1)]())/0x5265c00);this[_0x5a83f(0x1ea)]['log']?.[_0x5a83f(0x27b)](_0x5a83f(0x792)+_0x5dd18c+_0x5a83f(0x5e4),{'feature':_0x5a83f(0xb2),'licensee':this['_active'][_0x5a83f(0x511)],'expiresAt':new Date(this['_active'][_0x5a83f(0x738)])[_0x5a83f(0x165)]()});}this[_0x5a83f(0x2df)]&&this[_0x5a83f(0x2df)][_0x5a83f(0x6d3)]===_0x46fe94&&this[_0x5a83f(0x1ea)][_0x5a83f(0x219)]?.['warn'](_0x5a83f(0x158),{'feature':'license','licensee':this['_active']['licensee']});if(_0x5ad7e0&&!this[_0x5a83f(0x2df)]){this[_0x5a83f(0x1ea)]['log']?.[_0x5a83f(0x27b)](_0x5a83f(0x4c7),{'feature':_0x5a83f(0xb2)}),this['okdb'][_0x5a83f(0x599)]?.[_0x5a83f(0x454)](_0x57f20a[_0x5a83f(0x370)],{'previous':_0x5ad7e0});const _0x1f2adb=this['okdb'][_0x5a83f(0x5ba)]?.[_0x5a83f(0x523)]??_0x1ecafc[_0x5a83f(0x91)];_0x1f2adb===_0x5a83f(0x521)&&(this['okdb'][_0x5a83f(0x219)]?.[_0x5a83f(0x1da)]('Shutting\x20down\x20due\x20to\x20license\x20expiry',{'feature':_0x5a83f(0xb2)}),this[_0x5a83f(0x1ea)][_0x5a83f(0x57b)]()[_0x5a83f(0x31d)](()=>{})[_0x5a83f(0xcf)](()=>process[_0x5a83f(0x2e9)](0x1)));}}}return okdbLicense={'LicenseChecker':_0x3aad5a,'_C':_0x1ecafc,'FREE_TIER':_0x1d2b78},okdbLicense;}var okdbShell,hasRequiredOkdbShell;function requireOkdbShell(){const _0x105fc9=_0x1cb9ed;if(hasRequiredOkdbShell)return okdbShell;hasRequiredOkdbShell=0x1;const _0x555bea=require$$0$3,_0x55bb38=require$$0$1,_0x282fa4=require$$0,_0xfa7dd4=require$$1,_0x41194d=_0xfa7dd4[_0x105fc9(0x546)](_0x282fa4[_0x105fc9(0x218)](),_0x105fc9(0x508)),_0xdac776=0x3e8,_0x586886={'reset':'\x1b[0m','bold':'\x1b[1m','dim':_0x105fc9(0x451),'red':'\x1b[31m','green':_0x105fc9(0xba),'yellow':_0x105fc9(0x2ee),'blue':_0x105fc9(0x661),'magenta':_0x105fc9(0x65b),'cyan':_0x105fc9(0x42a),'white':'\x1b[37m','gray':'\x1b[90m'},_0x569d9c=!process[_0x105fc9(0x27e)]['isTTY']||!!process.env.NO_COLOR,_0x589bf5=(_0x115a45,_0x5c41cf)=>_0x569d9c?_0x5c41cf:''+_0x115a45+_0x5c41cf+_0x586886[_0x105fc9(0x34e)],_0x2c2b9a={'error':_0x586886['red'],'warn':_0x586886[_0x105fc9(0x360)],'info':_0x586886['cyan'],'debug':_0x586886[_0x105fc9(0x699)]},_0x991bf9={'debug':0x0,'info':0x1,'warn':0x2,'error':0x3};function _0xadd747(_0x1153c4,_0x2e664b=_0x105fc9(0x1b9)){const _0x435d85=_0x105fc9,{level:_0x163a63,msg:_0x3fd04b,meta:_0x33acb0,context:_0x4cd21d,ts:_0x2c32ec}=_0x1153c4;if((_0x991bf9[_0x163a63]??0x1)<(_0x991bf9[_0x2e664b]??0x1))return;const _0x3211fa=_0x589bf5(_0x586886[_0x435d85(0x699)],new Date(_0x2c32ec)[_0x435d85(0x165)]()),_0x24aec6=_0x589bf5(_0x2c2b9a[_0x163a63]??_0x586886[_0x435d85(0x32d)],_0x163a63[_0x435d85(0x6e3)](0x5));let _0xff2a54='\x20\x20'+_0x3211fa+'\x20'+_0x589bf5(_0x586886[_0x435d85(0x162)],_0x24aec6)+'\x20'+_0x3fd04b;if(_0x33acb0&&Object[_0x435d85(0x449)](_0x33acb0)['length']>0x0){const _0x1ac49b=Object[_0x435d85(0x377)](_0x33acb0)[_0x435d85(0x362)](([_0x45c2e8,_0x422b3d])=>_0x45c2e8+'='+_0x422b3d)[_0x435d85(0x546)]('\x20');_0xff2a54+=_0x589bf5(_0x586886[_0x435d85(0x79d)],_0x435d85(0x44a)+_0x1ac49b+']');}if(_0x4cd21d!==undefined){const _0x36efd4=typeof _0x4cd21d===_0x435d85(0x25a)?JSON['stringify'](_0x4cd21d):String(_0x4cd21d);_0xff2a54+=_0x589bf5(_0x586886['dim'],'\x20\x20'+_0x36efd4);}const _0x376df6=_0x163a63==='error'||_0x163a63==='warn'?process['stderr'][_0x435d85(0xc6)][_0x435d85(0x4b8)](process[_0x435d85(0x544)]):process[_0x435d85(0x27e)]['write'][_0x435d85(0x4b8)](process['stdout']);_0x376df6(_0xff2a54+'\x0a');}function _0x395a05(_0x4a0fe5,_0x1f27cb){const _0x6190ec=_0x105fc9;if(_0x4a0fe5===0xcc||_0x4a0fe5>=0xc8&&_0x4a0fe5<0x12c&&!_0x1f27cb){console['log'](_0x6190ec(0xce)+_0x589bf5(_0x586886[_0x6190ec(0x433)],'✓')+'\x0a');return;}if(_0x4a0fe5>=0x190||_0x1f27cb?.['error']){const _0x230a8d=_0x1f27cb?.[_0x6190ec(0x1da)]??_0x1f27cb?.[_0x6190ec(0x71d)]??_0x6190ec(0x329)+_0x4a0fe5;console['log'](_0x6190ec(0xce)+_0x589bf5(_0x586886['red'],'✗')+'\x20'+_0x589bf5(_0x586886['bold']+_0x586886[_0x6190ec(0x4bf)],String(_0x4a0fe5))+'\x20\x20'+_0x230a8d+'\x0a');return;}const _0x12c3eb=Object[_0x6190ec(0x62f)][_0x6190ec(0x34a)][_0x6190ec(0x70d)](_0x1f27cb??{},_0x6190ec(0x468))?_0x1f27cb[_0x6190ec(0x468)]:_0x1f27cb,_0x58f97f=_0x1f27cb?.[_0x6190ec(0x57f)];console['log'](''),_0x222e40(_0x12c3eb,'\x20\x20');if(_0x58f97f?.[_0x6190ec(0x6b4)]!=null||_0x58f97f?.['time']!=null){const _0x46896a=[];if(_0x58f97f[_0x6190ec(0x6b4)]!=null)_0x46896a[_0x6190ec(0x1c2)](_0x58f97f['count']+_0x6190ec(0x15b)+(_0x58f97f['count']!==0x1?'s':''));if(_0x58f97f['time']!=null)_0x46896a[_0x6190ec(0x1c2)](_0x58f97f[_0x6190ec(0x2be)]+'ms');console[_0x6190ec(0x219)](_0x6190ec(0xce)+_0x589bf5(_0x586886[_0x6190ec(0x79d)],_0x46896a[_0x6190ec(0x546)](_0x6190ec(0x5d8))));}console[_0x6190ec(0x219)]('');}function _0x222e40(_0x25cda1,_0x239fd0=''){const _0x162bbe=_0x105fc9;if(_0x25cda1===null||_0x25cda1===undefined){console[_0x162bbe(0x219)](_0x239fd0+_0x589bf5(_0x586886[_0x162bbe(0x79d)],'(null)'));return;}if(Array['isArray'](_0x25cda1)){if(_0x25cda1[_0x162bbe(0x2e8)]===0x0){console['log'](_0x239fd0+_0x589bf5(_0x586886[_0x162bbe(0x79d)],_0x162bbe(0x716)));return;}if(_0x25cda1[_0x162bbe(0x6a5)](_0x213f13=>_0x213f13&&typeof _0x213f13==='object'&&'key'in _0x213f13&&_0x162bbe(0x1c5)in _0x213f13)){_0x2e3ab5(_0x25cda1,_0x239fd0);return;}if(_0x25cda1[_0x162bbe(0x6a5)](_0x19d555=>_0x19d555&&typeof _0x19d555===_0x162bbe(0x25a)&&'type'in _0x19d555&&_0x162bbe(0x6b4)in _0x19d555)){_0x31d7ad(_0x25cda1,_0x239fd0);return;}if(_0x25cda1[_0x162bbe(0x6a5)](_0x4bab1c=>typeof _0x4bab1c!==_0x162bbe(0x25a)||_0x4bab1c===null)){_0x25cda1[_0x162bbe(0x35b)]((_0x206441,_0x5b68ef)=>console[_0x162bbe(0x219)](_0x239fd0+_0x589bf5(_0x586886['gray'],_0x5b68ef+0x1+'.')+'\x20'+_0x589bf5(_0x586886[_0x162bbe(0x32d)],String(_0x206441))));return;}_0x25cda1['forEach']((_0x1ee49f,_0x460cf5)=>{const _0x25006a=_0x162bbe;console[_0x25006a(0x219)](_0x239fd0+_0x589bf5(_0x586886[_0x25006a(0x79d)],'['+_0x460cf5+']'));if(typeof _0x1ee49f===_0x25006a(0x25a)&&_0x1ee49f!==null)_0x938e8f(_0x1ee49f,_0x239fd0+'\x20\x20');else console[_0x25006a(0x219)](_0x239fd0+'\x20\x20'+String(_0x1ee49f));});return;}if(typeof _0x25cda1===_0x162bbe(0x25a)){if('key'in _0x25cda1&&_0x162bbe(0x1c5)in _0x25cda1&&Object['keys'](_0x25cda1)[_0x162bbe(0x2e8)]<=0x3){console[_0x162bbe(0x219)](_0x239fd0+_0x589bf5(_0x586886['bold']+_0x586886['cyan'],String(_0x25cda1[_0x162bbe(0x1cd)])));const _0x272707=_0x25cda1['value'];if(_0x272707&&typeof _0x272707===_0x162bbe(0x25a))_0x938e8f(_0x272707,_0x239fd0);else console[_0x162bbe(0x219)](_0x239fd0+_0x589bf5(_0x586886[_0x162bbe(0x32d)],String(_0x272707)));return;}_0x938e8f(_0x25cda1,_0x239fd0);return;}console[_0x162bbe(0x219)](_0x239fd0+_0x589bf5(_0x586886[_0x162bbe(0x32d)],String(_0x25cda1)));}function _0x938e8f(_0x196571,_0x793d44=''){const _0x224723=_0x105fc9,_0xbe4873=Object[_0x224723(0x377)](_0x196571);if(_0xbe4873[_0x224723(0x2e8)]===0x0){console[_0x224723(0x219)](_0x793d44+_0x589bf5(_0x586886[_0x224723(0x79d)],'{}'));return;}const _0x501cf8=Math['min'](0x1c,Math['max'](..._0xbe4873[_0x224723(0x362)](([_0x4ac24f])=>_0x4ac24f['length'])));for(const [_0x4146a7,_0x558ee0]of _0xbe4873){const _0x22852f=_0x589bf5(_0x586886[_0x224723(0x763)],_0x4146a7[_0x224723(0x6e3)](_0x501cf8));if(_0x558ee0===null||_0x558ee0===undefined)console[_0x224723(0x219)](_0x793d44+_0x22852f+'\x20\x20'+_0x589bf5(_0x586886[_0x224723(0x79d)],_0x224723(0x5d2)));else{if(typeof _0x558ee0===_0x224723(0x25a)){const _0x40e3af=JSON['stringify'](_0x558ee0);_0x40e3af[_0x224723(0x2e8)]<=0x50?console[_0x224723(0x219)](_0x793d44+_0x22852f+'\x20\x20'+_0x589bf5(_0x586886[_0x224723(0x79d)],_0x40e3af)):(console[_0x224723(0x219)](_0x793d44+_0x22852f),_0x222e40(_0x558ee0,_0x793d44+'\x20\x20'));}else{const _0x1c8f04=typeof _0x558ee0===_0x224723(0x610)?_0x589bf5(_0x558ee0?_0x586886[_0x224723(0x433)]:_0x586886[_0x224723(0x360)],String(_0x558ee0)):typeof _0x558ee0===_0x224723(0x3f5)?_0x589bf5(_0x586886[_0x224723(0x54c)],String(_0x558ee0)):_0x589bf5(_0x586886[_0x224723(0x32d)],String(_0x558ee0));console[_0x224723(0x219)](_0x793d44+_0x22852f+'\x20\x20'+_0x1c8f04);}}}}function _0x2e3ab5(_0x204a9a,_0x199934=''){const _0x483040=_0x105fc9,_0x2751ac=Math[_0x483040(0x437)](0x20,Math['max'](..._0x204a9a[_0x483040(0x362)](_0x3fdb49=>String(_0x3fdb49[_0x483040(0x1cd)])[_0x483040(0x2e8)])));for(const {key:_0x10372b,value:_0x31b527,score:_0x470d30,clock:_0x3904de}of _0x204a9a){const _0xecfaa3=_0x589bf5(_0x586886[_0x483040(0x162)]+_0x586886[_0x483040(0x763)],String(_0x10372b)[_0x483040(0x6e3)](_0x2751ac)),_0x3cf9f0=_0x31b527==null?_0x589bf5(_0x586886['dim'],_0x483040(0x5d2)):typeof _0x31b527===_0x483040(0x25a)?_0x589bf5(_0x586886[_0x483040(0x79d)],JSON['stringify'](_0x31b527)):_0x589bf5(_0x586886[_0x483040(0x32d)],String(_0x31b527)),_0x3d6e7c=_0x470d30!=null?_0x589bf5(_0x586886['gray'],_0x483040(0x1bc)+_0x470d30[_0x483040(0x12a)](0x4)):'',_0x3f4ecd=_0x3904de!=null?_0x589bf5(_0x586886[_0x483040(0x699)],_0x483040(0x23a)+_0x3904de):'';console[_0x483040(0x219)](_0x199934+_0xecfaa3+'\x20\x20'+_0x3cf9f0+_0x3d6e7c+_0x3f4ecd);}}function _0x31d7ad(_0x2d3574,_0x38865=''){const _0xa49788=_0x105fc9,_0x7c59e1=Math[_0xa49788(0x437)](0x20,Math[_0xa49788(0x608)](..._0x2d3574[_0xa49788(0x362)](_0x13eb41=>_0x13eb41[_0xa49788(0x5be)][_0xa49788(0x2e8)])));for(const {type:_0x5f056c,count:_0x57168b,fields:_0x30ebc9}of _0x2d3574){if(_0x5f056c[_0xa49788(0x557)]('~'))continue;const _0x482925=_0x589bf5(_0x586886[_0xa49788(0x162)]+_0x586886[_0xa49788(0x763)],_0x5f056c[_0xa49788(0x6e3)](_0x7c59e1)),_0xafab25=_0x589bf5(_0x586886[_0xa49788(0x54c)],String(_0x57168b)['padStart'](0x6))+_0x589bf5(_0x586886[_0xa49788(0x79d)],'\x20records'),_0x6963e6=_0x30ebc9&&Object['keys'](_0x30ebc9)[_0xa49788(0x2e8)]?_0x589bf5(_0x586886[_0xa49788(0x79d)],_0xa49788(0x51d)+Object['keys'](_0x30ebc9)[_0xa49788(0x762)](0x0,0x6)['join'](',\x20')+(Object['keys'](_0x30ebc9)[_0xa49788(0x2e8)]>0x6?'…':'')):'';console[_0xa49788(0x219)](_0x38865+_0x482925+'\x20\x20'+_0xafab25+_0x6963e6);}}const _0x1321fd=[_0x105fc9(0x4e6),_0x105fc9(0x242),_0x105fc9(0x36b),_0x105fc9(0x78),'transaction','processors/'];function _0x162f95(_0x37b844,_0x5643c9){const _0xe2ab27=_0x105fc9;if(_0x37b844['startsWith'](_0xe2ab27(0x6b9)))return _0x37b844;if(_0x37b844['startsWith']('/'))return _0xe2ab27(0x784)+_0x37b844;if(_0x37b844['startsWith'](_0xe2ab27(0x3f6)))return _0xe2ab27(0x6b9)+_0x37b844;const _0x1969d7=_0x1321fd['some'](_0x101b5f=>_0x37b844===_0x101b5f[_0xe2ab27(0x61f)](/\/$/,'')||_0x37b844[_0xe2ab27(0x557)](_0x101b5f));return _0x1969d7?'/api/env/'+_0x5643c9+'/'+_0x37b844:_0xe2ab27(0x6b9)+_0x37b844;}function _0x7146b4(_0x5ec60d){const _0x5e9347=_0x105fc9,_0x2e180d={},_0x332064=[];let _0x4408a1=0x0;while(_0x4408a1<_0x5ec60d[_0x5e9347(0x2e8)]){if((_0x5ec60d[_0x4408a1]===_0x5e9347(0x284)||_0x5ec60d[_0x4408a1]==='-e')&&_0x5ec60d[_0x4408a1+0x1]&&!_0x5ec60d[_0x4408a1+0x1]['startsWith']('-'))_0x2e180d[_0x5e9347(0x514)]=_0x5ec60d[++_0x4408a1];else _0x5ec60d[_0x4408a1]===_0x5e9347(0x5ef)||_0x5ec60d[_0x4408a1]==='-h'?_0x2e180d[_0x5e9347(0x693)]=!![]:_0x332064[_0x5e9347(0x1c2)](_0x5ec60d[_0x4408a1]);_0x4408a1++;}return{'flags':_0x2e180d,'rest':_0x332064};}const _0x547e88={'system':_0x105fc9(0x5bb),'envs':_0x105fc9(0x420),'types':_0x105fc9(0x2ab),'data':_0x105fc9(0x12d),'indexes':_0x105fc9(0x59b),'fts':_0x105fc9(0x2da),'sync':_0x105fc9(0x726),'queue':'Queue','files':_0x105fc9(0x623),'embeddings':_0x105fc9(0x704),'engines':_0x105fc9(0x3e8),'admin':_0x105fc9(0x245),'event':_0x105fc9(0x517),'processor':_0x105fc9(0x4c6)},_0x53fcf3=[_0x105fc9(0x374),_0x105fc9(0xb1),'types',_0x105fc9(0x516),_0x105fc9(0x1c8),_0x105fc9(0x388),'sync',_0x105fc9(0x54f),_0x105fc9(0x567),_0x105fc9(0x760),_0x105fc9(0x1d6),'admin'];function _0x404760(_0x462448){const _0x5d75e2=_0x105fc9;return _0x462448[_0x5d75e2(0x61f)](/^\/api/,'')[_0x5d75e2(0x61f)](/^\[\/env\/:env=[^\]]*\]/,_0x5d75e2(0x30d))[_0x5d75e2(0x61f)](/^\/env\/:env/,_0x5d75e2(0x148))[_0x5d75e2(0x61f)](/^\//,'');}function _0x2927bf(_0x5b5869,_0x76dedf=''){const _0x192942=_0x105fc9,_0x3f7e1d=_0x5b5869[_0x192942(0x1be)][_0x192942(0x3c7)]()[_0x192942(0x20f)](_0x10f94b=>!_0x10f94b[_0x192942(0x57f)]?.['hidden']),_0x5d847d=_0x76dedf?_0x3f7e1d[_0x192942(0x20f)](_0x29cf4c=>_0x29cf4c['path'][_0x192942(0x36c)]()['includes'](_0x76dedf[_0x192942(0x36c)]())||(_0x4def03(_0x29cf4c)??'')[_0x192942(0x36c)]()['includes'](_0x76dedf[_0x192942(0x36c)]())||_0x4d561d(_0x29cf4c)[_0x192942(0x21d)](_0x54bf40=>_0x54bf40['toLowerCase']()[_0x192942(0x243)](_0x76dedf[_0x192942(0x36c)]()))):_0x3f7e1d;if(!_0x5d847d[_0x192942(0x2e8)]){console[_0x192942(0x219)](_0x589bf5(_0x586886[_0x192942(0x360)],'\x0a\x20\x20No\x20routes\x20matching\x20\x22'+_0x76dedf+'\x22\x0a'));return;}const _0x45074f=new Map();for(const _0x31a2ee of _0x5d847d){const _0x2756ea=_0x4d561d(_0x31a2ee)[0x0]??'other';if(!_0x45074f[_0x192942(0x783)](_0x2756ea))_0x45074f['set'](_0x2756ea,[]);_0x45074f[_0x192942(0x741)](_0x2756ea)[_0x192942(0x1c2)](_0x31a2ee);}const _0x2f1f76=[..._0x53fcf3['filter'](_0x133a6d=>_0x45074f['has'](_0x133a6d)),...[..._0x45074f[_0x192942(0x449)]()][_0x192942(0x20f)](_0x54c154=>!_0x53fcf3[_0x192942(0x243)](_0x54c154))];console['log']('');for(const _0x3f660c of _0x2f1f76){const _0x1ea58d=_0x45074f['get'](_0x3f660c);if(!_0x1ea58d?.[_0x192942(0x2e8)])continue;console[_0x192942(0x219)](_0x589bf5(_0x586886[_0x192942(0x162)],'\x20\x20'+(_0x547e88[_0x3f660c]??_0x3f660c)));for(const _0x5d2370 of _0x1ea58d){const _0x4a73a7=_0x589bf5(_0x586886[_0x192942(0x54c)],_0x5d2370['method'][_0x192942(0x6e3)](0x7)),_0x2b6304=_0x589bf5(_0x586886[_0x192942(0x763)],_0x404760(_0x5d2370[_0x192942(0x2cc)])),_0x28b365=_0x4def03(_0x5d2370)?_0x589bf5(_0x586886['dim'],'\x20\x20'+_0x4def03(_0x5d2370)):'',_0x991753=_0x5d2370[_0x192942(0x658)]?.['id']?_0x589bf5(_0x586886[_0x192942(0x699)],_0x192942(0x44a)+_0x5d2370[_0x192942(0x658)]['id']+']'):'';console[_0x192942(0x219)](_0x192942(0x66e)+_0x4a73a7+'\x20'+_0x2b6304+_0x28b365+_0x991753);}console[_0x192942(0x219)]('');}}function _0x4e8b99(_0x4e31f5,_0x7c1512){const _0x5c5215=_0x105fc9,_0xd0823=_0x7c1512[_0x5c5215(0x61f)](/^\/api(\/env\/[^/]+)?\//,'')[_0x5c5215(0x527)]('/')[0x0],_0x378fe0=_0x4e31f5[_0x5c5215(0x1be)][_0x5c5215(0x3c7)]()[_0x5c5215(0x20f)](_0x5a7c3a=>_0x5a7c3a[_0x5c5215(0x2cc)][_0x5c5215(0x36c)]()[_0x5c5215(0x243)](_0xd0823[_0x5c5215(0x36c)]()));if(!_0x378fe0[_0x5c5215(0x2e8)]){console[_0x5c5215(0x219)](_0x589bf5(_0x586886['yellow'],'\x0a\x20\x20No\x20documentation\x20found\x20for:\x20'+_0x7c1512+'\x0a'));return;}console['log']('');for(const _0x34f80e of _0x378fe0['slice'](0x0,0xc)){for(const _0x20e3e8 of _0x53f515(_0x34f80e)){console[_0x5c5215(0x219)](_0x20e3e8);}console[_0x5c5215(0x219)]('');}}function _0x4def03(_0x59414d){const _0x48779f=_0x105fc9;return _0x59414d['operation']?.[_0x48779f(0x21b)]??_0x59414d[_0x48779f(0x57f)]?.[_0x48779f(0x21b)]??'';}function _0x4911f9(_0x332a31){const _0x11309f=_0x105fc9;return _0x332a31['operation']?.['description']??_0x332a31['meta']?.[_0x11309f(0x689)]??'';}function _0x4d561d(_0x2fd6ff){const _0x55b219=_0x105fc9;return _0x2fd6ff[_0x55b219(0x658)]?.[_0x55b219(0x5f0)]?.[_0x55b219(0x2e8)]?_0x2fd6ff[_0x55b219(0x658)][_0x55b219(0x5f0)]:_0x2fd6ff[_0x55b219(0x57f)]?.[_0x55b219(0x5f0)]??[];}function _0x53f515(_0x14959b){const _0x47e95c=_0x105fc9,_0x27e36a=[];_0x27e36a['push']('\x20\x20'+_0x589bf5(_0x586886['bold']+_0x586886[_0x47e95c(0x54c)],_0x14959b['method']['padEnd'](0x7))+'\x20'+_0x589bf5(_0x586886[_0x47e95c(0x162)]+_0x586886[_0x47e95c(0x763)],_0x14959b[_0x47e95c(0x2cc)]));_0x14959b[_0x47e95c(0x658)]?.['id']&&_0x27e36a[_0x47e95c(0x1c2)](_0x47e95c(0x593)+_0x589bf5(_0x586886['gray'],'id:\x20'+_0x14959b['operation']['id']));_0x4def03(_0x14959b)&&_0x27e36a[_0x47e95c(0x1c2)]('\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20'+_0x589bf5(_0x586886[_0x47e95c(0x32d)],_0x4def03(_0x14959b)));_0x4911f9(_0x14959b)&&_0x27e36a[_0x47e95c(0x1c2)](_0x47e95c(0x593)+_0x589bf5(_0x586886['dim'],_0x4911f9(_0x14959b)));_0x4d561d(_0x14959b)[_0x47e95c(0x2e8)]&&_0x27e36a['push']('\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20'+_0x589bf5(_0x586886['gray'],_0x47e95c(0x41c)+_0x4d561d(_0x14959b)['join'](',\x20')));_0x14959b[_0x47e95c(0x658)]?.[_0x47e95c(0x6b5)]?.[_0x47e95c(0x2d6)]&&_0x27e36a[_0x47e95c(0x1c2)](_0x47e95c(0x593)+_0x589bf5(_0x586886['gray'],'access:\x20'+_0x14959b[_0x47e95c(0x658)][_0x47e95c(0x6b5)][_0x47e95c(0x2d6)]));_0x14959b['operation']?.['http']?.['transport']&&_0x14959b[_0x47e95c(0x658)][_0x47e95c(0x1be)][_0x47e95c(0x69b)]!==_0x47e95c(0x561)&&_0x27e36a['push'](_0x47e95c(0x593)+_0x589bf5(_0x586886[_0x47e95c(0x699)],_0x47e95c(0x53b)+_0x14959b[_0x47e95c(0x658)][_0x47e95c(0x1be)][_0x47e95c(0x69b)]));if(_0x14959b[_0x47e95c(0x658)]?.[_0x47e95c(0x2e6)]){const _0x193285=Object[_0x47e95c(0x449)](_0x14959b[_0x47e95c(0x658)]['inputSchema'][_0x47e95c(0x77d)]||{});if(_0x193285[_0x47e95c(0x2e8)])_0x27e36a[_0x47e95c(0x1c2)]('\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20'+_0x589bf5(_0x586886[_0x47e95c(0x699)],_0x47e95c(0x574)+_0x193285[_0x47e95c(0x546)](',\x20')));}return _0x14959b[_0x47e95c(0x57f)]?.['body']&&_0x27e36a['push'](_0x47e95c(0x593)+_0x589bf5(_0x586886[_0x47e95c(0x699)],'body:\x20'+JSON[_0x47e95c(0x5bd)](_0x14959b['meta'][_0x47e95c(0x772)]))),_0x27e36a;}async function _0x227b11(_0x373ad2,_0x31ace2,_0x363ef6,_0x4055db=null){const _0x12cb02=_0x105fc9,_0x57f00c=_0x363ef6[_0x12cb02(0x6b0)]('?'),_0x2c47ae=_0x57f00c>=0x0?_0x363ef6[_0x12cb02(0x762)](0x0,_0x57f00c):_0x363ef6,_0x5ec650=_0x57f00c>=0x0?_0x363ef6[_0x12cb02(0x762)](_0x57f00c+0x1):'',_0x36f05d=Object['fromEntries'](new URLSearchParams(_0x5ec650)['entries']());return _0x373ad2[_0x12cb02(0x1be)][_0x12cb02(0x31f)](_0x31ace2,_0x2c47ae,{'body':_0x4055db,'query':_0x36f05d,'headers':{'content-type':_0x12cb02(0x766)}},{'internal':!![]});}function _0x2e5d15(_0x5c7b73){const _0x507460=_0x105fc9;if(!_0x5c7b73)return null;const _0x1ede3e=_0x5c7b73[_0x507460(0x220)]();if(!_0x1ede3e)return null;try{return JSON[_0x507460(0x110)](_0x1ede3e);}catch{}try{return JSON[_0x507460(0x110)](_0x495063(_0x1ede3e));}catch(_0x581269){throw new SyntaxError(_0x581269[_0x507460(0x71d)],{'cause':_0x581269});}}function _0x495063(_0x456247){const _0x5b206e=_0x105fc9;let _0x3b79d0='',_0x54fba5=0x0;while(_0x54fba5<_0x456247[_0x5b206e(0x2e8)]){const _0x50d68e=_0x456247[_0x54fba5];if(_0x50d68e==='\x22'){_0x3b79d0+='\x22',_0x54fba5++;while(_0x54fba5<_0x456247[_0x5b206e(0x2e8)]&&_0x456247[_0x54fba5]!=='\x22'){if(_0x456247[_0x54fba5]==='\x5c'){_0x3b79d0+=_0x456247[_0x54fba5++];if(_0x54fba5<_0x456247[_0x5b206e(0x2e8)])_0x3b79d0+=_0x456247[_0x54fba5++];}else _0x3b79d0+=_0x456247[_0x54fba5++];}_0x3b79d0+='\x22';if(_0x54fba5<_0x456247[_0x5b206e(0x2e8)])_0x54fba5++;continue;}if(_0x50d68e==='\x27'){_0x3b79d0+='\x22',_0x54fba5++;while(_0x54fba5<_0x456247[_0x5b206e(0x2e8)]&&_0x456247[_0x54fba5]!=='\x27'){if(_0x456247[_0x54fba5]==='\x5c'&&_0x456247[_0x54fba5+0x1]==='\x27')_0x3b79d0+='\x27',_0x54fba5+=0x2;else _0x456247[_0x54fba5]==='\x22'?(_0x3b79d0+='\x5c\x22',_0x54fba5++):_0x3b79d0+=_0x456247[_0x54fba5++];}_0x3b79d0+='\x22';if(_0x54fba5<_0x456247[_0x5b206e(0x2e8)])_0x54fba5++;continue;}if(_0x5b206e(0x630)[_0x5b206e(0x243)](_0x50d68e)){_0x3b79d0+=_0x50d68e,_0x54fba5++;continue;}let _0x56ca5a='';while(_0x54fba5<_0x456247[_0x5b206e(0x2e8)]&&!_0x5b206e(0xeb)[_0x5b206e(0x243)](_0x456247[_0x54fba5])&&_0x456247[_0x54fba5]!=='\x20'&&_0x456247[_0x54fba5]!=='\x09'&&_0x456247[_0x54fba5]!=='\x0a'&&_0x456247[_0x54fba5]!=='\x0d'){_0x56ca5a+=_0x456247[_0x54fba5++];}let _0x3f55b9=_0x54fba5;while(_0x3f55b9<_0x456247[_0x5b206e(0x2e8)]&&(_0x456247[_0x3f55b9]==='\x20'||_0x456247[_0x3f55b9]==='\x09'))_0x3f55b9++;if(_0x456247[_0x3f55b9]===':')_0x3b79d0+='\x22'+_0x56ca5a+'\x22';else _0x56ca5a===_0x5b206e(0x509)||_0x56ca5a===_0x5b206e(0x460)||_0x56ca5a==='null'||/^-?\d+(\.\d+)?([eE][+-]?\d+)?$/['test'](_0x56ca5a)?_0x3b79d0+=_0x56ca5a:_0x3b79d0+='\x22'+_0x56ca5a+'\x22';}return _0x3b79d0[_0x5b206e(0x61f)](/,(\s*[}\]])/g,'$1');}function _0x34252e(_0x84435d){const _0x4dec02=_0x105fc9,_0x42b6be=[];let _0x2d8f79=0x0;while(_0x2d8f79<_0x84435d[_0x4dec02(0x2e8)]){while(_0x2d8f79<_0x84435d[_0x4dec02(0x2e8)]&&(_0x84435d[_0x2d8f79]==='\x20'||_0x84435d[_0x2d8f79]==='\x09'))_0x2d8f79++;if(_0x2d8f79>=_0x84435d[_0x4dec02(0x2e8)])break;const _0xb7da71=_0x84435d[_0x2d8f79];if(_0xb7da71==='{'||_0xb7da71==='['){const _0x1f7ec5=_0xb7da71==='{'?'}':']',_0x3b3f24=_0x2d8f79++;let _0x18de42=0x1,_0x5b3ce6=![],_0x56a85e='';while(_0x2d8f79<_0x84435d[_0x4dec02(0x2e8)]&&_0x18de42>0x0){const _0x329407=_0x84435d[_0x2d8f79];if(_0x5b3ce6){if(_0x329407==='\x5c')_0x2d8f79++;else{if(_0x329407===_0x56a85e)_0x5b3ce6=![];}}else{if(_0x329407==='\x22'||_0x329407==='\x27')_0x5b3ce6=!![],_0x56a85e=_0x329407;else{if(_0x329407===_0xb7da71)_0x18de42++;else{if(_0x329407===_0x1f7ec5)_0x18de42--;}}}_0x2d8f79++;}_0x42b6be[_0x4dec02(0x1c2)](_0x84435d[_0x4dec02(0x762)](_0x3b3f24,_0x2d8f79));continue;}if(_0xb7da71==='\x22'||_0xb7da71==='\x27'){const _0x5ad9ab=_0xb7da71;_0x2d8f79++;let _0x180c48='';while(_0x2d8f79<_0x84435d[_0x4dec02(0x2e8)]&&_0x84435d[_0x2d8f79]!==_0x5ad9ab){if(_0x84435d[_0x2d8f79]==='\x5c'&&_0x2d8f79+0x1<_0x84435d[_0x4dec02(0x2e8)])_0x2d8f79++,_0x180c48+=_0x84435d[_0x2d8f79++];else _0x180c48+=_0x84435d[_0x2d8f79++];}if(_0x2d8f79<_0x84435d[_0x4dec02(0x2e8)])_0x2d8f79++;_0x42b6be[_0x4dec02(0x1c2)](_0x180c48);continue;}let _0x412e74='';while(_0x2d8f79<_0x84435d[_0x4dec02(0x2e8)]&&_0x84435d[_0x2d8f79]!=='\x20'&&_0x84435d[_0x2d8f79]!=='\x09'&&_0x84435d[_0x2d8f79]!=='{'&&_0x84435d[_0x2d8f79]!=='['){_0x412e74+=_0x84435d[_0x2d8f79++];}if(_0x412e74)_0x42b6be[_0x4dec02(0x1c2)](_0x412e74);}return _0x42b6be;}function _0x19b657(_0x970858,_0x3b3b66){const _0x4fbc1c=_0x105fc9,_0x273bad=[..._0x970858['_envs']['keys']()][_0x4fbc1c(0x20f)](_0x126d5f=>!_0x126d5f[_0x4fbc1c(0x557)]('~'));console[_0x4fbc1c(0x219)](['',_0x589bf5(_0x586886[_0x4fbc1c(0x162)]+_0x586886[_0x4fbc1c(0x763)],'\x20\x20╔═══════════════════════════╗'),_0x589bf5(_0x586886[_0x4fbc1c(0x162)]+_0x586886[_0x4fbc1c(0x763)],_0x4fbc1c(0x51c))+_0x589bf5(_0x586886[_0x4fbc1c(0x162)],_0x4fbc1c(0x4c9))+_0x589bf5(_0x586886[_0x4fbc1c(0x162)]+_0x586886[_0x4fbc1c(0x763)],'║'),_0x589bf5(_0x586886[_0x4fbc1c(0x162)]+_0x586886['cyan'],_0x4fbc1c(0x5d3)),'','\x20\x20'+_0x589bf5(_0x586886[_0x4fbc1c(0x433)],'✓')+'\x20'+_0x589bf5(_0x586886[_0x4fbc1c(0x162)],_0x4fbc1c(0x463))+'\x20\x20http://localhost:'+_0x3b3b66[_0x4fbc1c(0x64d)],..._0x3b3b66[_0x4fbc1c(0x5e1)]>0x1?['\x20\x20'+_0x589bf5(_0x586886['green'],'✓')+'\x20'+_0x589bf5(_0x586886['bold'],'cluster')+'\x20'+_0x3b3b66[_0x4fbc1c(0x5e1)]+_0x4fbc1c(0x10d)+_0x589bf5(_0x586886[_0x4fbc1c(0x699)],_0x4fbc1c(0x384))]:[],'\x20\x20'+_0x589bf5(_0x586886[_0x4fbc1c(0x433)],'✓')+'\x20'+_0x589bf5(_0x586886[_0x4fbc1c(0x162)],_0x4fbc1c(0x729))+'\x20\x20\x20\x20\x20http://localhost:'+_0x3b3b66[_0x4fbc1c(0x64d)]+'/api','\x20\x20'+_0x589bf5(_0x586886[_0x4fbc1c(0x433)],'✓')+'\x20'+_0x589bf5(_0x586886[_0x4fbc1c(0x162)],_0x4fbc1c(0x2cc))+_0x4fbc1c(0x66e)+_0x3b3b66[_0x4fbc1c(0x6bb)],'\x20\x20'+_0x589bf5(_0x586886[_0x4fbc1c(0x433)],'✓')+'\x20'+_0x589bf5(_0x586886[_0x4fbc1c(0x162)],'id')+_0x4fbc1c(0x4cb)+_0x589bf5(_0x586886[_0x4fbc1c(0x699)],_0x970858['id']),'\x20\x20'+_0x589bf5(_0x586886[_0x4fbc1c(0x433)],'✓')+'\x20'+_0x589bf5(_0x586886[_0x4fbc1c(0x162)],_0x4fbc1c(0xb1))+_0x4fbc1c(0x66e)+_0x273bad['map'](_0x3bce76=>_0x589bf5(_0x586886[_0x4fbc1c(0x763)],_0x3bce76))[_0x4fbc1c(0x546)]('\x20\x20'),..._0x3b3b66['noAdmin']?[]:['\x20\x20'+_0x589bf5(_0x586886[_0x4fbc1c(0x433)],'✓')+'\x20'+_0x589bf5(_0x586886[_0x4fbc1c(0x162)],'admin')+_0x4fbc1c(0x22c)+_0x3b3b66[_0x4fbc1c(0x64d)]+_0x4fbc1c(0x62c)],'',_0x589bf5(_0x586886[_0x4fbc1c(0x79d)],_0x4fbc1c(0x78b)+_0x589bf5(_0x586886[_0x4fbc1c(0x162)],_0x4fbc1c(0x693))+_0x4fbc1c(0x2c7)+_0x589bf5(_0x586886[_0x4fbc1c(0x162)],_0x4fbc1c(0x1a1))+_0x4fbc1c(0x34f)+_0x589bf5(_0x586886[_0x4fbc1c(0x162)],_0x4fbc1c(0x2e9))+_0x4fbc1c(0x4ac)),'']['join']('\x0a'));}function _0x1c5d48(_0x3c5d9b){const _0x34692d=_0x105fc9;console[_0x34692d(0x219)]('\x0a'+_0x589bf5(_0x586886[_0x34692d(0x162)],'\x20\x20Path\x20access')+'\x20\x20'+_0x589bf5(_0x586886['dim'],_0x34692d(0x6e2))+_0x34692d(0x223)+_0x589bf5(_0x586886[_0x34692d(0x763)],_0x34692d(0x76f))+_0x34692d(0x5d4)+_0x589bf5(_0x586886['cyan'],_0x34692d(0x76f))+'\x20'+_0x589bf5(_0x586886['yellow'],_0x34692d(0x6ea))+'\x20\x20\x20\x20\x20\x20\x20POST\x20(body\x20implies\x20POST)\x0a\x20\x20'+_0x589bf5(_0x586886['cyan'],'VERB')+'\x20'+_0x589bf5(_0x586886[_0x34692d(0x763)],_0x34692d(0x76f))+'\x20'+_0x589bf5(_0x586886[_0x34692d(0x360)],'[body]')+_0x34692d(0x648)+_0x589bf5(_0x586886[_0x34692d(0x79d)],_0x34692d(0x5ff))+_0x34692d(0x25e)+_0x589bf5(_0x586886['gray'],'info')+_0x34692d(0x678)+_0x589bf5(_0x586886[_0x34692d(0x699)],_0x34692d(0xb1))+_0x34692d(0x5d1)+_0x589bf5(_0x586886['gray'],_0x34692d(0x4e6))+_0x34692d(0x2b7)+_0x3c5d9b[_0x34692d(0x514)]+'/types\x0a\x20\x20\x20\x20'+_0x589bf5(_0x586886['gray'],_0x34692d(0x270))+_0x34692d(0x5f9)+_0x3c5d9b[_0x34692d(0x514)]+_0x34692d(0x4af)+_0x589bf5(_0x586886[_0x34692d(0x699)],'type/users/item/alice')+_0x34692d(0x49e)+_0x3c5d9b[_0x34692d(0x514)]+_0x34692d(0x573)+_0x589bf5(_0x586886[_0x34692d(0x699)],_0x34692d(0x4a3))+_0x34692d(0x69a)+_0x3c5d9b[_0x34692d(0x514)]+_0x34692d(0x4ef)+_0x589bf5(_0x586886['gray'],_0x34692d(0x85))+_0x34692d(0x25e)+_0x589bf5(_0x586886[_0x34692d(0x699)],_0x34692d(0x3b6))+_0x34692d(0x25e)+_0x589bf5(_0x586886[_0x34692d(0x699)],'env/staging/info')+_0x34692d(0x385)+_0x589bf5(_0x586886['bold'],'\x20\x20Flags')+'\x20\x20'+_0x589bf5(_0x586886[_0x34692d(0x79d)],_0x34692d(0x785))+_0x34692d(0x223)+_0x589bf5(_0x586886[_0x34692d(0x763)],_0x34692d(0x43b))+_0x34692d(0x28d)+_0x589bf5(_0x586886[_0x34692d(0x763)],_0x34692d(0x5ef))+_0x34692d(0x92)+_0x589bf5(_0x586886[_0x34692d(0x79d)],_0x34692d(0x5ff))+'\x0a\x20\x20\x20\x20'+_0x589bf5(_0x586886['gray'],_0x34692d(0x46f))+_0x34692d(0x25e)+_0x589bf5(_0x586886['gray'],_0x34692d(0x62d))+_0x34692d(0x25e)+_0x589bf5(_0x586886[_0x34692d(0x699)],_0x34692d(0x71))+'\x0a\x0a'+_0x589bf5(_0x586886[_0x34692d(0x162)],_0x34692d(0x700))+_0x34692d(0x223)+_0x589bf5(_0x586886[_0x34692d(0x763)],'use\x20<env>')+_0x34692d(0x297)+_0x589bf5(_0x586886[_0x34692d(0x763)],_0x34692d(0x514))+_0x34692d(0x1c1)+_0x589bf5(_0x586886[_0x34692d(0x763)],_0x34692d(0x1a1))+'\x20'+_0x589bf5(_0x586886[_0x34692d(0x79d)],_0x34692d(0x74))+_0x34692d(0x24f)+_0x589bf5(_0x586886[_0x34692d(0x763)],_0x34692d(0x340))+'\x20'+_0x589bf5(_0x586886['dim'],'[on|off|level]')+_0x34692d(0x3c4)+_0x589bf5(_0x586886['cyan'],_0x34692d(0x58f))+_0x34692d(0x470)+_0x589bf5(_0x586886[_0x34692d(0x763)],_0x34692d(0x693))+'\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20show\x20this\x20help\x0a\x20\x20'+_0x589bf5(_0x586886[_0x34692d(0x763)],'exit')+'\x20'+_0x589bf5(_0x586886[_0x34692d(0x79d)],_0x34692d(0x1d2))+_0x34692d(0x37d));}let _0x4dcdf4=![];async function _0x388116(_0x108342,_0x316161=0x0,_0x220cce=null){const _0x128edd=_0x105fc9;_0x4dcdf4&&(process[_0x128edd(0x544)]['write'](_0x589bf5(_0x586886[_0x128edd(0x4bf)],_0x128edd(0x50f))),process['exit'](0x82));_0x4dcdf4=!![],process['stdout'][_0x128edd(0xc6)]('\x0a'),process['stderr'][_0x128edd(0xc6)](_0x589bf5(_0x586886['yellow'],_0x128edd(0x3d3)+(_0x220cce?_0x128edd(0x346)+_0x220cce+',\x20':'')+_0x128edd(0x1c4)));const _0x5ea869=setTimeout(()=>{const _0x33bdc9=_0x128edd;process[_0x33bdc9(0x544)]['write'](_0x589bf5(_0x586886['red'],_0x33bdc9(0x21e))),process[_0x33bdc9(0x2e9)](0x1);},0x1388);try{await _0x108342[_0x128edd(0x57b)]();}catch(_0x423466){console['error'](_0x589bf5(_0x586886[_0x128edd(0x4bf)],'\x20\x20'+_0x423466[_0x128edd(0x71d)]));}clearTimeout(_0x5ea869),process[_0x128edd(0x544)][_0x128edd(0xc6)](_0x589bf5(_0x586886[_0x128edd(0x79d)],_0x128edd(0x6ad))),process[_0x128edd(0x2e9)](_0x316161);}function _0x6f5489(_0x47df14){const _0x439747=_0x105fc9,_0x14d404=_0x47df14['env']!=='default'?_0x589bf5(_0x586886[_0x439747(0x360)],'['+_0x47df14[_0x439747(0x514)]+']'):'';return _0x589bf5(_0x586886[_0x439747(0x162)]+_0x586886[_0x439747(0x763)],_0x439747(0x1ea))+_0x14d404+_0x589bf5(_0x586886['gray'],'>\x20');}const _0x2562e2=new Set([_0x105fc9(0x19e),'POST',_0x105fc9(0x502),_0x105fc9(0xe6),_0x105fc9(0x78d)]);async function _0xef5bc7(_0x57e2e4,_0x2a61f8,_0x1a4fa6,_0xb0f16a,_0x2627ab,_0xd469d7){const _0x117a03=_0x105fc9;_0x57e2e4=_0x57e2e4[_0x117a03(0x220)]();if(!_0x57e2e4||_0x57e2e4[_0x117a03(0x557)]('#'))return;const _0x2f1e1a=_0x34252e(_0x57e2e4),{flags:_0xbbf6fc,rest:_0x359ffb}=_0x7146b4(_0x2f1e1a);if(!_0x359ffb['length'])return;const _0xe5233a=_0x359ffb[0x0],_0x20dd07=_0xe5233a[_0x117a03(0x731)]();if(_0x20dd07==='HELP'){if(_0x359ffb[0x1])_0x4e8b99(_0x2a61f8,_0x162f95(_0x359ffb[0x1],_0xbbf6fc[_0x117a03(0x514)]??_0x2627ab[_0x117a03(0x514)]));else _0x1c5d48(_0x2627ab);return;}if(_0x20dd07===_0x117a03(0x432)){const _0xcffacf=_0x359ffb[0x1];if(!_0xcffacf){console[_0x117a03(0x219)](_0x589bf5(_0x586886[_0x117a03(0x4bf)],_0x117a03(0x47d)));return;}try{_0x2a61f8[_0x117a03(0x514)](_0xcffacf),_0x2627ab[_0x117a03(0x514)]=_0xcffacf,_0xd469d7?.[_0x117a03(0x38b)](_0x6f5489(_0x2627ab)),console[_0x117a03(0x219)](_0x117a03(0xce)+_0x589bf5(_0x586886[_0x117a03(0x433)],'✓')+_0x117a03(0x3d2)+_0x589bf5(_0x586886[_0x117a03(0x162)]+_0x586886[_0x117a03(0x763)],_0xcffacf)+'\x0a');}catch{console['log'](_0x117a03(0xce)+_0x589bf5(_0x586886['red'],'✗')+_0x117a03(0x444)+_0x589bf5(_0x586886[_0x117a03(0x162)],_0xcffacf)+'\x20not\x20found'+_0x589bf5(_0x586886[_0x117a03(0x79d)],'\x20—\x20type\x20env\x20to\x20list\x20available\x0a'));}return;}if(_0x20dd07===_0x117a03(0x2d3)){const _0x378740=[..._0x2a61f8[_0x117a03(0x319)][_0x117a03(0x449)]()]['filter'](_0x4d4a65=>!_0x4d4a65[_0x117a03(0x557)]('~'));console[_0x117a03(0x219)]('');for(const _0x1fc0c3 of _0x378740){const _0x10fc1d=_0x1fc0c3===_0x2627ab[_0x117a03(0x514)];console[_0x117a03(0x219)]('\x20\x20'+(_0x10fc1d?_0x589bf5(_0x586886[_0x117a03(0x433)],'●'):_0x589bf5(_0x586886[_0x117a03(0x79d)],'○'))+'\x20\x20'+(_0x10fc1d?_0x589bf5(_0x586886['bold']+_0x586886[_0x117a03(0x763)],_0x1fc0c3):_0x589bf5(_0x586886[_0x117a03(0x79d)],_0x1fc0c3)));}console[_0x117a03(0x219)](_0x117a03(0xce)+_0x589bf5(_0x586886['dim'],'active:')+'\x20'+_0x589bf5(_0x586886['cyan'],_0x2627ab[_0x117a03(0x514)])),console[_0x117a03(0x219)]('');return;}if(_0x20dd07==='ENVS'){const _0x49aff7=[..._0x2a61f8['_envs'][_0x117a03(0x260)]()][_0x117a03(0x20f)](_0x98703f=>!_0x98703f[_0x117a03(0x58e)]['startsWith']('~'));console[_0x117a03(0x219)]('');const _0x4cf0ea=Math[_0x117a03(0x608)](..._0x49aff7[_0x117a03(0x362)](_0x100c52=>_0x100c52[_0x117a03(0x58e)][_0x117a03(0x2e8)]));for(const _0x217247 of _0x49aff7){const _0x2aba2a=_0x217247[_0x117a03(0x58e)]===_0x2627ab[_0x117a03(0x514)],_0x4dab58=_0x2aba2a?_0x589bf5(_0x586886[_0x117a03(0x433)],'●'):_0x589bf5(_0x586886[_0x117a03(0x79d)],'○'),_0xd1d02b=_0x2aba2a?_0x589bf5(_0x586886['bold']+_0x586886[_0x117a03(0x763)],_0x217247[_0x117a03(0x58e)][_0x117a03(0x6e3)](_0x4cf0ea)):_0x589bf5(_0x586886[_0x117a03(0x79d)],_0x217247[_0x117a03(0x58e)][_0x117a03(0x6e3)](_0x4cf0ea)),_0x445a4a=[..._0x217247[_0x117a03(0x696)][_0x117a03(0x449)]()]['filter'](_0x454e75=>!_0x454e75['startsWith']('~')),_0x4d06ec=_0x445a4a['length']?_0x589bf5(_0x586886[_0x117a03(0x79d)],_0x445a4a[_0x117a03(0x762)](0x0,0x5)[_0x117a03(0x546)](',\x20')+(_0x445a4a['length']>0x5?_0x117a03(0x4cd)+(_0x445a4a[_0x117a03(0x2e8)]-0x5)+'\x20more':'')):_0x589bf5(_0x586886[_0x117a03(0x79d)],_0x117a03(0x75c));console[_0x117a03(0x219)]('\x20\x20'+_0x4dab58+'\x20\x20'+_0xd1d02b+'\x20\x20'+_0x4d06ec);}console['log']('');return;}if(_0x20dd07===_0x117a03(0x518)){const _0x32a775=_0xbbf6fc[_0x117a03(0x514)]??_0x359ffb[0x1]??_0x2627ab[_0x117a03(0x514)];try{const _0x32d936=_0x2a61f8[_0x117a03(0x514)](_0x32a775),_0x53d447=[..._0x32d936[_0x117a03(0x696)][_0x117a03(0x449)]()][_0x117a03(0x20f)](_0x331a0e=>!_0x331a0e[_0x117a03(0x557)]('~'))[_0x117a03(0x108)]();console[_0x117a03(0x219)](_0x117a03(0xce)+_0x589bf5(_0x586886['dim'],_0x53d447[_0x117a03(0x2e8)]+_0x117a03(0x5eb)+(_0x53d447[_0x117a03(0x2e8)]!==0x1?'s':'')+'\x20in\x20'+_0x32a775));for(const _0x59abfe of _0x53d447){const _0x178f88=_0x32d936[_0x117a03(0x696)][_0x117a03(0x741)](_0x59abfe),_0x1550d7=_0x178f88?.['data']?.['getCount']?.()??0x0,_0x2b1a0d=_0x589bf5(_0x586886[_0x117a03(0x162)]+_0x586886['cyan'],_0x59abfe[_0x117a03(0x6e3)](0x1c));console[_0x117a03(0x219)](_0x117a03(0x66e)+_0x2b1a0d+'\x20\x20'+_0x589bf5(_0x586886[_0x117a03(0x54c)],String(_0x1550d7)[_0x117a03(0x1fa)](0x6))+'\x20'+_0x589bf5(_0x586886[_0x117a03(0x79d)],'records'));}console[_0x117a03(0x219)]('');}catch(_0x5cfea2){console[_0x117a03(0x1da)](_0x589bf5(_0x586886[_0x117a03(0x4bf)],'\x0a\x20\x20'+_0x5cfea2[_0x117a03(0x71d)]+'\x0a'));}return;}if(_0x20dd07===_0x117a03(0x1b5)){_0x2927bf(_0x2a61f8,_0x359ffb[_0x117a03(0x762)](0x1)[_0x117a03(0x546)]('\x20'));return;}if(_0x20dd07==='LOGS'){const _0x24c4e4=(_0x359ffb[0x1]??'')['toLowerCase']();if(!_0x24c4e4||_0x24c4e4==='on')_0xb0f16a[_0x117a03(0x283)]=!![],_0xb0f16a['level']=_0x117a03(0x1b9),console['log'](_0x117a03(0xce)+_0x589bf5(_0x586886[_0x117a03(0x433)],'✓')+_0x117a03(0x359)+_0x589bf5(_0x586886['dim'],_0x117a03(0x643))+'\x0a');else{if(_0x24c4e4==='off')_0xb0f16a[_0x117a03(0x283)]=![],console[_0x117a03(0x219)](_0x117a03(0xce)+_0x589bf5(_0x586886['yellow'],'○')+_0x117a03(0x72));else _0x991bf9[_0x24c4e4]!==undefined?(_0xb0f16a[_0x117a03(0x283)]=!![],_0xb0f16a[_0x117a03(0xc0)]=_0x24c4e4,console[_0x117a03(0x219)](_0x117a03(0xce)+_0x589bf5(_0x586886[_0x117a03(0x433)],'✓')+_0x117a03(0x21a)+_0x589bf5(_0x586886['bold'],_0x24c4e4)+'\x0a')):console['error'](_0x589bf5(_0x586886['red'],_0x117a03(0x4be)));}return;}if(_0x20dd07===_0x117a03(0xe3)||_0x20dd07==='QUIT'){await _0x388116(_0x2a61f8,0x0);return;}if(_0x20dd07===_0x117a03(0x107)){const _0x39f205=_0x117a03(0x3f1)+_0x1a4fa6[_0x117a03(0x64d)]+_0x117a03(0x62c),_0x3be7c1=process[_0x117a03(0x6af)]===_0x117a03(0x45d)?'start\x20'+_0x39f205:process[_0x117a03(0x6af)]==='darwin'?_0x117a03(0x38f)+_0x39f205:'xdg-open\x20'+_0x39f205;require$$4[_0x117a03(0x74c)](_0x3be7c1),console['log'](_0x117a03(0xce)+_0x589bf5(_0x586886['green'],'✓')+_0x117a03(0x7c)+_0x589bf5(_0x586886[_0x117a03(0x763)],_0x39f205)+'\x0a');return;}let _0x499a5c,_0x4035e4,_0x27db4c;if(_0x2562e2['has'](_0x20dd07)){_0x499a5c=_0x20dd07,_0x4035e4=_0x359ffb[0x1],_0x27db4c=_0x359ffb[_0x117a03(0x762)](0x2);if(!_0x4035e4){console[_0x117a03(0x1da)](_0x589bf5(_0x586886[_0x117a03(0x4bf)],_0x117a03(0x46a)+_0xe5233a+_0x117a03(0x8b)));return;}}else _0x499a5c=null,_0x4035e4=_0x359ffb[0x0],_0x27db4c=_0x359ffb[_0x117a03(0x762)](0x1);const _0x3877a9=_0xbbf6fc[_0x117a03(0x514)]??_0x2627ab[_0x117a03(0x514)],_0x156fe9=_0x162f95(_0x4035e4,_0x3877a9);if(_0xbbf6fc[_0x117a03(0x693)]){_0x4e8b99(_0x2a61f8,_0x156fe9);return;}let _0x1b1087=null;if(_0x27db4c[_0x117a03(0x2e8)]){const _0x4203ab=_0x27db4c[_0x117a03(0x546)]('\x20');try{_0x1b1087=_0x2e5d15(_0x4203ab);}catch(_0x59ad81){console['error'](_0x589bf5(_0x586886['red'],_0x117a03(0x364)+_0x4203ab+_0x117a03(0xce)+_0x589bf5(_0x586886[_0x117a03(0x79d)],_0x59ad81[_0x117a03(0x71d)])+'\x0a'));return;}}if(!_0x499a5c)_0x499a5c=_0x1b1087!==null?_0x117a03(0x6df):_0x117a03(0x19e);try{const _0x320ade=await _0x227b11(_0x2a61f8,_0x499a5c,_0x156fe9,_0x1b1087);_0x395a05(_0x320ade[_0x117a03(0x469)],_0x320ade[_0x117a03(0x772)]);}catch(_0x5a8321){console[_0x117a03(0x1da)](_0x117a03(0xce)+_0x589bf5(_0x586886[_0x117a03(0x4bf)],'✗')+'\x20'+_0x5a8321[_0x117a03(0x71d)]+'\x0a');}}class _0x1d4e4d{constructor(){const _0x59623a=_0x105fc9;this['children']=new Map(),this[_0x59623a(0x1ba)]=null,this[_0x59623a(0x406)]=![];}}function _0x2ebdfd(_0x1178b3){const _0x441ee5=_0x105fc9,_0x4fc010=new _0x1d4e4d();for(const _0x3dadc5 of _0x1178b3){if(_0x3dadc5['meta']?.[_0x441ee5(0x15a)])continue;const _0x4cebd8=_0x3dadc5['path'][_0x441ee5(0x61f)](/^\/api/,'')[_0x441ee5(0x61f)](/^\[\/env\/:env=[^\]]*\]/,'')[_0x441ee5(0x61f)](/^\//,'');if(!_0x4cebd8)continue;let _0x4582e6=_0x4fc010;for(const _0x5407c8 of _0x4cebd8[_0x441ee5(0x527)]('/')[_0x441ee5(0x20f)](Boolean)){if(_0x5407c8[_0x441ee5(0x557)](':')){const _0x2c0aeb=_0x5407c8['slice'](0x1);if(!_0x4582e6['dynamic'])_0x4582e6[_0x441ee5(0x1ba)]={'param':_0x2c0aeb,'node':new _0x1d4e4d()};_0x4582e6=_0x4582e6[_0x441ee5(0x1ba)][_0x441ee5(0x3fc)];}else{if(!_0x4582e6['children'][_0x441ee5(0x783)](_0x5407c8))_0x4582e6[_0x441ee5(0x450)][_0x441ee5(0x543)](_0x5407c8,new _0x1d4e4d());_0x4582e6=_0x4582e6[_0x441ee5(0x450)][_0x441ee5(0x741)](_0x5407c8);}}_0x4582e6[_0x441ee5(0x406)]=!![];}return _0x4fc010;}const _0x1ebbc5=new Map();function _0x3d19ce(_0x50da79,_0x93b83c,_0xdb52e4){const _0x2dda6d=_0x105fc9,_0x4b184c=_0x1ebbc5[_0x2dda6d(0x741)](_0x50da79);if(_0x4b184c&&_0x4b184c['exp']>Date[_0x2dda6d(0x6f1)]())return _0x4b184c[_0x2dda6d(0x4d8)];const _0x550b70=_0xdb52e4();return _0x1ebbc5[_0x2dda6d(0x543)](_0x50da79,{'val':_0x550b70,'exp':Date[_0x2dda6d(0x6f1)]()+_0x93b83c}),_0x550b70;}function _0x47a475(_0x22e48d,_0x74afed,_0x2ffaf7,_0x5c2934){const _0x5662da=_0x105fc9,_0x5167a9=_0x74afed[_0x5662da(0x514)]??_0x5c2934[_0x5662da(0x514)];switch(_0x22e48d){case _0x5662da(0x514):return[..._0x2ffaf7[_0x5662da(0x319)][_0x5662da(0x449)]()][_0x5662da(0x20f)](_0x1aac3c=>!_0x1aac3c[_0x5662da(0x557)]('~'));case'type':return _0x3d19ce(_0x5662da(0x2ad)+_0x5167a9,0x7d0,()=>{const _0x12982c=_0x5662da;try{return[..._0x2ffaf7[_0x12982c(0x514)](_0x5167a9)[_0x12982c(0x696)][_0x12982c(0x449)]()][_0x12982c(0x20f)](_0x38f4f2=>!_0x38f4f2[_0x12982c(0x557)]('~'));}catch{return[];}});case _0x5662da(0x1cd):if(!_0x74afed[_0x5662da(0x5be)])return[];return _0x3d19ce(_0x5662da(0x75e)+_0x5167a9+':'+_0x74afed[_0x5662da(0x5be)],0x5dc,()=>{const _0x595694=_0x5662da;try{const _0x5b8f7c=_0x2ffaf7[_0x595694(0x514)](_0x5167a9)[_0x595694(0x696)][_0x595694(0x741)](_0x74afed[_0x595694(0x5be)]);if(!_0x5b8f7c?.['data'])return[];const _0x1e498a=[];for(const {key:_0xe3a10e}of _0x5b8f7c[_0x595694(0x516)][_0x595694(0x4f6)]({'limit':0x32})){_0x1e498a[_0x595694(0x1c2)](String(_0xe3a10e));if(_0x1e498a[_0x595694(0x2e8)]>=0x32)break;}return _0x1e498a;}catch{return[];}});case _0x5662da(0x249):if(!_0x74afed['type'])return[];return _0x3d19ce('idx:'+_0x5167a9+':'+_0x74afed[_0x5662da(0x5be)],0x7d0,()=>{const _0x55abba=_0x5662da;try{const _0x53aac2=_0x2ffaf7[_0x55abba(0x514)](_0x5167a9)[_0x55abba(0x696)][_0x55abba(0x741)](_0x74afed[_0x55abba(0x5be)]);return _0x53aac2?[..._0x53aac2[_0x55abba(0x1d5)]?.[_0x55abba(0x449)]()??[]]:[];}catch{return[];}});case _0x5662da(0x18a):if(!_0x74afed['type'])return[];return _0x3d19ce('fts:'+_0x5167a9+':'+_0x74afed[_0x5662da(0x5be)],0x7d0,()=>{const _0x1c82f5=_0x5662da;try{return _0x2ffaf7['fts']?.[_0x1c82f5(0x36f)]?.(_0x74afed['type'],_0x2ffaf7['env'](_0x5167a9))?.[_0x1c82f5(0x362)](_0x355138=>_0x355138[_0x1c82f5(0x58e)])??[];}catch{return[];}});default:return[];}}function _0x56dff5(_0x2638b8,_0x42c038,_0x2e6b05,_0xaace94){const _0x5b51d1=_0x105fc9,_0x296af8=_0x2638b8['endsWith']('/'),_0x45f747=_0x2638b8[_0x5b51d1(0x527)]('/'),_0x17d87b=_0x296af8?_0x45f747['slice'](0x0,-0x1):_0x45f747['slice'](0x0,-0x1),_0x53bd13=_0x296af8?'':_0x45f747[_0x45f747[_0x5b51d1(0x2e8)]-0x1];let _0x362a93=_0x42c038;const _0x58ce3f={};for(const _0x57ce96 of _0x17d87b){if(!_0x57ce96)continue;if(_0x362a93[_0x5b51d1(0x450)][_0x5b51d1(0x783)](_0x57ce96))_0x362a93=_0x362a93['children'][_0x5b51d1(0x741)](_0x57ce96);else{if(_0x362a93[_0x5b51d1(0x1ba)])_0x58ce3f[_0x362a93['dynamic']['param']]=_0x57ce96,_0x362a93=_0x362a93[_0x5b51d1(0x1ba)][_0x5b51d1(0x3fc)];else return[];}}const _0x35b706=_0x17d87b['filter'](Boolean),_0x41ce2a=_0x35b706[_0x5b51d1(0x2e8)]?_0x35b706[_0x5b51d1(0x546)]('/')+'/':'',_0x33f8be=[];for(const [_0x449a3c]of _0x362a93['children']){if(_0x449a3c['startsWith'](_0x53bd13))_0x33f8be['push'](_0x41ce2a+_0x449a3c);}if(_0x362a93[_0x5b51d1(0x1ba)])for(const _0x34ac4e of _0x47a475(_0x362a93[_0x5b51d1(0x1ba)][_0x5b51d1(0x756)],_0x58ce3f,_0x2e6b05,_0xaace94)){if(String(_0x34ac4e)[_0x5b51d1(0x557)](_0x53bd13))_0x33f8be[_0x5b51d1(0x1c2)](_0x41ce2a+_0x34ac4e);}return _0x33f8be[_0x5b51d1(0x762)](0x0,0x64);}const _0x5a0103=[_0x105fc9(0x693),_0x105fc9(0xa8),_0x105fc9(0x514),_0x105fc9(0xb1),'types',_0x105fc9(0x1a1),_0x105fc9(0x340),'open',_0x105fc9(0x2e9),_0x105fc9(0x343)];function _0x4073fa(_0x5b9dff,_0x1b054c,_0x152fa3){return function _0x263ddb(_0x4ad186){const _0x239450=_0x4ed4;try{const _0x18441b=_0x4ad186[_0x239450(0x486)](/\s[{[]/),_0x3c3bd9=_0x18441b>=0x0?_0x4ad186[_0x239450(0x762)](0x0,_0x18441b):_0x4ad186,_0x559119=_0x3c3bd9['trimStart']();if(!_0x559119){const _0x52bb2c=[..._0x5a0103,...[..._0x5b9dff[_0x239450(0x450)]['keys']()]][_0x239450(0x762)](0x0,0x64);return[_0x52bb2c,''];}const _0x3bb214=_0x559119[_0x239450(0x527)](/\s+/),_0x3fb3ab=_0x3bb214[0x0],_0x2c15a8=_0x3fb3ab['toUpperCase']();if(_0x3bb214[_0x239450(0x2e8)]===0x1){const _0x4e41e0=_0x3fb3ab[_0x239450(0x36c)](),_0x4e74c7=_0x5a0103[_0x239450(0x20f)](_0x53b41f=>_0x53b41f[_0x239450(0x557)](_0x4e41e0)),_0x4716c9=_0x56dff5(_0x3fb3ab,_0x5b9dff,_0x1b054c,_0x152fa3),_0x51f910=[...new Set([..._0x4e74c7,..._0x4716c9])][_0x239450(0x762)](0x0,0x64);return[_0x51f910,_0x3fb3ab];}if(_0x2562e2[_0x239450(0x783)](_0x2c15a8)&&_0x3bb214[_0x239450(0x2e8)]===0x2){const _0x37f1f2=_0x3bb214[0x1],_0x1ad987=_0x56dff5(_0x37f1f2,_0x5b9dff,_0x1b054c,_0x152fa3);return[_0x1ad987['map'](_0x476589=>_0x3fb3ab+'\x20'+_0x476589),_0x3fb3ab+'\x20'+_0x37f1f2];}if(!_0x2562e2[_0x239450(0x783)](_0x2c15a8)&&_0x3bb214['length']>0x1){const _0x5c44fa=_0x56dff5(_0x3fb3ab,_0x5b9dff,_0x1b054c,_0x152fa3),_0x5e536f='\x20'+_0x3bb214[_0x239450(0x762)](0x1)[_0x239450(0x546)]('\x20');return[_0x5c44fa[_0x239450(0x362)](_0x10eca3=>_0x10eca3+_0x5e536f),_0x3fb3ab+_0x5e536f];}return[[],_0x4ad186];}catch{return[[],_0x4ad186];}};}async function _0x5f8a56(_0x4a1d0f,_0x4a6a85){const _0x441f87=_0x105fc9,_0xf687bb={'enabled':!![],'level':_0x4a6a85[_0x441f87(0x628)]??_0x441f87(0x1b9)},_0x875b69={'env':_0x441f87(0x666)},_0x307c01={'current':null},_0x3d2d38=_0x2ebdfd(_0x4a1d0f[_0x441f87(0x1be)][_0x441f87(0x3c7)]()),_0x582d4d=_0x4073fa(_0x3d2d38,_0x4a1d0f,_0x875b69);_0x4a1d0f[_0x441f87(0x219)][_0x441f87(0x6b2)](_0x363b3a=>{const _0x51a50b=_0x441f87;if(!_0xf687bb[_0x51a50b(0x283)])return;_0xadd747(_0x363b3a,_0xf687bb[_0x51a50b(0xc0)]),_0x307c01[_0x51a50b(0x3ca)]?.['prompt'](!![]);}),_0x19b657(_0x4a1d0f,_0x4a6a85);const _0x2ce0dd=_0x555bea['createInterface']({'input':process[_0x441f87(0x18f)],'output':process['stdout'],'terminal':!![],'completer':_0x582d4d,'prompt':_0x6f5489(_0x875b69),'historySize':_0xdac776});try{const _0x25d9b5=_0x55bb38[_0x441f87(0x20c)](_0x41194d,'utf8')[_0x441f87(0x527)]('\x0a')['filter'](Boolean);_0x2ce0dd[_0x441f87(0x4bb)]=_0x25d9b5[_0x441f87(0x3a1)]()[_0x441f87(0x762)](0x0,_0xdac776);}catch{}_0x307c01[_0x441f87(0x3ca)]=_0x2ce0dd,_0x2ce0dd['on'](_0x441f87(0x6ee),async _0xf09477=>{const _0x2a1f70=_0x441f87;_0x2ce0dd[_0x2a1f70(0x659)]();try{await _0xef5bc7(_0xf09477,_0x4a1d0f,_0x4a6a85,_0xf687bb,_0x875b69,_0x2ce0dd);}catch(_0x1d0ec8){console[_0x2a1f70(0x1da)](_0x589bf5(_0x586886[_0x2a1f70(0x4bf)],_0x2a1f70(0x744)+_0x1d0ec8[_0x2a1f70(0x71d)]));}finally{_0x2ce0dd[_0x2a1f70(0x4b3)](),_0x2ce0dd[_0x2a1f70(0x275)]();}}),_0x2ce0dd['on'](_0x441f87(0x57b),()=>{const _0x3b4edc=_0x441f87;try{const _0xc34ad3=[..._0x2ce0dd[_0x3b4edc(0x4bb)]][_0x3b4edc(0x3a1)]()[_0x3b4edc(0x20f)](Boolean)['slice'](0x0,_0xdac776);_0x55bb38['writeFileSync'](_0x41194d,_0xc34ad3['join']('\x0a')+'\x0a');}catch{}_0x388116(_0x4a1d0f,0x0);});let _0x3aa9ac=0x0;return process['on']('SIGINT',()=>{const _0x393a1b=_0x441f87;if(_0x4dcdf4)return _0x388116(_0x4a1d0f,0x82,_0x393a1b(0x2ea));if(_0x2ce0dd[_0x393a1b(0x6ee)]==='')return _0x388116(_0x4a1d0f,0x0,_0x393a1b(0x2ea));const _0x2394f2=Date[_0x393a1b(0x6f1)]();if(_0x2394f2-_0x3aa9ac<0x5dc)return _0x388116(_0x4a1d0f,0x0,_0x393a1b(0x59c));_0x3aa9ac=_0x2394f2,process[_0x393a1b(0x27e)][_0x393a1b(0xc6)]('\x0a'),_0x2ce0dd[_0x393a1b(0x109)](0x0),_0x2ce0dd[_0x393a1b(0x275)](),process[_0x393a1b(0x544)][_0x393a1b(0xc6)](_0x589bf5(_0x586886[_0x393a1b(0x79d)],'\x20\x20(press\x20Ctrl+C\x20again\x20to\x20exit)\x0a'));}),process['on'](_0x441f87(0x9b),()=>_0x388116(_0x4a1d0f,0x0,_0x441f87(0x9b))),process['on'](_0x441f87(0x5a0),()=>_0x388116(_0x4a1d0f,0x0,_0x441f87(0x5a0))),_0x2ce0dd[_0x441f87(0x275)](),_0x2ce0dd;}return okdbShell={'start':_0x5f8a56,'colorLog':_0xadd747,'lenientParse':_0x2e5d15,'_splitLine':_0x34252e,'_formatRouteHelpLines':_0x53f515,'_routeSummary':_0x4def03,'_routeTags':_0x4d561d},okdbShell;}var okdbLoopMonitor,hasRequiredOkdbLoopMonitor;function _0x4ed4(_0x2acbb6,_0x3883cd){_0x2acbb6=_0x2acbb6-0x6c;const _0x21966c=_0x2196();let _0x4ed4d3=_0x21966c[_0x2acbb6];return _0x4ed4d3;}function requireOkdbLoopMonitor(){const _0x2d1319=_0x1cb9ed;if(hasRequiredOkdbLoopMonitor)return okdbLoopMonitor;hasRequiredOkdbLoopMonitor=0x1;const {monitorEventLoopDelay:_0x12a07b,performance:_0x361a74}=require$$0$4,_0x557dda=process.env.OKDB_LOOP_LAG==='1'||process.env.OKDB_LOOP_LAG==='true',_0x2a95ac=Number(process.env.OKDB_LOOP_LAG_MS)||0x7d0,_0x56e488=process.env.OKDB_LOOP_LAG_ALL==='1',_0x44b966=Number(process.env.OKDB_LOOP_LAG_MIN_MS)||0x64;class _0x21f70a{constructor(){const _0x3de0f3=_0x4ed4;this[_0x3de0f3(0x283)]=_0x557dda,this[_0x3de0f3(0x7a3)]=new Map(),this['_h']=null,this[_0x3de0f3(0x295)]=null,this['_started']=![],this[_0x3de0f3(0x267)]=(_0x2b00c0,_0x16c0c1)=>process['stderr'][_0x3de0f3(0xc6)](_0x2b00c0+(_0x16c0c1?'\x20'+JSON[_0x3de0f3(0x5bd)](_0x16c0c1):'')+'\x0a');}[_0x2d1319(0x6f1)](){const _0x55c557=_0x2d1319;return _0x361a74[_0x55c557(0x6f1)]();}['setLogger'](_0x4cb4c5){const _0x3c92e8=_0x2d1319;if(typeof _0x4cb4c5===_0x3c92e8(0x18e))this[_0x3c92e8(0x267)]=_0x4cb4c5;}['note'](_0x27b3ae,_0x2f06a1,_0x1dd8a0){const _0x31247f=_0x2d1319;if(!this[_0x31247f(0x283)])return;let _0x3ea45b=this['_buckets'][_0x31247f(0x741)](_0x27b3ae);!_0x3ea45b&&(_0x3ea45b={'ms':0x0,'count':0x0,'maxMs':0x0,'maxExtra':''},this[_0x31247f(0x7a3)]['set'](_0x27b3ae,_0x3ea45b)),_0x3ea45b['ms']+=_0x2f06a1,_0x3ea45b[_0x31247f(0x6b4)]+=0x1,_0x2f06a1>_0x3ea45b[_0x31247f(0x56c)]&&(_0x3ea45b[_0x31247f(0x56c)]=_0x2f06a1,_0x3ea45b[_0x31247f(0x138)]=_0x1dd8a0||'');}['start'](_0x20ad43){const _0x1d6d0d=_0x2d1319;if(!this[_0x1d6d0d(0x283)]||this['_started'])return;this[_0x1d6d0d(0x778)]=!![];if(_0x20ad43)this[_0x1d6d0d(0x267)]=_0x20ad43;this['_h']=_0x12a07b({'resolution':0xa}),this['_h'][_0x1d6d0d(0x190)](),this[_0x1d6d0d(0x295)]=setInterval(()=>this[_0x1d6d0d(0x2dd)](),_0x2a95ac);if(this[_0x1d6d0d(0x295)][_0x1d6d0d(0x575)])this[_0x1d6d0d(0x295)][_0x1d6d0d(0x575)]();}[_0x2d1319(0x56d)](_0x10055e){const _0x5f3e59=_0x2d1319;if(!this['_windowCbs'])this['_windowCbs']=new Set();this[_0x5f3e59(0x300)][_0x5f3e59(0x5f3)](_0x10055e);if(!this[_0x5f3e59(0x778)])this[_0x5f3e59(0x5ed)]();}[_0x2d1319(0x5b2)](_0x4f19c5){const _0x26d84e=_0x2d1319;this['_windowCbs']?.[_0x26d84e(0x210)](_0x4f19c5);}[_0x2d1319(0x5ed)](){const _0x195c3d=_0x2d1319;if(this['_admissionStarted'])return;this['_admissionStarted']=!![];!this['_h']&&(this['_h']=_0x12a07b({'resolution':0xa}),this['_h'][_0x195c3d(0x190)]());const _0x139655=_0x2a95ac;this['_admissionTimer']=setInterval(()=>{const _0xa41d3e=_0x195c3d,_0x206ce5=this['_h'];if(!_0x206ce5)return;const _0x4137b6=_0x206ce5[_0xa41d3e(0x169)](0x63)/0xf4240,_0x17803d=_0x206ce5[_0xa41d3e(0x608)]/0xf4240,_0x1d734c=_0x206ce5[_0xa41d3e(0x81)]/0xf4240;_0x206ce5[_0xa41d3e(0x34e)]();if(this[_0xa41d3e(0x300)])for(const _0x194cf4 of this['_windowCbs']){try{_0x194cf4({'p99Ms':_0x4137b6,'maxMs':_0x17803d,'meanMs':_0x1d734c,'reportMs':_0x139655});}catch{}}},_0x139655);if(this[_0x195c3d(0x2c2)]['unref'])this[_0x195c3d(0x2c2)][_0x195c3d(0x575)]();}[_0x2d1319(0x2dd)](){const _0x43d6d5=_0x2d1319,_0x73afbf=this['_h'],_0x38d14d=_0x73afbf[_0x43d6d5(0x608)]/0xf4240,_0x52904c=_0x73afbf[_0x43d6d5(0x169)](0x63)/0xf4240,_0x207c6e=_0x73afbf[_0x43d6d5(0x81)]/0xf4240;_0x73afbf[_0x43d6d5(0x34e)]();const _0x4fc98e=[...this[_0x43d6d5(0x7a3)][_0x43d6d5(0x377)]()][_0x43d6d5(0x362)](([_0x1a543c,_0x5dbd34])=>({'label':_0x1a543c,..._0x5dbd34}))['sort']((_0x193c7f,_0x853f50)=>_0x853f50['ms']-_0x193c7f['ms'])[_0x43d6d5(0x762)](0x0,0x8);this[_0x43d6d5(0x7a3)]['clear']();const _0x10b863=_0x4fc98e[_0x43d6d5(0x4ea)]((_0x493f90,_0x516095)=>_0x493f90+_0x516095['ms'],0x0),_0x37aee8=_0x4fc98e[_0x43d6d5(0x362)](_0x1837e5=>_0x1837e5['label']+'='+_0x1837e5['ms'][_0x43d6d5(0x12a)](0x0)+'ms/'+_0x1837e5[_0x43d6d5(0x6b4)]+(_0x1837e5[_0x43d6d5(0x56c)]>0x5?'(worst\x20'+_0x1837e5[_0x43d6d5(0x56c)][_0x43d6d5(0x12a)](0x0)+'ms'+(_0x1837e5[_0x43d6d5(0x138)]?'\x20'+_0x1837e5[_0x43d6d5(0x138)]:'')+')':''));(_0x56e488||_0x38d14d>=_0x44b966)&&this[_0x43d6d5(0x267)]('loop-lag\x20'+_0x2a95ac+_0x43d6d5(0x241)+_0x38d14d[_0x43d6d5(0x12a)](0x0)+_0x43d6d5(0x265)+_0x52904c[_0x43d6d5(0x12a)](0x0)+_0x43d6d5(0xc2)+_0x207c6e[_0x43d6d5(0x12a)](0x0)+'ms\x20busy='+_0x10b863['toFixed'](0x0)+'ms'+(_0x37aee8['length']?_0x43d6d5(0x8e)+_0x37aee8[_0x43d6d5(0x546)]('\x20\x20'):''),{'feature':_0x43d6d5(0x491)});if(this[_0x43d6d5(0x300)])for(const _0xec93f9 of this[_0x43d6d5(0x300)]){try{_0xec93f9({'p99Ms':_0x52904c,'maxMs':_0x38d14d,'meanMs':_0x207c6e,'reportMs':_0x2a95ac});}catch{}}}[_0x2d1319(0x391)](){const _0x28f7cc=_0x2d1319;if(this[_0x28f7cc(0x295)])clearInterval(this[_0x28f7cc(0x295)]);if(this['_h'])this['_h'][_0x28f7cc(0x6a8)]();this['_timer']=null,this['_h']=null,this['_started']=![];}}const _0x31418f=new _0x21f70a();if(_0x31418f['enabled'])_0x31418f[_0x2d1319(0xfa)]();return okdbLoopMonitor={'LOOP':_0x31418f},okdbLoopMonitor;}var okdbWriter={'exports':{}},okdbDiag,hasRequiredOkdbDiag;function requireOkdbDiag(){if(hasRequiredOkdbDiag)return okdbDiag;hasRequiredOkdbDiag=0x1;const _0x2443f5=require$$0$1,_0x5c2857=require$$1;let _0x2d5938,_0x19349c,_0x1ac944,_0x239a68,_0x487bf8,_0x4f19b6,_0x27ad7e,_0x2f464a=![];const _0xb28b2b=new Set();let _0x464e9a=null;const _0x318ae3=new Map();function _0x39801c(){const _0x38e334=_0x4ed4;if(_0x2d5938!==undefined)return _0x2d5938;_0x2d5938=process.env.OKDB_DIAG==='1';if(!_0x2d5938)return![];_0x19349c=process.env.OKDB_DIAG_STACK==='1',_0x239a68=Math[_0x38e334(0x608)](0x10,Number(process.env.OKDB_DIAG_RING)||0x100),_0x1ac944=new Array(_0x239a68),_0x487bf8=0x0,_0x4f19b6=0x0,_0x27ad7e=process.env.OKDB_DIAG_DIR||null;if(_0x27ad7e)try{_0x2443f5[_0x38e334(0x3b8)](_0x27ad7e,{'recursive':!![]});}catch{}return!![];}function _0xd26f2b(){return _0x2d5938===undefined?_0x39801c():_0x2d5938;}function _0x189732(_0x1d0801,_0x14e07b){const _0x339775=_0x4ed4;if(_0x2d5938===undefined?!_0x39801c():!_0x2d5938)return;let _0x46c928;if(_0x19349c){const _0x4224a5=new Error()[_0x339775(0x644)]||'';_0x46c928=_0x4224a5[_0x339775(0x527)]('\x0a')[_0x339775(0x762)](0x3)[_0x339775(0x362)](_0x3349b9=>_0x3349b9[_0x339775(0x220)]())['filter'](Boolean)['slice'](0x0,0x8);}_0x1ac944[_0x487bf8]={'seq':_0x4f19b6++,'t':Date['now'](),'env':_0x1d0801,'kind':_0x14e07b||_0x339775(0x537),'stack':_0x46c928},_0x487bf8=(_0x487bf8+0x1)%_0x239a68;}function _0x1022e5(_0x2f6398){const _0x5c9ec2=_0x4ed4,_0x5b9191=[];for(let _0x35d58f=0x0;_0x35d58f<_0x239a68;_0x35d58f++){const _0x48c641=_0x1ac944[(_0x487bf8-0x1-_0x35d58f+_0x239a68*0x2)%_0x239a68];if(!_0x48c641)continue;_0x5b9191[_0x5c9ec2(0x1c2)](_0x48c641);if(_0x5b9191[_0x5c9ec2(0x2e8)]>=_0x2f6398)break;}return _0x5b9191;}function _0x53e922(_0x5549ba){const _0x3234f9=_0x4ed4;try{process[_0x3234f9(0x544)][_0x3234f9(0xc6)](_0x5549ba+'\x0a');}catch{}if(_0x27ad7e)try{_0x2443f5['appendFileSync'](_0x5c2857[_0x3234f9(0x546)](_0x27ad7e,_0x3234f9(0x316)+process[_0x3234f9(0x401)]+_0x3234f9(0x61b)),_0x5549ba+'\x0a');}catch{}}function _0x99b1e4(_0xf3a3f9){const _0x1ed230=_0x4ed4,_0xff341b=_0x1022e5(_0xf3a3f9);if(!_0xff341b['length'])return _0x1ed230(0x237);const _0x85eda6=Date['now']();return _0xff341b['map'](_0x1fc288=>{const _0x1ab84b=_0x1ed230,_0x4975c2=_0x1ab84b(0x171)+_0x1fc288[_0x1ab84b(0x57a)]+'\x20-'+(_0x85eda6-_0x1fc288['t'])+'ms\x20env='+_0x1fc288['env']+'\x20'+_0x1fc288['kind'];return _0x1fc288['stack']&&_0x1fc288[_0x1ab84b(0x644)][_0x1ab84b(0x2e8)]?_0x4975c2+'\x0a\x20\x20\x20\x20\x20\x20'+_0x1fc288['stack'][_0x1ab84b(0x546)](_0x1ab84b(0x3d0)):_0x4975c2;})[_0x1ed230(0x546)]('\x0a');}function _0x5c906f(_0x195b22,_0x6f090d){const _0x2ac236=_0x4ed4,_0x579651=_0x2ac236(0x5bf)+_0x195b22+_0x2ac236(0x74f)+new Date()['toISOString']()+_0x2ac236(0x529)+process[_0x2ac236(0x401)]+_0x2ac236(0x428),_0x4eb232=[_0x579651,_0x2ac236(0xec)+(_0x6f090d&&_0x6f090d['stack']?_0x6f090d['stack'][_0x2ac236(0x527)]('\x0a')[0x0]:_0x6f090d),_0x2ac236(0x4e7)+(_0x19349c?'':_0x2ac236(0x781))+':',_0x99b1e4(0x18),_0x1c7098(),'='[_0x2ac236(0x32c)](_0x579651[_0x2ac236(0x2e8)]-0x1)];_0x53e922(_0x4eb232[_0x2ac236(0x546)]('\x0a'));}function _0x33ad65(_0x13b140){const _0x55cd86=_0x4ed4;if(!_0xd26f2b())return;const _0x162b28=String(_0x13b140&&_0x13b140['message']||_0x13b140||''),_0x8fb4a8=/already closed|environment is already|invalid read txn|reset an invalid/i[_0x55cd86(0x86)](_0x162b28);_0x5c906f(_0x8fb4a8?_0x55cd86(0x28e):_0x55cd86(0x102),_0x13b140);if(process.env.OKDB_DIAG_SURVIVE==='1'&&_0x8fb4a8)return;try{console[_0x55cd86(0x1da)](_0x13b140&&_0x13b140[_0x55cd86(0x644)]?_0x13b140[_0x55cd86(0x644)]:_0x13b140);}catch{}process['exit'](0x1);}function _0x224ef5(_0x2542ee){const _0x60e6b1=_0x4ed4;if(!_0xd26f2b())return;const _0x196fed=String(_0x2542ee&&_0x2542ee[_0x60e6b1(0x71d)]||_0x2542ee||'');/already closed|environment is already|invalid read txn|reset an invalid/i['test'](_0x196fed)&&_0x5c906f('ORPHAN\x20(env-closed\x20write,\x20unhandledRejection)',_0x2542ee);}function _0x1c7098(){const _0x56a4d1=_0x4ed4,_0x5bc521=[_0x56a4d1(0x179)];let _0x5b8a78=![];for(const _0x47cc9a of _0xb28b2b){const _0x4fe6cf=_0x47cc9a&&_0x47cc9a[_0x56a4d1(0x319)];if(!_0x4fe6cf)continue;for(const [_0x2d1857,_0xd232de]of _0x4fe6cf){const _0x4ee5ef=_0xd232de&&_0xd232de[_0x56a4d1(0x46b)]&&_0xd232de[_0x56a4d1(0x46b)][_0x56a4d1(0x342)];if(!_0x4ee5ef)continue;let _0x473dd3,_0x35776c;try{_0x473dd3=Atomics[_0x56a4d1(0x52f)](_0x4ee5ef,0x0),_0x35776c=Atomics[_0x56a4d1(0x52f)](_0x4ee5ef,0x1);}catch{continue;}if(_0x473dd3===0x0)continue;_0x5b8a78=!![];const _0x5ab581=_0x473dd3>0x0?_0x56a4d1(0x67c):_0x56a4d1(0x3cd),_0x234bf8=Date[_0x56a4d1(0x6f1)]()-Math[_0x56a4d1(0x2b2)](_0x473dd3)*0x3e8,_0x37e930=((()=>{const _0x1ef0f2=_0x56a4d1;try{return _0xd232de[_0x1ef0f2(0x43d)]&&_0xd232de[_0x1ef0f2(0x43d)]['status']?_0xd232de[_0x1ef0f2(0x43d)][_0x1ef0f2(0x469)]():null;}catch{return null;}})());_0x5bc521[_0x56a4d1(0x1c2)](_0x56a4d1(0x480)+_0x2d1857+_0x56a4d1(0x5e8)+_0x5ab581+_0x56a4d1(0x56a)+_0x234bf8+_0x56a4d1(0x24c)+_0x35776c+(_0x37e930?_0x56a4d1(0x399)+_0x37e930[_0x56a4d1(0x2c3)]+_0x56a4d1(0x626)+_0x37e930['oldestPendingMs']+_0x56a4d1(0x549)+_0x37e930[_0x56a4d1(0x82)]+'}':''));}}if(!_0x5b8a78)_0x5bc521[_0x56a4d1(0x1c2)](_0x56a4d1(0x5c7));return _0x5bc521['join']('\x0a');}function _0x50895f(){const _0x3b45fd=_0x4ed4;if(!_0xd26f2b())return;const _0x4d2a43=Math[_0x3b45fd(0x608)](0x3e8,Number(process.env.OKDB_DIAG_STALL_MS)||0x1f40),_0x459388=Date[_0x3b45fd(0x6f1)]();for(const _0x1e20e8 of _0xb28b2b){const _0x3dacf8=_0x1e20e8&&_0x1e20e8['_envs'];if(!_0x3dacf8)continue;for(const [_0x410029,_0x1ccb66]of _0x3dacf8){const _0x392471=_0x1ccb66&&_0x1ccb66[_0x3b45fd(0x46b)]&&_0x1ccb66[_0x3b45fd(0x46b)]['view'];if(!_0x392471)continue;let _0x38f5dd;try{_0x38f5dd=Atomics[_0x3b45fd(0x52f)](_0x392471,0x0);}catch{continue;}const _0x3fdf8c=_0x1e20e8[_0x3b45fd(0x2cc)]+'|'+_0x410029;if(_0x38f5dd<=0x0){_0x318ae3[_0x3b45fd(0x210)](_0x3fdf8c);continue;}const _0x506477=_0x459388-_0x38f5dd*0x3e8,_0x12e8ad=_0x318ae3['get'](_0x3fdf8c);if(_0x506477<_0x4d2a43)continue;if(_0x12e8ad&&_0x459388-_0x12e8ad[_0x3b45fd(0x4d6)]<_0x4d2a43)continue;_0x318ae3[_0x3b45fd(0x543)](_0x3fdf8c,{'firstTs':_0x12e8ad?_0x12e8ad[_0x3b45fd(0x595)]:_0x38f5dd,'dumpedAt':_0x459388});const _0x3bdcfc=_0x3b45fd(0x334)+_0x506477+_0x3b45fd(0x73a)+_0x410029+_0x3b45fd(0x74f)+new Date()[_0x3b45fd(0x165)]()+'\x20pid='+process[_0x3b45fd(0x401)]+_0x3b45fd(0x428);_0x53e922([_0x3bdcfc,_0x1c7098(),'='['repeat'](_0x3bdcfc['length']-0x1)][_0x3b45fd(0x546)]('\x0a'));}}}function _0x1aba19(){const _0x4231d7=_0x4ed4;if(!_0xd26f2b()||_0x2f464a)return;_0x2f464a=!![],process['prependListener'](_0x4231d7(0x102),_0x33ad65),process[_0x4231d7(0x562)]('unhandledRejection',_0x224ef5);const _0x23c122=Math[_0x4231d7(0x608)](0xfa,Number(process.env.OKDB_DIAG_WATCH_MS)||0x7d0);_0x464e9a=setInterval(_0x50895f,_0x23c122);if(_0x464e9a[_0x4231d7(0x575)])_0x464e9a[_0x4231d7(0x575)]();}function _0x5f2ad0(_0x5eb27d){const _0x57ed43=_0x4ed4;if(!_0xd26f2b()||!_0x5eb27d)return;_0xb28b2b[_0x57ed43(0x5f3)](_0x5eb27d),_0x1aba19();}function _0xcde04d(_0x1644e5){const _0x14655b=_0x4ed4;_0xb28b2b[_0x14655b(0x210)](_0x1644e5);}function _0x1e29f3(){const _0x44b6a4=_0x4ed4;if(!_0xd26f2b())return{'enabled':![],'hint':_0x44b6a4(0x2c9)};return{'enabled':!![],'stackCapture':!!_0x19349c,'recentWrites':_0x1022e5(0x10),'drain':_0x1c7098()};}return okdbDiag={'isEnabled':_0xd26f2b,'recordWrite':_0x189732,'installDiag':_0x1aba19,'registerOkdb':_0x5f2ad0,'unregisterOkdb':_0xcde04d,'snapshot':_0x1e29f3},okdbDiag;}function _0x2196(){const _0x15b21d=['processKey','writerStatus','signature','\x1b[34m','processor:progress','isBusy','Materialized\x20views:\x20query\x20definitions\x20that\x20are\x20continuously\x20maintained\x20and\x20queryable.','stats','default','created','missing_blob','_isReader','orphan','\x20is\x20not\x20a\x20complete\x20okdb\x20backup\x20(no\x20','\x20\x20✓\x20Revoked\x20token\x20','\x0a[okdb]\x20force-exiting\x20(second\x20interrupt)\x0a','\x20\x20\x20\x20','off','_getType','toLocaleString','ITEM_PENDING','\x20\x20\x20\x20\x20\x20\x20','okdb-lock:\x20env\x20closed','endsWith','_okdb','~processes:cmd','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20→\x20GET\x20/api/info\x0a\x20\x20\x20\x20','closed','INDEX_ALREADY_REGISTERED','examples','SWAP','import','maxBodyBytes','_supervisorKey','wrong_node','x-forwarded-for','doctor','_heldTotal',';\x20Max-Age=','type:drop','[okdb]\x20warning:\x20failed\x20to\x20restore\x20identity/licenses\x20after\x20reset:\x20','(workers\x20can\x27t\x20share\x20the\x20cross-process\x20HLC/clock).\x20Forcing\x20single-process\x20(was\x20','\x20\x20after\x20sync.\x20Duplicate\x20names\x20will\x20surface\x20as\x20ambiguous\x20logins\x20to\x20clean\x20up.','description','okdb.http.listen(port)\x20in\x20each\x20worker.','selfAddress','\x1b[0m','index:registered','ms\x20(pid\x20','LICENSEE','_enforceOperationAccess','licenses','child_process','help','jwksUri','_startHeartbeat','typeSubDbs','dataBytes','_hbTimer','gray','\x20→\x20POST\x20/api/env/','transport','grants','--dry-run','\x22\x20(hash:\x20','isTTY','route','authorizationUrl','\x20\x20Tier:\x20\x20\x20\x20','heldBy','is\x20required','every','equals','NOT_FOUND','disable','destroyed','List\x20jobs,\x20view\x20stats,\x20list\x20buckets.','views','1ofN:','\x20\x20[okdb]\x20closed\x20cleanly\x0a','heapUsed','platform','indexOf','backup\x20destination\x20\x22','attach','OKDB_CODE_TO_HTTP_STATUS','count','safety','\x0a-----END\x20CERTIFICATE-----\x0a','listening','oauth','/api/','createHash','dbPath','_singletonLocks','\x20\x20Build:\x20\x20\x20key\x20fingerprint\x20','\x20has\x20canonical\x20metadata\x20but\x20missing\x20valid\x20inputSchema','randomUUID','isEnabled','node\x20identity','consumeLoginState','_totalRequests','listDesired','\x20\x20\x20\x20name:\x20\x20\x20\x20\x20\x20\x20\x20','body.','exportToStream','\x22\x20—\x20choose\x20a\x20directory\x20outside\x20it','\x20\x20\x20\x20status:\x20\x20\x20\x20','removeLicense','_lockDb','__fts:','connection','shmbuf','sizeAfter','data:\x20','recordWrite','slotKey','licenseType','getSecurityNotices','isWanted','processingStatusView','processor:retry','compareExchange','derived;\x20rebuilt\x20from\x20source\x20docs\x20on\x20first\x20open\x20of\x20the\x20restored\x20store','killable','draining','The\x20following\x20routes\x20require\x20auth\x20but\x20declare\x20no\x20permission:\x0a\x20\x20','registerIndex','\x20\x20\x20\x20id:\x20\x20\x20\x20\x20\x20\x20\x20','POST','rows=','\x20statusEnv=','—\x20/api/\x20is\x20auto-prefixed,\x20env\x20is\x20auto-injected','padEnd','updateSupervisedChildStats','notOkdbShaped','processor:ready','data:read','cpuUsage','files\x20feature\x20not\x20available','<json-body>','--prefix','__OKDB_PUB_FINGERPRINT__','fts:drop','line','\x27:\x20','CHANGEFEED_QUANTUM','now','ver','[okdb]\x20import\x20complete','\x20\x20\x20\x20permissions:\x20','.\x20Move\x20it\x20away\x20first\x20to\x20use\x20the\x20copy.','\x20\x20Usage:','_lockDbOf','Bearer\x20','hasLimit','addRaw','socket','der','_totalReadMs','\x20\x20changes=','isAuthenticated','\x20\x20Shell\x20commands','http-server','\x20cannot\x20be\x20MCP-exposed\x20without\x20an\x20explicit\x20adapter\x20because\x20it\x20uses\x20','activateLicense','Embeddings','Internal\x20error','startHeartbeat','[okdb]\x20exporting\x20env\x20\x22','outputSchema','INVALID_INDEX_KEY','online','flushLmdb','json','call','\x20worker','constructor','--workers','reload','license:invalid','--expose-gc','peer','[okdb-cluster]\x20slot=','(empty)','Worker-side:\x20claim,\x20heartbeat,\x20complete,\x20fail,\x20progress.',';\x20shmbuf\x20native\x20missing\x20→\x20forced\x20single-process','okdbVersion','_heartbeatInFlight','bus:poke','Get\x20and\x20list\x20records,\x20run\x20byIndex\x20queries.','message','kid','cluster:','field','header','\x20\x20\x20\x20addedAt:\x20\x20\x20','jwk','\x20\x20\x20\x20writes:\x20\x20\x20\x20','claimGated','Sync','\x20uses\x20bodyMode:array\x20but\x20does\x20not\x20have\x20exactly\x20one\x20unbound\x20array\x20input\x20field','ITEM_REMOVE','api','[okdb]\x20error:\x20--password\x20requires\x20--name','http://','fieldPath','code','decommission','Data','\x20\x20✓\x20','toUpperCase','\x20(durable\x20desired-state)','noAdmin','internal','setOwnMeta','Lax','effective','expiresAt','destroy','ms\x20on\x20env=','\x20\x20Example:\x20okdb\x20join\x20https://node-a.example.com\x20--token\x20<t>\x20--address\x20http://myhost:8484\x0a','[okdb]\x20shmbuf\x20native\x20binding\x20unavailable\x20—\x20multi-process\x20clustering\x20is\x20unsafe\x20','\x20licenses','EADDRINUSE','[okdb]\x20nothing\x20to\x20reset\x20—\x20','targetType','get','lifecycle',')\x20—\x20they\x20will\x20NOT\x20be\x20preserved','\x20\x20Error:\x20','KiB','holder','isFinite','makeOkdb','shm-gc','License\x20already\x20stored','\x20process(es)\x20had\x20unreadable\x20maps','exec','License\x20signature\x20invalid:\x20','alloc','\x20@\x20','typesDb','\x0a\x20\x20okdb\x20doctor\x0a','OKDBSchemaValidationError','FOREIGN_KEY_DELETE_RESTRICTED','category','loadEnvFile','param','UNAUTHORIZED','namespace','OKDBIndexNotRegisteredError','permissions','_closed','(no\x20types)','noteListenAddr','keys:','captureStackTrace','embeddings','exports','slice','cyan','_flushTimer','beforeWrite','application/json','create','env:removed','setupPrimary','targetKey','OPTIONS','\x22\x20has\x20been\x20retiring\x20for\x20','unshift','fts:registered','<path>','raw','_rotateBucket','body','http.listen:\x20host\x20must\x20be\x20a\x20non-empty\x20string\x20or\x20an\x20array\x20of\x20them',':\x20prefix\x20','system:env_release','unlinked','debug','_started','_pending','\x20\x20!\x20','guard','JWT\x20audience\x20mismatch','properties','\x20is\x20inside\x20the\x20backup\x20','\x0a\x20\x20Joining\x20cluster\x20at\x20','nodeKey','\x20—\x20set\x20OKDB_DIAG_STACK=1\x20to\x20name\x20the\x20call\x20site','label','has','/api','(on\x20any\x20path\x20command)','querySchema','shell','_lastCpuUsage','\x20stays\x20down\x20on\x20boot\x20(durable\x20decommission)','_sockets','\x20\x20Type\x20','HTTP_','DELETE','repairBlobRefs','_onTick','process','isBuffer','⚠\x20OPEN\x20LICENSE\x20ACTIVE\x20—\x20this\x20license\x20is\x20not\x20node-bound\x20and\x20is\x20intended\x20for\x20POC/demo\x20use\x20only.\x20Expires\x20in\x20','fill','_inflight','--verbose','wait','ITEM_UPDATE','\x20\x20\x20\x20api:\x20\x20\x20\x20\x20http://localhost:','createWriteStream','derivePin','\x20\x20All\x20checks\x20passed.\x0a','_bpParkedTotal','dim','JWT\x20is\x20missing\x20kid','setTtl','PUBLIC_KEY_PEM','embedded','TYPE_ALREADY_REGISTERED','_buckets','http.listen({workers/makeOkdb/primaryOkdb})\x20is\x20no\x20longer\x20supported\x20in\x20the\x20','errors','invalid','[okdb]\x20backup\x20complete','hdr','type/users\x20--help','\x20logs\x20off\x0a','\x20\x20Envs:\x20\x20\x20\x20','[filter]','_seen','_copyDir','quarantined:\x20','files/','unlinkSync','1552527qDOthe','tokenUrl','\x20opening\x20','Invalid\x20primary\x20key\x20type:\x20','activation','importBlobs','export:\x20stream\x20closed\x20before\x20drain','mean','parkedNow','\x20tokens:','utf8','PUT\x20type/users/item/x\x20{\x22n\x22:1}','test','[okdb]\x20error:\x20unrecognized\x20input:\x20\x22','_activateProcessesReader','89596Nmcowz','iss','\x20<path>\x20[json-body]','\x20(passive),\x20','Unknown\x20JWKS\x20kid:\x20','\x20│\x20','../okdb','_released','LICENSE_EXPIRED_ACTION','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20show\x20API\x20docs\x20for\x20a\x20path\x0a\x0a\x20\x20','database\x20path\x20writable:\x20','INDEX_PROGRESS','importFromFile','jwks_uri','[okdb]\x20cluster\x20close\x20error:\x20','_readNDJSON','onMapped','undefined','SIGTERM','Unsupported\x20JWT\x20alg:\x20','isPrimary','_startedAt','auth','hostname','\x20\x20⚠\x20\x20','schema:drop','\x20entries\x20in\x20','tmp','tokenSecret','blindCommands','_blobsDir','use','known\x20field','params.','_authOptions','att','scopes','reap','(?:/(.*))?$','precision','envs','license','--inspect','address','exposeHeaders','addSupervisedChild','[okdb]\x20error:\x20',',\x20signal=','_blobStatusDb','\x1b[32m','[okdb]\x20cluster\x20supervisor\x20pid=','_onPoke','match','\x20origin=','closing','level','setEncoding','ms\x20mean=','subject','OKDB-PIN-V1:','_listTypes','write','OKDBError','registerFts','schema','password','signingInput','EXPIRES','bus:type_drop','\x0a\x20\x20','finally','user','Index\x20\x27','Cannot\x20delete\x20','candidatesLegacyNamed','_key','decodeLicenseBlob','epoch','\x20\x20\x20\x20port:\x20\x20\x20\x20','Cluster\x20replication.\x20The\x20\x22peer\x22\x20op\x20is\x20for\x20cluster\x20nodes,\x20not\x20human\x20users.','\x20\x20✓\x20marked\x20for\x20a\x20new\x20identity\x20—\x20the\x20first\x20open\x20gives\x20this\x20copy\x20its\x20own\x20node\x20id','\x20\x20scanned\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','_onPending','committed','\x20\x20\x20\x20admin:\x20http://localhost:','~system','auth=','backup','[okdb]\x20shutdown\x20took\x20too\x20long,\x20force-exiting\x0a','Queue','EXIT','_drainOne','find','PATCH','_listenAddr','FTS_REGISTERED','--blobs','pin','{}[]:,\x27\x22','error:\x20','_servingEngines','SIGKILL','\x20\x20\x20\x20features:\x20\x20','_desired','\x20has\x20ambiguous\x20query/path\x20field:\x20','\x20supervised)','953890CpBXMX','GONE','config','\x20\x20deleted\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','listAll','compact','/.well-known/openid-configuration','start','onRetiring','allowedAlgs','item:remove','ttl:expired','\x20MB)','_groupByProcess','https','uncaughtException','\x20\x20\x20\x20label:\x20\x20\x20\x20\x20\x20\x20','never','runtimeProcessesView','headers','OPEN','sort','clearLine','expires','liveThreadStats','cpSync','\x20HTTP\x20workers\x20','_versionSkewWarned','Hint:\x20','parse','_countFileRefs','createEnvironment','_processStartedAt','ref:violation','_held','\x20writes\x20(','writes','License\x20limit\x20exceeded:\x20','ES256','No\x20license\x20found\x20matching\x20this\x20activation\x20token','\x20file','LICENSED_BUILD','compaction','\x0a\x20\x20Joined.\x20Remote\x20tokens\x20replicated.\x20You\x20can\x20now\x20log\x20in\x20with\x20cluster\x20credentials.\x0a','_bestMatch','TiB','_getOidcDiscovery','\x20\x20Writes:\x20\x20','resetting','106wZwrkl','\x20\x20\x20\x20•\x20a\x20path\x20to\x20a\x20.license\x20file','[okdb-cluster]\x20primary\x20pid=','\x20forked\x20','darwin','x-requested-with','toFixed','unique','\x20\x20\x20\x20•\x20a\x20license\x20id\x20\x20\x20\x20\x20(uuid)','Records',';\x20HttpOnly','search:query','SYSTEM_POKE','rss','cluster:\x20unavailable\x20(shmbuf\x20native\x20missing)\x20—\x20running\x20single-process','noRepl','lost','live\x20process\x20registry;\x20disposable','internalOnly','Forbidden\x20—\x20no\x20permissions\x20available','maxExtra','string','base64','migrate','authMode','tokenTtl','writeUInt32BE','_matchRoute','\x20worker(s)\x20still\x20serving','List\x20environments\x20and\x20read\x20environment\x20info.','~tokens','[okdb]\x20created\x20./okdb-data','--prefix=','\x20\x20\x20\x201.\x20Send\x20the\x20PIN\x20above\x20(','dropSchema','pending','env/:env','_totalWriteMs','cluster','SYSTEM_STOPPED','config\x20file\x20invalid:\x20','url','_heartbeatTimer','ppid','unique:violation','ttlMs','shm-gc:\x20unknown\x20argument\x20','additionalProperties','_dedupeMax','\x20\x20errors\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','_nodeDbCache','_nestedWarned','⚠\x20INTERNAL\x20LICENSE\x20ACTIVE\x20—\x20all\x20features\x20and\x20limits\x20are\x20unlocked.\x20For\x20vendor/internal\x20use\x20only.','Execute\x20functions\x20over\x20HTTP/MCP/shell.','hidden','\x20result','Blob\x20file\x20missing\x20for\x20~files\x20record\x20\x22','queue-worker','sync','dedupeMax','last-event-id','okdb-writer[','bold','issuedAt','skip\x20','toISOString','isFeatureEnabled','exportToFile','text/event-stream;\x20charset=utf-8','percentile','timeMachine','from','jwksTtlMs','revived','_oidcDiscoveryCache','references','standalone','\x20\x20#','dryRun','mcp-session-id','--new-identity','/proc','mixed\x20versions\x20on\x20one\x20store\x20are\x20unsafe\x20across\x20storage\x20migrations;\x20align\x20versions\x20before\x20upgrading\x20further.','[okdb-cluster]\x20CRASH-LOOP:\x20worker\x20slot=','id:\x20','drain\x20state\x20(envs\x20with\x20a\x20non-zero\x20drain):','\x20HTTP\x20workers,\x20each\x20serves\x20+\x20processes)','once','cursorKey','blob\x20status\x20db\x20not\x20available','Operator\x20surface:\x20server\x20info,\x20logs,\x20event\x20streams,\x20processor\x20status,\x20backups.','decommissioned','INDEX_RESET','[okdb]\x20loaded\x20config:\x20','bus:proc','copyFile','\x20\x20skipped=','run','processor:resumed','stopped','/dev/shm','\x20\x20No\x20licenses\x20stored.\x20Use\x20`okdb\x20license\x20<blob>`\x20to\x20add\x20one.','ftsName','\x20\x20not\x20okdb-shaped\x20\x20\x20\x20','_baselines','must\x20not\x20be\x20null','function','stdin','enable','zero_refs','\x20\x20\x20\x20status:\x20\x20\x20\x20pending\x20activation','protected:read','limits','--key','_runMiddlewares','_rowKey','outOfTree','_allEnvsWithFiles','LICENSE_ACTIVATION_INVALID','argv','integer','newIdentity','GET','authenticateToken','end','routes','ID\x20token\x20is\x20not\x20accepted','\x22:\x20','statSync','consecutiveFailures','authenticateRequest','Not\x20Found','none','recheck','_buildOwnRow','(code=','hard-killed','license:removed','_clusterWorkerAttached','createdAt','Feature\x20not\x20available\x20on\x20free\x20tier:\x20','query','Content-Type','43887040QSQTkV','~blobs','ROUTES','regex','.kdbconfig','valid','info','dynamic','_ensureTokensType','\x20\x20score:','primaryOkdb','http','stopHeartbeat','Type\x20\x27','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20show\x20active\x20environment\x20+\x20list\x20all\x20envs\x0a\x20\x20','push','_ensureDesired','shutting\x20down…\x0a','value','Writable','x5c','indexes','next','no-cache,\x20no-transform','started','running','key','processor','\x20\x20✓\x20joined\x20and\x20reconciliation\x20initiated','mode','procmodeack/','/\x20quit\x20/\x20Ctrl+C','getClock',';\x20Expires=','indexToDb','engines','createServer','permission','_wantDb','error','statusCode','allowMethods','admin','\x20binding\x20references\x20missing\x20input\x20field:\x20','Feature\x20not\x20licensed:\x20','--watch','pipe','okdb.pid','claims','_db','getuid','_cookieName','\x20\x20(unlimited)','functions','--eval','okdb','[okdb]\x20close\x20error:\x20','set-cookie','_onProcEvent','\x20\x20matching\x20prefix\x20\x20\x20\x20','decodeLicenseBlob:\x20blob\x20too\x20short\x20(','isFile','process\x20','issueToken','event:\x20','Token\x20secret\x20not\x20configured','readlinkSync','Pause/resume\x20processor,\x20trigger\x20backups,\x20restore.','cookie','[okdb]\x20error:\x20join\x20requires\x20a\x20remote\x20address.\x20Usage:\x20okdb\x20join\x20<address>\x20--token\x20<t>','no\x20.kdbconfig\x20(using\x20defaults)','padStart','cookieName','\x20has\x20ambiguous\x20binding\x20for\x20query\x20field:\x20','\x20\x20\x20\x20-\x20The\x20activation\x20token\x20has\x20expired\x20—\x20request\x20a\x20fresh\x20one.','dropping','_buildChildRow','Invalid\x20activation\x20token:\x20','_enableChangelog','SYNC_COMMITS','\x20(id:\x20','system:clock_change','[okdb]\x20closed\x20cleanly\x0a','parts','_store','\x20\x20✓\x20OKDB\x20server\x20running','refs','cpuPct','worker_threads','readFileSync','\x0a[okdb]\x20received\x20','instances','filter','delete','OKDBTypeAlreadyRegisteredError','system:stopped','_bucketIdx','_userPhase','verifyCookie','\x0a\x20\x20License\x20details:','\x20\x20(need\x20≥\x2018)','homedir','log','\x20log\x20level:\x20','summary','_license','some','\x20\x20[okdb]\x20shutdown\x20took\x20too\x20long,\x20force-exiting\x0a','Release','trim','_licenseHash','\x20for\x20system\x20env','\x0a\x0a\x20\x20','decoded','ms\x0a','\x20on\x20this\x20data\x20path\x20runs\x20okdb\x20','Unauthorized','\x20license\x20—\x20no\x20activation\x20needed)','blindPids','_migrateVocab','put','\x20\x20\x20http://localhost:','connected','view:progress','node:perf_hooks','\x20\x20note:\x20','operations','RSA-SHA256','265ZoeLrH','[okdb]\x20primary\x20okdb\x20close\x20error:\x20','content-type','txn:start','\x20\x20(write\x20ring\x20empty\x20—\x20was\x20OKDB_DIAG\x20set\x20before\x20any\x20write?)','feed:','Invalid\x20token','\x20\x20@','\x22\x20(must\x20be\x20debug|info|warn|error)','nodesView','TYPE_NOT_REGISTERED','freeze','disconnect','_dedupeKey','ms\x20max=','type/','includes','system:proc','Admin','\x20(deleted)','expiry','\x20\x20(+\x20time-machine)','index','relative','--grants','ms\x20activeWriters=','linux','writeFileSync','\x20\x20\x20\x20\x20\x20\x20\x20\x20browse\x20API\x20routes,\x20grouped\x20by\x20area\x0a\x20\x20','\x20has\x20invalid\x20http.bodyMode:\x20','decodeActivationToken:\x20expected\x2077\x20bytes,\x20got\x20','LABEL','--types','Validation\x20failed','_singletonLock','\x20SECURITY\x20NOTICE','then','Create,\x20update,\x20and\x20delete\x20tokens\x20and\x20users;\x20rotate\x20keys.','isArray','object','dropIndex','clusterStatusView','discoveryTtlMs','\x0a\x20\x20\x20\x20','drain','values','--path','store','Open\x20licenses\x20cannot\x20exceed\x206\x20months\x20duration\x20(this\x20license\x20expires\x20','verifySignature','ms\x20p99=','createLoginState','_log','_clusterOnMessage','randomBytes','getAuthOptions','tokenizer','\x20does\x20not\x20exist','token_use','existsSync','\x20uses\x20raw\x20bodyMode\x20without\x20addRaw/raw\x20route\x20metadata','type/users','[okdb]\x20invalid\x20config\x20\x22','clearThreadStats','payload','flushDebounce','prompt','clear','shm-gc:\x20cannot\x20read\x20the\x20memory\x20maps\x20of\x20','\x0a[okdb]\x20fatal\x20error:','defaults','ENV_CLOSING_RETRY','warn','\x0a[okdb]\x20error:\x20','--no-admin','stdout','include','[okdb]\x20invalid\x20','_onStop','hashed','enabled','--env','[okdb]\x20invalid\x20port:\x20','\x20\x20in\x20use\x20(mapped/fd)\x20','sizeBefore','capable\x20HTTP\x20worker(s)\x20serving\x20:','methods','OKDB_HTTP_WORKERS\x20env','_rawDb','\x20\x20records=','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20override\x20active\x20environment\x20for\x20this\x20call\x0a\x20\x20','ORPHAN\x20(env-closed\x20write)','failures','bus:env_release','[okdb]\x20warning:\x20could\x20not\x20read\x20node\x20identity/licenses\x20before\x20reset\x20(','JWT\x20signature\x20verification\x20failed','scope','memoryUsage','_timer','[okdb]\x20exporting\x20blobs…','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20set\x20active\x20environment\x20(persists\x20in\x20session)\x0a\x20\x20','_clusterOrphanWatch','quantum','_jwksNegativeCache','UNSUPPORTED_MEDIA_TYPE','OKDBForeignKeyError','./okdb-backup','reads','_putRowSync','question','dropExisting','bytes','response','host','isActive','hasDesired','_publishFailWarned','createPublicKey','state','_nodeDb','Types','\x20missing\x20path\x20field\x20in\x20inputSchema:\x20','types:',')\x20exited\x20','opendirSync','View\x20server\x20info,\x20logs,\x20SSE\x20event\x20streams,\x20processor\x20status,\x20backup\x20list.','Version\x20mismatch\x20for\x20','abs','VIEW_PROGRESS','_children','sab','OKDBInvalidPrimaryKeyError','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20→\x20GET\x20/api/env/','_putRowAsync','\x20\x20(name:\x20','cookies','pathParams','rawBuf','\x20(dry\x20run)','time','processor:paused','expired','listLicenses','_admissionTimer','depth','Schema\x20&\x20Indexes','content-length','[okdb]\x20invalid\x20config\x20\x22http.host\x22:\x20','\x20for\x20commands,\x20','hint','set\x20OKDB_DIAG=1\x20(and\x20OKDB_DIAG_STACK=1\x20to\x20name\x20write\x20sites)','SERVICE_UNAVAILABLE','transaction','path','\x0a\x20\x20✓\x20License\x20added','_collectSingletonClaims','_totalWrites','[okdb]\x20./okdb-data\x20already\x20exists\x20—\x20skipping','LENGTH_REQUIRED','HEAD','ENV','signCookie','flushed','access','origins','_pendingLocal','OKDBInvalidIndexKeyError','Full-text\x20search','_adminRelay','\x0a\x20\x20Delete\x20ALL\x20data\x20in\x20','_report','[okdb]\x20reset\x20aborted','_active','Environment\x20lifecycle.\x20Listing\x20and\x20creating\x20envs\x20is\x20system-level.','bus:drain','kill','BAD_GATEWAY','\x20\x20\x20\x20•\x20a\x20license\x20blob\x20\x20\x20(Crockford\x20base32,\x20~150–250\x20chars)','List\x20tokens\x20and\x20users.','inputSchema','CONFLICT','length','exit','SIGINT','[okdb]\x20preserved:\x20','detectInputType','sub','\x1b[33m','syncPeers','Usage:\x20okdb\x20shm-gc\x20[--dry-run]\x20[--prefix\x20<p>]\x20[--any-size]\x20[--force]\x20[--verbose]\x0a\x0aDelete\x20okdb\x20shared-memory\x20segments\x20in\x20/dev/shm\x20that\x20no\x20live\x20process\x20maps\x20or\x20holds\x20open\x0a(older\x20okdb\x20versions\x20never\x20unlinked\x20them).\x20Recognises\x20both\x20the\x20current\x20hashed\x20names\x0a(<path>-<hash>)\x20and\x20the\x20bare-path\x20names\x20of\x20okdb\x20<=\x202.4.0.\x20Linux\x20only.\x0a\x0a\x20\x20--dry-run,\x20-n\x20\x20\x20report\x20what\x20would\x20be\x20deleted,\x20delete\x20nothing\x0a\x20\x20--prefix\x20<p>\x20\x20\x20\x20only\x20names\x20starting\x20with\x20<p>\x20(default\x20\x22-tmp-\x22:\x20stores\x20under\x20/tmp;\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x22\x22\x20=\x20every\x20okdb-shaped\x20name)\x0a\x20\x20--any-size\x20\x20\x20\x20\x20\x20don\x27t\x20require\x20an\x20okdb\x20segment\x20size\x0a\x20\x20--force\x20\x20\x20\x20\x20\x20\x20\x20\x20delete\x20even\x20if\x20some\x20same-user\x20process\x27s\x20maps\x20could\x20not\x20be\x20read\x0a\x20\x20--verbose,\x20-v\x20\x20\x20print\x20every\x20kept\x20segment\x20and\x20why','List\x20views,\x20query\x20view\x20output,\x20inspect\x20metadata\x20and\x20definition.','shmbuf.node','_refreshDesiredSnapshot','\x20\x20\x20\x20status:\x20\x20\x20\x20active\x20\x20(','token','records','?\x0a\x20\x20(node\x20identity\x20and\x20licenses\x20are\x20preserved)\x0a\x20\x20Type\x20\x22yes\x22\x20to\x20confirm:\x20','Bearer\x20$1…','foreignOwner','Views','_durs','caps','init','OKDBSchemaCollectionError','127.0.0.1','_windowCbs','_instanceId','INVALID_VALUE','_onItem','_sampleOwnStats','allSettled','migrations','\x27\x20already\x20registered','BAD_REQUEST','\x20ipc\x20error:\x20','threads','perf_hooks','alg','[env]','middlewares','cors','already\x20in\x20use','token_endpoint','[okdb]\x20error:\x20ambiguous\x20prefix\x20\x22','_loginStates','_sync','assign','okdb-diag.','keys/public.pem','\x20files)','_envs','\x20died\x20','\x20\x20\x20\x20expires:\x20\x20\x20','SIG_INVALID','catch','_handlePoke','handle','--port','\x20\x20\x20\x203.\x20Run:\x20\x20okdb\x20license\x20<activation-token>','handler','_selfKey',':\x20ping\x0a\x0a','onClaimed','system:type_drop','--username','_handlePending','HTTP\x20','onThreadExit','_publishNow','repeat','white','\x20has\x20ambiguous\x20binding\x20for\x20path\x20field:\x20','readUInt16BE','noCluster','time-machine','_maybePublish','\x20\x20\x20\x20path:\x20\x20\x20\x20','\x0a===\x20OKDB_DIAG\x20STALL:\x20swap\x20drain\x20held\x20','deaths','putNode','SCHEMA_COLLECTION_INVALID','record','\x20(deleting\x20requires\x20--force\x20if\x20none\x20of\x20them\x20is\x20okdb)','Records\x20inside\x20your\x20types\x20—\x20the\x20actual\x20rows\x20you\x20store.','statuses','_done','sig','\x20(+','event','logs','fromEntries','view','quit','legacy','resetReadTxn','received\x20','\x20\x20(licensee:\x20','_threadStats','exportEnvsToStream','hasOwnProperty','okdb-http-worker-child.js','processing','threadId','reset','\x20to\x20browse\x20the\x20API,\x20','__esModule','active','kdb_admin_csrf','sync-node','\x22\x20is\x20not\x20empty\x20—\x20backups\x20never\x20overwrite;\x20choose\x20a\x20new\x20directory','candidates','_collectWriterFacet','List\x20functions\x20and\x20inspect\x20their\x20source.','raw-remove','\x20logs\x20on\x20\x20','blobs','forEach','busy','hash','_runGuards','Create,\x20update,\x20and\x20delete\x20records\x20(including\x20bulk\x20import).','yellow','unlink','map','_outstanding','\x0a\x20\x20Invalid\x20JSON:\x20','authorization_endpoint','cpus','openDB','48tCqSHp','_ensure',')\x20→\x20','queue/','toLowerCase','\x20\x20⚠','_wantDbHandle','list','LICENSE_INVALID','_markSeen','\x20\x20\x20\x20envs:\x20\x20\x20\x20\x20\x20','licenseHash','system','Route\x20','(none)','entries','[okdb]\x20backing\x20up\x20to\x20','-backups','dirname','\x20\x20Expected\x20one\x20of:','\x20\x20unused\x20(deletable)\x20','\x20\x20\x20\x20graceful\x20shutdown\x0a','createInterface','rowKey','yes','usage:\x20okdb\x20restore\x20<backup-dir>\x20--path\x20<target-data-dir>','port\x20','[okdb]\x20blobs:\x20imported=','(primary\x20=\x20processor)','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20→\x20GET\x20/api/env/staging/info\x0a\x0a','preferred_username','index:ready','fts','__identity','build','setPrompt','spki','round','_wantDbOf','open\x20','isInteger','stop','read','requests','execArgv','resolve','\x20in\x20','readUInt8','PUB_FINGERPRINT','\x20writer{depth=','okdb-backup.json','Run\x20searches\x20against\x20registered\x20FTS\x20and\x20vector\x20indexes.','verifyActivation','rmSync','_lastCpuAt','\x20size,\x20','_highWater','reverse','--force',')\x20—\x20this\x20process\x20will\x20not\x20appear\x20in\x20the\x20process\x20census','ftruncateSync','List,\x20download,\x20and\x20inspect\x20file\x20metadata.','verbose','__writeCounter','deletedAllocated','--permissions','registry\x20heartbeat\x20skipped\x20(writer=','stopping','ephemeral','--print','not\x20open','_isClusterController','ttl:set','\x20(slot=','transactionSync','createHmac','~licenses','release','DELETE\x20type/users/item/x','writeUInt16BE','mkdirSync','Register,\x20configure,\x20and\x20remove\x20cluster\x20peers.',')\x20to\x20your\x20license\x20vendor.','maps','pushEphemeral','ttl','sourceType','https:','MAX_POOL_HOLDS','identity','\x20process','heapTotal','\x20\x20\x20\x20\x20control\x20log\x20verbosity\x0a\x20\x20',':\x20connected\x0a\x0a','processors','listRoutes','UNIQUE_CONSTRAINT','getCmd','current','toString','--address','copy','JWT\x20not\x20yet\x20valid','Write','\x0a\x20\x20\x20\x20\x20\x20','Validation\x20failed:\x20','\x20active\x20env:\x20','\x20\x20[okdb]\x20','registry-publish','listNodes','[okdb]\x20error:\x20no\x20license\x20with\x20id\x20\x22','\x20times\x20in\x20','decodeLicenseBlob:\x20input\x20must\x20be\x20a\x20string','\x20\x20Usage:\x20okdb\x20license\x20[<blob|path|uuid|activation-token>]','_rootDb','uri','readUInt32BE','credentials','_resolveEnv','_lastTick','schema:set','[okdb]\x20opening\x20','kind','\x0a\x20\x20Run\x20okdb\x20to\x20start\x20the\x20server.\x0a','_cursors','\x20cf-ip=','(add\x20a\x20license\x20first)','_handleInProcess','Engines','\x20/\x20','\x20cf-ray=','Gate\x20flag\x20required\x20to\x20touch\x20system\x20types\x20(those\x20whose\x20name\x20starts\x20with\x20\x22~\x22).\x20Combined\x20with\x20the\x20underlying\x20namespace\x20permission.','update','details','isSetupMode','Register/update/delete\x20types,\x20register/drop/rebuild\x20indexes,\x20set\x20TTL\x20policy.','supervisorKey','http://localhost:','method','[okdb]\x20.kdbconfig\x20already\x20exists\x20—\x20skipping','rawResponse','number','env/','cause','OIDC\x20discovery\x20missing\x20jwks_uri','building','\x0a\x20\x20✓\x20License\x20activated',',\x20which\x20still\x20exists\x20—\x20the\x20restored\x20','node','\x0a\x20\x20Raw\x20token\x20(shown\x20once,\x20save\x20it\x20now):\x0a','_cmd','formatCookie','access-control-max-age','pid','store\x20will\x20open\x20THAT\x20directory,\x20not\x20the\x20copy\x20in\x20','\x20\x20✓\x20OKDB\x20cluster\x20running','setSchema','shm-gc:\x20Linux\x20only\x20(POSIX\x20shared\x20memory\x20under\x20/dev/shm)','terminal','okdb_session','tierList','blob','index:reset','\x20days\x20—\x20POC/demo\x20only,\x20not\x20node-bound)','issuer','columns','~processes','readdirSync','\x20\x20\x20\x20pin:\x20\x20\x20\x20\x20','\x20already\x20in\x20use','ENOENT','\x20freed','Enqueue,\x20cancel,\x20retry,\x20remove\x20jobs;\x20manage\x20buckets;\x20reconcile\x20and\x20rebuild\x20stats.','\x22\x20→\x20','listen','index:drop','_openEnvLazy','GATEWAY_TIMEOUT','node/',';\x20Secure','tags:\x20','afterWrite','userAdded','Origin','Environments','Build\x20expects\x20public\x20key\x20fingerprint\x20','exp','\x22\x20in\x20env\x20\x22','finish','cluster:\x20ready\x20(','prefix','features','\x20===','\x20(expires\x20in\x20','\x1b[36m','PAYLOAD_TOO_LARGE','target\x20','\x0d[okdb]\x20','processingSig','sha256','primary','_isFree','USE','green','nbf','\x20deleted','bodyMode','min','isDead','charCodeAt','\x20\x20\x20\x20path:\x20\x20','--env\x20<name>','\x20\x20✗\x20','_writer','_resolveOrCreateEnv','writeUInt8','creating','envsOpen','_dispatch','revoke','\x20environment\x20','parseBearer','groups','all','waiting','keys','\x20\x20[','OKDBInvalidValueError','access-control-request-headers','ceil','/([^/]+)','--name','children','\x1b[2m','~lock','env:opened','emit','basename','.okdb-write-test','maxAge','fts:reset','is\x20not\x20allowed','\x20which\x20does\x20not\x20exist','type:registered','inUse','win32','--drop','realpathSync','false','--changes','Type\x20definitions,\x20all\x20index\x20registrations\x20(byIndex,\x20FTS,\x20vector),\x20and\x20TTL\x20policy.','server','items','--log-level','_isOpen','INDEX_NOT_REGISTERED','result','status','\x20\x20Usage:\x20','_coordinator','deleted','context','isWorker','types\x20--env\x20staging','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20open\x20admin\x20UI\x20in\x20browser\x0a\x20\x20','NAME','shift','scrypt','\x20\x20\x20\x20licensee:\x20\x20','force','single','Query','CLI\x20(`okdb\x20listen`),\x20or\x20use\x20Node\x27s\x20built-in\x20`cluster`\x20module\x20and\x20call\x20','[okdb]\x20error:\x20failed\x20to\x20read\x20','[okdb]\x20restore\x20complete\x20—\x20full-text\x20indexes\x20rebuild\x20on\x20first\x20open','enforce','maxWrites','\x0a\x20\x20Usage:\x20use\x20<env-name>\x0a','segmentNameFor:\x20canonicalPath\x20must\x20be\x20a\x20non-empty\x20string','_normalizeOAuthAuthResult','\x20\x20env=','Access-Control-Request-Headers','backupRoot','(unset)','_acquiredAt','\x20\x20✓\x20database\x20opened\x0a','search','_desiredOverlay','required','\x0a\x20\x20✓\x20License\x20already\x20stored\x20(no\x20change)','_lastCpuPct','matched','pathname','entry','query.','\x20\x20(','getPins','loop-lag','\x22\x20on\x20\x22','MiB','uid','signalWant','metrics','27894cniFcI','servers','importJSON','params.env','ensureType','_nodeDbFor','_computeStatus','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20→\x20GET\x20/api/env/','[okdb]\x20reset:\x20','getKeys','_lock','\x22\x20matches\x20','type/users/query\x20{\x22active\x22:true}','_buildProcessingFacet','ready','setFlagsFromString','Forbidden','dropType','11885952bOgATW','_assertUsable','_put','\x20to\x20quit.','sse','May\x20write\x20system\x20types\x20when\x20also\x20granted\x20the\x20underlying\x20write\x20permission.','/type/users\x0a\x20\x20\x20\x20','TOO_MANY_REQUESTS','heartbeatMs','\x20(expires\x20','resume','cluster-wide','writes=','_lastPublishAt','slot','bind','payload-or-self','keep-alive','history','getProcess','\x20\x20\x20\x20port:\x20\x20','\x20\x20Usage:\x20logs\x20[on|off|debug|info|warn|error]','red','\x22\x20is\x20inside\x20the\x20store\x20\x22','\x27\x20on\x20type\x20\x27','[okdb]\x20error:\x20revoke\x20requires\x20an\x20id\x20argument','definition',';\x20SameSite=','BOOTSTRAP_LOCALHOST_ONLY','Processors','License\x20expired\x20or\x20invalidated','fetch','\x20\x20\x20\x20\x20\x20\x20\x20\x20OKDB\x20SHELL\x20\x20\x20\x20\x20\x20\x20\x20','extend','\x20\x20\x20\x20\x20\x20','guards','\x20\x20+','importFromStream','BACKUP_PATH_OUTSIDE_ROOT','--token','/dev/shm/','license:added','resetFts','resetIndex','\x20more)','dumpedAt','__okdbCluster','val','candidateBytes','Index\x20\x22','ingest','\x20envs','putSync','flatMap','./okdb-data','concat','\x20—\x20','export','username','VALIDATION_ERROR','bootstrapBlocked','types','recent\x20writes\x20(newest\x20first)','_role','dead','reduce','Read','register','--ttl','[okdb]\x20error:\x20remove\x20requires\x20an\x20id\x20argument','/type/users/query\x0a\x20\x20\x20\x20','\x20worker(s)\x20remaining','peers=','[okdb]\x20error:\x20--address\x20is\x20required\x20for\x20join\x20(this\x20node\x27s\x20reachable\x20sync\x20address).\x0a','typesPerEnv','shmbufNative','fast','getRange','SCHEMA_VALIDATION_FAILED','data.mdb','protected:write','readInt32LE','.\x20Primary\x20keys\x20must\x20be\x20string\x20or\x20number.\x20Got:\x20','updatedAt','_isWriter','readMs','data:write','comm','changed','PUT','_fetchJwks','FEATURES','workersFlag','index:progress','bumpCmd','.kdb_history','true','send','\x20\x20\x20\x20usage:\x20\x20\x20','\x20\x20\x20\x20status:\x20\x20\x20\x20active','./okdb-export.ndjson','\x27,\x20cannot\x20map\x20to\x20\x27','\x0a\x20\x20[okdb]\x20force-exiting\x20(second\x20interrupt)\x0a','getChanges','licensee','version','\x20\x20Common\x20causes:','env','\x20\x20Some\x20checks\x20failed.\x0a','data','Events','TYPES','ITEM_CREATE','licensed','req','\x20\x20║','\x20\x20·\x20','floor','workersConfigured','\x20(must\x20be\x20true\x20or\x20false)','shutdown','__okdbSlot','onLicenseExpired','reason','clockToChangeDb','SYSTEM_PROC','split','geo','\x20pid=','BACKUP_DEST_INSIDE_STORE','field:resolver_registered','hex','origin',',\x20stopping\x20workers…\x0a','load','\x20is\x20not\x20empty\x20—\x20restore\x20only\x20into\x20a\x20new\x20or\x20empty\x20directory','_scheduleFlush','\x27\x20doesn\x27t\x20exist','HTTP_CLUSTER_REMOVED','API\x20tokens,\x20users,\x20and\x20credentials.','INDEX_READY','changes','commit','\x20\x20\x20\x20•\x20an\x20activation\x20token\x20\x20(124\x20chars)','isAbsolute','\x20(must\x20be\x20a\x20string\x20or\x20array\x20of\x20strings)','transport:\x20','envName','retiring','participate','_totalReads','childTransaction','--config','tokenType','set','stderr','Execute\x20full-text\x20and\x20vector\x20searches.','join','respawnTimer','exportBlobs','\x20parkedNow=','size','cf-connecting-ip','magenta','forceAfterMs','listenAddr','queue',']:\x20transaction\x20ran\x20nested\x20inside\x20a\x20write\x20txn\x20held\x20open\x20by\x20a\x20non-writer\x20caller','[okdb]\x20error:\x20--grants\x20must\x20be\x20valid\x20JSON\x20object','okdb-backup-','role','external',':want','singletonClaims','startsWith','closeIdleConnections','\x20\x20\x20\x20api:\x20\x20\x20http://localhost:','isHeld','OKDBNotFoundError','pop','system:ready','scanned','No\x20tokens.','Run','standard','prependListener','ESRCH','Register,\x20update,\x20and\x20delete\x20function\x20definitions.','View\x20peer\x20status\x20and\x20replication\x20stats.','_getJwkKey','files','cf-ray',',\x20label:\x20','\x20drainAge=','~processes:desired','maxMs','onWindow','_committed','publishChildRow','decodeActivationToken','workers','remaining-fields','/type/users/item/alice\x0a\x20\x20\x20\x20','input:\x20','unref','\x20\x20✓\x20http\x20listening\x20on\x20','shared-memory\x20segment\x20\x22','node:crypto','race','seq','close','_caps','REQUEST_TIMEOUT','email','meta','change','[okdb]\x20error:\x20token\x20with\x20name\x20\x22','hasCanonical','inflightAgesMs','mcp','unclaimed','digest','_kind','3951438kZMtAr','_drain','getDesired','_ownMeta','params','\x22\x20resolves\x20outside\x20the\x20backup\x20root\x20\x22','name','open','activate','_nodeDead','byteLength','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','clock','firstTs','_jwksCache','fanout','remoteAddress','events','\x22.\x20Use:\x20create,\x20list,\x20revoke','Indexes','SIGINT\x20(double-tap)','openSync','exclusiveStart','hasType','SIGBREAK','removeSupervisedChild','sourcePath','ALREADY_EXISTS','~files','%),\x20','cpuWindowMs','work',';\x20Path=','logRequests','Unknown\x20error','matcher','processorsView','[okdb-cluster]\x20change-feed\x20init\x20failed:\x20','GiB','sandbox','acquiredAt','removeSync','offWindow','_flushDebounce','ACTIVATION_EXPIRED','\x20querySchema\x20references\x20missing\x20input\x20field:\x20','_bpWaiters',',\x20got\x20','JWT\x20issuer\x20mismatch','audiences','options','System','REMOVE','stringify','type','\x0a===\x20OKDB_DIAG\x20','_changefeed','[okdb]\x20started\x20in\x20','PERMISSIONS','\x20\x20other\x20owner\x20\x20\x20\x20\x20\x20\x20\x20','cli','INTERNAL_ERROR','\x20+\x20','\x20\x20(no\x20env\x20draining)','OKDBIndexAlreadyRegisteredError','LICENSE_ALREADY_STORED','bindings','authorization','skippedByProtocol','\x22\x20—\x20pass\x20a\x20path\x20relative\x20to\x20it\x20(configure\x20with\x20the\x20`backup.root`\x20option)','remove','Unique\x20constraint\x20violated\x20on\x20','processes','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20→\x20GET\x20/api/envs\x0a\x20\x20\x20\x20','null','\x20\x20╚═══════════════════════════╝','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20GET\x20(implicit)\x0a\x20\x20','_statusEnv','gate','worker','\x20\x20·\x20\x20','system:poke','\x22\x20already\x20exists','_quantum','\x20fetching\x20','roles','\x20\x20\x20\x20license:\x20⚠\x20OPEN\x20—\x20','\x20\x20✓\x20Removed\x20license\x20','tryAcquire','clusterWorkers','addSSE','_removeRowAsync','\x20day(s).','authRequired','processor:error','restore','\x20phase=','main','removeNode','\x20type','[okdb]\x20error:\x20join\x20requires\x20credentials.\x20Provide\x20--token\x20<t>\x20or\x20--username\x20<u>\x20--password\x20<p>','_startAdmission','\x20\x20→\x20\x20','--help','tags','unknown','Forbidden\x20—\x20requires\x20','add','SHM_SEGMENT_RETIRING','BACKUP_MANIFEST','stream','drop','txn:end','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20→\x20GET\x20/api/env/','detachConsole','okdb-writer:\x20env\x20closing\x20—\x20retry','uptime','isDirectory','PIN','Examples','_systemEnv','[okdb]\x20error:\x20no\x20token\x20with\x20id\x20\x22','readline','_validateOperationRequest','--label','[okdb]\x20error:\x20show\x20requires\x20an\x20id\x20argument','--any-size','License\x20signature\x20invalid\x20—\x20this\x20license\x20was\x20not\x20signed\x20by\x20the\x20key\x20paired\x20with\x20this\x20build.\x20','max','assertFeature','item:update','[okdb]\x20export\x20complete','getHeader','\x20sync','\x20HTTP\x20server(s)\x20on\x20port\x20','-tmp-','boolean','\x20\x20\x20\x202.\x20The\x20vendor\x20returns\x20an\x20activation\x20token.',');\x20','failed\x20to\x20open','attachFeed','paused','\x20(must\x20be\x201–65535)','fork','startedAt','UNPROCESSABLE_ENTITY','unreadablePids','.log','Server\x20is\x20in\x20bootstrap\x20mode\x20and\x20only\x20accepts\x20localhost\x20connections\x20until\x20the\x20first\x20token\x20is\x20created.','attached','inspect','replace','\x20document(s)\x20reference\x20it\x20with\x20onDelete:restrict','envs=','Server-side\x20user-defined\x20functions\x20registered\x20per\x20environment.','Files','registerType','FTS_RESET','\x20oldestPendingMs=','--no-repl','logLevel','ftsIndexes','starting','Payload\x20too\x20large','/admin/index.html','type/users/item/alice\x20--env\x20staging','_enqueuedAt','prototype','{}[]:,\x0a\x0d\x09\x20','geoConfig','array','[res]\x20','treeView',']\x20already\x20maps\x20to\x20\x27','Auth','_draining','base64url','[okdb]\x20imported\x20\x20types=','[okdb]\x20failed\x20to\x20parse\x20config\x20file\x20','setHeader','Invalid\x20license\x20blob:\x20','commitsPerSec','JWT\x20expired','LICENSE_HASH_MISMATCH','closeSync','dir','verify','level:\x20info','stack','shm\x20segment\x20','allocUnsafe','confirm','\x20\x20\x20\x20\x20explicit\x20method\x0a\x0a\x20\x20','withPoolHold',':\x20key\x20[','\x20(other\x20users;\x20cannot\x20map\x200600\x20segments)','addLicense','port','FTS_DROP','selfKey','publishOwnRow','candidateAllocated','_blobPath','_shouldWrapResponse','Create,\x20delete,\x20and\x20compact\x20environments.','copyFileSync','fields','unique:violation_resolved','operation','pause','Cannot\x20set\x20enforce\x20schema\x20on\x20','\x1b[35m','Upload,\x20update\x20metadata,\x20and\x20delete\x20files.','\x20\x20(licenses\x20must\x20be\x20signed\x20by\x20the\x20matching\x20private\x20key)'];_0x2196=function(){return _0x15b21d;};return _0x2196();}var hasRequiredOkdbWriter;function requireOkdbWriter(){const _0x2ee91b=_0x1cb9ed;if(hasRequiredOkdbWriter)return okdbWriter[_0x2ee91b(0x761)];hasRequiredOkdbWriter=0x1;const {performance:_0x587f35}=require$$0$5,_0x4e74cf=requireOkdbDiag(),_0x19dc47=process.env.OKDB_COMMIT_MODE===_0x2ee91b(0x15e);class _0x4d666b{constructor(_0x1605f8){const _0x22be25=_0x2ee91b;this[_0x22be25(0x514)]=_0x1605f8,this[_0x22be25(0x794)]=new Set(),this[_0x22be25(0x62e)]=new Map(),this['_committed']=0x0,this[_0x22be25(0x2fb)]=[],this['_done']=[],this[_0x22be25(0x3a0)]=Math[_0x22be25(0x608)](0x0,Number(process.env.OKDB_WRITER_HIGH_WATER??0x400)),this[_0x22be25(0x363)]=0x0,this['_bpWaiters']=[],this[_0x22be25(0x79c)]=0x0,this[_0x22be25(0x115)]=null,this[_0x22be25(0x683)]=0x0,this['_nestedTotal']=0x0,this[_0x22be25(0x157)]=![];}async[_0x2ee91b(0x2cb)](_0xe20edf,_0x4aac18,{admitted:admitted=![]}={}){const _0x48dbf7=_0x2ee91b;if(_0x4e74cf[_0x48dbf7(0x6c0)]())_0x4e74cf[_0x48dbf7(0x6d1)](this[_0x48dbf7(0x514)]?.[_0x48dbf7(0x58e)],_0x4aac18);if(this[_0x48dbf7(0x75b)]){const _0x3a2b86=new Error('okdb-writer:\x20env\x20closing\x20—\x20retry');_0x3a2b86['code']=_0x48dbf7(0x27a);throw _0x3a2b86;}if(this[_0x48dbf7(0x3a0)]>0x0){let _0x2282be=![];while(this['_outstanding']>=this['_highWater']&&!this[_0x48dbf7(0x75b)]){!_0x2282be&&(_0x2282be=!![],this[_0x48dbf7(0x79c)]++),await new Promise(_0xa3b0a2=>this[_0x48dbf7(0x5b6)][_0x48dbf7(0x1c2)](_0xa3b0a2));}if(this[_0x48dbf7(0x75b)]){const _0x191cfb=new Error(_0x48dbf7(0x5fb));_0x191cfb[_0x48dbf7(0x72d)]=_0x48dbf7(0x27a);throw _0x191cfb;}}this[_0x48dbf7(0x363)]++;const _0x3d4239=admitted?null:this[_0x48dbf7(0x514)][_0x48dbf7(0x46b)];for(;;){while(this[_0x48dbf7(0x115)])await this['_held'];if(_0x3d4239)try{await _0x3d4239[_0x48dbf7(0x765)]();}catch(_0x41861b){this[_0x48dbf7(0x363)]--;if(this['_bpWaiters']['length']&&this[_0x48dbf7(0x363)]<this[_0x48dbf7(0x3a0)])this[_0x48dbf7(0x5b6)]['shift']()();throw _0x41861b;}if(!this[_0x48dbf7(0x115)])break;if(_0x3d4239)_0x3d4239[_0x48dbf7(0x41d)]();}if(this[_0x48dbf7(0x75b)]){if(_0x3d4239)_0x3d4239[_0x48dbf7(0x41d)]();this[_0x48dbf7(0x363)]--;if(this[_0x48dbf7(0x5b6)][_0x48dbf7(0x2e8)]&&this[_0x48dbf7(0x363)]<this[_0x48dbf7(0x3a0)])this['_bpWaiters'][_0x48dbf7(0x472)]()();const _0x230489=new Error(_0x48dbf7(0x5fb));_0x230489[_0x48dbf7(0x72d)]=_0x48dbf7(0x27a);throw _0x230489;}const _0x25b26d=_0x587f35[_0x48dbf7(0x6f1)]();if(_0x19dc47)try{const _0x569def=this[_0x48dbf7(0x514)]['db']['transactionSync'](_0xe20edf);this['_committed']++;if(this[_0x48dbf7(0x2fb)][_0x48dbf7(0x1c2)](_0x587f35[_0x48dbf7(0x6f1)]()-_0x25b26d)>0x100)this[_0x48dbf7(0x2fb)]['shift']();if(this[_0x48dbf7(0x33c)][_0x48dbf7(0x1c2)](_0x587f35['now']())>0x800)this[_0x48dbf7(0x33c)][_0x48dbf7(0x472)]();return _0x569def;}finally{this[_0x48dbf7(0x363)]--;if(this[_0x48dbf7(0x5b6)][_0x48dbf7(0x2e8)]&&this[_0x48dbf7(0x363)]<this['_highWater'])this[_0x48dbf7(0x5b6)][_0x48dbf7(0x472)]()();if(_0x3d4239)_0x3d4239[_0x48dbf7(0x41d)]();}let _0x4feabf=null;const _0xbd58b3=()=>{const _0x529a61=_0x48dbf7,_0x10c0dd=_0xe20edf();if(_0x10c0dd&&typeof _0x10c0dd[_0x529a61(0x257)]===_0x529a61(0x18e)&&!_0x4feabf){this['_heldTotal']++;let _0x37857f;const _0x2b9952=new Promise(_0x1a8390=>_0x37857f=_0x1a8390);this['_held']=_0x2b9952,_0x4feabf=()=>{const _0x28eb2c=_0x529a61;if(this[_0x28eb2c(0x115)]===_0x2b9952)this['_held']=null;_0x37857f();};}return _0x10c0dd;};let _0x2c7523;try{_0x2c7523=this[_0x48dbf7(0x514)]['db'][_0x48dbf7(0x540)](_0xbd58b3);}catch(_0x1faf2e){_0x2c7523=Promise['reject'](_0x1faf2e);}(!_0x2c7523||typeof _0x2c7523[_0x48dbf7(0x257)]!==_0x48dbf7(0x18e))&&(this['_nestedTotal']++,!this[_0x48dbf7(0x157)]&&(this[_0x48dbf7(0x157)]=!![],console[_0x48dbf7(0x27b)](_0x48dbf7(0x161)+(this[_0x48dbf7(0x514)]?.['name']??'?')+_0x48dbf7(0x550))),_0x2c7523=Promise[_0x48dbf7(0x395)](_0x2c7523));const _0x443876=()=>{if(_0x4feabf)_0x4feabf();};_0x2c7523['then'](_0x443876,_0x443876),this[_0x48dbf7(0x794)][_0x48dbf7(0x5f3)](_0x2c7523),this['_enqueuedAt'][_0x48dbf7(0x543)](_0x2c7523,_0x25b26d);const _0x481e84=()=>{const _0x27d1a8=_0x48dbf7;this[_0x27d1a8(0x794)][_0x27d1a8(0x210)](_0x2c7523),this[_0x27d1a8(0x62e)][_0x27d1a8(0x210)](_0x2c7523),this[_0x27d1a8(0x56e)]++,this[_0x27d1a8(0x363)]--;this[_0x27d1a8(0x5b6)][_0x27d1a8(0x2e8)]&&this['_outstanding']<this[_0x27d1a8(0x3a0)]&&this['_bpWaiters'][_0x27d1a8(0x472)]()();if(this['_durs'][_0x27d1a8(0x1c2)](_0x587f35[_0x27d1a8(0x6f1)]()-_0x25b26d)>0x100)this[_0x27d1a8(0x2fb)][_0x27d1a8(0x472)]();if(this[_0x27d1a8(0x33c)][_0x27d1a8(0x1c2)](_0x587f35['now']())>0x800)this[_0x27d1a8(0x33c)]['shift']();};_0x2c7523[_0x48dbf7(0x257)](_0x481e84,_0x481e84);try{return await _0x2c7523;}finally{if(_0x3d4239)_0x3d4239['afterWrite']();}}[_0x2ee91b(0x469)](){const _0x47414c=_0x2ee91b,_0x4dea8e=_0x587f35['now']();let _0x5975e5=0x0;for(const _0x1ffcb6 of this[_0x47414c(0x62e)][_0x47414c(0x260)]()){const _0x42e3d3=_0x4dea8e-_0x1ffcb6;if(_0x42e3d3>_0x5975e5)_0x5975e5=_0x42e3d3;}let _0x1a96f4=0x0;for(let _0x31389c=this[_0x47414c(0x33c)][_0x47414c(0x2e8)]-0x1;_0x31389c>=0x0;_0x31389c--){if(_0x4dea8e-this[_0x47414c(0x33c)][_0x31389c]>0x3e8)break;_0x1a96f4++;}let _0xddc25b=0x0;if(this[_0x47414c(0x2fb)][_0x47414c(0x2e8)]){const _0x35a6fc=[...this[_0x47414c(0x2fb)]][_0x47414c(0x108)]((_0xf1c9ae,_0x4e1867)=>_0xf1c9ae-_0x4e1867);_0xddc25b=_0x35a6fc[Math[_0x47414c(0x437)](_0x35a6fc[_0x47414c(0x2e8)]-0x1,Math[_0x47414c(0x51e)](_0x35a6fc[_0x47414c(0x2e8)]*0.99))];}return{'depth':this[_0x47414c(0x794)][_0x47414c(0x54a)],'oldestPendingMs':Math[_0x47414c(0x38d)](_0x5975e5),'committed':this[_0x47414c(0x56e)],'commitsPerSec':_0x1a96f4,'commitP99Ms':Math['round'](_0xddc25b),'parkedNow':this[_0x47414c(0x5b6)][_0x47414c(0x2e8)],'parkedTotal':this[_0x47414c(0x79c)],'highWater':this['_highWater']};}[_0x2ee91b(0x583)](){const _0x114390=_0x2ee91b,_0x332903=_0x587f35[_0x114390(0x6f1)]();return[...this['_enqueuedAt'][_0x114390(0x260)]()][_0x114390(0x362)](_0x36262e=>Math[_0x114390(0x38d)](_0x332903-_0x36262e))[_0x114390(0x108)]((_0x4e09ca,_0x4e51e7)=>_0x4e51e7-_0x4e09ca);}['markClosed'](){const _0x3bc618=_0x2ee91b;this[_0x3bc618(0x75b)]=!![];for(const _0x3117c2 of this[_0x3bc618(0x5b6)]['splice'](0x0))_0x3117c2();}async['drain'](){const _0x3d06a0=_0x2ee91b;let _0x26b9c3=0x0;while(this[_0x3d06a0(0x794)][_0x3d06a0(0x54a)]&&_0x26b9c3++<0x3e8){await Promise['allSettled']([...this[_0x3d06a0(0x794)]]);}}async[_0x2ee91b(0x22b)](_0x9b759e,_0x403705,_0x1176d1,_0x1fd4b4){return this['transaction'](()=>{const _0x2cd3e1=_0x4ed4;if(_0x1fd4b4===undefined)_0x9b759e['putSync'](_0x403705,_0x1176d1);else _0x9b759e[_0x2cd3e1(0x4dd)](_0x403705,_0x1176d1,_0x1fd4b4);},'raw-put');}async['remove'](_0x4b5ffc,_0x3decef){const _0x25b52a=_0x2ee91b;return this[_0x25b52a(0x2cb)](()=>_0x4b5ffc[_0x25b52a(0x5b1)](_0x3decef),_0x25b52a(0x358));}}async function _0x48ebaf(_0x257306,_0x4751b6){const _0x180150=_0x2ee91b;if(_0x4751b6==null)_0x4751b6=Math[_0x180150(0x608)](0x3e8,Number(process.env.OKDB_FLUSH_BEFORE_CLOSE_MS)||0x1d4c0);try{const _0x1cb10f=_0x257306?.[_0x180150(0x2d5)];if(!_0x1cb10f||typeof _0x1cb10f['then']!==_0x180150(0x18e))return;await Promise[_0x180150(0x579)]([Promise['resolve'](_0x1cb10f)[_0x180150(0x31d)](()=>{}),new Promise(_0x55f945=>{const _0x58b362=_0x180150,_0x112a1a=setTimeout(_0x55f945,_0x4751b6);if(_0x112a1a[_0x58b362(0x575)])_0x112a1a[_0x58b362(0x575)]();})]);}catch{}}function _0x4fa3a9(_0xd96f29){const _0x1acced=_0x2ee91b;if(_0x19dc47)return Promise[_0x1acced(0x395)]();const _0x4f6719=_0xd96f29?.[_0x1acced(0xdc)];return _0x4f6719&&typeof _0x4f6719[_0x1acced(0x257)]===_0x1acced(0x18e)?_0x4f6719:Promise[_0x1acced(0x395)]();}const _0x1a8a70=Math['max'](0x1,Math[_0x2ee91b(0x51e)](Number(process.env.UV_THREADPOOL_SIZE))||0x4),_0xa4fd91=Math[_0x2ee91b(0x608)](0x1,_0x1a8a70-0x2);let _0x3a5639=0x0;const _0x4332a7=[];async function _0x14991c(_0x1d6e0c){const _0x194da8=_0x2ee91b;if(_0x3a5639<_0xa4fd91)_0x3a5639++;else await new Promise(_0x315a56=>_0x4332a7['push'](_0x315a56));try{return await _0x1d6e0c();}finally{const _0x22dd61=_0x4332a7[_0x194da8(0x472)]();if(_0x22dd61)_0x22dd61();else _0x3a5639--;}}return okdbWriter[_0x2ee91b(0x761)]=_0x4d666b,okdbWriter['exports'][_0x2ee91b(0x649)]=_0x14991c,okdbWriter[_0x2ee91b(0x761)][_0x2ee91b(0x3c0)]=_0xa4fd91,okdbWriter[_0x2ee91b(0x761)][_0x2ee91b(0x70b)]=_0x48ebaf,okdbWriter[_0x2ee91b(0x761)][_0x2ee91b(0xdc)]=_0x4fa3a9,okdbWriter['exports'][_0x2ee91b(0x202)]=_0x19dc47,okdbWriter[_0x2ee91b(0x761)];}var okdbLock,hasRequiredOkdbLock;function requireOkdbLock(){const _0x313f4e=_0x1cb9ed;if(hasRequiredOkdbLock)return okdbLock;hasRequiredOkdbLock=0x1;const _0x43aa22=require$$0,{SYNC_COMMITS:_0x4db44a}=requireOkdbWriter(),_0x1c2483=_0x313f4e(0x452);class _0x4eb5f4{constructor(_0x5850f8,_0x191760,_0x593f3f){const _0x56ce8a=_0x313f4e;this[_0x56ce8a(0x4a1)]=_0x5850f8,this[_0x56ce8a(0xd4)]=_0x191760,this[_0x56ce8a(0x484)]=_0x593f3f,this[_0x56ce8a(0x90)]=![],this[_0x56ce8a(0x14e)]=null,this[_0x56ce8a(0x71a)]=null;}[_0x313f4e(0x55a)](){const _0x1fd748=_0x313f4e;if(this['_released'])return![];try{const _0x414b19=this[_0x1fd748(0x4a1)]['_db']()['get'](this[_0x1fd748(0xd4)]);if(!_0x414b19||_0x414b19['acquiredAt']!==this[_0x1fd748(0x484)])return![];const _0x1f35d4=_0x414b19[_0x1fd748(0x4fc)]??_0x414b19[_0x1fd748(0x5b0)];if(_0x1f35d4+_0x414b19[_0x1fd748(0x151)]<Date[_0x1fd748(0x6f1)]())return![];return!![];}catch{return!this['_released'];}}[_0x313f4e(0x746)](){const _0x3414a=_0x313f4e;if(this[_0x3414a(0x90)])return null;try{return this[_0x3414a(0x4a1)][_0x3414a(0x1e4)]()['get'](this[_0x3414a(0xd4)])??null;}catch{return null;}}async[_0x313f4e(0x4ca)](_0x26418a){const _0x2f85a5=_0x313f4e;if(this[_0x2f85a5(0x90)])return;try{if(this[_0x2f85a5(0x4a1)][_0x2f85a5(0x75b)]())return;const _0x339c8=this['_lock'][_0x2f85a5(0x1e4)]()[_0x2f85a5(0x741)](this[_0x2f85a5(0xd4)]);if(!_0x339c8||_0x339c8[_0x2f85a5(0x5b0)]!==this['_acquiredAt'])return;if(_0x4db44a)this[_0x2f85a5(0x4a1)]['_db']()[_0x2f85a5(0x4dd)](this['_key'],{..._0x339c8,'ttlMs':_0x339c8[_0x2f85a5(0x151)]+_0x26418a});else await this[_0x2f85a5(0x4a1)]['_db']()[_0x2f85a5(0x22b)](this[_0x2f85a5(0xd4)],{..._0x339c8,'ttlMs':_0x339c8[_0x2f85a5(0x151)]+_0x26418a});}catch{}}async[_0x313f4e(0x3b5)](){const _0x5651d8=_0x313f4e;if(this[_0x5651d8(0x90)])return;if(this[_0x5651d8(0x71a)])try{await this['_heartbeatInFlight'];}catch{}clearInterval(this[_0x5651d8(0x14e)]),this['_heartbeatTimer']=null,this[_0x5651d8(0x90)]=!![];try{if(this[_0x5651d8(0x4a1)][_0x5651d8(0x75b)]())return;const _0x58a891=this[_0x5651d8(0x4a1)]['_db']()['get'](this[_0x5651d8(0xd4)]);if(_0x58a891&&_0x58a891[_0x5651d8(0x5b0)]===this[_0x5651d8(0x484)]){if(_0x4db44a)this[_0x5651d8(0x4a1)][_0x5651d8(0x1e4)]()['removeSync'](this[_0x5651d8(0xd4)]);else await this[_0x5651d8(0x4a1)][_0x5651d8(0x1e4)]()[_0x5651d8(0x5ce)](this['_key']);}}catch{}}[_0x313f4e(0x695)](_0x471433,_0x4c734d){const _0x397d2a=_0x313f4e,_0x435d25=_0x4c734d??Math['floor'](_0x471433/0x3);this[_0x397d2a(0x14e)]=setInterval(()=>{const _0x1116fa=_0x397d2a;if(this['_released'])return;this[_0x1116fa(0x71a)]=((async()=>{const _0x2c89d6=_0x1116fa;try{if(this[_0x2c89d6(0x4a1)][_0x2c89d6(0x75b)]())return;const _0x18300e=this[_0x2c89d6(0x4a1)][_0x2c89d6(0x1e4)]()[_0x2c89d6(0x741)](this[_0x2c89d6(0xd4)]);if(!_0x18300e||_0x18300e[_0x2c89d6(0x5b0)]!==this['_acquiredAt']){this[_0x2c89d6(0x90)]=!![],clearInterval(this[_0x2c89d6(0x14e)]),this['_heartbeatTimer']=null;return;}if(_0x4db44a)this[_0x2c89d6(0x4a1)][_0x2c89d6(0x1e4)]()[_0x2c89d6(0x4dd)](this[_0x2c89d6(0xd4)],{..._0x18300e,'updatedAt':Date[_0x2c89d6(0x6f1)]()});else await this[_0x2c89d6(0x4a1)][_0x2c89d6(0x1e4)]()[_0x2c89d6(0x22b)](this[_0x2c89d6(0xd4)],{..._0x18300e,'updatedAt':Date[_0x2c89d6(0x6f1)]()});}catch{}this[_0x2c89d6(0x71a)]=null;})());},_0x435d25);if(this[_0x397d2a(0x14e)][_0x397d2a(0x575)])this[_0x397d2a(0x14e)][_0x397d2a(0x575)]();}}class _0x30a56e{constructor(_0x545cf0,{namespace:_0x3d7c27,ttlMs:ttlMs=0x7530,heartbeatMs:heartbeatMs=null}={}){const _0x797ea7=_0x313f4e;this[_0x797ea7(0x28b)]=_0x545cf0,this['namespace']=_0x3d7c27,this[_0x797ea7(0x151)]=ttlMs,this[_0x797ea7(0x4b1)]=heartbeatMs,this[_0x797ea7(0x6cb)]=null;}['_db'](){const _0x5c47be=_0x313f4e;return this[_0x5c47be(0x4aa)](),(!this[_0x5c47be(0x6cb)]||this[_0x5c47be(0x6f7)]!==this[_0x5c47be(0x28b)])&&(this['_lockDb']=this[_0x5c47be(0x28b)][_0x5c47be(0x367)](_0x1c2483,{'dupSort':![]}),this[_0x5c47be(0x6f7)]=this[_0x5c47be(0x28b)]),this[_0x5c47be(0x6cb)];}[_0x313f4e(0x1d9)](){const _0x41df42=_0x313f4e;return this[_0x41df42(0x4aa)](),(!this[_0x41df42(0x36e)]||this[_0x41df42(0x38e)]!==this[_0x41df42(0x28b)])&&(this[_0x41df42(0x36e)]=this['_rawDb']['openDB'](_0x1c2483+_0x41df42(0x555),{'dupSort':![]}),this['_wantDbOf']=this[_0x41df42(0x28b)]),this[_0x41df42(0x36e)];}['_closed'](){const _0x5070ad=_0x313f4e,_0x1b23ee=this[_0x5070ad(0x28b)]?.[_0x5070ad(0x469)];return _0x1b23ee===_0x5070ad(0xbf)||_0x1b23ee===_0x5070ad(0x679);}[_0x313f4e(0x4aa)](){const _0x2aed7f=_0x313f4e;if(this['_closed']())throw new Error(_0x2aed7f(0x674));}['_key'](_0x596883){const _0x5a6db8=_0x313f4e;return this[_0x5a6db8(0x758)]+':'+_0x596883;}[_0x313f4e(0x495)](_0x2f530a){const _0x818078=_0x313f4e;try{if(this['_closed']())return;_0x4db44a?this[_0x818078(0x1d9)]()[_0x818078(0x4dd)](this[_0x818078(0xd4)](_0x2f530a),Date[_0x818078(0x6f1)]()):this[_0x818078(0x1d9)]()['put'](this[_0x818078(0xd4)](_0x2f530a),Date['now']())?.[_0x818078(0x31d)]?.(()=>{});}catch{}}[_0x313f4e(0x6d5)](_0x520dcc,_0x3bf225=0x3e8){const _0x1ff3b6=_0x313f4e;try{const _0x382666=this['_wantDb']()[_0x1ff3b6(0x741)](this[_0x1ff3b6(0xd4)](_0x520dcc));return typeof _0x382666===_0x1ff3b6(0x3f5)&&Date[_0x1ff3b6(0x6f1)]()-_0x382666<_0x3bf225;}catch{return![];}}['_isStale'](_0x57868b){const _0x19f227=_0x313f4e,_0x404d28=_0x57868b[_0x19f227(0x4fc)]??_0x57868b['acquiredAt'];return _0x404d28+_0x57868b[_0x19f227(0x151)]<Date[_0x19f227(0x6f1)]();}static['_holderDead'](_0xac0f0){const _0x170685=_0x313f4e,_0x32954e=_0xac0f0?.['holder'];if(!_0x32954e||typeof _0x32954e['pid']!==_0x170685(0x3f5))return![];if(_0x32954e[_0x170685(0xa0)]!==_0x43aa22[_0x170685(0xa0)]())return![];if(_0x32954e[_0x170685(0x401)]===process[_0x170685(0x401)])return![];try{return process[_0x170685(0x2e2)](_0x32954e['pid'],0x0),![];}catch(_0x3a40cc){return _0x3a40cc['code']==='ESRCH';}}async[_0x313f4e(0x5e0)](_0x428352,_0x383e5c={},_0x168379={}){const _0x3dbf73=_0x313f4e,_0x32be92=this[_0x3dbf73(0xd4)](_0x428352),_0x2df6ba=_0x168379[_0x3dbf73(0x151)]??this[_0x3dbf73(0x151)],_0x45dd10=Date[_0x3dbf73(0x6f1)](),_0x176d70={'holder':{'pid':process[_0x3dbf73(0x401)],'hostname':_0x43aa22[_0x3dbf73(0xa0)](),..._0x383e5c},'acquiredAt':_0x45dd10,'updatedAt':_0x45dd10,'ttlMs':_0x2df6ba};let _0x5a504f=![],_0x4f184d=null;if(this[_0x3dbf73(0x75b)]())return{'acquired':![],'handle':null,'current':null};try{const _0x5a6e4f=()=>{const _0x1dd49a=_0x3dbf73,_0x9e94f2=this[_0x1dd49a(0x1e4)]()['get'](_0x32be92);if(_0x9e94f2&&!this['_isStale'](_0x9e94f2)&&!_0x30a56e['_holderDead'](_0x9e94f2)){const _0x1f732d=_0x383e5c['processorId']!=null&&_0x9e94f2[_0x1dd49a(0x746)]['pid']===process[_0x1dd49a(0x401)]&&_0x9e94f2[_0x1dd49a(0x746)]['processorId']===_0x383e5c['processorId'];if(!_0x1f732d){_0x5a504f=![],_0x4f184d=_0x9e94f2;return;}_0x176d70['acquiredAt']<=_0x9e94f2[_0x1dd49a(0x5b0)]&&(_0x176d70[_0x1dd49a(0x5b0)]=_0x9e94f2[_0x1dd49a(0x5b0)]+0x1,_0x176d70[_0x1dd49a(0x4fc)]=_0x176d70[_0x1dd49a(0x5b0)]);}this['_db']()[_0x1dd49a(0x22b)](_0x32be92,_0x176d70),_0x5a504f=!![],_0x4f184d=_0x176d70;};if(_0x4db44a)this[_0x3dbf73(0x1e4)]()[_0x3dbf73(0x3b2)](_0x5a6e4f);else await this[_0x3dbf73(0x1e4)]()[_0x3dbf73(0x540)](_0x5a6e4f);}catch{return{'acquired':![],'handle':null,'current':null};}if(!_0x5a504f)return{'acquired':![],'handle':null,'current':_0x4f184d};const _0x4ade12=new _0x4eb5f4(this,_0x32be92,_0x176d70[_0x3dbf73(0x5b0)]);return _0x4ade12[_0x3dbf73(0x695)](_0x2df6ba,this[_0x3dbf73(0x4b1)]),{'acquired':!![],'handle':_0x4ade12,'current':_0x4f184d};}[_0x313f4e(0x61e)](_0x148cd6){const _0xd951f0=_0x313f4e;try{return this['_db']()[_0xd951f0(0x741)](this[_0xd951f0(0xd4)](_0x148cd6))??null;}catch{return null;}}[_0x313f4e(0x36f)](){const _0x326923=_0x313f4e,_0x32a04e=this[_0x326923(0x758)]+':',_0x195837=[];try{for(const {key:_0x528d91,value:_0x164b85}of this[_0x326923(0x1e4)]()[_0x326923(0x4f6)]({'start':_0x32a04e,'end':_0x32a04e+'\xff'})){typeof _0x528d91===_0x326923(0x139)&&_0x528d91[_0x326923(0x557)](_0x32a04e)&&_0x195837['push']({'id':_0x528d91[_0x326923(0x762)](_0x32a04e[_0x326923(0x2e8)]),'entry':_0x164b85});}}catch{}return _0x195837;}static[_0x313f4e(0xf7)](_0x4cec0b){const _0x4db56f=_0x313f4e,_0x324667=[];try{const _0x25d2bd=_0x4cec0b[_0x4db56f(0x367)](_0x1c2483,{'dupSort':![]});for(const {key:_0x39eb2c,value:_0x17126e}of _0x25d2bd[_0x4db56f(0x4f6)]({})){if(typeof _0x39eb2c!==_0x4db56f(0x139))continue;const _0x170776=_0x39eb2c['indexOf'](':');if(_0x170776<0x1)continue;_0x324667['push']({'namespace':_0x39eb2c['slice'](0x0,_0x170776),'id':_0x39eb2c[_0x4db56f(0x762)](_0x170776+0x1),'entry':_0x17126e});}}catch{}return _0x324667;}}return okdbLock={'OKDBLock':_0x30a56e},okdbLock;}var okdbProcessRegistry,hasRequiredOkdbProcessRegistry;function requireOkdbProcessRegistry(){const _0x34914d=_0x1cb9ed;if(hasRequiredOkdbProcessRegistry)return okdbProcessRegistry;hasRequiredOkdbProcessRegistry=0x1;const _0x4c92d4=require$$0,_0x34c005=require$$1$1,_0x51cbc6=require$$2$1,{LOOP:_0x335d48}=requireOkdbLoopMonitor(),{OKDBLock:_0x301c84}=requireOkdbLock(),{SYNC_COMMITS:_0x3ecdad}=requireOkdbWriter(),_0x5562f0=_0x34914d(0x40e),_0x2be9a8=_0x34914d(0x3fc),_0x500bb4=_0x34914d(0x56b),_0x152a9b=_0x34914d(0x677),_0x4ac719=(_0x58a062,_0x185c31)=>_0x58a062+':'+_0x185c31,_0x1b4066=(_0x43a1ca,_0x1b7f7a)=>_0x43a1ca+'::'+_0x1b7f7a,_0x5c5966=(_0x1f8f0c,_0x35b90b)=>_0x1f8f0c+'/'+_0x35b90b,_0xc21b77=(_0x5029ab,_0x434a38)=>_0x5029ab+'#'+_0x434a38,_0x4e7919=_0x19e8ae=>{const _0x4fef32=_0x34914d;if(_0x19e8ae?.['processKey'])return _0x19e8ae[_0x4fef32(0x65e)];const _0x3d77e5=_0x19e8ae?.[_0x4fef32(0x780)];return typeof _0x3d77e5===_0x4fef32(0x139)&&_0x3d77e5['includes']('#')?_0x3d77e5[_0x4fef32(0x762)](0x0,_0x3d77e5[_0x4fef32(0x6b0)]('#')):_0x3d77e5;},_0x4c635a=Number(process.env.OKDB_WORKERS_HEARTBEAT_MS)||0x2710,_0x4c5b8a=Number(process.env.OKDB_WORKERS_PUBLISH_MS)||0x3e8,_0x40748b=_0x4c635a*0x3,_0x27927d=Number(process.env.OKDB_PID_REUSE_HORIZON_MS)||Math[_0x34914d(0x608)](0x927c0,_0x40748b*0x14),_0x10ce4c=[_0x34914d(0x662),_0x34914d(0x6e6),_0x34914d(0x6d7),_0x34914d(0x5e6),_0x34914d(0x2bf),_0x34914d(0x186)];let _0xfe4220=null;function _0x244f33(){const _0x18501b=_0x34914d;if(_0xfe4220==null)_0xfe4220=Math[_0x18501b(0x38d)]((Date['now']()-process['uptime']()*0x3e8)/0x3e8)*0x3e8;return _0xfe4220;}function _0x4c7a34(_0x524b6f){const _0x16c4e6=_0x34914d;if(process.env.OKDB_PROCESS_KILL==='off')return![];if(_0x524b6f?.[_0x16c4e6(0x5ba)]?.[_0x16c4e6(0x5d0)]&&typeof _0x524b6f[_0x16c4e6(0x5ba)][_0x16c4e6(0x5d0)]===_0x16c4e6(0x25a)&&_0x524b6f['options']['processes'][_0x16c4e6(0x2e2)]===![])return![];return!![];}function _0x270dd0(_0x340409,_0x1fe796){const _0x3dfa6b=_0x34914d,_0x101809=!!_0x1fe796?.[_0x3dfa6b(0x3c6)];switch(_0x340409){case _0x3dfa6b(0x430):return{'controllable':_0x101809,'decommissionable':![],'killable':!![],'killConfirm':_0x3dfa6b(0x4b4)};case _0x3dfa6b(0x5c4):case _0x3dfa6b(0x170):return{'controllable':_0x101809,'decommissionable':![],'killable':!![],'killConfirm':_0x3dfa6b(0x647)};case _0x3dfa6b(0x7a1):return{'controllable':![],'decommissionable':![],'killable':![]};case _0x3dfa6b(0x701):case _0x3dfa6b(0x15d):case'fn-runner':case _0x3dfa6b(0x5d7):return{'controllable':![],'decommissionable':!![],'killable':!![],'killConfirm':_0x3dfa6b(0x475)};default:return{'controllable':![],'decommissionable':![],'killable':![]};}}class _0x2938df{constructor(_0x1e2bc7){const _0x203917=_0x34914d;this[_0x203917(0x1ea)]=_0x1e2bc7,this[_0x203917(0x5d5)]=null,this[_0x203917(0xf0)]=null,this[_0x203917(0x487)]=new Map(),this[_0x203917(0x3fe)]=null,this[_0x203917(0x4fd)]=![],this[_0x203917(0x669)]=![],this[_0x203917(0x113)]=_0x244f33(),this[_0x203917(0x323)]=_0x4ac719(process[_0x203917(0x401)],this[_0x203917(0x113)]),this[_0x203917(0x301)]=_0x51cbc6[_0x203917(0x6bf)]()[_0x203917(0x762)](0x0,0x8),this['_rowKey']=_0xc21b77(this[_0x203917(0x323)],this['_instanceId']),this[_0x203917(0x9e)]=Date[_0x203917(0x6f1)](),this[_0x203917(0x587)]=null,this[_0x203917(0x67f)]=null,this[_0x203917(0xe7)]=null,this[_0x203917(0x698)]=null,this[_0x203917(0x1ed)]=null,this[_0x203917(0x78f)]=null,this[_0x203917(0x4b6)]=0x0,this[_0x203917(0x58b)]={},this['_children']=new Map(),this[_0x203917(0x788)]=process['cpuUsage'](),this['_lastCpuAt']=Date[_0x203917(0x6f1)](),this[_0x203917(0x48a)]=0x0,this['_threadStats']=new Map();}get['selfKey'](){return this['_selfKey'];}get[_0x34914d(0x37f)](){const _0x253dae=_0x34914d;return this[_0x253dae(0x197)];}['_caps'](_0x246a65,_0x385ebd){const _0xb99371=_0x34914d,_0x23c0ba=_0x270dd0(_0x246a65,_0x385ebd);if(_0x23c0ba[_0xb99371(0x6da)]&&!_0x4c7a34(this[_0xb99371(0x1ea)]))return{..._0x23c0ba,'killable':![],'killConfirm':undefined};return _0x23c0ba;}[_0x34914d(0x2a5)](){const _0x374b42=_0x34914d;return!!this[_0x374b42(0x5d5)];}[_0x34914d(0x735)](_0x1822a6){const _0x54da06=_0x34914d;Object[_0x54da06(0x315)](this[_0x54da06(0x58b)],_0x1822a6||{});}[_0x34914d(0x75d)](_0x4d3d5f){const _0x580ced=_0x34914d;if(_0x4d3d5f)this[_0x580ced(0xe7)]=_0x4d3d5f;}[_0x34914d(0x4ec)](_0x16ce9d={}){const _0x1dc64b=_0x34914d;return this[_0x1dc64b(0x1ea)]['_activateProcesses'](_0x16ce9d);}[_0x34914d(0x6d6)](){const _0x242031=_0x34914d,_0x576222={};let _0x1ceacd=0x0,_0x321b5c=0x0;const _0x547e74=new Set();for(const _0x4edf77 of this['listNodes']()){_0x321b5c++;const _0x1fe5d4=_0x4edf77[_0x242031(0x34c)];if(!_0x1fe5d4)continue;if(_0x1fe5d4[_0x242031(0x53e)])_0x1ceacd++;for(const _0x438633 of _0x1fe5d4[_0x242031(0x3c6)]||[]){if(![_0x242031(0x476),'fanout'][_0x242031(0x243)](_0x438633[_0x242031(0x1d0)]))continue;(_0x438633[_0x242031(0x2a9)]===_0x242031(0x70a)||_0x438633['state']===_0x242031(0x3f9))&&_0x438633[_0x242031(0x17c)]&&_0x547e74['add']((_0x438633[_0x242031(0x514)]||_0x242031(0x666))+':'+_0x438633['cursorKey']);const _0x363915=_0x438633[_0x242031(0x514)]||'default';(_0x576222[_0x363915]||=[])[_0x242031(0x1c2)]({..._0x438633,'env':_0x363915,'owner':{'pid':_0x4edf77['pid']??null,'kind':_0x4edf77[_0x242031(0x3e2)]??null}});}}for(const [_0xcd4ec5,_0x13ae57]of Object[_0x242031(0x377)](_0x576222)){for(const _0x4278f5 of _0x13ae57){if(_0x4278f5[_0x242031(0x1d0)]===_0x242031(0x476)&&!_0x4278f5[_0x242031(0x725)]){const _0x6fa2=_0xcd4ec5+':'+(_0x4278f5[_0x242031(0x17c)]??'');if(!_0x547e74[_0x242031(0x783)](_0x6fa2))_0x4278f5[_0x242031(0x585)]=!![];}}}return{'envs':_0x576222,'policy':null,'participation':{'participating':_0x1ceacd,'total':_0x321b5c},'source':_0x242031(0x571)};}[_0x34914d(0x5ac)](){const _0x314b38=_0x34914d,_0x2d0e97=_0x294960=>{const _0x306149=_0x4ed4;if(_0x294960['state']===_0x306149(0x70a)||_0x294960['state']===_0x306149(0x3f9)||_0x294960[_0x306149(0x2a9)]===_0x306149(0x1da))return 0x3;if(_0x294960[_0x306149(0x725)])return 0x1;return 0x2;},_0x575dd3=new Map();for(const _0x16000f of this['listNodes']()){for(const _0x4ccee9 of _0x16000f[_0x314b38(0x34c)]?.['processors']||[]){const _0x290b83={..._0x4ccee9,'owner':{'pid':_0x16000f[_0x314b38(0x401)]??null,'kind':_0x16000f[_0x314b38(0x3e2)]??null,'host':_0x16000f[_0x314b38(0x2a4)]??null}},_0xc92623=_0x4ccee9[_0x314b38(0x1d0)]===_0x314b38(0x476)?_0x314b38(0x6ac)+(_0x4ccee9[_0x314b38(0x514)]??'')+'::'+(_0x4ccee9['cursorKey']??_0x4ccee9['type']??_0x4ccee9['id']):'inst:'+(_0x16000f['nodeKey']??_0x16000f[_0x314b38(0x65e)]??'')+'::'+(_0x4ccee9[_0x314b38(0x514)]??'')+'::'+_0x4ccee9['id'],_0x5bec40=_0x575dd3[_0x314b38(0x741)](_0xc92623);if(!_0x5bec40||_0x2d0e97(_0x290b83)>_0x2d0e97(_0x5bec40))_0x575dd3['set'](_0xc92623,_0x290b83);}}return[..._0x575dd3[_0x314b38(0x260)]()];}[_0x34914d(0x25c)](){const _0x4d08dd=_0x34914d,_0x56067d=Date[_0x4d08dd(0x6f1)](),_0x1e223d=this[_0x4d08dd(0x3d5)](),_0x3336ec=_0x24dc41=>Math['max'](0x0,Math[_0x4d08dd(0x38d)]((_0x56067d-(_0x24dc41['startedAt']||_0x56067d))/0x3e8)),_0xf4f0b7=_0x1e223d['find'](_0x1b1b28=>_0x1b1b28['kind']===_0x4d08dd(0x430)),_0x3c5376=_0x1e223d[_0x4d08dd(0x20f)](_0x2652b3=>_0x2652b3['kind']==='http-server');if(_0xf4f0b7||_0x3c5376[_0x4d08dd(0x2e8)])return{'primary':_0xf4f0b7?{'pid':_0xf4f0b7[_0x4d08dd(0x401)],'uptime':_0x3336ec(_0xf4f0b7)}:null,'workers':_0x3c5376['map'](_0xc08df1=>({'pid':_0xc08df1['pid'],'uptime':_0x3336ec(_0xc08df1)})),'workersConfigured':_0xf4f0b7?.[_0x4d08dd(0x57f)]?.[_0x4d08dd(0x51f)]??_0x3c5376['length'],'mode':_0x4d08dd(0x14a)};const _0x1af9ec=_0x1e223d[_0x4d08dd(0xe5)](_0x5f5095=>_0x5f5095[_0x4d08dd(0x3e2)]===_0x4d08dd(0x5c4)||_0x5f5095[_0x4d08dd(0x3e2)]===_0x4d08dd(0x170)||_0x5f5095['kind']===_0x4d08dd(0x7a1)),_0x4d7ef2=_0x1af9ec?{'pid':_0x1af9ec['pid'],'uptime':_0x3336ec(_0x1af9ec)}:{'pid':process[_0x4d08dd(0x401)],'uptime':Math[_0x4d08dd(0x608)](0x0,Math['round'](process['uptime']()))};return{'primary':_0x4d7ef2,'workers':[_0x4d7ef2],'workersConfigured':0x1,'mode':_0x4d08dd(0x476)};}[_0x34914d(0x23c)](){const _0x311ea6=_0x34914d;return this[_0x311ea6(0x100)]();}[_0x34914d(0x634)](){const _0x553816=_0x34914d,_0x31c096=new Map();for(const _0x5eaecd of this[_0x553816(0x100)]())_0x31c096[_0x553816(0x543)](_0x5eaecd[_0x553816(0x65e)],{..._0x5eaecd,'children':[]});const _0x557c73=[];for(const _0x115d68 of _0x31c096[_0x553816(0x260)]()){const _0x52d5e4=_0x115d68[_0x553816(0x3f0)]?_0x31c096[_0x553816(0x741)](_0x115d68[_0x553816(0x3f0)]):null;if(_0x52d5e4&&_0x52d5e4!==_0x115d68)_0x52d5e4[_0x553816(0x450)]['push'](_0x115d68);else _0x557c73[_0x553816(0x1c2)](_0x115d68);}const _0xb8cd3b=(_0x539b78,_0xc4381f)=>_0x539b78[_0x553816(0x3e2)]===_0xc4381f['kind']?(_0x539b78['pid']||0x0)-(_0xc4381f['pid']||0x0):(_0x539b78[_0x553816(0x3e2)]??'')<(_0xc4381f[_0x553816(0x3e2)]??'')?-0x1:0x1,_0x1dc2a3=_0x5cea7d=>{const _0x350504=_0x553816;_0x5cea7d[_0x350504(0x108)](_0xb8cd3b);for(const _0x265f0d of _0x5cea7d)if(_0x265f0d['children'][_0x350504(0x2e8)])_0x1dc2a3(_0x265f0d['children']);};return _0x1dc2a3(_0x557c73),_0x557c73;}[_0x34914d(0x4bc)](_0x370f8a){const _0x20a2f0=_0x34914d;return this['_groupByProcess']()[_0x20a2f0(0xe5)](_0x2f44a5=>_0x2f44a5[_0x20a2f0(0x65e)]===_0x370f8a)??null;}[_0x34914d(0x100)](_0x301c07=Date[_0x34914d(0x6f1)]()){const _0x47a303=_0x34914d,_0xbcb4f3=new Map();for(const _0x32d92d of this[_0x47a303(0x3d5)]()){const _0x1f2719=_0x4e7919(_0x32d92d);let _0x276945=_0xbcb4f3[_0x47a303(0x741)](_0x1f2719);!_0x276945&&(_0x276945={'processKey':_0x1f2719,'nodeKey':_0x1f2719,'pid':_0x32d92d[_0x47a303(0x401)],'ppid':_0x32d92d[_0x47a303(0x14f)]??null,'host':_0x32d92d['host']??null,'kind':_0x32d92d['kind'],'role':null,'supervisorKey':_0x32d92d[_0x47a303(0x3f0)]??null,'slot':_0x32d92d[_0x47a303(0x4b7)]??null,'slotKey':_0x32d92d[_0x47a303(0x6d2)]??null,'caps':_0x32d92d[_0x47a303(0x2fc)]??null,'lifecycle':_0x32d92d['lifecycle']??null,'uptime':Math['max'](0x0,Math[_0x47a303(0x38d)]((_0x301c07-(_0x32d92d[_0x47a303(0x618)]||_0x301c07))/0x3e8)),'startedAt':_0x32d92d[_0x47a303(0x618)]??null,'meta':_0x32d92d[_0x47a303(0x57f)]??null,'listenAddr':null,'processing':null,'engines':null,'singletonClaims':null,'stats':null,'instances':[]},_0xbcb4f3[_0x47a303(0x543)](_0x1f2719,_0x276945));_0x276945[_0x47a303(0x20e)]['push']({'instanceId':_0x32d92d['instanceId']??null,'role':_0x32d92d[_0x47a303(0x553)]??null,'listenAddr':_0x32d92d[_0x47a303(0x54e)]??null,'lifecycle':_0x32d92d[_0x47a303(0x742)]??null,'processing':_0x32d92d[_0x47a303(0x34c)]??null});if(!_0x276945['role']&&_0x32d92d[_0x47a303(0x553)])_0x276945['role']=_0x32d92d[_0x47a303(0x553)];if(!_0x276945[_0x47a303(0x54e)]&&_0x32d92d['listenAddr'])_0x276945[_0x47a303(0x54e)]=_0x32d92d[_0x47a303(0x54e)];if(!_0x276945[_0x47a303(0x34c)]&&_0x32d92d['processing'])_0x276945['processing']=_0x32d92d[_0x47a303(0x34c)];if(!_0x276945[_0x47a303(0x1d6)]&&_0x32d92d[_0x47a303(0x1d6)])_0x276945[_0x47a303(0x1d6)]=_0x32d92d[_0x47a303(0x1d6)];if(!_0x276945['singletonClaims']&&_0x32d92d[_0x47a303(0x556)])_0x276945['singletonClaims']=_0x32d92d[_0x47a303(0x556)];if(_0x276945[_0x47a303(0x2fc)]==null&&_0x32d92d['caps'])_0x276945[_0x47a303(0x2fc)]=_0x32d92d[_0x47a303(0x2fc)];if(_0x32d92d[_0x47a303(0x665)]&&(!_0x276945[_0x47a303(0x665)]||(_0x32d92d['stats']['at']??0x0)>(_0x276945[_0x47a303(0x665)]['at']??0x0)))_0x276945[_0x47a303(0x665)]=_0x32d92d['stats'];}return[..._0xbcb4f3['values']()];}[_0x34914d(0x105)](){const _0x106edb=_0x34914d,_0x3e3f9c=[],_0x23a2c3={'rss':0x0,'heapUsed':0x0,'processes':0x0,'threads':{'count':0x0,'sandbox':0x0,'busy':0x0}};for(const _0xd9a7f5 of this[_0x106edb(0x100)]()){_0x3e3f9c['push']({'processKey':_0xd9a7f5[_0x106edb(0x65e)],'kind':_0xd9a7f5[_0x106edb(0x3e2)],'pid':_0xd9a7f5[_0x106edb(0x401)],'supervisorKey':_0xd9a7f5[_0x106edb(0x3f0)],'meta':_0xd9a7f5[_0x106edb(0x57f)]??null,'uptime':_0xd9a7f5[_0x106edb(0x5fc)],'stats':_0xd9a7f5[_0x106edb(0x665)]??null}),_0x23a2c3[_0x106edb(0x5d0)]++;if(_0xd9a7f5[_0x106edb(0x665)]){_0x23a2c3['rss']+=_0xd9a7f5[_0x106edb(0x665)][_0x106edb(0x131)]||0x0,_0x23a2c3[_0x106edb(0x6ae)]+=(_0xd9a7f5[_0x106edb(0x665)][_0x106edb(0x6ae)]||0x0)+(_0xd9a7f5['stats'][_0x106edb(0x30a)]?.[_0x106edb(0x6ae)]||0x0);const _0x20f73b=_0xd9a7f5[_0x106edb(0x665)][_0x106edb(0x30a)];_0x20f73b&&(_0x23a2c3[_0x106edb(0x30a)][_0x106edb(0x6b4)]+=_0x20f73b['count']||0x0,_0x23a2c3[_0x106edb(0x30a)][_0x106edb(0x5af)]+=_0x20f73b['sandbox']||0x0,_0x23a2c3[_0x106edb(0x30a)][_0x106edb(0x35c)]+=_0x20f73b[_0x106edb(0x35c)]||0x0);}}return{'totals':_0x23a2c3,'nodes':_0x3e3f9c};}async[_0x34914d(0x58f)]({writer:writer=![],reader:reader=![],kind:kind=null,supervisorKey:supervisorKey=null,listenAddr:listenAddr=null}={}){const _0x322001=_0x34914d;this[_0x322001(0x4fd)]=this['_isWriter']||!!writer,this[_0x322001(0x669)]=this[_0x322001(0x669)]||!!reader,this[_0x322001(0x587)]=kind||this[_0x322001(0x587)]||(_0x34c005[_0x322001(0x46e)]?_0x322001(0x701):_0x322001(0x5c4)),this[_0x322001(0x67f)]=supervisorKey??this[_0x322001(0x67f)],this['_listenAddr']=listenAddr??this[_0x322001(0xe7)],this[_0x322001(0x1c3)](),await this[_0x322001(0x22a)]();if(!writer&&!reader)return null;if(!this['_statusEnv']){const _0x6f968e=await this['okdb'][_0x322001(0x112)](_0x5562f0,{'sync':![],'durability':_0x322001(0x4f5)});await _0x6f968e[_0x322001(0x49b)](_0x2be9a8),this[_0x322001(0x5d5)]=_0x6f968e;}return this[_0x322001(0x5d5)];}['_nodeDb'](){const _0x4d2c3f=_0x34914d;return this[_0x4d2c3f(0x49c)]!==this['_statusEnv']&&(this[_0x4d2c3f(0x49c)]=this[_0x4d2c3f(0x5d5)],this[_0x4d2c3f(0x156)]=this[_0x4d2c3f(0x5d5)][_0x4d2c3f(0x670)](_0x2be9a8)[_0x4d2c3f(0x516)]),this[_0x4d2c3f(0x156)];}[_0x34914d(0x2b8)](_0x496fa5){const _0x29f833=_0x34914d;if(_0x3ecdad)return this[_0x29f833(0x2aa)]()[_0x29f833(0x4dd)](_0x496fa5[_0x29f833(0x780)],_0x496fa5,0x1);const _0x30b5e0=this['_nodeDb']()[_0x29f833(0x22b)](_0x496fa5[_0x29f833(0x780)],_0x496fa5,0x1);if(_0x30b5e0&&typeof _0x30b5e0[_0x29f833(0x257)]===_0x29f833(0x18e))_0x30b5e0[_0x29f833(0x257)](undefined,()=>{});return _0x30b5e0;}[_0x34914d(0x29f)](_0x189c75){const _0x441ca6=_0x34914d;return this['_nodeDb']()[_0x441ca6(0x4dd)](_0x189c75[_0x441ca6(0x780)],_0x189c75,0x1);}['_removeRowAsync'](_0x4a0401){const _0x43d75a=_0x34914d;if(_0x3ecdad)try{return this['_nodeDb']()['removeSync'](_0x4a0401);}catch{return![];}const _0x436b1d=this['_nodeDb']()['remove'](_0x4a0401);if(_0x436b1d&&typeof _0x436b1d[_0x43d75a(0x257)]===_0x43d75a(0x18e))_0x436b1d[_0x43d75a(0x257)](undefined,()=>{});return _0x436b1d;}async['putNode'](_0x4a8a42){const _0x4d4984=_0x34914d;if(!this[_0x4d4984(0x5d5)]||!this['_isWriter']||!_0x4a8a42?.[_0x4d4984(0x780)])return;return this[_0x4d4984(0x2b8)](_0x4a8a42);}async[_0x34914d(0x5ea)](_0x547ade){const _0x32db80=_0x34914d;if(!this['_statusEnv']||!this[_0x32db80(0x4fd)]||!_0x547ade)return;const _0x36d433=_0x547ade['includes']('#'),_0xc266e4=[];for(const {key:_0x259024}of this[_0x32db80(0x5d5)][_0x32db80(0x4f6)](_0x2be9a8)){if(_0x259024===_0x547ade||!_0x36d433&&typeof _0x259024==='string'&&_0x259024['startsWith'](_0x547ade+'#'))_0xc266e4[_0x32db80(0x1c2)](_0x259024);}for(const _0x1c157 of _0xc266e4){try{this['_nodeDb']()[_0x32db80(0x5b1)](_0x1c157);}catch{}}}[_0x34914d(0x591)](_0x19ba69){const _0x47ffdc=_0x34914d;if(typeof _0x19ba69?.[_0x47ffdc(0x401)]!=='number')return![];if(_0x19ba69[_0x47ffdc(0x2a4)]!==_0x4c92d4[_0x47ffdc(0xa0)]())return![];if(_0x19ba69[_0x47ffdc(0x401)]===process['pid'])return![];if(_0x19ba69[_0x47ffdc(0x738)]!=null&&_0x19ba69['expiresAt']<Date[_0x47ffdc(0x6f1)]()-_0x27927d)return!![];try{return process['kill'](_0x19ba69[_0x47ffdc(0x401)],0x0),![];}catch(_0x1b9311){return _0x1b9311[_0x47ffdc(0x72d)]===_0x47ffdc(0x563);}}[_0x34914d(0x3d5)](){const _0x31cd57=_0x34914d;if(!this[_0x31cd57(0x5d5)])return[];try{this[_0x31cd57(0x5d5)]['db']?.[_0x31cd57(0x345)]?.();}catch{}const _0x556bfc=Date[_0x31cd57(0x6f1)](),_0x124180=_0x4c92d4['hostname'](),_0x36ac6b=[];for(const {value:_0x288264}of this[_0x31cd57(0x5d5)][_0x31cd57(0x4f6)](_0x2be9a8)){if(!_0x288264)continue;let _0x4c8610=null;_0x288264[_0x31cd57(0x2a4)]===_0x124180&&typeof _0x288264[_0x31cd57(0x401)]==='number'&&(_0x4c8610=!this['_nodeDead'](_0x288264));if(_0x4c8610===![])continue;const _0x35d714=_0x288264[_0x31cd57(0x738)]==null||_0x288264[_0x31cd57(0x738)]>=_0x556bfc;if(_0x4c8610===!![]||_0x35d714)_0x36ac6b['push'](_0x288264);}return _0x36ac6b;}async[_0x34914d(0xae)](_0x42caa0=0x0){const _0x25486c=_0x34914d;if(!this['_statusEnv']||!this[_0x25486c(0x4fd)])return;const _0x51d3d0=Date[_0x25486c(0x6f1)]()-_0x42caa0,_0x38f91e=new Set(),_0xe78f33=[],_0x4e8dcd=_0x4c92d4['hostname'](),_0x2ad405=require$$3[_0x25486c(0x512)];for(const {key:_0x8476e4,value:_0x3a15d2}of this['_statusEnv'][_0x25486c(0x4f6)](_0x2be9a8)){if(!_0x3a15d2)continue;const _0x298ff6=_0x3a15d2[_0x25486c(0x2a4)]===_0x4e8dcd&&typeof _0x3a15d2['pid']===_0x25486c(0x3f5),_0x2e988e=_0x298ff6?this['_nodeDead'](_0x3a15d2):_0x3a15d2[_0x25486c(0x738)]!=null&&_0x3a15d2[_0x25486c(0x738)]<_0x51d3d0;if(_0x2e988e)_0xe78f33[_0x25486c(0x1c2)](_0x8476e4);else{_0x38f91e[_0x25486c(0x5f3)](_0x4e7919(_0x3a15d2)??_0x8476e4);if(_0x3a15d2['version']&&_0x3a15d2[_0x25486c(0x512)]!==_0x2ad405){if(!this[_0x25486c(0x10e)])this[_0x25486c(0x10e)]=new Set();!this[_0x25486c(0x10e)][_0x25486c(0x783)](_0x3a15d2[_0x25486c(0x512)])&&(this[_0x25486c(0x10e)]['add'](_0x3a15d2[_0x25486c(0x512)]),this[_0x25486c(0x1ea)][_0x25486c(0x219)]?.[_0x25486c(0x27b)]?.(_0x25486c(0x1f1)+(_0x3a15d2[_0x25486c(0x401)]??'?')+_0x25486c(0x226)+_0x3a15d2[_0x25486c(0x512)]+'\x20while\x20this\x20process\x20runs\x20'+_0x2ad405+_0x25486c(0x4e1)+_0x25486c(0x176),{'feature':_0x25486c(0x306)}));}}}for(const _0x5bba6c of _0xe78f33)this[_0x25486c(0x5e3)](_0x5bba6c);if(this[_0x25486c(0x1c3)]()){const _0x99891c=[];for(const {key:_0x27974c}of this[_0x25486c(0x6c4)](_0x25486c(0x3fc))){if(!_0x38f91e[_0x25486c(0x783)](_0x27974c)){if(_0x3ecdad)try{this[_0x25486c(0xf0)][_0x25486c(0x5b1)]('node/'+_0x27974c);}catch{}else _0x99891c[_0x25486c(0x1c2)](this['_desired'][_0x25486c(0x5ce)](_0x25486c(0x41a)+_0x27974c));}}if(_0x99891c[_0x25486c(0x2e8)])await Promise[_0x25486c(0x305)](_0x99891c);}}[_0x34914d(0x706)](_0x4e6b6e=null){const _0x31d369=_0x34914d;if(this[_0x31d369(0x698)])return;if(!this[_0x31d369(0x4fd)]||!this[_0x31d369(0x5d5)]){this[_0x31d369(0x1ea)]?.[_0x31d369(0x219)]?.[_0x31d369(0x27b)]?.(_0x31d369(0x3aa)+this[_0x31d369(0x4fd)]+_0x31d369(0x6e1)+!!this[_0x31d369(0x5d5)]+_0x31d369(0x3a3),{'feature':_0x31d369(0x5d0)});return;}this[_0x31d369(0x78f)]=_0x4e6b6e,this['_onProcEvent']=()=>this[_0x31d369(0x332)]();for(const _0x2b3c45 of _0x10ce4c)this[_0x31d369(0x1ea)][_0x31d369(0x599)]['on'](_0x2b3c45,this[_0x31d369(0x1ed)]);this[_0x31d369(0x32b)]();const _0x34a25f=Number(process.env.OKDB_WORKERS_HEARTBEAT_MS)||_0x4c635a;this[_0x31d369(0x698)]=setInterval(()=>{const _0x495f78=_0x31d369;if(this[_0x495f78(0x78f)])try{this[_0x495f78(0x78f)]();}catch{}this[_0x495f78(0x32b)](),this['reap']()[_0x495f78(0x31d)](()=>{});},_0x34a25f);if(this[_0x31d369(0x698)][_0x31d369(0x575)])this[_0x31d369(0x698)][_0x31d369(0x575)]();}[_0x34914d(0x332)](){const _0xf93219=_0x34914d;if(!this[_0xf93219(0x4fd)]||!this['_statusEnv'])return;if(Date[_0xf93219(0x6f1)]()-this[_0xf93219(0x4b6)]<_0x4c5b8a)return;this[_0xf93219(0x32b)]();}['_publishNow'](){const _0xb91cf=_0x34914d;if(!this['_isWriter']||!this['_statusEnv'])return;this[_0xb91cf(0x4b6)]=Date[_0xb91cf(0x6f1)]();try{const _0x35b813=[this[_0xb91cf(0x1aa)]()];for(const _0x5c4b04 of this[_0xb91cf(0x2b4)]['values']())_0x35b813[_0xb91cf(0x1c2)](this[_0xb91cf(0x1ff)](_0x5c4b04));const _0x4fec1f=_0x335d48[_0xb91cf(0x283)]?_0x335d48[_0xb91cf(0x6f1)]():0x0;for(const _0x38fb6c of _0x35b813){try{this[_0xb91cf(0x29f)](_0x38fb6c),this['_publishFailWarned']=![];}catch(_0x321535){!this[_0xb91cf(0x2a7)]&&(this[_0xb91cf(0x2a7)]=!![],this[_0xb91cf(0x1ea)]?.['log']?.['warn']?.('registry\x20publish\x20failing:\x20'+_0x321535[_0xb91cf(0x71d)],{'feature':_0xb91cf(0x5d0)}));}}if(_0x335d48['enabled'])_0x335d48['note'](_0xb91cf(0x3d4),_0x335d48[_0xb91cf(0x6f1)]()-_0x4fec1f,_0xb91cf(0x6e0)+_0x35b813[_0xb91cf(0x2e8)]+_0xb91cf(0x60d));}catch(_0x3c4982){!this[_0xb91cf(0x2a7)]&&(this['_publishFailWarned']=!![],this[_0xb91cf(0x1ea)]?.[_0xb91cf(0x219)]?.[_0xb91cf(0x27b)]?.('registry\x20publish\x20failing:\x20'+_0x3c4982[_0xb91cf(0x71d)],{'feature':_0xb91cf(0x5d0)}));}}async[_0x34914d(0x1bf)](){const _0x5c73f3=_0x34914d;if(this[_0x5c73f3(0x1ed)]){for(const _0x5129c7 of _0x10ce4c){try{this[_0x5c73f3(0x1ea)][_0x5c73f3(0x599)]['off'](_0x5129c7,this['_onProcEvent']);}catch{}}this[_0x5c73f3(0x1ed)]=null;}this['_hbTimer']&&(clearInterval(this[_0x5c73f3(0x698)]),this[_0x5c73f3(0x698)]=null);try{if(this[_0x5c73f3(0x5d5)]&&this['_isWriter'])await this[_0x5c73f3(0x5ea)](this[_0x5c73f3(0x197)]);}catch{}}async['deregisterSelf'](){const _0x2d4894=_0x34914d;if(!this[_0x2d4894(0x5d5)]||!this[_0x2d4894(0x4fd)])return;try{await this[_0x2d4894(0x5ea)](this[_0x2d4894(0x197)]);}catch{}try{const _0x2a043a=[];for(const {value:_0x5c1d0c}of this['_statusEnv'][_0x2d4894(0x4f6)](_0x2be9a8)){if(_0x5c1d0c?.[_0x2d4894(0x14f)]===process[_0x2d4894(0x401)]&&_0x5c1d0c[_0x2d4894(0x780)])_0x2a043a[_0x2d4894(0x1c2)](_0x5c1d0c[_0x2d4894(0x780)]);}for(const _0x22a026 of _0x2a043a){try{await this[_0x2d4894(0x5ea)](_0x22a026);}catch{}}}catch{}}async[_0x34914d(0x650)](){const _0x5c8eb4=_0x34914d;return this[_0x5c8eb4(0x336)](this[_0x5c8eb4(0x1aa)]());}async['publishChildRow'](_0x351871){const _0x286b20=_0x34914d;if(!this[_0x286b20(0x5d5)]||!this[_0x286b20(0x4fd)])return;return this['putNode'](this[_0x286b20(0x1ff)](_0x351871));}[_0x34914d(0x1ff)]({pid:_0x284231,startedAt:_0x19eac0,kind:_0x4970b5,supervisorKey:_0x275875,slot:slot=null,slotKey:slotKey=null,role:role={},listenAddr:listenAddr=null,processing:processing=null,lifecycle:lifecycle=_0x34914d(0x1cc),meta:meta=null,stats:stats=null}){const _0x105e32=_0x34914d,_0x4cc6a5=Date['now'](),_0x1820a7=_0x4ac719(_0x284231,_0x19eac0);return{'nodeKey':_0xc21b77(_0x1820a7,'0'),'processKey':_0x1820a7,'instanceId':'0','pid':_0x284231,'startedAt':_0x19eac0,'ppid':process['pid'],'host':_0x4c92d4[_0x105e32(0xa0)](),'supervisorKey':_0x275875,'slot':slot,'slotKey':slotKey,'kind':_0x4970b5,'role':role,'listenAddr':listenAddr,'heartbeatAt':_0x4cc6a5,'expiresAt':_0x4cc6a5+_0x40748b,'caps':this[_0x105e32(0x57c)](_0x4970b5,role),'lifecycle':{'state':lifecycle,'desiredVersionApplied':null},'processing':processing,'meta':meta,'stats':stats};}async[_0x34914d(0xb6)](_0x252547){const _0x31da73=_0x34914d;if(!_0x252547?.[_0x31da73(0x401)])return null;const _0x186b46=_0x4ac719(_0x252547[_0x31da73(0x401)],_0x252547['startedAt']);this['_children'][_0x31da73(0x543)](_0x186b46,{..._0x252547,'supervisorKey':_0x252547[_0x31da73(0x3f0)]??this['_selfKey']});if(this[_0x31da73(0x4fd)])await this[_0x31da73(0x56f)](this[_0x31da73(0x2b4)]['get'](_0x186b46))[_0x31da73(0x31d)]?.(()=>{});return _0x186b46;}[_0x34914d(0x5a1)](_0x1d58f5){const _0x235235=_0x34914d;if(!_0x1d58f5)return;return this[_0x235235(0x2b4)][_0x235235(0x210)](_0x1d58f5),this[_0x235235(0x5ea)](_0x1d58f5);}['_sampleOwnStats'](){const _0x54cb5b=_0x34914d,_0x541886=Date[_0x54cb5b(0x6f1)](),_0x4d163e=process[_0x54cb5b(0x6e8)](),_0x18b93e=(_0x541886-this[_0x54cb5b(0x39e)])*0x3e8;if(_0x18b93e>=0x3d090){const _0x3d029c=_0x4d163e[_0x54cb5b(0xd0)]-this[_0x54cb5b(0x788)]['user']+(_0x4d163e['system']-this['_lastCpuUsage'][_0x54cb5b(0x374)]),_0x33ca9c=_0x4c92d4[_0x54cb5b(0x366)]()[_0x54cb5b(0x2e8)]||0x1;this[_0x54cb5b(0x48a)]=Math[_0x54cb5b(0x437)](0x64,Math[_0x54cb5b(0x38d)](_0x3d029c/(_0x18b93e*_0x33ca9c)*0x64)),this['_lastCpuWindowMs']=Math[_0x54cb5b(0x38d)](_0x18b93e/0x3e8),this[_0x54cb5b(0x788)]=_0x4d163e,this['_lastCpuAt']=_0x541886;}const _0x5cd24e=process[_0x54cb5b(0x294)](),_0x58de69=this['_threadStats'][_0x54cb5b(0x54a)];let _0x390ed9=0x0;if(_0x58de69>0x0){const _0x3241f0=[this['okdb'],...this['okdb'][_0x54cb5b(0x319)]?.['values']?.()??[]];for(const _0x442a4f of _0x3241f0){const _0xbc8e1=_0x442a4f[_0x54cb5b(0x1e8)]?.['_sandbox'];if(_0xbc8e1)_0x390ed9+=_0xbc8e1[_0x54cb5b(0x10b)][_0x54cb5b(0x35c)];}}let _0x1764f6=null;const _0x4a90a9=_0x58de69;if(_0x4a90a9>0x0){let _0xfc62b0=0x0;for(const _0x554399 of this[_0x54cb5b(0x348)]['values']())_0xfc62b0+=_0x554399[_0x54cb5b(0x6ae)]||0x0;_0x1764f6={'count':_0x4a90a9,'heapUsed':_0xfc62b0,'sandbox':_0x58de69,'busy':_0x390ed9};}return{'rss':_0x5cd24e[_0x54cb5b(0x131)],'heapUsed':_0x5cd24e[_0x54cb5b(0x6ae)],'heapTotal':_0x5cd24e[_0x54cb5b(0x3c3)],'external':_0x5cd24e[_0x54cb5b(0x554)],'cpuPct':this[_0x54cb5b(0x48a)],'cpuWindowMs':this['_lastCpuWindowMs']??null,'threads':_0x1764f6,'at':_0x541886};}['reportThreadStats'](_0x6b283a,_0x2dfb9b){const _0x12b083=_0x34914d;if(!_0x6b283a||!_0x2dfb9b)return;this[_0x12b083(0x348)][_0x12b083(0x543)](_0x6b283a,_0x2dfb9b);}[_0x34914d(0x272)](_0x54e2ce){const _0x44f67e=_0x34914d;this[_0x44f67e(0x348)]['delete'](_0x54e2ce);}[_0x34914d(0x6e4)](_0x34fb4e,_0x384b06,_0x4e95d9=undefined){const _0x3d811c=_0x34914d,_0x2c0c04=this['_children'][_0x3d811c(0x741)](_0x34fb4e);if(!_0x2c0c04||!_0x384b06)return;if(_0x4e95d9!==undefined)_0x2c0c04[_0x3d811c(0x34c)]=_0x4e95d9;_0x2c0c04['stats']={'rss':_0x384b06[_0x3d811c(0x131)]??null,'heapUsed':_0x384b06[_0x3d811c(0x6ae)]??null,'heapTotal':_0x384b06['heapTotal']??null,'external':_0x384b06['external']??null,'cpuPct':_0x384b06[_0x3d811c(0x20a)]??null,'cpuWindowMs':_0x384b06[_0x3d811c(0x5a6)]??null,'threads':_0x384b06[_0x3d811c(0x30a)]??null,'claims':_0x384b06[_0x3d811c(0x1e3)]??null,'envsOpen':_0x384b06[_0x3d811c(0x441)]??null,'at':Date['now']()};}['_buildOwnRow'](){const _0x3d8846=_0x34914d,_0x40691f=Date['now'](),_0x2cf096=this[_0x3d8846(0x1ea)][_0x3d8846(0x4e8)]||{},_0x44e132=this[_0x3d8846(0x587)]||_0x3d8846(0x5c4);return{'nodeKey':this[_0x3d8846(0x197)],'processKey':this[_0x3d8846(0x323)],'instanceId':this[_0x3d8846(0x301)],'pid':process[_0x3d8846(0x401)],'startedAt':this['_processStartedAt'],'instanceStartedAt':this[_0x3d8846(0x9e)],'ppid':typeof process[_0x3d8846(0x14f)]===_0x3d8846(0x3f5)?process['ppid']:null,'host':_0x4c92d4['hostname'](),'supervisorKey':this[_0x3d8846(0x67f)]??null,'version':require$$3['version'],'kind':_0x44e132,'role':{'engines':!!_0x2cf096[_0x3d8846(0x1d6)],'processors':!!_0x2cf096[_0x3d8846(0x3c6)],'compaction':_0x2cf096[_0x3d8846(0x11d)],'http':_0x2cf096[_0x3d8846(0x1be)]},'listenAddr':this[_0x3d8846(0xe7)]??null,'heartbeatAt':_0x40691f,'expiresAt':_0x40691f+_0x40748b,'caps':this[_0x3d8846(0x57c)](_0x44e132,_0x2cf096),'lifecycle':{'state':_0x3d8846(0x1cc),'desiredVersionApplied':null},'meta':{...this['_ownMeta']},'processing':_0x2cf096['processors']?this['_buildProcessingFacet']():null,'engines':_0x2cf096[_0x3d8846(0x1d6)]?[...this['okdb'][_0x3d8846(0xed)]??[]]:null,'singletonClaims':this[_0x3d8846(0x2ce)](),'stats':this[_0x3d8846(0x304)](),'writers':this[_0x3d8846(0x356)]()};}[_0x34914d(0x356)](){const _0x43e677=_0x34914d,_0x35abc4={};try{for(const [_0x302093,_0x4f1ca8]of this[_0x43e677(0x1ea)][_0x43e677(0x319)]){try{const _0x449bb4=_0x4f1ca8[_0x43e677(0x65f)]?.();if(!_0x449bb4)continue;if(!_0x449bb4[_0x43e677(0x2c3)]&&!_0x449bb4[_0x43e677(0xdc)]&&!(_0x449bb4[_0x43e677(0x82)]??0x0)&&!_0x449bb4[_0x43e677(0x6db)])continue;_0x35abc4[_0x302093]={'depth':_0x449bb4[_0x43e677(0x2c3)],'oldestPendingMs':_0x449bb4['oldestPendingMs'],'committed':_0x449bb4[_0x43e677(0xdc)],'commitsPerSec':_0x449bb4[_0x43e677(0x63d)],'commitP99Ms':_0x449bb4['commitP99Ms'],'parkedNow':_0x449bb4[_0x43e677(0x82)]??0x0,'draining':!!_0x449bb4[_0x43e677(0x6db)]};}catch{}}}catch{}return Object['keys'](_0x35abc4)[_0x43e677(0x2e8)]?_0x35abc4:null;}[_0x34914d(0x2ce)](){const _0x55ee3c=_0x34914d,_0x2c2380=process['pid'],_0x3d0bb0=Date[_0x55ee3c(0x6f1)](),_0x22f2fa=_0x279119=>{const _0x19f2e9=_0x55ee3c;if(!_0x279119)return[];const _0x53b60c=[];try{for(const {id:_0xed80c5,entry:_0x51c925}of _0x279119[_0x19f2e9(0x36f)]()){if(_0x51c925?.[_0x19f2e9(0x746)]?.[_0x19f2e9(0x401)]!==_0x2c2380)continue;const _0x1a7d11=_0x51c925['updatedAt']??_0x51c925[_0x19f2e9(0x5b0)]??0x0;if(_0x1a7d11+(_0x51c925[_0x19f2e9(0x151)]??0x0)<_0x3d0bb0)continue;_0x53b60c[_0x19f2e9(0x1c2)](_0xed80c5);}}catch{}return _0x53b60c;},_0x3e0c7f=_0x22f2fa(this[_0x55ee3c(0x255)](_0x55ee3c(0xf8))),_0x188b45=_0x22f2fa(this['_singletonLock'](_0x55ee3c(0x15e)));if(!_0x3e0c7f['length']&&!_0x188b45[_0x55ee3c(0x2e8)])return null;return{'compact':_0x3e0c7f,'replicate':_0x188b45};}['_singletonLock'](_0x39ff97){const _0x2d8ee7=_0x34914d;if(!this[_0x2d8ee7(0x1ea)]?.[_0x2d8ee7(0x3da)])return null;if(!this[_0x2d8ee7(0x6bc)])this[_0x2d8ee7(0x6bc)]=new Map();let _0x4b023d=this['_singletonLocks']['get'](_0x39ff97);if(!_0x4b023d)try{_0x4b023d=new _0x301c84(this[_0x2d8ee7(0x1ea)][_0x2d8ee7(0x3da)],{'namespace':_0x39ff97}),this[_0x2d8ee7(0x6bc)][_0x2d8ee7(0x543)](_0x39ff97,_0x4b023d);}catch{return null;}return _0x4b023d;}[_0x34914d(0x4a4)](){const _0x1ce6ea=_0x34914d,_0x323147=[];try{for(const [_0x593811,_0x34f798]of this['okdb']['_envs']){if(_0x593811[_0x1ce6ea(0x557)]('~'))continue;for(const _0x16edf5 of _0x34f798[_0x1ce6ea(0x1ce)][_0x1ce6ea(0x408)]())_0x323147[_0x1ce6ea(0x1c2)]({..._0x16edf5,'env':_0x593811});}}catch{}return{'participate':this[_0x1ce6ea(0x1ea)][_0x1ce6ea(0x3c6)]?.['_participate']??![],'processors':_0x323147};}[_0x34914d(0x1c3)](){const _0x358977=_0x34914d;if(this['_desired'])return!![];const _0x4866a0=this['okdb'][_0x358977(0x3da)];if(!_0x4866a0)return![];return this['_desired']=_0x4866a0[_0x358977(0x367)](_0x500bb4,{'dupSort':![]}),this[_0x358977(0x3fe)]=_0x4866a0['openDB'](_0x152a9b,{'dupSort':![]}),!![];}async[_0x34914d(0x22a)](){const _0x17ed33=_0x34914d;if(!this['_ensureDesired']())return;const _0x1ef58b='__vocab/version',_0x11aafc=0x1,_0x30a9b0=this[_0x17ed33(0xf0)][_0x17ed33(0x741)](_0x1ef58b)??0x0;if(_0x30a9b0>=_0x11aafc)return;const _0x4d6296=_0x44ed65=>{const _0x452e21=_0x17ed33;if(_0x44ed65==='worker')return _0x452e21(0x476);if(_0x44ed65==='async')return _0x452e21(0x597);return _0x44ed65;};await this[_0x17ed33(0x1ea)]['_systemEnv']['_writer'][_0x17ed33(0x2cb)](()=>{const _0x1677bb=_0x17ed33;for(const _0x55862c of['procmode/',_0x1677bb(0x1d1)]){for(const {key:_0x23b8d6,value:_0x5860b6}of this['_desired'][_0x1677bb(0x4f6)]({'start':_0x55862c,'end':_0x55862c+'\xff'})){if(typeof _0x23b8d6!==_0x1677bb(0x139)||!_0x23b8d6[_0x1677bb(0x557)](_0x55862c))break;const _0x178112=_0x4d6296(_0x5860b6[_0x1677bb(0x1d0)]);if(_0x178112!==_0x5860b6[_0x1677bb(0x1d0)])this['_desired'][_0x1677bb(0x22b)](_0x23b8d6,{..._0x5860b6,'mode':_0x178112});}}this[_0x1677bb(0xf0)][_0x1677bb(0x22b)](_0x1ef58b,_0x11aafc);});}[_0x34914d(0x2a6)](){const _0x41229a=_0x34914d;return!!this[_0x41229a(0xf0)];}[_0x34914d(0x58a)](_0x429d6f,_0x28f83e){const _0x555668=_0x34914d;if(!this['_ensureDesired']())return null;const _0x32b5ff=_0x429d6f+'/'+_0x28f83e;return this['_refreshDesiredSnapshot'](),this[_0x555668(0x487)][_0x555668(0x741)](_0x32b5ff)??this[_0x555668(0xf0)][_0x555668(0x741)](_0x32b5ff)??null;}['_refreshDesiredSnapshot'](){const _0x13ee07=_0x34914d;if(!_0x3ecdad)return;try{this[_0x13ee07(0x1ea)][_0x13ee07(0x600)]?.['db']?.[_0x13ee07(0x345)]?.();}catch{}}async['setDesired'](_0x343f09,_0x317eab,_0x571d89){const _0x4f0c4b=_0x34914d;if(!this[_0x4f0c4b(0x1c3)]())return null;const _0x459a95=_0x343f09+'/'+_0x317eab;this[_0x4f0c4b(0x2f3)]();const _0x443167=this[_0x4f0c4b(0x487)][_0x4f0c4b(0x741)](_0x459a95)??this[_0x4f0c4b(0xf0)][_0x4f0c4b(0x741)](_0x459a95)??{'version':0x0},_0xf233fd=(_0x443167[_0x4f0c4b(0x512)]||0x0)+0x1,_0x4d8108={..._0x443167,..._0x571d89,'version':_0xf233fd,'updatedAt':Date[_0x4f0c4b(0x6f1)]()};this[_0x4f0c4b(0x487)][_0x4f0c4b(0x543)](_0x459a95,_0x4d8108);try{await this[_0x4f0c4b(0x1ea)][_0x4f0c4b(0x600)][_0x4f0c4b(0x43d)][_0x4f0c4b(0x2cb)](()=>{const _0x4f3214=_0x4f0c4b;this[_0x4f3214(0xf0)][_0x4f3214(0x22b)](_0x459a95,_0x4d8108);});}finally{if(this[_0x4f0c4b(0x487)]['get'](_0x459a95)===_0x4d8108)this[_0x4f0c4b(0x487)]['delete'](_0x459a95);}return _0xf233fd;}[_0x34914d(0x6c4)](_0xda10ad){const _0xc131ec=_0x34914d;if(!this['_ensureDesired']())return[];this[_0xc131ec(0x2f3)]();const _0x354257=_0xda10ad+'/',_0x4fc042=[];for(const {key:_0x34155e,value:_0x502f2a}of this[_0xc131ec(0xf0)][_0xc131ec(0x4f6)]({'start':_0x354257,'end':_0x354257+'\xff'})){if(typeof _0x34155e!=='string'||!_0x34155e['startsWith'](_0x354257))break;_0x4fc042[_0xc131ec(0x1c2)]({'key':_0x34155e[_0xc131ec(0x762)](_0x354257[_0xc131ec(0x2e8)]),'value':_0x502f2a});}return _0x4fc042;}[_0x34914d(0x3c9)](_0x45ddc5){const _0xf95957=_0x34914d;if(!this[_0xf95957(0x1c3)]())return null;return this[_0xf95957(0x3fe)][_0xf95957(0x741)](_0x45ddc5)??null;}async[_0x34914d(0x507)](_0x3b8e4e,_0x25228c,_0x1d21f3={}){const _0x2230f4=_0x34914d;if(!this[_0x2230f4(0x1c3)]())return null;let _0x2bb701;return await this[_0x2230f4(0x1ea)][_0x2230f4(0x600)][_0x2230f4(0x43d)]['transaction'](()=>{const _0x43f349=_0x2230f4,_0x192263=this[_0x43f349(0x3fe)][_0x43f349(0x741)](_0x3b8e4e)||{'epoch':0x0};_0x2bb701=(_0x192263[_0x43f349(0xd6)]||0x0)+0x1,this[_0x43f349(0x3fe)][_0x43f349(0x22b)](_0x3b8e4e,{..._0x192263,..._0x1d21f3,'cmd':_0x25228c,'epoch':_0x2bb701,'updatedAt':Date[_0x43f349(0x6f1)]()});}),_0x2bb701;}}return okdbProcessRegistry={'OKDBProcessRegistry':_0x2938df,'nodeKey':_0x4ac719,'logicalKey':_0x1b4066,'slotKey':_0x5c5966,'PROCESS_ENV':_0x5562f0,'NODE_TYPE':_0x2be9a8},okdbProcessRegistry;}var okdbChangefeed,hasRequiredOkdbChangefeed;function requireOkdbChangefeed(){const _0x1f69fc=_0x1cb9ed;if(hasRequiredOkdbChangefeed)return okdbChangefeed;hasRequiredOkdbChangefeed=0x1;const _0x52ec33=require$$0$6,{EVENTS:_0x1f3293,CHANGE_ACTIONS:_0x5a97ff}=requireOkdbEnums(),{LOOP:_0x522e3e}=requireOkdbLoopMonitor(),_0x332332=Number(process.env.OKDB_CHANGEFEED_QUANTUM)||0x3e8,_0x4626d8=0x5,_0x533f7f=0x2710;class _0x5f0e49 extends _0x52ec33{constructor(_0x5494bc,_0x502f57={}){const _0x5b9c60=_0x4ed4;super(),this['okdb']=_0x5494bc,this[_0x5b9c60(0x5db)]=_0x502f57[_0x5b9c60(0x299)]??_0x332332,this[_0x5b9c60(0x5b3)]=_0x502f57[_0x5b9c60(0x274)]??_0x4626d8,this[_0x5b9c60(0x154)]=_0x502f57[_0x5b9c60(0x15f)]??_0x533f7f,this['_started']=![],this[_0x5b9c60(0x3e4)]=new Map(),this[_0x5b9c60(0x18c)]=new Map(),this[_0x5b9c60(0x779)]=new Map(),this[_0x5b9c60(0x764)]=null,this[_0x5b9c60(0x637)]=![],this[_0x5b9c60(0x75)]=new Set(),this[_0x5b9c60(0x2d8)]=new Set(),this[_0x5b9c60(0x303)]=_0x5219a2=>this[_0x5b9c60(0x3e7)](_0x5219a2),this['_onPending']=_0x31f004=>this[_0x5b9c60(0x328)](_0x31f004),this[_0x5b9c60(0xbc)]=_0x1b9752=>this[_0x5b9c60(0x31e)](_0x1b9752),this[_0x5b9c60(0x281)]=()=>this[_0x5b9c60(0x391)]();}[_0x1f69fc(0xfa)](){const _0x272947=_0x1f69fc;if(this['_started'])return;this['_started']=!![];for(const [_0x5c8143,_0x29cbc0]of this[_0x272947(0x1ea)][_0x272947(0x319)]){if(_0x5c8143[_0x272947(0x557)]('~'))continue;try{_0x29cbc0[_0x272947(0x201)]();}catch{}}for(const [_0x44f733,_0x134bd8]of this[_0x272947(0x1ea)][_0x272947(0x319)]){if(_0x44f733[_0x272947(0x557)]('~'))continue;try{this[_0x272947(0x18c)]['set'](_0x44f733,_0x134bd8[_0x272947(0x1d3)]()||0x0);}catch{}}const {events:_0x9b6c90}=this[_0x272947(0x1ea)];_0x9b6c90['on'](_0x1f3293[_0x272947(0x672)],this['_onPending']),_0x9b6c90['on'](_0x1f3293[_0x272947(0x519)],this['_onItem']),_0x9b6c90['on'](_0x1f3293[_0x272947(0x797)],this[_0x272947(0x303)]),_0x9b6c90['on'](_0x1f3293[_0x272947(0x728)],this[_0x272947(0x303)]),_0x9b6c90['on'](_0x1f3293[_0x272947(0x130)],this['_onPoke']),_0x9b6c90[_0x272947(0x17b)](_0x1f3293[_0x272947(0x14b)],this[_0x272947(0x281)]);}[_0x1f69fc(0x391)](){const _0x1e71c7=_0x1f69fc;if(!this[_0x1e71c7(0x778)])return;this['_started']=![];const {events:_0xe9bcca}=this[_0x1e71c7(0x1ea)];_0xe9bcca[_0x1e71c7(0x66f)](_0x1f3293[_0x1e71c7(0x672)],this[_0x1e71c7(0xdb)]),_0xe9bcca[_0x1e71c7(0x66f)](_0x1f3293[_0x1e71c7(0x519)],this['_onItem']),_0xe9bcca['off'](_0x1f3293[_0x1e71c7(0x797)],this['_onItem']),_0xe9bcca['off'](_0x1f3293[_0x1e71c7(0x728)],this[_0x1e71c7(0x303)]),_0xe9bcca[_0x1e71c7(0x66f)](_0x1f3293['SYSTEM_POKE'],this[_0x1e71c7(0xbc)]);try{_0xe9bcca['off'](_0x1f3293[_0x1e71c7(0x14b)],this[_0x1e71c7(0x281)]);}catch{}this[_0x1e71c7(0x764)]&&(clearTimeout(this[_0x1e71c7(0x764)]),this[_0x1e71c7(0x764)]=null),this[_0x1e71c7(0x779)][_0x1e71c7(0x276)](),this['_cursors']['clear'](),this[_0x1e71c7(0x18c)]['clear'](),this['_seen']['clear'](),this[_0x1e71c7(0x2d8)][_0x1e71c7(0x276)]();}[_0x1f69fc(0x240)](_0x5e8af0,_0x379821,_0x679b01,_0x500094){return _0x5e8af0+'\x00'+_0x379821+'\x00'+_0x679b01+'\x00'+_0x500094;}[_0x1f69fc(0x371)](_0x385a7b,_0x3fb065,_0x150697,_0x32b7a1){const _0x313c2c=_0x1f69fc,_0x2194e1=this[_0x313c2c(0x240)](_0x385a7b,_0x3fb065,_0x150697,_0x32b7a1);if(this[_0x313c2c(0x75)][_0x313c2c(0x783)](_0x2194e1))return![];this['_seen'][_0x313c2c(0x5f3)](_0x2194e1);if(this['_seen'][_0x313c2c(0x54a)]>this[_0x313c2c(0x154)]){const _0x1a76c8=this['_seen'][_0x313c2c(0x260)]()[_0x313c2c(0x1c9)]()[_0x313c2c(0x1c5)];this[_0x313c2c(0x75)][_0x313c2c(0x210)](_0x1a76c8);}return!![];}[_0x1f69fc(0x328)](_0xfc946a){const _0x1e2da0=_0x1f69fc;if(!this[_0x1e2da0(0x778)]||!_0xfc946a)return;const {env:_0x201f21,type:_0x4a5e3d,key:_0x25717f,clock:_0x5c99d0}=_0xfc946a;if(_0x201f21==null||_0x4a5e3d==null||_0x25717f==null)return;if(typeof _0x201f21===_0x1e2da0(0x139)&&_0x201f21[_0x1e2da0(0x557)]('~'))return;if(typeof _0x4a5e3d===_0x1e2da0(0x139)&&_0x4a5e3d[_0x1e2da0(0x557)]('~'))return;this[_0x1e2da0(0x2d8)][_0x1e2da0(0x5f3)](this[_0x1e2da0(0x240)](_0x201f21,_0x4a5e3d,_0x25717f,_0x5c99d0)),this[_0x1e2da0(0x2d8)][_0x1e2da0(0x54a)]>this['_dedupeMax']&&this[_0x1e2da0(0x2d8)][_0x1e2da0(0x210)](this['_pendingLocal']['values']()[_0x1e2da0(0x1c9)]()[_0x1e2da0(0x1c5)]);}[_0x1f69fc(0x3e7)](_0x4750fd){const _0x4129a9=_0x1f69fc;if(!this[_0x4129a9(0x778)]||!_0x4750fd)return;const {env:_0x4153f7,type:_0x5317a5,key:_0x57a0f8,clock:_0x52a68d,origin:_0x2d6436,action:_0x24c66c,newValue:_0x1e811a,oldValue:_0x436459}=_0x4750fd;if(_0x4153f7==null||_0x5317a5==null||_0x57a0f8==null)return;if(typeof _0x4153f7===_0x4129a9(0x139)&&_0x4153f7[_0x4129a9(0x557)]('~'))return;if(typeof _0x5317a5===_0x4129a9(0x139)&&_0x5317a5[_0x4129a9(0x557)]('~'))return;this[_0x4129a9(0x2d8)][_0x4129a9(0x210)](this[_0x4129a9(0x240)](_0x4153f7,_0x5317a5,_0x57a0f8,_0x52a68d));if(!this[_0x4129a9(0x371)](_0x4153f7,_0x5317a5,_0x57a0f8,_0x52a68d))return;const _0x18e351=_0x24c66c===_0x5a97ff[_0x4129a9(0x5bc)]?_0x4129a9(0x5ce):'put';this[_0x4129a9(0x454)]('change',{'env':_0x4153f7,'type':_0x5317a5,'key':_0x57a0f8,'op':_0x18e351,'clock':_0x52a68d,'origin':_0x2d6436,'value':_0x18e351===_0x4129a9(0x5ce)?null:_0x1e811a,'prevValue':_0x436459});}[_0x1f69fc(0x31e)](_0x4c4b9f){const _0x1fc057=_0x1f69fc;if(!this[_0x1fc057(0x778)])return;if(!_0x4c4b9f||typeof _0x4c4b9f[_0x1fc057(0x514)]!=='string'||typeof _0x4c4b9f[_0x1fc057(0x5be)]!==_0x1fc057(0x139))return;const {env:_0x3e9c00,type:_0x43f2db}=_0x4c4b9f;if(_0x3e9c00[_0x1fc057(0x557)]('~')||_0x43f2db[_0x1fc057(0x557)]('~'))return;this[_0x1fc057(0x779)][_0x1fc057(0x543)](_0x3e9c00+'\x00'+_0x43f2db,{'env':_0x3e9c00,'type':_0x43f2db}),this[_0x1fc057(0x531)]();}['_scheduleFlush'](){const _0x982682=_0x1f69fc;if(this['_flushTimer'])return;const _0x54348b=()=>{const _0x4ca337=_0x4ed4;this[_0x4ca337(0x764)]=null,this[_0x4ca337(0x589)]()['catch'](()=>{});};this[_0x982682(0x764)]=setTimeout(_0x54348b,this['_flushDebounce']>0x0?this['_flushDebounce']:0x0);}async[_0x1f69fc(0x589)](){const _0x3436a0=_0x1f69fc;if(this[_0x3436a0(0x637)]){this[_0x3436a0(0x531)]();return;}this[_0x3436a0(0x637)]=!![];try{const _0x3bf566=[...this['_pending'][_0x3436a0(0x260)]()];this['_pending']['clear']();let _0x2d3f31=![];for(const {env:_0x252549,type:_0x7280b4}of _0x3bf566){try{const _0x39b686=await this[_0x3436a0(0xe4)](_0x252549,_0x7280b4);if(_0x39b686)_0x2d3f31=!![];}catch{this[_0x3436a0(0x779)][_0x3436a0(0x543)](_0x252549+'\x00'+_0x7280b4,{'env':_0x252549,'type':_0x7280b4}),_0x2d3f31=!![];}}if(_0x2d3f31||this['_pending'][_0x3436a0(0x54a)]>0x0)this[_0x3436a0(0x531)]();}finally{this[_0x3436a0(0x637)]=![];}}async['_drainOne'](_0x33fd2d,_0x53da54){const _0x4d8ec8=_0x1f69fc,_0x48253b=await this[_0x4d8ec8(0x1ea)][_0x4d8ec8(0x418)](_0x33fd2d),_0x3140d8=_0x33fd2d+'\x00'+_0x53da54;!this[_0x4d8ec8(0x3e4)]['has'](_0x3140d8)&&(!this['_baselines'][_0x4d8ec8(0x783)](_0x33fd2d)&&(_0x48253b[_0x4d8ec8(0x201)](),this['_baselines'][_0x4d8ec8(0x543)](_0x33fd2d,_0x48253b[_0x4d8ec8(0x1d3)]()||0x0)),this[_0x4d8ec8(0x3e4)][_0x4d8ec8(0x543)](_0x3140d8,this[_0x4d8ec8(0x18c)][_0x4d8ec8(0x741)](_0x33fd2d)));const _0x287285=this[_0x4d8ec8(0x3e4)][_0x4d8ec8(0x741)](_0x3140d8),_0x40e04e=_0x48253b[_0x4d8ec8(0x1d3)](_0x53da54)||0x0;if(_0x40e04e<=_0x287285)return![];const _0x3f39cd=_0x287285+this[_0x4d8ec8(0x5db)],_0x233413=Math['min'](_0x40e04e,_0x3f39cd),_0x329b5d=_0x522e3e[_0x4d8ec8(0x283)]?_0x522e3e[_0x4d8ec8(0x6f1)]():0x0,_0xc14f0f=Array[_0x4d8ec8(0x16b)](_0x48253b[_0x4d8ec8(0x510)](_0x53da54,_0x287285+0x1,_0x233413));let _0x271ef1=_0x287285;for(const _0x58b4d4 of _0xc14f0f){const {clock:_0x23e3fb,key:_0x391079,action:_0x188961,origin:_0x4e05ab}=_0x58b4d4;if(_0x23e3fb>_0x271ef1)_0x271ef1=_0x23e3fb;if(_0x391079==null)continue;if(this[_0x4d8ec8(0x2d8)][_0x4d8ec8(0x783)](this[_0x4d8ec8(0x240)](_0x33fd2d,_0x53da54,_0x391079,_0x23e3fb)))continue;if(!this[_0x4d8ec8(0x371)](_0x33fd2d,_0x53da54,_0x391079,_0x23e3fb))continue;let _0xcbfd3f,_0x1750c0;if(_0x188961===_0x5a97ff[_0x4d8ec8(0x5bc)])_0xcbfd3f=_0x4d8ec8(0x5ce),_0x1750c0=null;else{const _0xe9f18d=_0x48253b[_0x4d8ec8(0x741)](_0x53da54,_0x391079);_0xe9f18d==null?(_0xcbfd3f=_0x4d8ec8(0x5ce),_0x1750c0=null):(_0xcbfd3f='put',_0x1750c0=_0xe9f18d);}this[_0x4d8ec8(0x454)](_0x4d8ec8(0x580),{'env':_0x33fd2d,'type':_0x53da54,'key':_0x391079,'op':_0xcbfd3f,'clock':_0x23e3fb,'origin':_0x4e05ab,'value':_0x1750c0});}if(_0x522e3e[_0x4d8ec8(0x283)])_0x522e3e['note'](_0x4d8ec8(0x238)+_0x33fd2d+':'+_0x53da54,_0x522e3e[_0x4d8ec8(0x6f1)]()-_0x329b5d,'n='+_0xc14f0f[_0x4d8ec8(0x2e8)]);return this[_0x4d8ec8(0x3e4)][_0x4d8ec8(0x543)](_0x3140d8,Math[_0x4d8ec8(0x608)](_0x271ef1,_0x233413)),_0x48253b['getClock'](_0x53da54)>_0x233413;}[_0x1f69fc(0x469)](){const _0x5590c1=_0x1f69fc;return{'started':this[_0x5590c1(0x778)],'quantum':this[_0x5590c1(0x5db)],'flushDebounce':this[_0x5590c1(0x5b3)],'cursors':Object[_0x5590c1(0x341)]([...this[_0x5590c1(0x3e4)][_0x5590c1(0x377)]()][_0x5590c1(0x362)](([_0x5484bd,_0x4998c4])=>[_0x5484bd[_0x5590c1(0x61f)]('\x00',':'),_0x4998c4])),'pending':this[_0x5590c1(0x779)][_0x5590c1(0x54a)],'seen':this['_seen'][_0x5590c1(0x54a)]};}}return _0x5f0e49[_0x1f69fc(0x6f0)]=_0x332332,okdbChangefeed={'OKDBChangefeed':_0x5f0e49},okdbChangefeed;}var okdbCluster,hasRequiredOkdbCluster;function requireOkdbCluster(){const _0x4d5d62=_0x1cb9ed;if(hasRequiredOkdbCluster)return okdbCluster;hasRequiredOkdbCluster=0x1;const _0x37d983=require$$1$1,_0x17934e=require$$1,{EVENTS:_0x369e01}=requireOkdbEnums(),_0x3cd610=require$$0,{slotKey:_0x439f13}=requireOkdbProcessRegistry(),_0x1dbfe5=Number(process.env.OKDB_CLUSTER_RESPAWN_BACKOFF_MS)||0xfa,_0x111e8a=0xfa0,_0x3476e9=0x5,_0x3c694a=0x2710,_0x54c289=0xbb8,_0x3d8268=0x7d0,_0x2ad969=_0x4d5d62(0x4d7),_0x5d54bf=_0x4d5d62(0x3ac),_0x2869f9='log',_0x544df2=_0x4d5d62(0x665),_0x5a161b=[_0x369e01[_0x4d5d62(0x2b3)],_0x369e01[_0x4d5d62(0xe8)],_0x369e01[_0x4d5d62(0x64e)],_0x369e01[_0x4d5d62(0x625)],_0x369e01[_0x4d5d62(0x94)],_0x369e01[_0x4d5d62(0x535)],_0x369e01[_0x4d5d62(0x180)],_0x369e01['INDEX_REGISTERED'],'processor:ready',_0x4d5d62(0x662),'processor:error',_0x4d5d62(0x2bf),'processor:resumed',_0x4d5d62(0x6d7)],_0x4a1f68=Number(process.env.OKDB_CLUSTER_STATUS_MS)||0x7d0,_0x433cfa=0x64;function _0x350b2c(_0x2fbb0d){const _0x49b7e7=_0x4d5d62;if(!_0x2fbb0d)return _0x49b7e7(0x5d2);const _0x1e33ce=(_0x2fbb0d[_0x49b7e7(0x3c6)]||[])[_0x49b7e7(0x362)](_0x15d76d=>[_0x15d76d[_0x49b7e7(0x514)],_0x15d76d['id'],_0x15d76d[_0x49b7e7(0x1d0)],_0x15d76d['state'],!!_0x15d76d[_0x49b7e7(0x615)],!!_0x15d76d[_0x49b7e7(0x585)],!!_0x15d76d['claimGated'],_0x15d76d[_0x49b7e7(0x6a3)]?.[_0x49b7e7(0x401)]??null,_0x15d76d['error']?String(_0x15d76d[_0x49b7e7(0x1da)]?.[_0x49b7e7(0x71d)]??_0x15d76d['error']):null]);return JSON[_0x49b7e7(0x5bd)]([!!_0x2fbb0d[_0x49b7e7(0x53e)],_0x1e33ce]);}function _0x5edf4c({workers:_0x3c75d5,makeOkdb:_0x249eeb,port:_0x1def2b,primaryOkdb:_0x3b6a25,childEntry:childEntry=![],workerEnv:workerEnv=null,workerRole:workerRole=null,listenAddr:listenAddr=null}={}){const _0x97d15e=_0x4d5d62;if(_0x37d983[_0x97d15e(0x9d)])return childEntry&&_0x37d983[_0x97d15e(0x769)]({'exec':_0x17934e['join'](__dirname,_0x97d15e(0x34b)),'args':[],'execArgv':((()=>{const _0xd50a73=_0x97d15e,_0x11ee12=[];for(let _0x2d3796=0x0;_0x2d3796<process[_0xd50a73(0x394)]['length'];_0x2d3796++){const _0x1f894b=process[_0xd50a73(0x394)][_0x2d3796];if(_0x1f894b[_0xd50a73(0x557)]('--test')||_0x1f894b[_0xd50a73(0x557)](_0xd50a73(0x1e0))||_0x1f894b[_0xd50a73(0x557)](_0xd50a73(0xb3)))continue;if(_0x1f894b==='-e'||_0x1f894b===_0xd50a73(0x1e9)||_0x1f894b==='-p'||_0x1f894b===_0xd50a73(0x3ad)){_0x2d3796++;continue;}_0x11ee12[_0xd50a73(0x1c2)](_0x1f894b);}return _0x11ee12;})())}),_0x2ea06c({'workers':_0x3c75d5,'port':_0x1def2b,'primaryOkdb':_0x3b6a25,'workerEnv':workerEnv,'workerRole':workerRole,'listenAddr':listenAddr??':'+_0x1def2b});return _0x485af2({'makeOkdb':_0x249eeb,'port':_0x1def2b});}function _0x2ea06c({workers:_0x30c2b0,port:_0x31cd22,primaryOkdb:_0x30b209,workerEnv:_0x3485b6,workerRole:_0x279e39,listenAddr:_0x5234be}){const _0x112d28=_0x4d5d62,_0x2e6d7d=new Map(),_0x6deb51=new Map();let _0x1afe96=![];const _0x380338=_0x778bef=>_0x778bef?.[_0x112d28(0x522)],_0x43b5f2=_0x46c1fd=>{const _0x5b8379=_0x112d28,_0x195690=_0x37d983[_0x5b8379(0x617)]({...process.env,..._0x3485b6||{},'OKDB_CLUSTER_SLOT':String(_0x46c1fd)});return _0x195690[_0x5b8379(0x522)]=_0x46c1fd,_0x2e6d7d[_0x5b8379(0x543)](_0x195690['process'][_0x5b8379(0x401)],{'worker':_0x195690,'startedAt':Date[_0x5b8379(0x6f1)](),'slot':_0x46c1fd}),_0x195690['on']('error',_0xea97b8=>{const _0x2a06c1=_0x5b8379;console['log']('[okdb-cluster]\x20worker\x20pid='+_0x195690[_0x2a06c1(0x790)][_0x2a06c1(0x401)]+_0x2a06c1(0x309)+(_0xea97b8?.[_0x2a06c1(0x71d)]??_0xea97b8));}),_0x195690['on'](_0x5b8379(0x70a),()=>_0x2409e3()),_0x195690;},_0x5a9b7d=_0x487e68=>{const _0x4078cc=_0x112d28;for(const {worker:_0x5106ed}of _0x2e6d7d[_0x4078cc(0x260)]()){if(_0x5106ed[_0x4078cc(0x438)]()||!_0x5106ed['isConnected']())continue;try{_0x5106ed[_0x4078cc(0x50a)](_0x487e68);}catch{}}};_0x30b209?.['_activateProcesses']?.({'kind':_0x112d28(0x430),'listenAddr':_0x5234be})[_0x112d28(0x31d)](()=>{}),_0x30b209?.[_0x112d28(0x5d0)]?.[_0x112d28(0x735)]?.({'workersConfigured':_0x30c2b0});const _0x831ec4={'engines':!![],'processors':!![],'compaction':!![],..._0x279e39,'http':!![]},_0x2409e3=()=>{const _0x370aa8=_0x112d28,_0x202e84=_0x30b209?.[_0x370aa8(0x5d0)];if(!_0x202e84||!_0x202e84[_0x370aa8(0x4fd)])return;const _0x3830b3=_0x202e84[_0x370aa8(0x64f)];for(const {worker:_0x860a1d,startedAt:_0x6cad31,slot:_0x530596,stats:_0x110562,processing:_0x434c21}of _0x2e6d7d[_0x370aa8(0x260)]()){if(_0x860a1d[_0x370aa8(0x438)]())continue;const _0x3b7630=_0x202e84[_0x370aa8(0x2a6)]?.()&&_0x202e84[_0x370aa8(0x58a)](_0x370aa8(0x4b7),_0x123c20(_0x530596))?.[_0x370aa8(0x72e)]===!![];_0x202e84[_0x370aa8(0x56f)]({'pid':_0x860a1d[_0x370aa8(0x790)][_0x370aa8(0x401)],'startedAt':_0x6cad31,'kind':_0x370aa8(0x701),'supervisorKey':_0x3830b3,'slot':_0x530596,'slotKey':_0x123c20(_0x530596),'role':_0x831ec4,'listenAddr':_0x5234be,'lifecycle':_0x3b7630?'decommissioning':_0x370aa8(0x1cc),'processing':_0x434c21??null,'stats':_0x110562??null})[_0x370aa8(0x31d)](()=>{});}},_0x123c20=_0x497c28=>_0x439f13(_0x112d28(0x71f)+_0x31cd22,_0x497c28),_0x301c85=_0x34a1bd=>{const _0x210827=_0x112d28,_0x5ac23e=_0x30b209?.[_0x210827(0x5d0)];if(!_0x5ac23e?.[_0x210827(0x2a6)]?.())return![];return _0x5ac23e['getDesired']('slot',_0x123c20(_0x34a1bd))?.[_0x210827(0x72e)]===!![];};for(let _0x482630=0x0;_0x482630<_0x30c2b0;_0x482630++){const _0x39a8cd=_0x301c85(_0x482630);_0x6deb51[_0x112d28(0x543)](_0x482630,{'deaths':[],'consecutiveFailures':0x0,'dead':_0x39a8cd,'respawnTimer':null}),_0x39a8cd?console[_0x112d28(0x219)](_0x112d28(0x715)+_0x482630+_0x112d28(0x789)):_0x43b5f2(_0x482630);}const _0x1b543b=()=>{const _0x3202ae=_0x112d28,_0x3ff493=_0x30b209?.[_0x3202ae(0x5d0)];if(!_0x3ff493?.[_0x3202ae(0x4fd)]||!_0x3ff493['hasDesired']?.())return;for(const [_0x2e9459,_0x1b517f]of _0x6deb51[_0x3202ae(0x377)]()){const _0x24d246=_0x3ff493['getDesired']('slot',_0x123c20(_0x2e9459)),_0x438f40=_0x24d246?.[_0x3202ae(0x72e)]===!![],_0x235609=_0x24d246?.[_0x3202ae(0x2e2)]===!![];if(_0x438f40&&!_0x1b517f[_0x3202ae(0x4e9)]){_0x1b517f[_0x3202ae(0x4e9)]=!![];_0x1b517f[_0x3202ae(0x547)]&&(clearTimeout(_0x1b517f[_0x3202ae(0x547)]),_0x1b517f[_0x3202ae(0x547)]=null);for(const {worker:_0x76e4b7}of _0x2e6d7d['values']()){if(_0x380338(_0x76e4b7)!==_0x2e9459||_0x76e4b7['isDead']())continue;try{if(_0x235609)_0x76e4b7['process'][_0x3202ae(0x2e2)](_0x3202ae(0xee));else _0x76e4b7['isConnected']()&&_0x76e4b7['disconnect']();}catch{}}console[_0x3202ae(0x219)]('[okdb-cluster]\x20'+(_0x235609?_0x3202ae(0x1ac):_0x3202ae(0x17f))+'\x20worker\x20slot='+_0x2e9459+_0x3202ae(0x732));}else{if(!_0x438f40&&_0x1b517f[_0x3202ae(0x4e9)]&&_0x24d246){_0x1b517f[_0x3202ae(0x4e9)]=![],_0x1b517f[_0x3202ae(0x335)]=[],_0x1b517f[_0x3202ae(0x1a5)]=0x0;const _0x215242=[..._0x2e6d7d[_0x3202ae(0x260)]()][_0x3202ae(0x21d)](({worker:_0x332d43})=>_0x380338(_0x332d43)===_0x2e9459&&!_0x332d43[_0x3202ae(0x438)]());!_0x215242&&!_0x1afe96&&(_0x43b5f2(_0x2e9459),console[_0x3202ae(0x219)]('[okdb-cluster]\x20recommissioned\x20worker\x20slot='+_0x2e9459));}}}},_0x22d3e7=()=>{try{_0x1b543b();}catch{}};_0x30b209?.[_0x112d28(0x599)]?.['on']?.(_0x369e01[_0x112d28(0x526)],_0x22d3e7);const _0x2f7ef9=[];if(_0x30b209?.[_0x112d28(0x599)]?.['on'])for(const _0x42b85b of _0x5a161b){const _0x4959fb=_0x3c15e9=>{_0x5a9b7d({[_0x2ad969]:_0x5d54bf,'event':_0x42b85b,'data':_0x3c15e9??{}});};_0x30b209['events']['on'](_0x42b85b,_0x4959fb),_0x2f7ef9['push']({'event':_0x42b85b,'handler':_0x4959fb});}const _0x49b0b6=setInterval(()=>{_0x1b543b(),_0x2409e3();},_0x4a1f68);_0x49b0b6['unref']?.();const _0x5a768d=(_0x17c761,_0x3e2eb6)=>{const _0x5a05c2=_0x112d28;if(!_0x3e2eb6||typeof _0x3e2eb6!==_0x5a05c2(0x25a)||_0x3e2eb6[_0x2ad969]!==_0x2869f9)return;if(!_0x30b209?.[_0x5a05c2(0x219)]?.[_0x5a05c2(0x4db)])return;const _0x15e287=_0x3e2eb6[_0x5a05c2(0x48d)]||{};_0x30b209[_0x5a05c2(0x219)][_0x5a05c2(0x4db)]({..._0x15e287,'msg':'[w'+_0x3e2eb6[_0x5a05c2(0x4b7)]+']\x20'+(_0x15e287['msg']??''),'meta':{..._0x15e287[_0x5a05c2(0x57f)]||{},'worker':_0x3e2eb6['slot'],'workerPid':_0x3e2eb6[_0x5a05c2(0x401)]}});};_0x37d983['on']('message',_0x5a768d);const _0x5d2f87=(_0x5d3f27,_0x46f314)=>{const _0x472688=_0x112d28;if(!_0x46f314||typeof _0x46f314!==_0x472688(0x25a)||_0x46f314[_0x2ad969]!==_0x544df2)return;const _0x261e33=_0x2e6d7d[_0x472688(0x741)](_0x5d3f27['process'][_0x472688(0x401)]);if(_0x261e33){_0x261e33[_0x472688(0x665)]={..._0x46f314[_0x472688(0x665)],'at':Date[_0x472688(0x6f1)]()};if(_0x46f314[_0x472688(0x34c)]!==undefined){const _0x514416=_0x350b2c(_0x46f314['processing']);_0x514416!==_0x261e33[_0x472688(0x42e)]&&(_0x261e33[_0x472688(0x42e)]=_0x514416,_0x453acf()),_0x261e33[_0x472688(0x34c)]=_0x46f314['processing'];}}};let _0x1fe8f3=null;const _0x453acf=()=>{const _0x521ba5=_0x112d28;if(_0x1fe8f3||_0x1afe96)return;_0x1fe8f3=setTimeout(()=>{_0x1fe8f3=null;if(!_0x1afe96)_0x2409e3();},_0x433cfa),_0x1fe8f3[_0x521ba5(0x575)]?.();};_0x37d983['on'](_0x112d28(0x71d),_0x5d2f87),_0x37d983['on']('exit',(_0x26d8fc,_0x5cb223,_0x490fca)=>{const _0x2fd638=_0x112d28,_0x237f62=_0x26d8fc['process'][_0x2fd638(0x401)],_0x31de07=_0x380338(_0x26d8fc),_0x198183=_0x2e6d7d[_0x2fd638(0x741)](_0x237f62);if(_0x198183&&_0x30b209?.[_0x2fd638(0x5d0)])_0x30b209[_0x2fd638(0x5d0)]['removeNode'](_0x237f62+':'+_0x198183[_0x2fd638(0x618)])[_0x2fd638(0x31d)](()=>{});_0x2e6d7d['delete'](_0x237f62),console[_0x2fd638(0x219)]('[okdb-cluster]\x20worker\x20pid='+_0x237f62+_0x2fd638(0x3b1)+(_0x31de07??'?')+_0x2fd638(0x2ae)+(_0x2fd638(0x1ab)+_0x5cb223+_0x2fd638(0xb8)+(_0x490fca??_0x2fd638(0x1a8))+_0x2fd638(0x612)+_0x2e6d7d[_0x2fd638(0x54a)]+_0x2fd638(0x4f0))),_0x2409e3();if(_0x1afe96||_0x31de07==null)return;const _0x3782f5=_0x6deb51[_0x2fd638(0x741)](_0x31de07);if(!_0x3782f5||_0x3782f5[_0x2fd638(0x4e9)])return;const _0xca91dd=Date[_0x2fd638(0x6f1)]();_0x3782f5[_0x2fd638(0x335)][_0x2fd638(0x1c2)](_0xca91dd),_0x3782f5['deaths']=_0x3782f5[_0x2fd638(0x335)][_0x2fd638(0x20f)](_0x69fe9c=>_0xca91dd-_0x69fe9c<=_0x3c694a);if(_0x3782f5[_0x2fd638(0x335)]['length']>=_0x3476e9){_0x3782f5['dead']=!![],console[_0x2fd638(0x1da)](_0x2fd638(0x177)+_0x31de07+_0x2fd638(0x31a)+_0x3782f5[_0x2fd638(0x335)][_0x2fd638(0x2e8)]+_0x2fd638(0x3d7)+(_0x3c694a+'ms\x20—\x20giving\x20up\x20on\x20this\x20slot;\x20'+_0x2e6d7d[_0x2fd638(0x54a)]+_0x2fd638(0x140)));return;}_0x3782f5[_0x2fd638(0x1a5)]++;const _0x2bba46=Math['min'](_0x111e8a,_0x1dbfe5*0x2**(_0x3782f5[_0x2fd638(0x1a5)]-0x1));console[_0x2fd638(0x219)]('[okdb-cluster]\x20respawning\x20worker\x20slot='+_0x31de07+_0x2fd638(0x396)+_0x2bba46+'ms\x20(attempt\x20'+_0x3782f5[_0x2fd638(0x1a5)]+')'),_0x3782f5[_0x2fd638(0x547)]=setTimeout(()=>{const _0x445653=_0x2fd638;_0x3782f5[_0x445653(0x547)]=null;if(_0x1afe96||_0x3782f5[_0x445653(0x4e9)])return;const _0x3437a6=_0x43b5f2(_0x31de07);_0x3437a6[_0x445653(0x17b)](_0x445653(0x6b7),()=>{const _0x28692b=_0x445653;if(_0x6deb51[_0x28692b(0x741)](_0x31de07)===_0x3782f5)_0x3782f5[_0x28692b(0x1a5)]=0x0;});},_0x2bba46),_0x3782f5['respawnTimer'][_0x2fd638(0x575)]?.();});const _0x35876d=[..._0x2e6d7d['keys']()];console['log'](_0x112d28(0x126)+process[_0x112d28(0x401)]+_0x112d28(0x127)+_0x30c2b0+_0x112d28(0x60e)+_0x31cd22+':\x20'+('['+_0x35876d[_0x112d28(0x546)](',\x20')+']'));const _0x2446b4={'_isClusterController':!![],'port':_0x31cd22,'primaryOkdb':_0x30b209??null,'status'(){const _0x494619=_0x112d28;return{'clustered':!![],'primaryPid':process[_0x494619(0x401)],'port':_0x31cd22,'primaryRole':_0x30b209?.[_0x494619(0x553)]??null,'processorPid':null,'supervisorPid':process[_0x494619(0x401)],'workers':[..._0x2e6d7d[_0x494619(0x260)]()][_0x494619(0x362)](({worker:_0x43509f})=>({'pid':_0x43509f['process'][_0x494619(0x401)],'id':_0x43509f['id'],'dead':_0x43509f[_0x494619(0x438)]()}))};},async 'close'(){const _0x382f0d=_0x112d28;_0x1afe96=!![];for(const _0x3a5564 of _0x6deb51[_0x382f0d(0x260)]()){_0x3a5564['dead']=!![],_0x3a5564[_0x382f0d(0x547)]&&(clearTimeout(_0x3a5564[_0x382f0d(0x547)]),_0x3a5564[_0x382f0d(0x547)]=null);}clearInterval(_0x49b0b6);_0x1fe8f3&&(clearTimeout(_0x1fe8f3),_0x1fe8f3=null);_0x37d983[_0x382f0d(0x66f)](_0x382f0d(0x71d),_0x5a768d),_0x37d983[_0x382f0d(0x66f)]('message',_0x5d2f87),_0x30b209?.['events']?.[_0x382f0d(0x66f)]?.(_0x369e01[_0x382f0d(0x526)],_0x22d3e7);if(_0x30b209?.[_0x382f0d(0x599)]?.[_0x382f0d(0x66f)])for(const {event:_0x422346,handler:_0x97a6d8}of _0x2f7ef9){try{_0x30b209[_0x382f0d(0x599)]['off'](_0x422346,_0x97a6d8);}catch{}}_0x2f7ef9['length']=0x0;const _0x2eefb6=[..._0x2e6d7d['values']()]['map'](({worker:_0xce6e0d})=>_0xce6e0d);if(_0x2eefb6['length']===0x0)return;await Promise[_0x382f0d(0x447)](_0x2eefb6[_0x382f0d(0x362)](_0x5278c1=>new Promise(_0x1b878d=>{const _0x40f343=_0x382f0d;if(_0x5278c1[_0x40f343(0x438)]()){_0x1b878d();return;}let _0x3adf93=![];const _0x4fdb0f=()=>{if(_0x3adf93)return;_0x3adf93=!![];if(_0x107016)clearTimeout(_0x107016);_0x1b878d();};_0x5278c1[_0x40f343(0x17b)](_0x40f343(0x2e9),_0x4fdb0f);const _0x107016=setTimeout(()=>{const _0x27c833=_0x40f343;try{_0x5278c1[_0x27c833(0x790)][_0x27c833(0x2e2)]();}catch{}},_0x54c289+0x1f4);_0x107016[_0x40f343(0x575)]?.();try{_0x5278c1[_0x40f343(0x23f)]();}catch{try{_0x5278c1[_0x40f343(0x790)][_0x40f343(0x2e2)]();}catch{}}})));}};return _0x2446b4;}async function _0x485af2({makeOkdb:_0x38b3f7,port:_0x3e261d}){const _0x2dd06f=_0x4d5d62,_0x2c551a=await _0x38b3f7();return _0x280f55(_0x2c551a),_0x2c551a[_0x2dd06f(0x1be)][_0x2dd06f(0x416)](_0x3e261d);}function _0x280f55(_0x4241ee){const _0x479098=_0x4d5d62;if(!_0x4241ee||_0x4241ee[_0x479098(0x1ae)])return;_0x4241ee[_0x479098(0x1ae)]=!![];try{const {OKDBChangefeed:_0xb84869}=requireOkdbChangefeed(),_0x25285b=_0x4241ee[_0x479098(0x2db)];if(_0x25285b&&typeof _0x25285b['attachFeed']==='function'){const _0x5d6eb3=new _0xb84869(_0x4241ee);_0x5d6eb3[_0x479098(0xfa)](),_0x25285b[_0x479098(0x614)](_0x5d6eb3),_0x4241ee[_0x479098(0x5c0)]=_0x5d6eb3;}}catch(_0x3be7a0){_0x4241ee[_0x479098(0x219)]?.[_0x479098(0x27b)]?.(_0x479098(0x5ad)+(_0x3be7a0?.[_0x479098(0x71d)]??_0x3be7a0),{'feature':_0x479098(0x14a)});}const _0x3e1e0e=_0x3cc1ab=>{const _0x582cc9=_0x479098;if(!_0x3cc1ab||typeof _0x3cc1ab!==_0x582cc9(0x25a)||_0x3cc1ab[_0x2ad969]==null)return;if(_0x3cc1ab[_0x2ad969]===_0x5d54bf)try{_0x4241ee[_0x582cc9(0x2db)]?.[_0x582cc9(0x3bc)]?.(_0x3cc1ab[_0x582cc9(0x33f)],_0x3cc1ab['data']);}catch{}};process['on'](_0x479098(0x71d),_0x3e1e0e),_0x4241ee[_0x479098(0x268)]=_0x3e1e0e;{let _0x2c3018=process['cpuUsage'](),_0x29fff9=Date['now']();const _0x1662c9=()=>{const _0x1230d3=_0x479098;if(typeof process[_0x1230d3(0x50a)]!==_0x1230d3(0x18e)||!process[_0x1230d3(0x22d)])return;const _0x3fbd90=Date['now'](),_0x246a31=process['cpuUsage'](),_0x2c6b95=(_0x3fbd90-_0x29fff9)*0x3e8,_0x443a77=_0x246a31[_0x1230d3(0xd0)]-_0x2c3018[_0x1230d3(0xd0)]+(_0x246a31[_0x1230d3(0x374)]-_0x2c3018[_0x1230d3(0x374)]),_0x8b7a11=_0x2c6b95>0x0?Math[_0x1230d3(0x437)](0x64,Math[_0x1230d3(0x38d)](_0x443a77/(_0x2c6b95*(_0x3cd610[_0x1230d3(0x366)]()[_0x1230d3(0x2e8)]||0x1))*0x64)):0x0;_0x2c3018=_0x246a31,_0x29fff9=_0x3fbd90;const _0x53753b=process['memoryUsage']();let _0x1bc270=null;try{_0x1bc270=_0x4241ee[_0x1230d3(0x553)]?.[_0x1230d3(0x3c6)]?_0x4241ee[_0x1230d3(0x5d0)]?.[_0x1230d3(0x4a4)]?.()??null:null;}catch{}try{process[_0x1230d3(0x50a)]({[_0x2ad969]:_0x544df2,'stats':{'rss':_0x53753b[_0x1230d3(0x131)],'heapUsed':_0x53753b['heapUsed'],'heapTotal':_0x53753b[_0x1230d3(0x3c3)],'external':_0x53753b['external'],'cpuPct':_0x8b7a11,'cpuWindowMs':Math[_0x1230d3(0x38d)](_0x2c6b95/0x3e8)||null},'processing':_0x1bc270});}catch{}},_0x3d8073=Math[_0x479098(0x608)](0x3e8,Number(process.env.OKDB_STATS_INTERVAL_MS)||0x1388),_0x29d539=setInterval(_0x1662c9,_0x3d8073);_0x29d539[_0x479098(0x575)]?.(),_0x1662c9();for(const _0x30bee9 of[_0x479098(0x2bf),_0x479098(0x186)]){_0x4241ee[_0x479098(0x599)]?.['on']?.(_0x30bee9,()=>{try{_0x1662c9();}catch{}});}}let _0x1183a3=![];const _0x24ced6=async _0x2c5627=>{const _0x4c7995=_0x479098;if(_0x1183a3)return;_0x1183a3=!![];const _0x2579eb=setTimeout(()=>process[_0x4c7995(0x2e9)](_0x2c5627),_0x54c289);_0x2579eb[_0x4c7995(0x575)]?.();try{await _0x4241ee[_0x4c7995(0x57b)]?.();}catch{}process[_0x4c7995(0x2e9)](_0x2c5627);};process['on'](_0x479098(0x23f),()=>_0x24ced6(0x0));if(process[_0x479098(0x50a)]&&!process[_0x479098(0x22d)])_0x24ced6(0x0);if(process[_0x479098(0x6af)]!=='win32'){const _0x26bac7=setInterval(()=>{if(process['ppid']===0x1)_0x24ced6(0x0);},_0x3d8268);_0x26bac7[_0x479098(0x575)]?.(),_0x4241ee[_0x479098(0x298)]=_0x26bac7;}}return okdbCluster={'runClustered':_0x5edf4c,'attachWorkerCluster':_0x280f55},okdbCluster;}var okdbHttp={'exports':{}},okdbMetrics,hasRequiredOkdbMetrics;function requireOkdbMetrics(){const _0x4a5b00=_0x1cb9ed;if(hasRequiredOkdbMetrics)return okdbMetrics;hasRequiredOkdbMetrics=0x1;const _0x2e1c02=0x3c;function _0x4c5560(){return{'requests':0x0,'reads':0x0,'writes':0x0,'errors':0x0,'readMs':0x0,'writeMs':0x0};}class _0x14ffe0{constructor(){const _0x3f72d4=_0x4ed4;this[_0x3f72d4(0x6c3)]=0x0,this[_0x3f72d4(0x53f)]=0x0,this[_0x3f72d4(0x2cf)]=0x0,this['_totalErrors']=0x0,this['_totalReadMs']=0x0,this[_0x3f72d4(0x149)]=0x0,this[_0x3f72d4(0x7a3)]=Array[_0x3f72d4(0x16b)]({'length':_0x2e1c02},_0x4c5560),this[_0x3f72d4(0x213)]=0x0,this[_0x3f72d4(0x3df)]=Date[_0x3f72d4(0x6f1)](),this[_0x3f72d4(0x295)]=setInterval(()=>this[_0x3f72d4(0x771)](),0x3e8);if(this['_timer'][_0x3f72d4(0x575)])this[_0x3f72d4(0x295)][_0x3f72d4(0x575)]();}[_0x4a5b00(0x771)](){const _0x48cf98=_0x4a5b00;this['_bucketIdx']=(this[_0x48cf98(0x213)]+0x1)%_0x2e1c02,this[_0x48cf98(0x7a3)][this['_bucketIdx']]=_0x4c5560(),this[_0x48cf98(0x3df)]=Date[_0x48cf98(0x6f1)]();}[_0x4a5b00(0x338)](_0x3f92ea,_0x57a855,_0x2621e2){const _0x3c6ea6=_0x4a5b00,_0x1b9524=/^(POST|PUT|PATCH|DELETE)$/i['test'](_0x3f92ea),_0xce0dbb=this[_0x3c6ea6(0x7a3)][this['_bucketIdx']];this[_0x3c6ea6(0x6c3)]++,_0xce0dbb[_0x3c6ea6(0x393)]++,_0x2621e2&&(this['_totalErrors']++,_0xce0dbb[_0x3c6ea6(0x6d)]++),_0x1b9524?(this[_0x3c6ea6(0x2cf)]++,this['_totalWriteMs']+=_0x57a855,_0xce0dbb[_0x3c6ea6(0x117)]++,_0xce0dbb['writeMs']+=_0x57a855):(this[_0x3c6ea6(0x53f)]++,this[_0x3c6ea6(0x6fd)]+=_0x57a855,_0xce0dbb[_0x3c6ea6(0x29e)]++,_0xce0dbb[_0x3c6ea6(0x4fe)]+=_0x57a855);}[_0x4a5b00(0x665)](){const _0x130fe1=_0x4a5b00;let _0x1e1894=0x0,_0x8f18b=0x0,_0xe0de74=0x0,_0x3998d4=0x0,_0x3a25d5=0x0,_0x6a2355=0x0;for(const _0x554b6d of this['_buckets']){_0x1e1894+=_0x554b6d[_0x130fe1(0x393)],_0x8f18b+=_0x554b6d[_0x130fe1(0x29e)],_0xe0de74+=_0x554b6d[_0x130fe1(0x117)],_0x3998d4+=_0x554b6d['errors'],_0x3a25d5+=_0x554b6d[_0x130fe1(0x4fe)],_0x6a2355+=_0x554b6d['writeMs'];}const _0x231273=_0x2e1c02;return{'lifetime':{'requests':this[_0x130fe1(0x6c3)],'reads':this['_totalReads'],'writes':this[_0x130fe1(0x2cf)],'errors':this['_totalErrors'],'avgReadMs':this[_0x130fe1(0x53f)]>0x0?+(this['_totalReadMs']/this[_0x130fe1(0x53f)])[_0x130fe1(0x12a)](0x2):null,'avgWriteMs':this[_0x130fe1(0x2cf)]>0x0?+(this[_0x130fe1(0x149)]/this[_0x130fe1(0x2cf)])[_0x130fe1(0x12a)](0x2):null},'window':{'seconds':_0x231273,'requests':_0x1e1894,'reads':_0x8f18b,'writes':_0xe0de74,'errors':_0x3998d4,'reqPerSec':+(_0x1e1894/_0x231273)[_0x130fe1(0x12a)](0x2),'readPerSec':+(_0x8f18b/_0x231273)[_0x130fe1(0x12a)](0x2),'writePerSec':+(_0xe0de74/_0x231273)['toFixed'](0x2),'avgReadMs':_0x8f18b>0x0?+(_0x3a25d5/_0x8f18b)[_0x130fe1(0x12a)](0x2):null,'avgWriteMs':_0xe0de74>0x0?+(_0x6a2355/_0xe0de74)[_0x130fe1(0x12a)](0x2):null}};}[_0x4a5b00(0x57b)](){const _0x1e5faa=_0x4a5b00;clearInterval(this[_0x1e5faa(0x295)]);}}return okdbMetrics=_0x14ffe0,okdbMetrics;}var okdbAuthNamespaces,hasRequiredOkdbAuthNamespaces;function requireOkdbAuthNamespaces(){const _0x4b94c0=_0x1cb9ed;if(hasRequiredOkdbAuthNamespaces)return okdbAuthNamespaces;hasRequiredOkdbAuthNamespaces=0x1;const _0x34d539={'data':{'label':_0x4b94c0(0x72f),'scope':'env','description':_0x4b94c0(0x33a),'operations':{'read':{'label':_0x4b94c0(0x4eb),'summary':_0x4b94c0(0x71c)},'write':{'label':_0x4b94c0(0x3cf),'summary':_0x4b94c0(0x35f)}}},'schema':{'label':_0x4b94c0(0x2c4),'scope':_0x4b94c0(0x514),'description':_0x4b94c0(0x462),'operations':{'read':{'label':_0x4b94c0(0x4eb),'summary':'List\x20types,\x20get\x20type\x20schema,\x20list\x20registered\x20indexes.'},'write':{'label':_0x4b94c0(0x3cf),'summary':_0x4b94c0(0x3ef)}}},'search':{'label':'Search','scope':_0x4b94c0(0x514),'description':_0x4b94c0(0x39b),'operations':{'query':{'label':_0x4b94c0(0x477),'summary':_0x4b94c0(0x545)}}},'queue':{'label':_0x4b94c0(0xe2),'scope':'env','description':'Background\x20job\x20queue:\x20enqueue\x20work,\x20observe\x20state,\x20and\x20process\x20jobs.','operations':{'read':{'label':_0x4b94c0(0x4eb),'summary':_0x4b94c0(0x6aa)},'write':{'label':_0x4b94c0(0x3cf),'summary':_0x4b94c0(0x414)},'work':{'label':'Work','summary':_0x4b94c0(0x717)}}},'files':{'label':_0x4b94c0(0x623),'scope':_0x4b94c0(0x514),'description':'Blob\x20storage:\x20large\x20file\x20uploads\x20attached\x20to\x20records\x20or\x20stored\x20standalone.','operations':{'read':{'label':_0x4b94c0(0x4eb),'summary':_0x4b94c0(0x3a5)},'write':{'label':_0x4b94c0(0x3cf),'summary':_0x4b94c0(0x65c)}}},'functions':{'label':'Functions','scope':'env','description':_0x4b94c0(0x622),'operations':{'read':{'label':_0x4b94c0(0x4eb),'summary':_0x4b94c0(0x357)},'write':{'label':_0x4b94c0(0x3cf),'summary':_0x4b94c0(0x564)},'run':{'label':_0x4b94c0(0x560),'summary':_0x4b94c0(0x159)}}},'views':{'label':_0x4b94c0(0x2fa),'scope':_0x4b94c0(0x514),'description':_0x4b94c0(0x664),'operations':{'read':{'label':_0x4b94c0(0x4eb),'summary':_0x4b94c0(0x2f1)},'write':{'label':_0x4b94c0(0x3cf),'summary':'Create\x20and\x20delete\x20views,\x20start,\x20stop,\x20and\x20rebuild\x20them.'}}},'env':{'label':_0x4b94c0(0x420),'scope':_0x4b94c0(0x514),'description':_0x4b94c0(0x2e0),'operations':{'read':{'label':'Read','summary':_0x4b94c0(0x141)},'write':{'label':'Write','summary':_0x4b94c0(0x654)}}},'auth':{'label':_0x4b94c0(0x636),'scope':_0x4b94c0(0x374),'description':_0x4b94c0(0x534),'operations':{'read':{'label':_0x4b94c0(0x4eb),'summary':_0x4b94c0(0x2e5)},'write':{'label':'Write','summary':_0x4b94c0(0x258)}}},'system':{'label':_0x4b94c0(0x5bb),'scope':'system','description':_0x4b94c0(0x17e),'operations':{'read':{'label':_0x4b94c0(0x4eb),'summary':_0x4b94c0(0x2b0)},'write':{'label':_0x4b94c0(0x3cf),'summary':_0x4b94c0(0x1f6)}}},'sync':{'label':_0x4b94c0(0x726),'scope':'system','description':_0x4b94c0(0xd8),'operations':{'read':{'label':_0x4b94c0(0x4eb),'summary':_0x4b94c0(0x565)},'write':{'label':_0x4b94c0(0x3cf),'summary':_0x4b94c0(0x3b9)},'peer':{'label':'Peer','summary':'Machine-to-machine\x20cluster\x20protocol\x20(join\x20handshake,\x20replication\x20channel,\x20traffic).\x20Grant\x20only\x20to\x20peer\x20nodes\x20—\x20not\x20to\x20humans.','machineOnly':!![]}}},'protected':{'label':'Protected\x20(gate)','scope':_0x4b94c0(0x5d6),'description':_0x4b94c0(0x3eb),'operations':{'read':{'label':_0x4b94c0(0x4eb),'summary':'May\x20read\x20system\x20types\x20when\x20also\x20granted\x20the\x20underlying\x20read\x20permission.'},'write':{'label':_0x4b94c0(0x3cf),'summary':_0x4b94c0(0x4ae)}}}},_0x5e30a9={'schema:read':[_0x4b94c0(0x6e7),_0x4b94c0(0x4ff),_0x4b94c0(0x12f)]},_0x276ac3=[_0x4b94c0(0x392),_0x4b94c0(0x1b1),_0x4b94c0(0x185),_0x4b94c0(0xc6),_0x4b94c0(0x5a7),_0x4b94c0(0x714)];function _0x49a4d4(){const _0x5779cc=_0x4b94c0,_0x6b1b8=[];for(const [_0x5e6e08,_0x768752]of Object[_0x5779cc(0x377)](_0x34d539)){for(const _0x4667c4 of Object[_0x5779cc(0x449)](_0x768752['operations'])){_0x6b1b8['push'](_0x5e6e08+':'+_0x4667c4);}}return _0x6b1b8;}function _0x5ddb6d(_0x502b95){return _0x34d539[_0x502b95]||null;}function _0x29aae9(_0x14cc31,_0xa6ae92){const _0x1295d6=_0x4b94c0;return _0x34d539[_0x14cc31]?.[_0x1295d6(0x231)][_0xa6ae92]||null;}return okdbAuthNamespaces={'NAMESPACES':_0x34d539,'IMPLIED_BY':_0x5e30a9,'OP_ORDER':_0x276ac3,'listAllPermissions':_0x49a4d4,'getNamespaceMeta':_0x5ddb6d,'getOperationMeta':_0x29aae9},okdbAuthNamespaces;}var okdbAuthPermissions,hasRequiredOkdbAuthPermissions;function requireOkdbAuthPermissions(){const _0x5621ed=_0x1cb9ed;if(hasRequiredOkdbAuthPermissions)return okdbAuthPermissions;hasRequiredOkdbAuthPermissions=0x1;const {IMPLIED_BY:_0x2415ec}=requireOkdbAuthNamespaces(),_0x7bdbfb=new Set([_0x5621ed(0x392),_0x5621ed(0x1b1)]);function _0x37baad(_0x4f3114,_0x482d06){const _0x5abac3=_0x5621ed;if(!Array[_0x5abac3(0x259)](_0x4f3114)||_0x4f3114['length']===0x0)return![];for(const _0x3de07b of _0x4f3114){if(typeof _0x3de07b!==_0x5abac3(0x139)||!_0x3de07b[_0x5abac3(0x243)](':')){if(_0x3de07b==='*')return!![];continue;}const [_0x1cadb5,_0x448254]=_0x3de07b['split'](':'),[_0x33aa0b,_0x4cef3a]=_0x482d06[_0x5abac3(0x527)](':'),_0x5a69f4=_0x1cadb5==='*'||_0x1cadb5===_0x33aa0b,_0x2863f1=_0x448254==='*'||_0x448254===_0x4cef3a;if(_0x5a69f4&&_0x2863f1)return!![];}const _0x27198e=_0x2415ec[_0x482d06];if(_0x27198e)for(const _0xf7d9bd of _0x27198e){if(_0x37baad(_0x4f3114,_0xf7d9bd))return!![];}return![];}function _0x395504(_0x1d9efc,_0x34e6a3){const _0x2c55de=_0x5621ed,_0x5889a7=new Set();if(Array[_0x2c55de(0x259)](_0x1d9efc)){for(const _0x4e42f1 of _0x1d9efc)_0x5889a7[_0x2c55de(0x5f3)](_0x4e42f1);}if(Array[_0x2c55de(0x259)](_0x34e6a3)){for(const _0xe1473d of _0x34e6a3)_0x5889a7['add'](_0xe1473d);}return Array[_0x2c55de(0x16b)](_0x5889a7);}function _0x20567e(_0x37c638){const _0x4d59ce=_0x5621ed;if(typeof _0x37c638!==_0x4d59ce(0x139))return![];const [,_0x2fd850]=_0x37c638[_0x4d59ce(0x527)](':');return _0x7bdbfb[_0x4d59ce(0x783)](_0x2fd850);}function _0x55a5cd(_0x3555db){const _0x1372a8=_0x5621ed;return _0x20567e(_0x3555db)?_0x1372a8(0x193):_0x1372a8(0x4f9);}function _0x1e2ed9(_0x4a340e,_0xc13b45){const _0x40a265=_0x5621ed;return _0x395504(_0x4a340e[_0x40a265(0x75a)]||[],_0xc13b45?(_0x4a340e['grants']||{})[_0xc13b45]||[]:[]);}function _0x5af6a9(_0x2cceca){const _0x5ad8bf=_0x5621ed,_0x340a6e=[];for(const _0x51f042 of _0x2cceca[_0x5ad8bf(0x3c7)]()){const _0x4399c7=_0x51f042[_0x5ad8bf(0x658)]?.[_0x5ad8bf(0x2d6)];if(!_0x4399c7)continue;_0x4399c7[_0x5ad8bf(0x5e5)]&&!_0x4399c7[_0x5ad8bf(0x1d8)]&&_0x340a6e['push'](_0x51f042[_0x5ad8bf(0x3f2)]+'\x20'+_0x51f042[_0x5ad8bf(0x2cc)]+_0x5ad8bf(0x203)+(_0x51f042['operation']['id']??'?')+')');}if(_0x340a6e['length'])throw new Error(_0x5ad8bf(0x6dc)+_0x340a6e[_0x5ad8bf(0x546)](_0x5ad8bf(0xce)));}return okdbAuthPermissions={'hasPermission':_0x37baad,'unionPermissions':_0x395504,'isReadOperation':_0x20567e,'resolveProtectedGate':_0x55a5cd,'getEffectivePermissions':_0x1e2ed9,'assertEveryRouteHasPermission':_0x5af6a9},okdbAuthPermissions;}var okdbJwtUtils,hasRequiredOkdbJwtUtils;function requireOkdbJwtUtils(){if(hasRequiredOkdbJwtUtils)return okdbJwtUtils;hasRequiredOkdbJwtUtils=0x1;const _0x29a22d=require$$0$7,_0x13ff90=require$$1$2,_0x192fee=require$$2$1;function _0x82af89(_0x3b4ee1){const _0x56623b=_0x4ed4,_0x36e4ff=String(_0x3b4ee1||'')[_0x56623b(0x61f)](/-/g,'+')[_0x56623b(0x61f)](/_/g,'/'),_0x3d1ae5=_0x36e4ff+'='[_0x56623b(0x32c)]((0x4-(_0x36e4ff[_0x56623b(0x2e8)]%0x4||0x4))%0x4);return Buffer[_0x56623b(0x16b)](_0x3d1ae5,_0x56623b(0x13a));}function _0x520a73(_0xb0027f){const _0x2be31c=_0x4ed4;if(typeof _0xb0027f!==_0x2be31c(0x139))throw new Error(_0x2be31c(0x239));const _0x5c860f=_0xb0027f['split']('.');if(_0x5c860f[_0x2be31c(0x2e8)]!==0x3)throw new Error('Token\x20must\x20be\x20a\x20JWT');const [_0x7116f0,_0x540179,_0x55b637]=_0x5c860f,_0x39ea78=JSON['parse'](_0x82af89(_0x7116f0)[_0x2be31c(0x3cb)](_0x2be31c(0x84))),_0x55ecf7=JSON[_0x2be31c(0x110)](_0x82af89(_0x540179)[_0x2be31c(0x3cb)]('utf8'));return{'header':_0x39ea78,'payload':_0x55ecf7,'signature':_0x82af89(_0x55b637),'signingInput':Buffer[_0x2be31c(0x16b)](_0x7116f0+'.'+_0x540179),'encodedHeader':_0x7116f0,'encodedPayload':_0x540179};}function _0x537b66(_0x492e2c){const _0x4db3b8=_0x4ed4;if(Array[_0x4db3b8(0x259)](_0x492e2c))return _0x492e2c;if(_0x492e2c==null)return[];return[_0x492e2c];}function _0x3051a4(_0xa51c46){const _0x5dc218=_0x4ed4,_0x7f77f2=String(_0xa51c46||'')[_0x5dc218(0xbd)](/.{1,64}/g)||[];return'-----BEGIN\x20CERTIFICATE-----\x0a'+_0x7f77f2[_0x5dc218(0x546)]('\x0a')+_0x5dc218(0x6b6);}function _0x52cb33(_0x59c121={}){const _0x309a75=_0x4ed4;if(_0x59c121[_0x309a75(0x1c7)]?.[0x0])return _0x192fee[_0x309a75(0x2a8)](_0x3051a4(_0x59c121[_0x309a75(0x1c7)][0x0]));return _0x192fee[_0x309a75(0x2a8)]({'key':_0x59c121,'format':_0x309a75(0x723)});}function _0x2d0f71(_0x5501e0,_0x3db97e,_0x669029,_0x4f7da3){const _0x13e329=_0x4ed4;if(_0x5501e0==='RS256')return _0x192fee[_0x13e329(0x642)](_0x13e329(0x232),_0x669029,_0x3db97e,_0x4f7da3);if(_0x5501e0===_0x13e329(0x119))return _0x192fee['verify'](_0x13e329(0x42f),_0x669029,{'key':_0x3db97e,'dsaEncoding':'ieee-p1363'},_0x4f7da3);return![];}function _0x4f0572(_0x3c2d94){const _0x2c6c44=_0x4ed4;if(typeof commonjsGlobal[_0x2c6c44(0x4c8)]==='function')return commonjsGlobal[_0x2c6c44(0x4c8)](_0x3c2d94,{'headers':{'accept':'application/json'}})[_0x2c6c44(0x257)](async _0x25ca24=>{const _0x3abbe9=_0x2c6c44;if(!_0x25ca24['ok']){const _0x32542d=new Error(_0x3abbe9(0x329)+_0x25ca24['status']+'\x20fetching\x20'+_0x3c2d94);_0x32542d[_0x3abbe9(0x469)]=_0x25ca24[_0x3abbe9(0x469)];throw _0x32542d;}return _0x25ca24[_0x3abbe9(0x70c)]();});return new Promise((_0x464720,_0x12e623)=>{const _0x2d89d6=_0x2c6c44,_0x466572=String(_0x3c2d94)[_0x2d89d6(0x557)](_0x2d89d6(0x3bf))?_0x13ff90:_0x29a22d,_0xf9a8e9=_0x466572[_0x2d89d6(0x741)](_0x3c2d94,{'headers':{'accept':'application/json'}},_0x310eb5=>{const _0x517ab0=_0x2d89d6;let _0x24dfc5='';_0x310eb5[_0x517ab0(0xc1)](_0x517ab0(0x84)),_0x310eb5['on'](_0x517ab0(0x516),_0x1dd1f2=>{_0x24dfc5+=_0x1dd1f2;}),_0x310eb5['on']('end',()=>{const _0x53b29c=_0x517ab0;if(_0x310eb5['statusCode']<0xc8||_0x310eb5[_0x53b29c(0x1db)]>=0x12c){const _0x21e314=new Error(_0x53b29c(0x329)+_0x310eb5[_0x53b29c(0x1db)]+_0x53b29c(0x5dc)+_0x3c2d94);return _0x21e314[_0x53b29c(0x469)]=_0x310eb5[_0x53b29c(0x1db)],_0x12e623(_0x21e314);}try{_0x464720(JSON['parse'](_0x24dfc5||'{}'));}catch(_0xda4486){_0x12e623(_0xda4486);}});});_0xf9a8e9['on']('error',_0x12e623),_0xf9a8e9[_0x2d89d6(0x1a0)]();});}return okdbJwtUtils={'base64UrlDecode':_0x82af89,'parseJwt':_0x520a73,'normalizeAudience':_0x537b66,'normalizePemCertificate':_0x3051a4,'jwkToKeyObject':_0x52cb33,'verifyJwtSignature':_0x2d0f71,'fetchJson':_0x4f0572},okdbJwtUtils;}var hasRequiredOkdbHttp;function requireOkdbHttp(){const _0x41a5d4=_0x1cb9ed;if(hasRequiredOkdbHttp)return okdbHttp[_0x41a5d4(0x761)];hasRequiredOkdbHttp=0x1;const _0x53184a=require$$0$7,{URL:_0x210255}=require$$2$2,_0x491fed=requireOkdbMetrics(),_0x235110=requireOkdbAuthTokens(),{hasPermission:_0x473867,unionPermissions:_0x4434e2,resolveProtectedGate:_0x491f52}=requireOkdbAuthPermissions(),_0x6b95cb={0x190:_0x41a5d4(0x308),0x191:_0x41a5d4(0x757),0x193:'FORBIDDEN',0x194:_0x41a5d4(0x6a7),0x195:'METHOD_NOT_ALLOWED',0x198:_0x41a5d4(0x57d),0x199:_0x41a5d4(0x2e7),0x19a:_0x41a5d4(0xf4),0x19b:_0x41a5d4(0x2d1),0x19d:_0x41a5d4(0x42b),0x19f:_0x41a5d4(0x29b),0x1a6:_0x41a5d4(0x619),0x1ad:_0x41a5d4(0x4b0),0x1f4:_0x41a5d4(0x5c5),0x1f5:'NOT_IMPLEMENTED',0x1f6:_0x41a5d4(0x2e3),0x1f7:_0x41a5d4(0x2ca),0x1f8:_0x41a5d4(0x419)},_0x47923a={'INVALID_VALUE':0x190,'BAD_CONFIG':0x190,'INVALID_PRIMARY_KEY':0x190,'INVALID_INDEX_KEY':0x190,'TYPE_NOT_REGISTERED':0x194,'INDEX_NOT_REGISTERED':0x194,'NOT_FOUND':0x194,'ALREADY_EXISTS':0x199,'VERSION_MISMATCH':0x199,'UNIQUE_CONSTRAINT':0x199,'TYPE_ALREADY_REGISTERED':0x199,'INDEX_ALREADY_REGISTERED':0x199,'FK_ERROR':0x199,'FK_DELETE_ERROR':0x199,'FOREIGN_KEY_VIOLATION':0x199,'FOREIGN_KEY_DELETE_RESTRICTED':0x199,'ENV_NOT_FOUND':0x194,'ENV_PROTECTED':0x193,'ENGINE_CONFIG_PATCH_UNSUPPORTED':0x190,'QUEUE_WORKER_JOB_TYPE_CONFLICT':0x199,'SCHEMA_VALIDATION_FAILED':0x1a6,'SCHEMA_COLLECTION_INVALID':0x199,'INVALID_SCHEMA':0x190,'QUERY_OPERATOR_FORBIDDEN':0x190,'BUCKET_CONFIG_INVALID':0x190,'BUCKET_INVALID_TIME_VALUE':0x1a6,'BUCKET_PROJECT_NOT_PERSISTABLE':0x190,'BUCKET_PROJECT_UNKNOWN':0x190,'VIEW_UNKNOWN_REDUCER':0x190,'RESERVED_VIEW_NAME':0x190,'VIEW_NOT_BUCKETED':0x190,'VIEW_NOT_FOUND':0x194,'VIEW_RANGE_GRANULARITY_MISMATCH':0x190,'VIEW_RANGE_GRANULARITY_REQUIRED':0x190,'VIEW_REF_UNSUPPORTED_REDUCER':0x190},{hmac:_0xb1f799,timingSafeEqual:_0x3df55b,parseBearer:_0x469164,randomToken:_0x4953b5,issueToken:_0x32466d,authenticateToken:_0x3657fa}=_0x235110,{base64UrlDecode:_0x3d4cd6,parseJwt:_0x30383a,normalizeAudience:_0x3f4984,normalizePemCertificate:_0x2fd607,jwkToKeyObject:_0x45bbce,verifyJwtSignature:_0x36d463,fetchJson:_0x4880ac}=requireOkdbJwtUtils();function _0x53e271(_0x181422){const _0x4c0608=_0x41a5d4;return(_0x181422||'GET')[_0x4c0608(0x731)]();}function _0x442106(_0xcb6777){const _0x2b63b4=_0x41a5d4;if(Array[_0x2b63b4(0x259)](_0xcb6777))return _0xcb6777[_0x2b63b4(0x4de)](_0x442106);return String(_0xcb6777||'')[_0x2b63b4(0x527)](',')[_0x2b63b4(0x362)](_0x3aaaec=>_0x3aaaec[_0x2b63b4(0x220)]())['filter'](Boolean);}function _0x849516(..._0xca676a){const _0x347c63=_0x41a5d4;return[...new Set(_0xca676a[_0x347c63(0x4de)](_0x442106))][_0x347c63(0x546)](',\x20');}function _0x1f64de(_0xcb640c,_0x4e166c){const _0x328817=_0x41a5d4;if(!_0xcb640c)return![];if(_0x4e166c==='*')return!![];if(_0x4e166c instanceof RegExp)return _0x4e166c[_0x328817(0x86)](_0xcb640c);if(typeof _0x4e166c===_0x328817(0x18e))return!!_0x4e166c(_0xcb640c);if(Array[_0x328817(0x259)](_0x4e166c))return _0x4e166c[_0x328817(0x243)](_0xcb640c);return _0x4e166c===_0xcb640c;}function _0x2cdc9c(_0x1e0d23={},_0x31c32c={},_0x5351a4=null){const _0x4325da=_0x41a5d4;if(!_0x31c32c)return null;const _0x2a69a9=_0x1e0d23['origin'],_0x10b6fb=_0x31c32c[_0x4325da(0x2d7)]??_0x31c32c[_0x4325da(0x52d)]??'*',_0x3ec759=_0x10b6fb==='*'?'*':_0x1f64de(_0x2a69a9,_0x10b6fb)?_0x2a69a9:null;if(!_0x3ec759)return null;const _0x4a3048=_0x1e0d23[_0x4325da(0x44c)],_0x3de12a=_0x31c32c[_0x4325da(0x106)]??_0x31c32c['allowHeaders']??['content-type',_0x4325da(0x5cb),_0x4325da(0x173),_0x4325da(0x160),_0x4325da(0x129)],_0x446648=_0x31c32c[_0x4325da(0x289)]??_0x31c32c[_0x4325da(0x1dc)]??(_0x5351a4?[_0x5351a4,_0x4325da(0x76b)]:[_0x4325da(0x19e),_0x4325da(0x6df),_0x4325da(0x76b)]),_0x5463ed=_0x31c32c[_0x4325da(0xb5)]??['mcp-session-id'],_0x2665dd={'access-control-allow-origin':_0x3ec759,'access-control-allow-methods':Array['isArray'](_0x446648)?_0x446648[_0x4325da(0x546)](',\x20'):String(_0x446648),'access-control-allow-headers':_0x4a3048?_0x849516(_0x3de12a,_0x4a3048):Array[_0x4325da(0x259)](_0x3de12a)?_0x3de12a[_0x4325da(0x546)](',\x20'):String(_0x3de12a),'access-control-expose-headers':Array[_0x4325da(0x259)](_0x5463ed)?_0x5463ed[_0x4325da(0x546)](',\x20'):String(_0x5463ed),'vary':_0x849516(_0x4325da(0x41f),_0x3ec759==='*'?'':_0x4325da(0x41f),_0x4a3048?_0x4325da(0x481):'')};if(_0x31c32c[_0x4325da(0x3dd)])_0x2665dd['access-control-allow-credentials']=_0x4325da(0x509);if(Number['isFinite'](_0x31c32c[_0x4325da(0x457)]))_0x2665dd[_0x4325da(0x400)]=String(_0x31c32c[_0x4325da(0x457)]);return _0x2665dd;}function _0x2e4f19(_0xab3d7f){const _0x39ee09=_0x41a5d4,_0x1ebbf7=[],_0x58b3fe={};let _0x219f74=![];_0xab3d7f[_0x39ee09(0x675)]('/*')&&(_0x219f74=!![],_0xab3d7f=_0xab3d7f[_0x39ee09(0x762)](0x0,-0x2),_0x1ebbf7['push']('*'));let _0x1c8fd2=_0xab3d7f[_0x39ee09(0x61f)](/\/+$/,'')[_0x39ee09(0x61f)](/\[([^\]]*)\]/g,(_0x27dae8,_0x4c0490)=>{const _0x3b1256=_0x39ee09,_0x169aad=_0x4c0490[_0x3b1256(0x61f)](/\/:(\w+)(?:=([^/\]\s]*))?/g,(_0x571bdf,_0x35433f,_0x19cd6b)=>{const _0x3981d3=_0x3b1256;_0x1ebbf7[_0x3981d3(0x1c2)](_0x35433f);if(_0x19cd6b!==undefined)_0x58b3fe[_0x35433f]=_0x19cd6b;return'/([^/]+)';});return'(?:'+_0x169aad+')?';})[_0x39ee09(0x61f)](/\/:(\w+)/g,(_0x375476,_0x31d0fc)=>{const _0x23d048=_0x39ee09;return _0x1ebbf7[_0x23d048(0x1c2)](_0x31d0fc),_0x23d048(0x44e);});if(_0x1c8fd2==='')_0x1c8fd2='/';return{'keys':_0x1ebbf7,'defaults':_0x58b3fe,'wildcard':_0x219f74,'regex':new RegExp(_0x219f74?'^'+_0x1c8fd2+_0x39ee09(0xaf):'^'+_0x1c8fd2+'$')};}function _0x4a84e0(_0x3ca47d){const _0x30ec7d=_0x41a5d4;if(_0x3ca47d==null)return _0x3ca47d;return JSON[_0x30ec7d(0x110)](JSON[_0x30ec7d(0x5bd)](_0x3ca47d));}function _0x2c898d(_0x22375f){const _0x88e72a=_0x41a5d4;if(_0x22375f==null)return null;if(_0x22375f[_0x88e72a(0x5be)]===_0x88e72a(0x25a)&&_0x22375f[_0x88e72a(0x77d)]&&!Array[_0x88e72a(0x259)](_0x22375f['properties']))return _0x4a84e0(_0x22375f);const _0x138867=Object['values'](_0x22375f),_0x221c7d=_0x138867[_0x88e72a(0x2e8)]>0x0&&_0x138867[_0x88e72a(0x6a5)](_0x372a93=>{const _0x69cfb7=_0x88e72a;return _0x372a93&&typeof _0x372a93==='object'&&!Array['isArray'](_0x372a93)&&(Object[_0x69cfb7(0x62f)]['hasOwnProperty'][_0x69cfb7(0x70d)](_0x372a93,'type')||Object['prototype'][_0x69cfb7(0x34a)][_0x69cfb7(0x70d)](_0x372a93,_0x69cfb7(0x77d))||Object['prototype'][_0x69cfb7(0x34a)][_0x69cfb7(0x70d)](_0x372a93,_0x69cfb7(0x464))||Object['prototype'][_0x69cfb7(0x34a)][_0x69cfb7(0x70d)](_0x372a93,'default'));});if(_0x221c7d)return{'type':'object','properties':_0x4a84e0(_0x22375f),'required':[],'additionalProperties':![]};const _0x3f4fa4={},_0x2d045a=[];for(const [_0x431b4f,_0x4fd9e7]of Object[_0x88e72a(0x377)](_0x22375f)){_0x3f4fa4[_0x431b4f]=_0x3d9d48(_0x4fd9e7);if(_0x4fd9e7!==null&&_0x4fd9e7!==undefined)_0x2d045a['push'](_0x431b4f);}return{'type':_0x88e72a(0x25a),'properties':_0x3f4fa4,'required':_0x2d045a,'additionalProperties':![]};}function _0x3d9d48(_0x52e999){const _0xf2e62b=_0x41a5d4;if(_0x52e999===null)return{'type':[_0xf2e62b(0x5d2),_0xf2e62b(0x139),_0xf2e62b(0x3f5),_0xf2e62b(0x610),'object','array']};if(Array['isArray'](_0x52e999))return{'type':_0xf2e62b(0x632),'items':_0x52e999[_0xf2e62b(0x2e8)]>0x0?_0x3d9d48(_0x52e999[0x0]):{}};switch(typeof _0x52e999){case'string':return{'type':_0xf2e62b(0x139),'default':_0x52e999};case _0xf2e62b(0x3f5):return{'type':Number[_0xf2e62b(0x390)](_0x52e999)?_0xf2e62b(0x19c):_0xf2e62b(0x3f5),'default':_0x52e999};case _0xf2e62b(0x610):return{'type':_0xf2e62b(0x610),'default':_0x52e999};case _0xf2e62b(0x25a):{const _0x295013={};for(const [_0x2b9bcc,_0x1519b1]of Object[_0xf2e62b(0x377)](_0x52e999))_0x295013[_0x2b9bcc]=_0x3d9d48(_0x1519b1);return{'type':_0xf2e62b(0x25a),'properties':_0x295013,'additionalProperties':!![],'default':_0x4a84e0(_0x52e999)};}default:return{};}}function _0x14f076(_0x52934d,_0x5a3195){const _0x3cf36a=_0x41a5d4,_0x355dbc=[];for(const _0x59e2bf of _0x5a3195[_0x3cf36a(0x449)]){if(_0x59e2bf==='*')continue;_0x355dbc['push']({'name':_0x59e2bf,'required':!Object[_0x3cf36a(0x62f)]['hasOwnProperty']['call'](_0x5a3195['defaults'],_0x59e2bf),'default':_0x5a3195['defaults'][_0x59e2bf]});}return _0x355dbc;}function _0x2a426e(_0xbd8c27={},_0x5a1a2d){const _0x35538f=_0x41a5d4,_0x1d1f8a=_0x2c898d(_0xbd8c27[_0x35538f(0x1be)]?.[_0x35538f(0x786)]??_0xbd8c27[_0x35538f(0x1b1)]??null),_0x995566=_0xbd8c27[_0x35538f(0x1be)]?.[_0x35538f(0x436)]??(_0xbd8c27[_0x35538f(0x770)]?_0x35538f(0x770):_0x5a1a2d['method']===_0x35538f(0x19e)||_0x5a1a2d[_0x35538f(0x3f2)]===_0x35538f(0x2d2)?_0x35538f(0x1a8):_0x35538f(0x572));return{'querySchema':_0x1d1f8a,'bodyMode':_0x995566,'bindings':_0x4a84e0(_0xbd8c27['http']?.[_0x35538f(0x5ca)]??{}),'statuses':_0x4a84e0(_0xbd8c27[_0x35538f(0x1be)]?.[_0x35538f(0x33b)]??(_0xbd8c27['responseStatuses']||[])),'transport':_0xbd8c27['http']?.['transport']??(_0xbd8c27[_0x35538f(0x4ad)]?_0x35538f(0x4ad):_0xbd8c27[_0x35538f(0x770)]?_0x35538f(0x770):_0x35538f(0x561)),'rawResponse':_0xbd8c27[_0x35538f(0x1be)]?.['rawResponse']??!!_0xbd8c27[_0x35538f(0x3f4)],'cors':_0x4a84e0(_0xbd8c27[_0x35538f(0x1be)]?.[_0x35538f(0x30f)]??_0xbd8c27['cors']??null)};}function _0xdc6d17(_0x3c8700){const _0x2df798=_0x41a5d4,_0x13c826=_0x3c8700[_0x2df798(0x57f)]||{},_0x2e88f5=_0x14f076(_0x3c8700['path'],_0x3c8700[_0x2df798(0x5ab)]),_0x24356d=!!(_0x13c826['id']||_0x13c826['inputSchema']||_0x13c826[_0x2df798(0x708)]||_0x13c826[_0x2df798(0x1be)]||_0x13c826['mcp']||_0x13c826[_0x2df798(0x5c4)]||_0x13c826[_0x2df798(0x2d6)]||_0x13c826[_0x2df798(0x6b5)]),_0x5591fa=_0x2a426e(_0x13c826,_0x3c8700),_0x4b397d=_0x13c826[_0x2df798(0x2e6)]?_0x4a84e0(_0x13c826[_0x2df798(0x2e6)]):null;return{'id':_0x13c826['id']??null,'summary':_0x13c826[_0x2df798(0x21b)]??null,'description':_0x13c826[_0x2df798(0x689)]??null,'tags':_0x4a84e0(_0x13c826[_0x2df798(0x5f0)]??[]),'category':_0x13c826[_0x2df798(0x754)]??null,'safety':_0x4a84e0(_0x13c826['safety']??null),'access':_0x4a84e0(_0x13c826[_0x2df798(0x2d6)]??null),'inputSchema':_0x4b397d,'outputSchema':_0x4a84e0(_0x13c826['outputSchema']??null),'examples':_0x4a84e0(_0x13c826[_0x2df798(0x67b)]??[]),'pathParams':_0x2e88f5,'http':_0x5591fa,'cli':_0x4a84e0(_0x13c826[_0x2df798(0x5c4)]??null),'mcp':_0x4a84e0(_0x13c826[_0x2df798(0x584)]??null),'legacy':{'params':_0x4a84e0(_0x13c826[_0x2df798(0x58c)]??null),'query':_0x4a84e0(_0x13c826[_0x2df798(0x1b1)]??null),'body':_0x4a84e0(_0x13c826[_0x2df798(0x772)]??null),'response':_0x4a84e0(_0x13c826[_0x2df798(0x2a3)]??null)},'transport':{'raw':!!_0x13c826[_0x2df798(0x770)],'sse':!!_0x13c826[_0x2df798(0x4ad)],'rawResponse':!!_0x13c826[_0x2df798(0x3f4)],'cors':_0x4a84e0(_0x13c826[_0x2df798(0x30f)]??null)},'hasCanonical':_0x24356d};}function _0x3264ba(_0x47d087,_0x4f7ef9){const _0x46b48e=_0x41a5d4;if(!_0x4f7ef9?.[_0x46b48e(0x582)])return;if(!_0x4f7ef9[_0x46b48e(0x2e6)]||_0x4f7ef9[_0x46b48e(0x2e6)][_0x46b48e(0x5be)]!=='object'||!_0x4f7ef9[_0x46b48e(0x2e6)]['properties'])throw new Error('Route\x20'+_0x47d087[_0x46b48e(0x3f2)]+'\x20'+_0x47d087['path']+_0x46b48e(0x6be));const _0x4cecc7=_0x4f7ef9[_0x46b48e(0x2e6)]['properties']||{},_0x42ea9f=new Set(_0x4f7ef9[_0x46b48e(0x2bb)][_0x46b48e(0x362)](_0x2535db=>_0x2535db[_0x46b48e(0x58e)])),_0x314eec=new Set(Object[_0x46b48e(0x449)](_0x4f7ef9[_0x46b48e(0x1be)]?.[_0x46b48e(0x786)]?.[_0x46b48e(0x77d)]||{})),_0x47b657=new Set(Object['keys'](_0x4f7ef9[_0x46b48e(0x1be)]?.[_0x46b48e(0x5ca)]||{}));for(const _0x593de9 of _0x4f7ef9[_0x46b48e(0x2bb)]){if(!_0x4cecc7[_0x593de9[_0x46b48e(0x58e)]])throw new Error(_0x46b48e(0x375)+_0x47d087[_0x46b48e(0x3f2)]+'\x20'+_0x47d087['path']+_0x46b48e(0x2ac)+_0x593de9[_0x46b48e(0x58e)]);}for(const _0x239c71 of _0x314eec){if(!_0x4cecc7[_0x239c71])throw new Error(_0x46b48e(0x375)+_0x47d087['method']+'\x20'+_0x47d087[_0x46b48e(0x2cc)]+_0x46b48e(0x5b5)+_0x239c71);}for(const _0x190ae4 of _0x47b657){if(!_0x4cecc7[_0x190ae4])throw new Error(_0x46b48e(0x375)+_0x47d087[_0x46b48e(0x3f2)]+'\x20'+_0x47d087[_0x46b48e(0x2cc)]+_0x46b48e(0x1de)+_0x190ae4);}for(const _0x4124a3 of _0x47b657){if(_0x42ea9f[_0x46b48e(0x783)](_0x4124a3))throw new Error('Route\x20'+_0x47d087[_0x46b48e(0x3f2)]+'\x20'+_0x47d087['path']+_0x46b48e(0x32e)+_0x4124a3);if(_0x314eec[_0x46b48e(0x783)](_0x4124a3))throw new Error('Route\x20'+_0x47d087[_0x46b48e(0x3f2)]+'\x20'+_0x47d087['path']+_0x46b48e(0x1fc)+_0x4124a3);const _0x33dc8d=_0x4f7ef9['http']['bindings'][_0x4124a3];if(!/^params\.[A-Za-z0-9_*.-]+$/[_0x46b48e(0x86)](_0x33dc8d)&&!/^query\.[A-Za-z0-9_*.-]+$/[_0x46b48e(0x86)](_0x33dc8d)&&!/^body(?:\.[A-Za-z0-9_*.-]+)?$/[_0x46b48e(0x86)](_0x33dc8d)&&!/^headers\.[A-Za-z0-9_*.-]+$/['test'](_0x33dc8d))throw new Error('Route\x20'+_0x47d087['method']+'\x20'+_0x47d087[_0x46b48e(0x2cc)]+'\x20has\x20illegal\x20binding\x20target\x20for\x20'+_0x4124a3+':\x20'+_0x33dc8d);}for(const _0x282b34 of _0x314eec){if(_0x42ea9f[_0x46b48e(0x783)](_0x282b34))throw new Error(_0x46b48e(0x375)+_0x47d087[_0x46b48e(0x3f2)]+'\x20'+_0x47d087['path']+_0x46b48e(0xf1)+_0x282b34);}const _0x44d47b=_0x4f7ef9[_0x46b48e(0x1be)]?.[_0x46b48e(0x436)],_0x521855=new Set([_0x46b48e(0x1a8),_0x46b48e(0x572),_0x46b48e(0x25a),_0x46b48e(0x4b9),_0x46b48e(0x632),_0x46b48e(0x770)]);if(!_0x521855[_0x46b48e(0x783)](_0x44d47b))throw new Error(_0x46b48e(0x375)+_0x47d087[_0x46b48e(0x3f2)]+'\x20'+_0x47d087[_0x46b48e(0x2cc)]+_0x46b48e(0x250)+_0x44d47b);if(_0x44d47b===_0x46b48e(0x770)&&!_0x47d087[_0x46b48e(0x57f)]?.[_0x46b48e(0x770)])throw new Error('Route\x20'+_0x47d087[_0x46b48e(0x3f2)]+'\x20'+_0x47d087[_0x46b48e(0x2cc)]+_0x46b48e(0x26f));if(_0x4f7ef9[_0x46b48e(0x584)]?.[_0x46b48e(0x27f)]!==![]&&(_0x47d087['meta']?.['raw']||_0x47d087[_0x46b48e(0x57f)]?.[_0x46b48e(0x4ad)]||_0x4f7ef9[_0x46b48e(0x1be)]?.[_0x46b48e(0x69b)]===_0x46b48e(0x5f6)))throw new Error(_0x46b48e(0x375)+_0x47d087['method']+'\x20'+_0x47d087['path']+_0x46b48e(0x702)+_0x4f7ef9[_0x46b48e(0x1be)]?.[_0x46b48e(0x69b)]);const _0x26fd68=Object[_0x46b48e(0x449)](_0x4cecc7)[_0x46b48e(0x20f)](_0x39e74a=>{const _0x10d8ff=_0x46b48e;if(_0x42ea9f[_0x10d8ff(0x783)](_0x39e74a))return![];if(_0x314eec[_0x10d8ff(0x783)](_0x39e74a))return![];if(_0x47b657[_0x10d8ff(0x783)](_0x39e74a))return![];return!![];});if(_0x44d47b==='none'&&_0x26fd68[_0x46b48e(0x2e8)]>0x0)throw new Error('Route\x20'+_0x47d087[_0x46b48e(0x3f2)]+'\x20'+_0x47d087[_0x46b48e(0x2cc)]+'\x20has\x20unbound\x20input\x20fields\x20with\x20bodyMode:none:\x20'+_0x26fd68[_0x46b48e(0x546)](',\x20'));if(_0x44d47b==='array'&&_0x26fd68['filter'](_0x5ab168=>_0x5061bb(_0x4cecc7[_0x5ab168],_0x46b48e(0x632)))[_0x46b48e(0x2e8)]!==0x1)throw new Error(_0x46b48e(0x375)+_0x47d087['method']+'\x20'+_0x47d087['path']+_0x46b48e(0x727));}function _0x2e0605(_0x12d563,_0x166b5f,_0x2e075d,_0x50b0e1){const _0x28ee2f=_0x41a5d4;for(const [_0x206e35,_0x4dfd07]of Object[_0x28ee2f(0x377)](_0x12d563)){if(_0x166b5f[_0x28ee2f(0x783)](_0x206e35)||_0x2e075d[_0x28ee2f(0x783)](_0x206e35)||Object[_0x28ee2f(0x62f)][_0x28ee2f(0x34a)][_0x28ee2f(0x70d)](_0x50b0e1,_0x206e35))continue;if(_0x5061bb(_0x4dfd07,'array'))return _0x206e35;}return null;}function _0x173340(_0x518e1e){const _0x566bcf=_0x41a5d4;if(Array[_0x566bcf(0x259)](_0x518e1e))return _0x518e1e;if(_0x518e1e==null)return[];return[_0x518e1e];}function _0x5061bb(_0xf0b472,_0x26e7b3){const _0x546e16=_0x41a5d4;return _0x173340(_0xf0b472?.[_0x546e16(0x5be)])[_0x546e16(0x243)](_0x26e7b3);}function _0x2d0c06(_0x3a207e,_0x502853){const _0x842467=_0x41a5d4;if(_0x3a207e==null||typeof _0x3a207e!=='string')return _0x3a207e;const _0x2b5fa1=_0x173340(_0x502853?.[_0x842467(0x5be)]);if(_0x2b5fa1[_0x842467(0x2e8)]===0x0)return _0x3a207e;if(_0x2b5fa1[_0x842467(0x243)](_0x842467(0x5d2))&&_0x3a207e===_0x842467(0x5d2))return null;if(_0x2b5fa1[_0x842467(0x243)](_0x842467(0x610))){if(_0x3a207e===_0x842467(0x509))return!![];if(_0x3a207e==='false')return![];}if(_0x2b5fa1['includes'](_0x842467(0x19c))&&/^-?\d+$/[_0x842467(0x86)](_0x3a207e))return Number['parseInt'](_0x3a207e,0xa);if(_0x2b5fa1[_0x842467(0x243)](_0x842467(0x3f5))&&/^-?(?:\d+|\d*\.\d+)$/[_0x842467(0x86)](_0x3a207e))return Number(_0x3a207e);return _0x3a207e;}function _0x45c593(_0x34077b){return _0x4a84e0(_0x34077b);}function _0x4e8bdb(_0x4dcdbc,_0x56876e={},_0x3eb4c3={},_0x24dfee=null,_0x4c9803={}){const _0xa25980=_0x41a5d4,_0x4bd669=_0x4dcdbc?.[_0xa25980(0x658)];if(!_0x4bd669?.['hasCanonical']||!_0x4bd669['inputSchema'])return null;const _0x19449f=_0x4bd669[_0xa25980(0x2e6)]['properties']||{},_0x469bfe=_0x4bd669[_0xa25980(0x1be)]?.[_0xa25980(0x786)]?.[_0xa25980(0x77d)]||{},_0x219d7c=_0x4bd669['http']?.[_0xa25980(0x5ca)]||{},_0xfae5f5=new Set((_0x4bd669['pathParams']||[])[_0xa25980(0x362)](_0x4d7954=>_0x4d7954[_0xa25980(0x58e)])),_0x3fc6c9=new Set(Object[_0xa25980(0x449)](_0x469bfe)),_0x31240b={};for(const [_0x4ca627,_0x5d7e12]of Object[_0xa25980(0x377)](_0x19449f)){Object[_0xa25980(0x62f)][_0xa25980(0x34a)][_0xa25980(0x70d)](_0x5d7e12||{},_0xa25980(0x666))&&(_0x31240b[_0x4ca627]=_0x45c593(_0x5d7e12['default']));}for(const _0x221cd5 of _0x4bd669[_0xa25980(0x2bb)]||[]){if(!Object[_0xa25980(0x62f)]['hasOwnProperty'][_0xa25980(0x70d)](_0x56876e,_0x221cd5[_0xa25980(0x58e)]))continue;const _0x250d16=_0x19449f[_0x221cd5[_0xa25980(0x58e)]]||{};_0x31240b[_0x221cd5[_0xa25980(0x58e)]]=_0x2d0c06(_0x56876e[_0x221cd5['name']],_0x250d16);}for(const [_0xdd2d3,_0x1a7806]of Object[_0xa25980(0x377)](_0x469bfe)){if(!Object[_0xa25980(0x62f)][_0xa25980(0x34a)]['call'](_0x3eb4c3,_0xdd2d3))continue;_0x31240b[_0xdd2d3]=_0x2d0c06(_0x3eb4c3[_0xdd2d3],_0x1a7806||_0x19449f[_0xdd2d3]||{});}for(const [_0x38ebde,_0x1d385d]of Object[_0xa25980(0x377)](_0x219d7c)){if(typeof _0x1d385d!==_0xa25980(0x139))continue;let _0x98c6e7;if(_0x1d385d[_0xa25980(0x557)](_0xa25980(0xaa)))_0x98c6e7=_0x56876e[_0x1d385d[_0xa25980(0x762)](0x7)];else{if(_0x1d385d[_0xa25980(0x557)](_0xa25980(0x48e)))_0x98c6e7=_0x3eb4c3[_0x1d385d[_0xa25980(0x762)](0x6)];else{if(_0x1d385d===_0xa25980(0x772))_0x98c6e7=_0x24dfee;else{if(_0x1d385d['startsWith'](_0xa25980(0x6c6)))_0x98c6e7=_0x24dfee?.[_0x1d385d['slice'](0x5)];else{if(_0x1d385d['startsWith']('headers.'))_0x98c6e7=_0x4c9803?.[_0x1d385d[_0xa25980(0x762)](0x8)[_0xa25980(0x36c)]()]??_0x4c9803?.[_0x1d385d[_0xa25980(0x762)](0x8)];}}}}if(_0x98c6e7!==undefined)_0x31240b[_0x38ebde]=_0x98c6e7;}const _0x3eeaa0=_0x4bd669['http']?.[_0xa25980(0x436)];if(_0x3eeaa0!==_0xa25980(0x1a8)&&_0x3eeaa0!=='raw'&&_0x24dfee!=null){if(_0x3eeaa0===_0xa25980(0x632)&&Array[_0xa25980(0x259)](_0x24dfee)){const _0x5a97ae=_0x2e0605(_0x19449f,_0xfae5f5,_0x3fc6c9,_0x219d7c);if(_0x5a97ae)_0x31240b[_0x5a97ae]=_0x24dfee;}else{if(_0x3eeaa0===_0xa25980(0x25a))for(const [_0xe11299,_0x287b43]of Object['entries'](_0x19449f)){if(_0xfae5f5['has'](_0xe11299)||_0x3fc6c9['has'](_0xe11299)||Object[_0xa25980(0x62f)][_0xa25980(0x34a)][_0xa25980(0x70d)](_0x219d7c,_0xe11299))continue;if(Object[_0xa25980(0x62f)]['hasOwnProperty'][_0xa25980(0x70d)](_0x24dfee,_0xe11299))_0x31240b[_0xe11299]=_0x24dfee[_0xe11299];else{if(_0x5061bb(_0x287b43,_0xa25980(0x25a)))_0x31240b[_0xe11299]=_0x24dfee;}}else for(const [_0x3186f6,_0x5a74fa]of Object[_0xa25980(0x377)](_0x24dfee)){if(_0xfae5f5[_0xa25980(0x783)](_0x3186f6)||_0x3fc6c9['has'](_0x3186f6)||Object[_0xa25980(0x62f)][_0xa25980(0x34a)]['call'](_0x219d7c,_0x3186f6))continue;_0x31240b[_0x3186f6]=_0x5a74fa;}}}return _0x31240b;}function _0x156fc3(_0x2ac8ad,_0x4060ae,_0x1beecd,_0x23adf8){const _0x54e54c=_0x41a5d4;if(!_0x4060ae)return;const _0x5718ef=_0x173340(_0x4060ae['type']);if(_0x2ac8ad===undefined)return;if(_0x2ac8ad===null){_0x5718ef[_0x54e54c(0x2e8)]>0x0&&!_0x5718ef[_0x54e54c(0x243)](_0x54e54c(0x5d2))&&_0x23adf8[_0x54e54c(0x1c2)]({'field':_0x1beecd,'message':_0x54e54c(0x18d),'expected':_0x5718ef[_0x54e54c(0x546)]('|'),'actual':null});return;}if(_0x5718ef['length']===0x0)return;const _0x2ff10e=_0x5718ef[_0x54e54c(0x21d)](_0x22e803=>{const _0xa05ffb=_0x54e54c;switch(_0x22e803){case _0xa05ffb(0x139):return typeof _0x2ac8ad===_0xa05ffb(0x139);case _0xa05ffb(0x19c):return Number[_0xa05ffb(0x390)](_0x2ac8ad);case _0xa05ffb(0x3f5):return typeof _0x2ac8ad==='number'&&Number['isFinite'](_0x2ac8ad);case'boolean':return typeof _0x2ac8ad===_0xa05ffb(0x610);case _0xa05ffb(0x25a):return _0x2ac8ad&&typeof _0x2ac8ad===_0xa05ffb(0x25a)&&!Array['isArray'](_0x2ac8ad);case _0xa05ffb(0x632):return Array['isArray'](_0x2ac8ad);case'null':return _0x2ac8ad===null;default:return!![];}});if(!_0x2ff10e){_0x23adf8[_0x54e54c(0x1c2)]({'field':_0x1beecd,'message':'must\x20be\x20'+_0x5718ef[_0x54e54c(0x546)]('|'),'expected':_0x5718ef[_0x54e54c(0x546)]('|'),'actual':_0x2ac8ad});return;}Array[_0x54e54c(0x259)](_0x2ac8ad)&&_0x4060ae[_0x54e54c(0x464)]&&_0x2ac8ad[_0x54e54c(0x35b)]((_0x117d87,_0x3b0b1f)=>_0x156fc3(_0x117d87,_0x4060ae[_0x54e54c(0x464)],_0x1beecd+'['+_0x3b0b1f+']',_0x23adf8));}function _0x18f025(_0x242d20,_0x3fcecc){const _0x519833=_0x41a5d4,_0x218a1c=_0x242d20?.[_0x519833(0x658)];if(!_0x218a1c?.[_0x519833(0x582)]||!_0x218a1c[_0x519833(0x2e6)])return null;const _0x53e072=_0x218a1c[_0x519833(0x2e6)],_0x2eb523=_0x53e072['properties']||{},_0x35e2f6=new Set(_0x53e072[_0x519833(0x488)]||[]),_0x4e540e=[];for(const _0x1d72d4 of _0x35e2f6){_0x3fcecc[_0x1d72d4]===undefined&&_0x4e540e[_0x519833(0x1c2)]({'field':_0x1d72d4,'message':_0x519833(0x6a4),'expected':'present','actual':undefined});}if(_0x53e072[_0x519833(0x153)]===![])for(const _0x3be92b of Object['keys'](_0x3fcecc||{})){!Object[_0x519833(0x62f)][_0x519833(0x34a)]['call'](_0x2eb523,_0x3be92b)&&_0x4e540e['push']({'field':_0x3be92b,'message':_0x519833(0x459),'expected':_0x519833(0xa9),'actual':_0x3fcecc[_0x3be92b]});}for(const [_0x2218c1,_0x115177]of Object[_0x519833(0x377)](_0x2eb523)){_0x156fc3(_0x3fcecc[_0x2218c1],_0x115177,_0x2218c1,_0x4e540e);}if(_0x4e540e[_0x519833(0x2e8)]===0x0)return null;return{'code':_0x519833(0x4e4),'errors':_0x4e540e};}function _0x4bf455(_0x53fb22=[]){const _0xc8781d=_0x41a5d4;if(!Array['isArray'](_0x53fb22)||_0x53fb22[_0xc8781d(0x2e8)]===0x0)return null;const _0x1508ef=_0x53fb22[_0xc8781d(0x762)](0x0,0x3)[_0xc8781d(0x362)]((_0x1b3ec1={})=>{const _0x470329=_0xc8781d,_0x1048ef=_0x1b3ec1['field']?_0x1b3ec1[_0x470329(0x720)]+'\x20':'';return(''+_0x1048ef+(_0x1b3ec1[_0x470329(0x71d)]||'is\x20invalid'))[_0x470329(0x220)]();})[_0xc8781d(0x546)](';\x20');return _0x53fb22['length']>0x3?_0x1508ef+_0xc8781d(0x33e)+(_0x53fb22[_0xc8781d(0x2e8)]-0x3)+_0xc8781d(0x4d5):_0x1508ef;}function _0xe0f99e(_0x6e7b2a,_0x1369ce={}){const _0x331286=_0x41a5d4,_0x7e9382=_0x1369ce?.[_0x331286(0x468)]?.[_0x331286(0x1da)]??_0x1369ce?.['error']??'Unknown\x20error',_0x29de7c=_0x1369ce?.[_0x331286(0x468)]?.['details']??_0x1369ce?.[_0x331286(0x3ed)]??_0x7e9382?.[_0x331286(0x3ed)]??null,_0x231a6e=_0x1369ce?.['result']?.[_0x331286(0x72d)]??_0x1369ce?.[_0x331286(0x72d)]??_0x7e9382?.[_0x331286(0x72d)]??null,_0x2203fd=_0x1369ce?.[_0x331286(0x468)]?.[_0x331286(0x71d)]??_0x1369ce?.[_0x331286(0x71d)]??_0x7e9382?.[_0x331286(0x71d)]??null,_0x467774=typeof _0x7e9382===_0x331286(0x139)?_0x7e9382:null,_0x12df5a=typeof _0x467774===_0x331286(0x139)&&/^[A-Z0-9_]+$/[_0x331286(0x86)](_0x467774),_0x5a3558=_0x231a6e??(_0x12df5a?_0x467774:null)??(_0x6b95cb[_0x6e7b2a]||'HTTP_'+_0x6e7b2a);let _0x55008d=_0x2203fd;!_0x55008d&&typeof _0x467774===_0x331286(0x139)&&!_0x12df5a&&(_0x55008d=_0x467774);if(!_0x55008d&&_0x5a3558==='VALIDATION_ERROR'){const _0x5d0a45=_0x4bf455(_0x29de7c);_0x55008d=_0x5d0a45?_0x331286(0x3d1)+_0x5d0a45:_0x331286(0x254);}if(!_0x55008d&&Array[_0x331286(0x259)](_0x29de7c)&&_0x29de7c[_0x331286(0x2e8)]>0x0){const _0x465e4d=_0x4bf455(_0x29de7c);if(_0x465e4d)_0x55008d=_0x465e4d;}if(!_0x55008d)_0x55008d=_0x6b95cb[_0x6e7b2a]||_0x331286(0x5aa);const _0x8472cc={'code':_0x5a3558,'message':_0x55008d};if(_0x29de7c!=null)_0x8472cc[_0x331286(0x3ed)]=_0x29de7c;return _0x8472cc;}function _0x523d72(_0x844e65){const _0x10ec7f=_0x41a5d4,_0x5f1b90={};if(!_0x844e65)return _0x5f1b90;for(const _0x412f0b of _0x844e65[_0x10ec7f(0x527)](';')){const _0x59d6bb=_0x412f0b['indexOf']('=');if(_0x59d6bb===-0x1)continue;const _0x225c71=_0x412f0b['slice'](0x0,_0x59d6bb)[_0x10ec7f(0x220)](),_0x38c0cb=_0x412f0b['slice'](_0x59d6bb+0x1)[_0x10ec7f(0x220)]();_0x5f1b90[_0x225c71]=decodeURIComponent(_0x38c0cb);}return _0x5f1b90;}function _0x748bd0(_0x493ff2,_0x17300c){const _0x9c0c1=_0x41a5d4;return _0x17300c=_0x14b20e(_0x17300c),{'status':_0x17300c[_0x9c0c1(0x469)]??_0x493ff2[_0x9c0c1(0x469)],'headers':{..._0x493ff2[_0x9c0c1(0x106)]||{},..._0x17300c[_0x9c0c1(0x106)]||{}},'body':_0x17300c['body']??_0x493ff2[_0x9c0c1(0x772)]};}function _0x3f9981(_0x1a5b78={}){const _0x2290ab=_0x41a5d4;return _0x1a5b78['transport']||(_0x1a5b78['internal']?_0x2290ab(0x734):_0x2290ab(0x1be));}function _0x7a04fa(_0x4fe9d1){const _0x1e4584=_0x41a5d4;if(_0x4fe9d1['context']?.['internal']===!![])return!![];if(_0x4fe9d1[_0x1e4584(0x46d)]?.[_0x1e4584(0x9f)]?.[_0x1e4584(0x6ff)]===!![])return!![];if(_0x4fe9d1[_0x1e4584(0x46d)]?.[_0x1e4584(0x9f)]?.['ok']===!![])return!![];return![];}function _0x688c1e(_0xf1d15b,_0x39db87){const _0x1ba955=_0x41a5d4,_0x1faf97=_0x39db87[_0x1ba955(0x527)]('.');let _0x4a6ce5=_0xf1d15b;for(const _0x4eaaea of _0x1faf97){_0x4a6ce5=_0x4a6ce5?.[_0x4eaaea];}return _0x4a6ce5||null;}class _0x52b9f3{constructor(){const _0xc9827a=_0x41a5d4;this['middlewares']=[],this['guards']=[],this[_0xc9827a(0x1a1)]=[],this[_0xc9827a(0x67e)]=0x5*0x400*0x400,this[_0xc9827a(0x463)]=null,this[_0xc9827a(0x498)]=[],this[_0xc9827a(0x78a)]=new Set(),this[_0xc9827a(0x9f)]={'cookieName':_0xc9827a(0x407),'stateCookieName':'kdb_admin_oauth_state','csrfCookieName':_0xc9827a(0x352)},this[_0xc9827a(0xab)]={},this['_loginStates']=new Map(),this[_0xc9827a(0x16e)]=null,this['_jwksCache']=null,this[_0xc9827a(0x29a)]=new Map(),this['metrics']=new _0x491fed(),this[_0xc9827a(0x214)]=![],this['_userRouteCount']=0x0;}['configureAuth'](_0x215b09={}){const _0x5b027d=_0x41a5d4;return this[_0x5b027d(0xab)]=_0x215b09||{},this[_0x5b027d(0x13c)]=_0x215b09[_0x5b027d(0x1d0)]??_0x5b027d(0x58f),this[_0x5b027d(0xab)];}get[_0x41a5d4(0x3ee)](){const _0x3c1709=_0x41a5d4;if(this[_0x3c1709(0x676)]?.[_0x3c1709(0x9f)])return this[_0x3c1709(0x676)][_0x3c1709(0x9f)][_0x3c1709(0x3ee)];return![];}[_0x41a5d4(0x26a)](){const _0x2ac86e=_0x41a5d4;if(this[_0x2ac86e(0x676)]?.[_0x2ac86e(0x9f)])return this[_0x2ac86e(0x676)]['auth'][_0x2ac86e(0x26a)]();return this[_0x2ac86e(0xab)]||{};}[_0x41a5d4(0xa8)](_0x2cacd8){const _0xf2f629=_0x41a5d4;this[_0xf2f629(0x30e)][_0xf2f629(0x1c2)](_0x2cacd8);}[_0x41a5d4(0x77b)](_0x29696a,_0x2dc64d){const _0x3e4b30=_0x41a5d4;this[_0x3e4b30(0x4cc)][_0x3e4b30(0x1c2)]({'match':_0x29696a,'handler':_0x2dc64d});}[_0x41a5d4(0x5f3)](_0x41584a,_0x182b4b,_0x2fbc09,_0x432f7e={}){const _0x304ef7=_0x41a5d4,_0x15ba4e={'method':_0x53e271(_0x41584a),'path':_0x182b4b,'matcher':_0x2e4f19(_0x182b4b),'handler':_0x2fbc09,'meta':_0x432f7e||{}},_0x19359d=_0xdc6d17(_0x15ba4e);_0x3264ba(_0x15ba4e,_0x19359d),_0x15ba4e[_0x304ef7(0x658)]=_0x19359d,_0x15ba4e[_0x304ef7(0x41e)]=this[_0x304ef7(0x214)]===!![];if(_0x15ba4e[_0x304ef7(0x41e)])this['_userRouteCount']++;this[_0x304ef7(0x1a1)][_0x304ef7(0x1c2)](_0x15ba4e);}[_0x41a5d4(0x6fa)](_0x2e7762,_0x7dbdd6,_0x25cf3a,_0x132b2e={}){const _0x295c13=_0x41a5d4;this[_0x295c13(0x5f3)](_0x2e7762,_0x7dbdd6,_0x25cf3a,{..._0x132b2e,'raw':!![]});}[_0x41a5d4(0x11f)](_0xc5bc79,_0x302339,{corsOnly:corsOnly=![]}={}){const _0x209463=_0x41a5d4;let _0x45567a=null,_0x515912=Infinity;for(const _0x38e37b of this[_0x209463(0x1a1)]){if(corsOnly){if(!_0x38e37b[_0x209463(0x57f)]?.[_0x209463(0x30f)])continue;}else{if(_0x38e37b[_0x209463(0x3f2)]!==_0xc5bc79)continue;}if(!_0x38e37b[_0x209463(0x5ab)]['regex'][_0x209463(0x86)](_0x302339))continue;const _0xefb61e=_0x38e37b[_0x209463(0x5ab)]['keys']?.[_0x209463(0x2e8)]??0x0;if(_0xefb61e<_0x515912){_0x45567a=_0x38e37b,_0x515912=_0xefb61e;if(_0xefb61e===0x0)break;}}return _0x45567a;}[_0x41a5d4(0x13f)](_0x321ae5,_0x36914e){const _0x24fe45=_0x41a5d4,_0x23918b=_0x53e271(_0x321ae5),_0x2fe44e=this[_0x24fe45(0x11f)](_0x23918b,_0x36914e);if(_0x2fe44e)return _0x2fe44e;if(_0x23918b===_0x24fe45(0x76b))return this['_bestMatch'](_0x23918b,_0x36914e,{'corsOnly':!![]});return null;}['_shouldWrapResponse'](_0x113c19,_0x1f0597){const _0x49945c=_0x41a5d4;if(_0x113c19?.['meta']?.[_0x49945c(0x3f4)])return![];if(_0x1f0597?.[_0x49945c(0x106)]?.['x-okdb-raw-response'])return![];return!![];}[_0x41a5d4(0x3c7)](){const _0x42779a=_0x41a5d4;return this['routes']['filter'](_0x25a2cf=>!_0x25a2cf[_0x42779a(0x57f)]?.[_0x42779a(0x15a)])[_0x42779a(0x362)](_0x406666=>({'method':_0x406666[_0x42779a(0x3f2)],'path':_0x406666['path'],'defaults':_0x406666[_0x42779a(0x5ab)][_0x42779a(0x279)],'meta':_0x406666[_0x42779a(0x57f)],'operation':_0x406666[_0x42779a(0x658)]}));}[_0x41a5d4(0x5e2)](_0x311db5,_0x2b4eb6,_0x41bdee={}){const _0x1dffb0=_0x41a5d4,{PassThrough:_0x1815ec}=require$$5;this[_0x1dffb0(0x5f3)](_0x1dffb0(0x19e),_0x311db5,({params:_0x2921b7,query:_0x3d2841,headers:_0x94ccbd,context:_0x15a6bf})=>{const _0x13c841=_0x1dffb0,_0x3b91d6=new _0x1815ec();let _0x576edc=null;const _0x5096b4={};try{_0x15a6bf?.['req']?.['socket']?.['setNoDelay'](!![]);}catch{}_0x3b91d6['write'](_0x13c841(0x3c5)),_0x576edc=setInterval(()=>{const _0x4c0f11=_0x13c841;try{_0x3b91d6[_0x4c0f11(0xc6)](_0x4c0f11(0x324));}catch{}},0x3a98);const _0x590f38=(_0x1bf234,_0x34d81c,_0x1e3498={})=>{const _0x3c10ae=_0x13c841;try{const _0x492f0b=_0x1e3498[_0x3c10ae(0x770)]?String(_0x34d81c??''):JSON[_0x3c10ae(0x5bd)](_0x34d81c);_0x1e3498['id']!=null&&_0x3b91d6[_0x3c10ae(0xc6)](_0x3c10ae(0x178)+_0x1e3498['id']+'\x0a');_0x3b91d6[_0x3c10ae(0xc6)](_0x3c10ae(0x1f3)+_0x1bf234+'\x0a');for(const _0xa0765b of _0x492f0b[_0x3c10ae(0x527)]('\x0a')){_0x3b91d6[_0x3c10ae(0xc6)](_0x3c10ae(0x6d0)+_0xa0765b+'\x0a');}_0x3b91d6[_0x3c10ae(0xc6)]('\x0a');}catch{}},_0x326223=()=>{const _0x354b4c=_0x13c841;_0x576edc&&(clearInterval(_0x576edc),_0x576edc=null);try{_0x3b91d6[_0x354b4c(0x739)]();}catch{}},_0x2cd891=(_0x1d0521,_0x2cca81)=>{_0x5096b4[_0x1d0521]=_0x2cca81;};_0x15a6bf?.[_0x13c841(0x51b)]?.['on'](_0x13c841(0x57b),_0x326223),_0x3b91d6['on'](_0x13c841(0x57b),_0x326223);if(_0x15a6bf?.[_0x13c841(0x9f)]&&_0x15a6bf[_0x13c841(0x9f)]['open']!==!![]&&_0x15a6bf[_0x13c841(0x9f)]['isAuthenticated']){const _0x16b8e3={'headers':_0x94ccbd??{},'cookies':_0x523d72(_0x94ccbd?.[_0x13c841(0x1f7)]),'context':{},'socket':_0x15a6bf?.[_0x13c841(0x51b)]?.[_0x13c841(0x6fb)]??{'remoteAddress':null}},_0x38d1d7=setInterval(async()=>{const _0x4683ad=_0x13c841;try{const _0x18fb5d=await this[_0x4683ad(0x1a6)](_0x16b8e3);if(_0x18fb5d?.[_0x4683ad(0x58f)]===!![]||_0x18fb5d?.['isAuthenticated'])return;_0x590f38(_0x4683ad(0x9f),{'expired':!![]}),_0x326223();}catch{_0x326223();}},0xea60);_0x38d1d7[_0x13c841(0x575)]?.(),_0x3b91d6['on'](_0x13c841(0x57b),()=>clearInterval(_0x38d1d7));}const _0x1b6769=_0x2b4eb6({'send':_0x590f38,'close':_0x326223,'params':_0x2921b7??{},'query':_0x3d2841??{},'headers':_0x94ccbd??{},'context':_0x15a6bf,'setHeader':_0x2cd891});return typeof _0x1b6769==='function'&&_0x3b91d6['on'](_0x13c841(0x57b),_0x1b6769),{'status':0xc8,'headers':{'content-type':_0x13c841(0x168),'cache-control':_0x13c841(0x1ca),'connection':_0x13c841(0x4ba),'x-accel-buffering':'no',..._0x5096b4},'body':_0x3b91d6};},{..._0x41bdee,'sse':!![]});}async[_0x41a5d4(0x35e)](_0x5a2661,_0xccbf22){const _0x552ba4=_0x41a5d4;for(const _0x211cf1 of this[_0x552ba4(0x4cc)]){if(!_0x211cf1[_0x552ba4(0xbd)](_0x5a2661))continue;const _0x3f3d98=await _0x211cf1['handler'](_0x5a2661,_0xccbf22);if(_0x3f3d98===![])return![];}return!![];}async[_0x41a5d4(0x196)](_0x4cae93,_0x215002,_0x3bcbe2){let _0x52a289=0x0;const _0x3904d2=async()=>{const _0x1e3983=_0x4ed4,_0x2f7059=this[_0x1e3983(0x30e)][_0x52a289++];if(!_0x2f7059)return _0x3bcbe2();return _0x2f7059(_0x4cae93,_0x215002,_0x3904d2);};return _0x3904d2();}['_wrapApiResponse'](_0x59e67d,_0x51d409){const _0x294f88=_0x41a5d4,{status:status=0xc8,headers:headers={},body:_0x1216e1}=_0x59e67d;if(status>=0x12c&&status<0x190)return _0x59e67d;if(_0x2a98e7(_0x1216e1))return _0x59e67d;if(Buffer['isBuffer'](_0x1216e1))return _0x59e67d;if(typeof _0x1216e1===_0x294f88(0x139))return _0x59e67d;const _0x387f56={'time':+_0x51d409[_0x294f88(0x12a)](0x2)};if(_0x1216e1?.[_0x294f88(0x57f)]&&typeof _0x1216e1['meta']===_0x294f88(0x25a)){const {time:_0x19dd82,..._0x269459}=_0x1216e1['meta'];Object['assign'](_0x387f56,_0x269459);}let _0x45b544;if(status>=0x190){const _0x46a154=_0xe0f99e(status,_0x1216e1);_0x45b544={'data':null,'error':_0x46a154,'meta':_0x387f56};}else{if(status===0xcc||_0x1216e1==null)_0x45b544={'data':null,'error':null,'meta':_0x387f56};else{let _0x5c9c58;if(_0x294f88(0x468)in _0x1216e1)_0x5c9c58=_0x1216e1[_0x294f88(0x468)];else{const {meta:_0x3598d9,..._0x164a82}=_0x1216e1;_0x5c9c58=Object[_0x294f88(0x449)](_0x164a82)[_0x294f88(0x2e8)]>0x0?_0x164a82:null;}_0x45b544={'data':_0x5c9c58,'error':null,'meta':_0x387f56};}}return{'status':status===0xcc?0xc8:status,'headers':headers,'body':_0x45b544};}async[_0x41a5d4(0x31f)](_0x16ef2d,_0xd5d318,_0x2b1363={},_0x5ee312={}){const _0x548263=_0x41a5d4;_0x16ef2d=_0x53e271(_0x16ef2d);const _0x3832ec=this[_0x548263(0x13f)](_0x16ef2d,_0xd5d318),_0xce825d={'method':_0x16ef2d,'path':_0xd5d318,'headers':_0x2b1363[_0x548263(0x106)]??{},'body':_0x2b1363[_0x548263(0x772)]??null,'query':_0x2b1363['query']??{},'context':_0x5ee312,'cookies':_0x523d72(_0x2b1363[_0x548263(0x106)]?.[_0x548263(0x1f7)]),'route':_0x3832ec,'socket':{'remoteAddress':_0x2b1363[_0x548263(0x598)]??_0x548263(0x2ff)}};_0xce825d[_0x548263(0x46d)]=_0xce825d['context']||{};!_0xce825d[_0x548263(0x46d)][_0x548263(0x9f)]&&(_0xce825d[_0x548263(0x46d)]['auth']=await this[_0x548263(0x1a6)](_0xce825d));if(_0xce825d[_0x548263(0x46d)][_0x548263(0x9f)]?.[_0x548263(0x4e5)])return _0x14b20e({'status':0x193,'body':{'error':{'code':_0x548263(0x4c5),'message':_0x548263(0x61c)}}});_0xce825d['context'][_0x548263(0x9f)]?.[_0x548263(0xd0)]&&!_0xce825d[_0x548263(0x46d)][_0x548263(0xd0)]&&(_0xce825d['context']['user']=_0xce825d[_0x548263(0x46d)]['auth'][_0x548263(0xd0)]);let _0xa4c1e7=null;const _0x54b2de={'status'(_0x5912ef){const _0x5a066e=_0x548263;_0xa4c1e7=_0xa4c1e7||{},_0xa4c1e7[_0x5a066e(0x469)]=_0x5912ef;},'setHeader'(_0x2d2a64,_0x3d9ccf){const _0x251394=_0x548263;_0xa4c1e7=_0xa4c1e7||{},_0xa4c1e7[_0x251394(0x106)]=_0xa4c1e7[_0x251394(0x106)]||{};const _0x215145=String(_0x2d2a64)[_0x251394(0x36c)]();if(_0x215145===_0x251394(0x1ec)){const _0x377cb7=_0xa4c1e7[_0x251394(0x106)][_0x2d2a64];if(!_0x377cb7)_0xa4c1e7[_0x251394(0x106)][_0x2d2a64]=_0x3d9ccf;else{if(Array[_0x251394(0x259)](_0x377cb7))_0x377cb7[_0x251394(0x1c2)](_0x3d9ccf);else _0xa4c1e7[_0x251394(0x106)][_0x2d2a64]=[_0x377cb7,_0x3d9ccf];}return;}_0xa4c1e7['headers'][_0x2d2a64]=_0x3d9ccf;},'send'(_0x2c3ed0){const _0x17b8e5=_0x548263;_0xa4c1e7=_0xa4c1e7||{},_0xa4c1e7[_0x17b8e5(0x772)]=_0x2c3ed0;}},_0x1f8647=await this[_0x548263(0x35e)](_0xce825d,_0x54b2de);if(!_0x1f8647)return _0x14b20e(_0xa4c1e7??{'status':0x193});const _0x87e7d8=this['_enforceOperationAccess'](_0xce825d);if(_0x87e7d8)return _0x14b20e(_0x87e7d8);const _0x5319de=this[_0x548263(0x603)](_0xce825d);if(_0x5319de)return _0x14b20e(_0x5319de);return await this[_0x548263(0x196)](_0xce825d,_0x54b2de,async()=>{const _0x33bd43=_0x548263,_0x53fd9e=await this[_0x33bd43(0x442)](_0xce825d);if(_0xa4c1e7==null){_0xa4c1e7=_0x53fd9e;return;}_0xa4c1e7=_0x748bd0(_0xa4c1e7,_0x53fd9e);}),_0x14b20e(_0xa4c1e7);}[_0x41a5d4(0x690)](_0x191538){const _0x4cb0a4=_0x41a5d4,_0x3e46f7=_0x191538[_0x4cb0a4(0x6a0)]?.[_0x4cb0a4(0x658)],_0x33d23f=_0x3e46f7?.[_0x4cb0a4(0x2d6)];if(!_0x3e46f7?.[_0x4cb0a4(0x582)]||!_0x33d23f)return null;if(_0x191538['context']?.[_0x4cb0a4(0x9f)]?.[_0x4cb0a4(0x58f)]===!![]||_0x191538[_0x4cb0a4(0x46d)]?.[_0x4cb0a4(0x9f)]?.['isSystem']===!![])return null;const _0x1ea84e=_0x3f9981(_0x191538[_0x4cb0a4(0x46d)]),_0x3ccdc0=Array['isArray'](_0x33d23f[_0x4cb0a4(0x5b9)])?_0x33d23f[_0x4cb0a4(0x5b9)]:null;if(_0x33d23f[_0x4cb0a4(0x136)]&&_0x191538[_0x4cb0a4(0x46d)]?.[_0x4cb0a4(0x734)]!==!![])return{'status':0x193,'body':{'error':_0x4cb0a4(0x4a7)}};if(_0x3ccdc0&&_0x3ccdc0[_0x4cb0a4(0x2e8)]>0x0&&!_0x3ccdc0['includes'](_0x1ea84e)&&!(_0x1ea84e==='internal'&&_0x3ccdc0[_0x4cb0a4(0x243)](_0x4cb0a4(0x787))))return{'status':0x193,'body':{'error':'Forbidden'}};if(_0x33d23f['authRequired']&&!_0x7a04fa(_0x191538))return{'status':0x191,'body':{'error':_0x4cb0a4(0x227)}};const _0x460ebd=_0x33d23f[_0x4cb0a4(0x1d8)];if(!_0x460ebd)return null;if(_0x191538['context']?.[_0x4cb0a4(0x9f)]?.[_0x4cb0a4(0x5be)]===_0x4cb0a4(0x353))return null;const _0x1bd201=_0x191538[_0x4cb0a4(0x46d)]?.['auth']?.[_0x4cb0a4(0x2f5)];if(!_0x1bd201){if(_0x191538[_0x4cb0a4(0x46d)]?.['auth']?.['ok']===!![])return null;return{'status':0x193,'body':{'error':_0x4cb0a4(0x137)}};}if(!_0x191538[_0x4cb0a4(0x58c)]&&_0x191538[_0x4cb0a4(0x6a0)]?.['matcher']){const _0x250964=_0x191538[_0x4cb0a4(0x6a0)][_0x4cb0a4(0x5ab)][_0x4cb0a4(0x1b6)][_0x4cb0a4(0x74c)](_0x191538['path']);_0x250964&&(_0x191538[_0x4cb0a4(0x58c)]={},_0x191538[_0x4cb0a4(0x6a0)][_0x4cb0a4(0x5ab)]['keys'][_0x4cb0a4(0x35b)]((_0x49dd7b,_0x3c53c4)=>{const _0x15215d=_0x4cb0a4,_0x2c2a02=_0x250964[_0x3c53c4+0x1];_0x191538['params'][_0x49dd7b]=_0x2c2a02?decodeURIComponent(_0x2c2a02):_0x191538[_0x15215d(0x6a0)][_0x15215d(0x5ab)][_0x15215d(0x279)][_0x49dd7b]??undefined;}));}let _0x535ad9=null;const _0x3527e9=_0x33d23f[_0x4cb0a4(0x293)]===_0x4cb0a4(0x514)?_0x4cb0a4(0x49a):_0x33d23f[_0x4cb0a4(0x293)]?.[_0x4cb0a4(0x514)];_0x3527e9&&(_0x535ad9=_0x688c1e(_0x191538,_0x3527e9));if(_0x535ad9&&_0x535ad9[_0x4cb0a4(0x557)]('~')){const _0x39ece0=_0x491f52(_0x460ebd),_0x4d88fa=_0x4434e2(_0x1bd201['permissions']||[],(_0x1bd201['grants']||{})[_0x535ad9]||[]);if(!_0x473867(_0x4d88fa,_0x39ece0))return{'status':0x193,'body':{'error':_0x4cb0a4(0x5f2)+_0x39ece0+_0x4cb0a4(0x222)}};}const _0x4a8882=_0x4434e2(_0x1bd201[_0x4cb0a4(0x75a)]||[],_0x535ad9?(_0x1bd201[_0x4cb0a4(0x69c)]||{})[_0x535ad9]||[]:[]);if(!_0x473867(_0x4a8882,_0x460ebd))return{'status':0x193,'body':{'error':'Forbidden\x20—\x20requires\x20'+_0x460ebd}};return null;}['_validateOperationRequest'](_0x249c29){const _0x51cd2e=_0x41a5d4,_0x1460db=_0x249c29[_0x51cd2e(0x6a0)],_0x4f482d=_0x1460db?.[_0x51cd2e(0x658)];if(!_0x4f482d?.['hasCanonical']||!_0x4f482d[_0x51cd2e(0x2e6)])return null;let _0x10f376=_0x249c29['params']??null;if(!_0x10f376&&_0x1460db?.['matcher']){const _0x2ee8f1=_0x1460db['matcher'][_0x51cd2e(0x1b6)][_0x51cd2e(0x74c)](_0x249c29['path']);_0x2ee8f1&&(_0x10f376={},_0x1460db[_0x51cd2e(0x5ab)][_0x51cd2e(0x449)]['forEach']((_0xc51036,_0x50a273)=>{const _0x5a9d31=_0x51cd2e,_0x478d6c=_0x2ee8f1[_0x50a273+0x1];_0x10f376[_0xc51036]=_0x478d6c?decodeURIComponent(_0x478d6c):_0x1460db['matcher'][_0x5a9d31(0x279)][_0xc51036]??undefined;}));}const _0x5bb105=_0x4e8bdb(_0x1460db,_0x10f376??{},_0x249c29['query']??{},_0x249c29['body'],_0x249c29[_0x51cd2e(0x106)]??{}),_0x1d771c=_0x18f025(_0x1460db,_0x5bb105||{});if(!_0x1d771c)return null;const _0x35f9ad=_0x4bf455(_0x1d771c['errors']);return{'status':0x190,'body':{'error':_0x1d771c['code'],'code':_0x1d771c['code'],'message':_0x35f9ad?'Validation\x20failed:\x20'+_0x35f9ad:_0x51cd2e(0x254),'details':_0x1d771c[_0x51cd2e(0x6d)]}};}['validateRouteInput'](_0xf34581,_0x5b60ed){const _0x1edbb3=_0x41a5d4,_0x2c8ab7=_0x18f025(_0xf34581,_0x5b60ed||{});if(!_0x2c8ab7)return null;return{'code':_0x2c8ab7[_0x1edbb3(0x72d)],'message':_0x4bf455(_0x2c8ab7[_0x1edbb3(0x6d)])?_0x1edbb3(0x3d1)+_0x4bf455(_0x2c8ab7[_0x1edbb3(0x6d)]):_0x1edbb3(0x254),'details':_0x2c8ab7['errors']};}async['_dispatch'](_0x44c65e){const _0x52b48a=_0x41a5d4;if(_0x44c65e[_0x52b48a(0x3f2)]===_0x52b48a(0x76b)){const _0x42802e=this[_0x52b48a(0x11f)]('OPTIONS',_0x44c65e[_0x52b48a(0x2cc)],{'corsOnly':!![]});if(_0x42802e)return{'status':0xcc,'headers':_0x2cdc9c(_0x44c65e[_0x52b48a(0x106)],_0x42802e[_0x52b48a(0x57f)][_0x52b48a(0x30f)],_0x42802e[_0x52b48a(0x3f2)])||{}};}const _0xc51128=this[_0x52b48a(0x11f)](_0x44c65e[_0x52b48a(0x3f2)],_0x44c65e[_0x52b48a(0x2cc)]);if(_0xc51128){const _0x25b678=_0xc51128[_0x52b48a(0x5ab)]['regex'][_0x52b48a(0x74c)](_0x44c65e['path']),_0x2b9dc8={};_0xc51128[_0x52b48a(0x5ab)][_0x52b48a(0x449)][_0x52b48a(0x35b)]((_0x3c0f7b,_0x3051f2)=>{const _0x4fab6b=_0x52b48a,_0x1bb7e3=_0x25b678[_0x3051f2+0x1];_0x2b9dc8[_0x3c0f7b]=_0x1bb7e3?decodeURIComponent(_0x1bb7e3):_0xc51128[_0x4fab6b(0x5ab)][_0x4fab6b(0x279)][_0x3c0f7b]??undefined;}),_0x44c65e[_0x52b48a(0x58c)]=_0x2b9dc8;try{const _0x349914=await _0xc51128[_0x52b48a(0x322)]({'params':_0x2b9dc8,'body':_0x44c65e['body'],'query':_0x44c65e['query'],'headers':_0x44c65e[_0x52b48a(0x106)],'context':_0x44c65e[_0x52b48a(0x46d)]}),_0x5a296f=_0x14b20e(_0x349914),_0x37ff5c=_0x2cdc9c(_0x44c65e['headers'],_0xc51128[_0x52b48a(0x57f)]?.[_0x52b48a(0x30f)],_0xc51128[_0x52b48a(0x3f2)]);if(!_0x37ff5c)return _0x5a296f;return{..._0x5a296f,'headers':{..._0x5a296f[_0x52b48a(0x106)]||{},..._0x37ff5c}};}catch(_0x12b5e2){const _0x5a8149=_0x12b5e2?.[_0x52b48a(0x469)]||_0x47923a[_0x12b5e2?.[_0x52b48a(0x72d)]]||0x1f4;return{'status':_0x5a8149,'body':{'error':_0x12b5e2[_0x52b48a(0x71d)]||_0x52b48a(0x705),'code':_0x12b5e2?.[_0x52b48a(0x72d)]||_0x6b95cb[_0x5a8149]||_0x52b48a(0x78c)+_0x5a8149,'message':_0x12b5e2?.[_0x52b48a(0x71d)]||_0x52b48a(0x705),..._0x12b5e2?.[_0x52b48a(0x3ed)]!=null?{'details':_0x12b5e2['details']}:{}}};}}return{'status':0x194,'body':{'error':_0x52b48a(0x1a7)}};}[_0x41a5d4(0x416)](_0x3fd861,_0x2a4732={}){const _0x2b3c48=_0x41a5d4;if(typeof _0x2a4732===_0x2b3c48(0x139)||Array[_0x2b3c48(0x259)](_0x2a4732))_0x2a4732={'host':_0x2a4732};_0x2a4732=_0x2a4732??{};const _0x2f3878=Number(_0x2a4732[_0x2b3c48(0x571)])||0x0;if(_0x2f3878>=0x1||_0x2a4732[_0x2b3c48(0x748)]!=null||_0x2a4732[_0x2b3c48(0x1bd)]!=null){const _0x5d7618=new Error(_0x2b3c48(0x6c)+'library\x20(okdb\x20node-model\x202.0).\x20For\x20multi-process\x20HTTP\x20serving\x20use\x20the\x20okdb\x20'+_0x2b3c48(0x478)+_0x2b3c48(0x68a));_0x5d7618['code']=_0x2b3c48(0x533);throw _0x5d7618;}if(this[_0x2b3c48(0x463)])throw new Error('HTTP\x20server\x20already\x20running');const _0x11d756=_0x2a4732[_0x2b3c48(0x2a4)]==null?[undefined]:[][_0x2b3c48(0x4e0)](_0x2a4732[_0x2b3c48(0x2a4)]);if(!_0x11d756[_0x2b3c48(0x2e8)]||_0x11d756[_0x2b3c48(0x21d)](_0x26f156=>_0x26f156!==undefined&&(typeof _0x26f156!==_0x2b3c48(0x139)||!_0x26f156))){const _0x121dec=new Error(_0x2b3c48(0x773));_0x121dec['code']='BAD_HOST';throw _0x121dec;}_0x3fd861&&this['auth'][_0x2b3c48(0x1fb)]===_0x2b3c48(0x407)&&(this[_0x2b3c48(0x9f)][_0x2b3c48(0x1fb)]='okdb_session_'+_0x3fd861,this['_okdb']?.['auth']&&(this[_0x2b3c48(0x676)][_0x2b3c48(0x9f)][_0x2b3c48(0x1e6)]=this[_0x2b3c48(0x9f)][_0x2b3c48(0x1fb)]));const _0x19cb4b=this[_0x2b3c48(0x676)]?.[_0x2b3c48(0x5ba)]?.[_0x2b3c48(0x777)]?.[_0x2b3c48(0x5a9)]??![],_0x405066=async(_0x1219bf,_0x445cd5)=>{const _0x4755f8=_0x2b3c48,_0x585725=Date[_0x4755f8(0x6f1)]();if(_0x19cb4b){const _0x46ce01=_0x1219bf[_0x4755f8(0x14d)]||'/',_0x17d35c=_0x1219bf['headers']?.[_0x4755f8(0x5cb)]?_0x1219bf[_0x4755f8(0x106)][_0x4755f8(0x5cb)][_0x4755f8(0x61f)](/^Bearer\s+(\S{0,8})\S*/i,_0x4755f8(0x2f8)):'-',_0x33dd4a=_0x1219bf[_0x4755f8(0x106)]?.[_0x4755f8(0x568)]||'-',_0x7a96ab=_0x1219bf[_0x4755f8(0x106)]?.[_0x4755f8(0x54b)]||_0x1219bf[_0x4755f8(0x106)]?.[_0x4755f8(0x681)]||'-',_0x4332fe=_0x1219bf[_0x4755f8(0x106)]?.[_0x4755f8(0x52d)]||'-';process[_0x4755f8(0x27e)][_0x4755f8(0xc6)]('[req]\x20'+_0x1219bf[_0x4755f8(0x3f2)]['padEnd'](0x7)+'\x20'+_0x46ce01[_0x4755f8(0x6e3)](0x2d)+'\x20'+(_0x4755f8(0xdf)+_0x17d35c+_0x4755f8(0xbe)+_0x4332fe+_0x4755f8(0x3ea)+_0x33dd4a+_0x4755f8(0x3e5)+_0x7a96ab+'\x0a'));}try{const _0x4dd181=new _0x210255(_0x1219bf['url'],_0x4755f8(0x72b)+_0x1219bf['headers'][_0x4755f8(0x2a4)]),_0x15f360=this[_0x4755f8(0x13f)](_0x1219bf[_0x4755f8(0x3f2)],_0x4dd181[_0x4755f8(0x48c)]),_0x58a805=_0x15f360?.[_0x4755f8(0x57f)]?.[_0x4755f8(0x770)]===!![];if(_0x58a805){const _0x2b5120=_0x1219bf[_0x4755f8(0x106)]?.[_0x4755f8(0x2c5)];if(_0x2b5120!=null){const _0x60c669=Number(_0x2b5120);if(Number[_0x4755f8(0x747)](_0x60c669)&&_0x60c669>this[_0x4755f8(0x67e)]){_0x445cd5[_0x4755f8(0x1db)]=0x19d,_0x445cd5[_0x4755f8(0x1a0)](_0x4755f8(0x62b));return;}}}const _0x6543e2=_0x58a805?null:await _0x44f099(_0x1219bf,this[_0x4755f8(0x67e)]),_0x336f3f=_0x58a805?_0x219741(_0x1219bf,this[_0x4755f8(0x67e)]):undefined,_0x3aa69c=await this[_0x4755f8(0x31f)](_0x1219bf[_0x4755f8(0x3f2)],_0x4dd181['pathname'],{'body':_0x6543e2,'query':Object[_0x4755f8(0x341)](_0x4dd181['searchParams'][_0x4755f8(0x377)]()),'headers':_0x1219bf[_0x4755f8(0x106)]},{'req':_0x1219bf,'res':_0x445cd5,'rawStream':_0x336f3f}),_0x29fff2=this[_0x4755f8(0x13f)](_0x1219bf[_0x4755f8(0x3f2)],_0x4dd181[_0x4755f8(0x48c)]),_0x2538c0=Date['now']()-_0x585725,_0x3b9529=this[_0x4755f8(0x653)](_0x29fff2,_0x3aa69c)?this['_wrapApiResponse'](_0x3aa69c,_0x2538c0):_0x14b20e(_0x3aa69c),_0x492527=(_0x3b9529[_0x4755f8(0x469)]||0xc8)>=0x190;this['metrics'][_0x4755f8(0x338)](_0x1219bf[_0x4755f8(0x3f2)],_0x2538c0,_0x492527),_0x4b86c4(_0x445cd5,_0x3b9529);if(_0x19cb4b){const _0x482d19=_0x3b9529[_0x4755f8(0x469)]||0xc8,_0xb93a9c=Date[_0x4755f8(0x6f1)]()-_0x585725;process[_0x4755f8(0x27e)][_0x4755f8(0xc6)](_0x4755f8(0x633)+_0x1219bf[_0x4755f8(0x3f2)][_0x4755f8(0x6e3)](0x7)+'\x20'+_0x4dd181[_0x4755f8(0x48c)][_0x4755f8(0x6e3)](0x2d)+'\x20'+_0x482d19+'\x20\x20'+_0xb93a9c+_0x4755f8(0x225));}}catch(_0x38ce0f){const _0x84eda1=Date[_0x4755f8(0x6f1)]()-_0x585725;this[_0x4755f8(0x496)][_0x4755f8(0x338)](_0x1219bf['method'],_0x84eda1,!![]);const _0x3b5e49=_0x38ce0f?.[_0x4755f8(0x469)]||0x1f4;_0x445cd5['statusCode']=_0x3b5e49,_0x3b5e49===0x19d?_0x445cd5['end'](_0x4755f8(0x62b)):_0x445cd5[_0x4755f8(0x1a0)](_0x38ce0f[_0x4755f8(0x71d)]||'Internal\x20error');}};this[_0x2b3c48(0x498)]=_0x11d756[_0x2b3c48(0x362)](_0x5d0dee=>{const _0x1adc5d=_0x2b3c48,_0x4e3f89=_0x53184a[_0x1adc5d(0x1d7)](_0x405066);_0x4e3f89['on'](_0x1adc5d(0x6cd),_0x53e2bd=>{const _0x8031e4=_0x1adc5d;this[_0x8031e4(0x78a)][_0x8031e4(0x5f3)](_0x53e2bd),_0x53e2bd['on'](_0x8031e4(0x57b),()=>this[_0x8031e4(0x78a)]['delete'](_0x53e2bd));});if(_0x5d0dee===undefined)_0x4e3f89[_0x1adc5d(0x416)](_0x3fd861);else _0x4e3f89[_0x1adc5d(0x416)](_0x3fd861,_0x5d0dee);return _0x4e3f89;}),this[_0x2b3c48(0x463)]=this[_0x2b3c48(0x498)][0x0];for(const _0x31d0a3 of this[_0x2b3c48(0x498)]['slice'](0x1))_0x31d0a3['on'](_0x2b3c48(0x1da),_0x2c0854=>this[_0x2b3c48(0x463)]?.[_0x2b3c48(0x454)]('error',_0x2c0854));const _0x4eb5cc=_0x59aad9(_0x3fd861,_0x2a4732[_0x2b3c48(0x2a4)]),_0x4b9264=this[_0x2b3c48(0x676)];return _0x4b9264?.[_0x2b3c48(0x5d0)]&&(_0x4b9264[_0x2b3c48(0x5d0)][_0x2b3c48(0x75d)](_0x4eb5cc),require$$1$1[_0x2b3c48(0x46e)]?_0x4b9264[_0x2b3c48(0x88)]?.({'kind':_0x2b3c48(0x701)})[_0x2b3c48(0x31d)](()=>{}):_0x4b9264['_activateProcesses']?.({'kind':_0x2b3c48(0x170),'listenAddr':_0x4eb5cc})[_0x2b3c48(0x31d)](()=>{})),this[_0x2b3c48(0x463)];}async[_0x41a5d4(0x57b)](_0x5cdaba={}){const _0x466249=_0x41a5d4,_0x2e51a2=this[_0x466249(0x463)];this[_0x466249(0x463)]=null;const _0x439c76=this[_0x466249(0x498)]['includes'](_0x2e51a2)?this[_0x466249(0x498)]:_0x2e51a2?[_0x2e51a2]:[];this[_0x466249(0x498)]=[];if(_0x2e51a2&&_0x2e51a2[_0x466249(0x3af)]){try{await _0x2e51a2[_0x466249(0x57b)]();}catch{}this[_0x466249(0x496)]&&this[_0x466249(0x496)][_0x466249(0x57b)]();return;}if(_0x439c76[_0x466249(0x2e8)]){const _0x474be6=Number[_0x466249(0x747)](_0x5cdaba[_0x466249(0x54d)])?Math[_0x466249(0x608)](0x0,_0x5cdaba['forceAfterMs']):0x3e8,_0x3c485c=_0x4eca80=>new Promise(_0x9a32d3=>{const _0x1e02c6=_0x466249;let _0x18e171=![],_0xd4fc40=null,_0xc3cdfc=null;const _0x24cc76=()=>{if(_0x18e171)return;_0x18e171=!![];if(_0xd4fc40)clearTimeout(_0xd4fc40);if(_0xc3cdfc)clearTimeout(_0xc3cdfc);_0x9a32d3();};try{_0x4eca80[_0x1e02c6(0x57b)](_0x24cc76);}catch{_0x24cc76();return;}try{_0x4eca80[_0x1e02c6(0x558)]?.();}catch{}_0xd4fc40=setTimeout(()=>{const _0x425435=_0x1e02c6;try{_0x4eca80['closeAllConnections']?.();}catch{}for(const _0x402a7d of this[_0x425435(0x78a)]){try{_0x402a7d[_0x425435(0x739)]();}catch{}}_0xc3cdfc=setTimeout(_0x24cc76,0x64),_0xc3cdfc['unref']?.();},_0x474be6),_0xd4fc40['unref']?.();});await Promise[_0x466249(0x447)](_0x439c76[_0x466249(0x362)](_0x3c485c));}this['metrics']&&this[_0x466249(0x496)][_0x466249(0x57b)]();}[_0x41a5d4(0x2d4)](_0x492d3c,_0x1e0418,_0x5e27b6=0x36ee80){const _0x1ac53c=_0x41a5d4,_0x4716a8=Date['now'](),_0x407254=Buffer['from'](JSON[_0x1ac53c(0x5bd)]({'iat':_0x4716a8,'exp':_0x4716a8+_0x5e27b6,..._0x492d3c}))[_0x1ac53c(0x3cb)](_0x1ac53c(0x638)),_0x46001f=_0xb1f799(_0x407254,_0x1e0418);return _0x407254+'.'+_0x46001f;}[_0x41a5d4(0x3ff)](_0x5250e0,_0x33fd87={}){const _0x2a5dea=_0x41a5d4,{httpOnly:httpOnly=!![],sameSite:sameSite=_0x2a5dea(0x736),path:path='/',secure:secure=![],maxAge:maxAge=null,expires:expires=null}=_0x33fd87;let _0x457a00=this['auth'][_0x2a5dea(0x1fb)]+'='+_0x5250e0;if(httpOnly)_0x457a00+=';\x20HttpOnly';if(sameSite)_0x457a00+=';\x20SameSite='+sameSite;if(path)_0x457a00+=';\x20Path='+path;if(secure)_0x457a00+=_0x2a5dea(0x41b);if(Number[_0x2a5dea(0x747)](maxAge))_0x457a00+=_0x2a5dea(0x684)+Math['max'](0x0,Math[_0x2a5dea(0x51e)](maxAge));if(expires instanceof Date)_0x457a00+=_0x2a5dea(0x1d4)+expires['toUTCString']();return _0x457a00;}['clearCookie'](_0x22cbc7=this[_0x41a5d4(0x9f)]['cookieName'],_0x5c7ca1={}){const _0x5c7769=_0x41a5d4,{path:path='/',sameSite:sameSite=_0x5c7769(0x736),secure:secure=![],httpOnly:httpOnly=!![]}=_0x5c7ca1;let _0x32aec2=_0x22cbc7+'=';if(httpOnly)_0x32aec2+=_0x5c7769(0x12e);if(sameSite)_0x32aec2+=_0x5c7769(0x4c4)+sameSite;if(path)_0x32aec2+=_0x5c7769(0x5a8)+path;if(secure)_0x32aec2+=_0x5c7769(0x41b);return _0x32aec2+=';\x20Max-Age=0;\x20Expires=Thu,\x2001\x20Jan\x201970\x2000:00:00\x20GMT',_0x32aec2;}[_0x41a5d4(0x215)](_0x279268,_0x10c907){const _0x2766ee=_0x41a5d4;if(!_0x279268)return null;const [_0x2f9c18,_0x140d43]=String(_0x279268)[_0x2766ee(0x527)]('.');if(!_0x2f9c18||!_0x140d43)return null;const _0x3d843e=_0xb1f799(_0x2f9c18,_0x10c907);if(!_0x3df55b(_0x140d43,_0x3d843e))return null;try{const _0xd3cbdd=JSON[_0x2766ee(0x110)](Buffer['from'](_0x2f9c18,_0x2766ee(0x638))[_0x2766ee(0x3cb)]());if(_0xd3cbdd[_0x2766ee(0x422)]<=Date['now']())return null;return _0xd3cbdd;}catch{return null;}}['parseBearer'](_0x306b2b){const _0x159213=_0x41a5d4;if(this['_okdb']?.[_0x159213(0x9f)])return this[_0x159213(0x676)][_0x159213(0x9f)][_0x159213(0x445)](_0x306b2b);return _0x469164(_0x306b2b);}[_0x41a5d4(0x1f2)](_0x4384dc){const _0x1ff0bf=_0x41a5d4;if(this[_0x1ff0bf(0x676)]?.[_0x1ff0bf(0x9f)])return this['_okdb'][_0x1ff0bf(0x9f)][_0x1ff0bf(0x1f2)](_0x4384dc);const _0x45fdb7=this[_0x1ff0bf(0xab)]?.[_0x1ff0bf(0x13d)]??0x36ee80,_0x2ccbf3=this[_0x1ff0bf(0xab)]?.[_0x1ff0bf(0xa5)];return _0x32466d(_0x4384dc,_0x2ccbf3,_0x45fdb7);}[_0x41a5d4(0x19f)](_0x4a3406){const _0x1d189f=_0x41a5d4;if(this[_0x1d189f(0x676)]?.[_0x1d189f(0x9f)])return this[_0x1d189f(0x676)][_0x1d189f(0x9f)][_0x1d189f(0x19f)](_0x4a3406);const _0x312e0d=this[_0x1d189f(0xab)]?.[_0x1d189f(0xa5)];return _0x3657fa(_0x4a3406,_0x312e0d);}async['authenticateRequest'](_0x1ae648){const _0x4ace0e=_0x41a5d4;if(this[_0x4ace0e(0x676)]?.['auth'])return this[_0x4ace0e(0x676)]['auth']['authenticateRequest'](_0x1ae648);if(_0x1ae648[_0x4ace0e(0x46d)]?.['internal']===!![]||this[_0x4ace0e(0x13c)]===_0x4ace0e(0x58f))return{'id':_0x4ace0e(0x374),'username':_0x4ace0e(0x374),'roles':['admin'],'isAuthenticated':!![],'isSystem':!![],'user':{'id':_0x4ace0e(0x374),'username':_0x4ace0e(0x374),'roles':['admin'],'isAuthenticated':!![],'isSystem':!![]}};const _0x2c8f12=this[_0x4ace0e(0x445)](_0x1ae648[_0x4ace0e(0x106)]?.['authorization']),_0xa321f4=_0x1ae648[_0x4ace0e(0x2ba)]?.[this[_0x4ace0e(0x9f)][_0x4ace0e(0x1fb)]],_0x3c22cd=_0x2c8f12||_0xa321f4;if(!_0x3c22cd)return{'isAuthenticated':![],'isSystem':![],'user':null};const _0x24fa00=this['authenticateToken'](_0x3c22cd);if(!_0x24fa00)return{'isAuthenticated':![],'isSystem':![],'user':null};const _0xba074a={'id':_0x24fa00[_0x4ace0e(0x2ed)]??null,'username':_0x24fa00[_0x4ace0e(0x4e3)]??null,'roles':Array[_0x4ace0e(0x259)](_0x24fa00[_0x4ace0e(0x5dd)])?_0x24fa00['roles']:[],'isAuthenticated':!![],'isSystem':![]};return{'id':_0xba074a['id'],'username':_0xba074a['username'],'roles':_0xba074a[_0x4ace0e(0x5dd)],'isAuthenticated':!![],'isSystem':![],'user':_0xba074a,'claims':_0x24fa00,'subject':_0xba074a['id']};}async['_validateOidcAccessToken'](_0x27cef7,_0x11fd5e={}){const _0x1dc661=_0x41a5d4,_0x1f4cdb=_0x30383a(_0x27cef7),_0x4eb84f=Array[_0x1dc661(0x259)](_0x11fd5e[_0x1dc661(0xfc)])&&_0x11fd5e[_0x1dc661(0xfc)][_0x1dc661(0x2e8)]>0x0?_0x11fd5e['allowedAlgs']:['RS256',_0x1dc661(0x119)],_0x2d9f0a=_0x1f4cdb[_0x1dc661(0x721)]?.[_0x1dc661(0x30c)];if(!_0x4eb84f[_0x1dc661(0x243)](_0x2d9f0a))throw new Error(_0x1dc661(0x9c)+_0x2d9f0a);if(!_0x1f4cdb[_0x1dc661(0x721)]?.[_0x1dc661(0x71e)])throw new Error(_0x1dc661(0x79e));const _0x398049=await this[_0x1dc661(0x121)](_0x11fd5e);if(!_0x398049?.[_0x1dc661(0x96)])throw new Error(_0x1dc661(0x3f8));const _0x3e980c=await this[_0x1dc661(0x566)](_0x398049[_0x1dc661(0x96)],_0x1f4cdb[_0x1dc661(0x721)]['kid'],_0x11fd5e);if(!_0x36d463(_0x2d9f0a,_0x3e980c,_0x1f4cdb[_0x1dc661(0xcb)],_0x1f4cdb[_0x1dc661(0x660)]))throw new Error(_0x1dc661(0x292));const _0x4e5598=Math['floor'](Date[_0x1dc661(0x6f1)]()/0x3e8),_0x15a3d0=_0x1f4cdb[_0x1dc661(0x273)]||{};if(_0x15a3d0[_0x1dc661(0x8a)]!==_0x398049[_0x1dc661(0x40c)])throw new Error(_0x1dc661(0x5b8));const _0x2f0100=_0x11fd5e['audience'];if(_0x2f0100){const _0x28c4e8=_0x3f4984(_0x15a3d0['aud']);if(!_0x28c4e8[_0x1dc661(0x243)](_0x2f0100))throw new Error(_0x1dc661(0x77c));}if(typeof _0x15a3d0[_0x1dc661(0x422)]!==_0x1dc661(0x3f5)||_0x15a3d0[_0x1dc661(0x422)]<=_0x4e5598)throw new Error(_0x1dc661(0x63e));if(_0x15a3d0[_0x1dc661(0x434)]!=null&&_0x15a3d0['nbf']>_0x4e5598)throw new Error(_0x1dc661(0x3ce));if(_0x15a3d0[_0x1dc661(0x26d)]==='id')throw new Error(_0x1dc661(0x1a2));return{'subject':_0x15a3d0[_0x1dc661(0x2ed)]??null,'email':_0x15a3d0[_0x1dc661(0x57e)]??null,'scopes':typeof _0x15a3d0[_0x1dc661(0x293)]===_0x1dc661(0x139)?_0x15a3d0[_0x1dc661(0x293)]['split'](/\s+/)['filter'](Boolean):[],'claims':_0x15a3d0,'tokenType':'access'};}async['_getOidcDiscovery'](_0x418171={}){const _0x412e88=_0x41a5d4,_0x367d56=String(_0x418171['issuer']||'')['replace'](/\/+$/,'');if(!_0x367d56)return null;const _0xdec00e=Number[_0x412e88(0x747)](_0x418171['discoveryTtlMs'])?_0x418171[_0x412e88(0x25d)]:0xa*0x3c*0x3e8;if(this[_0x412e88(0x16e)]?.['issuer']===_0x367d56&&this['_oidcDiscoveryCache'][_0x412e88(0x738)]>Date[_0x412e88(0x6f1)]())return this[_0x412e88(0x16e)][_0x412e88(0x1c5)];const _0x4a529d=await _0x4880ac(_0x367d56+_0x412e88(0xf9)),_0x3bd988={'issuer':_0x4a529d[_0x412e88(0x40c)]||_0x367d56,'authorization_endpoint':_0x418171[_0x412e88(0x6a1)]||_0x4a529d[_0x412e88(0x365)],'token_endpoint':_0x418171[_0x412e88(0x7b)]||_0x4a529d[_0x412e88(0x311)],'jwks_uri':_0x418171[_0x412e88(0x694)]||_0x4a529d[_0x412e88(0x96)]};return this[_0x412e88(0x16e)]={'issuer':_0x367d56,'value':_0x3bd988,'expiresAt':Date[_0x412e88(0x6f1)]()+_0xdec00e},_0x3bd988;}async[_0x41a5d4(0x503)](_0x4e0c9f,_0x35fb38=0x5*0x3c*0x3e8){const _0x166f4d=_0x41a5d4,_0x192b3e=await _0x4880ac(_0x4e0c9f),_0x5383d8=new Map();for(const _0x4a4d28 of _0x192b3e['keys']||[]){if(!_0x4a4d28?.['kid'])continue;_0x5383d8[_0x166f4d(0x543)](_0x4a4d28[_0x166f4d(0x71e)],_0x45bbce(_0x4a4d28));}return this[_0x166f4d(0x596)]={'uri':_0x4e0c9f,'keys':_0x5383d8,'expiresAt':Date[_0x166f4d(0x6f1)]()+_0x35fb38},this[_0x166f4d(0x596)];}async[_0x41a5d4(0x566)](_0x544d03,_0x4252ba,_0x3c42a0={}){const _0x321375=_0x41a5d4,_0x1f5e8a=Number['isFinite'](_0x3c42a0[_0x321375(0x16c)])?_0x3c42a0[_0x321375(0x16c)]:0x5*0x3c*0x3e8,_0x20f476=0x1e*0x3e8,_0x2bcc79=this[_0x321375(0x29a)][_0x321375(0x741)](_0x4252ba);if(_0x2bcc79!==undefined&&_0x2bcc79>Date[_0x321375(0x6f1)]())throw new Error(_0x321375(0x8d)+_0x4252ba);(!this[_0x321375(0x596)]||this[_0x321375(0x596)][_0x321375(0x3db)]!==_0x544d03||this[_0x321375(0x596)]['expiresAt']<=Date[_0x321375(0x6f1)]())&&await this[_0x321375(0x503)](_0x544d03,_0x1f5e8a);let _0x5790c3=this[_0x321375(0x596)]?.[_0x321375(0x449)]?.['get'](_0x4252ba);if(_0x5790c3)return _0x5790c3;await this[_0x321375(0x503)](_0x544d03,_0x1f5e8a),_0x5790c3=this[_0x321375(0x596)]?.[_0x321375(0x449)]?.[_0x321375(0x741)](_0x4252ba);if(!_0x5790c3){this['_jwksNegativeCache']['set'](_0x4252ba,Date[_0x321375(0x6f1)]()+_0x20f476);throw new Error(_0x321375(0x8d)+_0x4252ba);}return _0x5790c3;}[_0x41a5d4(0x47f)](_0x204e2e){const _0x5458e0=_0x41a5d4;if(this[_0x5458e0(0x676)]?.[_0x5458e0(0x9f)])return this['_okdb'][_0x5458e0(0x9f)][_0x5458e0(0x47f)](_0x204e2e);const _0x27a4a9=_0x204e2e?.[_0x5458e0(0x1e3)]||{},_0x130087={'sub':_0x204e2e?.[_0x5458e0(0xc3)]??_0x27a4a9[_0x5458e0(0x2ed)]??null,'email':_0x204e2e?.[_0x5458e0(0x57e)]??_0x27a4a9[_0x5458e0(0x57e)]??null,'name':_0x204e2e?.[_0x5458e0(0x58e)]??_0x27a4a9['name']??_0x27a4a9[_0x5458e0(0x386)]??null,'groups':_0x204e2e?.['groups']??_0x27a4a9[_0x5458e0(0x446)]??[],'roles':_0x204e2e?.[_0x5458e0(0x5dd)]??_0x27a4a9[_0x5458e0(0x5dd)]??[]};return{'type':_0x5458e0(0x6b8),'tokenType':_0x204e2e?.[_0x5458e0(0x542)]??_0x5458e0(0x2d6),'subject':_0x130087[_0x5458e0(0x2ed)],'email':_0x130087[_0x5458e0(0x57e)],'scopes':_0x204e2e?.[_0x5458e0(0xad)]??_0x27a4a9[_0x5458e0(0x293)]?.[_0x5458e0(0x527)]?.('\x20')?.[_0x5458e0(0x20f)](Boolean)??[],'claims':_0x27a4a9,'user':_0x130087,'isAuthenticated':!![]};}[_0x41a5d4(0x266)](_0x3a8be3={},_0x16587d=0x927c0){const _0x48233d=_0x41a5d4;if(this['_okdb']?.[_0x48233d(0x9f)])return this[_0x48233d(0x676)]['auth'][_0x48233d(0x266)](_0x3a8be3,_0x16587d);const _0x260df2=_0x4953b5(0x18);this[_0x48233d(0x313)][_0x48233d(0x543)](_0x260df2,{..._0x3a8be3,'exp':Date[_0x48233d(0x6f1)]()+_0x16587d});if(this[_0x48233d(0x313)]['size']%0x32===0x0){const _0x2e746a=Date[_0x48233d(0x6f1)]();for(const [_0x16a75d,_0x16595d]of this[_0x48233d(0x313)]){if(_0x16595d[_0x48233d(0x422)]<=_0x2e746a)this['_loginStates']['delete'](_0x16a75d);}}return _0x260df2;}[_0x41a5d4(0x6c2)](_0x5844c5){const _0x2d0271=_0x41a5d4;if(this[_0x2d0271(0x676)]?.[_0x2d0271(0x9f)])return this['_okdb']['auth']['consumeLoginState'](_0x5844c5);if(!_0x5844c5)return null;const _0x5a812f=this['_loginStates'][_0x2d0271(0x741)](_0x5844c5);this[_0x2d0271(0x313)][_0x2d0271(0x210)](_0x5844c5);if(!_0x5a812f)return null;if(_0x5a812f['exp']<=Date['now']())return null;return _0x5a812f;}}function _0x14b20e(_0x4ba279){const _0xd3f5b=_0x41a5d4;if(_0x4ba279==null)return{'status':0xcc};if(Buffer[_0xd3f5b(0x791)](_0x4ba279)||_0x2a98e7(_0x4ba279))return{'status':0xc8,'body':_0x4ba279};if(typeof _0x4ba279==='object'&&_0xd3f5b(0x469)in _0x4ba279){if(!(_0xd3f5b(0x772)in _0x4ba279)&&!_0x2a98e7(_0x4ba279[_0xd3f5b(0x772)])){const {status:_0x2db560,headers:_0x187820,..._0x4fb0bb}=_0x4ba279;if(Object[_0xd3f5b(0x449)](_0x4fb0bb)['length']>0x0)return{'status':_0x2db560,'headers':_0x187820,'body':_0x4fb0bb};}return _0x4ba279;}return{'status':0xc8,'body':_0x4ba279};}function _0x2a98e7(_0xca734){const _0x34b368=_0x41a5d4;return _0xca734&&typeof _0xca734[_0x34b368(0x1e1)]===_0x34b368(0x18e);}function _0x219741(_0xa8caf7,_0x3b2f4e){const _0x2835d8=_0x41a5d4,{PassThrough:_0xb7b83e}=require$$5;let _0x925d0a=0x0,_0x3f523c=![];const _0x5bd9cc=new _0xb7b83e();return _0xa8caf7['on'](_0x2835d8(0x516),_0x27a83c=>{const _0x225bea=_0x2835d8;if(_0x3f523c)return;_0x925d0a+=_0x27a83c[_0x225bea(0x2e8)];if(_0x925d0a>_0x3b2f4e){_0x3f523c=!![];const _0x2e2eb2=new Error('Payload\x20too\x20large');_0x2e2eb2[_0x225bea(0x469)]=0x19d,_0x5bd9cc[_0x225bea(0x739)](_0x2e2eb2);return;}if(!_0x5bd9cc['destroyed'])_0x5bd9cc[_0x225bea(0x1c2)](_0x27a83c);}),_0xa8caf7['on'](_0x2835d8(0x1a0),()=>{const _0x3e99c7=_0x2835d8;!_0x3f523c&&!_0x5bd9cc[_0x3e99c7(0x6a9)]&&(_0x3f523c=!![],_0x5bd9cc['end']());}),_0xa8caf7['on'](_0x2835d8(0x1da),_0x1f5d9d=>{const _0xd43017=_0x2835d8;if(!_0x5bd9cc[_0xd43017(0x6a9)])_0x5bd9cc[_0xd43017(0x739)](_0x1f5d9d);}),_0xa8caf7[_0x2835d8(0x659)](),_0x5bd9cc['on'](_0x2835d8(0x4b3),()=>{const _0x5cd1ab=_0x2835d8;if(!_0x5bd9cc[_0x5cd1ab(0x6a9)])_0xa8caf7[_0x5cd1ab(0x4b3)]();}),_0x5bd9cc;}function _0x44f099(_0x192966,_0x419b6e){const _0x11ded4=_0x41a5d4;if(_0x192966[_0x11ded4(0x3f2)]==='GET'||_0x192966[_0x11ded4(0x3f2)]===_0x11ded4(0x2d2))return null;const _0x545172=_0x192966[_0x11ded4(0x106)]?.[_0x11ded4(0x2c5)];if(_0x545172!=null){const _0xb91678=Number(_0x545172);if(Number['isFinite'](_0xb91678)&&_0xb91678>_0x419b6e){const _0x361317=new Error(_0x11ded4(0x62b));_0x361317[_0x11ded4(0x469)]=0x19d;throw _0x361317;}}return new Promise((_0x5da1bb,_0x5c6985)=>{const _0x1b824e=_0x11ded4;let _0x4b6093='',_0x427eae=0x0;_0x192966['on'](_0x1b824e(0x516),_0x3a1881=>{const _0x365912=_0x1b824e;_0x427eae+=_0x3a1881['length'];if(_0x427eae>_0x419b6e){try{_0x192966[_0x365912(0x739)]();}catch{}const _0x261f3e=new Error(_0x365912(0x62b));_0x261f3e[_0x365912(0x469)]=0x19d,_0x5c6985(_0x261f3e);return;}_0x4b6093+=_0x3a1881;}),_0x192966['on'](_0x1b824e(0x1a0),()=>{const _0x1d748c=_0x1b824e;if(!_0x4b6093)return _0x5da1bb(null);const _0x2360c1=_0x192966['headers']?.[_0x1d748c(0x235)]||'';if(_0x2360c1[_0x1d748c(0x243)]('application/x-www-form-urlencoded')){const _0x2f822d={};for(const [_0x2ea052,_0xd93566]of new URLSearchParams(_0x4b6093))_0x2f822d[_0x2ea052]=_0xd93566;return _0x5da1bb(_0x2f822d);}try{_0x5da1bb(JSON[_0x1d748c(0x110)](_0x4b6093));}catch(_0x3a0712){_0x5c6985(_0x3a0712);}}),_0x192966['on'](_0x1b824e(0x1da),_0x5c6985);});}function _0x4b86c4(_0x26c7c1,_0x231de5){const _0x1e9b49=_0x41a5d4,{status:status=0xc8,headers:headers={},body:_0x1b49df}=_0x231de5;_0x26c7c1[_0x1e9b49(0x1db)]=status;for(const [_0x49d79c,_0x424f2d]of Object['entries'](headers)){_0x26c7c1[_0x1e9b49(0x63b)](_0x49d79c,_0x424f2d);}if(_0x1b49df==null){_0x26c7c1[_0x1e9b49(0x1a0)]();return;}if(_0x2a98e7(_0x1b49df)){_0x1b49df[_0x1e9b49(0x1e1)](_0x26c7c1);return;}if(Buffer[_0x1e9b49(0x791)](_0x1b49df)){_0x26c7c1[_0x1e9b49(0x1a0)](_0x1b49df);return;}if(typeof _0x1b49df==='object'){!_0x26c7c1[_0x1e9b49(0x60c)](_0x1e9b49(0x1b2))&&_0x26c7c1[_0x1e9b49(0x63b)]('Content-Type',_0x1e9b49(0x766));_0x26c7c1[_0x1e9b49(0x1a0)](JSON[_0x1e9b49(0x5bd)](_0x1b49df));return;}_0x26c7c1['end'](String(_0x1b49df));}function _0x59aad9(_0x55cb68,_0x248512){const _0x41160a=_0x41a5d4;if(_0x248512==null)return':'+_0x55cb68;return[][_0x41160a(0x4e0)](_0x248512)[_0x41160a(0x362)](_0x2beba6=>(_0x2beba6[_0x41160a(0x243)](':')?'['+_0x2beba6+']':_0x2beba6)+':'+_0x55cb68)[_0x41160a(0x546)](',\x20');}return okdbHttp[_0x41a5d4(0x761)]=_0x52b9f3,okdbHttp[_0x41a5d4(0x761)]['formatListenAddr']=_0x59aad9,okdbHttp[_0x41a5d4(0x761)][_0x41a5d4(0x6b3)]=_0x47923a,okdbHttp[_0x41a5d4(0x761)];}var okdbShmSegment,hasRequiredOkdbShmSegment;function requireOkdbShmSegment(){const _0x10d8c8=_0x1cb9ed;if(hasRequiredOkdbShmSegment)return okdbShmSegment;hasRequiredOkdbShmSegment=0x1;const _0x436d71=require$$0$1,_0x4c5dab=require$$2$1,_0x37f205=0x80,_0x2059bc=0x0,_0x8866d=0x1,_0x6d9982=0x2,_0x19f477=0x3,_0x5dd7e3=0x4,_0x3f9bab=_0x5dd7e3+_0x37f205,_0x3796d7=_0x3f9bab+_0x37f205,_0x41347c=require$$2$3[_0x10d8c8(0x34d)],_0x2cc3db=_0x3796d7*0x4,_0x30872e=process[_0x10d8c8(0x6af)]!=='win32',_0x415cda=0xc,_0x1c5392=process[_0x10d8c8(0x6af)]===_0x10d8c8(0x128)?0x1f:0xa0,_0x3ddf61=/^[A-Za-z0-9-]+(?:_boot)?$/,_0x460650=/^[A-Za-z0-9-]*-[0-9a-f]{12}(?:_boot)?$/,_0x4fd2be=_0x21926e=>_0x21926e['replace'](/[^a-zA-Z0-9]/g,'-');function _0x5d9715(_0x1563bf,_0x23ded1=''){const _0x242ab2=_0x10d8c8;if(typeof _0x1563bf!==_0x242ab2(0x139)||_0x1563bf==='')throw new TypeError(_0x242ab2(0x47e));if(_0x23ded1!==''&&!/^_[A-Za-z0-9]+$/[_0x242ab2(0x86)](_0x23ded1))throw new TypeError('segmentNameFor:\x20suffix\x20must\x20look\x20like\x20\x22_name\x22\x20(got\x20'+JSON[_0x242ab2(0x5bd)](_0x23ded1)+')');const _0x47206c=_0x4c5dab['createHash'](_0x242ab2(0x42f))[_0x242ab2(0x3ec)](_0x1563bf)[_0x242ab2(0x586)]('hex')[_0x242ab2(0x762)](0x0,_0x415cda),_0xfc5a8d=Math[_0x242ab2(0x608)](0x0,_0x1c5392-0x1-_0x415cda-_0x23ded1[_0x242ab2(0x2e8)]);return _0x4fd2be(_0x1563bf)[_0x242ab2(0x762)](0x0,_0xfc5a8d)+'-'+_0x47206c+_0x23ded1;}function _0x73162f(_0x129a25,_0x2afa1b=''){return''+_0x4fd2be(_0x129a25)+_0x2afa1b;}function _0x383b84(_0x1d58dc){const _0x1b574d=_0x10d8c8;if(_0x460650[_0x1b574d(0x86)](_0x1d58dc))return _0x1b574d(0x282);if(_0x3ddf61[_0x1b574d(0x86)](_0x1d58dc))return _0x1b574d(0x344);return null;}const _0x5a13a4={'onMapped':null,'onClaimed':null,'onRetiring':null},_0x4eb516=_0x10e488=>Math['ceil'](_0x10e488/0x8)*0x8,_0x1e0a4d=_0x2f8da5=>_0x4eb516(_0x2f8da5)+_0x2cc3db;function _0x1c2539(_0x104488){const _0x1b94d5=_0x10d8c8;try{return process[_0x1b94d5(0x2e2)](_0x104488,0x0),![];}catch(_0x4bc8a7){return _0x4bc8a7[_0x1b94d5(0x72d)]===_0x1b94d5(0x563);}}const _0x390205=new Int32Array(new SharedArrayBuffer(0x4));function _0x1e8057(_0x354f7f){const _0x17af91=_0x10d8c8;if(_0x354f7f>0x0)Atomics[_0x17af91(0x796)](_0x390205,0x0,0x0,_0x354f7f);}function _0x8cc522(_0x295c67,_0xa15fa6){const _0x21801d=_0x10d8c8;if(process[_0x21801d(0x6af)]!==_0x21801d(0x24d))return;let _0x1c1ae1;try{_0x1c1ae1=_0x436d71[_0x21801d(0x59d)](_0x21801d(0x4d1)+_0x295c67,'r+');if(_0x436d71['fstatSync'](_0x1c1ae1)[_0x21801d(0x54a)]<_0xa15fa6)_0x436d71[_0x21801d(0x3a4)](_0x1c1ae1,_0xa15fa6);}catch{}finally{if(_0x1c1ae1!==undefined)try{_0x436d71[_0x21801d(0x640)](_0x1c1ae1);}catch{}}}function _0x247a63(_0x998300,_0xbf7ba){const _0x168478=_0x10d8c8,_0x3cd00e=require$$3$1;for(let _0x3d2ebc=0x0;;_0x3d2ebc++){try{return _0x3cd00e['open'](_0x998300,_0xbf7ba);}catch(_0x2216bd){if(_0x3d2ebc>=0x3e8||!/No such file or directory/['test'](_0x2216bd?.[_0x168478(0x71d)]??''))throw _0x2216bd;}}}function _0x4f28e4(_0x2b3ffb,_0x3f692d){const _0x127030=_0x10d8c8,_0x399c37=_0x1e0a4d(_0x3f692d),_0x5d711e=_0x247a63(_0x2b3ffb,_0x399c37);_0x8cc522(_0x2b3ffb,_0x399c37);if(_0x5d711e['byteLength']<_0x399c37)throw new Error(_0x127030(0x645)+_0x2b3ffb+':\x20mapped\x20'+_0x5d711e[_0x127030(0x592)]+'\x20<\x20'+_0x399c37+'\x20bytes');return{'sab':_0x5d711e,'hdr':new Int32Array(_0x5d711e,_0x4eb516(_0x3f692d),_0x3796d7)};}function _0x2736b2(_0x292c38){const _0xcf5424=_0x10d8c8;try{require(_0xcf5424(0x6ce))[_0xcf5424(0x57b)](_0x292c38);}catch{}}function _0x1eec02(_0xd617e2){const _0x1ce2d5=_0x10d8c8;try{require(_0x1ce2d5(0x6ce))[_0x1ce2d5(0x361)](_0xd617e2);}catch{}}function _0xae5d9b(_0x24d159){const _0x155e9d=_0x10d8c8;if(Atomics[_0x155e9d(0x52f)](_0x24d159,_0x6d9982)!==0x0&&Atomics['load'](_0x24d159,_0x19f477)!==0x0)return;const _0x26d021=_0x4c5dab[_0x155e9d(0x269)](0x8),_0x4cbc73=_0x26d021['readInt32LE'](0x0)||0x1,_0x5a3bbe=_0x26d021[_0x155e9d(0x4fa)](0x4)||0x1;Atomics[_0x155e9d(0x6d8)](_0x24d159,_0x6d9982,0x0,_0x4cbc73),Atomics[_0x155e9d(0x6d8)](_0x24d159,_0x19f477,0x0,_0x5a3bbe);}function _0x4778ea(_0x4a3994){const _0x1991d3=_0x10d8c8,_0x5ed2d2=process[_0x1991d3(0x401)];for(let _0xba335a=0x0;_0xba335a<_0x37f205;_0xba335a++){const _0x55ebae=Atomics[_0x1991d3(0x52f)](_0x4a3994,_0x5dd7e3+_0xba335a);if(_0x55ebae===0x0||_0x55ebae===_0x5ed2d2)continue;if(!_0x1c2539(_0x55ebae))continue;Atomics[_0x1991d3(0x262)](_0x4a3994,_0x3f9bab+_0xba335a,0x0),Atomics[_0x1991d3(0x6d8)](_0x4a3994,_0x5dd7e3+_0xba335a,_0x55ebae,0x0);}}function _0x40f533(_0x3de674){const _0x3b6f46=_0x10d8c8;if(Atomics[_0x3b6f46(0x52f)](_0x3de674,_0x8866d)!==0x0)return!![];for(let _0x3594f7=0x0;_0x3594f7<_0x37f205;_0x3594f7++)if(Atomics[_0x3b6f46(0x52f)](_0x3de674,_0x5dd7e3+_0x3594f7)!==0x0)return!![];return![];}function _0x224b69(_0x59b2ea){const _0xa8c46a=_0x10d8c8,_0x320543=process[_0xa8c46a(0x401)];for(let _0x4ee5d0=0x0;_0x4ee5d0<0x2;_0x4ee5d0++){for(let _0x1d238b=0x0;_0x1d238b<_0x37f205;_0x1d238b++){if(Atomics['compareExchange'](_0x59b2ea,_0x5dd7e3+_0x1d238b,0x0,_0x320543)===0x0)return Atomics[_0xa8c46a(0x262)](_0x59b2ea,_0x3f9bab+_0x1d238b,_0x41347c),_0x1d238b;}_0x4778ea(_0x59b2ea);}return Atomics[_0xa8c46a(0x5f3)](_0x59b2ea,_0x8866d,0x1),-0x1;}function _0x4d9a8f(_0x253e62,_0x22e868){const _0x1cef23=_0x10d8c8;if(_0x22e868>=0x0)Atomics[_0x1cef23(0x262)](_0x253e62,_0x3f9bab+_0x22e868,0x0),Atomics[_0x1cef23(0x6d8)](_0x253e62,_0x5dd7e3+_0x22e868,process[_0x1cef23(0x401)],0x0);else Atomics[_0x1cef23(0x2ed)](_0x253e62,_0x8866d,0x1);}function _0x3ddcf4(_0x17d82d,_0x2f815b,_0x4dd444,_0x3e6dea){const _0x157878=_0x10d8c8,_0x349285=process['pid'];if(Atomics[_0x157878(0x6d8)](_0x4dd444,_0x2059bc,_0x3e6dea,_0x349285)!==_0x3e6dea)return _0x157878(0x134);const _0x141d9c=Atomics[_0x157878(0x52f)](_0x4dd444,_0x6d9982),_0xd1ee2c=Atomics[_0x157878(0x52f)](_0x4dd444,_0x19f477);let _0x3cedc6;try{_0x3cedc6=_0x4f28e4(_0x17d82d,_0x2f815b)['hdr'];}catch{return _0x157878(0x66a);}if(Atomics[_0x157878(0x52f)](_0x3cedc6,_0x6d9982)!==_0x141d9c||Atomics[_0x157878(0x52f)](_0x3cedc6,_0x19f477)!==_0xd1ee2c)return _0x157878(0x66a);_0x4778ea(_0x4dd444);if(_0x40f533(_0x4dd444))return Atomics[_0x157878(0x6d8)](_0x4dd444,_0x2059bc,_0x349285,0x0),_0x157878(0x16d);return _0x1eec02(_0x17d82d),'unlinked';}function _0xf1421f(_0x9ad5e8,_0x3aa338,{timeoutMs:_0x14500e}={}){const _0x11649c=_0x10d8c8;_0x14500e=_0x14500e??(Number(process.env.OKDB_SHM_ATTACH_TIMEOUT_MS)||0x7530);const _0x118de5=process[_0x11649c(0x401)],_0x39338c=Date['now']()+_0x14500e;for(let _0x1277fb=0x0;;_0x1277fb++){const {sab:_0x5ec117,hdr:_0x725c5c}=_0x4f28e4(_0x9ad5e8,_0x3aa338);_0x5a13a4[_0x11649c(0x99)]?.(_0x9ad5e8,_0x1277fb),_0xae5d9b(_0x725c5c);const _0x1e6c87=_0x224b69(_0x725c5c);_0x5a13a4[_0x11649c(0x325)]?.(_0x9ad5e8,_0x1277fb);const _0x303527=Atomics[_0x11649c(0x52f)](_0x725c5c,_0x2059bc);if(_0x303527===0x0||!_0x30872e){if(_0x1277fb===0x0)_0x4778ea(_0x725c5c);return{'sab':_0x5ec117,'hdr':_0x725c5c,'slot':_0x1e6c87};}_0x4d9a8f(_0x725c5c,_0x1e6c87);if(_0x303527!==_0x118de5&&_0x1c2539(_0x303527))_0x3ddcf4(_0x9ad5e8,_0x3aa338,_0x725c5c,_0x303527);_0x2736b2(_0x9ad5e8);if(Date[_0x11649c(0x6f1)]()>_0x39338c){const {OKDBError:_0x440249}=requireOkdbError();throw new _0x440249(_0x11649c(0x577)+_0x9ad5e8+_0x11649c(0x76c)+_0x14500e+_0x11649c(0x68e)+_0x303527+_0x11649c(0x612)+'stop\x20every\x20okdb\x20process\x20on\x20this\x20path\x20and\x20run\x20`okdb\x20shm-gc`.',_0x11649c(0x5f4));}_0x1e8057(_0x1277fb<0x14?0x0:0x1);}}function _0x445781(_0x217bc9,_0x114604,_0x5d43cd,_0x457ea2){const _0x5d7f17=_0x10d8c8,{hdr:_0x306d32,slot:_0x2774b5}=_0x5d43cd;if(_0x2774b5!==null)_0x4d9a8f(_0x306d32,_0x2774b5);let _0x3acbbd=![];try{if(!_0x30872e)return![];const _0x48f3af=process[_0x5d7f17(0x401)];_0x4778ea(_0x306d32);if(_0x40f533(_0x306d32)||_0x457ea2?.(_0x5d43cd[_0x5d7f17(0x2b5)]))return![];if(Atomics[_0x5d7f17(0x6d8)](_0x306d32,_0x2059bc,0x0,_0x48f3af)!==0x0)return![];let _0x8b7b0d=!![];try{_0x5a13a4[_0x5d7f17(0xfb)]?.(_0x217bc9),!_0x40f533(_0x306d32)&&!_0x457ea2?.(_0x5d43cd['sab'])&&(_0x8b7b0d=![],_0x1eec02(_0x217bc9),_0x3acbbd=!![]);}finally{if(_0x8b7b0d)Atomics['compareExchange'](_0x306d32,_0x2059bc,_0x48f3af,0x0);}return _0x3acbbd;}finally{_0x2736b2(_0x217bc9);}}function _0x38176f(_0x247625,_0x2ff096,{isBusy:_0x45d58f}={}){const _0x1d11af=_0x10d8c8,_0x385cd3=process[_0x1d11af(0x401)],{sab:_0x4b5d30,hdr:_0x4df43e}=_0x4f28e4(_0x247625,_0x2ff096);try{_0x4778ea(_0x4df43e);const _0x3d3931=Atomics[_0x1d11af(0x52f)](_0x4df43e,_0x2059bc);if(_0x3d3931!==0x0){if(_0x3d3931===_0x385cd3||!_0x1c2539(_0x3d3931))return'retiring';return _0x3ddcf4(_0x247625,_0x2ff096,_0x4df43e,_0x3d3931);}if(_0x40f533(_0x4df43e))return _0x1d11af(0x61d);if(_0x45d58f?.(_0x4b5d30))return _0x1d11af(0x35c);if(Atomics[_0x1d11af(0x6d8)](_0x4df43e,_0x2059bc,0x0,_0x385cd3)!==0x0)return _0x1d11af(0x53d);if(_0x40f533(_0x4df43e)||_0x45d58f?.(_0x4b5d30))return Atomics[_0x1d11af(0x6d8)](_0x4df43e,_0x2059bc,_0x385cd3,0x0),_0x1d11af(0x61d);return _0x1eec02(_0x247625),_0x1d11af(0x776);}finally{_0x2736b2(_0x247625);}}const _0x3f19b1=new Map(),_0x1d38f2=new Set();function _0x374260(_0x1c1f00){const _0x4c53c5=_0x10d8c8,_0x61e6d3=process[_0x4c53c5(0x401)];for(let _0x3a8a56=0x0;_0x3a8a56<_0x37f205;_0x3a8a56++){if(Atomics[_0x4c53c5(0x52f)](_0x1c1f00,_0x5dd7e3+_0x3a8a56)===_0x61e6d3&&Atomics[_0x4c53c5(0x52f)](_0x1c1f00,_0x3f9bab+_0x3a8a56)!==_0x41347c)return!![];}return![];}function _0x414249(_0x19dd22,_0x353dca,_0x575c8e={}){const _0x511a57=_0x10d8c8;let _0x21d63f=_0x3f19b1[_0x511a57(0x741)](_0x19dd22);if(!_0x21d63f){const _0x357826=_0xf1421f(_0x19dd22,_0x353dca,_0x575c8e);_0x21d63f={'att':_0x357826,'dataBytes':_0x353dca,'refs':0x0,'isBusy':_0x575c8e[_0x511a57(0x663)]??null,'onThreadExit':_0x575c8e[_0x511a57(0x32a)]??null},_0x3f19b1[_0x511a57(0x543)](_0x19dd22,_0x21d63f);}if(_0x575c8e['isBusy'])_0x21d63f[_0x511a57(0x663)]=_0x575c8e[_0x511a57(0x663)];if(_0x575c8e[_0x511a57(0x32a)])_0x21d63f[_0x511a57(0x32a)]=_0x575c8e[_0x511a57(0x32a)];_0x21d63f[_0x511a57(0x209)]++;let _0xaef071=![];return{'sab':_0x21d63f[_0x511a57(0xac)][_0x511a57(0x2b5)],'name':_0x19dd22,'release'(){const _0x3bb1a3=_0x511a57;if(_0xaef071)return![];_0xaef071=!![];if(--_0x21d63f[_0x3bb1a3(0x209)]>0x0)return![];if(_0x3f19b1[_0x3bb1a3(0x741)](_0x19dd22)===_0x21d63f)_0x3f19b1['delete'](_0x19dd22);const _0x4b4843=_0x445781(_0x19dd22,_0x21d63f[_0x3bb1a3(0x697)],_0x21d63f[_0x3bb1a3(0xac)],_0x21d63f[_0x3bb1a3(0x663)]);!_0x4b4843&&_0x30872e&&_0x374260(_0x21d63f[_0x3bb1a3(0xac)][_0x3bb1a3(0x70)])&&_0x1d38f2[_0x3bb1a3(0x5f3)]({'name':_0x19dd22,'dataBytes':_0x21d63f[_0x3bb1a3(0x697)],'att':{..._0x21d63f[_0x3bb1a3(0xac)],'slot':null},'isBusy':_0x21d63f[_0x3bb1a3(0x663)],'onThreadExit':_0x21d63f[_0x3bb1a3(0x32a)]});if(_0x1d38f2[_0x3bb1a3(0x54a)])_0x380bea();return _0x4b4843;}};}function _0x12dc1c(_0x23e616){const _0x233702=_0x10d8c8;if(!(_0x23e616>0x0))return 0x0;const _0x4202d4=process[_0x233702(0x401)];let _0x7cdf4c=0x0;const _0x8e50f0=({att:_0x3d1e7a,onThreadExit:_0x57fd14})=>{const _0x515ecf=_0x233702;try{_0x57fd14?.(_0x3d1e7a[_0x515ecf(0x2b5)],_0x23e616);}catch{}const {hdr:_0x3b845f}=_0x3d1e7a;for(let _0x530e1b=0x0;_0x530e1b<_0x37f205;_0x530e1b++){if(Atomics[_0x515ecf(0x52f)](_0x3b845f,_0x5dd7e3+_0x530e1b)!==_0x4202d4||Atomics['load'](_0x3b845f,_0x3f9bab+_0x530e1b)!==_0x23e616)continue;Atomics['store'](_0x3b845f,_0x3f9bab+_0x530e1b,0x0);if(Atomics['compareExchange'](_0x3b845f,_0x5dd7e3+_0x530e1b,_0x4202d4,0x0)===_0x4202d4)_0x7cdf4c++;}};for(const _0x54f0b9 of _0x3f19b1[_0x233702(0x260)]())_0x8e50f0(_0x54f0b9);for(const _0x36970d of _0x1d38f2)_0x8e50f0(_0x36970d);return _0x380bea(),_0x7cdf4c;}function _0x380bea(){const _0x596807=_0x10d8c8;for(const _0x3e4d80 of[..._0x1d38f2]){if(_0x374260(_0x3e4d80['att'][_0x596807(0x70)]))continue;_0x1d38f2[_0x596807(0x210)](_0x3e4d80),_0x445781(_0x3e4d80['name'],_0x3e4d80[_0x596807(0x697)],_0x3e4d80[_0x596807(0xac)],_0x3e4d80[_0x596807(0x663)]);}}return okdbShmSegment={'attachSegment':_0x414249,'releaseThreadSlots':_0x12dc1c,'segmentNameFor':_0x5d9715,'legacySegmentNameFor':_0x73162f,'segmentNameStyle':_0x383b84,'SEG_NAME_MAX':_0x1c5392,'retireIfUnused':_0x38176f,'totalBytes':_0x1e0a4d,'headerOffset':_0x4eb516,'MAX_SLOTS':_0x37f205,'_attachRaw':_0xf1421f,'_detachRaw':_0x445781,'_takeover':_0x3ddcf4,'_mapByName':_0x4f28e4,'_hooks':_0x5a13a4,'_registry':_0x3f19b1,'_lingering':_0x1d38f2,'_H':{'STATE':_0x2059bc,'OVERFLOW':_0x8866d,'NONCE_A':_0x6d9982,'NONCE_B':_0x19f477,'SLOTS':_0x5dd7e3,'TIDS':_0x3f9bab}},okdbShmSegment;}var okdbShmGc,hasRequiredOkdbShmGc;function requireOkdbShmGc(){const _0x4755ce=_0x1cb9ed;if(hasRequiredOkdbShmGc)return okdbShmGc;hasRequiredOkdbShmGc=0x1;const _0x4d4c73=require$$0$1,_0x3530be=require$$1,_0x3bd9a9=_0x4755ce(0x188),_0x5540e5=0x18+0x3*0x100*0x4,_0x134285=0x18+0x2*0x100*0x4,_0x347a32=0xc;function _0x453961(){const {totalBytes:_0x5dde4a}=requireOkdbShmSegment();return new Set([0x0,0x8,0x18,_0x134285,_0x347a32,_0x5dde4a(_0x134285),_0x5dde4a(_0x5540e5),_0x5dde4a(_0x347a32)]);}function _0x4f26eb(_0x32c447,_0x58a05c,_0x2e371a){const _0x50528a=_0x4755ce,{totalBytes:_0x41cfb5}=requireOkdbShmSegment();if(_0x32c447[_0x50528a(0x675)]('_boot')||_0x58a05c===_0x347a32||_0x58a05c===_0x41cfb5(_0x347a32))return _0x347a32;if(_0x58a05c===_0x41cfb5(_0x5540e5))return _0x5540e5;if(_0x58a05c===_0x41cfb5(_0x134285))return _0x134285;return _0x2e371a===_0x50528a(0x282)?_0x5540e5:_0x134285;}function _0xf7ee1e(){const _0xb36d48=_0x4755ce,_0x573e85=new Set(),_0x4b0132=[],_0x5a60a1=_0x3bd9a9+'/';let _0x4d755c;try{_0x4d755c=_0x4d4c73[_0xb36d48(0x40f)](_0xb36d48(0x175))[_0xb36d48(0x20f)](_0x1ac14a=>/^\d+$/[_0xb36d48(0x86)](_0x1ac14a));}catch{throw new Error('shm-gc:\x20/proc\x20is\x20not\x20readable\x20—\x20cannot\x20tell\x20which\x20segments\x20are\x20in\x20use');}for(const _0x51f2ce of _0x4d755c){const _0x51ab2b=_0x3530be[_0xb36d48(0x546)](_0xb36d48(0x175),_0x51f2ce);let _0x25a7af=!![];try{const _0x4fe242=_0x4d4c73[_0xb36d48(0x20c)](_0x3530be[_0xb36d48(0x546)](_0x51ab2b,_0xb36d48(0x3bb)),'utf8');let _0x3746e4=_0x4fe242[_0xb36d48(0x6b0)](_0x5a60a1);while(_0x3746e4!==-0x1){const _0x376610=_0x4fe242[_0xb36d48(0x6b0)]('\x0a',_0x3746e4),_0x3b0208=_0x4fe242['slice'](_0x3746e4+_0x5a60a1['length'],_0x376610===-0x1?undefined:_0x376610);if(!_0x3b0208['endsWith']('\x20(deleted)'))_0x573e85[_0xb36d48(0x5f3)](_0x3b0208);_0x3746e4=_0x4fe242[_0xb36d48(0x6b0)](_0x5a60a1,_0x3746e4+0x1);}}catch(_0x2a9c34){if(_0x2a9c34[_0xb36d48(0x72d)]!==_0xb36d48(0x412)&&_0x2a9c34[_0xb36d48(0x72d)]!==_0xb36d48(0x563))_0x25a7af=![];}try{for(const _0x2f5ada of _0x4d4c73[_0xb36d48(0x40f)](_0x3530be[_0xb36d48(0x546)](_0x51ab2b,'fd'))){let _0x56a8ba;try{_0x56a8ba=_0x4d4c73[_0xb36d48(0x1f5)](_0x3530be['join'](_0x51ab2b,'fd',_0x2f5ada));}catch{continue;}if(_0x56a8ba['startsWith'](_0x5a60a1)&&!_0x56a8ba[_0xb36d48(0x675)](_0xb36d48(0x246)))_0x573e85[_0xb36d48(0x5f3)](_0x56a8ba[_0xb36d48(0x762)](_0x5a60a1[_0xb36d48(0x2e8)]));}}catch(_0x198ad6){if(_0x198ad6[_0xb36d48(0x72d)]!==_0xb36d48(0x412)&&_0x198ad6[_0xb36d48(0x72d)]!==_0xb36d48(0x563))_0x25a7af=![];}if(!_0x25a7af){let _0x1ec3aa=null;try{_0x1ec3aa=_0x4d4c73[_0xb36d48(0x1a4)](_0x51ab2b)[_0xb36d48(0x494)];}catch{}let _0x5696de='?';try{_0x5696de=_0x4d4c73['readFileSync'](_0x3530be['join'](_0x51ab2b,'comm'),_0xb36d48(0x84))[_0xb36d48(0x220)]();}catch{}if(_0x1ec3aa!==null)_0x4b0132[_0xb36d48(0x1c2)]({'pid':Number(_0x51f2ce),'uid':_0x1ec3aa,'comm':_0x5696de});}}return{'inUse':_0x573e85,'unreadable':_0x4b0132};}function _0x41e29e({prefix:prefix=_0x4755ce(0x60f),dryRun:dryRun=![],anySize:anySize=![],force:force=![],log:log=()=>{}}={}){const _0xee7687=_0x4755ce;if(process['platform']!==_0xee7687(0x24d)||!_0x4d4c73[_0xee7687(0x26e)](_0x3bd9a9))throw new Error(_0xee7687(0x405));const _0x3149e2=process[_0xee7687(0x1e5)](),_0x6fe9e9=_0x3149e2===0x0,_0x3a167d=_0x453961(),{inUse:_0x2132b9,unreadable:_0x3595e7}=_0xf7ee1e(),_0x4e7dde=_0x3595e7[_0xee7687(0x20f)](_0x265978=>_0x6fe9e9||_0x265978[_0xee7687(0x494)]===_0x3149e2),_0x26a9dd={'dryRun':dryRun,'prefix':prefix,'scanned':0x0,'matched':0x0,'inUse':0x0,'notOkdbShaped':0x0,'foreignOwner':0x0,'candidates':0x0,'candidatesLegacyNamed':0x0,'candidateBytes':0x0,'candidateAllocated':0x0,'deleted':0x0,'deletedAllocated':0x0,'skippedByProtocol':0x0,'errors':0x0,'unreadablePids':_0x3595e7[_0xee7687(0x2e8)],'blindPids':_0x4e7dde[_0xee7687(0x362)](_0x347be6=>_0x347be6[_0xee7687(0x401)]),'blindCommands':_0x4b8fe0(_0x4e7dde)};if(_0x4e7dde['length']&&!dryRun&&!force)throw new Error(_0xee7687(0x277)+_0x4e7dde[_0xee7687(0x2e8)]+'\x20process(es)\x20that\x20could\x20map\x20these\x20'+('segments\x20('+_0x26a9dd['blindCommands']+').\x20If\x20none\x20of\x20them\x20runs\x20okdb,\x20pass\x20--force;\x20')+'otherwise\x20rerun\x20as\x20root.');const {retireIfUnused:_0x37e06d,segmentNameStyle:_0x4fb30d,_registry:_0x42f525}=requireOkdbShmSegment();let _0x324b54=null;if(!dryRun)try{require('v8')[_0xee7687(0x4a6)](_0xee7687(0x713)),_0x324b54=require('vm')['runInNewContext']('gc');}catch{}const _0x5aa567=_0x4d4c73[_0xee7687(0x2af)](_0x3bd9a9);try{let _0x21b0bb,_0x158446=0x0;while(_0x21b0bb=_0x5aa567['readSync']()){_0x26a9dd[_0xee7687(0x55e)]++;const _0x4433df=_0x21b0bb[_0xee7687(0x58e)];if(!_0x4433df['startsWith'](prefix))continue;_0x26a9dd[_0xee7687(0x48b)]++;if(_0x42f525[_0xee7687(0x783)](_0x4433df)){_0x26a9dd[_0xee7687(0x45c)]++;continue;}if(_0x2132b9[_0xee7687(0x783)](_0x4433df)){_0x26a9dd[_0xee7687(0x45c)]++;continue;}let _0x544d0f;try{_0x544d0f=_0x4d4c73['lstatSync'](_0x3530be[_0xee7687(0x546)](_0x3bd9a9,_0x4433df));}catch{continue;}if(!_0x544d0f[_0xee7687(0x1f0)]())continue;const _0xc60681=_0x4fb30d(_0x4433df);if(!_0xc60681||!anySize&&!_0x3a167d[_0xee7687(0x783)](_0x544d0f['size'])){_0x26a9dd[_0xee7687(0x6e5)]++;continue;}if(!_0x6fe9e9&&_0x544d0f['uid']!==_0x3149e2){_0x26a9dd[_0xee7687(0x2f9)]++;continue;}_0x26a9dd[_0xee7687(0x355)]++;if(_0xc60681==='legacy')_0x26a9dd[_0xee7687(0xd3)]++;_0x26a9dd['candidateBytes']+=_0x544d0f[_0xee7687(0x54a)],_0x26a9dd[_0xee7687(0x651)]+=_0x544d0f['blocks']*0x200;if(dryRun)continue;const _0x3bcb33=_0x4f26eb(_0x4433df,_0x544d0f[_0xee7687(0x54a)],_0xc60681);try{const _0x4f1e9f=_0x37e06d(_0x4433df,_0x3bcb33);_0x4f1e9f===_0xee7687(0x776)?(_0x26a9dd[_0xee7687(0x46c)]++,_0x26a9dd[_0xee7687(0x3a8)]+=_0x544d0f['blocks']*0x200):(_0x26a9dd[_0xee7687(0x5cc)]++,log(_0xee7687(0x164)+_0x4433df+':\x20'+_0x4f1e9f));}catch(_0x4d398b){_0x26a9dd[_0xee7687(0x6d)]++,log('error\x20'+_0x4433df+':\x20'+_0x4d398b['message']);}_0x324b54&&++_0x158446>=0x200&&(_0x158446=0x0,_0x324b54());}}finally{_0x5aa567['closeSync']();}return _0x26a9dd;}function _0x4b8fe0(_0x5e1df2){const _0x12f16c=_0x4755ce,_0x113adf=new Map();for(const _0xc28e32 of _0x5e1df2)_0x113adf[_0x12f16c(0x543)](_0xc28e32[_0x12f16c(0x500)],(_0x113adf[_0x12f16c(0x741)](_0xc28e32[_0x12f16c(0x500)])??0x0)+0x1);return[..._0x113adf][_0x12f16c(0x362)](([_0x69af35,_0x20e2db])=>_0x20e2db>0x1?_0x69af35+'×'+_0x20e2db:_0x69af35)[_0x12f16c(0x546)](',\x20');}function _0x5db453(_0x54436a){const _0x1ec82e=_0x4755ce,_0x80c131=['B',_0x1ec82e(0x745),_0x1ec82e(0x493),_0x1ec82e(0x5ae),_0x1ec82e(0x120)];let _0x5ce4bf=0x0;while(_0x54436a>=0x400&&_0x5ce4bf<_0x80c131[_0x1ec82e(0x2e8)]-0x1){_0x54436a/=0x400,_0x5ce4bf++;}return _0x54436a[_0x1ec82e(0x12a)](_0x5ce4bf?0x1:0x0)+'\x20'+_0x80c131[_0x5ce4bf];}function _0x813b56(_0x58e04c){const _0x151713=_0x4755ce,_0x436120=['shm-gc'+(_0x58e04c[_0x151713(0x172)]?_0x151713(0x2bd):'')+_0x151713(0x774)+JSON[_0x151713(0x5bd)](_0x58e04c['prefix']),_0x151713(0xda)+_0x58e04c[_0x151713(0x55e)]+_0x151713(0xa3)+_0x3bd9a9,_0x151713(0x1ee)+_0x58e04c[_0x151713(0x48b)],_0x151713(0x286)+_0x58e04c[_0x151713(0x45c)],_0x151713(0x18b)+_0x58e04c[_0x151713(0x6e5)],_0x151713(0x5c3)+_0x58e04c[_0x151713(0x2f9)],_0x151713(0x37c)+_0x58e04c[_0x151713(0x355)]+_0x151713(0x4e1)+_0x5db453(_0x58e04c[_0x151713(0x4d9)])+_0x151713(0x39f)+_0x5db453(_0x58e04c[_0x151713(0x651)])+'\x20allocated'+(_0x58e04c['candidatesLegacyNamed']?'\x20('+_0x58e04c[_0x151713(0xd3)]+'\x20named\x20by\x20okdb\x20≤\x202.4.0)':'')];if(!_0x58e04c['dryRun']){_0x436120[_0x151713(0x1c2)](_0x151713(0xf6)+_0x58e04c[_0x151713(0x46c)]+'\x20—\x20'+_0x5db453(_0x58e04c[_0x151713(0x3a8)])+_0x151713(0x413));if(_0x58e04c[_0x151713(0x5cc)])_0x436120[_0x151713(0x1c2)]('\x20\x20kept\x20(attached/retiring\x20when\x20retired)\x20'+_0x58e04c[_0x151713(0x5cc)]);if(_0x58e04c[_0x151713(0x6d)])_0x436120[_0x151713(0x1c2)](_0x151713(0x155)+_0x58e04c[_0x151713(0x6d)]);}return _0x58e04c[_0x151713(0x61a)]&&_0x436120['push'](_0x151713(0x230)+_0x58e04c[_0x151713(0x61a)]+_0x151713(0x74b)+(_0x58e04c[_0x151713(0x229)][_0x151713(0x2e8)]?_0x151713(0x4e1)+_0x58e04c['blindPids'][_0x151713(0x2e8)]+'\x20of\x20them\x20run\x20as\x20this\x20user\x20and\x20could\x20map\x20these\x20segments:\x20'+(_0x58e04c[_0x151713(0xa6)]+_0x151713(0x339)):_0x151713(0x64b))),_0x436120[_0x151713(0x546)]('\x0a');}function _0x27cb61(_0x18ac93){const _0x3a8827=_0x4755ce,_0x46e2b7={'prefix':_0x3a8827(0x60f),'dryRun':![],'anySize':![],'force':![],'verbose':![]};for(let _0xb5b22c=0x0;_0xb5b22c<_0x18ac93[_0x3a8827(0x2e8)];_0xb5b22c++){const _0x142cbf=_0x18ac93[_0xb5b22c];if(_0x142cbf===_0x3a8827(0x69d)||_0x142cbf==='-n')_0x46e2b7[_0x3a8827(0x172)]=!![];else{if(_0x142cbf===_0x3a8827(0x606))_0x46e2b7['anySize']=!![];else{if(_0x142cbf===_0x3a8827(0x3a2))_0x46e2b7['force']=!![];else{if(_0x142cbf===_0x3a8827(0x795)||_0x142cbf==='-v')_0x46e2b7[_0x3a8827(0x3a6)]=!![];else{if(_0x142cbf===_0x3a8827(0x6eb))_0x46e2b7[_0x3a8827(0x426)]=_0x18ac93[++_0xb5b22c]??'';else{if(_0x142cbf[_0x3a8827(0x557)](_0x3a8827(0x144)))_0x46e2b7[_0x3a8827(0x426)]=_0x142cbf[_0x3a8827(0x762)]('--prefix='['length']);else{if(_0x142cbf===_0x3a8827(0x5ef)||_0x142cbf==='-h')_0x46e2b7[_0x3a8827(0x693)]=!![];else throw new Error(_0x3a8827(0x152)+_0x142cbf);}}}}}}}return _0x46e2b7;}const _0x43d928=_0x4755ce(0x2f0);function _0x2c25ad(_0x9afd57){const _0x4e406a=_0x4755ce;let _0x1c9a8a;try{_0x1c9a8a=_0x27cb61(_0x9afd57);}catch(_0x4ec3b0){return console[_0x4e406a(0x1da)](_0x4ec3b0[_0x4e406a(0x71d)]),console[_0x4e406a(0x1da)](_0x43d928),0x2;}if(_0x1c9a8a[_0x4e406a(0x693)])return console[_0x4e406a(0x219)](_0x43d928),0x0;const _0x297ba9=_0x41e29e({..._0x1c9a8a,'log':_0x1c9a8a[_0x4e406a(0x3a6)]?_0x3e6184=>console['log'](_0x3e6184):undefined});return console[_0x4e406a(0x219)](_0x813b56(_0x297ba9)),_0x297ba9[_0x4e406a(0x6d)]?0x1:0x0;}return okdbShmGc={'shmGc':_0x41e29e,'formatReport':_0x813b56,'main':_0x2c25ad,'scanInUse':_0xf7ee1e,'ENV_DATA_BYTES':_0x5540e5,'LEGACY_ENV_DATA_BYTES':_0x134285,'BOOT_DATA_BYTES':_0x347a32},okdbShmGc;}var hasRequiredOkdb;function requireOkdb(){const _0x1ced24=_0x1cb9ed;if(hasRequiredOkdb)return okdb$1;hasRequiredOkdb=0x1;try{process[_0x1ced24(0x755)]();}catch{}const _0x29f498=require$$1,_0x54d51e=require$$0$1,{resolveWorkers:_0x205ff4,isShmbufNative:_0x508908}=requireOkdbWorkers();function _0x5bba9e(_0x36c98e){const _0xd08175=_0x1ced24,_0x167255=_0x36c98e[_0xd08175(0x762)](0x2),_0x8b5329={};let _0x30d0f7=0x0;while(_0x30d0f7<_0x167255['length']){const _0x3447d4=_0x167255[_0x30d0f7];if(_0x3447d4===_0xd08175(0x320)||_0x3447d4==='-p')_0x8b5329['port']=Number(_0x167255[++_0x30d0f7]);else{if(_0x3447d4===_0xd08175(0x261)||_0x3447d4==='-d')_0x8b5329[_0xd08175(0x2cc)]=_0x167255[++_0x30d0f7];else{if(_0x3447d4===_0xd08175(0x195)||_0x3447d4==='-k')_0x8b5329[_0xd08175(0x1cd)]=_0x167255[++_0x30d0f7];else{if(_0x3447d4==='--config'||_0x3447d4==='-c')_0x8b5329[_0xd08175(0xf5)]=_0x167255[++_0x30d0f7];else{if(_0x3447d4===_0xd08175(0x465))_0x8b5329[_0xd08175(0x628)]=_0x167255[++_0x30d0f7];else{if(_0x3447d4===_0xd08175(0x627))_0x8b5329[_0xd08175(0x133)]=!![];else{if(_0x3447d4===_0xd08175(0x27d))_0x8b5329[_0xd08175(0x733)]=!![];else{if(_0x3447d4==='--workers')_0x8b5329[_0xd08175(0x571)]=_0x167255[++_0x30d0f7];else{if(_0x3447d4==='--no-cluster')_0x8b5329['noCluster']=!![];else{if(_0x3447d4===_0xd08175(0x284)||_0x3447d4==='-e')_0x8b5329[_0xd08175(0x514)]=_0x167255[++_0x30d0f7];else{if(_0x3447d4===_0xd08175(0x253))_0x8b5329[_0xd08175(0x4e6)]=_0x167255[++_0x30d0f7];else{if(_0x3447d4===_0xd08175(0x461))_0x8b5329[_0xd08175(0x536)]=!![];else{if(_0x3447d4===_0xd08175(0xe9))_0x8b5329['blobs']=!![];else{if(_0x3447d4===_0xd08175(0x174))_0x8b5329[_0xd08175(0x19d)]=!![];else{if(_0x3447d4===_0xd08175(0x45e))_0x8b5329[_0xd08175(0x5f7)]=!![];else{if(_0x3447d4==='--open'){const _0x16de92=[];while(_0x30d0f7+0x1<_0x167255[_0xd08175(0x2e8)]&&!_0x167255[_0x30d0f7+0x1]['startsWith']('--')){_0x16de92[_0xd08175(0x1c2)](_0x167255[++_0x30d0f7]);}_0x8b5329['open']=_0x16de92[_0xd08175(0x2e8)]>0x0?_0x16de92:!![];}else{if(_0x3447d4==='--log-requests')_0x8b5329[_0xd08175(0x5a9)]=!![];else{if(_0x3447d4===_0xd08175(0x44f))_0x8b5329[_0xd08175(0x58e)]=_0x167255[++_0x30d0f7];else{if(_0x3447d4==='--password')_0x8b5329[_0xd08175(0xca)]=_0x167255[++_0x30d0f7];else{if(_0x3447d4==='--label')_0x8b5329[_0xd08175(0x782)]=_0x167255[++_0x30d0f7];else{if(_0x3447d4==='--permissions')_0x8b5329[_0xd08175(0x75a)]=_0x167255[++_0x30d0f7];else{if(_0x3447d4===_0xd08175(0x24b))_0x8b5329[_0xd08175(0x69c)]=_0x167255[++_0x30d0f7];else{if(_0x3447d4===_0xd08175(0x4ed))_0x8b5329[_0xd08175(0x3bd)]=_0x167255[++_0x30d0f7];else{if(_0x3447d4===_0xd08175(0x4d0))_0x8b5329[_0xd08175(0x2f5)]=_0x167255[++_0x30d0f7];else{if(_0x3447d4===_0xd08175(0x327)||_0x3447d4==='-u')_0x8b5329[_0xd08175(0x4e3)]=_0x167255[++_0x30d0f7];else{if(_0x3447d4===_0xd08175(0x3cc))_0x8b5329['selfAddress']=_0x167255[++_0x30d0f7];else{if(_0x3447d4==='--version'||_0x3447d4==='-v'){const _0x503145=require$$3;console[_0xd08175(0x219)](_0x503145[_0xd08175(0x512)]),process['exit'](0x0);}else(_0x3447d4===_0xd08175(0x5ef)||_0x3447d4==='-h')&&(_0x5074c2(),process['exit'](0x0));}}}}}}}}}}}}}}}}}}}}}}}}}}_0x30d0f7++;}return _0x8b5329;}function _0x5074c2(){const _0x56812d=_0x1ced24;console[_0x56812d(0x219)]('\x0a\x20\x20okdb\x20—\x20standalone\x20OKDB\x20server\x0a\x0a\x20\x20Usage:\x0a\x20\x20\x20\x20okdb\x20[options]\x0a\x20\x20\x20\x20okdb\x20<command>\x0a\x0a\x20\x20Options:\x0a\x20\x20\x20\x20-p,\x20--port\x20<port>\x20\x20\x20\x20\x20\x20\x20\x20HTTP\x20port\x20(default:\x208484)\x0a\x20\x20\x20\x20-d,\x20--path\x20<dir>\x20\x20\x20\x20\x20\x20\x20\x20\x20Database\x20directory\x20(default:\x20./okdb-data)\x0a\x20\x20\x20\x20-k,\x20--key\x20\x20<secret>\x20\x20\x20\x20\x20\x20Encryption\x20key\x20for\x20data\x20at\x20rest\x0a\x20\x20\x20\x20-c,\x20--config\x20<file>\x20\x20\x20\x20\x20\x20Config\x20file\x20path\x20(default:\x20.kdbconfig)\x0a\x20\x20\x20\x20\x20\x20\x20\x20--log-level\x20<level>\x20\x20Log\x20level:\x20debug\x20|\x20info\x20|\x20warn\x20|\x20error\x20(default:\x20info)\x0a\x20\x20\x20\x20\x20\x20\x20\x20--no-repl\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Start\x20server\x20without\x20interactive\x20shell\x0a\x20\x20\x20\x20\x20\x20\x20\x20--no-admin\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Disable\x20admin\x20UI\x0a\x20\x20\x20\x20\x20\x20\x20\x20--open\x20[ip\x20...]\x20\x20\x20\x20\x20\x20Open\x20mode:\x20bypass\x20auth\x20for\x20listed\x20IPs\x20(default:\x20localhost).\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Examples:\x20--open\x20\x20--open\x20192.168.1.0/24\x20\x20--open\x20*\x0a\x20\x20\x20\x20\x20\x20\x20\x20--log-requests\x20\x20\x20\x20\x20\x20\x20Print\x20every\x20HTTP\x20request\x20to\x20stdout\x20(for\x20debugging)\x0a\x20\x20\x20\x20\x20\x20\x20\x20--workers\x20<n>\x20\x20\x20\x20\x20\x20\x20\x20Number\x20of\x20capable\x20worker\x20processes\x20sharing\x20the\x20listen\x20socket\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20(default:\x20cores\x20−\x201).\x20Each\x20worker\x20serves\x20HTTP\x20+\x20SSE\x20AND\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20processes\x20(claims\x20leases,\x20drains\x20on\x20its\x20own\x20loop);\x20the\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20cluster\x20primary\x20is\x20a\x20thin\x20passive\x20supervisor.\x0a\x20\x20\x20\x20\x20\x20\x20\x20--no-cluster\x20\x20\x20\x20\x20\x20\x20\x20\x20Run\x20single-process\x20(equivalent\x20to\x20--workers\x201)\x0a\x20\x20\x20\x20-v,\x20--version\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Print\x20version\x20and\x20exit\x0a\x20\x20\x20\x20-h,\x20--help\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Show\x20this\x20help\x0a\x0a\x20\x20Commands:\x0a\x20\x20\x20\x20version\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Print\x20version\x20and\x20exit\x0a\x20\x20\x20\x20doctor\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Run\x20health\x20checks\x0a\x20\x20\x20\x20init\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Create\x20.kdbconfig\x20and\x20okdb-data/\x0a\x20\x20\x20\x20token\x20create\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Create\x20a\x20token\x20in\x20the\x20local\x20DB\x20(direct\x20access,\x20no\x20HTTP)\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20--name\x20<name>\x20\x20\x20\x20\x20\x20For\x20password\x20login\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20--password\x20<pass>\x20\x20Password\x20(requires\x20--name)\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20--label\x20<text>\x20\x20\x20\x20\x20Human\x20description\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20--permissions\x20<l>\x20\x20Comma-separated\x20baseline\x20permissions\x20(e.g.\x20\x22*\x22\x20or\x20\x22data:read\x22)\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20--grants\x20<json>\x20\x20\x20\x20Per-env\x20grants\x20as\x20JSON\x20(e.g.\x20\x27{\x22orders\x22:[\x22data:*\x22]}\x27)\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20--ttl\x20<ms>\x20\x20\x20\x20\x20\x20\x20\x20\x20Optional\x20TTL\x20in\x20milliseconds\x0a\x20\x20\x20\x20token\x20list\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20List\x20all\x20tokens\x20in\x20the\x20local\x20DB\x0a\x20\x20\x20\x20token\x20revoke\x20<id>\x20\x20\x20\x20\x20\x20\x20\x20Revoke\x20(delete)\x20a\x20token\x20by\x20id\x20(full\x20uuid\x20or\x20unique\x20prefix)\x0a\x20\x20\x20\x20join\x20<address>\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Join\x20an\x20existing\x20cluster\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20--token\x20<t>\x20\x20\x20\x20\x20\x20\x20\x20Bearer\x20token\x20from\x20the\x20cluster\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20--username\x20<u>\x20\x20\x20\x20\x20Or,\x20username\x20for\x20login\x20exchange\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20--password\x20<p>\x20\x20\x20\x20\x20Password\x20for\x20login\x20exchange\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20--address\x20<addr>\x20\x20\x20This\x20node\x27s\x20reachable\x20sync\x20address\x20(required)\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20--path\x20<dir>\x20\x20\x20\x20\x20\x20\x20Local\x20DB\x20path\x0a\x20\x20\x20\x20backup\x20[dir]\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Hot\x20backup:\x20LMDB\x20snapshot\x20copy\x20of\x20every\x20env\x20+\x20time-machine\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20history\x20+\x20file\x20blobs\x20into\x20a\x20NEW\x20dir\x20(default:\x20./okdb-backup);\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20full-text\x20indexes\x20are\x20rebuilt\x20on\x20first\x20open,\x20not\x20copied\x0a\x20\x20\x20\x20restore\x20<dir>\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Restore\x20a\x20backup\x20dir\x20into\x20--path\x20(must\x20not\x20exist\x20or\x20be\x20empty)\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20--new-identity\x20\x20\x20\x20bring\x20the\x20copy\x20up\x20as\x20a\x20NEW\x20node\x20(fresh\x20id,\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20no\x20sync\x20membership)\x20instead\x20of\x20replacing\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20the\x20original\x20—\x20see\x20docs/migration.md\x0a\x20\x20\x20\x20export\x20<file>\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Streaming\x20NDJSON\x20logical\x20export\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20--env\x20<name>\x20\x20\x20\x20\x20\x20env\x20to\x20export\x20(default:\x20default)\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20--types\x20<a,b,...>\x20comma-separated\x20type\x20filter\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20--changes\x20\x20\x20\x20\x20\x20\x20\x20\x20include\x20changelog\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20--blobs\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20also\x20export\x20blob\x20files\x20alongside\x0a\x20\x20\x20\x20import\x20<file>\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Streaming\x20NDJSON\x20logical\x20import\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20--env\x20<name>\x20\x20\x20\x20\x20\x20target\x20env\x20override\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20--types\x20<a,b,...>\x20import\x20only\x20these\x20types\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20--drop\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20drop\x20&\x20recreate\x20existing\x20types\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20--changes\x20\x20\x20\x20\x20\x20\x20\x20\x20restore\x20changelog\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20--blobs\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20also\x20import\x20blob\x20files\x20alongside\x0a\x20\x20\x20\x20reset\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Delete\x20and\x20recreate\x20database\x20(with\x20confirmation);\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20node\x20identity\x20and\x20licenses\x20are\x20preserved\x0a\x20\x20\x20\x20license\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20List\x20stored\x20licenses,\x20current\x20tier,\x20and\x20usage\x0a\x20\x20\x20\x20license\x20<blob|path>\x20\x20\x20\x20\x20\x20Add\x20a\x20license\x20blob\x20(or\x20read\x20from\x20a\x20.license\x20file)\x0a\x20\x20\x20\x20license\x20<activation>\x20\x20\x20\x20\x20Activate\x20a\x20previously-added\x20license\x20with\x20the\x20vendor\x27s\x20token\x0a\x20\x20\x20\x20license\x20<id>\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Show\x20details\x20for\x20one\x20stored\x20license\x20(by\x20uuid\x20or\x20prefix)\x0a\x20\x20\x20\x20license\x20remove\x20<id>\x20\x20\x20\x20\x20\x20Remove\x20a\x20stored\x20license\x0a\x20\x20\x20\x20shm-gc\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Delete\x20leaked\x20okdb\x20shared-memory\x20segments\x20no\x20process\x20uses\x20(Linux)\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20--dry-run\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20report\x20only\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20--prefix\x20<p>\x20\x20\x20\x20\x20\x20\x20only\x20names\x20starting\x20with\x20<p>\x20(default\x20\x22-tmp-\x22)\x0a\x0a\x20\x20Environment\x20variables:\x0a\x20\x20\x20\x20OKDB_PORT\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20HTTP\x20port\x0a\x20\x20\x20\x20OKDB_PATH\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Database\x20directory\x0a\x20\x20\x20\x20OKDB_LOG_LEVEL\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Log\x20level\x20(debug|info|warn|error)\x0a\x20\x20\x20\x20OKDB_KEY\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Encryption\x20key\x0a\x20\x20\x20\x20OKDB_NO_REPL=1\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Disable\x20REPL\x0a\x20\x20\x20\x20OKDB_NO_ADMIN=1\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Disable\x20admin\x20UI\x0a\x20\x20\x20\x20OKDB_HTTP_WORKERS\x20\x20\x20\x20\x20\x20\x20\x20\x20Number\x20of\x20passive\x20HTTP\x20worker\x20processes\x20(default:\x20cores\x20−\x201;\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20forced\x20to\x201\x20if\x20the\x20shmbuf\x20native\x20binding\x20is\x20unavailable)\x0a\x0a\x20\x20Config\x20file\x20(.kdbconfig)\x20—\x20JSON,\x20all\x20keys\x20optional:\x0a\x20\x20\x20\x20{\x0a\x20\x20\x20\x20\x20\x20\x22port\x22:\x20\x20\x20\x20\x208484,\x0a\x20\x20\x20\x20\x20\x20\x22path\x22:\x20\x20\x20\x20\x20\x22./okdb-data\x22,\x0a\x20\x20\x20\x20\x20\x20\x22key\x22:\x20\x20\x20\x20\x20\x20\x22...\x22,\x0a\x20\x20\x20\x20\x20\x20\x22logLevel\x22:\x20\x22info\x22,\x0a\x20\x20\x20\x20\x20\x20\x22noAdmin\x22:\x20\x20false,\x0a\x20\x20\x20\x20\x20\x20\x22noRepl\x22:\x20\x20\x20false,\x0a\x20\x20\x20\x20\x20\x20\x22auth\x22:\x20{\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x22open\x22:\x20false\x0a\x20\x20\x20\x20\x20\x20}\x0a\x20\x20\x20\x20}\x0a\x0a\x20\x20Examples:\x0a\x20\x20\x20\x20okdb\x0a\x20\x20\x20\x20okdb\x20--port\x209000\x20--path\x20./mydb\x0a\x20\x20\x20\x20okdb\x20--no-repl\x20--port\x208080\x0a\x20\x20\x20\x20okdb\x20--open\x0a\x20\x20\x20\x20okdb\x20--open\x20192.168.1.0/24\x0a\x20\x20\x20\x20okdb\x20doctor\x0a\x20\x20\x20\x20okdb\x20backup\x20./my-backup\x0a\x20\x20\x20\x20okdb\x20restore\x20./my-backup\x20--path\x20./okdb-data\x0a');}const _0x4c2308=new Set([_0x1ced24(0x777),_0x1ced24(0x1b9),_0x1ced24(0x27b),_0x1ced24(0x1da)]);function _0x1e64b7(_0x382173){const _0xea37f0=_0x1ced24,_0x33c3c2=_0x382173[_0xea37f0(0xf5)]?_0x29f498[_0xea37f0(0x395)](_0x382173['config']):_0x29f498[_0xea37f0(0x395)](_0xea37f0(0x1b7));let _0x41d2f7={};if(_0x54d51e[_0xea37f0(0x26e)](_0x33c3c2))try{const _0x492a75=_0x54d51e['readFileSync'](_0x33c3c2,_0xea37f0(0x84))[_0xea37f0(0x61f)](/^\uFEFF/,'');_0x41d2f7=JSON[_0xea37f0(0x110)](_0x492a75),console[_0xea37f0(0x219)](_0xea37f0(0x181)+_0x33c3c2);}catch(_0xa5fd91){console['error'](_0xea37f0(0x63a)+_0x33c3c2+':\x20'+_0xa5fd91['message']),process['exit'](0x1);}const _0x416459={'port':process.env.OKDB_PORT?Number(process.env.OKDB_PORT):undefined,'path':process.env.OKDB_PATH??undefined,'key':process.env.OKDB_KEY??undefined,'logLevel':process.env.OKDB_LOG_LEVEL??undefined,'noRepl':process.env.OKDB_NO_REPL==='1'?!![]:undefined,'noAdmin':process.env.OKDB_NO_ADMIN==='1'?!![]:undefined},_0x204908={'port':_0x382173[_0xea37f0(0x64d)]??_0x41d2f7['port']??_0x416459[_0xea37f0(0x64d)]??0x2124,'dbPath':_0x382173[_0xea37f0(0x2cc)]??_0x41d2f7[_0xea37f0(0x2cc)]??_0x416459[_0xea37f0(0x2cc)]??_0xea37f0(0x4df),'key':_0x382173[_0xea37f0(0x1cd)]??_0x41d2f7[_0xea37f0(0x1cd)]??_0x416459[_0xea37f0(0x1cd)]??undefined,'logLevel':_0x382173[_0xea37f0(0x628)]??_0x41d2f7[_0xea37f0(0x628)]??_0x416459['logLevel']??_0xea37f0(0x1b9),'noRepl':_0x382173[_0xea37f0(0x133)]??_0x41d2f7['noRepl']??_0x416459[_0xea37f0(0x133)]??![],'noAdmin':_0x382173[_0xea37f0(0x733)]??_0x41d2f7[_0xea37f0(0x733)]??_0x416459[_0xea37f0(0x733)]??![],'admin':_0x41d2f7[_0xea37f0(0x1dd)]??{},'api':_0x41d2f7[_0xea37f0(0x729)]??undefined,'auth':_0x41d2f7[_0xea37f0(0x9f)]??undefined,'mcp':_0x41d2f7['mcp']??undefined,'http':_0x41d2f7['http']??undefined,'backup':_0x41d2f7[_0xea37f0(0xe0)]??undefined,'timeMachine':_0x41d2f7[_0xea37f0(0x16a)]!==![]?_0x41d2f7[_0xea37f0(0x16a)]??{}:![],'processors':_0x41d2f7[_0xea37f0(0x3c6)],'engines':_0x41d2f7[_0xea37f0(0x1d6)],'compaction':_0x41d2f7['compaction']};if(_0x382173[_0xea37f0(0x330)])_0x204908['noCluster']=!![];if(_0x382173[_0xea37f0(0x571)]!==undefined)_0x204908[_0xea37f0(0x505)]=_0x382173[_0xea37f0(0x571)];_0x382173['open']!==undefined&&(_0x204908[_0xea37f0(0x9f)]=_0x204908[_0xea37f0(0x9f)]||{},_0x204908[_0xea37f0(0x9f)]['open']=_0x382173[_0xea37f0(0x58f)]);_0x382173[_0xea37f0(0x5a9)]&&(_0x204908[_0xea37f0(0x777)]=_0x204908[_0xea37f0(0x777)]||{},_0x204908[_0xea37f0(0x777)]['logRequests']=!![]);(!Number['isInteger'](_0x204908[_0xea37f0(0x64d)])||_0x204908['port']<0x1||_0x204908['port']>0xffff)&&(console[_0xea37f0(0x1da)](_0xea37f0(0x285)+_0x204908['port']+_0xea37f0(0x616)),process[_0xea37f0(0x2e9)](0x1));!_0x4c2308[_0xea37f0(0x783)](_0x204908[_0xea37f0(0x628)])&&(console[_0xea37f0(0x1da)]('[okdb]\x20invalid\x20log\x20level:\x20\x22'+_0x204908[_0xea37f0(0x628)]+_0xea37f0(0x23b)),process[_0xea37f0(0x2e9)](0x1));const _0x2a76d5=_0x204908[_0xea37f0(0x1be)]?.[_0xea37f0(0x2a4)];_0x2a76d5!==undefined&&!(typeof _0x2a76d5===_0xea37f0(0x139)&&_0x2a76d5)&&!(Array[_0xea37f0(0x259)](_0x2a76d5)&&_0x2a76d5['length']&&_0x2a76d5[_0xea37f0(0x6a5)](_0x51608b=>typeof _0x51608b===_0xea37f0(0x139)&&_0x51608b))&&(console[_0xea37f0(0x1da)](_0xea37f0(0x2c6)+JSON[_0xea37f0(0x5bd)](_0x2a76d5)+_0xea37f0(0x53a)),process[_0xea37f0(0x2e9)](0x1));for(const _0x67dc8 of _0xb50e42){_0x204908[_0x67dc8]!==undefined&&typeof _0x204908[_0x67dc8]!==_0xea37f0(0x610)&&(console[_0xea37f0(0x1da)](_0xea37f0(0x271)+_0x67dc8+_0xea37f0(0x1a3)+JSON[_0xea37f0(0x5bd)](_0x204908[_0x67dc8])+_0xea37f0(0x520)),process[_0xea37f0(0x2e9)](0x1));}return _0x204908;}const _0xb50e42=[_0x1ced24(0x3c6),_0x1ced24(0x1d6),_0x1ced24(0x11d)];function _0x39c929(_0x190b1b){const _0x5a75bb=_0x1ced24;return!!(_0x190b1b&&typeof _0x190b1b==='object'&&!Array['isArray'](_0x190b1b)&&Object['keys'](_0x190b1b)[_0x5a75bb(0x2e8)]>0x0);}function _0x2c84a0(_0x3ed00b){const _0x31e8e3=_0x1ced24;return{..._0x3ed00b['key']?{'encryptionKey':_0x3ed00b[_0x31e8e3(0x1cd)]}:{},'engines':![],'processors':![],'compaction':![]};}const _0x1f94e8=!process[_0x1ced24(0x27e)][_0x1ced24(0x69f)]||!!process.env.NO_COLOR;function _0x3cac9f(_0x589105,_0x14f90d){const _0x2d9bff=_0x1ced24;return _0x1f94e8?_0x14f90d:'\x1b['+_0x589105+'m'+_0x14f90d+_0x2d9bff(0x68c);}function _0x280b5a(_0xab4e7f){const _0x4d7401=_0x1ced24;if(!_0xab4e7f||_0xab4e7f[_0x4d7401(0x2e8)]===0x0)return;const _0x3d4b0f='─'[_0x4d7401(0x32c)](0x38);process[_0x4d7401(0x544)]['write']('\x0a'),process['stderr'][_0x4d7401(0xc6)](_0x3cac9f('33',_0x4d7401(0xa1)+_0xab4e7f[_0x4d7401(0x2e8)]+_0x4d7401(0x256)+(_0xab4e7f[_0x4d7401(0x2e8)]>0x1?'S':'')+'\x0a')),process[_0x4d7401(0x544)]['write']('\x20\x20'+_0x3d4b0f+'\x0a');for(const _0x4cef91 of _0xab4e7f){const _0x3264bb=_0x4cef91['level']===_0x4d7401(0x1da)?_0x3cac9f('31','\x20\x20✗'):_0x3cac9f('33',_0x4d7401(0x36d));process[_0x4d7401(0x544)]['write'](_0x3264bb+'\x20\x20'+_0x3cac9f('1',_0x4cef91['title'])+'\x0a'),process[_0x4d7401(0x544)][_0x4d7401(0xc6)](_0x4d7401(0x673)+_0x4cef91[_0x4d7401(0x71d)]+'\x0a');if(_0x4cef91['hint'])process['stderr'][_0x4d7401(0xc6)]('\x20\x20\x20\x20\x20\x20\x20'+_0x3cac9f('2',_0x4d7401(0x10f)+_0x4cef91[_0x4d7401(0x2c8)])+'\x0a');process[_0x4d7401(0x544)][_0x4d7401(0xc6)]('\x0a');}process['stderr'][_0x4d7401(0xc6)]('\x20\x20'+_0x3d4b0f+'\x0a\x0a');}function _0x43ffc2(_0x586ba7,_0x4370bd,_0xdde0cf={}){const _0x39ef45=_0x1ced24,_0x2bdc18=_0x586ba7['http']['listen'](_0x4370bd,_0xdde0cf);if(_0x2bdc18&&_0x2bdc18['_isClusterController'])return Promise['resolve'](_0x2bdc18);const _0x3b7989=_0x586ba7[_0x39ef45(0x1be)]['servers']?.[_0x39ef45(0x2e8)]?_0x586ba7[_0x39ef45(0x1be)]['servers']:[_0x2bdc18];return new Promise((_0x4792d7,_0x330374)=>{const _0xcdd4e0=_0x39ef45;_0x2bdc18[_0xcdd4e0(0x17b)](_0xcdd4e0(0x1da),_0x330374),Promise[_0xcdd4e0(0x447)](_0x3b7989[_0xcdd4e0(0x362)](_0x409a14=>_0x409a14['listening']?null:new Promise(_0x445e48=>_0x409a14[_0xcdd4e0(0x17b)](_0xcdd4e0(0x6b7),_0x445e48))))[_0xcdd4e0(0x257)](()=>_0x4792d7(_0x2bdc18));});}function _0x1d7805(_0x39aa54){const _0x38d4ef=_0x1ced24;return _0x39aa54['http']?.['host']!==undefined?{'host':_0x39aa54['http'][_0x38d4ef(0x2a4)]}:{};}async function _0x2ae6e6(_0x233576){const _0x1ca2bf=_0x1ced24,_0x5a3124=require$$4$1;console[_0x1ca2bf(0x219)](_0x1ca2bf(0x751));let _0x3aafd3=!![];const _0x2d22eb=(_0x138c73,_0x52b5a2)=>{const _0x3c90f3=_0x1ca2bf;console[_0x3c90f3(0x219)]('\x20\x20'+(_0x138c73?'✓':'✗')+'\x20'+_0x52b5a2);if(!_0x138c73)_0x3aafd3=![];},_0x3a7114=Number(process[_0x1ca2bf(0x512)][_0x1ca2bf(0x61f)]('v','')[_0x1ca2bf(0x527)]('.')[0x0]);_0x2d22eb(_0x3a7114>=0x12,'node\x20'+process['version']+(_0x3a7114<0x12?_0x1ca2bf(0x217):''));const _0x5e0889=_0x29f498[_0x1ca2bf(0x395)](_0x233576['dbPath']);try{_0x54d51e[_0x1ca2bf(0x3b8)](_0x5e0889,{'recursive':!![]});const _0x46a970=_0x29f498[_0x1ca2bf(0x546)](_0x5e0889,_0x1ca2bf(0x456));_0x54d51e[_0x1ca2bf(0x24e)](_0x46a970,''),_0x54d51e['unlinkSync'](_0x46a970),_0x2d22eb(!![],_0x1ca2bf(0x93)+_0x5e0889);}catch(_0x2b8d8b){_0x2d22eb(![],'database\x20path\x20not\x20writable:\x20'+_0x5e0889+_0x1ca2bf(0x48f)+_0x2b8d8b[_0x1ca2bf(0x71d)]+')');}const _0x5a215e=await new Promise(_0x8ead12=>{const _0x58c27c=_0x1ca2bf,_0x2df95e=_0x5a3124[_0x58c27c(0x1d7)]();_0x2df95e['once'](_0x58c27c(0x1da),()=>_0x8ead12(![])),_0x2df95e[_0x58c27c(0x17b)](_0x58c27c(0x6b7),()=>{_0x2df95e['close'](),_0x8ead12(!![]);}),_0x2df95e['listen'](_0x233576[_0x58c27c(0x64d)],_0x58c27c(0x2ff));});_0x2d22eb(_0x5a215e,_0x1ca2bf(0x382)+_0x233576['port']+'\x20'+(_0x5a215e?'available':_0x1ca2bf(0x310)));const _0x4afded=_0x29f498['resolve'](_0x1ca2bf(0x1b7));if(_0x54d51e[_0x1ca2bf(0x26e)](_0x4afded))try{JSON[_0x1ca2bf(0x110)](_0x54d51e[_0x1ca2bf(0x20c)](_0x4afded,_0x1ca2bf(0x84))['replace'](/^\uFEFF/,'')),_0x2d22eb(!![],'config\x20file\x20valid:\x20'+_0x4afded);}catch(_0x3f0cbe){_0x2d22eb(![],_0x1ca2bf(0x14c)+_0x3f0cbe[_0x1ca2bf(0x71d)]);}else _0x2d22eb(!![],_0x1ca2bf(0x1f9));if(_0x508908()){const _0x5eb1ca=_0x205ff4(_0x233576,{'shmbufNative':!![]});_0x2d22eb(!![],_0x1ca2bf(0x425)+_0x5eb1ca+_0x1ca2bf(0x70e)+(_0x5eb1ca===0x1?'':'s')+')');}else _0x2d22eb(!![],_0x1ca2bf(0x132));if(!_0x5a215e)try{const _0x2e57de=require(_0x1ca2bf(0x8f)),_0xeabd25=new _0x2e57de(_0x5e0889,{'engines':![],'processors':![],'compaction':![],'auth':{'open':!![]}});await _0xeabd25[_0x1ca2bf(0x58f)]();try{await _0xeabd25[_0x1ca2bf(0x5d0)]['open']({'reader':!![]});const _0x2d5234=_0xeabd25['processes'][_0x1ca2bf(0x3d5)](),_0x3fd598=_0x2d5234[_0x1ca2bf(0x20f)](_0x22839f=>_0x22839f[_0x1ca2bf(0x3f0)]!=null)[_0x1ca2bf(0x2e8)];_0x2d22eb(!![],'processes:\x20'+_0x2d5234['length']+_0x1ca2bf(0x3c2)+(_0x2d5234['length']===0x1?'':'es')+'\x20('+_0x3fd598+_0x1ca2bf(0xf2));}finally{await _0xeabd25[_0x1ca2bf(0x57b)]();}}catch{}console[_0x1ca2bf(0x219)](''),_0x3aafd3?console[_0x1ca2bf(0x219)](_0x1ca2bf(0x79b)):(console['log'](_0x1ca2bf(0x515)),process['exit'](0x1));}async function _0x2c2811(){const _0x568c1a=_0x1ced24,_0x2712ad=_0x29f498[_0x568c1a(0x395)](_0x568c1a(0x1b7));!_0x54d51e[_0x568c1a(0x26e)](_0x2712ad)?(_0x54d51e['writeFileSync'](_0x2712ad,JSON[_0x568c1a(0x5bd)]({'port':0x2124,'path':_0x568c1a(0x4df),'logLevel':_0x568c1a(0x1b9),'noRepl':![],'noAdmin':![]},null,0x2)+'\x0a'),console[_0x568c1a(0x219)]('[okdb]\x20created\x20.kdbconfig')):console[_0x568c1a(0x219)](_0x568c1a(0x3f3));const _0x444520=_0x29f498['resolve']('./okdb-data');!_0x54d51e['existsSync'](_0x444520)?(_0x54d51e[_0x568c1a(0x3b8)](_0x444520,{'recursive':!![]}),console[_0x568c1a(0x219)](_0x568c1a(0x143))):console[_0x568c1a(0x219)](_0x568c1a(0x2d0)),console[_0x568c1a(0x219)](_0x568c1a(0x3e3));}async function _0x83fca9(_0x38b631){const _0x413f50=_0x1ced24,_0x4c34c5=_0x29f498[_0x413f50(0x395)](_0x38b631[_0x413f50(0x6bb)]);if(!_0x54d51e[_0x413f50(0x26e)](_0x4c34c5)){console['log'](_0x413f50(0x73f)+_0x4c34c5+_0x413f50(0x26c));return;}const _0x4dadc4=require$$0$3,_0x3d66a4=_0x4dadc4[_0x413f50(0x37e)]({'input':process[_0x413f50(0x18f)],'output':process[_0x413f50(0x27e)]}),_0x55c41a=await new Promise(_0x209bce=>_0x3d66a4[_0x413f50(0x2a0)](_0x413f50(0x2dc)+_0x4c34c5+_0x413f50(0x2f7),_0x209bce));_0x3d66a4['close'](),console[_0x413f50(0x219)]('');if(_0x55c41a[_0x413f50(0x220)]()[_0x413f50(0x36c)]()!==_0x413f50(0x380)){console[_0x413f50(0x219)](_0x413f50(0x2de));return;}let _0x5394ed=null;try{_0x5394ed=await _0x422627(_0x4c34c5,_0x38b631,async _0x3c5c52=>{const _0x444b9e=_0x413f50,_0x326e4f=_0x3c5c52[_0x444b9e(0x600)],_0x456320=_0x326e4f?.['db']?.[_0x444b9e(0x741)](_0x444b9e(0x389))??null,_0x552c07=[];if(_0x326e4f?.['hasType'](_0x444b9e(0x3b4)))for(const {key:_0x50637f,value:_0x3ca5c3}of _0x326e4f[_0x444b9e(0x4f6)](_0x444b9e(0x3b4))){_0x552c07[_0x444b9e(0x1c2)]({'key':_0x50637f,'value':_0x3ca5c3});}return{'identity':_0x456320,'licenses':_0x552c07};});}catch(_0x44f70e){console[_0x413f50(0x219)](_0x413f50(0x291)+_0x44f70e['message']+_0x413f50(0x743));}_0x54d51e[_0x413f50(0x39d)](_0x4c34c5,{'recursive':!![],'force':!![]}),console[_0x413f50(0x219)](_0x413f50(0x49f)+_0x4c34c5+_0x413f50(0x435));if(_0x5394ed&&(_0x5394ed['identity']||_0x5394ed['licenses'][_0x413f50(0x2e8)]>0x0))try{await _0x422627(_0x4c34c5,_0x38b631,async _0x46f0f7=>{const _0x398d54=_0x413f50,_0x4b82f7=_0x46f0f7[_0x398d54(0x600)];_0x5394ed[_0x398d54(0x3c1)]&&_0x4b82f7['db'][_0x398d54(0x4dd)](_0x398d54(0x389),_0x5394ed[_0x398d54(0x3c1)]);if(_0x5394ed[_0x398d54(0x691)][_0x398d54(0x2e8)]>0x0){if(!_0x4b82f7[_0x398d54(0x59f)]('~licenses'))await _0x4b82f7[_0x398d54(0x624)](_0x398d54(0x3b4));for(const {key:_0x456c9c,value:_0x546e91}of _0x5394ed[_0x398d54(0x691)]){await _0x4b82f7[_0x398d54(0x22b)]('~licenses',_0x456c9c,_0x546e91);}}});const _0x118f23=[];if(_0x5394ed[_0x413f50(0x3c1)])_0x118f23[_0x413f50(0x1c2)](_0x413f50(0x6c1));if(_0x5394ed[_0x413f50(0x691)][_0x413f50(0x2e8)]>0x0)_0x118f23[_0x413f50(0x1c2)](_0x5394ed[_0x413f50(0x691)]['length']+'\x20license(s)');console['log'](_0x413f50(0x2eb)+_0x118f23[_0x413f50(0x546)](_0x413f50(0x5c6)));}catch(_0x5ed4d4){console['log'](_0x413f50(0x686)+_0x5ed4d4[_0x413f50(0x71d)]);}}async function _0x422627(_0x347ae8,_0x555ee6,_0x5f63c8){const _0x8794d5=_0x1ced24,_0xc3877a=require$$5$1,_0x588049=new _0xc3877a(_0x347ae8,{'admin':![],'mcp':![],'timeMachine':![],'engines':![],'processors':![],'compaction':![],'_skipBootRuntime':!![],..._0x2c84a0(_0x555ee6)});await _0x588049['open']();try{return await _0x5f63c8(_0x588049);}finally{await _0x588049[_0x8794d5(0x57b)]();}}async function _0x1f25b5(_0x219cc6,_0x6a332){const _0x68c859=_0x1ced24,_0x2bf1c0=require$$5$1,_0x35ad3e=_0x29f498[_0x68c859(0x395)](_0x6a332[_0x68c859(0x6bb)]);console[_0x68c859(0x219)](_0x68c859(0x3e1)+_0x35ad3e+'…');const _0x2f7a03=new _0x2bf1c0(_0x35ad3e,_0x2c84a0(_0x6a332));await _0x2f7a03[_0x68c859(0x58f)](),console['log'](_0x68c859(0x378)+_0x219cc6+'…');const {envs:_0x3eb44f,blobs:_0x3121c3,skipped:_0x2be83c}=await _0x2f7a03['migrate'][_0x68c859(0xe0)](_0x219cc6);for(const _0x433b59 of _0x3eb44f){const _0x5ba4ac=_0x433b59['sizeBefore']>0x0?_0x68c859(0x48f)+(_0x433b59[_0x68c859(0x287)]/0x400/0x400)['toFixed'](0x2)+'\x20MB\x20→\x20'+(_0x433b59[_0x68c859(0x6cf)]/0x400/0x400)[_0x68c859(0x12a)](0x2)+_0x68c859(0xff):'';console['log'](_0x68c859(0x730)+_0x433b59[_0x68c859(0x58e)]+_0x68c859(0x5ee)+_0x433b59['dest']+_0x5ba4ac+(_0x433b59[_0x68c859(0x16a)]?_0x68c859(0x248):''));}if(_0x3121c3[_0x68c859(0x6b4)]>0x0)console[_0x68c859(0x219)]('\x20\x20✓\x20~blobs\x20\x20('+_0x3121c3[_0x68c859(0x6b4)]+_0x68c859(0x318));for(const _0x5a572f of _0x2be83c)console['log'](_0x68c859(0x43c)+_0x5a572f[_0x68c859(0x58e)]+'\x20\x20skipped:\x20'+_0x5a572f[_0x68c859(0x524)]);await _0x2f7a03[_0x68c859(0x57b)](),console[_0x68c859(0x219)](_0x68c859(0x6f));}async function _0x43e78a(_0x33932b,_0x2b41a8,_0x40b1f9={}){const _0x5a61ee=_0x1ced24,{BACKUP_MANIFEST:_0x2ec131}=requireOkdbMigrate(),_0x64acef=_0x29f498[_0x5a61ee(0x395)](_0x2b41a8[_0x5a61ee(0x6bb)]),_0x1a8fa1=_0x29f498[_0x5a61ee(0x546)](_0x33932b,_0x2ec131);if(!_0x54d51e[_0x5a61ee(0x26e)](_0x1a8fa1))throw new Error(_0x33932b+_0x5a61ee(0x66b)+_0x2ec131+')');const _0x19de4e=JSON[_0x5a61ee(0x110)](_0x54d51e[_0x5a61ee(0x20c)](_0x1a8fa1,_0x5a61ee(0x84))),_0x8244a8=_0x29f498['relative'](_0x33932b,_0x64acef);if(_0x8244a8===''||!(_0x8244a8['startsWith']('..')||_0x29f498[_0x5a61ee(0x539)](_0x8244a8)))throw new Error(_0x5a61ee(0x42c)+_0x64acef+_0x5a61ee(0x77e)+_0x33932b);if(_0x54d51e[_0x5a61ee(0x26e)](_0x64acef)&&_0x54d51e[_0x5a61ee(0x40f)](_0x64acef)[_0x5a61ee(0x2e8)]>0x0)throw new Error(_0x5a61ee(0x42c)+_0x64acef+_0x5a61ee(0x530));console[_0x5a61ee(0x219)]('[okdb]\x20restoring\x20'+_0x33932b+'\x20(okdb\x20'+_0x19de4e[_0x5a61ee(0x719)]+',\x20'+_0x19de4e[_0x5a61ee(0x1af)]+_0x5a61ee(0x36a)+_0x64acef+'…'),_0x54d51e[_0x5a61ee(0x10c)](_0x33932b,_0x64acef,{'recursive':!![],'errorOnExist':!![]});for(const _0x5d22ba of _0x19de4e[_0x5a61ee(0xb1)]??[]){console['log'](_0x5a61ee(0x730)+_0x5d22ba[_0x5a61ee(0x58e)]+(_0x5d22ba[_0x5a61ee(0x16a)]?'\x20\x20(+\x20time-machine)':'')),_0x5d22ba[_0x5a61ee(0x198)]&&_0x5d22ba['sourcePath']&&_0x54d51e[_0x5a61ee(0x26e)](_0x5d22ba[_0x5a61ee(0x5a2)])&&console['log'](_0x5a61ee(0x77a)+_0x5d22ba['name']+'\x20lived\x20outside\x20the\x20store\x20at\x20'+_0x5d22ba[_0x5a61ee(0x5a2)]+_0x5a61ee(0x3fb)+(_0x5a61ee(0x402)+_0x5d22ba[_0x5a61ee(0x641)]+_0x5a61ee(0x6f5)));}_0x40b1f9['newIdentity']&&(require$$5$1['reidentify'](_0x64acef),console[_0x5a61ee(0x219)](_0x5a61ee(0xd9))),console['log'](_0x5a61ee(0x47a));}async function _0x5e97b4(_0x2b819d,_0x1b4acd,_0x1b984b){const _0x5681fc=_0x1ced24,_0x462245=require$$5$1,_0x517521=_0x29f498[_0x5681fc(0x395)](_0x1b4acd['dbPath']),_0x5a17c0=_0x1b984b[_0x5681fc(0x514)]??_0x5681fc(0x666),_0x3259b3=_0x1b984b['types']?_0x1b984b['types'][_0x5681fc(0x527)](',')[_0x5681fc(0x362)](_0x1af7e8=>_0x1af7e8[_0x5681fc(0x220)]()):null;console['log']('[okdb]\x20opening\x20'+_0x517521+'…');const _0x5c5ba0=new _0x462245(_0x517521,_0x2c84a0(_0x1b4acd));await _0x5c5ba0['open'](),console[_0x5681fc(0x219)](_0x5681fc(0x707)+_0x5a17c0+_0x5681fc(0x415)+_0x2b819d+'…');const _0x25fd1d=await _0x5c5ba0['migrate'][_0x5681fc(0x167)](_0x2b819d,{'envName':_0x5a17c0,'types':_0x3259b3,'includeChanges':!!_0x1b984b[_0x5681fc(0x536)]});console[_0x5681fc(0x219)]('[okdb]\x20exported\x20\x20types='+_0x25fd1d['types']+_0x5681fc(0x28c)+_0x25fd1d[_0x5681fc(0x2f6)]+'\x20\x20changes='+_0x25fd1d['changes']);if(_0x1b984b[_0x5681fc(0x35a)]){const _0x5699c4=_0x29f498[_0x5681fc(0x546)](_0x29f498[_0x5681fc(0x37a)](_0x2b819d),_0x5681fc(0x35a));process[_0x5681fc(0x27e)][_0x5681fc(0xc6)](_0x5681fc(0x296));const {count:_0x1fce9b,bytes:_0x3e767e}=await _0x5c5ba0[_0x5681fc(0x13b)][_0x5681fc(0x548)](_0x5699c4);console[_0x5681fc(0x219)]('\x0d[okdb]\x20blobs:\x20'+_0x5699c4+_0x5681fc(0x48f)+_0x1fce9b+_0x5681fc(0x11b)+(_0x1fce9b!==0x1?'s':'')+',\x20'+(_0x3e767e/0x400/0x400)[_0x5681fc(0x12a)](0x2)+_0x5681fc(0xff));}await _0x5c5ba0['close'](),console[_0x5681fc(0x219)](_0x5681fc(0x60b));}async function _0x1ee4a5(_0x59152f,_0x9e6aec,_0x2071b4){const _0x3c5d74=_0x1ced24,_0x331159=require$$5$1,_0x260fed=_0x29f498['resolve'](_0x9e6aec[_0x3c5d74(0x6bb)]),_0xf1f9c3=_0x2071b4[_0x3c5d74(0x514)]??null,_0x40bf0f=_0x2071b4[_0x3c5d74(0x4e6)]?_0x2071b4[_0x3c5d74(0x4e6)][_0x3c5d74(0x527)](',')[_0x3c5d74(0x362)](_0x396a7a=>_0x396a7a[_0x3c5d74(0x220)]()):null,_0x20a699=!!_0x2071b4['drop'];console[_0x3c5d74(0x219)](_0x3c5d74(0x3e1)+_0x260fed+'…');const _0x4380a7=new _0x331159(_0x260fed,_0x2c84a0(_0x9e6aec));await _0x4380a7[_0x3c5d74(0x58f)](),console['log']('[okdb]\x20importing\x20'+_0x59152f+'…');const _0x4fb6ec=await _0x4380a7[_0x3c5d74(0x13b)][_0x3c5d74(0x95)](_0x59152f,{'envName':_0xf1f9c3,'types':_0x40bf0f,'dropExisting':_0x20a699,'includeChanges':!!_0x2071b4[_0x3c5d74(0x536)],'onProgress':({type:_0x31ebdf,count:_0x36e6c8})=>{const _0x39d85f=_0x3c5d74;process['stdout']['write'](_0x39d85f(0x42d)+_0x31ebdf+':\x20'+_0x36e6c8+'\x20records…');}});process[_0x3c5d74(0x27e)][_0x3c5d74(0xc6)]('\x0a'),console[_0x3c5d74(0x219)](_0x3c5d74(0x639)+_0x4fb6ec['types']+_0x3c5d74(0x28c)+_0x4fb6ec[_0x3c5d74(0x2f6)]+_0x3c5d74(0x6fe)+_0x4fb6ec[_0x3c5d74(0x536)]);if(_0x2071b4[_0x3c5d74(0x35a)]){const _0x3e52be=_0x29f498[_0x3c5d74(0x546)](_0x29f498[_0x3c5d74(0x37a)](_0x59152f),'blobs');if(_0x54d51e[_0x3c5d74(0x26e)](_0x3e52be)){const {imported:_0x58bd00,skipped:_0x58f7bb}=await _0x4380a7['migrate'][_0x3c5d74(0x7f)](_0x3e52be);console[_0x3c5d74(0x219)](_0x3c5d74(0x383)+_0x58bd00+_0x3c5d74(0x184)+_0x58f7bb);}}await _0x4380a7[_0x3c5d74(0x57b)](),console[_0x3c5d74(0x219)](_0x3c5d74(0x6f3));}async function _0x5c5a2b(_0x17b1c1,_0x61c99a){const _0xf39193=_0x1ced24;_0x61c99a['password']&&!_0x61c99a[_0xf39193(0x58e)]&&(console[_0xf39193(0x1da)](_0xf39193(0x72a)),process[_0xf39193(0x2e9)](0x1));const _0x445f3f=_0x61c99a[_0xf39193(0x75a)]?_0x61c99a[_0xf39193(0x75a)][_0xf39193(0x527)](',')['map'](_0xce32b9=>_0xce32b9[_0xf39193(0x220)]())[_0xf39193(0x20f)](Boolean):[];let _0x15d93d={};if(_0x61c99a[_0xf39193(0x69c)])try{_0x15d93d=JSON['parse'](_0x61c99a[_0xf39193(0x69c)]);if(typeof _0x15d93d!==_0xf39193(0x25a)||Array[_0xf39193(0x259)](_0x15d93d)||_0x15d93d===null)throw new Error();}catch{console[_0xf39193(0x1da)](_0xf39193(0x551)),process['exit'](0x1);}const _0x4c42e9=require$$5$1,{randomToken:_0x4282a2,hashToken:_0xf08f1f,hashPassword:_0x31c950}=requireOkdbAuthTokens(),_0x2f0038=require$$2$1,_0x5158ba=_0x29f498[_0xf39193(0x395)](_0x17b1c1[_0xf39193(0x6bb)]),_0x2db317=new _0x4c42e9(_0x5158ba,_0x2c84a0(_0x17b1c1));await _0x2db317[_0xf39193(0x58f)]();try{await _0x2db317[_0xf39193(0x9f)][_0xf39193(0x1bb)]();if(_0x61c99a[_0xf39193(0x58e)]){const _0x5f2c0a=await _0x2db317[_0xf39193(0x9f)]['_lookupByName'](_0x61c99a['name']);_0x5f2c0a&&(console[_0xf39193(0x1da)](_0xf39193(0x581)+_0x61c99a[_0xf39193(0x58e)]+_0xf39193(0x5da)),process[_0xf39193(0x2e9)](0x1));}const _0x594e43=_0x4282a2(0x20),_0xb7eaa1=_0xf08f1f(_0x594e43),_0x592f09=_0x61c99a[_0xf39193(0xca)]?await _0x31c950(_0x61c99a[_0xf39193(0xca)]):null,_0x1290b7=_0x2f0038[_0xf39193(0x6bf)](),_0x5c5ff8={'tokenHash':_0xb7eaa1,'name':_0x61c99a['name']||null,'passwordHash':_0x592f09,'label':_0x61c99a[_0xf39193(0x782)]||null,'permissions':_0x445f3f,'grants':_0x15d93d,'createdAt':Date[_0xf39193(0x6f1)](),'lastUsedAt':null},_0x5c4bb0=_0x61c99a[_0xf39193(0x3bd)]?{'ttl':Number(_0x61c99a[_0xf39193(0x3bd)])}:undefined;await _0x2db317[_0xf39193(0x600)]['put'](_0xf39193(0x142),_0x1290b7,_0x5c5ff8,_0x5c4bb0),console['log']('\x0a\x20\x20\u2713\x20Token\x20created'),console['log']('\x20\x20\x20\x20id:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20'+_0x1290b7),console[_0xf39193(0x219)](_0xf39193(0x6c5)+(_0x61c99a['name']||_0xf39193(0x483))),console[_0xf39193(0x219)](_0xf39193(0x103)+(_0x61c99a['label']||_0xf39193(0x483))),console['log'](_0xf39193(0x6f4)+(_0x445f3f[_0xf39193(0x546)](',\x20')||'(none)')),console[_0xf39193(0x219)](_0xf39193(0x3fd)),console[_0xf39193(0x219)](_0xf39193(0x66e)+_0x594e43+'\x0a');}finally{await _0x2db317['close']();}}async function _0x41ba90(_0x119cea){const _0x5c565c=_0x1ced24,_0x3ccd71=require$$5$1,_0x23e0db=_0x29f498['resolve'](_0x119cea['dbPath']),_0x5acbaa=new _0x3ccd71(_0x23e0db,_0x2c84a0(_0x119cea));await _0x5acbaa[_0x5c565c(0x58f)]();try{const _0x2698a8=_0x5acbaa[_0x5c565c(0x600)];if(!_0x2698a8||!_0x2698a8[_0x5c565c(0x59f)](_0x5c565c(0x142))){console[_0x5c565c(0x219)](_0x5c565c(0x55f));return;}const _0x2d077c=[];for(const {key:_0x1a41e2,value:_0x275577}of _0x2698a8[_0x5c565c(0x4f6)]('~tokens')){_0x2d077c[_0x5c565c(0x1c2)]({'id':_0x1a41e2,'name':_0x275577[_0x5c565c(0x58e)]||_0x5c565c(0x483),'label':_0x275577[_0x5c565c(0x782)]||_0x5c565c(0x483),'permissions':Array[_0x5c565c(0x259)](_0x275577[_0x5c565c(0x75a)])?_0x275577['permissions'][_0x5c565c(0x546)](','):'','created':_0x275577[_0x5c565c(0x1af)]?new Date(_0x275577[_0x5c565c(0x1af)])[_0x5c565c(0x165)]()[_0x5c565c(0x762)](0x0,0xa):''});}if(_0x2d077c[_0x5c565c(0x2e8)]===0x0){console[_0x5c565c(0x219)]('No\x20tokens.');return;}const _0xf5d738=!process['stdout'][_0x5c565c(0x40d)]||process[_0x5c565c(0x27e)][_0x5c565c(0x40d)]>=0x64,_0x556ce1=_0xf5d738?0x24:0xa,_0x34c592=['ID'[_0x5c565c(0x6e3)](_0x556ce1),_0x5c565c(0x471)[_0x5c565c(0x6e3)](0x10),_0x5c565c(0x252)['padEnd'](0x14),_0x5c565c(0x5c2)[_0x5c565c(0x6e3)](0x14),'CREATED']['join']('\x20\x20');console['log']('\x0a'+_0x34c592),console[_0x5c565c(0x219)]('-'[_0x5c565c(0x32c)](_0x34c592['length']));for(const _0x2733ec of _0x2d077c){const _0x3eee70=_0xf5d738?_0x2733ec['id']:_0x2733ec['id'][_0x5c565c(0x762)](0x0,0x8)+'…';console['log']([_0x3eee70[_0x5c565c(0x6e3)](_0x556ce1),_0x2733ec[_0x5c565c(0x58e)]['slice'](0x0,0x10)[_0x5c565c(0x6e3)](0x10),_0x2733ec[_0x5c565c(0x782)][_0x5c565c(0x762)](0x0,0x14)[_0x5c565c(0x6e3)](0x14),_0x2733ec[_0x5c565c(0x75a)]['slice'](0x0,0x14)[_0x5c565c(0x6e3)](0x14),_0x2733ec['created']][_0x5c565c(0x546)]('\x20\x20'));}console[_0x5c565c(0x219)]('');}finally{await _0x5acbaa[_0x5c565c(0x57b)]();}}async function _0x41d019(_0x1dfc5a,_0x16fdfa){const _0x41e011=_0x1ced24;!_0x1dfc5a&&(console[_0x41e011(0x1da)](_0x41e011(0x4c2)),process[_0x41e011(0x2e9)](0x1));const _0x3236aa=require$$5$1,_0x1e8995=_0x29f498[_0x41e011(0x395)](_0x16fdfa[_0x41e011(0x6bb)]),_0x5e9d4c=new _0x3236aa(_0x1e8995,_0x2c84a0(_0x16fdfa));await _0x5e9d4c[_0x41e011(0x58f)]();try{const _0x1c9e6e=_0x5e9d4c['_systemEnv'];(!_0x1c9e6e||!_0x1c9e6e[_0x41e011(0x59f)](_0x41e011(0x142)))&&(console[_0x41e011(0x1da)](_0x41e011(0x601)+_0x1dfc5a+'\x22'),process[_0x41e011(0x2e9)](0x1));let _0x94584e=null,_0x45ce53=null;const _0x573bde=_0x1c9e6e[_0x41e011(0x741)]('~tokens',_0x1dfc5a);if(_0x573bde)_0x94584e=_0x1dfc5a,_0x45ce53=_0x573bde;else{const _0x589e4d=[];for(const {key:_0x104146,value:_0x4041e2}of _0x1c9e6e['getRange']('~tokens')){if(_0x104146['startsWith'](_0x1dfc5a))_0x589e4d[_0x41e011(0x1c2)]({'key':_0x104146,'value':_0x4041e2});}_0x589e4d[_0x41e011(0x2e8)]===0x0&&(console[_0x41e011(0x1da)]('[okdb]\x20error:\x20no\x20token\x20with\x20id\x20\x22'+_0x1dfc5a+'\x22'),process[_0x41e011(0x2e9)](0x1));if(_0x589e4d['length']>0x1){console[_0x41e011(0x1da)]('[okdb]\x20error:\x20ambiguous\x20prefix\x20\x22'+_0x1dfc5a+_0x41e011(0x4a2)+_0x589e4d[_0x41e011(0x2e8)]+_0x41e011(0x83));for(const _0x5a5bfd of _0x589e4d){console[_0x41e011(0x1da)]('\x20\x20'+_0x5a5bfd['key']+_0x41e011(0x2b9)+(_0x5a5bfd['value'][_0x41e011(0x58e)]||_0x41e011(0x483))+')');}process[_0x41e011(0x2e9)](0x1);}_0x94584e=_0x589e4d[0x0][_0x41e011(0x1cd)],_0x45ce53=_0x589e4d[0x0][_0x41e011(0x1c5)];}await _0x1c9e6e[_0x41e011(0x5ce)](_0x41e011(0x142),_0x94584e),console['log'](_0x41e011(0x66c)+_0x94584e+_0x41e011(0x2b9)+(_0x45ce53['name']||'(unset)')+_0x41e011(0x569)+(_0x45ce53[_0x41e011(0x782)]||_0x41e011(0x483))+')');}finally{await _0x5e9d4c[_0x41e011(0x57b)]();}}function _0x229b2a(_0x5e5fc1,_0xc5e364){const _0x6be288=_0x1ced24;if(!_0x5e5fc1[_0x6be288(0x7e)])return _0x6be288(0x147);const _0x53af23=_0x5e5fc1[_0x6be288(0x738)];if(!_0x53af23)return'active';if(_0xc5e364>_0x53af23)return'expired';return _0x6be288(0x351);}function _0xc3cb4b(_0x5d34af){const _0x157b75=_0x1ced24;if(!_0x5d34af||typeof _0x5d34af!==_0x157b75(0x25a))return'';const _0x3e8432=Object[_0x157b75(0x377)](_0x5d34af)[_0x157b75(0x20f)](([,_0xc08839])=>_0xc08839)[_0x157b75(0x362)](([_0x207884])=>_0x207884);if(_0x3e8432[_0x157b75(0x2e8)]===0x0)return _0x157b75(0x376);if(_0x3e8432[_0x157b75(0x2e8)]<=0x3)return _0x3e8432[_0x157b75(0x546)]('\x20');return _0x3e8432[_0x157b75(0x762)](0x0,0x3)[_0x157b75(0x546)]('\x20')+('\x20+'+(_0x3e8432['length']-0x3));}async function _0x4c0c3d(_0x47d7f1){const _0x5b5671=_0x1ced24,_0x19108c=require$$5$1,_0x255bbb=requireOkdbLicenseCodec(),{_C:_0x119e6a}=requireOkdbLicense(),_0x5b7ded=_0x29f498[_0x5b5671(0x395)](_0x47d7f1['dbPath']),_0x6ca6fc=new _0x19108c(_0x5b7ded,_0x2c84a0(_0x47d7f1));await _0x6ca6fc[_0x5b5671(0x58f)]();try{const _0x3a3a39=_0x6ca6fc[_0x5b5671(0x600)],_0x308550=_0x3a3a39?.['db']?.[_0x5b5671(0x741)]?.('__writeCounter')??0x0,_0x1cace0=[..._0x6ca6fc[_0x5b5671(0x319)]['keys']()]['filter'](_0x28e7cb=>!_0x28e7cb[_0x5b5671(0x557)]('~'))[_0x5b5671(0x2e8)],_0x34878f=_0x6ca6fc[_0x5b5671(0x21c)]?.['effective'];if(_0x34878f){const _0x2a98ce=_0x34878f['_isFree']===!![],_0x4ce1c6=_0x2a98ce?'free\x20tier':_0x6ca6fc[_0x5b5671(0x21c)][_0x5b5671(0x351)]?.[_0x5b5671(0x511)]||_0x5b5671(0x51a);console[_0x5b5671(0x219)](''),console['log'](_0x5b5671(0x6a2)+_0x4ce1c6);const _0x36b599=_0x34878f['limits']||{};if(_0x36b599[_0x5b5671(0x47c)]){const _0x49b2a4=Math[_0x5b5671(0x38d)](_0x308550/_0x36b599['maxWrites']*0x64);console['log'](_0x5b5671(0x122)+_0x308550['toLocaleString']()+_0x5b5671(0x3e9)+_0x36b599[_0x5b5671(0x47c)][_0x5b5671(0x671)]()+_0x5b5671(0x48f)+_0x49b2a4+'%)');}else console[_0x5b5671(0x219)](_0x5b5671(0x122)+_0x308550[_0x5b5671(0x671)]());_0x36b599[_0x5b5671(0xb1)]?console[_0x5b5671(0x219)]('\x20\x20Envs:\x20\x20\x20\x20'+_0x1cace0+_0x5b5671(0x3e9)+_0x36b599[_0x5b5671(0xb1)]):console['log'](_0x5b5671(0x73)+_0x1cace0),_0x119e6a?.[_0x5b5671(0x398)]&&console[_0x5b5671(0x219)](_0x5b5671(0x6bd)+_0x119e6a[_0x5b5671(0x398)]+_0x5b5671(0x65d));}if(!_0x3a3a39||!_0x3a3a39[_0x5b5671(0x59f)]('~licenses')){console[_0x5b5671(0x219)](''),console[_0x5b5671(0x219)](_0x5b5671(0x189)),console[_0x5b5671(0x219)]('');return;}const _0x165bd0=[],_0x37c85e=Date[_0x5b5671(0x6f1)](),_0x342aa9=_0x6ca6fc['id'],_0x591b88=_0x5b5671(0x6ec);for(const {key:_0x52e329,value:_0x12c1dc}of _0x3a3a39[_0x5b5671(0x4f6)]('~licenses')){const _0x200ddb=_0x12c1dc[_0x5b5671(0x221)]?Buffer['from'](_0x12c1dc[_0x5b5671(0x221)],_0x5b5671(0x52c)):Buffer[_0x5b5671(0x74e)](0x8);let _0x1bf31a='';try{_0x1bf31a=_0x255bbb[_0x5b5671(0x79a)](_0x342aa9,_0x200ddb,_0x591b88)['pin'];}catch{}_0x165bd0[_0x5b5671(0x1c2)]({'id':_0x52e329,'licensee':_0x12c1dc[_0x5b5671(0x511)]||'','expires':_0x12c1dc['expiresAt']?new Date(_0x12c1dc['expiresAt'])['toISOString']()[_0x5b5671(0x762)](0x0,0xa):'','features':_0xc3cb4b(_0x12c1dc[_0x5b5671(0x427)]),'pin':_0x1bf31a,'status':_0x229b2a(_0x12c1dc,_0x37c85e)});}if(_0x165bd0[_0x5b5671(0x2e8)]===0x0){console[_0x5b5671(0x219)](''),console[_0x5b5671(0x219)](_0x5b5671(0x189)),console[_0x5b5671(0x219)]('');return;}const _0xda246c=['\x20\x20'+'ID'[_0x5b5671(0x6e3)](0xe),_0x5b5671(0x68f)[_0x5b5671(0x6e3)](0xe),_0x5b5671(0xcc)[_0x5b5671(0x6e3)](0xc),_0x5b5671(0x504)['padEnd'](0x1e),_0x5b5671(0x5fe)[_0x5b5671(0x6e3)](0xa),'STATUS'][_0x5b5671(0x546)]('\x20');console[_0x5b5671(0x219)]('\x0a'+_0xda246c);for(const _0x3faea6 of _0x165bd0){const _0x1b5048=_0x3faea6['id'][_0x5b5671(0x762)](0x0,0x8)+'\u2026';console[_0x5b5671(0x219)](['\x20\x20'+_0x1b5048[_0x5b5671(0x6e3)](0xe),_0x3faea6[_0x5b5671(0x511)]['slice'](0x0,0xe)[_0x5b5671(0x6e3)](0xe),_0x3faea6[_0x5b5671(0x10a)]['padEnd'](0xc),_0x3faea6[_0x5b5671(0x427)]['slice'](0x0,0x1e)[_0x5b5671(0x6e3)](0x1e),_0x3faea6[_0x5b5671(0xea)][_0x5b5671(0x6e3)](0xa),_0x3faea6['status']][_0x5b5671(0x546)]('\x20'));}console[_0x5b5671(0x219)]('');}finally{await _0x6ca6fc['close']();}}async function _0xf1aa66(_0x540bf6,_0x30d8dd){const _0x2e9a21=_0x1ced24,_0xe4e2b8=require$$5$1,_0x273065=requireOkdbLicenseCodec();let _0x2ed60a=_0x540bf6;(_0x273065[_0x2e9a21(0x2ec)](_0x540bf6)===_0x2e9a21(0x2cc)||_0x54d51e[_0x2e9a21(0x26e)](_0x540bf6)&&_0x54d51e[_0x2e9a21(0x1a4)](_0x540bf6)['isFile']())&&(_0x2ed60a=_0x54d51e['readFileSync'](_0x540bf6,_0x2e9a21(0x84))[_0x2e9a21(0x220)]());const _0x33cb9e=_0x29f498[_0x2e9a21(0x395)](_0x30d8dd['dbPath']),_0x2d86c0=new _0xe4e2b8(_0x33cb9e,_0x2c84a0(_0x30d8dd));await _0x2d86c0[_0x2e9a21(0x58f)]();try{let _0x1770b2;try{_0x1770b2=await _0x2d86c0['licenses'][_0x2e9a21(0x5f3)]({'blob':_0x2ed60a});}catch(_0x862ce4){console[_0x2e9a21(0x1da)](_0x2e9a21(0xb7)+_0x862ce4[_0x2e9a21(0x71d)]),process[_0x2e9a21(0x2e9)](0x1);}const _0x289a2f=_0x1770b2[_0x2e9a21(0xea)]||'',_0x4be5c2=Object[_0x2e9a21(0x377)](_0x1770b2['features']||{})[_0x2e9a21(0x20f)](([,_0x4da9d8])=>_0x4da9d8)[_0x2e9a21(0x362)](([_0x36eb57])=>_0x36eb57),_0x55a5cb=_0x1770b2['limits']||{},_0x754197=[_0x55a5cb[_0x2e9a21(0xb1)]?_0x2e9a21(0x621)+_0x55a5cb[_0x2e9a21(0xb1)]:null,_0x55a5cb[_0x2e9a21(0x4f3)]?'types/env='+_0x55a5cb['typesPerEnv']:null,_0x55a5cb[_0x2e9a21(0x2ef)]?_0x2e9a21(0x4f1)+_0x55a5cb[_0x2e9a21(0x2ef)]:null,_0x55a5cb['maxWrites']?_0x2e9a21(0x4b5)+_0x55a5cb[_0x2e9a21(0x47c)][_0x2e9a21(0x671)]():null]['filter'](Boolean)[_0x2e9a21(0x546)]('\x20\x20'),_0x365895=_0x1770b2[_0x2e9a21(0x5be)]!==_0x2e9a21(0x561);console[_0x2e9a21(0x219)](_0x1770b2[_0x2e9a21(0x501)]?_0x2e9a21(0x2cd):_0x2e9a21(0x489)),console[_0x2e9a21(0x219)]('\x20\x20\x20\x20id:\x20\x20\x20\x20\x20\x20\x20\x20'+_0x1770b2['id']),console[_0x2e9a21(0x219)](_0x2e9a21(0x474)+_0x1770b2[_0x2e9a21(0x511)]),console[_0x2e9a21(0x219)](_0x2e9a21(0x31b)+(_0x1770b2[_0x2e9a21(0x738)]?new Date(_0x1770b2['expiresAt'])[_0x2e9a21(0x165)]()['slice'](0x0,0xa):_0x2e9a21(0x104))),console[_0x2e9a21(0x219)](_0x2e9a21(0xef)+(_0x4be5c2[_0x2e9a21(0x546)](',\x20')||_0x2e9a21(0x376)));if(_0x754197)console[_0x2e9a21(0x219)]('\x20\x20\x20\x20limits:\x20\x20\x20\x20'+_0x754197);if(_0x365895)console[_0x2e9a21(0x219)](_0x2e9a21(0x2f4)+_0x1770b2['type']+_0x2e9a21(0x228)),console['log']('');else!_0x1770b2['needsActivation']?(console[_0x2e9a21(0x219)](_0x2e9a21(0x6c9)+_0x1770b2[_0x2e9a21(0x469)]),console[_0x2e9a21(0x219)]('')):(console['log']('\x20\x20\x20\x20pin:\x20\x20\x20\x20\x20\x20\x20'+_0x289a2f),console[_0x2e9a21(0x219)](_0x2e9a21(0x192)),console[_0x2e9a21(0x219)](''),console[_0x2e9a21(0x219)]('\x20\x20Next\x20step\x20\u2014\x20activate\x20the\x20license:'),console[_0x2e9a21(0x219)](_0x2e9a21(0x145)+_0x289a2f+_0x2e9a21(0x3ba)),console['log'](_0x2e9a21(0x611)),console[_0x2e9a21(0x219)](_0x2e9a21(0x321)),console[_0x2e9a21(0x219)](''));}finally{await _0x2d86c0[_0x2e9a21(0x57b)]();}}async function _0x5ece99(_0x1e9527,_0x3fc481){const _0x14a29f=_0x1ced24,_0x17c4b6=require$$5$1,_0xec2930=_0x29f498[_0x14a29f(0x395)](_0x3fc481[_0x14a29f(0x6bb)]),_0x5c3216=new _0x17c4b6(_0xec2930,_0x2c84a0(_0x3fc481));await _0x5c3216['open']();try{let _0x3a1733;try{_0x3a1733=await _0x5c3216[_0x14a29f(0x691)][_0x14a29f(0x590)](_0x1e9527);}catch(_0x544eee){console[_0x14a29f(0x1da)](_0x14a29f(0xb7)+_0x544eee['message']),console[_0x14a29f(0x1da)](''),console['error'](_0x14a29f(0x513)),console[_0x14a29f(0x1da)]('\x20\x20\x20\x20-\x20The\x20license\x20blob\x20has\x20not\x20been\x20added\x20yet\x20—\x20run\x20`okdb\x20license\x20<blob>`\x20first.'),console[_0x14a29f(0x1da)]('\x20\x20\x20\x20-\x20The\x20activation\x20token\x20was\x20issued\x20for\x20a\x20different\x20node\x20—\x20share\x20this\x20node\x27s\x20PIN\x20with\x20the\x20vendor.'),console[_0x14a29f(0x1da)](_0x14a29f(0x1fd)),console[_0x14a29f(0x1da)](''),process['exit'](0x1);}console[_0x14a29f(0x219)](_0x14a29f(0x3fa)),console['log'](_0x14a29f(0x6de)+_0x3a1733['id']),console[_0x14a29f(0x219)](_0x14a29f(0x474)+_0x3a1733['licensee']),console[_0x14a29f(0x219)](_0x14a29f(0x31b)+(_0x3a1733[_0x14a29f(0x738)]?new Date(_0x3a1733['expiresAt'])[_0x14a29f(0x165)]()[_0x14a29f(0x762)](0x0,0xa):_0x14a29f(0x104))),console[_0x14a29f(0x219)](_0x14a29f(0x50c)),console[_0x14a29f(0x219)]('');}finally{await _0x5c3216[_0x14a29f(0x57b)]();}}async function _0x2e5f10(_0x136eaa,_0x503150){const _0x47db0e=_0x1ced24;!_0x136eaa&&(console[_0x47db0e(0x1da)](_0x47db0e(0x605)),process['exit'](0x1));const _0x340f4b=require$$5$1,_0x5cbb9d=requireOkdbLicenseCodec(),_0x482ec3=_0x29f498[_0x47db0e(0x395)](_0x503150[_0x47db0e(0x6bb)]),_0x218715=new _0x340f4b(_0x482ec3,_0x2c84a0(_0x503150));await _0x218715['open']();try{const _0x36dd13=_0x218715['_systemEnv'];(!_0x36dd13||!_0x36dd13['hasType'](_0x47db0e(0x3b4)))&&(console['error'](_0x47db0e(0x3d6)+_0x136eaa+'\x22'),process[_0x47db0e(0x2e9)](0x1));let _0x52cad3=null,_0x4f7746=null;const _0x313004=_0x36dd13['get'](_0x47db0e(0x3b4),_0x136eaa);if(_0x313004)_0x52cad3=_0x136eaa,_0x4f7746=_0x313004;else{const _0x1cdabc=[];for(const {key:_0x2c3512,value:_0x27b3f9}of _0x36dd13[_0x47db0e(0x4f6)]('~licenses')){if(_0x2c3512[_0x47db0e(0x557)](_0x136eaa))_0x1cdabc[_0x47db0e(0x1c2)]({'key':_0x2c3512,'value':_0x27b3f9});}_0x1cdabc[_0x47db0e(0x2e8)]===0x0&&(console['error']('[okdb]\x20error:\x20no\x20license\x20with\x20id\x20\x22'+_0x136eaa+'\x22'),process[_0x47db0e(0x2e9)](0x1)),_0x1cdabc[_0x47db0e(0x2e8)]>0x1&&(console[_0x47db0e(0x1da)]('[okdb]\x20error:\x20ambiguous\x20prefix\x20\x22'+_0x136eaa+_0x47db0e(0x4a2)+_0x1cdabc['length']+_0x47db0e(0x73d)),process['exit'](0x1)),_0x52cad3=_0x1cdabc[0x0][_0x47db0e(0x1cd)],_0x4f7746=_0x1cdabc[0x0][_0x47db0e(0x1c5)];}const _0xc67b04=Date[_0x47db0e(0x6f1)](),_0x56e235=_0x229b2a(_0x4f7746,_0xc67b04),_0x5c8e25=_0x218715['id'],_0x4f590f='__OKDB_PUB_FINGERPRINT__';let _0x2c0267='';try{const _0x48c46b=Buffer['from'](_0x4f7746[_0x47db0e(0x221)],_0x47db0e(0x52c));_0x2c0267=_0x5cbb9d[_0x47db0e(0x79a)](_0x5c8e25,_0x48c46b,_0x4f590f)['pin'];}catch{}const _0x59b8c5=_0x4f7746[_0x47db0e(0x427)]?Object[_0x47db0e(0x377)](_0x4f7746['features'])[_0x47db0e(0x20f)](([,_0x3e4f75])=>_0x3e4f75)[_0x47db0e(0x362)](([_0x31a26f])=>_0x31a26f):[],_0x53262c=_0x4f7746[_0x47db0e(0x194)]||{},_0x3ac0f3=_0x36dd13?.['db']?.[_0x47db0e(0x741)]?.(_0x47db0e(0x3a7))??0x0,_0x53dc25=[..._0x218715[_0x47db0e(0x319)][_0x47db0e(0x449)]()][_0x47db0e(0x20f)](_0x35ea0d=>!_0x35ea0d[_0x47db0e(0x557)]('~'))[_0x47db0e(0x2e8)];console[_0x47db0e(0x219)](_0x47db0e(0x216)),console[_0x47db0e(0x219)](_0x47db0e(0x6de)+_0x52cad3),console['log'](_0x47db0e(0x474)+(_0x4f7746[_0x47db0e(0x511)]||'')),console[_0x47db0e(0x219)](_0x47db0e(0x31b)+(_0x4f7746['expiresAt']?new Date(_0x4f7746[_0x47db0e(0x738)])['toISOString']()[_0x47db0e(0x762)](0x0,0xa):'')),console[_0x47db0e(0x219)](_0x47db0e(0xef)+(_0x59b8c5[_0x47db0e(0x546)](',\x20')||_0x47db0e(0x376))),console['log']('\x20\x20\x20\x20pin:\x20\x20\x20\x20\x20\x20\x20'+_0x2c0267),console[_0x47db0e(0x219)](_0x47db0e(0x6c9)+_0x56e235),console['log'](_0x47db0e(0x722)+new Date(_0x4f7746['addedAt'])[_0x47db0e(0x165)]());if(_0x56e235==='active'){console[_0x47db0e(0x219)](''),console[_0x47db0e(0x219)](_0x47db0e(0x6f6));if(_0x53262c[_0x47db0e(0x47c)]){const _0x3a7e80=Math[_0x47db0e(0x38d)](_0x3ac0f3/_0x53262c[_0x47db0e(0x47c)]*0x64);console[_0x47db0e(0x219)](_0x47db0e(0x724)+_0x3ac0f3[_0x47db0e(0x671)]()+_0x47db0e(0x3e9)+_0x53262c[_0x47db0e(0x47c)][_0x47db0e(0x671)]()+'\x20\x20('+_0x3a7e80+'%)');}else console[_0x47db0e(0x219)](_0x47db0e(0x724)+_0x3ac0f3[_0x47db0e(0x671)]()+_0x47db0e(0x1e7));_0x53262c[_0x47db0e(0xb1)]?console[_0x47db0e(0x219)](_0x47db0e(0x372)+_0x53dc25+_0x47db0e(0x3e9)+_0x53262c['envs']):console['log'](_0x47db0e(0x372)+_0x53dc25+_0x47db0e(0x1e7));}console['log']('');}finally{await _0x218715[_0x47db0e(0x57b)]();}}async function _0x18ec14(_0x15c70a,_0x316311){const _0x15d93a=_0x1ced24;!_0x15c70a&&(console['error'](_0x15d93a(0x4ee)),process[_0x15d93a(0x2e9)](0x1));const _0x295f45=require$$5$1,_0x16fdb5=_0x29f498['resolve'](_0x316311[_0x15d93a(0x6bb)]),_0x59d25f=new _0x295f45(_0x16fdb5,_0x2c84a0(_0x316311));await _0x59d25f[_0x15d93a(0x58f)]();try{const _0x186f71=_0x59d25f[_0x15d93a(0x600)];(!_0x186f71||!_0x186f71[_0x15d93a(0x59f)](_0x15d93a(0x3b4)))&&(console[_0x15d93a(0x1da)](_0x15d93a(0x3d6)+_0x15c70a+'\x22'),process[_0x15d93a(0x2e9)](0x1));let _0x3fb95e=null,_0x346a71=null;const _0x14a1ba=_0x186f71[_0x15d93a(0x741)](_0x15d93a(0x3b4),_0x15c70a);if(_0x14a1ba)_0x3fb95e=_0x15c70a,_0x346a71=_0x14a1ba;else{const _0x135532=[];for(const {key:_0x27cf5b,value:_0xb46fe}of _0x186f71[_0x15d93a(0x4f6)](_0x15d93a(0x3b4))){if(_0x27cf5b['startsWith'](_0x15c70a))_0x135532[_0x15d93a(0x1c2)]({'key':_0x27cf5b,'value':_0xb46fe});}_0x135532['length']===0x0&&(console[_0x15d93a(0x1da)]('[okdb]\x20error:\x20no\x20license\x20with\x20id\x20\x22'+_0x15c70a+'\x22'),process[_0x15d93a(0x2e9)](0x1)),_0x135532[_0x15d93a(0x2e8)]>0x1&&(console[_0x15d93a(0x1da)](_0x15d93a(0x312)+_0x15c70a+_0x15d93a(0x4a2)+_0x135532[_0x15d93a(0x2e8)]+_0x15d93a(0x73d)),process['exit'](0x1)),_0x3fb95e=_0x135532[0x0][_0x15d93a(0x1cd)],_0x346a71=_0x135532[0x0]['value'];}await _0x186f71[_0x15d93a(0x5ce)](_0x15d93a(0x3b4),_0x3fb95e),console[_0x15d93a(0x219)](_0x15d93a(0x5df)+_0x3fb95e+_0x15d93a(0x347)+(_0x346a71[_0x15d93a(0x511)]||'(unset)')+')');}finally{await _0x59d25f[_0x15d93a(0x57b)]();}}async function _0x4d6418(_0x259a2c,_0x22481d,_0x121560){const _0x545ae0=_0x1ced24;!_0x259a2c&&(console['error'](_0x545ae0(0x1f8)),process[_0x545ae0(0x2e9)](0x1));!_0x121560[_0x545ae0(0x2f5)]&&!(_0x121560[_0x545ae0(0x4e3)]&&_0x121560[_0x545ae0(0xca)])&&(console[_0x545ae0(0x1da)](_0x545ae0(0x5ec)),process[_0x545ae0(0x2e9)](0x1));const _0x5da95f=_0x121560[_0x545ae0(0x68b)]||_0x22481d[_0x545ae0(0x15e)]?.[_0x545ae0(0xb4)];!_0x5da95f&&(console[_0x545ae0(0x1da)](_0x545ae0(0x4f2)+_0x545ae0(0x73b)+'\x20\x20Or\x20set\x20sync.address\x20in\x20.kdbconfig'),process[_0x545ae0(0x2e9)](0x1));const _0x2030e6=require$$5$1,_0x1fdf48=new _0x2030e6(_0x22481d[_0x545ae0(0x6bb)],{'sync':{'address':_0x5da95f,'auto_reconcile':![]}});await _0x1fdf48['open']();try{const _0x18209b=_0x1fdf48[_0x545ae0(0x600)];if(_0x18209b&&_0x18209b[_0x545ae0(0x59f)]('~tokens')){let _0x248456=![];for(const _0x2edce3 of _0x18209b[_0x545ae0(0x4f6)](_0x545ae0(0x142))){_0x248456=!![];break;}_0x248456&&console[_0x545ae0(0x219)]('\x20\x20Note:\x20this\x20node\x20has\x20existing\x20tokens.\x20They\x20will\x20coexist\x20with\x20cluster\x20tokens\x0a'+_0x545ae0(0x688));}console[_0x545ae0(0x219)](_0x545ae0(0x77f)+_0x259a2c+'…'),await _0x1fdf48[_0x545ae0(0x15e)][_0x545ae0(0x546)](_0x259a2c[_0x545ae0(0x61f)](/\/+$/,''),{'token':_0x121560[_0x545ae0(0x2f5)],'username':_0x121560[_0x545ae0(0x4e3)],'password':_0x121560[_0x545ae0(0xca)]}),console['log'](_0x545ae0(0x1cf)),console[_0x545ae0(0x219)](_0x545ae0(0x11e));}finally{await _0x1fdf48[_0x545ae0(0x57b)]();}}async function _0x14f948(){const _0x2b5f11=_0x1ced24,_0x12fe86=Date[_0x2b5f11(0x6f1)](),_0x72ffb=_0x5bba9e(process[_0x2b5f11(0x19b)]),_0x312223=_0x1e64b7(_0x72ffb),_0x212f7f=_0x29f498[_0x2b5f11(0x395)](_0x312223[_0x2b5f11(0x6bb)]);!_0x312223[_0x2b5f11(0x133)]&&!process['stdin']['isTTY']&&(_0x312223[_0x2b5f11(0x133)]=!![]);const _0x4b8062=require$$5$1,{start:_0x272423,colorLog:_0x337fb7}=requireOkdbShell(),_0x1557d6=require$$1$1,_0x3b19bd={..._0x312223[_0x2b5f11(0x1cd)]?{'encryptionKey':_0x312223[_0x2b5f11(0x1cd)]}:{},..._0x312223[_0x2b5f11(0x733)]?{'admin':![]}:_0x39c929(_0x312223[_0x2b5f11(0x1dd)])?{'admin':_0x312223[_0x2b5f11(0x1dd)]}:{},..._0x39c929(_0x312223[_0x2b5f11(0x729)])?{'api':_0x312223['api']}:{},..._0x39c929(_0x312223['auth'])?{'auth':_0x312223['auth']}:{},..._0x39c929(_0x312223[_0x2b5f11(0x584)])?{'mcp':_0x312223['mcp']}:{},..._0x39c929(_0x312223['backup'])?{'backup':_0x312223['backup']}:{},..._0x312223[_0x2b5f11(0x16a)]!==![]?{'timeMachine':_0x312223[_0x2b5f11(0x16a)]}:{},...Object[_0x2b5f11(0x341)](_0xb50e42[_0x2b5f11(0x20f)](_0x5cd9e6=>_0x312223[_0x5cd9e6]!==undefined)['map'](_0x356309=>[_0x356309,_0x312223[_0x356309]]))},_0x51583d=_0x205ff4(_0x312223);if(!_0x1557d6[_0x2b5f11(0x46e)]){const _0x3c7225=_0x508908(),_0x2b18b5=_0x312223[_0x2b5f11(0x330)]?'--no-cluster':_0x312223[_0x2b5f11(0x505)]!=null&&_0x312223['workersFlag']!==''?_0x2b5f11(0x710):process.env.OKDB_HTTP_WORKERS?_0x2b5f11(0x28a):_0x312223['http']?.[_0x2b5f11(0x571)]!=null?'config\x20http.workers':'default:\x20cores−1\x20=\x20'+Math[_0x2b5f11(0x608)](0x1,require$$0['cpus']()[_0x2b5f11(0x2e8)]-0x1);process[_0x2b5f11(0x27e)]['write']('[okdb]\x20http\x20workers:\x20'+_0x51583d+'\x20('+_0x2b18b5+(!_0x3c7225?_0x2b5f11(0x718):'')+')\x0a');}if(_0x1557d6[_0x2b5f11(0x46e)]){const _0x6c52e2={..._0x3b19bd},_0x10c023=new _0x4b8062(_0x212f7f,_0x6c52e2);_0x10c023[_0x2b5f11(0x219)]['detachConsole']?.();const _0x1828d0=process.env.OKDB_CLUSTER_SLOT??'?',_0x47450c={'debug':0x0,'info':0x1,'warn':0x2,'error':0x3},_0x1e6b2c=_0x47450c[_0x312223[_0x2b5f11(0x628)]]??_0x47450c[_0x2b5f11(0x1b9)];_0x10c023[_0x2b5f11(0x219)][_0x2b5f11(0x6b2)](_0x1c0576=>{const _0xc75ed0=_0x2b5f11;if((_0x47450c[_0x1c0576['level']]??0x1)<_0x1e6b2c)return;try{process[_0xc75ed0(0x50a)]?.({'__okdbCluster':'log','slot':_0x1828d0,'pid':process[_0xc75ed0(0x401)],'entry':_0x1c0576});}catch{}}),await _0x10c023[_0x2b5f11(0x58f)]();const {attachWorkerCluster:_0x2dd127}=requireOkdbCluster();_0x2dd127(_0x10c023),await _0x43ffc2(_0x10c023,_0x312223[_0x2b5f11(0x64d)],_0x1d7805(_0x312223));return;}if(_0x51583d>0x1){const {runClustered:_0x45025e}=requireOkdbCluster(),_0x585acd=new _0x4b8062(_0x212f7f,{..._0x3b19bd,'engines':![],'processors':![],'compaction':![]});await _0x585acd[_0x2b5f11(0x58f)]();const _0x22d34f=async()=>{const _0x320dd0=new _0x4b8062(_0x212f7f,{..._0x3b19bd});return await _0x320dd0['open'](),_0x320dd0;},_0xf90e6f=Object['fromEntries'](_0xb50e42[_0x2b5f11(0x362)](_0x19e35c=>[_0x19e35c,_0x3b19bd[_0x19e35c]??!![]])),{formatListenAddr:_0x5da1e0}=requireOkdbHttp(),_0x130f11=_0x5da1e0(_0x312223[_0x2b5f11(0x64d)],_0x312223[_0x2b5f11(0x1be)]?.[_0x2b5f11(0x2a4)]),_0x4a5c39=_0x45025e({'workers':_0x51583d,'makeOkdb':_0x22d34f,'port':_0x312223[_0x2b5f11(0x64d)],'primaryOkdb':_0x585acd,'workerRole':_0xf90e6f,'listenAddr':_0x130f11});let _0x2ab477=![];async function _0x31f2e4(_0x2fa1b0){const _0x547381=_0x2b5f11;_0x2ab477&&(process[_0x547381(0x544)][_0x547381(0xc6)](_0x547381(0x66d)),process['exit'](0x82));_0x2ab477=!![],process[_0x547381(0x544)][_0x547381(0xc6)](_0x547381(0x20d)+(_0x2fa1b0||_0x547381(0x521))+_0x547381(0x52e));const _0x404242=setTimeout(()=>{const _0x37c3ad=_0x547381;process['stderr'][_0x37c3ad(0xc6)]('[okdb]\x20shutdown\x20drain\x20exceeded\x203000ms\x20—\x20hard-exiting\x0a'),process[_0x37c3ad(0x2e9)](0x0);},0xbb8);_0x404242[_0x547381(0x575)]?.();try{await _0x4a5c39['close']();}catch(_0x1247f5){process['stderr'][_0x547381(0xc6)](_0x547381(0x97)+(_0x1247f5?.[_0x547381(0x71d)]??_0x1247f5)+'\x0a');}try{await _0x585acd[_0x547381(0x57b)]();}catch(_0x352498){process[_0x547381(0x544)][_0x547381(0xc6)](_0x547381(0x234)+(_0x352498?.[_0x547381(0x71d)]??_0x352498)+'\x0a');}process['exit'](0x0);}_0x312223[_0x2b5f11(0x5e1)]=_0x51583d;if(!_0x312223[_0x2b5f11(0x133)]){_0x585acd['log'][_0x2b5f11(0x5fa)]?.(),_0x280b5a(_0x585acd['auth']?.[_0x2b5f11(0x6d4)]?.()??[]),await _0x272423(_0x585acd,_0x312223);return;}process['stdout'][_0x2b5f11(0xc6)](_0x2b5f11(0xbb)+process['pid']+_0x2b5f11(0x8c)+_0x51583d+'\x20'+(_0x2b5f11(0x288)+_0x312223[_0x2b5f11(0x64d)]+'\x0a')),console[_0x2b5f11(0x219)](''),console[_0x2b5f11(0x219)](_0x2b5f11(0x403)),console[_0x2b5f11(0x219)](_0x2b5f11(0xd7)+_0x312223[_0x2b5f11(0x64d)]+_0x2b5f11(0x48f)+_0x51583d+_0x2b5f11(0x17a)),console[_0x2b5f11(0x219)](_0x2b5f11(0x333)+_0x212f7f),console[_0x2b5f11(0x219)]('\x20\x20\x20\x20id:\x20\x20\x20\x20\x20\x20'+_0x585acd['id']),console[_0x2b5f11(0x219)](_0x2b5f11(0x798)+_0x312223[_0x2b5f11(0x64d)]+_0x2b5f11(0x784));!_0x312223[_0x2b5f11(0x733)]&&console[_0x2b5f11(0x219)]('\x20\x20\x20\x20admin:\x20\x20\x20http://localhost:'+_0x312223['port']+'/admin/index.html');console[_0x2b5f11(0x219)](''),_0x280b5a(_0x585acd[_0x2b5f11(0x9f)]?.[_0x2b5f11(0x6d4)]?.()??[]),process['on'](_0x2b5f11(0x2ea),()=>_0x31f2e4(_0x2b5f11(0x2ea))),process['on']('SIGTERM',()=>_0x31f2e4(_0x2b5f11(0x9b))),process['on']('SIGBREAK',()=>_0x31f2e4(_0x2b5f11(0x5a0)));return;}const _0x220c35=new _0x4b8062(_0x212f7f,_0x3b19bd);_0x220c35[_0x2b5f11(0x219)][_0x2b5f11(0x5fa)]?.();const _0x103e6f=_0x220c35[_0x2b5f11(0x219)][_0x2b5f11(0x6b2)](_0x452789=>_0x337fb7(_0x452789,_0x312223[_0x2b5f11(0x628)]));if(_0x312223[_0x2b5f11(0x133)])process[_0x2b5f11(0x27e)][_0x2b5f11(0xc6)]('[okdb]\x20starting…\x0a');await _0x220c35[_0x2b5f11(0x58f)]();if(_0x312223[_0x2b5f11(0x133)])process[_0x2b5f11(0x27e)][_0x2b5f11(0xc6)](_0x2b5f11(0x485));try{await _0x43ffc2(_0x220c35,_0x312223[_0x2b5f11(0x64d)],_0x1d7805(_0x312223));}catch(_0x19ef09){_0x19ef09[_0x2b5f11(0x72d)]===_0x2b5f11(0x73e)&&(console['error']('[okdb]\x20port\x20'+_0x312223[_0x2b5f11(0x64d)]+_0x2b5f11(0x411)),process[_0x2b5f11(0x2e9)](0x1));throw _0x19ef09;}if(_0x312223['noRepl']){const _0x25a847=_0x312223[_0x2b5f11(0x1be)]?.[_0x2b5f11(0x2a4)]!==undefined?[][_0x2b5f11(0x4e0)](_0x312223[_0x2b5f11(0x1be)]['host'])['join'](',\x20')+'\x20':'';process[_0x2b5f11(0x27e)]['write'](_0x2b5f11(0x576)+_0x25a847+':'+_0x312223['port']+'\x0a');}if(!_0x312223['noRepl'])_0x220c35[_0x2b5f11(0x219)]['detachConsole']?.(),_0x103e6f?.(),_0x280b5a(_0x220c35[_0x2b5f11(0x9f)]?.[_0x2b5f11(0x6d4)]?.()??[]),await _0x272423(_0x220c35,_0x312223);else{const _0x117137=_0x29f498[_0x2b5f11(0x546)](_0x212f7f,_0x2b5f11(0x1e2));try{_0x54d51e[_0x2b5f11(0x24e)](_0x117137,String(process[_0x2b5f11(0x401)]));}catch{}const _0x10ebe4=Date[_0x2b5f11(0x6f1)]()-_0x12fe86;console[_0x2b5f11(0x219)](''),console[_0x2b5f11(0x219)](_0x2b5f11(0x208)),console['log'](_0x2b5f11(0x4bd)+_0x312223[_0x2b5f11(0x64d)]),console[_0x2b5f11(0x219)](_0x2b5f11(0x43a)+_0x212f7f),console[_0x2b5f11(0x219)]('\x20\x20\x20\x20id:\x20\x20\x20\x20'+_0x220c35['id']);{const _0x313cd5=_0x220c35[_0x2b5f11(0x600)]?.['db']?.['get']?.(_0x2b5f11(0x3a7))??0x0,_0x57b82d=[..._0x220c35[_0x2b5f11(0x319)][_0x2b5f11(0x449)]()]['filter'](_0x284154=>!_0x284154[_0x2b5f11(0x557)]('~'))[_0x2b5f11(0x2e8)];if(_0x220c35[_0x2b5f11(0x21c)]?.[_0x2b5f11(0x351)]?.[_0x2b5f11(0x6d3)]===0x1){const _0xbdcac0=Math[_0x2b5f11(0x44d)]((_0x220c35['_license'][_0x2b5f11(0x351)][_0x2b5f11(0x738)]-Date[_0x2b5f11(0x6f1)]())/0x5265c00);console[_0x2b5f11(0x219)](_0x2b5f11(0x5de)+_0x220c35[_0x2b5f11(0x21c)][_0x2b5f11(0x351)]['licensee']+_0x2b5f11(0x429)+_0xbdcac0+_0x2b5f11(0x40b));}else{if(_0x220c35['_license']?.['active']){const _0x59e215=_0x220c35[_0x2b5f11(0x21c)][_0x2b5f11(0x351)];console[_0x2b5f11(0x219)]('\x20\x20\x20\x20license:\x20'+_0x59e215['licensee']+_0x2b5f11(0x4b2)+new Date(_0x59e215[_0x2b5f11(0x738)])[_0x2b5f11(0x165)]()[_0x2b5f11(0x762)](0x0,0xa)+')');const _0x755c9a=_0x59e215['limits']||{};if(_0x755c9a[_0x2b5f11(0x47c)]){const _0x267ba0=Math[_0x2b5f11(0x38d)](_0x313cd5/_0x755c9a[_0x2b5f11(0x47c)]*0x64);console[_0x2b5f11(0x219)](_0x2b5f11(0x50b)+_0x313cd5[_0x2b5f11(0x671)]()+_0x2b5f11(0x3e9)+_0x755c9a[_0x2b5f11(0x47c)][_0x2b5f11(0x671)]()+_0x2b5f11(0x116)+_0x267ba0+_0x2b5f11(0x5a5)+_0x57b82d+(_0x755c9a[_0x2b5f11(0xb1)]?'/'+_0x755c9a['envs']:'')+'\x20env'+(_0x57b82d===0x1?'':'s'));}}else{if(_0x220c35[_0x2b5f11(0x21c)]){const _0xf048fb=_0x220c35[_0x2b5f11(0x21c)][_0x2b5f11(0x490)](),_0x23d7f7=_0xf048fb[_0x2b5f11(0x2e8)]?_0xf048fb['map'](_0x531e49=>_0x531e49[_0x2b5f11(0xea)])[_0x2b5f11(0x546)](',\x20'):_0x2b5f11(0x3e6),_0x419d6e=_0x220c35[_0x2b5f11(0x21c)][_0x2b5f11(0x737)],_0xc7b609=_0x419d6e[_0x2b5f11(0x194)]['maxWrites']?Math[_0x2b5f11(0x38d)](_0x313cd5/_0x419d6e['limits'][_0x2b5f11(0x47c)]*0x64):0x0;console[_0x2b5f11(0x219)]('\x20\x20\x20\x20license:\x20free\x20tier\x20—\x20add\x20a\x20license\x20to\x20unlock\x20sync,\x20embeddings,\x20engines,\x20time-machine'),console['log']('\x20\x20\x20\x20usage:\x20\x20\x20'+_0x313cd5[_0x2b5f11(0x671)]()+_0x2b5f11(0x3e9)+_0x419d6e[_0x2b5f11(0x194)][_0x2b5f11(0x47c)]['toLocaleString']()+_0x2b5f11(0x116)+_0xc7b609+_0x2b5f11(0x5a5)+_0x57b82d+_0x2b5f11(0x3e9)+_0x419d6e[_0x2b5f11(0x194)][_0x2b5f11(0xb1)]+_0x2b5f11(0x4dc)),console[_0x2b5f11(0x219)](_0x2b5f11(0x410)+_0x23d7f7);}}}}console[_0x2b5f11(0x219)](_0x2b5f11(0x559)+_0x312223['port']+'/api');!_0x312223[_0x2b5f11(0x733)]&&console['log'](_0x2b5f11(0xdd)+_0x312223['port']+_0x2b5f11(0x62c));console['log'](''),console['log'](_0x2b5f11(0x5c1)+_0x10ebe4+'ms'),_0x280b5a(_0x220c35[_0x2b5f11(0x9f)]?.[_0x2b5f11(0x6d4)]?.()??[]);let _0x33a73b=![];async function _0x178b3c(_0x5a0e92){const _0x20976c=_0x2b5f11;_0x33a73b&&(process[_0x20976c(0x544)][_0x20976c(0xc6)](_0x20976c(0x66d)),process[_0x20976c(0x2e9)](0x82));_0x33a73b=!![],process[_0x20976c(0x544)][_0x20976c(0xc6)](_0x20976c(0x20d)+(_0x5a0e92||_0x20976c(0x521))+',\x20closing…\x0a');const _0x5c64cd=setTimeout(()=>{const _0x46dce1=_0x20976c;process[_0x46dce1(0x544)][_0x46dce1(0xc6)](_0x46dce1(0xe1)),process[_0x46dce1(0x2e9)](0x1);},0x1388);try{_0x54d51e[_0x20976c(0x79)](_0x117137);}catch{}try{await _0x220c35[_0x20976c(0x57b)]();}catch(_0xdcbea5){process[_0x20976c(0x544)]['write'](_0x20976c(0x1eb)+(_0xdcbea5?.[_0x20976c(0x71d)]??_0xdcbea5)+'\x0a');}clearTimeout(_0x5c64cd),process[_0x20976c(0x544)][_0x20976c(0xc6)](_0x20976c(0x205)),process[_0x20976c(0x2e9)](0x0);}process['on'](_0x2b5f11(0x2ea),()=>_0x178b3c('SIGINT')),process['on'](_0x2b5f11(0x9b),()=>_0x178b3c(_0x2b5f11(0x9b))),process['on'](_0x2b5f11(0x5a0),()=>_0x178b3c(_0x2b5f11(0x5a0)));}}const _0x31ef1f=new Set([_0x1ced24(0x512),_0x1ced24(0x682),_0x1ced24(0x2fd),_0x1ced24(0xe0),'restore',_0x1ced24(0x4e2),_0x1ced24(0x67d),_0x1ced24(0x34e),'token',_0x1ced24(0x546),_0x1ced24(0xb2)]),_0x3bffc5=process[_0x1ced24(0x19b)][0x2];if(_0x3bffc5==='version')console[_0x1ced24(0x219)](require$$3[_0x1ced24(0x512)]),process[_0x1ced24(0x2e9)](0x0);else{if(_0x3bffc5===_0x1ced24(0x749))process[_0x1ced24(0x2e9)](requireOkdbShmGc()[_0x1ced24(0x5e9)](process[_0x1ced24(0x19b)][_0x1ced24(0x762)](0x3)));else{if(_0x3bffc5&&_0x31ef1f[_0x1ced24(0x783)](_0x3bffc5)){const _0x17aaa3=process['argv'][_0x1ced24(0x762)](0x3),_0x2530cb=_0x5bba9e([_0x1ced24(0x3fc),_0x1ced24(0x1ea),..._0x17aaa3]),_0x334c8b=_0x1e64b7(_0x2530cb),_0x33c2ed=new Set([_0x1ced24(0x261),'-d','--key','-k',_0x1ced24(0x541),'-c',_0x1ced24(0x320),'-p',_0x1ced24(0x465),_0x1ced24(0x284),'-e',_0x1ced24(0x253),_0x1ced24(0x44f),'--password',_0x1ced24(0x604),'--permissions',_0x1ced24(0x24b),_0x1ced24(0x4ed),_0x1ced24(0x4d0),_0x1ced24(0x327),'-u',_0x1ced24(0x3cc)]);let _0xac52b2=null;for(let _0xbf9342=0x0;_0xbf9342<_0x17aaa3[_0x1ced24(0x2e8)];_0xbf9342++){if(_0x33c2ed[_0x1ced24(0x783)](_0x17aaa3[_0xbf9342])){_0xbf9342++;continue;}if(!_0x17aaa3[_0xbf9342][_0x1ced24(0x557)]('-')){_0xac52b2=_0x17aaa3[_0xbf9342];break;}}(async()=>{const _0x4ec2e0=_0x1ced24;if(_0x3bffc5==='token'){const _0x419885=process[_0x4ec2e0(0x19b)][0x3],_0x565ce0=process[_0x4ec2e0(0x19b)]['slice'](0x4),_0x1bfc42=_0x5bba9e(['node','okdb',..._0x565ce0]),_0x1113d9=_0x1e64b7(_0x1bfc42),_0x354df2=new Set([_0x4ec2e0(0x261),'-d',_0x4ec2e0(0x195),'-k',_0x4ec2e0(0x541),'-c',_0x4ec2e0(0x320),'-p',_0x4ec2e0(0x44f),'--password',_0x4ec2e0(0x604),_0x4ec2e0(0x3a9),_0x4ec2e0(0x24b),'--ttl','--log-level',_0x4ec2e0(0x284),'-e',_0x4ec2e0(0x253)]),_0x4110bf=[];for(let _0x262c61=0x0;_0x262c61<_0x565ce0[_0x4ec2e0(0x2e8)];_0x262c61++){if(_0x354df2[_0x4ec2e0(0x783)](_0x565ce0[_0x262c61])){_0x262c61++;continue;}if(_0x565ce0[_0x262c61][_0x4ec2e0(0x557)]('-'))continue;_0x4110bf[_0x4ec2e0(0x1c2)](_0x565ce0[_0x262c61]);}switch(_0x419885){case _0x4ec2e0(0x767):await _0x5c5a2b(_0x1113d9,_0x1bfc42);break;case'list':await _0x41ba90(_0x1113d9);break;case _0x4ec2e0(0x443):await _0x41d019(_0x4110bf[0x0],_0x1113d9);break;default:console[_0x4ec2e0(0x1da)]('[okdb]\x20unknown\x20token\x20action:\x20\x22'+_0x419885+_0x4ec2e0(0x59a)),process[_0x4ec2e0(0x2e9)](0x1);}return;}if(_0x3bffc5===_0x4ec2e0(0xb2)){const _0x2ac62c=requireOkdbLicenseCodec(),_0x305633=process[_0x4ec2e0(0x19b)]['slice'](0x3),_0x5ef75d=_0x5bba9e([_0x4ec2e0(0x3fc),'okdb',..._0x305633]),_0x3c54ca=_0x1e64b7(_0x5ef75d),_0x28ab22=new Set([_0x4ec2e0(0x261),'-d',_0x4ec2e0(0x195),'-k','--config','-c',_0x4ec2e0(0x320),'-p',_0x4ec2e0(0x465)]),_0x2812cf=[];for(let _0x4a9e65=0x0;_0x4a9e65<_0x305633[_0x4ec2e0(0x2e8)];_0x4a9e65++){if(_0x28ab22['has'](_0x305633[_0x4a9e65])){_0x4a9e65++;continue;}if(_0x305633[_0x4a9e65][_0x4ec2e0(0x557)]('-'))continue;_0x2812cf['push'](_0x305633[_0x4a9e65]);}const _0x3f7417=_0x2812cf[0x0]??null;if(_0x3f7417===_0x4ec2e0(0x5ce))await _0x18ec14(_0x2812cf[0x1],_0x3c54ca);else{if(!_0x3f7417)await _0x4c0c3d(_0x3c54ca);else{let _0x494aef=_0x2ac62c[_0x4ec2e0(0x2ec)](_0x3f7417);if(_0x494aef===_0x4ec2e0(0x5f1)&&_0x54d51e[_0x4ec2e0(0x26e)](_0x3f7417))_0x494aef=_0x4ec2e0(0x2cc);if(_0x494aef==='path')try{const _0x268a13=_0x54d51e[_0x4ec2e0(0x20c)](_0x3f7417,_0x4ec2e0(0x84))[_0x4ec2e0(0x220)](),_0x55b1f9=_0x2ac62c[_0x4ec2e0(0x2ec)](_0x268a13);if(_0x55b1f9===_0x4ec2e0(0x7e)){await _0x5ece99(_0x268a13,_0x3c54ca);return;}await _0xf1aa66(_0x3f7417,_0x3c54ca);return;}catch(_0x2452e8){console['error'](_0x4ec2e0(0x479)+_0x3f7417+':\x20'+_0x2452e8['message']),process[_0x4ec2e0(0x2e9)](0x1);}switch(_0x494aef){case _0x4ec2e0(0x409):await _0xf1aa66(_0x3f7417,_0x3c54ca);break;case _0x4ec2e0(0x7e):await _0x5ece99(_0x3f7417,_0x3c54ca);break;case'uuid':await _0x2e5f10(_0x3f7417,_0x3c54ca);break;default:console['error'](_0x4ec2e0(0x87)+_0x3f7417+'\x22'),console['error'](''),console[_0x4ec2e0(0x1da)](_0x4ec2e0(0x37b)),console[_0x4ec2e0(0x1da)](_0x4ec2e0(0x2e4)),console['error'](_0x4ec2e0(0x538)),console[_0x4ec2e0(0x1da)](_0x4ec2e0(0x12c)),console['error'](_0x4ec2e0(0x125)),console[_0x4ec2e0(0x1da)](''),console[_0x4ec2e0(0x1da)](_0x4ec2e0(0x3d9)),process[_0x4ec2e0(0x2e9)](0x1);}}}return;}switch(_0x3bffc5){case _0x4ec2e0(0x682):await _0x2ae6e6(_0x334c8b);break;case'init':await _0x2c2811();break;case _0x4ec2e0(0x34e):await _0x83fca9(_0x334c8b);break;case'backup':await _0x1f25b5(_0xac52b2??_0x29f498[_0x4ec2e0(0x395)](_0x4ec2e0(0x29d)),_0x334c8b);break;case _0x4ec2e0(0x5e7):if(!_0xac52b2)throw new Error(_0x4ec2e0(0x381));await _0x43e78a(_0x29f498['resolve'](_0xac52b2),_0x334c8b,_0x2530cb);break;case _0x4ec2e0(0x4e2):await _0x5e97b4(_0xac52b2??_0x29f498[_0x4ec2e0(0x395)](_0x4ec2e0(0x50d)),_0x334c8b,_0x2530cb);break;case _0x4ec2e0(0x67d):await _0x1ee4a5(_0xac52b2??_0x29f498[_0x4ec2e0(0x395)](_0x4ec2e0(0x50d)),_0x334c8b,_0x2530cb);break;case _0x4ec2e0(0x546):await _0x4d6418(_0xac52b2,_0x334c8b,_0x2530cb);break;}})()[_0x1ced24(0x257)](()=>process[_0x1ced24(0x2e9)](0x0))[_0x1ced24(0x31d)](_0x5210bd=>{const _0x1c9e96=_0x1ced24;console[_0x1c9e96(0x1da)](_0x1c9e96(0x27c)+(_0x5210bd['message']||_0x5210bd)+'\x0a'),process['exit'](0x1);});}else _0x14f948()[_0x1ced24(0x31d)](_0x210da8=>{const _0x58e723=_0x1ced24;console[_0x58e723(0x1da)](_0x58e723(0x278)),console[_0x58e723(0x1da)](_0x210da8[_0x58e723(0x644)]||_0x210da8),process[_0x58e723(0x2e9)](0x1);});}}return okdb$1;}var okdbExports=requireOkdb(),okdb=getDefaultExportFromCjs(okdbExports);module[_0x1cb9ed(0x761)]=okdb;
|