本文へ移動
cccskills
無料GitHub で公開

java-development

Use when working on any Java or JVM project: plain Java, libraries, CLI tools, Maven/Gradle builds, Spring Boot, Jakarta EE, MyBatis/MyBatis-Plus, JPA/Hibernate, Lombok, Java tests, Java code review, API design, exception handling, security review, refactoring, dependencies, Java version upgrades, javax/jakarta migrations, or JVM runtime troubleshooting such as GC, OOM, thread dumps, deadlocks, high CPU, and performance issues.

インストール方法を見る

含まれるファイル(55)

  • SKILL.md8.5 KB
  • .gitignore383 B
  • AGENTS.md1.1 KB
  • agents/openai.yaml483 B
  • assets/application.yml.template2.8 KB
  • assets/controller-service-test.java6.3 KB
  • assets/pom-spring-boot-2.xml3.2 KB
  • assets/pom-spring-boot-3.xml4.0 KB
  • build-tools/build-gradle-dependencies.md3.8 KB
  • build-tools/build-maven-dependencies.md4.1 KB
  • CLAUDE.md795 B
  • CODE_OF_CONDUCT.md5.1 KB
  • code-review/cr-anti-patterns.md6.7 KB
  • code-review/cr-concurrency.md7.8 KB
  • code-review/cr-equals-hashcode.md7.0 KB
  • code-review/cr-null-safety.md6.9 KB
  • code-review/cr-resource-leak.md6.4 KB
  • code-review/cr-security.md3.0 KB
  • code-review/cr-stream-pitfalls.md5.8 KB
  • CONTRIBUTING.md5.4 KB
  • core/java-api-design.md3.2 KB
  • core/java-exception-handling.md2.6 KB
  • core/java-general-development.md3.6 KB
  • core/java-version-modernization.md2.8 KB
  • examples/usage-examples.md2.6 KB
  • examples/usage-examples.zh.md2.6 KB
  • install.sh3.7 KB
  • jvm/jvm-cpu-high.md6.0 KB
  • jvm/jvm-gc-logs.md7.1 KB
  • jvm/jvm-gc-tuning.md7.6 KB
  • jvm/jvm-oom-analysis.md6.2 KB
  • jvm/jvm-thread-dump.md7.2 KB
  • LICENSE1.0 KB
  • metadata.json2.2 KB
  • README_zh.md8.8 KB
  • README.md12.5 KB
  • scripts/test-install.sh715 B
  • scripts/test-validate-skill.py3.3 KB
  • scripts/validate-skill.py13.5 KB
  • spring-boot/sb-actuator-health.md6.0 KB
  • spring-boot/sb-config-profiles.md4.8 KB
  • spring-boot/sb-dependency-injection.md6.4 KB
  • spring-boot/sb-exception-handling.md6.5 KB
  • spring-boot/sb-jpa-repository.md7.9 KB
  • spring-boot/sb-migration-2-to-3.md7.6 KB
  • spring-boot/sb-migration-3-to-4.md3.8 KB
  • spring-boot/sb-mybatis-plus.md9.9 KB
  • spring-boot/sb-project-structure.md4.9 KB
  • spring-boot/sb-rest-client.md5.8 KB
  • testing/test-coverage-assertj.md6.2 KB
  • testing/test-junit5.md7.2 KB
  • testing/test-layering.md6.1 KB
  • testing/test-mockito.md7.0 KB
  • testing/test-spring-boot-test.md6.9 KB
  • testing/test-testcontainers.md6.8 KB

SKILL.md(原文)

インストールする前に、エージェントに与えられる指示の中身を確認できます。

Java Development Agent

Router skill for general Java/JVM work. Treat Spring Boot as one supported framework, not the default for every project. Load only the matching rule files below.

