@owlmeans/redis-resource 0.1.7 → 0.1.9
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/README.md
CHANGED
|
@@ -87,3 +87,20 @@ Extends `Resource<T>` with:
|
|
|
87
87
|
- [`@owlmeans/redis`](../redis) — Redis connection service
|
|
88
88
|
- [`@owlmeans/resource`](../resource) — `Resource<T>` base interface
|
|
89
89
|
- [`@owlmeans/server-socket`](../server-socket) — WebSocket handlers often use Redis resources for streaming
|
|
90
|
+
|
|
91
|
+
<!-- owlmeans:agent-guidance:start -->
|
|
92
|
+
## Agent guidance
|
|
93
|
+
|
|
94
|
+
This package ships embedded Claude Code skills and GitHub Copilot instructions under
|
|
95
|
+
`agent-meta/`. After installing your `@owlmeans/*` packages, run the OwlMeans
|
|
96
|
+
agent-skills installer to place them into your project's native locations
|
|
97
|
+
(`.claude/skills/` and `.github/instructions/`):
|
|
98
|
+
|
|
99
|
+
```sh
|
|
100
|
+
npx @owlmeans/agent-skills
|
|
101
|
+
```
|
|
102
|
+
|
|
103
|
+
The embedded files are version-matched to this package release. Do not edit them
|
|
104
|
+
directly — they are regenerated on each publish. To contribute guidance edits,
|
|
105
|
+
open a PR against the source monorepo.
|
|
106
|
+
<!-- owlmeans:agent-guidance:end -->
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
---
|
|
2
|
+
description: "How to use @owlmeans/redis-resource — Redis-backed Resource implementation for caching/state with TTL support."
|
|
3
|
+
applyTo: "**/*.ts, **/*.tsx"
|
|
4
|
+
---
|
|
5
|
+
<!-- AUTO-GENERATED — do not edit. Regenerate via sync-agent-meta. -->
|
|
6
|
+
|
|
7
|
+
# @owlmeans/redis-resource
|
|
8
|
+
|
|
9
|
+
**Layer:** Infra
|
|
10
|
+
**Install:** `"@owlmeans/redis-resource": "^0.1.9"` in `dependencies`
|
|
11
|
+
|
|
12
|
+
## Key Exports
|
|
13
|
+
|
|
14
|
+
| Export | Description |
|
|
15
|
+
|--------|-------------|
|
|
16
|
+
| `makeRedisResource<T>(options)` | Redis-backed Resource factory |
|
|
17
|
+
| `RedisResource<T>` types | Resource interface |
|
|
18
|
+
| Constants | Default key prefix |
|
|
19
|
+
|
|
20
|
+
## Usage
|
|
21
|
+
|
|
22
|
+
```typescript
|
|
23
|
+
import { makeRedisResource } from '@owlmeans/redis-resource'
|
|
24
|
+
context.registerResource(makeRedisResource<SessionData>({ alias: 'sessions', prefix: 'sess:', ttl: 3600 }))
|
|
25
|
+
```
|
|
26
|
+
|
|
27
|
+
## Depends On
|
|
28
|
+
|
|
29
|
+
- `@owlmeans/redis`, `@owlmeans/resource`, `@owlmeans/server-context`
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
{
|
|
2
|
+
"schemaVersion": 1,
|
|
3
|
+
"package": "@owlmeans/redis-resource",
|
|
4
|
+
"version": "0.1.9",
|
|
5
|
+
"generatedAt": "2026-06-14T13:34:06.132Z",
|
|
6
|
+
"canonicalRepo": "https://github.com/owlmeans/common",
|
|
7
|
+
"entries": [
|
|
8
|
+
{
|
|
9
|
+
"kind": "skill",
|
|
10
|
+
"name": "redis-resource",
|
|
11
|
+
"category": "package-specific",
|
|
12
|
+
"file": "skills/redis-resource/SKILL.md",
|
|
13
|
+
"canonicalPath": ".claude/skills/redis-resource/SKILL.md"
|
|
14
|
+
},
|
|
15
|
+
{
|
|
16
|
+
"kind": "instruction",
|
|
17
|
+
"name": "redis-resource",
|
|
18
|
+
"category": "package-specific",
|
|
19
|
+
"file": "instructions/redis-resource.instructions.md",
|
|
20
|
+
"canonicalPath": ".github/instructions/redis-resource.instructions.md"
|
|
21
|
+
}
|
|
22
|
+
]
|
|
23
|
+
}
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: redis-resource
|
|
3
|
+
description: How to use @owlmeans/redis-resource — Redis-backed Resource implementation for caching/state with TTL support. Auto-invoked when defining a resource backed by Redis.
|
|
4
|
+
user-invocable: false
|
|
5
|
+
---
|
|
6
|
+
<!-- AUTO-GENERATED — do not edit. Regenerate via sync-agent-meta. -->
|
|
7
|
+
|
|
8
|
+
# @owlmeans/redis-resource
|
|
9
|
+
|
|
10
|
+
**Layer:** Infra
|
|
11
|
+
**Install:** `"@owlmeans/redis-resource": "^0.1.9"` in `dependencies`
|
|
12
|
+
|
|
13
|
+
## Key Exports
|
|
14
|
+
|
|
15
|
+
| Export | Description |
|
|
16
|
+
|--------|-------------|
|
|
17
|
+
| `makeRedisResource<T>(options)` | Factory for a Redis-backed Resource<T> |
|
|
18
|
+
| `RedisResource<T>` types | Resource interface (with TTL) |
|
|
19
|
+
| Constants | Default key prefix |
|
|
20
|
+
|
|
21
|
+
## Usage
|
|
22
|
+
|
|
23
|
+
```typescript
|
|
24
|
+
import { makeRedisResource } from '@owlmeans/redis-resource'
|
|
25
|
+
|
|
26
|
+
context.registerResource(makeRedisResource<SessionData>({
|
|
27
|
+
alias: 'sessions',
|
|
28
|
+
prefix: 'sess:',
|
|
29
|
+
ttl: 3600,
|
|
30
|
+
}))
|
|
31
|
+
```
|
|
32
|
+
|
|
33
|
+
## Depends On
|
|
34
|
+
|
|
35
|
+
- `@owlmeans/redis`, `@owlmeans/resource`, `@owlmeans/server-context`
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@owlmeans/redis-resource",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.9",
|
|
4
4
|
"license": "MIT",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"scripts": {
|
|
@@ -25,10 +25,10 @@
|
|
|
25
25
|
"ioredis": "*"
|
|
26
26
|
},
|
|
27
27
|
"dependencies": {
|
|
28
|
-
"@owlmeans/basic-ids": "^0.1.
|
|
29
|
-
"@owlmeans/context": "^0.1.
|
|
30
|
-
"@owlmeans/resource": "^0.1.
|
|
31
|
-
"@owlmeans/server-context": "^0.1.
|
|
28
|
+
"@owlmeans/basic-ids": "^0.1.9",
|
|
29
|
+
"@owlmeans/context": "^0.1.9",
|
|
30
|
+
"@owlmeans/resource": "^0.1.9",
|
|
31
|
+
"@owlmeans/server-context": "^0.1.9"
|
|
32
32
|
},
|
|
33
33
|
"devDependencies": {
|
|
34
34
|
"@owlmeans/dep-config": "workspace:*",
|