一键导入
java-coding-standards
Java coding standards for Spring Boot services: naming, immutability, Optional usage, streams, exceptions, generics, and project layout.
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
菜单
Java coding standards for Spring Boot services: naming, immutability, Optional usage, streams, exceptions, generics, and project layout.
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
基于 SOC 职业分类
Orchestrate end-to-end React feature development from idea or plan to reviewed, committed code. Use this skill proactively when the user wants to implement a feature, page, component, or UI flow in a React application — even if they just say "implement this", "build this", "add this to the app", "develop this plan", or "create this screen". Spawns parallel specialist subagents for codebase exploration, UX design, React implementation, testing, and code review, then guides the user through approval, commit, and optional PR creation.
Orchestrate end-to-end Java Spring Boot feature development from idea or plan to reviewed, committed code. Use this skill proactively when the user wants to implement a feature, endpoint, service, domain object, or integration in a Spring Boot application — even if they just say "implement this", "add this endpoint", "build this service", "develop this plan", or "create this API". Spawns parallel specialist subagents for codebase exploration, architecture planning, Spring Boot implementation, testing, and code review, then guides the user through approval, commit, and optional PR creation.
Orchestrate end-to-end Node.js backend feature development from idea or plan to reviewed, committed code. Use this skill proactively when the user wants to implement a feature, endpoint, service, module, or integration in a Node.js application — even if they just say "implement this", "add this endpoint", "build this service", "develop this plan", or "create this API". Works with any Node.js framework (Express, Fastify, NestJS, Koa) and TypeScript or JavaScript. Spawns parallel specialist subagents for codebase exploration, architecture planning, implementation, testing, and code review, then guides the user through approval, commit, and optional PR creation.
Create a PRD through user interview, codebase exploration, and module design, then submit as a GitHub issue. Use when user wants to write a PRD, create a product requirements document, or plan a new feature.
Guided idea exploration workflow that develops a raw concept into a mature, PRD-ready requirement through structured Socratic interviews. Use when user wants to explore, stress-test, or develop an idea — triggers at "explore idea", "I have an idea", "let's explore", or similar. Ends by invoking /workflow-create-prd when the idea is mature.
Orchestrate the implementation of a feature from an approved implementation plan. Detects the tech stack, spawns specialized agents per story and enabler (respecting dependency order), collects all agent artifacts into the spec folder, runs the test suite, and tracks progress. Always use this skill when the user says "implement", "start coding", "execute the plan", "implement the feature", or wants to continue a partially-implemented feature. This is the final phase of the product workflow: Conceituação → PRD → Plano → Implementação. Accepts optional flag --worktree to implement in an isolated git worktree.
| name | java-coding-standards |
| description | Java coding standards for Spring Boot services: naming, immutability, Optional usage, streams, exceptions, generics, and project layout. |
| metadata | {"scope":"implementation","version":"1.0.0"} |
Standards for readable, maintainable Java (17+) code in Spring Boot services.
// ✅ Classes/Records: PascalCase
public class MarketService {}
public record Money(BigDecimal amount, Currency currency) {}
// ✅ Methods/fields: camelCase
private final MarketRepository marketRepository;
public Market findBySlug(String slug) {}
// ✅ Constants: UPPER_SNAKE_CASE
private static final int MAX_PAGE_SIZE = 100;
// ✅ Favor records and final fields
public record MarketDto(Long id, String name, MarketStatus status) {}
public class Market {
private final Long id;
private final String name;
// getters only, no setters
}
// ✅ Return Optional from find* methods
Optional<Market> market = marketRepository.findBySlug(slug);
// ✅ Map/flatMap instead of get()
return market
.map(MarketResponse::from)
.orElseThrow(() -> new EntityNotFoundException("Market not found"));
// ✅ Use streams for transformations, keep pipelines short
List<String> names = markets.stream()
.map(Market::name)
.filter(Objects::nonNull)
.toList();
// ❌ Avoid complex nested streams; prefer loops for clarity
MarketNotFoundException)catch (Exception ex) unless rethrowing/logging centrallythrow new MarketNotFoundException(slug);
public <T extends Identifiable> Map<Long, T> indexById(Collection<T> items) { ... }
src/main/java/com/example/app/
config/
controller/
service/
repository/
domain/
dto/
util/
src/main/resources/
application.yml
src/test/java/... (mirrors main)
private static final Logger log = LoggerFactory.getLogger(MarketService.class);
log.info("fetch_market slug={}", slug);
log.error("failed_fetch_market slug={}", slug, ex);
@Nullable only when unavoidable; otherwise use @NonNull@NotNull, @NotBlank) on inputsRemember: Keep code intentional, typed, and observable. Optimize for maintainability over micro-optimizations unless proven necessary.
Load detailed guidance based on context:
| Topic | Reference | Load When |
|---|---|---|
| General Patterns | references/patterns.md | Patterns for design classes, records, DTO, services, builders, constructors |
| Security | references/security.md | Input validations, secret manager, exception details exposing, auth |
| Testing | references/testing.md | Frameworks to use, how to structure packages and classes, unit and integration testing, naming |