Defaults

  • Output explanations in Chinese when the user uses Chinese; keep code unchanged unless editing.
  • First identify the current project's runtime, Java version, build tool, framework, test stack, and conventions. Existing evidence beats this skill's defaults.
  • Do not introduce Spring Boot, Maven, Gradle, Lombok, MyBatis-Plus, JPA, Testcontainers, or Java 17+ syntax unless the project already uses it or the user asks.
  • If creating a new project and no preference is given: choose a dependency-supported Java LTS baseline (17 or newer), infer Maven or Gradle from the surrounding repository, use JUnit 5, constructor-based design, SLF4J-compatible logging, and immutable DTOs where practical.
  • For a new Spring Boot project, verify the current stable release, Java/build requirements, and third-party starter compatibility from official sources before choosing a line. For existing projects, keep their supported line unless migration is requested.
  • Do not choose a persistence framework by geography or popularity. Preserve the existing choice; for greenfield work, select JDBC, jOOQ, MyBatis/MyBatis-Plus, or JPA/Hibernate from the actual query model and team constraints.
  • Prefer constructor injection in DI frameworks. Use Lombok (@RequiredArgsConstructor, @Slf4j) only when the project already uses Lombok; otherwise write explicit constructors/loggers.
  • If multiple modules or frameworks exist, modify only the affected module unless the user asks for a cross-cutting change.
  • Do not edit generated output unless explicitly requested; edit the source template, annotation processor input, schema, or generator configuration instead.

Loading Rules

Start with the smallest useful set:

  • Any Java task: load core/java-general-development.md only if project classification or default choice is unclear.
  • API/exception/version work: load the specific core/... rule before framework rules.
  • Build edits: load exactly one build rule (build-tools/...) matching the detected build tool.
  • Spring Boot edits: load the primary spring-boot/... rule only when the project actually uses Spring Boot.
  • Broad code review: start with code-review/cr-anti-patterns.md, then add specific risk files.
  • Test work: load testing/test-layering.md first, then the framework-specific test file.
  • JVM incident: load the symptom file first; add GC/thread/resource files only when evidence points there.
  • Do not load README files or examples/ unless the user asks for usage docs.

Work Rules

  • Inspect only relevant files before editing: build descriptor, source layout, dependency versions, framework style, and tests around the change.
  • Prefer the smallest safe change; do not perform broad refactors unless requested.
  • If business behavior is unclear, ask one concise question instead of inventing rules.
  • For non-trivial work, report: change reason, impact scope, verification performed, verification not performed, and the narrowest verification command/result.

Route By Task

