java-coding-standards

Enforce Java 17+ Spring Boot coding standards for naming, immutability, Optional usage, exceptions, generics, and layouts.

40|8|Updated Jan 23, 2026
One-click install
npx skills add https://github.com/ysyecust/everything-claude-code --skill java-coding-standards-ysyecust
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: java-coding-standards
Source: https://github.com/ysyecust/everything-claude-code/tree/main/skills/java-coding-standards
Command: npx skills add https://github.com/ysyecust/everything-claude-code --skill java-coding-standards-ysyecust

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

This Skill codifies Java coding standards to improve readability, maintainability, and consistency across Spring Boot services, reducing code smells and onboarding time.

Core Features & Use Cases

  • Naming & packaging conventions: enforce PascalCase for types, camelCase for members, and logical package structures.
  • Immutability & value objects: prefer records or final fields to minimize mutability.
  • Optional usage & streams: promote safe null handling and readable data transformations.
  • Exception patterns & generics: define domain-specific exceptions and strong type safety.
  • Project layout guidance: provide a conventional Maven/Gradle structure for Spring Boot apps.

Quick Start

Start by auditing an existing Spring Boot module to align class names with the standards, then apply the rules to introduce an immutable value object and standard Optional usage.

Frequently Asked Questions about java-coding-standards

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
What are the Java coding standards for Spring Boot services?

Java coding standards for Spring Boot services enforce naming conventions, prefer records for immutability, mandate safe Optional usage, and define domain-specific exceptions to improve readability and maintainability.

How do I handle nulls in Java Spring Boot applications?

Handle nulls in Java Spring Boot applications by using Optional return patterns instead of returning raw nulls, promoting safe null handling and preventing NullPointerExceptions during data transformations.

Does this Java coding standard support Java 17 and Spring Boot projects?

Yes, these Java coding standards apply to Java 17 and Spring Boot projects, enforcing strict type safety with generics and providing a conventional Maven or Gradle structure for project layouts.

What is the best way to implement immutability in Java Spring services?

The best way to implement immutability in Java Spring services is by using Java records or final fields, minimizing mutability to reduce code smells and ensure thread-safe value objects.

How do I structure exceptions and streams in a Spring Boot application?

Structure exceptions in a Spring Boot application by defining domain-specific exceptions, and process streams by applying readable data transformation operations to maintain consistent code standards.

When should I not use Optional in Java methods?

Avoid using Optional in Java methods for field types or as parameters; these Java coding standards restrict Optional usage strictly to return patterns to ensure safe null handling without overhead.