@kedem/okdb 3.0.0 → 3.1.0
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 +114 -3
- package/README.md +72 -36
- package/bin/okdb +1 -1
- package/docs/auth-and-sync.md +30 -24
- package/docs/auth-permissions.md +5 -4
- package/docs/c-bridge.md +94 -0
- package/docs/change-log.md +79 -36
- package/docs/data-model.md +35 -9
- package/docs/deployment.md +42 -38
- package/docs/diagnostics.md +61 -125
- package/docs/embeddings.md +143 -51
- package/docs/encryption.md +132 -0
- package/docs/files.md +64 -27
- package/docs/fts.md +48 -23
- package/docs/functions.md +109 -56
- package/docs/getting-started.md +121 -9
- package/docs/http-api.md +66 -11
- package/docs/http-cluster.md +80 -88
- package/docs/index.md +33 -15
- package/docs/indexes.md +53 -17
- package/docs/licensing.md +19 -5
- package/docs/logging.md +11 -22
- package/docs/manifest.json +6 -3
- package/docs/migration.md +41 -16
- package/docs/pipelines.md +111 -46
- package/docs/plugins.md +47 -15
- package/docs/process-registry.md +23 -24
- package/docs/processors.md +26 -23
- package/docs/querying.md +102 -29
- package/docs/queue.md +165 -51
- package/docs/resolved-fields.md +24 -1
- package/docs/subscriptions.md +4 -4
- package/docs/sync.md +9 -6
- package/docs/time-machine.md +52 -14
- package/docs/transactions.md +63 -15
- package/docs/ttl.md +34 -13
- package/docs/upgrade-2.0.md +32 -15
- package/docs/upgrade-2.1.md +10 -12
- package/docs/upgrade-3.0.md +144 -0
- package/docs/views.md +165 -61
- package/index.js +1 -1
- package/native/linux-x64-gnu/okdb +0 -0
- package/native/linux-x64-gnu/okdb-node.linux-x64-gnu.node +0 -0
- package/native-loader.js +1 -1
- package/okdb-native.js +1 -1
- package/package.json +1 -1
- package/public/features/files/parts/files-blob-status.ok.js +1 -1
- package/types/environment.d.ts +32 -11
- package/types/errors.d.ts +20 -0
- package/types/features/admin.d.ts +3 -5
- package/types/features/api.d.ts +5 -7
- package/types/features/embeddings.d.ts +8 -7
- package/types/features/engines.d.ts +9 -1
- package/types/features/files.d.ts +2 -1
- package/types/features/fts.d.ts +3 -3
- package/types/features/functions.d.ts +14 -8
- package/types/features/pipelines.d.ts +10 -10
- package/types/features/queue.d.ts +15 -10
- package/types/features/sync.d.ts +7 -0
- package/types/features/time-machine.d.ts +3 -0
- package/types/index.d.ts +3 -0
- package/types/okdb.d.ts +70 -7
- package/types/options.d.ts +12 -8
- package/docs/OKDB-ARCHITECTURE.md +0 -1061
package/index.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
'use strict';const
|
|
1
|
+
'use strict';const _0x5f4eba=_0x2399;(function(_0x520d35,_0x331dda){const _0x55c99c=_0x2399,_0x15fd9c=_0x520d35();while(!![]){try{const _0x2513f4=-parseInt(_0x55c99c(0xff))/0x1+-parseInt(_0x55c99c(0xf3))/0x2*(parseInt(_0x55c99c(0x106))/0x3)+-parseInt(_0x55c99c(0x116))/0x4+parseInt(_0x55c99c(0x108))/0x5*(parseInt(_0x55c99c(0xf4))/0x6)+-parseInt(_0x55c99c(0x10d))/0x7+-parseInt(_0x55c99c(0xfc))/0x8+parseInt(_0x55c99c(0x10a))/0x9;if(_0x2513f4===_0x331dda)break;else _0x15fd9c['push'](_0x15fd9c['shift']());}catch(_0x196a19){_0x15fd9c['push'](_0x15fd9c['shift']());}}}(_0x2ca6,0x9f1b8));function _0x2399(_0x5d66ca,_0x17d434){_0x5d66ca=_0x5d66ca-0xf2;const _0x2ca6ac=_0x2ca6();let _0x239987=_0x2ca6ac[_0x5d66ca];return _0x239987;}const loader=require(_0x5f4eba(0x105)),p=loader[_0x5f4eba(0xf7)]();if(!p['ok']){const e=new Error(p[_0x5f4eba(0x10b)]?_0x5f4eba(0x110)+p[_0x5f4eba(0x109)]+_0x5f4eba(0xf5)+_0x5f4eba(0x117):_0x5f4eba(0x110)+p[_0x5f4eba(0x109)]+_0x5f4eba(0x113)+_0x5f4eba(0x10e));e[_0x5f4eba(0xfa)]=_0x5f4eba(0x10c);if(p['error'])e['cause']=p[_0x5f4eba(0xf9)];throw e;}if(process.env.OKDB_NATIVE_DEBUG)process[_0x5f4eba(0x100)][_0x5f4eba(0x107)]('[okdb]\x20native\x20core:\x20'+p[_0x5f4eba(0x10f)]+'\x20('+p[_0x5f4eba(0x115)]+')\x20'+p[_0x5f4eba(0xfe)]+'\x0a');{const path=require(_0x5f4eba(0x114)),fs=require('node:fs');for(const [k,rel]of[[_0x5f4eba(0xf2),_0x5f4eba(0xfb)],[_0x5f4eba(0xf8),'docs']]){const d=path[_0x5f4eba(0x111)](__dirname,rel);if(!process.env[k]&&fs['existsSync'](d))process.env[k]=d;}}function _0x2ca6(){const _0x2e637b=['key','okdb:\x20the\x20native\x20core\x20is\x20unavailable\x20—\x20','join','call','.\x20Reinstall\x20@kedem/okdb\x20(the\x20addon\x20ships\x20inside\x20the\x20package\x20under\x20','node:path','source','4706500TZkguR','(glibc),\x20or\x20stay\x20on\x20okdb\x202.x\x20on\x20this\x20platform.\x20OKDB_NATIVE_BINARY=<okdb-node\x20.node>\x20loads\x20a\x20build\x20you\x20made\x20yourself.','OKDB_ADMIN_PUBLIC_DIR','4EzIbHe','7459566cJNrAy','.\x20okdb\x203.x\x20has\x20no\x20JavaScript\x20fallback:\x20run\x20it\x20on\x20Linux\x20x64\x20','native','probe','OKDB_DOCS_DIR','error','code','public','463528QWgrWO','defineProperty','path','1196929DZmxFx','stderr','exports','nativeBinaryPath','./okdb-native.js','hasOwnProperty','./native-loader.js','907716dsEWuq','write','5wxltyv','reason','24137595MrCQxB','unsupported','NATIVE_UNAVAILABLE','1658111srmvBw','native/),\x20or\x20set\x20OKDB_NATIVE_BINARY\x20to\x20an\x20okdb-node\x20.node\x20file.'];_0x2ca6=function(){return _0x2e637b;};return _0x2ca6();}const OKDB=require(_0x5f4eba(0x103));module[_0x5f4eba(0x101)]=OKDB,Object[_0x5f4eba(0xfd)](OKDB,'implementation',{'value':_0x5f4eba(0xf6),'enumerable':![],'configurable':!![]});if(!Object['prototype'][_0x5f4eba(0x104)][_0x5f4eba(0x112)](OKDB,_0x5f4eba(0x102)))Object[_0x5f4eba(0xfd)](OKDB,'nativeBinaryPath',{'value':p[_0x5f4eba(0xfe)],'enumerable':![],'configurable':!![]});
|
|
Binary file
|
|
Binary file
|
package/native-loader.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
'use strict';const
|
|
1
|
+
'use strict';const _0xc25bbd=_0x41a4;(function(_0x557a30,_0x343a2e){const _0x575620=_0x41a4,_0x398eee=_0x557a30();while(!![]){try{const _0x59db9f=-parseInt(_0x575620(0xec))/0x1+-parseInt(_0x575620(0xb3))/0x2+parseInt(_0x575620(0xd2))/0x3+parseInt(_0x575620(0xd0))/0x4+-parseInt(_0x575620(0xd6))/0x5*(-parseInt(_0x575620(0xc3))/0x6)+-parseInt(_0x575620(0xef))/0x7+-parseInt(_0x575620(0xbd))/0x8*(parseInt(_0x575620(0xb4))/0x9);if(_0x59db9f===_0x343a2e)break;else _0x398eee['push'](_0x398eee['shift']());}catch(_0x152cdf){_0x398eee['push'](_0x398eee['shift']());}}}(_0x3b33,0x736da));const fs=require('node:fs'),path=require(_0xc25bbd(0xdd)),SCOPE=_0xc25bbd(0xe5),PREFIX=_0xc25bbd(0xcf),BUNDLED_DIR=_0xc25bbd(0xcf),KEYS=[_0xc25bbd(0xbc),_0xc25bbd(0xce),'linux-x64-musl',_0xc25bbd(0xab)];function isMusl(){const _0x1337a9=_0xc25bbd;try{const _0x104fd8=process['report']&&process[_0x1337a9(0xd4)]['getReport']&&process['report'][_0x1337a9(0xb8)]();if(_0x104fd8&&_0x104fd8['header'])return!_0x104fd8['header'][_0x1337a9(0xc8)];}catch{}try{return fs[_0x1337a9(0xd3)](_0x1337a9(0xd9),_0x1337a9(0xeb))[_0x1337a9(0xb1)](_0x1337a9(0xe4));}catch{}try{return require(_0x1337a9(0xc0))[_0x1337a9(0xc5)](_0x1337a9(0xb9),{'encoding':_0x1337a9(0xeb)})['includes'](_0x1337a9(0xe4));}catch{return![];}}function host(){const _0x3ce539=_0xc25bbd,_0x24bf3e=process.env.OKDB_NATIVE_PLATFORM;if(_0x24bf3e){const [_0x9d38f5,_0x165682,_0x5d0b4a]=_0x24bf3e['split']('-');return{'platform':_0x9d38f5,'arch':_0x165682,'libc':_0x9d38f5===_0x3ce539(0xbf)?_0x5d0b4a==='musl'?_0x3ce539(0xe4):'glibc':null};}const _0x2e04f0=process[_0x3ce539(0xdf)];return{'platform':_0x2e04f0,'arch':process['arch'],'libc':_0x2e04f0===_0x3ce539(0xbf)?isMusl()?_0x3ce539(0xe4):_0x3ce539(0xa9):null};}function _0x41a4(_0x274e74,_0x539589){_0x274e74=_0x274e74-0xa8;const _0x3b3331=_0x3b33();let _0x41a4b6=_0x3b3331[_0x274e74];return _0x41a4b6;}function describeHost(){const _0x1e481a=_0xc25bbd,_0x55b924=host();return[_0x55b924[_0x1e481a(0xdf)],_0x55b924[_0x1e481a(0xb6)],_0x55b924[_0x1e481a(0xb2)]][_0x1e481a(0xb7)](Boolean)[_0x1e481a(0xf0)]('/');}function platformKey(){const _0x2caa3f=_0xc25bbd,_0x2828e5=host();if(_0x2828e5[_0x2caa3f(0xdf)]!==_0x2caa3f(0xbf))return null;const _0x46e975=_0x2828e5[_0x2caa3f(0xb6)]==='x64'?_0x2caa3f(0xaf):_0x2828e5[_0x2caa3f(0xb6)]==='arm64'?_0x2caa3f(0xba):null;if(!_0x46e975)return null;return _0x2caa3f(0xc9)+_0x46e975+'-'+(_0x2828e5[_0x2caa3f(0xb2)]===_0x2caa3f(0xe4)?'musl':'gnu');}function packageName(_0x6cd3cc){return SCOPE+'/'+PREFIX+'-'+_0x6cd3cc;}function bundledKeys(){const _0x9722f7=_0xc25bbd;try{return fs[_0x9722f7(0xca)](path[_0x9722f7(0xf0)](__dirname,BUNDLED_DIR))['filter'](_0x314b4b=>fs[_0x9722f7(0xaa)](path[_0x9722f7(0xf0)](__dirname,BUNDLED_DIR,_0x314b4b,_0x9722f7(0xae)+_0x314b4b+_0x9722f7(0xbe))))['sort']();}catch{return[];}}function bundledPath(_0x2187ca,_0x29191f){const _0x1c7441=_0xc25bbd;if(_0x29191f==='cli')_0x29191f=_0x1c7441(0xcc);return path[_0x1c7441(0xf0)](__dirname,BUNDLED_DIR,_0x2187ca,_0x29191f==='addon'?'okdb-node.'+_0x2187ca+_0x1c7441(0xbe):_0x1c7441(0xc6));}function fromPackage(_0x763f50,_0x8be564){const _0x52a0bf=_0xc25bbd;let _0x69c545;try{_0x69c545=require['resolve'](packageName(_0x763f50)+_0x52a0bf(0xc1),{'paths':[__dirname]});}catch{return null;}const _0x157c3b=path[_0x52a0bf(0xf0)](path[_0x52a0bf(0xe1)](_0x69c545),_0x8be564);return fs['existsSync'](_0x157c3b)?{'path':_0x157c3b}:{'installed':!![]};}function unsupported(){const _0x45da6b=_0xc25bbd,_0x10a045=bundledKeys();return _0x45da6b(0xdc)+describeHost()+':\x20okdb\x203.0\x20ships\x20Linux\x20x64\x20(glibc)\x20only'+(_0x45da6b(0xd7)+(_0x10a045['length']?_0x10a045[_0x45da6b(0xf0)](',\x20'):_0x45da6b(0xc7))+')');}function locate(_0x34baf1){const _0x35fdae=_0xc25bbd;if(_0x34baf1===_0x35fdae(0xa8))_0x34baf1='launcher';const _0x36022e=platformKey(),_0x4e68de=_0x34baf1===_0x35fdae(0xbb)?process.env.OKDB_NATIVE_BINARY:process.env.OKDB_NATIVE_CLI;if(_0x4e68de)return fs[_0x35fdae(0xaa)](_0x4e68de)?{'path':_0x4e68de,'key':_0x36022e,'source':_0x35fdae(0xe8)}:{'path':null,'key':_0x36022e,'reason':(_0x34baf1===_0x35fdae(0xbb)?_0x35fdae(0xd8):'OKDB_NATIVE_CLI')+_0x35fdae(0xe3)+_0x4e68de};if(!_0x36022e)return{'path':null,'key':_0x36022e,'unsupported':!![],'reason':unsupported()};const _0x2c616e=bundledPath(_0x36022e,_0x34baf1);if(fs[_0x35fdae(0xaa)](_0x2c616e))return{'path':_0x2c616e,'key':_0x36022e,'source':_0x35fdae(0xb5)};const _0x43c3ad=_0x34baf1==='addon'?'okdb-node.'+_0x36022e+_0x35fdae(0xbe):path[_0x35fdae(0xf0)](_0x35fdae(0xcd),_0x35fdae(0xc6)),_0x4992ee=fromPackage(_0x36022e,_0x43c3ad);if(_0x4992ee&&_0x4992ee['path'])return{'path':_0x4992ee[_0x35fdae(0xd1)],'key':_0x36022e,'source':_0x35fdae(0xee)};if(_0x4992ee)return{'path':null,'key':_0x36022e,'reason':packageName(_0x36022e)+_0x35fdae(0xcb)+_0x43c3ad[_0x35fdae(0xe6)](/\\/g,'/')+_0x35fdae(0xb0)};if(bundledKeys()[_0x35fdae(0xb1)](_0x36022e))return{'path':null,'key':_0x36022e,'reason':_0x35fdae(0xf1)+path[_0x35fdae(0xc2)](__dirname,_0x2c616e)[_0x35fdae(0xe6)](/\\/g,'/')+_0x35fdae(0xac)+_0x34baf1+')'};return{'path':null,'key':_0x36022e,'unsupported':!![],'reason':unsupported()};}let cached=null;function probe(){const _0x2c3e5c=_0xc25bbd;if(cached)return cached;const _0x53e066=locate('addon');if(!_0x53e066[_0x2c3e5c(0xd1)])return cached={'ok':![],'reason':_0x53e066[_0x2c3e5c(0xe9)],'unsupported':!!_0x53e066[_0x2c3e5c(0xed)]};try{const _0x30b830=require(_0x53e066['path']),_0xda081d=typeof _0x30b830[_0x2c3e5c(0xe0)]===_0x2c3e5c(0xdb)?_0x30b830['bindingVersion']():null;return cached={'ok':!![],'mod':_0x30b830,'path':_0x53e066[_0x2c3e5c(0xd1)],'key':_0x53e066[_0x2c3e5c(0xe2)],'source':_0x53e066['source'],'bindingVersion':_0xda081d};}catch(_0x2906c2){return cached={'ok':![],'reason':'loading\x20'+_0x53e066[_0x2c3e5c(0xd1)]+_0x2c3e5c(0xde)+(_0x2906c2&&_0x2906c2[_0x2c3e5c(0xad)]),'error':_0x2906c2};}}function load(){const _0x2e5cdd=_0xc25bbd,_0x5da53c=probe();if(_0x5da53c['ok'])return _0x5da53c['mod'];const _0x4199b2=new Error('okdb:\x20native\x20core\x20unavailable\x20—\x20'+_0x5da53c[_0x2e5cdd(0xe9)]);_0x4199b2['code']=_0x2e5cdd(0xe7);if(_0x5da53c['error'])_0x4199b2['cause']=_0x5da53c[_0x2e5cdd(0xc4)];throw _0x4199b2;}function loadedPath(){const _0x4861f6=_0xc25bbd;if(!cached||!cached['ok'])return null;try{return fs[_0x4861f6(0xea)](cached['path']);}catch{return path[_0x4861f6(0xd5)](cached[_0x4861f6(0xd1)]);}}module[_0xc25bbd(0xda)]={'load':load,'loadedPath':loadedPath,'probe':probe,'locate':locate,'platformKey':platformKey,'describeHost':describeHost,'bundledKeys':bundledKeys,'bundledPath':bundledPath,'packageName':packageName,'isMusl':isMusl,'KEYS':KEYS,'BUNDLED_DIR':BUNDLED_DIR};function _0x3b33(){const _0x5efa6b=['\x20is\x20installed\x20but\x20has\x20no\x20','launcher','bin','linux-arm64-gnu','native','2529824rmyOOi','path','423936QOLJyM','readFileSync','report','resolve','4405955lxuhOa','\x20(this\x20package\x20bundles:\x20','OKDB_NATIVE_BINARY','/usr/bin/ldd','exports','function','no\x20native\x20build\x20for\x20','node:path','\x20failed:\x20','platform','bindingVersion','dirname','key','\x20points\x20to\x20a\x20missing\x20file:\x20','musl','@okdb','replace','NATIVE_BINARY_MISSING','env','reason','realpathSync','utf8','768844XhIMEU','unsupported','package','1797852jfxNEM','join','this\x20package\x20has\x20no\x20','cli','glibc','existsSync','linux-arm64-musl','\x20(a\x20build\x20without\x20the\x20','message','okdb-node.','x64','\x20(a\x20build\x20without\x20it)','includes','libc','165044KLsnFH','665667vlfCmh','bundled','arch','filter','getReport','ldd\x20--version\x202>&1\x20||\x20true','arm64','addon','linux-x64-gnu','8IsXJxx','.node','linux','node:child_process','/package.json','relative','6lzpRAb','error','execSync','okdb','nothing','glibcVersionRuntime','linux-','readdirSync'];_0x3b33=function(){return _0x5efa6b;};return _0x3b33();}
|