Logo vun Java Kotlin Migration Assistant

Java Kotlin Migration Assistant

Organisatioun
JetBrains
java-kotlin-migration-assistant

Migrate Java code to Kotlin in Spring-based codebases without changing behavior, public contracts, framework compatibility, or binary assumptions unless explicitly intended. Use when converting classes incrementally, replacing Lombok patterns, managing platform types and nullability, preserving JPA and proxy behavior, or planning the safe migration order of a mixed Java and Kotlin codebase.

Iwwersiicht

EditeurJetBrains
Repositoryskills
Skill-Nummjava-kotlin-migration-assistant
Stären
377
Forks
32
Matgeliwwert Fichieren
1
Linken
  • Instruktiounen am Markdown-Format

    Eng SKILL.md-Datei, déi de Modell bei Bedarf luet, soudatt nëmmen Token ufalen, wann eng Ufro tatsächlech dozou passt.

  • Funktionéiert mat all LLM

    KI-Skills si reng Markdown, keen ubidderspezifesche Code. Dofir funktionéiert dëse Skill mat GPT, Claude, Gemini, Grok oder engem lokale Modell.

  • 1 matgeliwwert Dateien

    Skripten, Virlagen a Referenzen, déi de Modell beim Schaffe liese kann. D'Dateie kënnen nëmme gelies ginn a ginn ni ausgeféiert.

  • Open Source

    Vum JetBrains op GitHub verëffentlecht. Liest de Quelltext, ier Dir de Skill installéiert.

Installatioun

Installéiert de KI-Skill Java Kotlin Migration Assistant an TypingMind, fir e mat all LLM ze benotzen, oder füügt en an en anere KI-Agent an, deen SKILL.md liest.

1

An TypingMind installéieren

TypingMind installéiert e Skill direkt aus sengem GitHub-Dossier — dobäi gëtt SKILL.md gelies, d'Ressourcedateie gi gebëndelt an d'Resultat gëtt lokal gespäichert.

  1. Maacht d'App op a gitt op Plugins → Skills.
  2. Wielt „Vun GitHub installéieren“.
  3. Pecht d'URL vum Skill-Dossier hei drënner an a bestätegt.
    https://github.com/JetBrains/skills/tree/main/java-kotlin-migration-assistant
  4. Aktivéiert de Skill an all Chat, an deem Dir e benotze wëllt.
Plugins → Skills → Skill afügen → Vu GitHub-URL, pecht dann d'URL vum Dossier an a klickt op Weider.
2

An engem anere KI-Agent installéieren

All KI-Agent, deen d'Format Agent Skills liest, kann dëse Skill benotzen — kopéiert den Dossier an de Skill-Verzeechnes vun deem KI-Agent.

Claude Code — .claude/skills
git clone --depth 1 https://github.com/JetBrains/skills.git /tmp/skills
mkdir -p .claude/skills
cp -r /tmp/skills/java-kotlin-migration-assistant .claude/skills/java-kotlin-migration-assistant
Start Claude Code nom Kopéieren nei, fir datt den neie Skill erkannt gëtt.

An TypingMind benotzen

Aktivéiert Java Kotlin Migration Assistant an engem Chat vun TypingMind, an de Modell iwwerhëlt de Rescht. Den Numm an d'Beschreiwung stinn am System-Prompt. Soubal eng Ufro dozou passt, luet de Modell déi komplett Instruktioune selwer — Dir musst de Skill ni manuell opruffen, an et fale keng Token un, bis en tatsächlech benotzt gëtt.

De Modell luet Java Kotlin Migration Assistant automatesch, soubal eng Ufro dozou passt.

Funktionéiert mat all KI-Modell

KI-Skills si reng Markdown-Instruktiounen amplaz vun ubidderspezifeschem Code. Dofir ass Java Kotlin Migration Assistant net un de Modell gebonnen, fir deen de Skill geschriwwe gouf. Installéiert en eemol an TypingMind a benotzt e mat GPT-5, Claude, Gemini, Grok, DeepSeek, Mistral, Llama oder engem lokale Modell, deen Dir selwer bedreift — alles mat Ären eegenen API-Keys.

  • Gëtt nëmme gelueden, wann et néideg ass

    De System-Prompt enthält nëmmen den Numm an d'Beschreiwung. D'Instruktioune gi bei der éischter passender Ufro gelueden, soudatt en onbenotzte Skill näischt kascht.

  • De Modell am lafende Chat wiesselen

    Well de Skill aus Instruktiounen amplaz vu Code besteet, funktionéiert en och no engem Modellwiessel — den nächste Modell liest déi selwecht SKILL.md-Datei.

Skill-Instruktiounen

Dëst ass den Inhalt vu SKILL.md, deen de Modell luet. Liest e virun der Installatioun — e Skill besteet aus Instruktiounen, déi Äre Modell befollegt.

Java Kotlin Migration Assistant

Source mapping: Tier 3 specialized skill derived from Kotlin_Spring_Developer_Pipeline.md (SK-19).