Task signalRead firstAdd if needed
Unknown Java project, framework-neutral edit, library/CLI codecore/java-general-development.mdadd matching build-tools/..., testing/..., or code-review/... rule
Public API, interfaces, DTOs, compatibility, library contractscore/java-api-design.mdcode-review/cr-null-safety.md
Exceptions, retries, interrupts, failure boundariescore/java-exception-handling.mdcode-review/cr-resource-leak.md
Java 8/11/17/21 upgrade, newer syntax, toolchaincore/java-version-modernization.mdbuild-tools/build-maven-dependencies.md or build-tools/build-gradle-dependencies.md
Maven pom.xml, dependencies, BOM, plugins, Java releasebuild-tools/build-maven-dependencies.mdrelevant spring-boot/..., testing/..., or migration rule
Gradle build.gradle(.kts), wrapper, version catalog, toolchainbuild-tools/build-gradle-dependencies.mdrelevant spring-boot/..., testing/..., or migration rule
DI, beans, Lombok, service/controller skeletonspring-boot/sb-dependency-injection.mdspring-boot/sb-project-structure.md
Package layout, controller/service/repository boundariesspring-boot/sb-project-structure.mdspring-boot/sb-exception-handling.md
application.yml, profiles, secrets, config importspring-boot/sb-config-profiles.mdspring-boot/sb-actuator-health.md
MyBatis, MyBatis-Plus, mapper, wrapper, paginationspring-boot/sb-mybatis-plus.mdcode-review/cr-equals-hashcode.md
JPA, Hibernate, N+1, lazy loading, transactionsspring-boot/sb-jpa-repository.mdcode-review/cr-equals-hashcode.md
REST API error handling, validation errorsspring-boot/sb-exception-handling.mdcode-review/cr-null-safety.md
HTTP clients, RestClient, WebClient, RestTemplatespring-boot/sb-rest-client.mdspring-boot/sb-config-profiles.md
Actuator, health, metrics, probesspring-boot/sb-actuator-health.mdjvm/jvm-gc-logs.md
Spring Boot 2->3, javax/jakarta migrationspring-boot/sb-migration-2-to-3.mdbuild-tools/... plus spring-boot/sb-rest-client.md when HTTP clients are affected
Spring Boot 3->4, Framework 7/Jakarta/Servlet baselinespring-boot/sb-migration-3-to-4.mdbuild-tools/..., spring-boot/sb-rest-client.md, and affected testing/... rules
Java code review, general smell scancode-review/cr-anti-patterns.mdspecific review files below
Security review, secrets, injection, crypto, deserialization, SSRFcode-review/cr-security.mdspring-boot/sb-config-profiles.md plus relevant build/framework rule
Thread safety, locks, ThreadLocal, transactions proxycode-review/cr-concurrency.mdcode-review/cr-resource-leak.md
Closeable, JDBC, locks, thread pools, leakscode-review/cr-resource-leak.mdjvm/jvm-oom-analysis.md
NPE, Optional, nullable contractscode-review/cr-null-safety.mdcore/java-exception-handling.md or framework error rule
equals, hashCode, entity identitycode-review/cr-equals-hashcode.mdspring-boot/sb-jpa-repository.md or spring-boot/sb-mybatis-plus.md when entities are involved
Stream API, parallel stream, lambda side effectscode-review/cr-stream-pitfalls.mdcode-review/cr-concurrency.md
Test strategy, unit/slice/integration choicetesting/test-layering.mdtesting/test-junit5.md, testing/test-mockito.md, testing/test-spring-boot-test.md, or testing/test-testcontainers.md
JUnit 5 lifecycle, parameterized teststesting/test-junit5.mdtesting/test-coverage-assertj.md
Mockito mocks, spies, static mockstesting/test-mockito.mdtesting/test-layering.md
Testcontainers, real DB/Redis/Kafkatesting/test-testcontainers.mdtesting/test-spring-boot-test.md
@SpringBootTest, @WebMvcTest, @DataJpaTesttesting/test-spring-boot-test.mdtesting/test-testcontainers.md
AssertJ, JaCoCo, coverage floortesting/test-coverage-assertj.mdaffected testing/... framework rule
OOM, heap dump, memory leakjvm/jvm-oom-analysis.mdcode-review/cr-resource-leak.md
High CPU, hot thread, profilingjvm/jvm-cpu-high.mdjvm/jvm-thread-dump.md
Hang, deadlock, thread leakjvm/jvm-thread-dump.mdcode-review/cr-concurrency.md
GC pause, heap sizing, collector choicejvm/jvm-gc-tuning.mdjvm/jvm-gc-logs.md
GC log interpretationjvm/jvm-gc-logs.mdjvm/jvm-gc-tuning.md

Assets

  • assets/pom-spring-boot-3.xml: opt-in Spring Boot 3.x + MyBatis-Plus Maven example.
  • assets/pom-spring-boot-2.xml: opt-in legacy Spring Boot 2.7 maintenance example.
  • assets/controller-service-test.java: opt-in Spring Boot 3 + MyBatis-Plus skeleton; split it into real files before use.
  • assets/application.yml.template: opt-in multi-environment Spring Boot + MyBatis-Plus config example.

レビュー

まだレビューはありません。使ってみた感想をお寄せください。

このスキルの問題を報告する