Skip to content

Commit 98016b6

Browse files
authored
Merge pull request #6044 from redis/release/3.6.0
merge release/3.6.0 to latest
2 parents b7d8f7b + 90490eb commit 98016b6

1,747 files changed

Lines changed: 44934 additions & 65546 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.agents/skills

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
../.ai/skills

.ai/README.md

Lines changed: 45 additions & 42 deletions
Original file line numberDiff line numberDiff line change
@@ -7,36 +7,35 @@ This directory contains the **single source of truth** for AI-assisted developme
77
This repository uses a centralized approach to AI development rules:
88

99
- **`AGENTS.md`** (at repository root) - Entry point for AI agents with essential commands, testing instructions, and quick reference
10-
- **`.ai/rules/`** - Detailed development standards organized by topic
11-
- **`.ai/skills/`** - Agent skills (local and from npm packages)
10+
- **`.ai/skills/`** - Detailed development standards as skills, plus skills from npm packages
1211
- **`.ai/commands/`** - AI workflow commands and templates
1312

14-
These rules are used by multiple AI coding assistants:
13+
These standards are consumed by:
1514

16-
- **Cursor** (via symlinks: `.cursor/rules/` and `.cursor/commands/`)
17-
- **Augment** (via symlink: `.augment/`)
18-
- **Windsurf** (via symlink: `.windsurfrules`)
19-
- **GitHub Copilot** (via file: `.github/copilot-instructions.md`)
15+
- **Claude Code** (via `CLAUDE.md -> AGENTS.md` plus `.claude/commands/` and `.claude/skills/` symlinks)
16+
- **Codex** (via `AGENTS.md` and the `.agents/skills` symlink)
17+
- **GitHub Copilot** (via file: `.github/copilot-instructions.md`, optional)
2018

2119
## Structure
2220

2321
```
2422
AGENTS.md # 🎯 AI agent entry point
23+
CLAUDE.md -> AGENTS.md # Claude Code entry point
2524
.ai/ # Single source of truth
2625
├── README.md # This file (human-readable overview)
27-
├── rules/ # Development standards (modular)
28-
│ ├── code-quality.md # Linting, TypeScript standards
29-
│ ├── frontend.md # React, Redux, UI patterns
30-
│ ├── backend.md # NestJS, API patterns
31-
│ ├── testing.md # Testing standards
32-
│ ├── branches.md # Branch naming conventions
33-
│ ├── commits.md # Commit message guidelines
34-
── pull-requests.md # Pull request process
35-
├── skills/ # Agent skills
36-
│ ├── branches/ # Branch naming skill
37-
│ ├── commits/ # Commit message skill
38-
│ ├── pull-requests/ # Pull request skill
39-
| ── feature-flags/SKILL.md # Feature flag lifecycle
26+
├── skills/ # Development standards and agent skills
27+
│ ├── code-quality/SKILL.md # Linting, TypeScript standards, naming, imports
28+
│ ├── frontend/SKILL.md # React, Redux, styled-components, UI patterns
29+
│ ├── backend/SKILL.md # NestJS, API patterns, DI, error handling
30+
│ ├── testing/SKILL.md # Jest/Testing Library standards, faker, helpers
31+
│ ├── e2e-testing/SKILL.md # Playwright standards, page objects, fixtures
32+
│ ├── git-safety/SKILL.md # Protected-branch guardrails
33+
── branches/SKILL.md # Branch naming
34+
├── commits/SKILL.md # Commit messages (Conventional Commits)
35+
│ ├── pull-requests/SKILL.md # Pull request process
36+
│ ├── feature-flags/SKILL.md # Feature flag lifecycle
37+
│ ├── tsconfigs/SKILL.md # TypeScript configuration
38+
── type-check-baselines/SKILL.md # TS error baseline workflow
4039
│ └── redis-ui-components/ -> node_modules/@redis-ui/components/skills/redis-ui-components
4140
│ ├── SKILL.md # Component catalog and usage patterns
4241
│ └── references/ # Per-component API docs (Button, Select, etc.)
@@ -45,16 +44,17 @@ AGENTS.md # 🎯 AI agent entry point
4544
├── commit-message.md # Commit message generation
4645
└── pull-request-review.md # PR review workflow
4746
48-
# Symlinks (all AI tools read from .ai/)
49-
.cursor/
50-
├── rules/ -> ../.ai/rules/ # Cursor AI (rules)
51-
├── commands/ -> ../.ai/commands/ # Cursor AI (commands)
52-
└── skills/ -> ../.ai/skills/ # Cursor AI (skills)
53-
.augment/ -> .ai/ # Augment AI
54-
.windsurfrules -> .ai/ # Windsurf AI
55-
.github/copilot-instructions.md # GitHub Copilot
47+
# Symlinks
48+
.claude/
49+
├── commands/ -> ../.ai/commands/ # Claude Code (commands)
50+
└── skills/ -> ../.ai/skills/ # Claude Code (skills)
51+
.agents/
52+
└── skills -> ../.ai/skills # Codex (skills)
53+
.github/copilot-instructions.md # GitHub Copilot reference (if used)
5654
```
5755