Mission

Translate Java into Kotlin in a way that improves long-term maintainability without introducing semantic drift. Prioritize behavioral equivalence first, idiomatic cleanup second, and broad redesign only when explicitly requested.

Read First

  • The Java class and its callers.
  • Existing tests and any contract documentation.
  • Spring annotations, JPA annotations, Jackson annotations, validation annotations, and logging patterns.
  • Build plugins and Kotlin compiler configuration already present in the repository.
  • Whether the module is internal-only or has external consumers that care about binary compatibility.

Migration Order

Use this default order unless the repository strongly suggests otherwise:

  1. Tests and support utilities.
  2. Stateless helpers and internal-only classes.
  3. Services and controllers.
  4. Domain models and DTOs.
  5. Entities and framework-sensitive classes last.

The most fragile classes are usually entities, heavily proxied services, reflection-heavy config classes, and public library APIs.

Translation Rules

  • Preserve public behavior before pursuing idiomatic compression.
  • Convert fields plus getters plus setters into properties only when that does not change framework expectations.
  • Replace Lombok consciously:
    • @Data is not a universal reason to create a Kotlin data class
    • @Builder may map to named/default parameters or may need an explicit builder for Java callers
    • @Slf4j usually becomes an explicit logger field or companion object
  • Replace checked-exception-heavy flows carefully. Kotlin does not enforce checked exceptions, but Java callers may still depend on them semantically.
  • Keep annotations on the correct target after translation. Kotlin use-site targets matter.

Nullability And Platform-Type Rules

  • Treat every Java type crossing into Kotlin as suspect until nullability is proven.
  • Add explicit Kotlin nullability based on contracts, not on optimistic guesses.
  • If upstream Java code lacks annotations, prefer defensive boundary checks over sprinkling !!.
  • Distinguish internal invariants from external compatibility. Sometimes a Kotlin non-null model is correct internally even when the Java boundary remains nullable.
  • Re-check collections, optionals, and maps separately. Java usage patterns often hide null values inside otherwise non-null containers.

Spring And JPA Nuances

  • Verify proxy-sensitive classes still work after translation:
    • @Transactional
    • @Cacheable
    • @Async
    • method security
  • Do not convert JPA entities into data class.
  • Preserve JPA constructor, field access, and equality semantics deliberately.
  • Re-check @ConfigurationProperties, Jackson creator behavior, and validation annotations after constructor translation.
  • If the project relies on interface-based proxies, do not accidentally move critical behavior into non-interface methods that callers bypass.

Advanced Migration Traps

  • Default parameters can change Java call sites, overload generation, and reflective constructor expectations.
  • Kotlin properties may alter method signatures, bean-introspection shape, and serialization behavior compared with explicit Java accessors.
  • Inline classes, sealed hierarchies, and scope-function-heavy refactors are not first-pass migration tools. Use them after compatibility is proven.
  • Replacing mutable Java collections with read-only Kotlin interfaces does not magically make the backing data immutable.
  • equals, hashCode, and toString generation can silently change semantics for entities, cache keys, and logging.
  • Library modules may need @JvmStatic, @JvmOverloads, @JvmField, or explicit overload preservation for Java consumers.
  • Mixed Java/Kotlin modules can expose incremental compilation and annotation-processing surprises. Keep build verification tight during migration.

Bytecode And Interop Nuances

  • internal visibility is a module-level bytecode concept, not a source-level privacy guarantee. Do not use it casually in previously public or Java-consumed APIs.
  • Interface default methods, companion objects, and top-level functions alter Java call ergonomics and sometimes reflective lookup paths.
  • SAM conversion, raw types, and wildcard variance can change overload resolution at Java call sites even when Kotlin looks cleaner.
  • Optional<T>, primitive wrappers, arrays, and checked exceptions each deserve explicit migration treatment; do not lump them under generic nullability cleanup.
  • Parameter-name retention, generated constructors, and method overloading affect frameworks that use reflection or bytecode-generated proxies.
  • Annotation processors, generated metamodels, and kapt or KSP transitions can change what "successful migration" means for the build beyond source compilation.

Expert Heuristics

  • If a class is consumed by Java, optimize for interop predictability before Kotlin elegance.
  • Migrate behaviorally boring classes first to establish project conventions for logging, nullability, builders, and testing.
  • Delay introduction of coroutines, sealed redesigns, and stronger domain modeling until the mixed Java/Kotlin seam is stable.
  • When uncertain, preserve explicit methods over collapsing everything into properties or generated helpers. Debuggability and binary stability matter during migration.

Output Contract

Return these sections:

  • Migration scope: what is being converted now and what stays in Java for the moment.
  • Behavioral invariants: what must remain unchanged.
  • Kotlin translation plan: the exact language-level changes to make.
  • Framework constraints: Spring, Jackson, JPA, validation, and binary-compatibility concerns.
  • Verification: tests and runtime checks that prove no semantic drift.

