Skip to content

Commit 2ecdd14

Browse files
committed
More polishing of agents and skills
1 parent e91b646 commit 2ecdd14

25 files changed

Lines changed: 168 additions & 183 deletions

File tree

.agents/skills/api-design/SKILL.md

Lines changed: 8 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -2,15 +2,18 @@
22
name: api-design
33
description: API stability annotations, design principles, and patterns for the MongoDB Java Driver. Use when adding or modifying public API surface — new classes, methods, interfaces, or changing method signatures.
44
---
5-
65
# API Design
76

87
## API Stability Annotations
98

10-
- `@Alpha` — Early development, may be removed. Not for production use.
11-
- `@Beta` — Subject to change or removal. Libraries should not depend on these.
12-
- `@Evolving` — May add abstract methods in future releases. Safe to use, but implementing/extending bears upgrade risk.
13-
- `@Sealed` — Must not be extended or implemented by consumers. Safe to use, but not to subclass.
9+
- `@Alpha` — Early development, may be removed.
10+
Not for production use.
11+
- `@Beta` — Subject to change or removal.
12+
Libraries should not depend on these.
13+
- `@Evolving` — May add abstract methods in future releases.
14+
Safe to use, but implementing/extending bears upgrade risk.
15+
- `@Sealed` — Must not be extended or implemented by consumers.
16+
Safe to use, but not to subclass.
1417
- `@Deprecated` — Supported until next major release but should be migrated away from.
1518

1619
## Design Principles

.agents/skills/evergreen/SKILL.md

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,12 +2,12 @@
22
name: evergreen
33
description: Evergreen CI infrastructure, configuration validation. Use when modifying .evergreen/ config, preparing to submit changes or understanding the Evergreen test matrix.
44
---
5-
65
# Evergreen
76

87
## Evergreen (MongoDB Internal CI)
98

10-
Primary CI runs on MongoDB's Evergreen system. Configuration lives in `.evergreen/`.
9+
Primary CI runs on MongoDB’s Evergreen system.
10+
Configuration lives in `.evergreen/`.
1111

1212
- Do not modify `.evergreen/` configuration without review
1313
- Evergreen runs the full test matrix across MongoDB versions, OS platforms, and JDK versions
@@ -30,4 +30,5 @@ To test your changes on Evergreen before merging, create a patch build:
3030
evergreen patch -u
3131
```
3232

33-
This uploads your uncommitted and committed local changes as a patch build on Evergreen, allowing you to run the full CI test matrix against your branch.
33+
This uploads your uncommitted and committed local changes as a patch build on Evergreen, allowing you to run the full CI
34+
test matrix against your branch.

.agents/skills/project-guide/SKILL.md

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,6 @@
22
name: project-guide
33
description: Project structure, dependency graph, and guide for finding the right project to work in. Use when starting a task and unsure which project owns the relevant code, or when you need to understand cross-project dependencies.
44
---
5-
65
# Project Guide
76

87
## Project Structure

.agents/skills/spec-tests/SKILL.md

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -2,14 +2,12 @@
22
name: spec-tests
33
description: How to work with MongoDB specification tests — structure, rules, and adding new spec test support. Use when implementing or modifying behavior defined by the MongoDB Driver Specifications, or when working with the test data in testing/resources/specifications/.
44
---
5-
65
# MongoDB Specification Tests
76

87
## Overview
98

10-
The driver implements the
11-
[MongoDB Driver Specifications](https://github.com/mongodb/specifications). Specification
12-
test data files live in `testing/resources/specifications/` — a git submodule.
9+
The driver implements the [MongoDB Driver Specifications](https://github.com/mongodb/specifications).
10+
Specification test data files live in `testing/resources/specifications/` — a git submodule.
1311

1412
## Rules
1513

@@ -40,4 +38,4 @@ testing/
4038
1. Check `testing/resources/specifications/` for the relevant spec test data
4139
2. Find existing test runners in the module (look for `*SpecificationTest*` or similar)
4240
3. Extend existing patterns — each module handles spec tests slightly differently
43-
4. Ensure tests run with `./gradlew check` or the module's test task
41+
4. Ensure tests run with `./gradlew check` or the modules test task

.agents/skills/style-reference/SKILL.md

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,6 @@
22
name: style-reference
33
description: Detailed code style rules for Java, Kotlin, Scala, and Groovy in the MongoDB Java Driver. Use when you need specific formatting rules beyond the basics in root AGENTS.md — e.g., line length, import ordering, brace style, or language-specific formatter configuration. Spotless auto-enforces most rules.
44
---
5-
65
# Style Reference
76

87
## Java Style Rules

.agents/skills/testing-guide/SKILL.md

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,6 @@
22
name: testing-guide
33
description: Testing frameworks, conventions, and commands for the MongoDB Java Driver. Use when writing or running tests — covers framework selection per module, test naming conventions, integration test setup, and how to run specific test subsets.
44
---
5-
65
# Testing Guide
76

87
## Frameworks
@@ -49,7 +48,7 @@ description: Testing frameworks, conventions, and commands for the MongoDB Java
4948
## Module-Specific Notes
5049

5150
- **driver-core:** Largest test suite — JUnit 5 + Spock + Mockito
52-
- **driver-sync:** JUnit 5 + Spock (heavy Spock usage, but don't add new)
51+
- **driver-sync:** JUnit 5 + Spock (heavy Spock usage, but dont add new)
5352
- **driver-reactive-streams:** JUnit 5 + Spock + Project Reactor
5453
- **bson-scala / driver-scala:** ScalaTest, test per Scala version
5554
- **Kotlin modules:** JUnit 5 + mockito-kotlin

AGENTS.md

Lines changed: 11 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,10 @@
11
# AGENTS.md - MongoDB Java Driver
22

3-
Official MongoDB JVM driver monorepo (Java, Kotlin, Scala).
43
All changes require human review.
5-
Breaking changes to public API require a major version bump — always warn if binary
6-
compatibility is affected.
4+
Breaking changes to public API require a major version bump — always warn if binary compatibility is affected.
75
Also consult `.AGENTS.md` / `~/.AGENTS.md` if present for local agent settings.
86

9-
See [`.agents/skills/project-guide`](.agents/skills/project-guide/SKILL.md) for module
10-
structure and dependency graph.
7+
See [`.agents/skills/project-guide`](.agents/skills/project-guide/SKILL.md) for module structure and dependency graph.
118
Each module has its own `AGENTS.md`.
129

1310
## Core Rules
@@ -23,8 +20,7 @@ Each module has its own `AGENTS.md`.
2320

2421
## Build
2522

26-
Gradle with Kotlin DSL. Build JDK: 17+. Source baseline: Java 8. Versions in
27-
`gradle/libs.versions.toml`.
23+
Gradle with Kotlin DSL. Build JDK: 17+. Source baseline: Java 8. Versions in `gradle/libs.versions.toml`.
2824

2925
```bash
3026
./gradlew check # Full validation (format + static checks + tests)
@@ -36,8 +32,7 @@ Gradle with Kotlin DSL. Build JDK: 17+. Source baseline: Java 8. Versions in
3632

