@luckystack/core 0.1.1 → 0.1.3

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.
@@ -375,7 +375,7 @@ Resolves after `setTimeout(ms)`. Used in fanout-yield loops and dev-mode hot rel
375
375
  | `DNS` | `''` | Reserved. |
376
376
  | `REDIS_HOST` | `'127.0.0.1'` | Default redis client. |
377
377
  | `REDIS_PORT` | `'6379'` | Same. |
378
- | `REDIS_USERNAME` | (unset) | Optional ioredis auth. |
378
+ | `REDIS_USER` | (unset) | Optional ioredis auth. |
379
379
  | `REDIS_PASSWORD` | (unset) | Optional ioredis auth. |
380
380
  | `PROJECT_NAME` | `'luckystack'` | `getProjectName` fallback. |
381
381
  | `LUCKYSTACK_ENV` | (unset) | `resolveEnvKey` first preference. |
@@ -23,7 +23,7 @@ export default redis
23
23
  **Behavior:**
24
24
  - Every method/property access is forwarded to whatever `getRedisClient()` currently returns.
25
25
  - When the consumer has called `registerRedisClient(...)`, that client wins.
26
- - Otherwise the proxy lazily constructs a default ioredis instance from `env.REDIS_HOST` / `env.REDIS_PORT` (plus optional `REDIS_USERNAME` / `REDIS_PASSWORD`) on first access.
26
+ - Otherwise the proxy lazily constructs a default ioredis instance from `env.REDIS_HOST` / `env.REDIS_PORT` (plus optional `REDIS_USER` / `REDIS_PASSWORD`) on first access.
27
27
  - The default client installs a `connect` listener that logs `"Connected to Redis"` via `getLogger().info` and an `error` listener that routes to `getLogger().error`.
28
28
  - The default client uses an exponential `retryStrategy(times => Math.min(times * 50, 2000))`.
29
29
 
@@ -55,7 +55,7 @@ export const getRedisConnectionOptions = (): RedisConnectionOptions
55
55
 
56
56
  **Behavior:**
57
57
  - Reads `env.REDIS_HOST` and parses `env.REDIS_PORT` to a number.
58
- - Includes `username` only when `process.env.REDIS_USERNAME` is non-empty.
58
+ - Includes `username` only when `process.env.REDIS_USER` is non-empty.
59
59
  - Includes `password` only when `process.env.REDIS_PASSWORD` is non-empty.
60
60
  - Read at call time so dotenv timing doesn't capture stale values.
61
61
 
@@ -100,7 +100,7 @@ setIoInstance(io);
100
100
  |---|---|---|
101
101
  | `REDIS_HOST` | `'127.0.0.1'` | Default client + `getRedisConnectionOptions`. |
102
102
  | `REDIS_PORT` | `'6379'` | Same. |
103
- | `REDIS_USERNAME` | (unset) | Optional ioredis auth. |
103
+ | `REDIS_USER` | (unset) | Optional ioredis auth. |
104
104
  | `REDIS_PASSWORD` | (unset) | Optional ioredis auth. |
105
105
 
106
106
  ## Related
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@luckystack/core",
3
- "version": "0.1.1",
3
+ "version": "0.1.3",
4
4
  "private": false,
5
5
  "publishConfig": {
6
6
  "access": "public"