@hotmeshio/hotmesh
Version:
Serverless Workflow
1 lines • 3.49 kB
JavaScript
'use strict';const j=b;(function(c,d){const i=b,e=c();while(!![]){try{const f=parseInt(i(0x141))/0x1*(-parseInt(i(0x153))/0x2)+parseInt(i(0x15d))/0x3+parseInt(i(0x14c))/0x4*(parseInt(i(0x144))/0x5)+parseInt(i(0x14b))/0x6*(parseInt(i(0x14e))/0x7)+-parseInt(i(0x136))/0x8*(-parseInt(i(0x142))/0x9)+-parseInt(i(0x15c))/0xa*(-parseInt(i(0x15f))/0xb)+parseInt(i(0x161))/0xc*(-parseInt(i(0x155))/0xd);if(f===d)break;else e['push'](e['shift']());}catch(g){e['push'](e['shift']());}}}(a,0xacde5));function b(c,d){const e=a();return b=function(f,g){f=f-0x136;let h=e[f];return h;},b(c,d);}function a(){const v=['6anyGPX','setFields','13kwJHpP','searchClient','__esModule','transact','../../index','logger','pgClient','195080WqTXji','259623TTYSmv','defineProperty','759wntsWh','hget','34858500VdeRAY','14848ueSSon','postgres-increment-field-error','PostgresSearchService','../../../store/providers/postgres/kvsql','sendIndexedQuery','appId','createSearchIndex','SearchService','incrementFieldByFloat','init','postgres-send-query-error','56466sDWyBo','4986XHflHf','postgres-search-get-fields-error','50MizahN','namespace','listSearchIndexes','KVSQL','postgres-send-indexed-query-error','getFields','hdel','78vCkzzM','523436IMpUNq','query','6965sLzuFL','length','hgetall','error','rows'];a=function(){return v;};return a();}Object[j(0x15e)](exports,j(0x157),{'value':!0x0}),exports[j(0x138)]=void 0x0;const index_1=require(j(0x159)),kvsql_1=require(j(0x139));class PostgresSearchService extends index_1[j(0x13d)]{[j(0x158)](){const k=j;return this['storeClient'][k(0x158)]();}constructor(c,d){const l=j;super(c,d),this[l(0x15b)]=c,this[l(0x156)]=new kvsql_1[(l(0x147))](c,this[l(0x145)],this['appId']);}async[j(0x13f)](c,d,f){const m=j;this[m(0x156)]['namespace']=this['namespace']=c,this[m(0x156)][m(0x13b)]=this[m(0x13b)]=d,this['namespace']=c,this[m(0x13b)]=d,this[m(0x15a)]=f;}async[j(0x13c)](c,d,f){}async[j(0x146)](){return[];}async[j(0x154)](c,d){const n=j;try{const f=await this['searchClient']['hset'](c,d);return Number(f);}catch(g){throw this[n(0x15a)][n(0x151)]('postgres-search-set-fields-error',{'key':c,'error':g}),g;}}async['getField'](c,d){const o=j;try{return await this[o(0x156)][o(0x160)](c,d);}catch(f){throw this[o(0x15a)]['error']('postgres-search-get-field-error',{'key':c,'field':d,'error':f}),f;}}async[j(0x149)](c,d){const p=j;try{return await this[p(0x156)]['hmget'](c,[...d]);}catch(f){throw this[p(0x15a)][p(0x151)](p(0x143),{'key':c,'fields':d,'error':f}),f;}}async['getAllFields'](c){const q=j;try{return await this[q(0x156)][q(0x150)](c);}catch(d){throw this[q(0x15a)][q(0x151)]('postgres-search-get-all-fields-error',{'key':c,'error':d}),d;}}async['deleteFields'](c,d){const r=j;try{const f=await this['searchClient'][r(0x14a)](c,d);return Number(f);}catch(g){throw this[r(0x15a)][r(0x151)]('postgres-search-delete-fields-error',{'key':c,'fields':d,'error':g}),g;}}async[j(0x13e)](c,d,f){const s=j;try{const g=await this[s(0x156)]['hincrbyfloat'](c,d,f);return Number(g);}catch(h){throw this[s(0x15a)][s(0x151)](s(0x137),{'key':c,'field':d,'error':h}),h;}}async['sendQuery'](c){const t=j;try{return await this[t(0x15b)]['query'](c);}catch(d){throw this[t(0x15a)][t(0x151)](t(0x140),{'query':c,'error':d}),d;}}async[j(0x13a)](c,d=[]){const u=j,[f,...g]=d;try{return(await this[u(0x15b)][u(0x14d)](f,g[u(0x14f)]?g:void 0x0))[u(0x152)];}catch(h){throw this[u(0x15a)][u(0x151)](u(0x148),{'query':f,'error':h}),h;}}}exports['PostgresSearchService']=PostgresSearchService;