56+
**Codex note**: Codex reads `AGENTS.md` for project instructions and discovers repo skills from `.agents/skills`. Do not create `.codex/rules/`: Codex `.rules` files are command execution policies, not Markdown development guidelines.
57+
5858
## For AI Agents
5959

6060
**Start here**: Read `AGENTS.md` at the repository root for:
@@ -65,20 +65,23 @@ AGENTS.md # 🎯 AI agent entry point
6565
- Git workflow guidelines
6666
- Boundaries and best practices
6767

68-
**Then refer to**: `.ai/rules/` for detailed guidelines on specific topics.
68+
**Then refer to**: `.ai/skills/` for detailed guidelines on specific topics.
6969

7070
## For Human Developers
7171

72-
This directory contains comprehensive development standards that are automatically used by AI coding assistants. The rules are organized into modular files for easy maintenance:
73-
74-
- **Code Quality Standards**: `.ai/rules/code-quality.md` - TypeScript standards, import organization, best practices
75-
- **Frontend Patterns**: `.ai/rules/frontend.md` - React, Redux, styled-components, UI component usage
76-
- **Backend Patterns**: `.ai/rules/backend.md` - NestJS, dependency injection, API patterns
77-
- **Testing Standards**: `.ai/rules/testing.md` - Testing patterns, faker usage, test helpers
78-
- **Branch Naming**: `.ai/rules/branches.md` - Branch naming conventions
79-
- **Commit Messages**: `.ai/rules/commits.md` - Commit message guidelines (Conventional Commits)
80-
- **Pull Request Process**: `.ai/rules/pull-requests.md` - PR creation and review guidelines
72+
This directory contains comprehensive development standards used by AI coding assistants. Each topic lives in its own skill folder:
73+
74+
- **Code Quality**: `.ai/skills/code-quality/SKILL.md` - TypeScript standards, import organization, best practices
75+
- **Frontend**: `.ai/skills/frontend/SKILL.md` - React, Redux, styled-components, UI component usage
76+
- **Backend**: `.ai/skills/backend/SKILL.md` - NestJS, dependency injection, API patterns
77+
- **Testing**: `.ai/skills/testing/SKILL.md` - Jest/Testing Library patterns, faker, helpers
78+
- **E2E Testing**: `.ai/skills/e2e-testing/SKILL.md` - Playwright standards, page objects
79+
- **Git Safety**: `.ai/skills/git-safety/SKILL.md` - Protected-branch guardrails
80+
- **Branches**: `.ai/skills/branches/SKILL.md` - Branch naming conventions
81+
- **Commits**: `.ai/skills/commits/SKILL.md` - Commit message guidelines (Conventional Commits)
82+
- **Pull Requests**: `.ai/skills/pull-requests/SKILL.md` - PR creation and review guidelines
8183
- **Feature Flags**: `.ai/skills/feature-flags/SKILL.md` - Adding, promoting, and removing feature flags
84+
- **TS Error Baselines**: `.ai/skills/type-check-baselines/SKILL.md` - TypeScript error baseline workflow
8285
- **Redis UI Components**: `.ai/skills/redis-ui-components/` - Component API references, props, and usage examples (sourced from `@redis-ui/components` npm package via symlink)
8386

