lakutata 2.0.82 → 2.0.83
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/com/docker.cjs +1 -1
- package/com/docker.mjs +1 -1
- package/decorator/orm.cjs +84 -84
- package/decorator/orm.mjs +42 -128
- package/orm.cjs +871 -1408
- package/orm.mjs +712 -1462
- package/package.json +1 -1
- package/src/components/Database.cjs +2 -2
- package/src/components/Database.mjs +6 -6
- package/src/components/cacher/Cacher.cjs +129 -129
- package/src/components/cacher/Cacher.mjs +117 -117
- package/src/components/cacher/adapters/CreateFileCacheAdapter.cjs +303 -312
- package/src/components/cacher/adapters/CreateFileCacheAdapter.mjs +304 -313
- package/src/components/cacher/adapters/CreateMemcacheCacheAdapter.cjs +12 -12
- package/src/components/cacher/adapters/CreateMemcacheCacheAdapter.mjs +11 -11
- package/src/components/cacher/adapters/CreateMongoCacheAdapter.cjs +16 -16
- package/src/components/cacher/adapters/CreateMongoCacheAdapter.mjs +14 -14
- package/src/components/cacher/adapters/CreateMysqlCacheAdapter.cjs +11 -11
- package/src/components/cacher/adapters/CreateMysqlCacheAdapter.mjs +11 -11
- package/src/components/cacher/adapters/CreatePostgresCacheAdapter.cjs +12 -12
- package/src/components/cacher/adapters/CreatePostgresCacheAdapter.mjs +13 -13
- package/src/components/cacher/adapters/CreateRedisCacheAdapter.cjs +2 -2
- package/src/components/cacher/adapters/CreateRedisCacheAdapter.mjs +2 -2
- package/src/components/cacher/adapters/CreateSqliteCacheAdapter.cjs +10 -10
- package/src/components/cacher/adapters/CreateSqliteCacheAdapter.mjs +10 -10
- package/src/components/cacher/lib/IsDriverPackageInstalled.cjs +2 -2
- package/src/components/cacher/lib/IsDriverPackageInstalled.mjs +5 -5
- package/src/components/docker/ConnectionOptionsBuilder.cjs +11 -11
- package/src/components/docker/ConnectionOptionsBuilder.mjs +7 -7
- package/src/components/docker/Docker.cjs +5067 -4956
- package/src/components/docker/Docker.mjs +4982 -4871
- package/src/components/docker/lib/DockerContainer.cjs +1 -1
- package/src/components/docker/lib/DockerContainer.mjs +1 -1
- package/src/components/docker/lib/DockerContainerTTY.cjs +1 -1
- package/src/components/docker/lib/DockerContainerTTY.mjs +1 -1
- package/src/components/docker/lib/ParseEnvToRecord.cjs +2 -2
- package/src/components/docker/lib/ParseEnvToRecord.mjs +12 -12
- package/src/components/docker/lib/ParseRepositoryTag.cjs +9 -9
- package/src/components/docker/lib/ParseRepositoryTag.mjs +11 -11
- package/src/components/entrypoint/Entrypoint.cjs +1678 -2168
- package/src/components/entrypoint/Entrypoint.mjs +1680 -2170
- package/src/components/monitor/AliveMonitor.cjs +2 -2
- package/src/components/monitor/AliveMonitor.mjs +2 -2
- package/src/components/monitor/MemoryMonitor.cjs +3 -3
- package/src/decorators/asst/After.cjs +3 -3
- package/src/decorators/asst/After.mjs +2 -2
- package/src/decorators/asst/Before.cjs +2 -2
- package/src/decorators/asst/Before.mjs +4 -4
- package/src/decorators/ctrl/CLIAction.cjs +2 -2
- package/src/decorators/ctrl/CLIAction.mjs +7 -7
- package/src/decorators/ctrl/HTTPAction.cjs +6 -6
- package/src/decorators/ctrl/HTTPAction.mjs +4 -4
- package/src/decorators/ctrl/ServiceAction.cjs +3 -3
- package/src/decorators/ctrl/ServiceAction.mjs +4 -4
- package/src/decorators/ctrl/http/DELETE.cjs +2 -2
- package/src/decorators/ctrl/http/DELETE.mjs +2 -2
- package/src/decorators/ctrl/http/GET.cjs +2 -2
- package/src/decorators/ctrl/http/GET.mjs +2 -2
- package/src/decorators/ctrl/http/HEAD.cjs +2 -2
- package/src/decorators/ctrl/http/HEAD.mjs +2 -2
- package/src/decorators/ctrl/http/OPTIONS.cjs +2 -2
- package/src/decorators/ctrl/http/OPTIONS.mjs +2 -2
- package/src/decorators/ctrl/http/PATCH.cjs +2 -2
- package/src/decorators/ctrl/http/PATCH.mjs +2 -2
- package/src/decorators/ctrl/http/POST.cjs +2 -2
- package/src/decorators/ctrl/http/POST.mjs +2 -2
- package/src/decorators/ctrl/http/PUT.cjs +2 -2
- package/src/decorators/ctrl/http/PUT.mjs +2 -2
- package/src/decorators/di/Autoload.cjs +2 -2
- package/src/decorators/di/Autoload.mjs +2 -2
- package/src/decorators/di/Configurable.cjs +3 -3
- package/src/decorators/di/Configurable.mjs +2 -2
- package/src/decorators/di/Inject.cjs +6 -6
- package/src/decorators/di/Inject.mjs +11 -11
- package/src/decorators/di/Lifetime.cjs +18 -18
- package/src/decorators/di/Lifetime.mjs +13 -13
- package/src/decorators/dto/Accept.cjs +3 -3
- package/src/decorators/dto/Accept.mjs +2 -2
- package/src/decorators/dto/Expect.cjs +2 -2
- package/src/decorators/dto/Expect.mjs +3 -3
- package/src/decorators/dto/IndexSignature.cjs +2 -2
- package/src/decorators/dto/IndexSignature.mjs +3 -3
- package/src/decorators/dto/Return.cjs +3 -3
- package/src/decorators/dto/Return.mjs +2 -2
- package/src/decorators/orm/AfterInsert.cjs +26 -4
- package/src/decorators/orm/AfterInsert.mjs +25 -5
- package/src/decorators/orm/AfterLoad.cjs +26 -4
- package/src/decorators/orm/AfterLoad.mjs +25 -5
- package/src/decorators/orm/AfterRecover.cjs +26 -4
- package/src/decorators/orm/AfterRecover.mjs +25 -5
- package/src/decorators/orm/AfterRemove.cjs +26 -4
- package/src/decorators/orm/AfterRemove.mjs +25 -5
- package/src/decorators/orm/AfterSoftRemove.cjs +26 -4
- package/src/decorators/orm/AfterSoftRemove.mjs +25 -5
- package/src/decorators/orm/AfterUpdate.cjs +26 -4
- package/src/decorators/orm/AfterUpdate.mjs +25 -5
- package/src/decorators/orm/BeforeInsert.cjs +26 -4
- package/src/decorators/orm/BeforeInsert.mjs +25 -5
- package/src/decorators/orm/BeforeRecover.cjs +26 -4
- package/src/decorators/orm/BeforeRecover.mjs +25 -5
- package/src/decorators/orm/BeforeRemove.cjs +26 -4
- package/src/decorators/orm/BeforeRemove.mjs +25 -5
- package/src/decorators/orm/BeforeSoftRemove.cjs +26 -4
- package/src/decorators/orm/BeforeSoftRemove.mjs +25 -5
- package/src/decorators/orm/BeforeUpdate.cjs +26 -4
- package/src/decorators/orm/BeforeUpdate.mjs +25 -5
- package/src/decorators/orm/Check.cjs +29 -4
- package/src/decorators/orm/Check.mjs +28 -5
- package/src/decorators/orm/ChildEntity.cjs +29 -4
- package/src/decorators/orm/ChildEntity.mjs +28 -5
- package/src/decorators/orm/Column.cjs +61 -4
- package/src/decorators/orm/Column.mjs +61 -6
- package/src/decorators/orm/CreateDateColumn.cjs +25 -4
- package/src/decorators/orm/CreateDateColumn.mjs +24 -5
- package/src/decorators/orm/DeleteDateColumn.cjs +25 -4
- package/src/decorators/orm/DeleteDateColumn.mjs +23 -4
- package/src/decorators/orm/Entity.cjs +35 -4
- package/src/decorators/orm/Entity.mjs +33 -4
- package/src/decorators/orm/EventSubscriber.cjs +22 -4
- package/src/decorators/orm/EventSubscriber.mjs +21 -5
- package/src/decorators/orm/Exclusion.cjs +29 -4
- package/src/decorators/orm/Exclusion.mjs +28 -5
- package/src/decorators/orm/Generated.cjs +24 -4
- package/src/decorators/orm/Generated.mjs +23 -5
- package/src/decorators/orm/Index.cjs +41 -4
- package/src/decorators/orm/Index.mjs +41 -6
- package/src/decorators/orm/JoinColumn.cjs +29 -4
- package/src/decorators/orm/JoinColumn.mjs +28 -5
- package/src/decorators/orm/JoinTable.cjs +30 -4
- package/src/decorators/orm/JoinTable.mjs +28 -4
- package/src/decorators/orm/ManyToMany.cjs +42 -4
- package/src/decorators/orm/ManyToMany.mjs +40 -4
- package/src/decorators/orm/ManyToOne.cjs +42 -4
- package/src/decorators/orm/ManyToOne.mjs +40 -4
- package/src/decorators/orm/ObjectIdColumn.cjs +28 -4
- package/src/decorators/orm/ObjectIdColumn.mjs +27 -5
- package/src/decorators/orm/OneToMany.cjs +34 -4
- package/src/decorators/orm/OneToMany.mjs +34 -6
- package/src/decorators/orm/OneToOne.cjs +42 -4
- package/src/decorators/orm/OneToOne.mjs +40 -4
- package/src/decorators/orm/PrimaryColumn.cjs +49 -4
- package/src/decorators/orm/PrimaryColumn.mjs +49 -6
- package/src/decorators/orm/PrimaryGeneratedColumn.cjs +54 -4
- package/src/decorators/orm/PrimaryGeneratedColumn.mjs +54 -6
- package/src/decorators/orm/RelationId.cjs +26 -4
- package/src/decorators/orm/RelationId.mjs +25 -5
- package/src/decorators/orm/TableInheritance.cjs +26 -4
- package/src/decorators/orm/TableInheritance.mjs +25 -5
- package/src/decorators/orm/Tree.cjs +24 -4
- package/src/decorators/orm/Tree.mjs +23 -5
- package/src/decorators/orm/TreeChildren.cjs +31 -4
- package/src/decorators/orm/TreeChildren.mjs +29 -4
- package/src/decorators/orm/TreeLevelColumn.cjs +25 -4
- package/src/decorators/orm/TreeLevelColumn.mjs +23 -4
- package/src/decorators/orm/TreeParent.cjs +31 -4
- package/src/decorators/orm/TreeParent.mjs +29 -4
- package/src/decorators/orm/Unique.cjs +44 -4
- package/src/decorators/orm/Unique.mjs +44 -6
- package/src/decorators/orm/UpdateDateColumn.cjs +25 -4
- package/src/decorators/orm/UpdateDateColumn.mjs +24 -5
- package/src/decorators/orm/VersionColumn.cjs +25 -4
- package/src/decorators/orm/VersionColumn.mjs +24 -5
- package/src/decorators/orm/ViewColumn.cjs +25 -4
- package/src/decorators/orm/ViewColumn.mjs +24 -5
- package/src/decorators/orm/ViewEntity.cjs +34 -4
- package/src/decorators/orm/ViewEntity.mjs +33 -5
- package/src/decorators/orm/VirtualColumn.cjs +42 -4
- package/src/decorators/orm/VirtualColumn.mjs +40 -4
- package/src/lib/base/EventEmitter.cjs +1195 -1202
- package/src/lib/base/EventEmitter.mjs +1195 -1202
- package/src/lib/base/async-constructor/Append.cjs +11 -11
- package/src/lib/base/async-constructor/Append.mjs +7 -7
- package/src/lib/base/internal/BasicInfo.cjs +10 -10
- package/src/lib/base/internal/BasicInfo.mjs +9 -9
- package/src/lib/base/internal/CamelCase.cjs +4 -4
- package/src/lib/base/internal/CamelCase.mjs +11 -11
- package/src/lib/base/internal/ConfigurableRecordsInjection.cjs +19 -19
- package/src/lib/base/internal/ConfigurableRecordsInjection.mjs +18 -18
- package/src/lib/base/internal/ConstructorSymbol.cjs +10 -10
- package/src/lib/base/internal/ConstructorSymbol.mjs +8 -8
- package/src/lib/base/internal/ControllerEntrypoint.cjs +65 -65
- package/src/lib/base/internal/ControllerEntrypoint.mjs +36 -36
- package/src/lib/base/internal/DataValidator.cjs +185 -174
- package/src/lib/base/internal/DataValidator.mjs +230 -219
- package/src/lib/base/internal/GetActionDTOAndOptions.cjs +9 -9
- package/src/lib/base/internal/GetActionDTOAndOptions.mjs +10 -10
- package/src/lib/base/internal/IEEE754.cjs +74 -74
- package/src/lib/base/internal/IEEE754.mjs +70 -70
- package/src/lib/base/internal/MethodAssistantFunction.cjs +28 -28
- package/src/lib/base/internal/MethodAssistantFunction.mjs +38 -38
- package/src/lib/base/internal/MethodValidation.cjs +25 -25
- package/src/lib/base/internal/MethodValidation.mjs +20 -20
- package/src/lib/base/internal/ObjectConfiguration.cjs +10 -10
- package/src/lib/base/internal/ObjectConfiguration.mjs +15 -15
- package/src/lib/base/internal/ObjectContainer.cjs +7 -7
- package/src/lib/base/internal/ObjectContainer.mjs +6 -6
- package/src/lib/base/internal/ObjectInjection.cjs +16 -16
- package/src/lib/base/internal/ObjectInjection.mjs +13 -13
- package/src/lib/base/internal/ObjectLifetime.cjs +10 -10
- package/src/lib/base/internal/ObjectLifetime.mjs +9 -9
- package/src/lib/base/internal/ObjectWeakRefs.cjs +11 -11
- package/src/lib/base/internal/ObjectWeakRefs.mjs +9 -9
- package/src/lib/base/internal/PatternManager.cjs +739 -744
- package/src/lib/base/internal/PatternManager.mjs +743 -748
- package/src/lib/base/internal/StringifyPattern.cjs +26 -26
- package/src/lib/base/internal/StringifyPattern.mjs +26 -26
- package/src/lib/base/internal/ThrowWarning.cjs +2 -2
- package/src/lib/base/internal/ThrowWarning.mjs +2 -2
- package/src/lib/core/Alias.cjs +5 -5
- package/src/lib/core/Application.cjs +115 -128
- package/src/lib/core/Application.mjs +135 -148
- package/src/lib/helpers/ArrayToSet.cjs +2 -2
- package/src/lib/helpers/ArrayToSet.mjs +3 -3
- package/src/lib/helpers/As.cjs +2 -2
- package/src/lib/helpers/As.mjs +2 -2
- package/src/lib/helpers/ConvertArrayLikeToIterable.cjs +3 -3
- package/src/lib/helpers/ConvertArrayLikeToIterable.mjs +3 -3
- package/src/lib/helpers/ConvertArrayLikeToStream.cjs +2 -2
- package/src/lib/helpers/ConvertArrayLikeToStream.mjs +2 -2
- package/src/lib/helpers/Delay.cjs +2 -2
- package/src/lib/helpers/Delay.mjs +2 -2
- package/src/lib/helpers/DevNull.cjs +2 -2
- package/src/lib/helpers/DevNull.mjs +2 -2
- package/src/lib/helpers/GetObjectNestingDepth.cjs +12 -12
- package/src/lib/helpers/GetObjectNestingDepth.mjs +11 -11
- package/src/lib/helpers/GetObjectPropertyPaths.cjs +7 -7
- package/src/lib/helpers/GetObjectPropertyPaths.mjs +9 -9
- package/src/lib/helpers/Glob.cjs +890 -890
- package/src/lib/helpers/Glob.mjs +889 -889
- package/src/lib/helpers/GraceExit.cjs +3 -3
- package/src/lib/helpers/GraceExit.mjs +7 -7
- package/src/lib/helpers/HexToIEEE754.cjs +4 -4
- package/src/lib/helpers/HexToIEEE754.mjs +2 -2
- package/src/lib/helpers/HexToSigned.cjs +5 -5
- package/src/lib/helpers/HexToSigned.mjs +4 -4
- package/src/lib/helpers/HexToUnsigned.cjs +2 -2
- package/src/lib/helpers/HexToUnsigned.mjs +2 -2
- package/src/lib/helpers/IEEE754ToHex.cjs +5 -5
- package/src/lib/helpers/IEEE754ToHex.mjs +5 -5
- package/src/lib/helpers/IsAbortError.cjs +2 -2
- package/src/lib/helpers/IsAbortError.mjs +3 -3
- package/src/lib/helpers/IsEmptyObject.cjs +3 -3
- package/src/lib/helpers/IsEmptyObject.mjs +3 -3
- package/src/lib/helpers/IsExists.cjs +5 -5
- package/src/lib/helpers/IsExists.mjs +4 -4
- package/src/lib/helpers/IsHtml.cjs +8 -18
- package/src/lib/helpers/IsHtml.mjs +8 -18
- package/src/lib/helpers/IsNativeFunction.cjs +2 -2
- package/src/lib/helpers/IsNativeFunction.mjs +2 -2
- package/src/lib/helpers/IsPath.cjs +2 -2
- package/src/lib/helpers/IsPath.mjs +5 -5
- package/src/lib/helpers/IsPromise.cjs +2 -2
- package/src/lib/helpers/IsPromise.mjs +2 -2
- package/src/lib/helpers/IsPromiseLike.cjs +5 -5
- package/src/lib/helpers/IsPromiseLike.mjs +6 -6
- package/src/lib/helpers/IsXML.cjs +1531 -1525
- package/src/lib/helpers/IsXML.mjs +1527 -1521
- package/src/lib/helpers/MD5.cjs +2 -2
- package/src/lib/helpers/MD5.mjs +2 -2
- package/src/lib/helpers/MergeArray.cjs +3 -3
- package/src/lib/helpers/MergeArray.mjs +3 -3
- package/src/lib/helpers/MergeMap.cjs +3 -3
- package/src/lib/helpers/MergeMap.mjs +3 -3
- package/src/lib/helpers/MergeSet.cjs +2 -2
- package/src/lib/helpers/MergeSet.mjs +3 -3
- package/src/lib/helpers/NoCase.cjs +27 -27
- package/src/lib/helpers/NoCase.mjs +24 -24
- package/src/lib/helpers/NonceStr.cjs +2 -2
- package/src/lib/helpers/NonceStr.mjs +2 -2
- package/src/lib/helpers/ObjectConstructor.cjs +2 -2
- package/src/lib/helpers/ObjectConstructor.mjs +4 -4
- package/src/lib/helpers/ObjectHash.cjs +377 -384
- package/src/lib/helpers/ObjectHash.mjs +373 -380
- package/src/lib/helpers/ObjectParentConstructor.cjs +2 -2
- package/src/lib/helpers/ObjectParentConstructor.mjs +5 -5
- package/src/lib/helpers/ObjectParentConstructors.cjs +6 -6
- package/src/lib/helpers/ObjectParentConstructors.mjs +2 -2
- package/src/lib/helpers/ObjectPrototype.cjs +2 -2
- package/src/lib/helpers/ObjectPrototype.mjs +2 -2
- package/src/lib/helpers/ObjectToMap.cjs +2 -2
- package/src/lib/helpers/ObjectToMap.mjs +3 -3
- package/src/lib/helpers/Paginator.cjs +2 -2
- package/src/lib/helpers/Paginator.mjs +6 -6
- package/src/lib/helpers/RandomString.cjs +148 -169
- package/src/lib/helpers/RandomString.mjs +145 -166
- package/src/lib/helpers/SHA1.cjs +2 -2
- package/src/lib/helpers/SHA1.mjs +2 -2
- package/src/lib/helpers/SHA256.cjs +2 -2
- package/src/lib/helpers/SHA256.mjs +2 -2
- package/src/lib/helpers/SetToArray.cjs +2 -2
- package/src/lib/helpers/SetToArray.mjs +2 -2
- package/src/lib/helpers/SignedToHex.cjs +4 -4
- package/src/lib/helpers/SignedToHex.mjs +4 -4
- package/src/lib/helpers/SortArray.cjs +16 -16
- package/src/lib/helpers/SortArray.mjs +15 -15
- package/src/lib/helpers/SortKeys.cjs +41 -41
- package/src/lib/helpers/SortKeys.mjs +41 -41
- package/src/lib/helpers/SortObject.cjs +2 -2
- package/src/lib/helpers/SortObject.mjs +2 -2
- package/src/lib/helpers/Templating.cjs +25 -25
- package/src/lib/helpers/Templating.mjs +25 -25
- package/src/lib/helpers/URLBuilder.cjs +355 -355
- package/src/lib/helpers/URLBuilder.mjs +349 -349
- package/src/lib/helpers/UniqueArray.cjs +3 -3
- package/src/lib/helpers/UniqueArray.mjs +2 -2
- package/src/lib/helpers/UnsignedToHex.cjs +3 -3
- package/src/lib/helpers/UnsignedToHex.mjs +3 -3
- package/src/lib/ioc/DependencyInjectionContainer.cjs +106 -106
- package/src/lib/ioc/DependencyInjectionContainer.mjs +122 -122
- package/src/lib/ioc/FunctionTokenizer.cjs +115 -115
- package/src/lib/ioc/FunctionTokenizer.mjs +102 -102
- package/src/lib/ioc/Lifetime.cjs +5 -5
- package/src/lib/ioc/Lifetime.mjs +5 -5
- package/src/lib/ioc/ListModules.cjs +5298 -5221
- package/src/lib/ioc/ListModules.mjs +5258 -5181
- package/src/lib/ioc/LoadModules.cjs +56 -56
- package/src/lib/ioc/LoadModules.mjs +69 -69
- package/src/lib/ioc/ParamParser.cjs +30 -30
- package/src/lib/ioc/ParamParser.mjs +41 -41
- package/src/lib/ioc/Resolvers.cjs +87 -87
- package/src/lib/ioc/Resolvers.mjs +109 -109
- package/src/lib/ioc/Utils.cjs +12 -12
- package/src/lib/ioc/Utils.mjs +18 -18
- package/src/lib/validation/VLD.cjs +4025 -4202
- package/src/lib/validation/VLD.mjs +2972 -3149
- package/src/providers/Database.cjs +2 -2
- package/src/providers/Database.mjs +7 -7
- package/src/providers/PasswordHash.cjs +330 -330
- package/src/providers/PasswordHash.mjs +397 -397
- package/src/providers/migration/GenerateMigration.cjs +2 -2
- package/src/providers/migration/GenerateMigration.mjs +2 -2
- package/vendor/Package.1.cjs +256 -256
- package/vendor/Package.1.mjs +254 -254
- package/vendor/Package.112.cjs +42157 -42076
- package/vendor/Package.112.mjs +42222 -42081
- package/vendor/Package.13.cjs +36 -36
- package/vendor/Package.13.mjs +24 -24
- package/vendor/Package.16.cjs +12351 -12233
- package/vendor/Package.16.mjs +12348 -12230
- package/vendor/Package.17.cjs +924 -924
- package/vendor/Package.17.mjs +943 -943
- package/vendor/Package.18.cjs +48229 -20
- package/vendor/Package.18.mjs +48192 -24
- package/vendor/Package.2.cjs +5824 -5853
- package/vendor/Package.2.mjs +5780 -5809
- package/vendor/Package.3.cjs +60 -60
- package/vendor/Package.3.mjs +85 -85
- package/vendor/Package.4.cjs +874 -884
- package/vendor/Package.4.mjs +877 -887
- package/vendor/Package.5.cjs +15 -19
- package/vendor/Package.5.mjs +10 -14
- package/vendor/Package.6.cjs +2058 -2067
- package/vendor/Package.6.mjs +2064 -2073
- package/vendor/Package.610.cjs +9 -9
- package/vendor/Package.611.cjs +39 -39
- package/vendor/Package.611.mjs +22 -22
- package/vendor/Package.612.cjs +33 -33
- package/vendor/Package.612.mjs +17 -17
- package/vendor/Package.613.cjs +62 -62
- package/vendor/Package.613.mjs +29 -29
- package/vendor/Package.62.cjs +295 -298
- package/vendor/Package.62.mjs +278 -281
- package/vendor/Package.63.cjs +354 -354
- package/vendor/Package.63.mjs +229 -229
- package/vendor/Package.64.cjs +74 -74
- package/vendor/Package.64.mjs +74 -74
- package/vendor/Package.65.cjs +1851 -1858
- package/vendor/Package.65.mjs +1693 -1700
- package/vendor/Package.66.cjs +16 -16
- package/vendor/Package.66.mjs +16 -16
- package/vendor/Package.67.cjs +87 -87
- package/vendor/Package.67.mjs +85 -85
- package/vendor/Package.68.cjs +14 -14
- package/vendor/Package.68.mjs +6 -6
- package/vendor/Package.69.cjs +8 -8
- package/vendor/Package.7.cjs +3 -3
- package/vendor/Package.7.mjs +3 -3
- package/vendor/Package.9.cjs +124 -138
- package/vendor/Package.9.mjs +121 -135
- package/vendor/TypeDef.internal.3.d.ts +0 -14
- package/vendor/Package.19.cjs +0 -37
- package/vendor/Package.19.mjs +0 -35
- package/vendor/Package.20.cjs +0 -37
- package/vendor/Package.20.mjs +0 -35
- package/vendor/Package.21.cjs +0 -37
- package/vendor/Package.21.mjs +0 -35
- package/vendor/Package.22.cjs +0 -37
- package/vendor/Package.22.mjs +0 -35
- package/vendor/Package.23.cjs +0 -37
- package/vendor/Package.23.mjs +0 -35
- package/vendor/Package.24.cjs +0 -37
- package/vendor/Package.24.mjs +0 -35
- package/vendor/Package.25.cjs +0 -37
- package/vendor/Package.25.mjs +0 -35
- package/vendor/Package.26.cjs +0 -37
- package/vendor/Package.26.mjs +0 -35
- package/vendor/Package.27.cjs +0 -37
- package/vendor/Package.27.mjs +0 -35
- package/vendor/Package.28.cjs +0 -37
- package/vendor/Package.28.mjs +0 -35
- package/vendor/Package.29.cjs +0 -40
- package/vendor/Package.29.mjs +0 -38
- package/vendor/Package.30.cjs +0 -41
- package/vendor/Package.30.mjs +0 -39
- package/vendor/Package.31.cjs +0 -72
- package/vendor/Package.31.mjs +0 -70
- package/vendor/Package.32.cjs +0 -37
- package/vendor/Package.32.mjs +0 -35
- package/vendor/Package.33.cjs +0 -37
- package/vendor/Package.33.mjs +0 -35
- package/vendor/Package.34.cjs +0 -46
- package/vendor/Package.34.mjs +0 -44
- package/vendor/Package.35.cjs +0 -34
- package/vendor/Package.35.mjs +0 -32
- package/vendor/Package.36.cjs +0 -40
- package/vendor/Package.36.mjs +0 -38
- package/vendor/Package.37.cjs +0 -36
- package/vendor/Package.37.mjs +0 -34
- package/vendor/Package.38.cjs +0 -52
- package/vendor/Package.38.mjs +0 -50
- package/vendor/Package.39.cjs +0 -41
- package/vendor/Package.39.mjs +0 -39
- package/vendor/Package.40.cjs +0 -42
- package/vendor/Package.40.mjs +0 -40
- package/vendor/Package.41.cjs +0 -53
- package/vendor/Package.41.mjs +0 -51
- package/vendor/Package.42.cjs +0 -53
- package/vendor/Package.42.mjs +0 -51
- package/vendor/Package.43.cjs +0 -40
- package/vendor/Package.43.mjs +0 -38
- package/vendor/Package.44.cjs +0 -46
- package/vendor/Package.44.mjs +0 -44
- package/vendor/Package.45.cjs +0 -53
- package/vendor/Package.45.mjs +0 -51
- package/vendor/Package.46.cjs +0 -59
- package/vendor/Package.46.mjs +0 -57
- package/vendor/Package.47.cjs +0 -65
- package/vendor/Package.47.mjs +0 -63
- package/vendor/Package.48.cjs +0 -38
- package/vendor/Package.48.mjs +0 -36
- package/vendor/Package.49.cjs +0 -38
- package/vendor/Package.49.mjs +0 -36
- package/vendor/Package.50.cjs +0 -36
- package/vendor/Package.50.mjs +0 -34
- package/vendor/Package.51.cjs +0 -43
- package/vendor/Package.51.mjs +0 -41
- package/vendor/Package.52.cjs +0 -37
- package/vendor/Package.52.mjs +0 -35
- package/vendor/Package.53.cjs +0 -43
- package/vendor/Package.53.mjs +0 -41
- package/vendor/Package.54.cjs +0 -55
- package/vendor/Package.54.mjs +0 -53
- package/vendor/Package.55.cjs +0 -37
- package/vendor/Package.55.mjs +0 -35
- package/vendor/Package.56.cjs +0 -37
- package/vendor/Package.56.mjs +0 -35
- package/vendor/Package.57.cjs +0 -37
- package/vendor/Package.57.mjs +0 -35
- package/vendor/Package.58.cjs +0 -45
- package/vendor/Package.58.mjs +0 -43
- package/vendor/Package.59.cjs +0 -53
- package/vendor/Package.59.mjs +0 -51
- package/vendor/Package.60.cjs +0 -47649
- package/vendor/Package.60.mjs +0 -47606
|
@@ -22,9 +22,9 @@ import { CreateMongoCacheAdapter as m } from "./adapters/CreateMongoCacheAdapter
|
|
|
22
22
|
|
|
23
23
|
import { CreateSqliteCacheAdapter as u } from "./adapters/CreateSqliteCacheAdapter.mjs";
|
|
24
24
|
|
|
25
|
-
import { CreatePostgresCacheAdapter as
|
|
25
|
+
import { CreatePostgresCacheAdapter as f } from "./adapters/CreatePostgresCacheAdapter.mjs";
|
|
26
26
|
|
|
27
|
-
import { CreateMysqlCacheAdapter as
|
|
27
|
+
import { CreateMysqlCacheAdapter as d } from "./adapters/CreateMysqlCacheAdapter.mjs";
|
|
28
28
|
|
|
29
29
|
import { D as p } from "../../../vendor/Package.2.mjs";
|
|
30
30
|
|
|
@@ -306,7 +306,7 @@ var x = class {
|
|
|
306
306
|
}
|
|
307
307
|
};
|
|
308
308
|
|
|
309
|
-
var
|
|
309
|
+
var P = class {
|
|
310
310
|
_seed;
|
|
311
311
|
constructor(e = 0) {
|
|
312
312
|
this._seed = e >>> 0;
|
|
@@ -388,7 +388,7 @@ var C = class {
|
|
|
388
388
|
}
|
|
389
389
|
};
|
|
390
390
|
|
|
391
|
-
var
|
|
391
|
+
var z = class {
|
|
392
392
|
_providers=new Map;
|
|
393
393
|
_getFuzzy=true;
|
|
394
394
|
constructor(e) {
|
|
@@ -435,10 +435,10 @@ var P = class {
|
|
|
435
435
|
}
|
|
436
436
|
};
|
|
437
437
|
|
|
438
|
-
var
|
|
438
|
+
var C = class extends s {
|
|
439
439
|
_parse=JSON.parse;
|
|
440
440
|
_stringify=JSON.stringify;
|
|
441
|
-
_providers=new
|
|
441
|
+
_providers=new z;
|
|
442
442
|
_defaultAlgorithm="SHA-256";
|
|
443
443
|
_defaultAlgorithmSync="djb2";
|
|
444
444
|
constructor(e) {
|
|
@@ -599,12 +599,12 @@ var z = class extends s {
|
|
|
599
599
|
this.providers.add(new S);
|
|
600
600
|
this.providers.add(new k);
|
|
601
601
|
this.providers.add(new x);
|
|
602
|
-
this.providers.add(new
|
|
602
|
+
this.providers.add(new P);
|
|
603
603
|
}
|
|
604
604
|
}
|
|
605
605
|
};
|
|
606
606
|
|
|
607
|
-
var
|
|
607
|
+
var H = e => {
|
|
608
608
|
let t;
|
|
609
609
|
if (e === void 0) {
|
|
610
610
|
return void 0;
|
|
@@ -673,58 +673,58 @@ var shorthandToMilliseconds = e => {
|
|
|
673
673
|
return t;
|
|
674
674
|
};
|
|
675
675
|
|
|
676
|
-
var
|
|
676
|
+
var O = (e, t) => {
|
|
677
677
|
t ??= new Date;
|
|
678
|
-
const r =
|
|
678
|
+
const r = H(e);
|
|
679
679
|
if (r === void 0) {
|
|
680
680
|
return t.getTime();
|
|
681
681
|
}
|
|
682
682
|
return t.getTime() + r;
|
|
683
683
|
};
|
|
684
684
|
|
|
685
|
-
var
|
|
685
|
+
var L = new Map;
|
|
686
686
|
|
|
687
|
-
function
|
|
688
|
-
return
|
|
687
|
+
function M(e) {
|
|
688
|
+
return L.has(e);
|
|
689
689
|
}
|
|
690
690
|
|
|
691
|
-
function
|
|
692
|
-
|
|
691
|
+
function I(e) {
|
|
692
|
+
L.set(e, []);
|
|
693
693
|
}
|
|
694
694
|
|
|
695
|
-
function
|
|
696
|
-
|
|
695
|
+
function N(e) {
|
|
696
|
+
L.delete(e);
|
|
697
697
|
}
|
|
698
698
|
|
|
699
|
-
function
|
|
700
|
-
const r =
|
|
699
|
+
function E(e, t) {
|
|
700
|
+
const r = U(e);
|
|
701
701
|
r.push(t);
|
|
702
|
-
|
|
702
|
+
L.set(e, r);
|
|
703
703
|
}
|
|
704
704
|
|
|
705
|
-
function
|
|
706
|
-
return
|
|
705
|
+
function U(e) {
|
|
706
|
+
return L.get(e) ?? [];
|
|
707
707
|
}
|
|
708
708
|
|
|
709
|
-
async function
|
|
709
|
+
async function B(e) {
|
|
710
710
|
return new Promise(((t, r) => {
|
|
711
711
|
const s = {
|
|
712
712
|
resolve: t,
|
|
713
713
|
reject: r
|
|
714
714
|
};
|
|
715
|
-
|
|
715
|
+
E(e, s);
|
|
716
716
|
}));
|
|
717
717
|
}
|
|
718
718
|
|
|
719
|
-
function
|
|
720
|
-
const t =
|
|
721
|
-
|
|
719
|
+
function D(e) {
|
|
720
|
+
const t = U(e);
|
|
721
|
+
N(e);
|
|
722
722
|
return t;
|
|
723
723
|
}
|
|
724
724
|
|
|
725
|
-
function
|
|
725
|
+
function $(e) {
|
|
726
726
|
const {key: t, error: r, result: s} = e;
|
|
727
|
-
for (const e of
|
|
727
|
+
for (const e of D(t)) {
|
|
728
728
|
if (r) {
|
|
729
729
|
e.reject(r);
|
|
730
730
|
} else {
|
|
@@ -733,28 +733,28 @@ function coalesce(e) {
|
|
|
733
733
|
}
|
|
734
734
|
}
|
|
735
735
|
|
|
736
|
-
async function
|
|
737
|
-
if (!
|
|
738
|
-
|
|
736
|
+
async function T(e, t) {
|
|
737
|
+
if (!M(e)) {
|
|
738
|
+
I(e);
|
|
739
739
|
try {
|
|
740
740
|
const r = await Promise.resolve(t());
|
|
741
|
-
|
|
741
|
+
$({
|
|
742
742
|
key: e,
|
|
743
743
|
result: r
|
|
744
744
|
});
|
|
745
745
|
return r;
|
|
746
746
|
} catch (t) {
|
|
747
|
-
|
|
747
|
+
$({
|
|
748
748
|
key: e,
|
|
749
749
|
error: t
|
|
750
750
|
});
|
|
751
751
|
throw t;
|
|
752
752
|
}
|
|
753
753
|
}
|
|
754
|
-
return
|
|
754
|
+
return B(e);
|
|
755
755
|
}
|
|
756
756
|
|
|
757
|
-
var
|
|
757
|
+
var F = (e => {
|
|
758
758
|
e["SHA256"] = "SHA-256";
|
|
759
759
|
e["SHA384"] = "SHA-384";
|
|
760
760
|
e["SHA512"] = "SHA-512";
|
|
@@ -763,35 +763,35 @@ var O = (e => {
|
|
|
763
763
|
e["MURMER"] = "murmer";
|
|
764
764
|
e["CRC32"] = "crc32";
|
|
765
765
|
return e;
|
|
766
|
-
})(
|
|
766
|
+
})(F || {});
|
|
767
767
|
|
|
768
|
-
async function
|
|
768
|
+
async function V(e, t = {
|
|
769
769
|
algorithm: "SHA-256",
|
|
770
770
|
serialize: JSON.stringify
|
|
771
771
|
}) {
|
|
772
772
|
const r = t?.algorithm ?? "SHA-256";
|
|
773
773
|
const s = t?.serialize ?? JSON.stringify;
|
|
774
774
|
const i = s(e);
|
|
775
|
-
const n = new
|
|
775
|
+
const n = new C;
|
|
776
776
|
return n.toHash(i, {
|
|
777
777
|
algorithm: r
|
|
778
778
|
});
|
|
779
779
|
}
|
|
780
780
|
|
|
781
|
-
function
|
|
781
|
+
function J(e, t = {
|
|
782
782
|
algorithm: "djb2",
|
|
783
783
|
serialize: JSON.stringify
|
|
784
784
|
}) {
|
|
785
785
|
const r = t?.algorithm ?? "djb2";
|
|
786
786
|
const s = t?.serialize ?? JSON.stringify;
|
|
787
787
|
const i = s(e);
|
|
788
|
-
const n = new
|
|
788
|
+
const n = new C;
|
|
789
789
|
return n.toHashSync(i, {
|
|
790
790
|
algorithm: r
|
|
791
791
|
});
|
|
792
792
|
}
|
|
793
793
|
|
|
794
|
-
async function
|
|
794
|
+
async function R(e, t = {
|
|
795
795
|
min: 0,
|
|
796
796
|
max: 10,
|
|
797
797
|
algorithm: "SHA-256",
|
|
@@ -806,7 +806,7 @@ async function hashToNumber(e, t = {
|
|
|
806
806
|
throw new Error(`Invalid range: min (${r}) must be less than max (${s})`);
|
|
807
807
|
}
|
|
808
808
|
const a = n(e);
|
|
809
|
-
const c = new
|
|
809
|
+
const c = new C;
|
|
810
810
|
return c.toNumber(a, {
|
|
811
811
|
algorithm: i,
|
|
812
812
|
min: r,
|
|
@@ -815,7 +815,7 @@ async function hashToNumber(e, t = {
|
|
|
815
815
|
});
|
|
816
816
|
}
|
|
817
817
|
|
|
818
|
-
function
|
|
818
|
+
function K(e, t = {
|
|
819
819
|
min: 0,
|
|
820
820
|
max: 10,
|
|
821
821
|
algorithm: "djb2",
|
|
@@ -830,7 +830,7 @@ function hashToNumberSync(e, t = {
|
|
|
830
830
|
throw new Error(`Invalid range: min (${r}) must be less than max (${s})`);
|
|
831
831
|
}
|
|
832
832
|
const a = n(e);
|
|
833
|
-
const c = new
|
|
833
|
+
const c = new C;
|
|
834
834
|
return c.toNumberSync(a, {
|
|
835
835
|
algorithm: i,
|
|
836
836
|
min: r,
|
|
@@ -839,7 +839,7 @@ function hashToNumberSync(e, t = {
|
|
|
839
839
|
});
|
|
840
840
|
}
|
|
841
841
|
|
|
842
|
-
function
|
|
842
|
+
function q(e) {
|
|
843
843
|
if (e === null || e === void 0) {
|
|
844
844
|
return false;
|
|
845
845
|
}
|
|
@@ -850,18 +850,18 @@ function isKeyvInstance(e) {
|
|
|
850
850
|
return t.every((t => typeof e[t] === "function"));
|
|
851
851
|
}
|
|
852
852
|
|
|
853
|
-
function
|
|
853
|
+
function G(e) {
|
|
854
854
|
return e !== null && typeof e === "object" && !Array.isArray(e);
|
|
855
855
|
}
|
|
856
856
|
|
|
857
|
-
function
|
|
857
|
+
function W(e, t) {
|
|
858
858
|
return typeof e === "number" && typeof t === "number" ? e < t : false;
|
|
859
859
|
}
|
|
860
860
|
|
|
861
|
-
function
|
|
861
|
+
function X(e, t) {
|
|
862
862
|
const {ttl: r, keyPrefix: s, cache: i, serialize: n} = t;
|
|
863
863
|
return (...o) => {
|
|
864
|
-
let a =
|
|
864
|
+
let a = Z(e, o, {
|
|
865
865
|
keyPrefix: s,
|
|
866
866
|
serialize: n
|
|
867
867
|
});
|
|
@@ -884,13 +884,13 @@ function wrapSync(e, t) {
|
|
|
884
884
|
};
|
|
885
885
|
}
|
|
886
886
|
|
|
887
|
-
async function
|
|
887
|
+
async function Q(e, t, r) {
|
|
888
888
|
const s = typeof e === "function" ? e(r) : e;
|
|
889
889
|
let i = await r.cache.get(s);
|
|
890
890
|
if (i === void 0) {
|
|
891
891
|
const e = r.cacheId ?? "default";
|
|
892
892
|
const n = `${e}::${s}`;
|
|
893
|
-
i = await
|
|
893
|
+
i = await T(n, (async () => {
|
|
894
894
|
try {
|
|
895
895
|
const e = await t();
|
|
896
896
|
await r.cache.set(s, e, r.ttl);
|
|
@@ -909,39 +909,39 @@ async function getOrSet(e, t, r) {
|
|
|
909
909
|
return i;
|
|
910
910
|
}
|
|
911
911
|
|
|
912
|
-
function
|
|
912
|
+
function Y(e, t) {
|
|
913
913
|
const {keyPrefix: r, serialize: s} = t;
|
|
914
914
|
return async (...i) => {
|
|
915
|
-
let n =
|
|
915
|
+
let n = Z(e, i, {
|
|
916
916
|
keyPrefix: r,
|
|
917
917
|
serialize: s
|
|
918
918
|
});
|
|
919
919
|
if (t.createKey) {
|
|
920
920
|
n = t.createKey(e, i, t);
|
|
921
921
|
}
|
|
922
|
-
return
|
|
922
|
+
return Q(n, (async () => e(...i)), t);
|
|
923
923
|
};
|
|
924
924
|
}
|
|
925
925
|
|
|
926
|
-
function
|
|
926
|
+
function Z(e, t, r) {
|
|
927
927
|
const {keyPrefix: s, serialize: i} = r || {};
|
|
928
928
|
if (!s) {
|
|
929
|
-
return `${e.name}::${
|
|
929
|
+
return `${e.name}::${J(t, {
|
|
930
930
|
serialize: i
|
|
931
931
|
})}`;
|
|
932
932
|
}
|
|
933
|
-
return `${s}::${e.name}::${
|
|
933
|
+
return `${s}::${e.name}::${J(t, {
|
|
934
934
|
serialize: i
|
|
935
935
|
})}`;
|
|
936
936
|
}
|
|
937
937
|
|
|
938
|
-
function
|
|
938
|
+
function ee(e, ...t) {
|
|
939
939
|
return typeof e === "function" ? e(...t) : e;
|
|
940
940
|
}
|
|
941
941
|
|
|
942
|
-
var
|
|
942
|
+
var te = async e => new Promise((t => setTimeout(t, e)));
|
|
943
943
|
|
|
944
|
-
var
|
|
944
|
+
var re = class {
|
|
945
945
|
_hits=0;
|
|
946
946
|
_misses=0;
|
|
947
947
|
_gets=0;
|
|
@@ -1118,7 +1118,7 @@ var L = class {
|
|
|
1118
1118
|
}
|
|
1119
1119
|
};
|
|
1120
1120
|
|
|
1121
|
-
function
|
|
1121
|
+
function se(e) {
|
|
1122
1122
|
if (e === void 0 || e === null) {
|
|
1123
1123
|
return void 0;
|
|
1124
1124
|
}
|
|
@@ -1129,12 +1129,12 @@ function getTtlFromExpires(e) {
|
|
|
1129
1129
|
return e - t;
|
|
1130
1130
|
}
|
|
1131
1131
|
|
|
1132
|
-
function
|
|
1133
|
-
return r ?? t ??
|
|
1132
|
+
function ie(e, t, r) {
|
|
1133
|
+
return r ?? t ?? H(e);
|
|
1134
1134
|
}
|
|
1135
1135
|
|
|
1136
|
-
function
|
|
1137
|
-
const r =
|
|
1136
|
+
function ne(e, t) {
|
|
1137
|
+
const r = se(t);
|
|
1138
1138
|
const s = e ? Date.now() + e : void 0;
|
|
1139
1139
|
if (r === void 0) {
|
|
1140
1140
|
return e;
|
|
@@ -1148,7 +1148,7 @@ function calculateTtlFromExpiration(e, t) {
|
|
|
1148
1148
|
return r;
|
|
1149
1149
|
}
|
|
1150
1150
|
|
|
1151
|
-
var
|
|
1151
|
+
var oe = class {
|
|
1152
1152
|
opts;
|
|
1153
1153
|
namespace;
|
|
1154
1154
|
_cache;
|
|
@@ -1196,9 +1196,9 @@ var I = class {
|
|
|
1196
1196
|
}
|
|
1197
1197
|
};
|
|
1198
1198
|
|
|
1199
|
-
var
|
|
1199
|
+
var ae = e => e === 0 ? "primary" : `secondary:${e - 1}`;
|
|
1200
1200
|
|
|
1201
|
-
var
|
|
1201
|
+
var ce = e => {
|
|
1202
1202
|
const t = new r;
|
|
1203
1203
|
const s = new i;
|
|
1204
1204
|
s.serialize = void 0;
|
|
@@ -1206,7 +1206,7 @@ var createCache = e => {
|
|
|
1206
1206
|
const n = e?.stores?.length ? e.stores : [ s ];
|
|
1207
1207
|
const o = e?.nonBlocking ?? false;
|
|
1208
1208
|
const a = e?.cacheId ?? Math.random().toString(36).slice(2);
|
|
1209
|
-
const
|
|
1209
|
+
const c = async e => {
|
|
1210
1210
|
let r;
|
|
1211
1211
|
if (o) {
|
|
1212
1212
|
try {
|
|
@@ -1230,7 +1230,7 @@ var createCache = e => {
|
|
|
1230
1230
|
t.emit("get", {
|
|
1231
1231
|
key: e,
|
|
1232
1232
|
value: r,
|
|
1233
|
-
store:
|
|
1233
|
+
store: ae(s)
|
|
1234
1234
|
});
|
|
1235
1235
|
break;
|
|
1236
1236
|
}
|
|
@@ -1238,14 +1238,14 @@ var createCache = e => {
|
|
|
1238
1238
|
t.emit("get", {
|
|
1239
1239
|
key: e,
|
|
1240
1240
|
error: r,
|
|
1241
|
-
store:
|
|
1241
|
+
store: ae(s)
|
|
1242
1242
|
});
|
|
1243
1243
|
}
|
|
1244
1244
|
}
|
|
1245
1245
|
}
|
|
1246
1246
|
return r;
|
|
1247
1247
|
};
|
|
1248
|
-
const
|
|
1248
|
+
const l = async e => {
|
|
1249
1249
|
let r = e.map((() => void 0));
|
|
1250
1250
|
if (o) {
|
|
1251
1251
|
try {
|
|
@@ -1289,7 +1289,7 @@ var createCache = e => {
|
|
|
1289
1289
|
});
|
|
1290
1290
|
return r;
|
|
1291
1291
|
};
|
|
1292
|
-
const
|
|
1292
|
+
const h = async e => {
|
|
1293
1293
|
let r;
|
|
1294
1294
|
if (o) {
|
|
1295
1295
|
try {
|
|
@@ -1332,14 +1332,14 @@ var createCache = e => {
|
|
|
1332
1332
|
}
|
|
1333
1333
|
return void 0;
|
|
1334
1334
|
};
|
|
1335
|
-
const
|
|
1335
|
+
const m = async (r, s, i, n) => {
|
|
1336
1336
|
try {
|
|
1337
1337
|
const a = r.map((async (r, o) => {
|
|
1338
1338
|
await r.set(s, i, n ?? e?.ttl);
|
|
1339
1339
|
t.emit("set", {
|
|
1340
1340
|
key: s,
|
|
1341
1341
|
value: i,
|
|
1342
|
-
store:
|
|
1342
|
+
store: ae(o)
|
|
1343
1343
|
});
|
|
1344
1344
|
}));
|
|
1345
1345
|
if (o) {
|
|
@@ -1365,7 +1365,7 @@ var createCache = e => {
|
|
|
1365
1365
|
return Promise.reject(e);
|
|
1366
1366
|
}
|
|
1367
1367
|
};
|
|
1368
|
-
const
|
|
1368
|
+
const u = async (r, s) => {
|
|
1369
1369
|
const i = s.map((({key: t, value: r, ttl: s}) => ({
|
|
1370
1370
|
key: t,
|
|
1371
1371
|
value: r,
|
|
@@ -1393,7 +1393,7 @@ var createCache = e => {
|
|
|
1393
1393
|
return Promise.reject(e);
|
|
1394
1394
|
}
|
|
1395
1395
|
};
|
|
1396
|
-
const
|
|
1396
|
+
const f = async e => {
|
|
1397
1397
|
try {
|
|
1398
1398
|
if (o) {
|
|
1399
1399
|
Promise.all(n.map((async t => t.delete(e))));
|
|
@@ -1415,7 +1415,7 @@ var createCache = e => {
|
|
|
1415
1415
|
return Promise.reject(r);
|
|
1416
1416
|
}
|
|
1417
1417
|
};
|
|
1418
|
-
const
|
|
1418
|
+
const d = async e => {
|
|
1419
1419
|
try {
|
|
1420
1420
|
const r = [];
|
|
1421
1421
|
for (const t of e) {
|
|
@@ -1441,7 +1441,7 @@ var createCache = e => {
|
|
|
1441
1441
|
return Promise.reject(r);
|
|
1442
1442
|
}
|
|
1443
1443
|
};
|
|
1444
|
-
const
|
|
1444
|
+
const p = async () => {
|
|
1445
1445
|
try {
|
|
1446
1446
|
if (o) {
|
|
1447
1447
|
Promise.all(n.map((async e => e.clear())));
|
|
@@ -1456,16 +1456,16 @@ var createCache = e => {
|
|
|
1456
1456
|
return Promise.reject(e);
|
|
1457
1457
|
}
|
|
1458
1458
|
};
|
|
1459
|
-
const
|
|
1459
|
+
const y = async (r, s, i, o) => T(`${a}::${r}`, (async () => {
|
|
1460
1460
|
let c;
|
|
1461
1461
|
let l;
|
|
1462
1462
|
let h = 0;
|
|
1463
|
-
let
|
|
1464
|
-
const {ttl:
|
|
1463
|
+
let u;
|
|
1464
|
+
const {ttl: f, refreshThreshold: d, raw: p} = G(i) ? i : {
|
|
1465
1465
|
ttl: i,
|
|
1466
1466
|
refreshThreshold: o
|
|
1467
1467
|
};
|
|
1468
|
-
const
|
|
1468
|
+
const y = t => ee(f, t) ?? e?.ttl;
|
|
1469
1469
|
for (;h < n.length; h++) {
|
|
1470
1470
|
try {
|
|
1471
1471
|
const e = await n[h].get(r, {
|
|
@@ -1475,7 +1475,7 @@ var createCache = e => {
|
|
|
1475
1475
|
c = e.value;
|
|
1476
1476
|
l = e;
|
|
1477
1477
|
if (typeof e.expires === "number") {
|
|
1478
|
-
|
|
1478
|
+
u = Math.max(0, e.expires - Date.now());
|
|
1479
1479
|
}
|
|
1480
1480
|
break;
|
|
1481
1481
|
}
|
|
@@ -1483,18 +1483,18 @@ var createCache = e => {
|
|
|
1483
1483
|
}
|
|
1484
1484
|
if (c === void 0) {
|
|
1485
1485
|
const e = await s();
|
|
1486
|
-
const t =
|
|
1487
|
-
await
|
|
1488
|
-
return
|
|
1486
|
+
const t = y(e);
|
|
1487
|
+
await m(n, r, e, t);
|
|
1488
|
+
return p ? {
|
|
1489
1489
|
value: e,
|
|
1490
1490
|
expires: Date.now() + t
|
|
1491
1491
|
} : e;
|
|
1492
1492
|
}
|
|
1493
|
-
const
|
|
1494
|
-
if (
|
|
1495
|
-
|
|
1493
|
+
const g = W(u, ee(d, c) ?? e?.refreshThreshold);
|
|
1494
|
+
if (g) {
|
|
1495
|
+
T(`+++${a}__${r}`, s).then((async s => {
|
|
1496
1496
|
try {
|
|
1497
|
-
await
|
|
1497
|
+
await m(e?.refreshAllStores ? n : n.slice(0, h + 1), r, s, y(s));
|
|
1498
1498
|
t.emit("refresh", {
|
|
1499
1499
|
key: r,
|
|
1500
1500
|
value: s
|
|
@@ -1514,40 +1514,40 @@ var createCache = e => {
|
|
|
1514
1514
|
});
|
|
1515
1515
|
}));
|
|
1516
1516
|
}
|
|
1517
|
-
if (!
|
|
1518
|
-
await
|
|
1517
|
+
if (!g && h > 0) {
|
|
1518
|
+
await m(n.slice(0, h), r, c, y(c));
|
|
1519
1519
|
}
|
|
1520
|
-
return
|
|
1520
|
+
return p ? l : c;
|
|
1521
1521
|
}));
|
|
1522
|
-
const
|
|
1523
|
-
const
|
|
1524
|
-
const
|
|
1522
|
+
const g = (e, r) => t.addListener(e, r);
|
|
1523
|
+
const b = (e, r) => t.removeListener(e, r);
|
|
1524
|
+
const v = async () => {
|
|
1525
1525
|
try {
|
|
1526
1526
|
await Promise.all(n.map((async e => e.disconnect())));
|
|
1527
1527
|
} catch (e) {
|
|
1528
1528
|
return Promise.reject(e);
|
|
1529
1529
|
}
|
|
1530
1530
|
};
|
|
1531
|
-
const
|
|
1531
|
+
const _ = () => a;
|
|
1532
1532
|
return {
|
|
1533
|
-
get,
|
|
1534
|
-
mget,
|
|
1535
|
-
ttl,
|
|
1536
|
-
set: async (e, t, r) =>
|
|
1537
|
-
mset: async e =>
|
|
1538
|
-
del,
|
|
1539
|
-
mdel,
|
|
1540
|
-
clear,
|
|
1541
|
-
wrap,
|
|
1542
|
-
on,
|
|
1543
|
-
off,
|
|
1544
|
-
disconnect,
|
|
1545
|
-
cacheId,
|
|
1533
|
+
get: c,
|
|
1534
|
+
mget: l,
|
|
1535
|
+
ttl: h,
|
|
1536
|
+
set: async (e, t, r) => m(n, e, t, r),
|
|
1537
|
+
mset: async e => u(n, e),
|
|
1538
|
+
del: f,
|
|
1539
|
+
mdel: d,
|
|
1540
|
+
clear: p,
|
|
1541
|
+
wrap: y,
|
|
1542
|
+
on: g,
|
|
1543
|
+
off: b,
|
|
1544
|
+
disconnect: v,
|
|
1545
|
+
cacheId: _,
|
|
1546
1546
|
stores: n
|
|
1547
1547
|
};
|
|
1548
1548
|
};
|
|
1549
1549
|
|
|
1550
|
-
const
|
|
1550
|
+
const le = e => ({
|
|
1551
1551
|
class: Cacher,
|
|
1552
1552
|
stores: e?.stores,
|
|
1553
1553
|
ttl: e?.ttl,
|
|
@@ -1578,17 +1578,17 @@ class Cacher extends n {
|
|
|
1578
1578
|
return u(e);
|
|
1579
1579
|
|
|
1580
1580
|
case "postgres":
|
|
1581
|
-
return
|
|
1581
|
+
return f(e);
|
|
1582
1582
|
|
|
1583
1583
|
case "mysql":
|
|
1584
|
-
return
|
|
1584
|
+
return d(e);
|
|
1585
1585
|
|
|
1586
1586
|
default:
|
|
1587
1587
|
return undefined;
|
|
1588
1588
|
}
|
|
1589
1589
|
})));
|
|
1590
1590
|
const r = t.filter((e => !!e));
|
|
1591
|
-
this.cache =
|
|
1591
|
+
this.cache = ce({
|
|
1592
1592
|
stores: r.length ? r : undefined,
|
|
1593
1593
|
ttl: this.ttl,
|
|
1594
1594
|
refreshThreshold: this.refreshThreshold,
|
|
@@ -1647,4 +1647,4 @@ e([ o(p.Boolean().optional()), t("design:type", Boolean) ], Cacher.prototype, "n
|
|
|
1647
1647
|
|
|
1648
1648
|
e([ o(p.String().optional()), t("design:type", String) ], Cacher.prototype, "cacheId", void 0);
|
|
1649
1649
|
|
|
1650
|
-
export { BuildCacherOptions, Cacher };
|
|
1650
|
+
export { le as BuildCacherOptions, Cacher };
|