cdk-ecr-deployment 2.5.5 → 2.5.21
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/.gitattributes +5 -4
- package/.jsii +673 -21
- package/.jsii.tabl.json +1 -0
- package/.projenrc.ts +100 -0
- package/API.md +4 -4
- package/README.md +4 -4
- package/lambda/go.mod +2 -5
- package/lambda/go.sum +39 -14
- package/lib/index.d.ts +7 -65
- package/lib/index.js +7 -45
- package/node_modules/@sindresorhus/is/dist/index.d.ts +12 -7
- package/node_modules/@sindresorhus/is/dist/index.js +9 -4
- package/node_modules/@sindresorhus/is/dist/types.d.ts +1 -0
- package/node_modules/@sindresorhus/is/package.json +1 -1
- package/node_modules/@sindresorhus/is/readme.md +25 -7
- package/node_modules/@types/cacheable-request/README.md +2 -2
- package/node_modules/@types/cacheable-request/node_modules/@types/node/README.md +2 -2
- package/node_modules/@types/cacheable-request/node_modules/@types/node/assert.d.ts +135 -75
- package/node_modules/@types/cacheable-request/node_modules/@types/node/async_hooks.d.ts +67 -38
- package/node_modules/@types/cacheable-request/node_modules/@types/node/buffer.d.ts +226 -104
- package/node_modules/@types/cacheable-request/node_modules/@types/node/child_process.d.ts +87 -58
- package/node_modules/@types/cacheable-request/node_modules/@types/node/cluster.d.ts +29 -29
- package/node_modules/@types/cacheable-request/node_modules/@types/node/console.d.ts +5 -5
- package/node_modules/@types/cacheable-request/node_modules/@types/node/crypto.d.ts +888 -256
- package/node_modules/@types/cacheable-request/node_modules/@types/node/dgram.d.ts +16 -16
- package/node_modules/@types/cacheable-request/node_modules/@types/node/diagnostics_channel.d.ts +60 -21
- package/node_modules/@types/cacheable-request/node_modules/@types/node/dns/promises.d.ts +52 -8
- package/node_modules/@types/cacheable-request/node_modules/@types/node/dns.d.ts +27 -18
- package/node_modules/@types/cacheable-request/node_modules/@types/node/dom-events.d.ts +126 -0
- package/node_modules/@types/cacheable-request/node_modules/@types/node/domain.d.ts +6 -5
- package/node_modules/@types/cacheable-request/node_modules/@types/node/events.d.ts +166 -93
- package/node_modules/@types/cacheable-request/node_modules/@types/node/fs/promises.d.ts +169 -70
- package/node_modules/@types/cacheable-request/node_modules/@types/node/fs.d.ts +301 -126
- package/node_modules/@types/cacheable-request/node_modules/@types/node/globals.d.ts +22 -13
- package/node_modules/@types/cacheable-request/node_modules/@types/node/http.d.ts +453 -125
- package/node_modules/@types/cacheable-request/node_modules/@types/node/http2.d.ts +74 -46
- package/node_modules/@types/cacheable-request/node_modules/@types/node/https.d.ts +103 -53
- package/node_modules/@types/cacheable-request/node_modules/@types/node/index.d.ts +6 -2
- package/node_modules/@types/cacheable-request/node_modules/@types/node/inspector.d.ts +20 -16
- package/node_modules/@types/cacheable-request/node_modules/@types/node/module.d.ts +6 -4
- package/node_modules/@types/cacheable-request/node_modules/@types/node/net.d.ts +114 -22
- package/node_modules/@types/cacheable-request/node_modules/@types/node/os.d.ts +36 -14
- package/node_modules/@types/cacheable-request/node_modules/@types/node/package.json +15 -3
- package/node_modules/@types/cacheable-request/node_modules/@types/node/path.d.ts +37 -26
- package/node_modules/@types/cacheable-request/node_modules/@types/node/perf_hooks.d.ts +96 -15
- package/node_modules/@types/cacheable-request/node_modules/@types/node/process.d.ts +95 -82
- package/node_modules/@types/cacheable-request/node_modules/@types/node/punycode.d.ts +1 -1
- package/node_modules/@types/cacheable-request/node_modules/@types/node/querystring.d.ts +6 -6
- package/node_modules/@types/cacheable-request/node_modules/@types/node/readline/promises.d.ts +145 -0
- package/node_modules/@types/cacheable-request/node_modules/@types/node/readline.d.ts +51 -175
- package/node_modules/@types/cacheable-request/node_modules/@types/node/repl.d.ts +21 -21
- package/node_modules/@types/cacheable-request/node_modules/@types/node/stream/consumers.d.ts +2 -14
- package/node_modules/@types/cacheable-request/node_modules/@types/node/stream.d.ts +983 -824
- package/node_modules/@types/cacheable-request/node_modules/@types/node/string_decoder.d.ts +6 -6
- package/node_modules/@types/cacheable-request/node_modules/@types/node/test.d.ts +1052 -0
- package/node_modules/@types/cacheable-request/node_modules/@types/node/timers/promises.d.ts +26 -1
- package/node_modules/@types/cacheable-request/node_modules/@types/node/timers.d.ts +127 -6
- package/node_modules/@types/cacheable-request/node_modules/@types/node/tls.d.ts +149 -50
- package/node_modules/@types/cacheable-request/node_modules/@types/node/trace_events.d.ts +30 -9
- package/node_modules/@types/cacheable-request/node_modules/@types/node/ts4.8/assert/strict.d.ts +8 -0
- package/node_modules/@types/cacheable-request/node_modules/@types/node/ts4.8/assert.d.ts +972 -0
- package/node_modules/@types/cacheable-request/node_modules/@types/node/ts4.8/async_hooks.d.ts +530 -0
- package/node_modules/@types/cacheable-request/node_modules/@types/node/ts4.8/buffer.d.ts +2354 -0
- package/node_modules/@types/cacheable-request/node_modules/@types/node/ts4.8/child_process.d.ts +1395 -0
- package/node_modules/@types/cacheable-request/node_modules/@types/node/ts4.8/cluster.d.ts +414 -0
- package/node_modules/@types/cacheable-request/node_modules/@types/node/ts4.8/console.d.ts +412 -0
- package/node_modules/@types/cacheable-request/node_modules/@types/node/ts4.8/constants.d.ts +18 -0
- package/node_modules/@types/cacheable-request/node_modules/@types/node/ts4.8/crypto.d.ts +3969 -0
- package/node_modules/@types/cacheable-request/node_modules/@types/node/ts4.8/dgram.d.ts +545 -0
- package/node_modules/@types/cacheable-request/node_modules/@types/node/ts4.8/diagnostics_channel.d.ts +191 -0
- package/node_modules/@types/cacheable-request/node_modules/@types/node/ts4.8/dns/promises.d.ts +414 -0
- package/node_modules/@types/cacheable-request/node_modules/@types/node/ts4.8/dns.d.ts +668 -0
- package/node_modules/@types/cacheable-request/node_modules/@types/node/ts4.8/dom-events.d.ts +126 -0
- package/node_modules/@types/cacheable-request/node_modules/@types/node/ts4.8/domain.d.ts +170 -0
- package/node_modules/@types/cacheable-request/node_modules/@types/node/ts4.8/events.d.ts +724 -0
- package/node_modules/@types/cacheable-request/node_modules/@types/node/ts4.8/fs/promises.d.ts +1189 -0
- package/node_modules/@types/cacheable-request/node_modules/@types/node/ts4.8/fs.d.ts +4044 -0
- package/node_modules/@types/cacheable-request/node_modules/@types/node/ts4.8/globals.d.ts +303 -0
- package/node_modules/@types/cacheable-request/node_modules/@types/node/ts4.8/globals.global.d.ts +1 -0
- package/node_modules/@types/cacheable-request/node_modules/@types/node/ts4.8/http.d.ts +1724 -0
- package/node_modules/@types/cacheable-request/node_modules/@types/node/ts4.8/http2.d.ts +2129 -0
- package/node_modules/@types/cacheable-request/node_modules/@types/node/ts4.8/https.d.ts +441 -0
- package/node_modules/@types/cacheable-request/node_modules/@types/node/ts4.8/index.d.ts +88 -0
- package/node_modules/@types/cacheable-request/node_modules/@types/node/ts4.8/inspector.d.ts +2748 -0
- package/node_modules/@types/cacheable-request/node_modules/@types/node/ts4.8/module.d.ts +116 -0
- package/node_modules/@types/cacheable-request/node_modules/@types/node/ts4.8/net.d.ts +888 -0
- package/node_modules/@types/cacheable-request/node_modules/@types/node/ts4.8/os.d.ts +477 -0
- package/node_modules/@types/cacheable-request/node_modules/@types/node/ts4.8/path.d.ts +191 -0
- package/node_modules/@types/cacheable-request/node_modules/@types/node/ts4.8/perf_hooks.d.ts +638 -0
- package/node_modules/@types/cacheable-request/node_modules/@types/node/ts4.8/process.d.ts +1494 -0
- package/node_modules/@types/cacheable-request/node_modules/@types/node/ts4.8/punycode.d.ts +117 -0
- package/node_modules/@types/cacheable-request/node_modules/@types/node/ts4.8/querystring.d.ts +131 -0
- package/node_modules/@types/cacheable-request/node_modules/@types/node/ts4.8/readline/promises.d.ts +145 -0
- package/node_modules/@types/cacheable-request/node_modules/@types/node/ts4.8/readline.d.ts +526 -0
- package/node_modules/@types/cacheable-request/node_modules/@types/node/ts4.8/repl.d.ts +424 -0
- package/node_modules/@types/cacheable-request/node_modules/@types/node/ts4.8/stream/consumers.d.ts +12 -0
- package/node_modules/@types/cacheable-request/node_modules/@types/node/ts4.8/stream/promises.d.ts +42 -0
- package/node_modules/@types/cacheable-request/node_modules/@types/node/ts4.8/stream/web.d.ts +330 -0
- package/node_modules/@types/cacheable-request/node_modules/@types/node/ts4.8/stream.d.ts +1392 -0
- package/node_modules/@types/cacheable-request/node_modules/@types/node/ts4.8/string_decoder.d.ts +67 -0
- package/node_modules/@types/cacheable-request/node_modules/@types/node/ts4.8/test.d.ts +1052 -0
- package/node_modules/@types/cacheable-request/node_modules/@types/node/ts4.8/timers/promises.d.ts +93 -0
- package/node_modules/@types/cacheable-request/node_modules/@types/node/ts4.8/timers.d.ts +215 -0
- package/node_modules/@types/cacheable-request/node_modules/@types/node/ts4.8/tls.d.ts +1119 -0
- package/node_modules/@types/cacheable-request/node_modules/@types/node/ts4.8/trace_events.d.ts +182 -0
- package/node_modules/@types/cacheable-request/node_modules/@types/node/ts4.8/tty.d.ts +208 -0
- package/node_modules/@types/cacheable-request/node_modules/@types/node/ts4.8/url.d.ts +901 -0
- package/node_modules/@types/cacheable-request/node_modules/@types/node/ts4.8/util.d.ts +2052 -0
- package/node_modules/@types/cacheable-request/node_modules/@types/node/ts4.8/v8.d.ts +635 -0
- package/node_modules/@types/cacheable-request/node_modules/@types/node/ts4.8/vm.d.ts +894 -0
- package/node_modules/@types/cacheable-request/node_modules/@types/node/ts4.8/wasi.d.ts +152 -0
- package/node_modules/@types/cacheable-request/node_modules/@types/node/ts4.8/worker_threads.d.ts +693 -0
- package/node_modules/@types/cacheable-request/node_modules/@types/node/ts4.8/zlib.d.ts +517 -0
- package/node_modules/@types/cacheable-request/node_modules/@types/node/tty.d.ts +11 -7
- package/node_modules/@types/cacheable-request/node_modules/@types/node/url.d.ts +66 -56
- package/node_modules/@types/cacheable-request/node_modules/@types/node/util.d.ts +528 -70
- package/node_modules/@types/cacheable-request/node_modules/@types/node/v8.d.ts +271 -14
- package/node_modules/@types/cacheable-request/node_modules/@types/node/vm.d.ts +421 -34
- package/node_modules/@types/cacheable-request/node_modules/@types/node/wasi.d.ts +15 -21
- package/node_modules/@types/cacheable-request/node_modules/@types/node/worker_threads.d.ts +81 -37
- package/node_modules/@types/cacheable-request/node_modules/@types/node/zlib.d.ts +11 -11
- package/node_modules/@types/cacheable-request/package.json +5 -5
- package/node_modules/@types/keyv/README.md +1 -1
- package/node_modules/@types/keyv/index.d.ts +16 -3
- package/node_modules/@types/keyv/node_modules/@types/node/README.md +2 -2
- package/node_modules/@types/keyv/node_modules/@types/node/assert.d.ts +135 -75
- package/node_modules/@types/keyv/node_modules/@types/node/async_hooks.d.ts +67 -38
- package/node_modules/@types/keyv/node_modules/@types/node/buffer.d.ts +226 -104
- package/node_modules/@types/keyv/node_modules/@types/node/child_process.d.ts +87 -58
- package/node_modules/@types/keyv/node_modules/@types/node/cluster.d.ts +29 -29
- package/node_modules/@types/keyv/node_modules/@types/node/console.d.ts +5 -5
- package/node_modules/@types/keyv/node_modules/@types/node/crypto.d.ts +888 -256
- package/node_modules/@types/keyv/node_modules/@types/node/dgram.d.ts +16 -16
- package/node_modules/@types/keyv/node_modules/@types/node/diagnostics_channel.d.ts +60 -21
- package/node_modules/@types/keyv/node_modules/@types/node/dns/promises.d.ts +52 -8
- package/node_modules/@types/keyv/node_modules/@types/node/dns.d.ts +27 -18
- package/node_modules/@types/keyv/node_modules/@types/node/dom-events.d.ts +126 -0
- package/node_modules/@types/keyv/node_modules/@types/node/domain.d.ts +6 -5
- package/node_modules/@types/keyv/node_modules/@types/node/events.d.ts +166 -93
- package/node_modules/@types/keyv/node_modules/@types/node/fs/promises.d.ts +169 -70
- package/node_modules/@types/keyv/node_modules/@types/node/fs.d.ts +301 -126
- package/node_modules/@types/keyv/node_modules/@types/node/globals.d.ts +22 -13
- package/node_modules/@types/keyv/node_modules/@types/node/http.d.ts +453 -125
- package/node_modules/@types/keyv/node_modules/@types/node/http2.d.ts +74 -46
- package/node_modules/@types/keyv/node_modules/@types/node/https.d.ts +103 -53
- package/node_modules/@types/keyv/node_modules/@types/node/index.d.ts +6 -2
- package/node_modules/@types/keyv/node_modules/@types/node/inspector.d.ts +20 -16
- package/node_modules/@types/keyv/node_modules/@types/node/module.d.ts +6 -4
- package/node_modules/@types/keyv/node_modules/@types/node/net.d.ts +114 -22
- package/node_modules/@types/keyv/node_modules/@types/node/os.d.ts +36 -14
- package/node_modules/@types/keyv/node_modules/@types/node/package.json +15 -3
- package/node_modules/@types/keyv/node_modules/@types/node/path.d.ts +37 -26
- package/node_modules/@types/keyv/node_modules/@types/node/perf_hooks.d.ts +96 -15
- package/node_modules/@types/keyv/node_modules/@types/node/process.d.ts +95 -82
- package/node_modules/@types/keyv/node_modules/@types/node/punycode.d.ts +1 -1
- package/node_modules/@types/keyv/node_modules/@types/node/querystring.d.ts +6 -6
- package/node_modules/@types/keyv/node_modules/@types/node/readline/promises.d.ts +145 -0
- package/node_modules/@types/keyv/node_modules/@types/node/readline.d.ts +51 -175
- package/node_modules/@types/keyv/node_modules/@types/node/repl.d.ts +21 -21
- package/node_modules/@types/keyv/node_modules/@types/node/stream/consumers.d.ts +2 -14
- package/node_modules/@types/keyv/node_modules/@types/node/stream.d.ts +983 -824
- package/node_modules/@types/keyv/node_modules/@types/node/string_decoder.d.ts +6 -6
- package/node_modules/@types/keyv/node_modules/@types/node/test.d.ts +1052 -0
- package/node_modules/@types/keyv/node_modules/@types/node/timers/promises.d.ts +26 -1
- package/node_modules/@types/keyv/node_modules/@types/node/timers.d.ts +127 -6
- package/node_modules/@types/keyv/node_modules/@types/node/tls.d.ts +149 -50
- package/node_modules/@types/keyv/node_modules/@types/node/trace_events.d.ts +30 -9
- package/node_modules/@types/keyv/node_modules/@types/node/ts4.8/assert/strict.d.ts +8 -0
- package/node_modules/@types/keyv/node_modules/@types/node/ts4.8/assert.d.ts +972 -0
- package/node_modules/@types/keyv/node_modules/@types/node/ts4.8/async_hooks.d.ts +530 -0
- package/node_modules/@types/keyv/node_modules/@types/node/ts4.8/buffer.d.ts +2354 -0
- package/node_modules/@types/keyv/node_modules/@types/node/ts4.8/child_process.d.ts +1395 -0
- package/node_modules/@types/keyv/node_modules/@types/node/ts4.8/cluster.d.ts +414 -0
- package/node_modules/@types/keyv/node_modules/@types/node/ts4.8/console.d.ts +412 -0
- package/node_modules/@types/keyv/node_modules/@types/node/ts4.8/constants.d.ts +18 -0
- package/node_modules/@types/keyv/node_modules/@types/node/ts4.8/crypto.d.ts +3969 -0
- package/node_modules/@types/keyv/node_modules/@types/node/ts4.8/dgram.d.ts +545 -0
- package/node_modules/@types/keyv/node_modules/@types/node/ts4.8/diagnostics_channel.d.ts +191 -0
- package/node_modules/@types/keyv/node_modules/@types/node/ts4.8/dns/promises.d.ts +414 -0
- package/node_modules/@types/keyv/node_modules/@types/node/ts4.8/dns.d.ts +668 -0
- package/node_modules/@types/keyv/node_modules/@types/node/ts4.8/dom-events.d.ts +126 -0
- package/node_modules/@types/keyv/node_modules/@types/node/ts4.8/domain.d.ts +170 -0
- package/node_modules/@types/keyv/node_modules/@types/node/ts4.8/events.d.ts +724 -0
- package/node_modules/@types/keyv/node_modules/@types/node/ts4.8/fs/promises.d.ts +1189 -0
- package/node_modules/@types/keyv/node_modules/@types/node/ts4.8/fs.d.ts +4044 -0
- package/node_modules/@types/keyv/node_modules/@types/node/ts4.8/globals.d.ts +303 -0
- package/node_modules/@types/keyv/node_modules/@types/node/ts4.8/globals.global.d.ts +1 -0
- package/node_modules/@types/keyv/node_modules/@types/node/ts4.8/http.d.ts +1724 -0
- package/node_modules/@types/keyv/node_modules/@types/node/ts4.8/http2.d.ts +2129 -0
- package/node_modules/@types/keyv/node_modules/@types/node/ts4.8/https.d.ts +441 -0
- package/node_modules/@types/keyv/node_modules/@types/node/ts4.8/index.d.ts +88 -0
- package/node_modules/@types/keyv/node_modules/@types/node/ts4.8/inspector.d.ts +2748 -0
- package/node_modules/@types/keyv/node_modules/@types/node/ts4.8/module.d.ts +116 -0
- package/node_modules/@types/keyv/node_modules/@types/node/ts4.8/net.d.ts +888 -0
- package/node_modules/@types/keyv/node_modules/@types/node/ts4.8/os.d.ts +477 -0
- package/node_modules/@types/keyv/node_modules/@types/node/ts4.8/path.d.ts +191 -0
- package/node_modules/@types/keyv/node_modules/@types/node/ts4.8/perf_hooks.d.ts +638 -0
- package/node_modules/@types/keyv/node_modules/@types/node/ts4.8/process.d.ts +1494 -0
- package/node_modules/@types/keyv/node_modules/@types/node/ts4.8/punycode.d.ts +117 -0
- package/node_modules/@types/keyv/node_modules/@types/node/ts4.8/querystring.d.ts +131 -0
- package/node_modules/@types/keyv/node_modules/@types/node/ts4.8/readline/promises.d.ts +145 -0
- package/node_modules/@types/keyv/node_modules/@types/node/ts4.8/readline.d.ts +526 -0
- package/node_modules/@types/keyv/node_modules/@types/node/ts4.8/repl.d.ts +424 -0
- package/node_modules/@types/keyv/node_modules/@types/node/ts4.8/stream/consumers.d.ts +12 -0
- package/node_modules/@types/keyv/node_modules/@types/node/ts4.8/stream/promises.d.ts +42 -0
- package/node_modules/@types/keyv/node_modules/@types/node/ts4.8/stream/web.d.ts +330 -0
- package/node_modules/@types/keyv/node_modules/@types/node/ts4.8/stream.d.ts +1392 -0
- package/node_modules/@types/keyv/node_modules/@types/node/ts4.8/string_decoder.d.ts +67 -0
- package/node_modules/@types/keyv/node_modules/@types/node/ts4.8/test.d.ts +1052 -0
- package/node_modules/@types/keyv/node_modules/@types/node/ts4.8/timers/promises.d.ts +93 -0
- package/node_modules/@types/keyv/node_modules/@types/node/ts4.8/timers.d.ts +215 -0
- package/node_modules/@types/keyv/node_modules/@types/node/ts4.8/tls.d.ts +1119 -0
- package/node_modules/@types/keyv/node_modules/@types/node/ts4.8/trace_events.d.ts +182 -0
- package/node_modules/@types/keyv/node_modules/@types/node/ts4.8/tty.d.ts +208 -0
- package/node_modules/@types/keyv/node_modules/@types/node/ts4.8/url.d.ts +901 -0
- package/node_modules/@types/keyv/node_modules/@types/node/ts4.8/util.d.ts +2052 -0
- package/node_modules/@types/keyv/node_modules/@types/node/ts4.8/v8.d.ts +635 -0
- package/node_modules/@types/keyv/node_modules/@types/node/ts4.8/vm.d.ts +894 -0
- package/node_modules/@types/keyv/node_modules/@types/node/ts4.8/wasi.d.ts +152 -0
- package/node_modules/@types/keyv/node_modules/@types/node/ts4.8/worker_threads.d.ts +693 -0
- package/node_modules/@types/keyv/node_modules/@types/node/ts4.8/zlib.d.ts +517 -0
- package/node_modules/@types/keyv/node_modules/@types/node/tty.d.ts +11 -7
- package/node_modules/@types/keyv/node_modules/@types/node/url.d.ts +66 -56
- package/node_modules/@types/keyv/node_modules/@types/node/util.d.ts +528 -70
- package/node_modules/@types/keyv/node_modules/@types/node/v8.d.ts +271 -14
- package/node_modules/@types/keyv/node_modules/@types/node/vm.d.ts +421 -34
- package/node_modules/@types/keyv/node_modules/@types/node/wasi.d.ts +15 -21
- package/node_modules/@types/keyv/node_modules/@types/node/worker_threads.d.ts +81 -37
- package/node_modules/@types/keyv/node_modules/@types/node/zlib.d.ts +11 -11
- package/node_modules/@types/keyv/package.json +3 -3
- package/node_modules/@types/responselike/node_modules/@types/node/README.md +2 -2
- package/node_modules/@types/responselike/node_modules/@types/node/assert.d.ts +135 -75
- package/node_modules/@types/responselike/node_modules/@types/node/async_hooks.d.ts +67 -38
- package/node_modules/@types/responselike/node_modules/@types/node/buffer.d.ts +226 -104
- package/node_modules/@types/responselike/node_modules/@types/node/child_process.d.ts +87 -58
- package/node_modules/@types/responselike/node_modules/@types/node/cluster.d.ts +29 -29
- package/node_modules/@types/responselike/node_modules/@types/node/console.d.ts +5 -5
- package/node_modules/@types/responselike/node_modules/@types/node/crypto.d.ts +888 -256
- package/node_modules/@types/responselike/node_modules/@types/node/dgram.d.ts +16 -16
- package/node_modules/@types/responselike/node_modules/@types/node/diagnostics_channel.d.ts +60 -21
- package/node_modules/@types/responselike/node_modules/@types/node/dns/promises.d.ts +52 -8
- package/node_modules/@types/responselike/node_modules/@types/node/dns.d.ts +27 -18
- package/node_modules/@types/responselike/node_modules/@types/node/dom-events.d.ts +126 -0
- package/node_modules/@types/responselike/node_modules/@types/node/domain.d.ts +6 -5
- package/node_modules/@types/responselike/node_modules/@types/node/events.d.ts +166 -93
- package/node_modules/@types/responselike/node_modules/@types/node/fs/promises.d.ts +169 -70
- package/node_modules/@types/responselike/node_modules/@types/node/fs.d.ts +301 -126
- package/node_modules/@types/responselike/node_modules/@types/node/globals.d.ts +22 -13
- package/node_modules/@types/responselike/node_modules/@types/node/http.d.ts +453 -125
- package/node_modules/@types/responselike/node_modules/@types/node/http2.d.ts +74 -46
- package/node_modules/@types/responselike/node_modules/@types/node/https.d.ts +103 -53
- package/node_modules/@types/responselike/node_modules/@types/node/index.d.ts +6 -2
- package/node_modules/@types/responselike/node_modules/@types/node/inspector.d.ts +20 -16
- package/node_modules/@types/responselike/node_modules/@types/node/module.d.ts +6 -4
- package/node_modules/@types/responselike/node_modules/@types/node/net.d.ts +114 -22
- package/node_modules/@types/responselike/node_modules/@types/node/os.d.ts +36 -14
- package/node_modules/@types/responselike/node_modules/@types/node/package.json +15 -3
- package/node_modules/@types/responselike/node_modules/@types/node/path.d.ts +37 -26
- package/node_modules/@types/responselike/node_modules/@types/node/perf_hooks.d.ts +96 -15
- package/node_modules/@types/responselike/node_modules/@types/node/process.d.ts +95 -82
- package/node_modules/@types/responselike/node_modules/@types/node/punycode.d.ts +1 -1
- package/node_modules/@types/responselike/node_modules/@types/node/querystring.d.ts +6 -6
- package/node_modules/@types/responselike/node_modules/@types/node/readline/promises.d.ts +145 -0
- package/node_modules/@types/responselike/node_modules/@types/node/readline.d.ts +51 -175
- package/node_modules/@types/responselike/node_modules/@types/node/repl.d.ts +21 -21
- package/node_modules/@types/responselike/node_modules/@types/node/stream/consumers.d.ts +2 -14
- package/node_modules/@types/responselike/node_modules/@types/node/stream.d.ts +983 -824
- package/node_modules/@types/responselike/node_modules/@types/node/string_decoder.d.ts +6 -6
- package/node_modules/@types/responselike/node_modules/@types/node/test.d.ts +1052 -0
- package/node_modules/@types/responselike/node_modules/@types/node/timers/promises.d.ts +26 -1
- package/node_modules/@types/responselike/node_modules/@types/node/timers.d.ts +127 -6
- package/node_modules/@types/responselike/node_modules/@types/node/tls.d.ts +149 -50
- package/node_modules/@types/responselike/node_modules/@types/node/trace_events.d.ts +30 -9
- package/node_modules/@types/responselike/node_modules/@types/node/ts4.8/assert/strict.d.ts +8 -0
- package/node_modules/@types/responselike/node_modules/@types/node/ts4.8/assert.d.ts +972 -0
- package/node_modules/@types/responselike/node_modules/@types/node/ts4.8/async_hooks.d.ts +530 -0
- package/node_modules/@types/responselike/node_modules/@types/node/ts4.8/buffer.d.ts +2354 -0
- package/node_modules/@types/responselike/node_modules/@types/node/ts4.8/child_process.d.ts +1395 -0
- package/node_modules/@types/responselike/node_modules/@types/node/ts4.8/cluster.d.ts +414 -0
- package/node_modules/@types/responselike/node_modules/@types/node/ts4.8/console.d.ts +412 -0
- package/node_modules/@types/responselike/node_modules/@types/node/ts4.8/constants.d.ts +18 -0
- package/node_modules/@types/responselike/node_modules/@types/node/ts4.8/crypto.d.ts +3969 -0
- package/node_modules/@types/responselike/node_modules/@types/node/ts4.8/dgram.d.ts +545 -0
- package/node_modules/@types/responselike/node_modules/@types/node/ts4.8/diagnostics_channel.d.ts +191 -0
- package/node_modules/@types/responselike/node_modules/@types/node/ts4.8/dns/promises.d.ts +414 -0
- package/node_modules/@types/responselike/node_modules/@types/node/ts4.8/dns.d.ts +668 -0
- package/node_modules/@types/responselike/node_modules/@types/node/ts4.8/dom-events.d.ts +126 -0
- package/node_modules/@types/responselike/node_modules/@types/node/ts4.8/domain.d.ts +170 -0
- package/node_modules/@types/responselike/node_modules/@types/node/ts4.8/events.d.ts +724 -0
- package/node_modules/@types/responselike/node_modules/@types/node/ts4.8/fs/promises.d.ts +1189 -0
- package/node_modules/@types/responselike/node_modules/@types/node/ts4.8/fs.d.ts +4044 -0
- package/node_modules/@types/responselike/node_modules/@types/node/ts4.8/globals.d.ts +303 -0
- package/node_modules/@types/responselike/node_modules/@types/node/ts4.8/globals.global.d.ts +1 -0
- package/node_modules/@types/responselike/node_modules/@types/node/ts4.8/http.d.ts +1724 -0
- package/node_modules/@types/responselike/node_modules/@types/node/ts4.8/http2.d.ts +2129 -0
- package/node_modules/@types/responselike/node_modules/@types/node/ts4.8/https.d.ts +441 -0
- package/node_modules/@types/responselike/node_modules/@types/node/ts4.8/index.d.ts +88 -0
- package/node_modules/@types/responselike/node_modules/@types/node/ts4.8/inspector.d.ts +2748 -0
- package/node_modules/@types/responselike/node_modules/@types/node/ts4.8/module.d.ts +116 -0
- package/node_modules/@types/responselike/node_modules/@types/node/ts4.8/net.d.ts +888 -0
- package/node_modules/@types/responselike/node_modules/@types/node/ts4.8/os.d.ts +477 -0
- package/node_modules/@types/responselike/node_modules/@types/node/ts4.8/path.d.ts +191 -0
- package/node_modules/@types/responselike/node_modules/@types/node/ts4.8/perf_hooks.d.ts +638 -0
- package/node_modules/@types/responselike/node_modules/@types/node/ts4.8/process.d.ts +1494 -0
- package/node_modules/@types/responselike/node_modules/@types/node/ts4.8/punycode.d.ts +117 -0
- package/node_modules/@types/responselike/node_modules/@types/node/ts4.8/querystring.d.ts +131 -0
- package/node_modules/@types/responselike/node_modules/@types/node/ts4.8/readline/promises.d.ts +145 -0
- package/node_modules/@types/responselike/node_modules/@types/node/ts4.8/readline.d.ts +526 -0
- package/node_modules/@types/responselike/node_modules/@types/node/ts4.8/repl.d.ts +424 -0
- package/node_modules/@types/responselike/node_modules/@types/node/ts4.8/stream/consumers.d.ts +12 -0
- package/node_modules/@types/responselike/node_modules/@types/node/ts4.8/stream/promises.d.ts +42 -0
- package/node_modules/@types/responselike/node_modules/@types/node/ts4.8/stream/web.d.ts +330 -0
- package/node_modules/@types/responselike/node_modules/@types/node/ts4.8/stream.d.ts +1392 -0
- package/node_modules/@types/responselike/node_modules/@types/node/ts4.8/string_decoder.d.ts +67 -0
- package/node_modules/@types/responselike/node_modules/@types/node/ts4.8/test.d.ts +1052 -0
- package/node_modules/@types/responselike/node_modules/@types/node/ts4.8/timers/promises.d.ts +93 -0
- package/node_modules/@types/responselike/node_modules/@types/node/ts4.8/timers.d.ts +215 -0
- package/node_modules/@types/responselike/node_modules/@types/node/ts4.8/tls.d.ts +1119 -0
- package/node_modules/@types/responselike/node_modules/@types/node/ts4.8/trace_events.d.ts +182 -0
- package/node_modules/@types/responselike/node_modules/@types/node/ts4.8/tty.d.ts +208 -0
- package/node_modules/@types/responselike/node_modules/@types/node/ts4.8/url.d.ts +901 -0
- package/node_modules/@types/responselike/node_modules/@types/node/ts4.8/util.d.ts +2052 -0
- package/node_modules/@types/responselike/node_modules/@types/node/ts4.8/v8.d.ts +635 -0
- package/node_modules/@types/responselike/node_modules/@types/node/ts4.8/vm.d.ts +894 -0
- package/node_modules/@types/responselike/node_modules/@types/node/ts4.8/wasi.d.ts +152 -0
- package/node_modules/@types/responselike/node_modules/@types/node/ts4.8/worker_threads.d.ts +693 -0
- package/node_modules/@types/responselike/node_modules/@types/node/ts4.8/zlib.d.ts +517 -0
- package/node_modules/@types/responselike/node_modules/@types/node/tty.d.ts +11 -7
- package/node_modules/@types/responselike/node_modules/@types/node/url.d.ts +66 -56
- package/node_modules/@types/responselike/node_modules/@types/node/util.d.ts +528 -70
- package/node_modules/@types/responselike/node_modules/@types/node/v8.d.ts +271 -14
- package/node_modules/@types/responselike/node_modules/@types/node/vm.d.ts +421 -34
- package/node_modules/@types/responselike/node_modules/@types/node/wasi.d.ts +15 -21
- package/node_modules/@types/responselike/node_modules/@types/node/worker_threads.d.ts +81 -37
- package/node_modules/@types/responselike/node_modules/@types/node/zlib.d.ts +11 -11
- package/node_modules/cacheable-request/package.json +1 -1
- package/node_modules/clone-response/node_modules/mimic-response/index.js +32 -0
- package/node_modules/{get-stream → clone-response/node_modules/mimic-response}/license +1 -1
- package/node_modules/clone-response/node_modules/mimic-response/package.json +37 -0
- package/node_modules/clone-response/node_modules/mimic-response/readme.md +54 -0
- package/node_modules/clone-response/package.json +3 -6
- package/node_modules/got/dist/source/as-promise/index.js +2 -1
- package/node_modules/got/dist/source/core/index.js +8 -0
- package/node_modules/got/dist/source/types.d.ts +8 -8
- package/node_modules/got/package.json +2 -1
- package/node_modules/http-cache-semantics/index.js +4 -3
- package/node_modules/http-cache-semantics/package.json +2 -8
- package/node_modules/keyv/README.md +141 -5
- package/node_modules/keyv/package.json +56 -50
- package/node_modules/keyv/src/index.d.ts +116 -0
- package/node_modules/keyv/src/index.js +179 -24
- package/node_modules/mimic-response/index.js +58 -13
- package/node_modules/mimic-response/license +1 -1
- package/node_modules/mimic-response/package.json +40 -35
- package/node_modules/mimic-response/readme.md +33 -9
- package/node_modules/responselike/package.json +3 -2
- package/package.json +54 -25
- package/rosetta/default.ts-fixture +17 -0
- package/changelog.md +0 -2
- package/node_modules/decompress-response/node_modules/mimic-response/index.js +0 -77
- package/node_modules/decompress-response/node_modules/mimic-response/package.json +0 -42
- package/node_modules/decompress-response/node_modules/mimic-response/readme.md +0 -78
- package/node_modules/keyv/.nyc_output/37411020-4142-4b08-b825-343ba2427bf7.json +0 -1
- package/node_modules/keyv/.nyc_output/cd79f2de-c8b8-4493-bc15-b2bde28efa4b.json +0 -1
- package/node_modules/keyv/.nyc_output/processinfo/37411020-4142-4b08-b825-343ba2427bf7.json +0 -1
- package/node_modules/keyv/.nyc_output/processinfo/cd79f2de-c8b8-4493-bc15-b2bde28efa4b.json +0 -1
- package/node_modules/keyv/.nyc_output/processinfo/index.json +0 -1
- package/node_modules/keyv/test/test.js +0 -132
- package/node_modules/keyv/test/testdb.sqlite +0 -0
- package/releasetag.txt +0 -1
- package/version.txt +0 -1
- /package/node_modules/{get-stream → cacheable-request/node_modules/get-stream}/buffer-stream.js +0 -0
- /package/node_modules/{get-stream → cacheable-request/node_modules/get-stream}/index.d.ts +0 -0
- /package/node_modules/{get-stream → cacheable-request/node_modules/get-stream}/index.js +0 -0
- /package/node_modules/{decompress-response/node_modules/mimic-response → cacheable-request/node_modules/get-stream}/license +0 -0
- /package/node_modules/{get-stream → cacheable-request/node_modules/get-stream}/package.json +0 -0
- /package/node_modules/{get-stream → cacheable-request/node_modules/get-stream}/readme.md +0 -0
- /package/node_modules/{decompress-response/node_modules/mimic-response → mimic-response}/index.d.ts +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "got",
|
|
3
|
-
"version": "11.8.
|
|
3
|
+
"version": "11.8.6",
|
|
4
4
|
"description": "Human-friendly and powerful HTTP request library for Node.js",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"repository": "sindresorhus/got",
|
|
@@ -61,6 +61,7 @@
|
|
|
61
61
|
"@sinonjs/fake-timers": "^6.0.1",
|
|
62
62
|
"@types/benchmark": "^1.0.33",
|
|
63
63
|
"@types/express": "^4.17.7",
|
|
64
|
+
"@types/express-serve-static-core": "4.17.18 - 4.17.30",
|
|
64
65
|
"@types/node": "^14.14.0",
|
|
65
66
|
"@types/node-fetch": "^2.5.7",
|
|
66
67
|
"@types/pem": "^1.9.5",
|
|
@@ -7,6 +7,7 @@ const statusCodeCacheableByDefault = new Set([
|
|
|
7
7
|
206,
|
|
8
8
|
300,
|
|
9
9
|
301,
|
|
10
|
+
308,
|
|
10
11
|
404,
|
|
11
12
|
405,
|
|
12
13
|
410,
|
|
@@ -79,10 +80,10 @@ function parseCacheControl(header) {
|
|
|
79
80
|
|
|
80
81
|
// TODO: When there is more than one value present for a given directive (e.g., two Expires header fields, multiple Cache-Control: max-age directives),
|
|
81
82
|
// the directive's value is considered invalid. Caches are encouraged to consider responses that have invalid freshness information to be stale
|
|
82
|
-
const parts = header.trim().split(
|
|
83
|
+
const parts = header.trim().split(/,/);
|
|
83
84
|
for (const part of parts) {
|
|
84
|
-
const [k, v] = part.split(
|
|
85
|
-
cc[k] = v === undefined ? true : v.replace(/^"|"$/g, '');
|
|
85
|
+
const [k, v] = part.split(/=/, 2);
|
|
86
|
+
cc[k.trim()] = v === undefined ? true : v.trim().replace(/^"|"$/g, '');
|
|
86
87
|
}
|
|
87
88
|
|
|
88
89
|
return cc;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "http-cache-semantics",
|
|
3
|
-
"version": "4.1.
|
|
3
|
+
"version": "4.1.1",
|
|
4
4
|
"description": "Parses Cache-Control and other headers. Helps building correct HTTP caches and proxies",
|
|
5
5
|
"repository": "https://github.com/kornelski/http-cache-semantics.git",
|
|
6
6
|
"main": "index.js",
|
|
@@ -13,12 +13,6 @@
|
|
|
13
13
|
"author": "Kornel Lesiński <kornel@geekhood.net> (https://kornel.ski/)",
|
|
14
14
|
"license": "BSD-2-Clause",
|
|
15
15
|
"devDependencies": {
|
|
16
|
-
"
|
|
17
|
-
"eslint-plugin-prettier": "^3.0.1",
|
|
18
|
-
"husky": "^0.14.3",
|
|
19
|
-
"lint-staged": "^8.1.3",
|
|
20
|
-
"mocha": "^5.1.0",
|
|
21
|
-
"prettier": "^1.14.3",
|
|
22
|
-
"prettier-eslint-cli": "^4.7.1"
|
|
16
|
+
"mocha": "^10.0"
|
|
23
17
|
}
|
|
24
18
|
}
|
|
@@ -6,8 +6,8 @@
|
|
|
6
6
|
|
|
7
7
|
> Simple key-value storage with support for multiple backends
|
|
8
8
|
|
|
9
|
-
[](https://github.com/jaredwray/keyv/actions/workflows/tests.yaml)
|
|
10
|
+
[](https://codecov.io/gh/jaredwray/keyv)
|
|
11
11
|
[](https://www.npmjs.com/package/keyv)
|
|
12
12
|
[](https://www.npmjs.com/package/keyv)
|
|
13
13
|
|
|
@@ -44,6 +44,7 @@ npm install --save @keyv/mongo
|
|
|
44
44
|
npm install --save @keyv/sqlite
|
|
45
45
|
npm install --save @keyv/postgres
|
|
46
46
|
npm install --save @keyv/mysql
|
|
47
|
+
npm install --save @keyv/etcd
|
|
47
48
|
```
|
|
48
49
|
|
|
49
50
|
Create a new Keyv instance, passing your connection string if applicable. Keyv will automatically load the correct storage adapter.
|
|
@@ -58,6 +59,7 @@ const keyv = new Keyv('mongodb://user:pass@localhost:27017/dbname');
|
|
|
58
59
|
const keyv = new Keyv('sqlite://path/to/database.sqlite');
|
|
59
60
|
const keyv = new Keyv('postgresql://user:pass@localhost:5432/dbname');
|
|
60
61
|
const keyv = new Keyv('mysql://user:pass@localhost:3306/dbname');
|
|
62
|
+
const keyv = new Keyv('etcd://localhost:2379');
|
|
61
63
|
|
|
62
64
|
// Handle DB connection errors
|
|
63
65
|
keyv.on('error', err => console.log('Connection Error', err));
|
|
@@ -100,7 +102,7 @@ const keyv = new Keyv({ serialize: JSON.stringify, deserialize: JSON.parse });
|
|
|
100
102
|
|
|
101
103
|
## Official Storage Adapters
|
|
102
104
|
|
|
103
|
-
The official storage adapters are covered by [over 150 integration tests](https://github.com/jaredwray/keyv/actions/workflows/
|
|
105
|
+
The official storage adapters are covered by [over 150 integration tests](https://github.com/jaredwray/keyv/actions/workflows/tests.yaml) to guarantee consistent behaviour. They are lightweight, efficient wrappers over the DB clients making use of indexes and native TTLs where available.
|
|
104
106
|
|
|
105
107
|
Database | Adapter | Native TTL
|
|
106
108
|
---|---|---
|
|
@@ -109,6 +111,8 @@ MongoDB | [@keyv/mongo](https://github.com/jaredwray/keyv/tree/master/packages/m
|
|
|
109
111
|
SQLite | [@keyv/sqlite](https://github.com/jaredwray/keyv/tree/master/packages/sqlite) | No
|
|
110
112
|
PostgreSQL | [@keyv/postgres](https://github.com/jaredwray/keyv/tree/master/packages/postgres) | No
|
|
111
113
|
MySQL | [@keyv/mysql](https://github.com/jaredwray/keyv/tree/master/packages/mysql) | No
|
|
114
|
+
Etcd | [@keyv/etcd](https://github.com/jaredwray/keyv/tree/master/packages/etcd) | Yes
|
|
115
|
+
Memcache | [@keyv/memcache](https://github.com/jaredwray/keyv/tree/master/packages/memcache) | Yes
|
|
112
116
|
|
|
113
117
|
## Third-party Storage Adapters
|
|
114
118
|
|
|
@@ -146,7 +150,6 @@ The following are third-party storage adapters compatible with Keyv:
|
|
|
146
150
|
- [keyv-null](https://www.npmjs.com/package/keyv-null) - Null storage adapter for Keyv
|
|
147
151
|
- [keyv-firestore ](https://github.com/goto-bus-stop/keyv-firestore) – Firebase Cloud Firestore adapter for Keyv
|
|
148
152
|
- [keyv-mssql](https://github.com/pmorgan3/keyv-mssql) - Microsoft Sql Server adapter for Keyv
|
|
149
|
-
- [keyv-memcache](https://github.com/jaredwray/keyv/tree/master/packages/memcache) - Memcache storage adapter for Keyv
|
|
150
153
|
- [keyv-azuretable](https://github.com/howlowck/keyv-azuretable) - Azure Table Storage/API adapter for Keyv
|
|
151
154
|
|
|
152
155
|
## Add Cache Support to your Module
|
|
@@ -184,6 +187,42 @@ const awesomeModule = new AwesomeModule({ cache: 'redis://localhost' });
|
|
|
184
187
|
const awesomeModule = new AwesomeModule({ cache: some3rdPartyStore });
|
|
185
188
|
```
|
|
186
189
|
|
|
190
|
+
## Compression
|
|
191
|
+
|
|
192
|
+
Keyv supports `gzip` and `brotli` compression. To enable compression, pass the `compress` option to the constructor.
|
|
193
|
+
|
|
194
|
+
```js
|
|
195
|
+
const KeyvGzip = require('@keyv/compress-gzip');
|
|
196
|
+
const Keyv = require('keyv');
|
|
197
|
+
|
|
198
|
+
const keyvGzip = new KeyvGzip();
|
|
199
|
+
const keyv = new Keyv({ compression: KeyvGzip });
|
|
200
|
+
```
|
|
201
|
+
|
|
202
|
+
You can also pass a custom compression function to the `compression` option. Following the pattern of the official compression adapters.
|
|
203
|
+
|
|
204
|
+
### Want to build your own?
|
|
205
|
+
|
|
206
|
+
Great! Keyv is designed to be easily extended. You can build your own compression adapter by following the pattern of the official compression adapters based on this interface:
|
|
207
|
+
|
|
208
|
+
```typescript
|
|
209
|
+
interface CompressionAdapter {
|
|
210
|
+
async compress(value: any, options?: any);
|
|
211
|
+
async decompress(value: any, options?: any);
|
|
212
|
+
async serialize(value: any);
|
|
213
|
+
async deserialize(value: any);
|
|
214
|
+
}
|
|
215
|
+
```
|
|
216
|
+
|
|
217
|
+
In addition to the interface, you can test it with our compression test suite using @keyv/test-suite:
|
|
218
|
+
|
|
219
|
+
```js
|
|
220
|
+
const {keyvCompresstionTests} = require('@keyv/test-suite');
|
|
221
|
+
const KeyvGzip = require('@keyv/compress-gzip');
|
|
222
|
+
|
|
223
|
+
keyvCompresstionTests(test, new KeyvGzip());
|
|
224
|
+
```
|
|
225
|
+
|
|
187
226
|
## API
|
|
188
227
|
|
|
189
228
|
### new Keyv([uri], [options])
|
|
@@ -221,6 +260,13 @@ Default: `undefined`
|
|
|
221
260
|
|
|
222
261
|
Default TTL. Can be overridden by specififying a TTL on `.set()`.
|
|
223
262
|
|
|
263
|
+
#### options.compression
|
|
264
|
+
|
|
265
|
+
Type: `@keyv/compress-<compression_package_name>`<br>
|
|
266
|
+
Default: `undefined`
|
|
267
|
+
|
|
268
|
+
Compression package to use. See [Compression](#compression) for more details.
|
|
269
|
+
|
|
224
270
|
#### options.serialize
|
|
225
271
|
|
|
226
272
|
Type: `Function`<br>
|
|
@@ -286,6 +332,96 @@ Delete all entries in the current namespace.
|
|
|
286
332
|
|
|
287
333
|
Returns a promise which is resolved when the entries have been cleared.
|
|
288
334
|
|
|
335
|
+
#### .iterator()
|
|
336
|
+
|
|
337
|
+
Iterate over all entries of the current namespace.
|
|
338
|
+
|
|
339
|
+
Returns a iterable that can be iterated by for-of loops. For example:
|
|
340
|
+
|
|
341
|
+
```js
|
|
342
|
+
// please note that the "await" keyword should be used here
|
|
343
|
+
for await (const [key, value] of this.keyv.iterator()) {
|
|
344
|
+
console.log(key, value);
|
|
345
|
+
};
|
|
346
|
+
```
|
|
347
|
+
|
|
348
|
+
# How to Contribute
|
|
349
|
+
|
|
350
|
+
In this section of the documentation we will cover:
|
|
351
|
+
|
|
352
|
+
1) How to set up this repository locally
|
|
353
|
+
2) How to get started with running commands
|
|
354
|
+
3) How to contribute changes using Pull Requests
|
|
355
|
+
|
|
356
|
+
## Dependencies
|
|
357
|
+
|
|
358
|
+
This package requires the following dependencies to run:
|
|
359
|
+
|
|
360
|
+
1) [Yarn V1](https://yarnpkg.com/getting-started/install)
|
|
361
|
+
3) [Docker](https://docs.docker.com/get-docker/)
|
|
362
|
+
|
|
363
|
+
## Setting up your workspace
|
|
364
|
+
|
|
365
|
+
To contribute to this repository, start by setting up this project locally:
|
|
366
|
+
|
|
367
|
+
1) Fork this repository into your Git account
|
|
368
|
+
2) Clone the forked repository to your local directory using `git clone`
|
|
369
|
+
3) Install any of the above missing dependencies
|
|
370
|
+
|
|
371
|
+
## Launching the project
|
|
372
|
+
|
|
373
|
+
Once the project is installed locally, you are ready to start up its services:
|
|
374
|
+
|
|
375
|
+
1) Ensure that your Docker service is running.
|
|
376
|
+
2) From the root directory of your project, run the `yarn` command in the command prompt to install yarn.
|
|
377
|
+
3) Run the `yarn bootstrap` command to install any necessary dependencies.
|
|
378
|
+
4) Run `yarn test:services:start` to start up this project's Docker container. The container will launch all services within your workspace.
|
|
379
|
+
|
|
380
|
+
## Available Commands
|
|
381
|
+
|
|
382
|
+
Once the project is running, you can execute a variety of commands. The root workspace and each subpackage contain a `package.json` file with a `scripts` field listing all the commands that can be executed from that directory. This project also supports native `yarn`, and `docker` commands.
|
|
383
|
+
|
|
384
|
+
Here, we'll cover the primary commands that can be executed from the root directory. Unless otherwise noted, these commands can also be executed from a subpackage. If executed from a subpackage, they will only affect that subpackage, rather than the entire workspace.
|
|
385
|
+
|
|
386
|
+
### `yarn`
|
|
387
|
+
|
|
388
|
+
The `yarn` command installs yarn in the workspace.
|
|
389
|
+
|
|
390
|
+
### `yarn bootstrap`
|
|
391
|
+
|
|
392
|
+
The `yarn bootstrap` command installs all dependencies in the workspace.
|
|
393
|
+
|
|
394
|
+
### `yarn test:services:start`
|
|
395
|
+
|
|
396
|
+
The `yarn test:services:start` command starts up the project's Docker container, launching all services in the workspace. This command must be executed from the root directory.
|
|
397
|
+
|
|
398
|
+
### `yarn test:services:stop`
|
|
399
|
+
|
|
400
|
+
The `yarn test:services:stop` command brings down the project's Docker container, halting all services. This command must be executed from the root directory.
|
|
401
|
+
|
|
402
|
+
### `yarn test`
|
|
403
|
+
|
|
404
|
+
The `yarn test` command runs all tests in the workspace.
|
|
405
|
+
|
|
406
|
+
### `yarn clean`
|
|
407
|
+
|
|
408
|
+
The `yarn clean` command removes yarn and all dependencies installed by yarn. After executing this command, you must repeat the steps in *Setting up your workspace* to rebuild your workspace.
|
|
409
|
+
|
|
410
|
+
## Contributing Changes
|
|
411
|
+
|
|
412
|
+
Now that you've set up your workspace, you're ready to contribute changes to the `keyv` repository.
|
|
413
|
+
|
|
414
|
+
1) Make any changes that you would like to contribute in your local workspace.
|
|
415
|
+
2) After making these changes, ensure that the project's tests still pass by executing the `yarn test` command in the root directory.
|
|
416
|
+
3) Commit your changes and push them to your forked repository.
|
|
417
|
+
4) Navigate to the original `keyv` repository and go the *Pull Requests* tab.
|
|
418
|
+
5) Click the *New pull request* button, and open a pull request for the branch in your repository that contains your changes.
|
|
419
|
+
6) Once your pull request is created, ensure that all checks have passed and that your branch has no conflicts with the base branch. If there are any issues, resolve these changes in your local repository, and then commit and push them to git.
|
|
420
|
+
7) Similarly, respond to any reviewer comments or requests for changes by making edits to your local repository and pushing them to Git.
|
|
421
|
+
8) Once the pull request has been reviewed, those with write access to the branch will be able to merge your changes into the `keyv` repository.
|
|
422
|
+
|
|
423
|
+
If you need more information on the steps to create a pull request, you can find a detailed walkthrough in the [Github documentation](https://docs.github.com/en/pull-requests/collaborating-with-pull-requests/proposing-changes-to-your-work-with-pull-requests/creating-a-pull-request-from-a-fork)
|
|
424
|
+
|
|
289
425
|
## License
|
|
290
426
|
|
|
291
|
-
MIT © Jared Wray
|
|
427
|
+
MIT © Jared Wray
|
|
@@ -1,52 +1,58 @@
|
|
|
1
1
|
{
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
2
|
+
"name": "keyv",
|
|
3
|
+
"version": "4.5.2",
|
|
4
|
+
"description": "Simple key-value storage with support for multiple backends",
|
|
5
|
+
"main": "src/index.js",
|
|
6
|
+
"scripts": {
|
|
7
|
+
"test": "xo && nyc ava --serial",
|
|
8
|
+
"coverage": "nyc report --reporter=text-lcov > coverage.lcov",
|
|
9
|
+
"clean": "rm -rf node_modules && rm -rf .nyc_output && rm -rf coverage.lcov && rm -rf ./test/testdb.sqlite"
|
|
10
|
+
},
|
|
11
|
+
"xo": {
|
|
12
|
+
"rules": {
|
|
13
|
+
"unicorn/prefer-module": 0,
|
|
14
|
+
"unicorn/prefer-node-protocol": 0,
|
|
15
|
+
"@typescript-eslint/consistent-type-definitions": 0
|
|
16
|
+
}
|
|
17
|
+
},
|
|
18
|
+
"repository": {
|
|
19
|
+
"type": "git",
|
|
20
|
+
"url": "git+https://github.com/jaredwray/keyv.git"
|
|
21
|
+
},
|
|
22
|
+
"keywords": [
|
|
23
|
+
"key",
|
|
24
|
+
"value",
|
|
25
|
+
"store",
|
|
26
|
+
"cache",
|
|
27
|
+
"ttl"
|
|
28
|
+
],
|
|
29
|
+
"author": "Jared Wray <me@jaredwray.com> (http://jaredwray.com)",
|
|
30
|
+
"license": "MIT",
|
|
31
|
+
"bugs": {
|
|
32
|
+
"url": "https://github.com/jaredwray/keyv/issues"
|
|
33
|
+
},
|
|
34
|
+
"homepage": "https://github.com/jaredwray/keyv",
|
|
35
|
+
"dependencies": {
|
|
36
|
+
"json-buffer": "3.0.1"
|
|
37
|
+
},
|
|
38
|
+
"devDependencies": {
|
|
39
|
+
"@keyv/test-suite": "*",
|
|
40
|
+
"ava": "^5.0.1",
|
|
41
|
+
"eslint": "^8.26.0",
|
|
42
|
+
"eslint-plugin-promise": "^6.1.1",
|
|
43
|
+
"nyc": "^15.1.0",
|
|
44
|
+
"pify": "5.0.0",
|
|
45
|
+
"this": "^1.1.0",
|
|
46
|
+
"timekeeper": "^2.2.0",
|
|
47
|
+
"tsd": "^0.24.1",
|
|
48
|
+
"typescript": "^4.8.4",
|
|
49
|
+
"xo": "^0.52.4"
|
|
50
|
+
},
|
|
51
|
+
"tsd": {
|
|
52
|
+
"directory": "test"
|
|
53
|
+
},
|
|
54
|
+
"types": "./src/index.d.ts",
|
|
55
|
+
"files": [
|
|
56
|
+
"src"
|
|
57
|
+
]
|
|
52
58
|
}
|
|
@@ -0,0 +1,116 @@
|
|
|
1
|
+
import {EventEmitter} from 'events';
|
|
2
|
+
|
|
3
|
+
type WithRequiredProperties<T, K extends keyof T> = T & Required<Pick<T, K>>;
|
|
4
|
+
|
|
5
|
+
declare class Keyv<Value = any, Options extends Record<string, any> = Record<string, unknown>> extends EventEmitter {
|
|
6
|
+
/**
|
|
7
|
+
* `this.opts` is an object containing at least the properties listed
|
|
8
|
+
* below. However, `Keyv.Options` allows arbitrary properties as well.
|
|
9
|
+
* These properties can be specified as the second type parameter to `Keyv`.
|
|
10
|
+
*/
|
|
11
|
+
opts: WithRequiredProperties<
|
|
12
|
+
Keyv.Options<Value>,
|
|
13
|
+
'deserialize' | 'namespace' | 'serialize' | 'store' | 'uri'
|
|
14
|
+
> &
|
|
15
|
+
Options;
|
|
16
|
+
|
|
17
|
+
/**
|
|
18
|
+
* @param opts The options object is also passed through to the storage adapter. Check your storage adapter docs for any extra options.
|
|
19
|
+
*/
|
|
20
|
+
constructor(options?: Keyv.Options<Value> & Options);
|
|
21
|
+
/**
|
|
22
|
+
* @param uri The connection string URI.
|
|
23
|
+
*
|
|
24
|
+
* Merged into the options object as options.uri.
|
|
25
|
+
* @param opts The options object is also passed through to the storage adapter. Check your storage adapter docs for any extra options.
|
|
26
|
+
*/
|
|
27
|
+
constructor(uri?: string, options?: Keyv.Options<Value> & Options);
|
|
28
|
+
|
|
29
|
+
/** Returns the value. */
|
|
30
|
+
get<Raw extends boolean = false>(key: string, options?: {raw?: Raw}):
|
|
31
|
+
Promise<(Raw extends false
|
|
32
|
+
? Value
|
|
33
|
+
: Keyv.DeserializedData<Value>) | undefined>;
|
|
34
|
+
|
|
35
|
+
/** Returns an array of values. Uses `store.getMany` if it exists, otherwise uses parallel calls to `store.get`. */
|
|
36
|
+
get<Raw extends boolean = false>(
|
|
37
|
+
key: string[],
|
|
38
|
+
options?: {raw?: Raw}
|
|
39
|
+
): Promise<
|
|
40
|
+
Array<(Raw extends false ? Value : Keyv.DeserializedData<Value>) | undefined>
|
|
41
|
+
>;
|
|
42
|
+
|
|
43
|
+
/**
|
|
44
|
+
* Set a value.
|
|
45
|
+
*
|
|
46
|
+
* By default keys are persistent. You can set an expiry TTL in milliseconds.
|
|
47
|
+
*/
|
|
48
|
+
set(key: string, value: Value, ttl?: number): Promise<true>;
|
|
49
|
+
/**
|
|
50
|
+
* Deletes an entry.
|
|
51
|
+
*
|
|
52
|
+
* Returns `true` if the key existed, `false` if not.
|
|
53
|
+
*/
|
|
54
|
+
delete(key: string | string[]): Promise<boolean>;
|
|
55
|
+
/** Delete all entries in the current namespace. */
|
|
56
|
+
clear(): Promise<void>;
|
|
57
|
+
/** Check if key exists in current namespace. */
|
|
58
|
+
has(key: string): Promise<boolean>;
|
|
59
|
+
/** Iterator */
|
|
60
|
+
iterator(namespace?: string): AsyncGenerator<any, void, any>;
|
|
61
|
+
/**
|
|
62
|
+
* Closes the connection.
|
|
63
|
+
*
|
|
64
|
+
* Returns `undefined` when the connection closes.
|
|
65
|
+
*/
|
|
66
|
+
disconnect(): Promise<void>;
|
|
67
|
+
}
|
|
68
|
+
|
|
69
|
+
declare namespace Keyv {
|
|
70
|
+
interface Options<Value> {
|
|
71
|
+
[key: string]: any;
|
|
72
|
+
|
|
73
|
+
/** Namespace for the current instance. */
|
|
74
|
+
namespace?: string | undefined;
|
|
75
|
+
/** A custom serialization function. */
|
|
76
|
+
serialize?: ((data: DeserializedData<Value>) => string) | undefined;
|
|
77
|
+
/** A custom deserialization function. */
|
|
78
|
+
deserialize?: ((data: string) => DeserializedData<Value> | undefined) | undefined;
|
|
79
|
+
/** The connection string URI. */
|
|
80
|
+
uri?: string | undefined;
|
|
81
|
+
/** The storage adapter instance to be used by Keyv. */
|
|
82
|
+
store?: Store<string | undefined> | undefined;
|
|
83
|
+
/** Default TTL. Can be overridden by specififying a TTL on `.set()`. */
|
|
84
|
+
ttl?: number | undefined;
|
|
85
|
+
/** Specify an adapter to use. e.g `'redis'` or `'mongodb'`. */
|
|
86
|
+
adapter?: 'redis' | 'mongodb' | 'mongo' | 'sqlite' | 'postgresql' | 'postgres' | 'mysql' | undefined;
|
|
87
|
+
/** Enable compression option **/
|
|
88
|
+
compression?: CompressionAdapter | undefined;
|
|
89
|
+
}
|
|
90
|
+
|
|
91
|
+
interface CompressionAdapter {
|
|
92
|
+
compress(value: any, options?: any): Promise<any>;
|
|
93
|
+
decompress(value: any, options?: any): Promise<any>;
|
|
94
|
+
serialize(value: any): Promise<any>;
|
|
95
|
+
deserialize(value: any): Promise<any>;
|
|
96
|
+
}
|
|
97
|
+
|
|
98
|
+
interface DeserializedData<Value> {
|
|
99
|
+
value: Value; expires: number | undefined;
|
|
100
|
+
}
|
|
101
|
+
|
|
102
|
+
type StoredData<Value> = DeserializedData<Value> | string | undefined;
|
|
103
|
+
|
|
104
|
+
interface Store<Value> {
|
|
105
|
+
get(key: string): Value | Promise<Value | undefined> | undefined;
|
|
106
|
+
set(key: string, value: Value, ttl?: number): any;
|
|
107
|
+
delete(key: string): boolean | Promise<boolean>;
|
|
108
|
+
clear(): void | Promise<void>;
|
|
109
|
+
has?(key: string): boolean | Promise<boolean>;
|
|
110
|
+
getMany?(
|
|
111
|
+
keys: string[]
|
|
112
|
+
): Array<StoredData<Value>> | Promise<Array<StoredData<Value>>> | undefined;
|
|
113
|
+
}
|
|
114
|
+
}
|
|
115
|
+
|
|
116
|
+
export = Keyv;
|