8487
## MCP (Model Context Protocol) Setup
@@ -137,11 +140,11 @@ The `mcp.json` file configures these services:
137140

138141
## Updating These Rules
139142

140-
To update AI rules:
143+
To update AI standards:
141144

142-
1. **Edit files in `.ai/` only** (never edit symlinked files directly)
143-
2. **Update `AGENTS.md`** if you change commands, testing instructions, or boundaries
144-
3. Changes automatically propagate to all AI tools via symlinks
145+
1. **Edit `SKILL.md` files under `.ai/skills/`** (never edit symlinked files directly)
146+
2. **Update `AGENTS.md`** if you change commands, testing instructions, or the always-on rules block
147+
3. Changes propagate to Claude Code automatically via the `.claude/` symlinks
145148
4. Commit changes to version control
146149

147150
**Remember**: These rules exist to maintain code quality and consistency. Follow them, but also use good judgment.

.ai/commands/e2e-fix.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ argument-hint: <test-pattern>
77

88
Run E2E tests matching a pattern, analyze failures, and fix them.
99

10-
**Follow all standards in `.ai/rules/e2e-testing.md`**
10+
**Follow all standards in `.ai/skills/e2e-testing/SKILL.md`**
1111

1212
## Input
1313

.ai/commands/e2e-generate.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ argument-hint: <ticket-id or ticket-url>
77

88
Use Playwright MCP to explore a page, discover testable functionality, and generate E2E tests based on a Jira ticket.
99

10-
**Follow all standards in `.ai/rules/e2e-testing.md`**
10+
**Follow all standards in `.ai/skills/e2e-testing/SKILL.md`**
1111

1212
**Reference:** @tests/e2e-playwright/TEST_PLAN.md
1313

@@ -73,11 +73,11 @@ Run only the new tests using list reporter (no HTML report):
7373

7474
```bash
7575
cd tests/e2e-playwright
76-
npx playwright test tests/main/{feature}/{action}/ --project=chromium --reporter=list
76+
npx playwright test tests/parallel/{feature}/{action}/ --project=chromium-parallel --reporter=list
7777
npm run lint && npx tsc --noEmit
7878
```
7979

80-
**Note:** Use `--reporter=list` to avoid Playwright generating and hosting an HTML report. Use `--project=chromium` to run only browser tests (faster feedback).
80+
**Note:** Use `--reporter=list` to avoid Playwright generating and hosting an HTML report. Use `--project=chromium-parallel` to run only browser tests (faster feedback).
8181

8282
### Step 7: Update Test Plan
8383

.ai/commands/pr-plan.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -307,8 +307,8 @@ After saving the plan document:
307307
- **ALWAYS save the plan document** - use `write` tool to save to `docs/pr-plan-{ticket-id}-{brief-description}.md`
308308
- **Use main branch as baseline** - all analysis should be against current main
309309
- **Be specific and actionable** - every task should be clear and verifiable
310-
- **Consider PR stacking** - plan for small, reviewable PRs (see `.ai/rules/pull-requests.md`). plan breaking the implementation in a stack of PRs.
311-
- **Follow all project standards** - reference rules in `.ai/rules/`
310+
- **Consider PR stacking** - plan for small, reviewable PRs (see `.ai/skills/pull-requests/SKILL.md`). plan breaking the implementation in a stack of PRs.
311+
- **Follow all project standards** - reference skills in `.ai/skills/`
312312
- **Document assumptions** - if anything is unclear, document the assumption made
313313
- **Identify blockers early** - surface dependencies and knowledge gaps upfront
314314