3733
`check` runs `spotlessApply` automatically — formatting is enforced.
3834
Do not reformat outside your changes.
39-
See [`.agents/skills/style-reference`](.agents/skills/style-reference/SKILL.md) for full
40-
rules.
35+
See [`.agents/skills/style-reference`](.agents/skills/style-reference/SKILL.md) for full rules.
4136

4237
- No `System.out.println` / `System.err.println` — use SLF4J
4338
- No `e.printStackTrace()` — use proper error handling
@@ -48,15 +43,14 @@ rules.
4843

4944
- Every code change must include tests.
5045
Do not reduce coverage.
51-
- JUnit 5 primary. Spock is legacy — do not add new Spock tests.
52-
- Unit tests must not require a running MongoDB instance.
53-
- Descriptive method names or `@DisplayName`. Clean up in `@AfterEach`.
46+
- See [`.agents/skills/testing-guide`](.agents/skills/testing-guide/SKILL.md) for framework details and running specific
47+
tests.
48+
- See [`.agents/skills/spec-tests`](.agents/skills/spec-tests/SKILL.md) for MongoDB specification test conventions.
5449

5550
## API
5651

57-
All `com.mongodb.internal.*` / `org.bson.internal.*` is private API — never expose in
58-
public APIs. See [`.agents/skills/api-design`](.agents/skills/api-design/SKILL.md) for
59-
stability annotations and design principles.
52+
All `com.mongodb.internal.*` / `org.bson.internal.*` is private API — never expose in public APIs.
53+
See [`.agents/skills/api-design`](.agents/skills/api-design/SKILL.md) for stability annotations and design principles.
6054

6155
## Do Not Modify Without Human Approval
6256

@@ -68,14 +62,10 @@ stability annotations and design principles.
6862
- Spec test data submodule (`testing/resources/specifications/`)
6963
- Release/versioning scripts, `.evergreen/` config, credentials/secrets
7064

71-
See [`.agents/skills/evergreen`](.agents/skills/evergreen/SKILL.md) for CI validation
72-
and patch builds.
65+
See [`.agents/skills/evergreen`](.agents/skills/evergreen/SKILL.md) for CI validation and patch builds.
7366

7467
## Before Submitting
7568

7669
```bash
77-
./gradlew doc check scalaCheck # Docs + formatting (spotlessApply) + static checks + all tests
70+
./gradlew spotlessApply doc check scalaCheck # formatting + Docs + static checks + all tests
7871
```
79-
80-
Note: `check` includes `spotlessApply` for all modules.
81-
`buildSrc` uses `spotlessCheck` instead (no auto-fix).

0 commit comments

Comments
 (0)