@hg-ts/redis 0.1.17 → 0.1.19
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/.eslintcache +1 -1
- package/dist/index.d.ts +2 -0
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +4 -0
- package/dist/index.js.map +1 -1
- package/dist/redis.client.d.ts +4 -0
- package/dist/redis.client.d.ts.map +1 -0
- package/dist/redis.client.js +9 -0
- package/dist/redis.client.js.map +1 -0
- package/dist/redis.module.d.ts +1 -2
- package/dist/redis.module.d.ts.map +1 -1
- package/dist/redis.module.js +17 -4
- package/dist/redis.module.js.map +1 -1
- package/dist-esm/index.d.ts +2 -0
- package/dist-esm/index.d.ts.map +1 -1
- package/dist-esm/index.js +2 -1
- package/dist-esm/index.js.map +1 -1
- package/dist-esm/redis.client.d.ts +4 -0
- package/dist-esm/redis.client.d.ts.map +1 -0
- package/dist-esm/redis.client.js +4 -0
- package/dist-esm/redis.client.js.map +1 -0
- package/dist-esm/redis.module.d.ts +1 -2
- package/dist-esm/redis.module.d.ts.map +1 -1
- package/dist-esm/redis.module.js +19 -6
- package/dist-esm/redis.module.js.map +1 -1
- package/package.json +12 -12
- package/src/index.ts +2 -0
- package/src/redis.client.ts +3 -0
- package/src/redis.module.ts +22 -9
package/.eslintcache
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
[{"/Volumes/Work/ts/hg/framework/packages/server/src/index.ts":"1","/Volumes/Work/ts/hg/framework/packages/server/src/server.module.ts":"2","/Volumes/Work/ts/hg/framework/packages/server/src/controllers/controller-explorer.service.ts":"3","/Volumes/Work/ts/hg/framework/packages/server/src/controllers/controller.caller.ts":"4","/Volumes/Work/ts/hg/framework/packages/server/src/controllers/index.ts":"5","/Volumes/Work/ts/hg/framework/packages/server/src/decorators/context.decorator.ts":"6","/Volumes/Work/ts/hg/framework/packages/server/src/decorators/controller.decorator.ts":"7","/Volumes/Work/ts/hg/framework/packages/server/src/decorators/create-param-decorator.ts":"8","/Volumes/Work/ts/hg/framework/packages/server/src/decorators/index.ts":"9","/Volumes/Work/ts/hg/framework/packages/server/src/decorators/middleware-data.decorator.ts":"10","/Volumes/Work/ts/hg/framework/packages/server/src/execution-context/execution-context.provider.ts":"11","/Volumes/Work/ts/hg/framework/packages/server/src/execution-context/execution-context.ts":"12","/Volumes/Work/ts/hg/framework/packages/server/src/execution-context/index.ts":"13","/Volumes/Work/ts/hg/framework/packages/server/src/server/base.handler-map.ts":"14","/Volumes/Work/ts/hg/framework/packages/server/src/server/base.server.ts":"15","/Volumes/Work/ts/hg/framework/packages/server/src/server/index.ts":"16","/Volumes/Work/ts/hg/framework/packages/server/src/server/request.handler.ts":"17","/Volumes/Work/ts/hg/framework/packages/server/src/tests/controllers/consts.ts":"18","/Volumes/Work/ts/hg/framework/packages/server/src/tests/controllers/controller.test-suite.ts":"19","/Volumes/Work/ts/hg/framework/packages/server/src/tests/controllers/test.controller.ts":"20","/Volumes/Work/ts/hg/framework/packages/server/src/tests/controllers/test.execution-context.ts":"21","/Volumes/Work/ts/hg/framework/packages/server/src/tests/server/server.test-suite.ts":"22","/Volumes/Work/ts/hg/framework/packages/server/src/tests/server/test-handler.decorator.ts":"23","/Volumes/Work/ts/hg/framework/packages/server/src/tests/server/test.body.ts":"24","/Volumes/Work/ts/hg/framework/packages/server/src/tests/server/test.controller.ts":"25","/Volumes/Work/ts/hg/framework/packages/server/src/tests/server/test.execution-context.ts":"26","/Volumes/Work/ts/hg/framework/packages/server/src/tests/server/test.handler-map.ts":"27","/Volumes/Work/ts/hg/framework/packages/server/src/tests/server/test.module.ts":"28","/Volumes/Work/ts/hg/framework/packages/server/src/tests/server/test.server.ts":"29","/Volumes/Work/ts/hg/framework/packages/server/src/utils.ts":"30","/Volumes/Work/ts/hg/framework/packages/redis/src/config.ts":"31","/Volumes/Work/ts/hg/framework/packages/redis/src/index.ts":"32","/Volumes/Work/ts/hg/framework/packages/redis/src/redis.module.ts":"33"},{"size":0,"mtime":1708838426330,"results":"34","hashOfConfig":"35"},{"size":489,"mtime":1704693489346,"results":"36","hashOfConfig":"35"},{"size":898,"mtime":1704693194902,"results":"37","hashOfConfig":"35"},{"size":1301,"mtime":1704693356706,"results":"38","hashOfConfig":"35"},{"size":84,"mtime":1704693160554,"results":"39","hashOfConfig":"35"},{"size":213,"mtime":1698022585971,"results":"40","hashOfConfig":"35"},{"size":1229,"mtime":1698022585972,"results":"41","hashOfConfig":"35"},{"size":2312,"mtime":1698022585972,"results":"42","hashOfConfig":"35"},{"size":165,"mtime":1698022585972,"results":"43","hashOfConfig":"35"},{"size":241,"mtime":1698022585972,"results":"44","hashOfConfig":"35"},{"size":212,"mtime":1708838426328,"results":"45","hashOfConfig":"35"},{"size":2730,"mtime":1708838426329,"results":"46","hashOfConfig":"35"},{"size":83,"mtime":1704692942783,"results":"47","hashOfConfig":"35"},{"size":880,"mtime":1708838426331,"results":"48","hashOfConfig":"35"},{"size":2385,"mtime":1708838426332,"results":"49","hashOfConfig":"35"},{"size":102,"mtime":1704693390851,"results":"50","hashOfConfig":"35"},{"size":405,"mtime":1704693489344,"results":"51","hashOfConfig":"35"},{"size":56,"mtime":1698022585973,"results":"52","hashOfConfig":"35"},{"size":1902,"mtime":1704692991785,"results":"53","hashOfConfig":"35"},{"size":603,"mtime":1704693160564,"results":"54","hashOfConfig":"35"},{"size":197,"mtime":1704692991779,"results":"55","hashOfConfig":"35"},{"size":971,"mtime":1713131798111,"results":"56","hashOfConfig":"35"},{"size":695,"mtime":1704693160551,"results":"57","hashOfConfig":"35"},{"size":229,"mtime":1704693160570,"results":"58","hashOfConfig":"35"},{"size":330,"mtime":1704693160566,"results":"59","hashOfConfig":"35"},{"size":261,"mtime":1704693160562,"results":"60","hashOfConfig":"35"},{"size":659,"mtime":1704693489341,"results":"61","hashOfConfig":"35"},{"size":295,"mtime":1704692907521,"results":"62","hashOfConfig":"35"},{"size":1536,"mtime":1704693489349,"results":"63","hashOfConfig":"35"},{"size":873,"mtime":1704693356704,"results":"64","hashOfConfig":"35"},{"size":335,"mtime":1713905382473,"results":"65","hashOfConfig":"66"},{"size":0,"mtime":1713904162225,"results":"67","hashOfConfig":"66"},{"size":883,"mtime":1713906364489,"results":"68","hashOfConfig":"66"},{"filePath":"69","messages":"70","suppressedMessages":"71","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},"1prrhjb",{"filePath":"72","messages":"73","suppressedMessages":"74","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"75","messages":"76","suppressedMessages":"77","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"78","messages":"79","suppressedMessages":"80","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"81","messages":"82","suppressedMessages":"83","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"84","messages":"85","suppressedMessages":"86","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"87","messages":"88","suppressedMessages":"89","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"90","messages":"91","suppressedMessages":"92","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"93","messages":"94","suppressedMessages":"95","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"96","messages":"97","suppressedMessages":"98","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"99","messages":"100","suppressedMessages":"101","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"102","messages":"103","suppressedMessages":"104","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"105","messages":"106","suppressedMessages":"107","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"108","messages":"109","suppressedMessages":"110","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"111","messages":"112","suppressedMessages":"113","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"114","messages":"115","suppressedMessages":"116","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"117","messages":"118","suppressedMessages":"119","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"120","messages":"121","suppressedMessages":"122","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"123","messages":"124","suppressedMessages":"125","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"126","messages":"127","suppressedMessages":"128","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"129","messages":"130","suppressedMessages":"131","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"132","messages":"133","suppressedMessages":"134","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"135","messages":"136","suppressedMessages":"137","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"138","messages":"139","suppressedMessages":"140","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"141","messages":"142","suppressedMessages":"143","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"144","messages":"145","suppressedMessages":"146","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"147","messages":"148","suppressedMessages":"149","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"150","messages":"151","suppressedMessages":"152","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"153","messages":"154","suppressedMessages":"155","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"156","messages":"157","suppressedMessages":"158","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"159","messages":"160","suppressedMessages":"161","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},"fwzekl",{"filePath":"162","messages":"163","suppressedMessages":"164","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"165","messages":"166","suppressedMessages":"167","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},"/Volumes/Work/ts/hg/framework/packages/server/src/index.ts",[],[],"/Volumes/Work/ts/hg/framework/packages/server/src/server.module.ts",[],[],"/Volumes/Work/ts/hg/framework/packages/server/src/controllers/controller-explorer.service.ts",[],["168"],"/Volumes/Work/ts/hg/framework/packages/server/src/controllers/controller.caller.ts",[],[],"/Volumes/Work/ts/hg/framework/packages/server/src/controllers/index.ts",[],[],"/Volumes/Work/ts/hg/framework/packages/server/src/decorators/context.decorator.ts",[],[],"/Volumes/Work/ts/hg/framework/packages/server/src/decorators/controller.decorator.ts",[],[],"/Volumes/Work/ts/hg/framework/packages/server/src/decorators/create-param-decorator.ts",[],[],"/Volumes/Work/ts/hg/framework/packages/server/src/decorators/index.ts",[],[],"/Volumes/Work/ts/hg/framework/packages/server/src/decorators/middleware-data.decorator.ts",[],[],"/Volumes/Work/ts/hg/framework/packages/server/src/execution-context/execution-context.provider.ts",[],[],"/Volumes/Work/ts/hg/framework/packages/server/src/execution-context/execution-context.ts",[],[],"/Volumes/Work/ts/hg/framework/packages/server/src/execution-context/index.ts",[],[],"/Volumes/Work/ts/hg/framework/packages/server/src/server/base.handler-map.ts",[],[],"/Volumes/Work/ts/hg/framework/packages/server/src/server/base.server.ts",[],[],"/Volumes/Work/ts/hg/framework/packages/server/src/server/index.ts",[],[],"/Volumes/Work/ts/hg/framework/packages/server/src/server/request.handler.ts",[],[],"/Volumes/Work/ts/hg/framework/packages/server/src/tests/controllers/consts.ts",[],[],"/Volumes/Work/ts/hg/framework/packages/server/src/tests/controllers/controller.test-suite.ts",[],[],"/Volumes/Work/ts/hg/framework/packages/server/src/tests/controllers/test.controller.ts",[],[],"/Volumes/Work/ts/hg/framework/packages/server/src/tests/controllers/test.execution-context.ts",[],[],"/Volumes/Work/ts/hg/framework/packages/server/src/tests/server/server.test-suite.ts",[],[],"/Volumes/Work/ts/hg/framework/packages/server/src/tests/server/test-handler.decorator.ts",[],[],"/Volumes/Work/ts/hg/framework/packages/server/src/tests/server/test.body.ts",[],[],"/Volumes/Work/ts/hg/framework/packages/server/src/tests/server/test.controller.ts",[],[],"/Volumes/Work/ts/hg/framework/packages/server/src/tests/server/test.execution-context.ts",[],[],"/Volumes/Work/ts/hg/framework/packages/server/src/tests/server/test.handler-map.ts",[],[],"/Volumes/Work/ts/hg/framework/packages/server/src/tests/server/test.module.ts",[],[],"/Volumes/Work/ts/hg/framework/packages/server/src/tests/server/test.server.ts",[],[],"/Volumes/Work/ts/hg/framework/packages/server/src/utils.ts",[],[],"/Volumes/Work/ts/hg/framework/packages/redis/src/config.ts",[],[],"/Volumes/Work/ts/hg/framework/packages/redis/src/index.ts",[],[],"/Volumes/Work/ts/hg/framework/packages/redis/src/redis.module.ts",[],[],{"ruleId":"169","severity":2,"message":"170","line":23,"column":37,"nodeType":"171","messageId":"172","endLine":23,"endColumn":50,"suppressions":"173"},"@typescript-eslint/no-unnecessary-condition","Unnecessary conditional, value is always truthy.","MemberExpression","alwaysTruthy",["174"],{"kind":"175","justification":"176"},"directive",""]
|
|
1
|
+
[{"/Volumes/Work/ts/hg/framework/packages/server/src/index.ts":"1","/Volumes/Work/ts/hg/framework/packages/server/src/server.module.ts":"2","/Volumes/Work/ts/hg/framework/packages/server/src/controllers/controller-explorer.service.ts":"3","/Volumes/Work/ts/hg/framework/packages/server/src/controllers/controller.caller.ts":"4","/Volumes/Work/ts/hg/framework/packages/server/src/controllers/index.ts":"5","/Volumes/Work/ts/hg/framework/packages/server/src/decorators/context.decorator.ts":"6","/Volumes/Work/ts/hg/framework/packages/server/src/decorators/controller.decorator.ts":"7","/Volumes/Work/ts/hg/framework/packages/server/src/decorators/create-param-decorator.ts":"8","/Volumes/Work/ts/hg/framework/packages/server/src/decorators/index.ts":"9","/Volumes/Work/ts/hg/framework/packages/server/src/decorators/middleware-data.decorator.ts":"10","/Volumes/Work/ts/hg/framework/packages/server/src/execution-context/execution-context.provider.ts":"11","/Volumes/Work/ts/hg/framework/packages/server/src/execution-context/execution-context.ts":"12","/Volumes/Work/ts/hg/framework/packages/server/src/execution-context/index.ts":"13","/Volumes/Work/ts/hg/framework/packages/server/src/server/base.handler-map.ts":"14","/Volumes/Work/ts/hg/framework/packages/server/src/server/base.server.ts":"15","/Volumes/Work/ts/hg/framework/packages/server/src/server/index.ts":"16","/Volumes/Work/ts/hg/framework/packages/server/src/server/request.handler.ts":"17","/Volumes/Work/ts/hg/framework/packages/server/src/tests/controllers/consts.ts":"18","/Volumes/Work/ts/hg/framework/packages/server/src/tests/controllers/controller.test-suite.ts":"19","/Volumes/Work/ts/hg/framework/packages/server/src/tests/controllers/test.controller.ts":"20","/Volumes/Work/ts/hg/framework/packages/server/src/tests/controllers/test.execution-context.ts":"21","/Volumes/Work/ts/hg/framework/packages/server/src/tests/server/server.test-suite.ts":"22","/Volumes/Work/ts/hg/framework/packages/server/src/tests/server/test-handler.decorator.ts":"23","/Volumes/Work/ts/hg/framework/packages/server/src/tests/server/test.body.ts":"24","/Volumes/Work/ts/hg/framework/packages/server/src/tests/server/test.controller.ts":"25","/Volumes/Work/ts/hg/framework/packages/server/src/tests/server/test.execution-context.ts":"26","/Volumes/Work/ts/hg/framework/packages/server/src/tests/server/test.handler-map.ts":"27","/Volumes/Work/ts/hg/framework/packages/server/src/tests/server/test.module.ts":"28","/Volumes/Work/ts/hg/framework/packages/server/src/tests/server/test.server.ts":"29","/Volumes/Work/ts/hg/framework/packages/server/src/utils.ts":"30","/Volumes/Work/ts/hg/framework/packages/redis/src/config.ts":"31","/Volumes/Work/ts/hg/framework/packages/redis/src/index.ts":"32","/Volumes/Work/ts/hg/framework/packages/redis/src/redis.module.ts":"33","/Volumes/Work/ts/hg/framework/packages/redis/src/redis.client.ts":"34"},{"size":0,"mtime":1708838426330,"results":"35","hashOfConfig":"36"},{"size":489,"mtime":1704693489346,"results":"37","hashOfConfig":"36"},{"size":898,"mtime":1704693194902,"results":"38","hashOfConfig":"36"},{"size":1301,"mtime":1704693356706,"results":"39","hashOfConfig":"36"},{"size":84,"mtime":1704693160554,"results":"40","hashOfConfig":"36"},{"size":213,"mtime":1698022585971,"results":"41","hashOfConfig":"36"},{"size":1229,"mtime":1698022585972,"results":"42","hashOfConfig":"36"},{"size":2312,"mtime":1698022585972,"results":"43","hashOfConfig":"36"},{"size":165,"mtime":1698022585972,"results":"44","hashOfConfig":"36"},{"size":241,"mtime":1698022585972,"results":"45","hashOfConfig":"36"},{"size":212,"mtime":1708838426328,"results":"46","hashOfConfig":"36"},{"size":2730,"mtime":1708838426329,"results":"47","hashOfConfig":"36"},{"size":83,"mtime":1704692942783,"results":"48","hashOfConfig":"36"},{"size":880,"mtime":1708838426331,"results":"49","hashOfConfig":"36"},{"size":2385,"mtime":1708838426332,"results":"50","hashOfConfig":"36"},{"size":102,"mtime":1704693390851,"results":"51","hashOfConfig":"36"},{"size":405,"mtime":1704693489344,"results":"52","hashOfConfig":"36"},{"size":56,"mtime":1698022585973,"results":"53","hashOfConfig":"36"},{"size":1902,"mtime":1704692991785,"results":"54","hashOfConfig":"36"},{"size":603,"mtime":1704693160564,"results":"55","hashOfConfig":"36"},{"size":197,"mtime":1704692991779,"results":"56","hashOfConfig":"36"},{"size":971,"mtime":1713131798111,"results":"57","hashOfConfig":"36"},{"size":695,"mtime":1704693160551,"results":"58","hashOfConfig":"36"},{"size":229,"mtime":1704693160570,"results":"59","hashOfConfig":"36"},{"size":330,"mtime":1704693160566,"results":"60","hashOfConfig":"36"},{"size":261,"mtime":1704693160562,"results":"61","hashOfConfig":"36"},{"size":659,"mtime":1704693489341,"results":"62","hashOfConfig":"36"},{"size":295,"mtime":1704692907521,"results":"63","hashOfConfig":"36"},{"size":1536,"mtime":1704693489349,"results":"64","hashOfConfig":"36"},{"size":873,"mtime":1704693356704,"results":"65","hashOfConfig":"36"},{"size":335,"mtime":1713905382473,"results":"66","hashOfConfig":"67"},{"size":64,"mtime":1714388145937,"results":"68","hashOfConfig":"67"},{"size":1200,"mtime":1714388123663,"results":"69","hashOfConfig":"67"},{"size":72,"mtime":1714388100835,"results":"70","hashOfConfig":"67"},{"filePath":"71","messages":"72","suppressedMessages":"73","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},"1prrhjb",{"filePath":"74","messages":"75","suppressedMessages":"76","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"77","messages":"78","suppressedMessages":"79","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"80","messages":"81","suppressedMessages":"82","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"83","messages":"84","suppressedMessages":"85","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"86","messages":"87","suppressedMessages":"88","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"89","messages":"90","suppressedMessages":"91","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"92","messages":"93","suppressedMessages":"94","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"95","messages":"96","suppressedMessages":"97","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"98","messages":"99","suppressedMessages":"100","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"101","messages":"102","suppressedMessages":"103","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"104","messages":"105","suppressedMessages":"106","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"107","messages":"108","suppressedMessages":"109","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"110","messages":"111","suppressedMessages":"112","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"113","messages":"114","suppressedMessages":"115","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"116","messages":"117","suppressedMessages":"118","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"119","messages":"120","suppressedMessages":"121","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"122","messages":"123","suppressedMessages":"124","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"125","messages":"126","suppressedMessages":"127","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"128","messages":"129","suppressedMessages":"130","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"131","messages":"132","suppressedMessages":"133","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"134","messages":"135","suppressedMessages":"136","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"137","messages":"138","suppressedMessages":"139","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"140","messages":"141","suppressedMessages":"142","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"143","messages":"144","suppressedMessages":"145","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"146","messages":"147","suppressedMessages":"148","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"149","messages":"150","suppressedMessages":"151","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"152","messages":"153","suppressedMessages":"154","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"155","messages":"156","suppressedMessages":"157","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"158","messages":"159","suppressedMessages":"160","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"161","messages":"162","suppressedMessages":"163","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},"fwzekl",{"filePath":"164","messages":"165","suppressedMessages":"166","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"167","messages":"168","suppressedMessages":"169","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"170","messages":"171","suppressedMessages":"172","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},"/Volumes/Work/ts/hg/framework/packages/server/src/index.ts",[],[],"/Volumes/Work/ts/hg/framework/packages/server/src/server.module.ts",[],[],"/Volumes/Work/ts/hg/framework/packages/server/src/controllers/controller-explorer.service.ts",[],["173"],"/Volumes/Work/ts/hg/framework/packages/server/src/controllers/controller.caller.ts",[],[],"/Volumes/Work/ts/hg/framework/packages/server/src/controllers/index.ts",[],[],"/Volumes/Work/ts/hg/framework/packages/server/src/decorators/context.decorator.ts",[],[],"/Volumes/Work/ts/hg/framework/packages/server/src/decorators/controller.decorator.ts",[],[],"/Volumes/Work/ts/hg/framework/packages/server/src/decorators/create-param-decorator.ts",[],[],"/Volumes/Work/ts/hg/framework/packages/server/src/decorators/index.ts",[],[],"/Volumes/Work/ts/hg/framework/packages/server/src/decorators/middleware-data.decorator.ts",[],[],"/Volumes/Work/ts/hg/framework/packages/server/src/execution-context/execution-context.provider.ts",[],[],"/Volumes/Work/ts/hg/framework/packages/server/src/execution-context/execution-context.ts",[],[],"/Volumes/Work/ts/hg/framework/packages/server/src/execution-context/index.ts",[],[],"/Volumes/Work/ts/hg/framework/packages/server/src/server/base.handler-map.ts",[],[],"/Volumes/Work/ts/hg/framework/packages/server/src/server/base.server.ts",[],[],"/Volumes/Work/ts/hg/framework/packages/server/src/server/index.ts",[],[],"/Volumes/Work/ts/hg/framework/packages/server/src/server/request.handler.ts",[],[],"/Volumes/Work/ts/hg/framework/packages/server/src/tests/controllers/consts.ts",[],[],"/Volumes/Work/ts/hg/framework/packages/server/src/tests/controllers/controller.test-suite.ts",[],[],"/Volumes/Work/ts/hg/framework/packages/server/src/tests/controllers/test.controller.ts",[],[],"/Volumes/Work/ts/hg/framework/packages/server/src/tests/controllers/test.execution-context.ts",[],[],"/Volumes/Work/ts/hg/framework/packages/server/src/tests/server/server.test-suite.ts",[],[],"/Volumes/Work/ts/hg/framework/packages/server/src/tests/server/test-handler.decorator.ts",[],[],"/Volumes/Work/ts/hg/framework/packages/server/src/tests/server/test.body.ts",[],[],"/Volumes/Work/ts/hg/framework/packages/server/src/tests/server/test.controller.ts",[],[],"/Volumes/Work/ts/hg/framework/packages/server/src/tests/server/test.execution-context.ts",[],[],"/Volumes/Work/ts/hg/framework/packages/server/src/tests/server/test.handler-map.ts",[],[],"/Volumes/Work/ts/hg/framework/packages/server/src/tests/server/test.module.ts",[],[],"/Volumes/Work/ts/hg/framework/packages/server/src/tests/server/test.server.ts",[],[],"/Volumes/Work/ts/hg/framework/packages/server/src/utils.ts",[],[],"/Volumes/Work/ts/hg/framework/packages/redis/src/config.ts",[],[],"/Volumes/Work/ts/hg/framework/packages/redis/src/index.ts",[],[],"/Volumes/Work/ts/hg/framework/packages/redis/src/redis.module.ts",[],[],"/Volumes/Work/ts/hg/framework/packages/redis/src/redis.client.ts",[],[],{"ruleId":"174","severity":2,"message":"175","line":23,"column":37,"nodeType":"176","messageId":"177","endLine":23,"endColumn":50,"suppressions":"178"},"@typescript-eslint/no-unnecessary-condition","Unnecessary conditional, value is always truthy.","MemberExpression","alwaysTruthy",["179"],{"kind":"180","justification":"181"},"directive",""]
|
package/dist/index.d.ts
CHANGED
package/dist/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":""}
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,cAAc,gBAAgB,CAAC;AAC/B,cAAc,gBAAgB,CAAC"}
|
package/dist/index.js
CHANGED
|
@@ -1,2 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
const tslib_1 = require("tslib");
|
|
4
|
+
tslib_1.__exportStar(require("./redis.module"), exports);
|
|
5
|
+
tslib_1.__exportStar(require("./redis.client"), exports);
|
|
2
6
|
//# sourceMappingURL=index.js.map
|
package/dist/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":""}
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";;;AAAA,yDAA+B;AAC/B,yDAA+B"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"redis.client.d.ts","sourceRoot":"","sources":["../src/redis.client.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,SAAS,CAAC;AAE5B,qBAAa,WAAY,SAAQ,KAAK;CAAG"}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.RedisClient = void 0;
|
|
4
|
+
const tslib_1 = require("tslib");
|
|
5
|
+
const ioredis_1 = tslib_1.__importDefault(require("ioredis"));
|
|
6
|
+
class RedisClient extends ioredis_1.default {
|
|
7
|
+
}
|
|
8
|
+
exports.RedisClient = RedisClient;
|
|
9
|
+
//# sourceMappingURL=redis.client.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"redis.client.js","sourceRoot":"","sources":["../src/redis.client.ts"],"names":[],"mappings":";;;;AAAA,8DAA4B;AAE5B,MAAa,WAAY,SAAQ,iBAAK;CAAG;AAAzC,kCAAyC"}
|
package/dist/redis.module.d.ts
CHANGED
|
@@ -1,6 +1,5 @@
|
|
|
1
|
-
import { ConfigLoader } from '@hg-ts/config-loader';
|
|
2
1
|
import { DynamicModule } from '@hg-ts/ioc';
|
|
3
2
|
export declare class RedisModule {
|
|
4
|
-
static forRootAsync(
|
|
3
|
+
static forRootAsync(options: Pick<DynamicModule, 'imports'>): DynamicModule;
|
|
5
4
|
}
|
|
6
5
|
//# sourceMappingURL=redis.module.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"redis.module.d.ts","sourceRoot":"","sources":["../src/redis.module.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"redis.module.d.ts","sourceRoot":"","sources":["../src/redis.module.ts"],"names":[],"mappings":"AACA,OAAO,EACN,aAAa,EAGb,MAAM,YAAY,CAAC;AAWpB,qBAEa,WAAW;WACT,YAAY,CAAC,OAAO,EAAE,IAAI,CAAC,aAAa,EAAE,SAAS,CAAC,GAAG,aAAa;CAiClF"}
|
package/dist/redis.module.js
CHANGED
|
@@ -3,13 +3,16 @@ var RedisModule_1;
|
|
|
3
3
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4
4
|
exports.RedisModule = void 0;
|
|
5
5
|
const tslib_1 = require("tslib");
|
|
6
|
+
const config_loader_1 = require("@hg-ts/config-loader");
|
|
6
7
|
const ioc_1 = require("@hg-ts/ioc");
|
|
7
8
|
const nestjs_redis_1 = require("@liaoliaots/nestjs-redis");
|
|
8
9
|
const config_1 = require("./config");
|
|
10
|
+
const redis_client_1 = require("./redis.client");
|
|
9
11
|
let RedisModule = RedisModule_1 = class RedisModule {
|
|
10
|
-
static forRootAsync(
|
|
12
|
+
static forRootAsync(options) {
|
|
11
13
|
const redisModule = nestjs_redis_1.RedisModule.forRootAsync({
|
|
12
|
-
|
|
14
|
+
...options,
|
|
15
|
+
async useFactory(configLoader) {
|
|
13
16
|
const config = await configLoader.load(config_1.REDIS_CONFIG_SCHEMA, 'redis');
|
|
14
17
|
return {
|
|
15
18
|
commonOptions: { enableReadyCheck: true },
|
|
@@ -20,12 +23,22 @@ let RedisModule = RedisModule_1 = class RedisModule {
|
|
|
20
23
|
},
|
|
21
24
|
};
|
|
22
25
|
},
|
|
23
|
-
inject: [
|
|
26
|
+
inject: [config_loader_1.ConfigLoader],
|
|
24
27
|
});
|
|
25
28
|
return {
|
|
26
29
|
module: RedisModule_1,
|
|
27
30
|
imports: [redisModule],
|
|
28
|
-
|
|
31
|
+
providers: [
|
|
32
|
+
{
|
|
33
|
+
provide: redis_client_1.RedisClient,
|
|
34
|
+
useFactory(redisService) {
|
|
35
|
+
return redisService.getClient();
|
|
36
|
+
},
|
|
37
|
+
inject: [nestjs_redis_1.RedisService],
|
|
38
|
+
},
|
|
39
|
+
],
|
|
40
|
+
exports: [redis_client_1.RedisClient],
|
|
41
|
+
global: true,
|
|
29
42
|
};
|
|
30
43
|
}
|
|
31
44
|
};
|
package/dist/redis.module.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"redis.module.js","sourceRoot":"","sources":["../src/redis.module.ts"],"names":[],"mappings":";;;;;
|
|
1
|
+
{"version":3,"file":"redis.module.js","sourceRoot":"","sources":["../src/redis.module.ts"],"names":[],"mappings":";;;;;AAAA,wDAAoD;AACpD,oCAIoB;AAEpB,2DAIkC;AAElC,qCAA+C;AAC/C,iDAA6C;AAItC,IAAM,WAAW,mBAAjB,MAAM,WAAW;IAChB,MAAM,CAAC,YAAY,CAAC,OAAuC;QACjE,MAAM,WAAW,GAAG,0BAAc,CAAC,YAAY,CAAC;YAC/C,GAAG,OAAO;YACV,KAAK,CAAC,UAAU,CAAC,YAA0B;gBAC1C,MAAM,MAAM,GAAG,MAAM,YAAY,CAAC,IAAI,CAAC,4BAAmB,EAAE,OAAO,CAAC,CAAC;gBACrE,OAAO;oBACN,aAAa,EAAE,EAAE,gBAAgB,EAAE,IAAI,EAAE;oBACzC,MAAM,EAAE;wBACP,IAAI,EAAE,MAAM,CAAC,IAAI;wBACjB,IAAI,EAAE,MAAM,CAAC,IAAI;wBACjB,EAAE,EAAE,MAAM,CAAC,QAAQ;qBACnB;iBACD,CAAC;YACH,CAAC;YACD,MAAM,EAAE,CAAC,4BAAY,CAAC;SACtB,CAAC,CAAC;QAEH,OAAO;YACN,MAAM,EAAE,aAAW;YACnB,OAAO,EAAE,CAAC,WAAW,CAAC;YACtB,SAAS,EAAE;gBACV;oBACC,OAAO,EAAE,0BAAW;oBACpB,UAAU,CAAC,YAA0B;wBACpC,OAAO,YAAY,CAAC,SAAS,EAAE,CAAC;oBACjC,CAAC;oBACD,MAAM,EAAE,CAAC,2BAAY,CAAC;iBACtB;aACD;YACD,OAAO,EAAE,CAAC,0BAAW,CAAC;YACtB,MAAM,EAAE,IAAI;SACZ,CAAC;IACH,CAAC;CACD,CAAA;AAlCY,kCAAW;sBAAX,WAAW;IAFvB,IAAA,YAAM,GAAE;IACR,IAAA,YAAM,GAAE;GACI,WAAW,CAkCvB"}
|
package/dist-esm/index.d.ts
CHANGED
package/dist-esm/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":""}
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,cAAc,gBAAgB,CAAC;AAC/B,cAAc,gBAAgB,CAAC"}
|
package/dist-esm/index.js
CHANGED
package/dist-esm/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":""}
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,cAAc,gBAAgB,CAAC;AAC/B,cAAc,gBAAgB,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"redis.client.d.ts","sourceRoot":"","sources":["../src/redis.client.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,SAAS,CAAC;AAE5B,qBAAa,WAAY,SAAQ,KAAK;CAAG"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"redis.client.js","sourceRoot":"","sources":["../src/redis.client.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,SAAS,CAAC;AAE5B,MAAM,OAAO,WAAY,SAAQ,KAAK;CAAG"}
|
|
@@ -1,6 +1,5 @@
|
|
|
1
|
-
import { ConfigLoader } from '@hg-ts/config-loader';
|
|
2
1
|
import { DynamicModule } from '@hg-ts/ioc';
|
|
3
2
|
export declare class RedisModule {
|
|
4
|
-
static forRootAsync(
|
|
3
|
+
static forRootAsync(options: Pick<DynamicModule, 'imports'>): DynamicModule;
|
|
5
4
|
}
|
|
6
5
|
//# sourceMappingURL=redis.module.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"redis.module.d.ts","sourceRoot":"","sources":["../src/redis.module.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"redis.module.d.ts","sourceRoot":"","sources":["../src/redis.module.ts"],"names":[],"mappings":"AACA,OAAO,EACN,aAAa,EAGb,MAAM,YAAY,CAAC;AAWpB,qBAEa,WAAW;WACT,YAAY,CAAC,OAAO,EAAE,IAAI,CAAC,aAAa,EAAE,SAAS,CAAC,GAAG,aAAa;CAiClF"}
|
package/dist-esm/redis.module.js
CHANGED
|
@@ -1,12 +1,15 @@
|
|
|
1
1
|
var RedisModule_1;
|
|
2
2
|
import { __decorate } from "tslib";
|
|
3
|
+
import { ConfigLoader } from '@hg-ts/config-loader';
|
|
3
4
|
import { Global, Module, } from '@hg-ts/ioc';
|
|
4
|
-
import { RedisModule as RawRedisModule } from '@liaoliaots/nestjs-redis';
|
|
5
|
-
import { REDIS_CONFIG_SCHEMA
|
|
5
|
+
import { RedisModule as RawRedisModule, RedisService, } from '@liaoliaots/nestjs-redis';
|
|
6
|
+
import { REDIS_CONFIG_SCHEMA } from './config';
|
|
7
|
+
import { RedisClient } from './redis.client';
|
|
6
8
|
let RedisModule = RedisModule_1 = class RedisModule {
|
|
7
|
-
static forRootAsync(
|
|
9
|
+
static forRootAsync(options) {
|
|
8
10
|
const redisModule = RawRedisModule.forRootAsync({
|
|
9
|
-
|
|
11
|
+
...options,
|
|
12
|
+
async useFactory(configLoader) {
|
|
10
13
|
const config = await configLoader.load(REDIS_CONFIG_SCHEMA, 'redis');
|
|
11
14
|
return {
|
|
12
15
|
commonOptions: { enableReadyCheck: true },
|
|
@@ -17,12 +20,22 @@ let RedisModule = RedisModule_1 = class RedisModule {
|
|
|
17
20
|
},
|
|
18
21
|
};
|
|
19
22
|
},
|
|
20
|
-
inject: [
|
|
23
|
+
inject: [ConfigLoader],
|
|
21
24
|
});
|
|
22
25
|
return {
|
|
23
26
|
module: RedisModule_1,
|
|
24
27
|
imports: [redisModule],
|
|
25
|
-
|
|
28
|
+
providers: [
|
|
29
|
+
{
|
|
30
|
+
provide: RedisClient,
|
|
31
|
+
useFactory(redisService) {
|
|
32
|
+
return redisService.getClient();
|
|
33
|
+
},
|
|
34
|
+
inject: [RedisService],
|
|
35
|
+
},
|
|
36
|
+
],
|
|
37
|
+
exports: [RedisClient],
|
|
38
|
+
global: true,
|
|
26
39
|
};
|
|
27
40
|
}
|
|
28
41
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"redis.module.js","sourceRoot":"","sources":["../src/redis.module.ts"],"names":[],"mappings":";;
|
|
1
|
+
{"version":3,"file":"redis.module.js","sourceRoot":"","sources":["../src/redis.module.ts"],"names":[],"mappings":";;AAAA,OAAO,EAAE,YAAY,EAAE,MAAM,sBAAsB,CAAC;AACpD,OAAO,EAEN,MAAM,EACN,MAAM,GACN,MAAM,YAAY,CAAC;AAEpB,OAAO,EACN,WAAW,IAAI,cAAc,EAE7B,YAAY,GACZ,MAAM,0BAA0B,CAAC;AAElC,OAAO,EAAE,mBAAmB,EAAE,MAAM,UAAU,CAAC;AAC/C,OAAO,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAC;AAItC,IAAM,WAAW,mBAAjB,MAAM,WAAW;IAChB,MAAM,CAAC,YAAY,CAAC,OAAuC;QACjE,MAAM,WAAW,GAAG,cAAc,CAAC,YAAY,CAAC;YAC/C,GAAG,OAAO;YACV,KAAK,CAAC,UAAU,CAAC,YAA0B;gBAC1C,MAAM,MAAM,GAAG,MAAM,YAAY,CAAC,IAAI,CAAC,mBAAmB,EAAE,OAAO,CAAC,CAAC;gBACrE,OAAO;oBACN,aAAa,EAAE,EAAE,gBAAgB,EAAE,IAAI,EAAE;oBACzC,MAAM,EAAE;wBACP,IAAI,EAAE,MAAM,CAAC,IAAI;wBACjB,IAAI,EAAE,MAAM,CAAC,IAAI;wBACjB,EAAE,EAAE,MAAM,CAAC,QAAQ;qBACnB;iBACD,CAAC;YACH,CAAC;YACD,MAAM,EAAE,CAAC,YAAY,CAAC;SACtB,CAAC,CAAC;QAEH,OAAO;YACN,MAAM,EAAE,aAAW;YACnB,OAAO,EAAE,CAAC,WAAW,CAAC;YACtB,SAAS,EAAE;gBACV;oBACC,OAAO,EAAE,WAAW;oBACpB,UAAU,CAAC,YAA0B;wBACpC,OAAO,YAAY,CAAC,SAAS,EAAE,CAAC;oBACjC,CAAC;oBACD,MAAM,EAAE,CAAC,YAAY,CAAC;iBACtB;aACD;YACD,OAAO,EAAE,CAAC,WAAW,CAAC;YACtB,MAAM,EAAE,IAAI;SACZ,CAAC;IACH,CAAC;CACD,CAAA;AAlCY,WAAW;IAFvB,MAAM,EAAE;IACR,MAAM,EAAE;GACI,WAAW,CAkCvB"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@hg-ts/redis",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.19",
|
|
4
4
|
"main": "dist/index.js",
|
|
5
5
|
"module": "dist-esm/index.js",
|
|
6
6
|
"repository": "git@gitlab.com:hyper-graph/framework.git",
|
|
@@ -12,14 +12,14 @@
|
|
|
12
12
|
"lint:fix": "hg lint:fix"
|
|
13
13
|
},
|
|
14
14
|
"devDependencies": {
|
|
15
|
-
"@hg-ts-config/eslint-config": "0.1.
|
|
16
|
-
"@hg-ts-config/typescript": "0.1.
|
|
17
|
-
"@hg-ts/cli": "0.1.
|
|
18
|
-
"@hg-ts/config-loader": "0.1.
|
|
19
|
-
"@hg-ts/exception": "0.1.
|
|
20
|
-
"@hg-ts/ioc": "0.1.
|
|
21
|
-
"@hg-ts/types": "0.1.
|
|
22
|
-
"@hg-ts/validation": "0.1.
|
|
15
|
+
"@hg-ts-config/eslint-config": "0.1.19",
|
|
16
|
+
"@hg-ts-config/typescript": "0.1.19",
|
|
17
|
+
"@hg-ts/cli": "0.1.19",
|
|
18
|
+
"@hg-ts/config-loader": "0.1.19",
|
|
19
|
+
"@hg-ts/exception": "0.1.19",
|
|
20
|
+
"@hg-ts/ioc": "0.1.19",
|
|
21
|
+
"@hg-ts/types": "0.1.19",
|
|
22
|
+
"@hg-ts/validation": "0.1.19",
|
|
23
23
|
"@types/node": "20.8.7",
|
|
24
24
|
"@typescript-eslint/eslint-plugin": "6.8.0",
|
|
25
25
|
"@typescript-eslint/parser": "6.8.0",
|
|
@@ -31,9 +31,9 @@
|
|
|
31
31
|
"typescript": "5.2.2"
|
|
32
32
|
},
|
|
33
33
|
"peerDependencies": {
|
|
34
|
-
"@hg-ts/config-loader": "0.1.
|
|
35
|
-
"@hg-ts/ioc": "0.1.
|
|
36
|
-
"@hg-ts/validation": "0.1.
|
|
34
|
+
"@hg-ts/config-loader": "0.1.19",
|
|
35
|
+
"@hg-ts/ioc": "0.1.19",
|
|
36
|
+
"@hg-ts/validation": "0.1.19",
|
|
37
37
|
"reflect-metadata": "*",
|
|
38
38
|
"rxjs": "*",
|
|
39
39
|
"tslib": "*"
|
package/src/index.ts
CHANGED
package/src/redis.module.ts
CHANGED
|
@@ -5,19 +5,22 @@ import {
|
|
|
5
5
|
Module,
|
|
6
6
|
} from '@hg-ts/ioc';
|
|
7
7
|
|
|
8
|
-
import { RedisModule as RawRedisModule, RedisModuleOptions } from '@liaoliaots/nestjs-redis';
|
|
9
|
-
|
|
10
8
|
import {
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
9
|
+
RedisModule as RawRedisModule,
|
|
10
|
+
RedisModuleOptions,
|
|
11
|
+
RedisService,
|
|
12
|
+
} from '@liaoliaots/nestjs-redis';
|
|
13
|
+
|
|
14
|
+
import { REDIS_CONFIG_SCHEMA } from './config';
|
|
15
|
+
import { RedisClient } from './redis.client';
|
|
14
16
|
|
|
15
17
|
@Global()
|
|
16
18
|
@Module()
|
|
17
19
|
export class RedisModule {
|
|
18
|
-
public static forRootAsync(
|
|
20
|
+
public static forRootAsync(options: Pick<DynamicModule, 'imports'>): DynamicModule {
|
|
19
21
|
const redisModule = RawRedisModule.forRootAsync({
|
|
20
|
-
|
|
22
|
+
...options,
|
|
23
|
+
async useFactory(configLoader: ConfigLoader): Promise<RedisModuleOptions> {
|
|
21
24
|
const config = await configLoader.load(REDIS_CONFIG_SCHEMA, 'redis');
|
|
22
25
|
return {
|
|
23
26
|
commonOptions: { enableReadyCheck: true },
|
|
@@ -28,13 +31,23 @@ export class RedisModule {
|
|
|
28
31
|
},
|
|
29
32
|
};
|
|
30
33
|
},
|
|
31
|
-
inject: [
|
|
34
|
+
inject: [ConfigLoader],
|
|
32
35
|
});
|
|
33
36
|
|
|
34
37
|
return {
|
|
35
38
|
module: RedisModule,
|
|
36
39
|
imports: [redisModule],
|
|
37
|
-
|
|
40
|
+
providers: [
|
|
41
|
+
{
|
|
42
|
+
provide: RedisClient,
|
|
43
|
+
useFactory(redisService: RedisService): RedisClient {
|
|
44
|
+
return redisService.getClient();
|
|
45
|
+
},
|
|
46
|
+
inject: [RedisService],
|
|
47
|
+
},
|
|
48
|
+
],
|
|
49
|
+
exports: [RedisClient],
|
|
50
|
+
global: true,
|
|
38
51
|
};
|
|
39
52
|
}
|
|
40
53
|
}
|