Lines changed: 11 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,15 @@
11
---
2-
description: NestJS backend development patterns, module structure, services, controllers, DTOs, and error handling
3-
globs: redisinsight/api/**/*.ts
4-
alwaysApply: false
2+
name: backend
3+
description: >-
4+
NestJS backend development patterns for the RedisInsight API:
5+
module structure, services, controllers, DTOs, dependency injection,
6+
and error handling. Use when editing any file under
7+
redisinsight/api/**, writing or modifying NestJS modules,
8+
controllers, services, DTOs, providers, or when the user mentions
9+
the backend, API, or NestJS.
510
---
611

12+
713
# Backend Development (NestJS/API)
814

915
## Module Structure
@@ -72,7 +78,7 @@ export const FEATURE_ERROR_MESSAGES = {
7278

7379
1. Node.js built-in modules
7480
2. External dependencies (`@nestjs/*`, etc.)
75-
3. Internal modules (using `apiSrc/*` alias)
81+
3. Internal modules (using `src/*` alias — the backend's self-reference into `redisinsight/api/src/*`)
7682
4. Local relative imports
7783

7884
## Service Layer
@@ -192,7 +198,7 @@ this.logger.error('Error message', error.stack, { context })
192198

193199
### Redis Service Pattern
194200

195-
- Use RedisClient from `apiSrc/modules/redis`
201+
- Use RedisClient from `src/modules/redis`
196202
- Handle errors gracefully
197203
- Log Redis operations
198204
- Use try-catch for error handling

.ai/skills/branches/SKILL.md

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,14 @@
11
---
22
name: branches
33
description: >-
4-
Create and name git branches following project conventions and GitHub Actions
5-
enforcement rules. Use when creating branches, checking out new branches, or
6-
the user mentions branch naming.
4+
Create and name git branches following project conventions. Use when
5+
creating branches, checking out new branches, or the user mentions
6+
branch naming.
77
---
88

99
# Branch Naming Conventions
1010

11-
Use lowercase kebab-case with type prefix and issue/ticket identifier. **Branch names must match GitHub Actions workflow rules** (see `.github/workflows/enforce-branch-name-rules.yml`).
11+
Use lowercase kebab-case with type prefix and issue/ticket identifier.
1212

1313
```bash
1414
# Pattern: <type>/<issue-ref>/<short-title>
@@ -31,7 +31,7 @@ release/v2.0.0
3131
ric/RI-666/custom-prefix
3232
```
3333

34-
## Allowed Branch Types (GitHub Actions Enforced)
34+
## Branch Types
3535

3636
- `feature/` - New features and refactoring (affects multiple areas)
3737
- `bugfix/` - Bug fixes (affects multiple areas)
Lines changed: 16 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,16 @@
11
---
2-
alwaysApply: true
2+
name: code-quality
3+
description: >-
4+
Code-quality standards for RedisInsight: TypeScript strictness,
5+
naming conventions (camelCase, PascalCase, UPPER_SNAKE_CASE),
6+
linting rules, no `any` without reason, no `!important` in styles,
7+
and constant extraction. Use when writing or refactoring any
8+
TypeScript/JavaScript code in this repo, when ESLint or Prettier
9+
issues come up, or when the user mentions code style, lint, naming
10+
conventions, or general code quality.
311
---
412

13+
514
# Code Quality Standards
615

716
## Critical Rules
@@ -27,15 +36,17 @@ alwaysApply: true
2736

2837
1. External libraries (`react`, `lodash`, etc.)
2938
2. Built-in Node modules (`path`, `fs` - backend only)
30-
3. Internal modules with aliases (`uiSrc/*`, `apiSrc/*`)
39+
3. Internal modules with aliases (`uiSrc/*`, `apiClient`)
3140
4. Sibling/parent relative imports
3241
5. Style imports (ALWAYS LAST)
3342

3443
### Module Aliases
3544

36-
- `uiSrc/*``redisinsight/ui/src/*`
37-
- `apiSrc/*``redisinsight/api/src/*`
38-
- `desktopSrc/*``redisinsight/desktop/src/*`
45+
- `uiSrc/*``redisinsight/ui/src/*` (UI workspace)
46+
- `apiClient``redisinsight/api-client` (auto-generated OpenAPI types — the UI's only entry point into BE-defined shapes)
47+
- `desktopSrc/*``redisinsight/desktop/src/*` (desktop workspace)
48+
49+
The UI workspace must not import from the backend codebase directly. Use `apiClient` for types and the existing service layer (`uiSrc/services`) for HTTP calls.
3950

4051
**Use aliases**: `import { Button } from 'uiSrc/components/Button'`
4152
**Avoid relative**: `import { Button } from '../../../ui/src/components/Button'`

0 commit comments

Comments
 (0)