# Use latest Kotlin in your Gradle plugins

DevFeed: [Use latest Kotlin in your Gradle plugins](<https://devfeed.tech/articles/use-latest-kotlin-in-your-gradle-plugins-25435.md>)

Original publisher: [Read original article](<https://blog.mbonnin.net/use-latest-kotlin-in-your-gradle-plugins>)

Author: Martin Bonnin

Published: 2021-11-12T15:13:39Z

Content type: tutorial

Language: en

Sources: [Martin Bonnin's blog](<https://devfeed.tech/sources/martin-bonnin-s-blog.md>)

Topics: [Gradle](<https://devfeed.tech/topics/gradle.md>), [Kotlin](<https://devfeed.tech/topics/kotlin.md>), [Compiler](<https://devfeed.tech/topics/compiler.md>), [toolchain](<https://devfeed.tech/topics/toolchain.md>)

Tags: [bytecode](<https://devfeed.tech/tags/bytecode.md>), [compiler](<https://devfeed.tech/tags/compiler.md>), [dependencies](<https://devfeed.tech/tags/dependencies.md>), [gradle](<https://devfeed.tech/tags/gradle.md>), [kotlin](<https://devfeed.tech/tags/kotlin.md>), [plugins](<https://devfeed.tech/tags/plugins.md>)

## AI overview

This article explains the classloader and embedded Kotlin runtime limitations that arise when using newer Kotlin APIs in Gradle plugins. It discusses the resulting compatibility problem and workarounds including bytecode restrictions and Gradle's Worker API with classloader isolation.

## Source excerpt

This is the story of how I got down the rabbit hole of relocating classes while trying to workaround the Gradle classloaders and fixed Kotlin runtime limitations. I'm not sure if I'd recommend trying this at home but this was an interesting journey! ...