@anncic-api/cache 1.1.22 → 1.1.24
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.
|
@@ -1 +1 @@
|
|
|
1
|
-
'use strict';const
|
|
1
|
+
'use strict';const a0_0x3a1c12=a0_0x2134;(function(_0x1ae0a4,_0x385222){const _0x44bc13=a0_0x2134,_0x9ff460=_0x1ae0a4();while(!![]){try{const _0x461842=-parseInt(_0x44bc13(0x1fc))/0x1*(parseInt(_0x44bc13(0x1f7))/0x2)+-parseInt(_0x44bc13(0x1ef))/0x3*(parseInt(_0x44bc13(0x1eb))/0x4)+parseInt(_0x44bc13(0x1ed))/0x5*(parseInt(_0x44bc13(0x1f2))/0x6)+-parseInt(_0x44bc13(0x1fd))/0x7*(parseInt(_0x44bc13(0x1f0))/0x8)+parseInt(_0x44bc13(0x1e9))/0x9*(parseInt(_0x44bc13(0x1f6))/0xa)+parseInt(_0x44bc13(0x1f8))/0xb*(-parseInt(_0x44bc13(0x1ec))/0xc)+parseInt(_0x44bc13(0x1f4))/0xd*(parseInt(_0x44bc13(0x1e8))/0xe);if(_0x461842===_0x385222)break;else _0x9ff460['push'](_0x9ff460['shift']());}catch(_0x2cd08){_0x9ff460['push'](_0x9ff460['shift']());}}}(a0_0x2eea,0xa026d));function a0_0x2eea(){const _0xc94e9d=['cache-manager-ioredis','337350KRKxiD','22OgiJZw','2239435bOjpPr','cache-manager-fs-hash','appDir','defineProperty','3607CUEgxF','2523346pXydpT','__esModule','127.0.0.1','10171924wOcEjl','270EvgNnD','memory','2716772BFKgbk','72zKWQAi','5xAGUBS','name','3CuIHgb','8BBbEUa','/runtime/.cache','2949942lsAPZG','file','26IYUdZr'];a0_0x2eea=function(){return _0xc94e9d;};return a0_0x2eea();}function a0_0x2134(_0x295566,_0xd766ed){const _0x2eea27=a0_0x2eea();return a0_0x2134=function(_0x2134c4,_0x8859a6){_0x2134c4=_0x2134c4-0x1e8;let _0xb484d2=_0x2eea27[_0x2134c4];return _0xb484d2;},a0_0x2134(_0x295566,_0xd766ed);}Object[a0_0x3a1c12(0x1fb)](exports,a0_0x3a1c12(0x1fe),{'value':!![]});const fsStore=require(a0_0x3a1c12(0x1f9)),redisStore=require(a0_0x3a1c12(0x1f5));exports['default']=_0x5efe82=>{const _0x3bd830=a0_0x3a1c12;return{'cache':{'default':_0x3bd830(0x1f3),'stores':{'file':{'store':fsStore,'options':{'ttl':0x1e13380,'subdirs':![],'path':_0x5efe82[_0x3bd830(0x1fa)]+_0x3bd830(0x1f1)}},'redis':{'store':redisStore,'options':{'port':0x18eb,'host':_0x3bd830(0x1ff),'password':'','ttl':0x1e13380,'keyPrefix':_0x5efe82[_0x3bd830(0x1ee)]+':'}},'memory':{'store':_0x3bd830(0x1ea),'options':{'max':0x64,'ttl':0x1e13380}}}}};};
|
package/dist/configuration.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
'use strict';var
|
|
1
|
+
'use strict';function a1_0x56aa(_0x3d8c74,_0x1b3804){var _0x3aec98=a1_0x3aec();return a1_0x56aa=function(_0x56aa1f,_0x5f2ea8){_0x56aa1f=_0x56aa1f-0xf1;var _0x303348=_0x3aec98[_0x56aa1f];return _0x303348;},a1_0x56aa(_0x3d8c74,_0x1b3804);}var a1_0x32a235=a1_0x56aa;(function(_0x23abb5,_0x308ce1){var _0x49d22b=a1_0x56aa,_0x4cb03b=_0x23abb5();while(!![]){try{var _0x134b24=parseInt(_0x49d22b(0xff))/0x1+parseInt(_0x49d22b(0xfc))/0x2*(-parseInt(_0x49d22b(0xfa))/0x3)+-parseInt(_0x49d22b(0xf4))/0x4+-parseInt(_0x49d22b(0xfe))/0x5*(-parseInt(_0x49d22b(0xf8))/0x6)+-parseInt(_0x49d22b(0xf3))/0x7+-parseInt(_0x49d22b(0x103))/0x8+parseInt(_0x49d22b(0xf9))/0x9*(parseInt(_0x49d22b(0x106))/0xa);if(_0x134b24===_0x308ce1)break;else _0x4cb03b['push'](_0x4cb03b['shift']());}catch(_0x312cb7){_0x4cb03b['push'](_0x4cb03b['shift']());}}}(a1_0x3aec,0x9ca4f));function a1_0x3aec(){var _0xf31a0c=['anncic-api:cache','2IwUoDI','Configuration','87445EokhCN','705680UnfThR','@midwayjs/decorator','decorate','./config/config.default','1225896odKaob','getOwnPropertyDescriptor','defineProperty','11930azsLfB','length','object','2315705dELpjk','4084432JiHhZi','__decorate','CustomConfiguration','function','180BOIiDg','15678DrJnTR','3485343qjHRSX'];a1_0x3aec=function(){return _0xf31a0c;};return a1_0x3aec();}var __decorate=this&&this[a1_0x32a235(0xf5)]||function(_0x576b01,_0x4bc873,_0x2d6df0,_0x44baa3){var _0x33cef5=a1_0x32a235,_0x2c2ff7=arguments[_0x33cef5(0xf1)],_0x39c77a=_0x2c2ff7<0x3?_0x4bc873:_0x44baa3===null?_0x44baa3=Object[_0x33cef5(0x104)](_0x4bc873,_0x2d6df0):_0x44baa3,_0x23ae90;if(typeof Reflect===_0x33cef5(0xf2)&&typeof Reflect[_0x33cef5(0x101)]===_0x33cef5(0xf7))_0x39c77a=Reflect[_0x33cef5(0x101)](_0x576b01,_0x4bc873,_0x2d6df0,_0x44baa3);else{for(var _0x39f546=_0x576b01[_0x33cef5(0xf1)]-0x1;_0x39f546>=0x0;_0x39f546--)if(_0x23ae90=_0x576b01[_0x39f546])_0x39c77a=(_0x2c2ff7<0x3?_0x23ae90(_0x39c77a):_0x2c2ff7>0x3?_0x23ae90(_0x4bc873,_0x2d6df0,_0x39c77a):_0x23ae90(_0x4bc873,_0x2d6df0))||_0x39c77a;}return _0x2c2ff7>0x3&&_0x39c77a&&Object[_0x33cef5(0x105)](_0x4bc873,_0x2d6df0,_0x39c77a),_0x39c77a;};Object[a1_0x32a235(0x105)](exports,'__esModule',{'value':!![]}),exports[a1_0x32a235(0xf6)]=void 0x0;const decorator_1=require(a1_0x32a235(0x100)),ConfigDefault=require(a1_0x32a235(0x102));let CustomConfiguration=class CustomConfiguration{};CustomConfiguration=__decorate([(0x0,decorator_1[a1_0x32a235(0xfd)])({'conflictCheck':![],'namespace':a1_0x32a235(0xfb),'importConfigs':[{'default':ConfigDefault}]})],CustomConfiguration),exports[a1_0x32a235(0xf6)]=CustomConfiguration;
|
package/dist/decorator/Cache.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
'use strict';const
|
|
1
|
+
'use strict';const a2_0x2449d5=a2_0x2a19;(function(_0x38f548,_0x156b68){const _0x47c379=a2_0x2a19,_0x17684c=_0x38f548();while(!![]){try{const _0xf2c6e9=parseInt(_0x47c379(0x202))/0x1+-parseInt(_0x47c379(0x1f5))/0x2*(parseInt(_0x47c379(0x207))/0x3)+-parseInt(_0x47c379(0x200))/0x4*(-parseInt(_0x47c379(0x1f8))/0x5)+parseInt(_0x47c379(0x1fa))/0x6+parseInt(_0x47c379(0x201))/0x7*(-parseInt(_0x47c379(0x1f6))/0x8)+-parseInt(_0x47c379(0x205))/0x9+parseInt(_0x47c379(0x1fb))/0xa*(-parseInt(_0x47c379(0x204))/0xb);if(_0xf2c6e9===_0x156b68)break;else _0x17684c['push'](_0x17684c['shift']());}catch(_0xdd5e70){_0x17684c['push'](_0x17684c['shift']());}}}(a2_0x9df2,0x18e87));function a2_0x9df2(){const _0x1bcbf4=['apply','773346ZQOUme','20uAJsky','stringify','value','use','set','575188dtveVX','14eSblBs','163093tYIJiG','Cache','188837aaEaBl','1376505SARbAf','MD5','303993CfMFbE','crypto-js','REQUEST_OBJ_CTX_KEY','__esModule','CacheService','MethodDecorator','2QdouNR','180592hmakJS','get','5vajlGX'];a2_0x9df2=function(){return _0x1bcbf4;};return a2_0x9df2();}function a2_0x2a19(_0x1ae695,_0x1a781){const _0x9df2e6=a2_0x9df2();return a2_0x2a19=function(_0x2a1960,_0x5829ab){_0x2a1960=_0x2a1960-0x1f3;let _0x711688=_0x9df2e6[_0x2a1960];return _0x711688;},a2_0x2a19(_0x1ae695,_0x1a781);}Object['defineProperty'](exports,a2_0x2449d5(0x20a),{'value':!![]}),exports[a2_0x2449d5(0x203)]=void 0x0;const crypto_js_1=require(a2_0x2449d5(0x208)),CacheService_1=require('../service/CacheService'),core_1=require('@midwayjs/core');function Cache(_0x5896d1,_0x57cb4b){return(_0x3c8c99,_0x4b0ed1,_0x2080c2)=>{const _0x657bb7=a2_0x2a19,_0xcb349b=_0x2080c2['value'];return _0x2080c2[_0x657bb7(0x1fd)]=async function(..._0x2141f7){const _0x5f34f9=_0x657bb7;!_0x5896d1&&(_0x5896d1=(0x0,crypto_js_1[_0x5f34f9(0x206)])(JSON[_0x5f34f9(0x1fc)](_0x2141f7))['toString']());let _0x148737=await this[core_1[_0x5f34f9(0x209)]]['app']['getApplicationContext']()['getAsync'](CacheService_1[_0x5f34f9(0x1f3)]),_0x1a08dd=await _0x148737[_0x5f34f9(0x1fe)]('MethodDecorator')[_0x5f34f9(0x1f7)](_0x5896d1);if(_0x1a08dd)return JSON['parse'](_0x1a08dd);else _0x1a08dd=await _0xcb349b[_0x5f34f9(0x1f9)](this,[..._0x2141f7]),await _0x148737[_0x5f34f9(0x1fe)](_0x5f34f9(0x1f4))[_0x5f34f9(0x1ff)](_0x5896d1,JSON['stringify'](_0x1a08dd),_0x57cb4b);return _0x1a08dd;},_0x2080c2;};}exports[a2_0x2449d5(0x203)]=Cache;
|
package/dist/index.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
'use strict';var
|
|
1
|
+
'use strict';var a3_0x437c93=a3_0x4c6d;(function(_0x5def5,_0x10b437){var _0x54878c=a3_0x4c6d,_0x235d50=_0x5def5();while(!![]){try{var _0x157934=parseInt(_0x54878c(0x1e3))/0x1+parseInt(_0x54878c(0x1dc))/0x2*(-parseInt(_0x54878c(0x1e9))/0x3)+parseInt(_0x54878c(0x1df))/0x4+-parseInt(_0x54878c(0x1e5))/0x5*(parseInt(_0x54878c(0x1e2))/0x6)+parseInt(_0x54878c(0x1da))/0x7+parseInt(_0x54878c(0x1e6))/0x8*(parseInt(_0x54878c(0x1e0))/0x9)+-parseInt(_0x54878c(0x1e4))/0xa;if(_0x157934===_0x10b437)break;else _0x235d50['push'](_0x235d50['shift']());}catch(_0x459ba0){_0x235d50['push'](_0x235d50['shift']());}}}(a3_0x2e50,0xafaa1));function a3_0x2e50(){var _0x588d11=['13393690lJnvHy','50yVfxLk','8073552qzxmiH','./decorator/Cache','CacheService','435DsgiQZ','./service/CacheService','4319924mEMOXR','Configuration','15262SpzPvU','Cache','defineProperty','4860196RPQboG','9rGQqQM','CustomConfiguration','358404ZCGLyA','921350MiAXuG'];a3_0x2e50=function(){return _0x588d11;};return a3_0x2e50();}Object['defineProperty'](exports,'__esModule',{'value':!![]}),exports[a3_0x437c93(0x1e8)]=exports[a3_0x437c93(0x1dd)]=exports[a3_0x437c93(0x1db)]=void 0x0;var configuration_1=require('./configuration');function a3_0x4c6d(_0x484b3f,_0x30821b){var _0x2e5028=a3_0x2e50();return a3_0x4c6d=function(_0x4c6d64,_0x2fbd9e){_0x4c6d64=_0x4c6d64-0x1da;var _0x395dae=_0x2e5028[_0x4c6d64];return _0x395dae;},a3_0x4c6d(_0x484b3f,_0x30821b);}Object[a3_0x437c93(0x1de)](exports,a3_0x437c93(0x1db),{'enumerable':!![],'get':function(){var _0x5a836f=a3_0x437c93;return configuration_1[_0x5a836f(0x1e1)];}});var Cache_1=require(a3_0x437c93(0x1e7));Object[a3_0x437c93(0x1de)](exports,a3_0x437c93(0x1dd),{'enumerable':!![],'get':function(){var _0x49e9a4=a3_0x437c93;return Cache_1[_0x49e9a4(0x1dd)];}});var CacheService_1=require(a3_0x437c93(0x1ea));Object['defineProperty'](exports,a3_0x437c93(0x1e8),{'enumerable':!![],'get':function(){var _0x406844=a3_0x437c93;return CacheService_1[_0x406844(0x1e8)];}});
|
|
@@ -1 +1 @@
|
|
|
1
|
-
'use strict';var
|
|
1
|
+
'use strict';var a4_0x21764e=a4_0x4351;function a4_0x4351(_0x45e7ec,_0x51d849){var _0x45f464=a4_0x45f4();return a4_0x4351=function(_0x435170,_0x381b12){_0x435170=_0x435170-0x170;var _0x3508fe=_0x45f464[_0x435170];return _0x3508fe;},a4_0x4351(_0x45e7ec,_0x51d849);}(function(_0xb54b61,_0xdb2f1a){var _0x31482c=a4_0x4351,_0x8a75fc=_0xb54b61();while(!![]){try{var _0x3c749f=-parseInt(_0x31482c(0x19b))/0x1*(parseInt(_0x31482c(0x183))/0x2)+parseInt(_0x31482c(0x191))/0x3*(-parseInt(_0x31482c(0x198))/0x4)+parseInt(_0x31482c(0x187))/0x5+parseInt(_0x31482c(0x177))/0x6*(parseInt(_0x31482c(0x186))/0x7)+-parseInt(_0x31482c(0x188))/0x8+-parseInt(_0x31482c(0x174))/0x9+-parseInt(_0x31482c(0x175))/0xa*(-parseInt(_0x31482c(0x17a))/0xb);if(_0x3c749f===_0xdb2f1a)break;else _0x8a75fc['push'](_0x8a75fc['shift']());}catch(_0x8c1854){_0x8a75fc['push'](_0x8a75fc['shift']());}}}(a4_0x45f4,0x94feb));var __decorate=this&&this[a4_0x21764e(0x170)]||function(_0x5a8b4b,_0x578642,_0x10a9b4,_0x15294e){var _0x2acad6=a4_0x21764e,_0x3b1f2f=arguments[_0x2acad6(0x184)],_0x35f62b=_0x3b1f2f<0x3?_0x578642:_0x15294e===null?_0x15294e=Object[_0x2acad6(0x17f)](_0x578642,_0x10a9b4):_0x15294e,_0x44a1fc;if(typeof Reflect===_0x2acad6(0x171)&&typeof Reflect[_0x2acad6(0x194)]===_0x2acad6(0x172))_0x35f62b=Reflect['decorate'](_0x5a8b4b,_0x578642,_0x10a9b4,_0x15294e);else{for(var _0x1917de=_0x5a8b4b[_0x2acad6(0x184)]-0x1;_0x1917de>=0x0;_0x1917de--)if(_0x44a1fc=_0x5a8b4b[_0x1917de])_0x35f62b=(_0x3b1f2f<0x3?_0x44a1fc(_0x35f62b):_0x3b1f2f>0x3?_0x44a1fc(_0x578642,_0x10a9b4,_0x35f62b):_0x44a1fc(_0x578642,_0x10a9b4))||_0x35f62b;}return _0x3b1f2f>0x3&&_0x35f62b&&Object['defineProperty'](_0x578642,_0x10a9b4,_0x35f62b),_0x35f62b;},__metadata=this&&this[a4_0x21764e(0x19a)]||function(_0x2679a4,_0x27c5a8){var _0x37715d=a4_0x21764e;if(typeof Reflect==='object'&&typeof Reflect[_0x37715d(0x193)]===_0x37715d(0x172))return Reflect['metadata'](_0x2679a4,_0x27c5a8);};Object[a4_0x21764e(0x176)](exports,a4_0x21764e(0x190),{'value':!![]}),exports['CacheService']=void 0x0;function a4_0x45f4(){var _0x353ef9=['length','use','5183647bdxSVJ','5959975xEpdGx','7811520rVKKKO','design:type','hdel','@midwayjs/decorator','default','set','options','Singleton','__esModule','1761bImgjZ','del','metadata','decorate','store','cache-manager','clients','5596kFuEhC','Scope','__metadata','11jSJuGw','file','__decorate','object','function','prefix','1434348tkHFxf','19870tafHyq','defineProperty','6AtFwzf','ScopeEnum','caching','5071DjKSfI','hset','cache','stores','Provide','getOwnPropertyDescriptor','reset','config','get','51130LKmLjp'];a4_0x45f4=function(){return _0x353ef9;};return a4_0x45f4();}const cacheManager=require(a4_0x21764e(0x196)),decorator_1=require(a4_0x21764e(0x18b));let CacheService=class CacheService{constructor(){var _0x5c5a3b=a4_0x21764e;this[_0x5c5a3b(0x17c)]=undefined,this[_0x5c5a3b(0x197)]=new Map();}[a4_0x21764e(0x185)](_0x583a00){var _0x464d44=a4_0x21764e,_0x52502c,_0x37115c;if(!this['cache']){const _0x23e7cc=((_0x52502c=this[_0x464d44(0x181)][_0x464d44(0x17d)])===null||_0x52502c===void 0x0?void 0x0:_0x52502c[(_0x37115c=this[_0x464d44(0x181)][_0x464d44(0x17c)])===null||_0x37115c===void 0x0?void 0x0:_0x37115c[_0x464d44(0x18c)]])||this[_0x464d44(0x181)][_0x464d44(0x17d)][_0x464d44(0x19c)];this['cache']=cacheManager[_0x464d44(0x179)]({..._0x23e7cc[_0x464d44(0x18e)],'store':_0x23e7cc[_0x464d44(0x195)]});}return!this['clients']['has'](_0x583a00)&&this[_0x464d44(0x197)]['set'](_0x583a00,new CacheHandler(_0x583a00,this[_0x464d44(0x17c)])),this['clients'][_0x464d44(0x182)](_0x583a00);}async[a4_0x21764e(0x180)](){var _0x11d813=a4_0x21764e;return await this[_0x11d813(0x17c)][_0x11d813(0x180)]();}};__decorate([(0x0,decorator_1['Config'])(a4_0x21764e(0x17c)),__metadata(a4_0x21764e(0x189),Object)],CacheService['prototype'],'config',void 0x0),CacheService=__decorate([(0x0,decorator_1[a4_0x21764e(0x17e)])(),(0x0,decorator_1[a4_0x21764e(0x199)])(decorator_1[a4_0x21764e(0x178)][a4_0x21764e(0x18f)])],CacheService),exports['CacheService']=CacheService;class CacheHandler{constructor(_0x4befa4,_0x46ea01){var _0x1e13d7=a4_0x21764e;this[_0x1e13d7(0x17c)]=_0x46ea01,this['prefix']=_0x4befa4;}async[a4_0x21764e(0x192)](_0x54cfe1){var _0x5f23d5=a4_0x21764e;return await this[_0x5f23d5(0x17c)][_0x5f23d5(0x192)](this[_0x5f23d5(0x173)]+':'+_0x54cfe1);}async[a4_0x21764e(0x18d)](_0x1d197a,_0x5c9904,_0x40e39f){var _0x487997=a4_0x21764e;return await this[_0x487997(0x17c)][_0x487997(0x18d)](this[_0x487997(0x173)]+':'+_0x1d197a,_0x5c9904,_0x40e39f);}async[a4_0x21764e(0x182)](_0x2222e3,_0x49cad7){return new Promise((_0x3f2623,_0x107890)=>{var _0x3b398f=a4_0x4351;this[_0x3b398f(0x17c)][_0x3b398f(0x182)](this[_0x3b398f(0x173)]+':'+_0x2222e3,(_0x10bf1a,_0x52c667)=>{_0x10bf1a?_0x107890(_0x10bf1a):_0x3f2623(_0x52c667||_0x49cad7);});});}async[a4_0x21764e(0x18a)](_0x4abec1,_0x52c601){var _0x26b487=a4_0x21764e;return await this[_0x26b487(0x192)](_0x4abec1+'-'+_0x52c601);}async[a4_0x21764e(0x17b)](_0x4caad8,_0xb4b99,_0x4a5d58,_0x4d2244){var _0xdef169=a4_0x21764e;return await this[_0xdef169(0x18d)](_0x4caad8+'-'+_0xb4b99,_0x4a5d58,_0x4d2244);}async['hget'](_0x24f37e,_0x2bd83e,_0x2251cc){var _0x1adca6=a4_0x21764e;return await this[_0x1adca6(0x182)](_0x24f37e+'-'+_0x2bd83e,_0x2251cc);}}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@anncic-api/cache",
|
|
3
|
-
"version": "1.1.
|
|
3
|
+
"version": "1.1.24",
|
|
4
4
|
"main": "./dist/index.js",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"files": [
|
|
@@ -23,5 +23,5 @@
|
|
|
23
23
|
"javascript-obfuscator": "2.19.0",
|
|
24
24
|
"typescript": "^4.7.4"
|
|
25
25
|
},
|
|
26
|
-
"gitHead": "
|
|
26
|
+
"gitHead": "c273d494dd497231c4e1b64412879e17d536020e"
|
|
27
27
|
}
|