Guardrails

  • Do not change public API shape casually.
  • Do not hide uncertain nullability behind !!.
  • Do not mix migration with broad architectural redesign unless explicitly asked.
  • Do not make entity, proxy, or serialization classes "more idiomatic" at the cost of framework correctness.

Quality Bar

A good run of this skill yields Kotlin that is safer and cleaner while still behaving like the original Java where it matters. A bad run produces "Java with Kotlin syntax" or, worse, a pretty rewrite that silently breaks callers, proxies, or persistence.

Matgeliwwert Fichieren

De Modell liest dës Dateie bei Bedarf, wärend de Skill gelueden ass. Si ginn als liesbar Dateie bereetgestallt a ginn ni ausgeféiert.

Heefeg gestallte Froen

Wat mécht de KI-Skill Java Kotlin Migration Assistant?

Migrate Java code to Kotlin in Spring-based codebases without changing behavior, public contracts, framework compatibility, or binary assumptions unless explicitly intended. Use when converting classes incrementally, replacing Lombok patterns, managing platform types and nullability, preserving JPA and proxy behavior, or planning the safe migration order of a mixed Java and Kotlin codebase.

Firwat Java Kotlin Migration Assistant op TypingMind benotzen?

Well Dir en eemol installéiert a mat all Modell benotze kënnt. Java Kotlin Migration Assistant besteet aus einfachem Markdown amplaz vun ubidderspezifeschem Code. Dee selwechte Skill funktionéiert also mat GPT-5, Claude, Gemini, Grok oder engem lokale Modell – an Dir kënnt de Modell matzen am Chat wiesselen, ouni datt de Skill ophält ze funktionéieren. TypingMind benotzt Är eegen API-Schlësselen, sou datt Dir d'Ubidder direkt bezuelt amplaz vun engem Abonnement pro Benotzerplaz. Är Skills a Chats bleiwen an Ärem eegene Späicher.

Wéi installéieren ech Java Kotlin Migration Assistant an TypingMind?

Maacht an TypingMind Plugins → Skills → Vu GitHub installéieren op a setzt https://github.com/JetBrains/skills/tree/main/java-kotlin-migration-assistant an. TypingMind liest d'Datei SKILL.md, bündelt déi zougehéiereg Dateien an installéiert dat Ganzt als Skill, deen Dir pro Chat aktivéiere kënnt.

Wéi eng KI-Modeller kënnen Java Kotlin Migration Assistant benotzen?

All Modell, deen Dir an TypingMind verbënnt. KI-Skills sinn einfach Markdown-Instruktiounen an net ubidderspezifesche Code. Dofir kënne GPT, Claude, Gemini, Grok a lokal Modeller dëse Skill lueden, wann eng Ufro dozou passt.

Wéi vill KI-Modeller kann ech mat Java Kotlin Migration Assistant benotzen?

Esou vill Dir wëllt. Soulaang e Modell Skills ënnerstëtzt, kënnt Dir Java Kotlin Migration Assistant domat benotzen – GPT, Claude, Gemini, Grok, DeepSeek, Mistral, Llama a méi – alles op TypingMind mat Ären eegenen API-Schlësselen.

Ass de KI-Skill Java Kotlin Migration Assistant gratis?

De Skill gëtt vum JetBrains op GitHub publizéiert. Kuckt am Repository no de Lizenzbedéngungen. Dir bezuelt nëmmen Ären eegene KI-Ubidder fir d'Token, déi Dir benotzt.

Wat si KI-Skills?

E KI-Skill ass e weiderverwendbaart Pak vun Instruktiounen, dat engem KI-Modell bäibréngt, wéi en eng bestëmmt Aufgab erfëllt. E follegt dem oppenen Agent Skills-Format: eng Datei SKILL.md mat engem Numm an enger Beschreiwung, plus all Scripten, Virlagen oder Referenzdateien, déi de Modell eventuell brauch. De Modell liest d'Instruktiounen eréischt, wann Är Ufro zum Skill passt. En installéierte Skill kascht also näischt, bis e benotzt gëtt.

Wéi ënnerscheede sech KI-Skills vu Plugins oder MCP-Serveren?

E Plugin oder MCP-Server gëtt engem Modell nei Tools, déi en opruffe kann – Code, deen iergendwou leeft an e Resultat zeréckgëtt. E KI-Skill gëtt dem Modell dogéint Wëssen an eng Virgoensweis: wéi en eng Aufgab ugeet, wéi eng Schrëtt en nokënnt a wéi eng gutt Ausgab ausgesäit. Skills bestinn aus einfachem Markdown, brauche kee Server, keen API-Schlëssel a keng Lafzäitëmfeld a funktionéiere mat all Modell.

All weisen

Elo Ären eegene KI-Workspace ariichten

Abonnéiert Iech op eisen Newsletter, fir iwwer nei Funktiounen an zukünfteg Gewënnspiller informéiert ze ginn 👇