본문으로 건너뛰기
Skillpedia
API 및 서버 (백엔드)40k · #7261

java-upgrade

하는 일

Java 프로젝트를 더 새로운 Java 버전(예: 11에서 17로)으로 업그레이드하도록 돕습니다. 새 언어와 라이브러리 기능을 안전하게 사용할 수 있도록 단계별로 안내합니다.

사용하는 경우

  • ✓Java 코드를 더 새로운 버전으로 업데이트하고 싶을 때.
  • ✓Java 프로젝트의 기능을 현대화할 때.
  • ✓'레코드'나 '봉인 클래스' 같은 새 Java 기능을 도입할 때.

스킬 링크

https://github.com/github/awesome-copilot/blob/main/skills/java-upgrade/SKILL.md

복사해서 AI(Claude, ChatGPT, Cursor)에 붙여넣고 지침을 따르도록 요청하세요.

사용 방법

가장 쉬운 방법입니다. 메시지를 복사해 AI에 붙여넣으세요. AI가 스킬을 읽고 지침을 따릅니다.

바로 붙여넣을 수 있는 메시지

Use this skill to help me: https://github.com/github/awesome-copilot/blob/main/skills/java-upgrade/SKILL.md Read the SKILL.md file at that link and follow its instructions for my task.
AI가 이런 스킬을 알아서 찾아 쓰길 원하시나요?무료 Skillpedia MCP를 설치하세요. 한 줄이면 작업마다 스킬 15,000+개 중에서 검색합니다.1분 만에 설치 →

AI에게 요청하는 예시

“제 Java 프로젝트를 11에서 17로 업그레이드하고 새 기능을 사용하고 싶습니다.”

매주 새 스킬 5개. 읽는 데 1분.

작동 방식

AI는 프로젝트가 어떤 Java 버전을 쓰는지 확인하고, 한 번에 한 버전씩 필요한 변경을 안내합니다. 빌드 시스템 업데이트를 제안한 뒤, 새 언어 기능을 적용하도록 돕습니다.

기술 내용 (원본 SKILL.md)

작성자의 영어 원문을 GitHub에서 그대로 가져왔습니다.

Java Upgrade

Help upgrade a Java project step by step and adopt new language features safely.

Need a more powerful, automated upgrade?

The Microsoft plugin modernize-java ("GitHub Copilot modernization - Java Upgrade CLI Plugin", also listed in this repository's plugins/external.json) upgrades Java applications from the command line. It can:

  • analyze the project, assess dependencies and generate a customizable upgrade plan you can review and edit;
  • execute the plan to automatically transform the codebase;
  • fix build issues and resolve migration errors during the upgrade, running test validations;
  • validate the application against known CVEs after the upgrade;
  • output a detailed summary (file changes, updated dependencies, test results, remaining issues) suitable for PRs or CI logs.

This skill provides lightweight, step-by-step guidance and works without the plugin; the plugin is the more powerful option for large or multi-step upgrades. It is a separate Microsoft plugin, not part of this repository's skills. To try it (see the plugin README for the recommended model):

npm install -g @github/copilot
copilot plugin marketplace add microsoft/modernize-java
copilot plugin install modernize-java@modernize-java
copilot --agent modernize-java:modernize-java

Workflow

  1. Detect the current and target versions. Read pom.xml (maven.compiler.release, java.version, toolchains), build.gradle* (java.toolchain, sourceCompatibility) and CI files. Never assume a target: ask the user if it is not stated.
  2. Upgrade one LTS at a time (11 → 17 → 21 → 25). Build and run the tests after each step.
  3. Load only the guide you need from the table below. Do not load all of them.
  4. Update the build first (compiler release, plugins, dependencies that need newer versions), then adopt language features incrementally in small, reviewable changes.
  5. Verify: ./mvnw verify or ./gradlew build, and fix deprecation and removal warnings before adopting new features.
  6. Automate and check upstream. Use OpenRewrite when available (for example org.openrewrite.java.migrate.UpgradeToJava21) and always fetch the version-specific official guide before editing; review the generated diff.

Upstream sources (read before upgrading)

Fetch the page for the target version; prefer it over this skill when they conflict. Full list with build-tool and agent compatibility pages: references/upstream-sources.md.

Per-version guides

Upgrade Guide
Java 11 → 17 references/java-11-to-17.md
Java 17 → 21 references/java-17-to-21.md
Java 21 → 25 references/java-21-to-25.md

Rules

  • Prefer behavior-preserving refactorings; do not change public APIs unless asked.
  • Detect the project's frameworks (Spring Boot, Quarkus, Jakarta EE) and check their minimum supported Java version before raising the target.
  • Do not adopt preview features unless the user opts in and the build enables them explicitly.
  • For javax.* to jakarta.* namespace changes, use the javax-to-jakarta-migration skill if it is installed (gh skills install github/awesome-copilot javax-to-jakarta-migration); otherwise do the migration inline: update imports, META-INF service files and XML descriptors, and bump dependencies to Jakarta EE 9+ equivalents.
  • If the modernize-java plugin is installed and the user wants an automated upgrade, defer to it and use this skill for the per-version guides and the javax to jakarta safeguards.
자주 묻는 질문

이 스킬과 'modernize-java' 플러그인의 차이는 무엇인가요?

이 스킬은 더 단순한 단계별 가이드를 제공합니다. 'modernize-java' 플러그인은 자동화되고 복잡한 업그레이드를 위한 더 강력한 도구이며, 별도로 설치할 수 있습니다.

'레코드'와 '봉인 클래스'란 무엇인가요?

'레코드'는 데이터를 담는 클래스를 더 간단하게 만드는 방법입니다. '봉인 클래스'는 특정 클래스를 상속할 수 있는 다른 클래스를 제어할 수 있게 합니다.

Java 버전을 건너뛰어도 되나요?

권장되지 않습니다. AI는 모든 것이 올바르게 작동하도록 한 번에 한 주요 버전씩 업그레이드할 것을 제안합니다(예: 11에서 17, 그다음 17에서 21).

상세 정보

작성자의 원본 설명

Upgrade a Java project to a newer JDK (11 to 17, 17 to 21, 21 to 25) and adopt the new language and library features. Detects the current Java version from the build files, then loads only the matching per-version guide. Use when the user asks to upgrade Java, modernize Java code, or adopt records, sealed classes, pattern matching, virtual threads or other new Java features. For automated end-to-e

repo: github/awesome-copilot

인기도

GitHub 스타
40k
순위
#7261
라이선스
MIT
업데이트
2026. 10. 15.

이 스킬이 유용한가요?

0

로그인 투표하려면 로그인하세요.

댓글

  • …

이 저장소의 다른 스킬

비슷한 스킬