Highlights
Please make a harmful welcome to the brand new Avro4k plugin! 👋
By adding the io.github.avro-kotlin
plugin to your buildscript, you will:
- ✍️ Generate kotlin classes to be directly used with Avro core module and avro4k kafka (de)serializers
- ✅ Ensures consistent version across avro4k modules, plugin, and kotlinx-serialization library
- 🚀 Maybe more in the future...
Until now, I suppose you've been declaring manually your models based on existing schemas. Or even the clean way, you are still using the well-known (but discontinued) davidmc24's plug-in generating Java classes, which is not well playing with kotlin null-safety nor avro4k 😠
Now, by adding id("io.github.avro-kotlin")
in the plugins block, drop your schemas inside src/main/avro
, and just use the generated classes in your production codebase without any other complex configuration!
As this plug-in is quite new, there isn't that much configuration, so don't hesitate to propose features or contribute 👥
Tip: combined with the avro4k-confluent-kafka-serializer added in the last minor release, your productivity will take a bump 😁
Also, a new BOM module has been created to ensure consistency in your projects!

I've been struggling with releasing the plugin, and it took time to be approved by the gradle portal team, which ended up to intermediate versions v2.5.0, v2.5.1 or v2.5.2 😅 Please be kind and directly use the v2.5.3
! 🙏
What's Changed
🚀 Features
- feat: Add gradle plugin to generate kotlin sources by @Chuckame in #370
- feat: Allow handling logical type with custom KSerializer by @Chuckame in #367
- feat: Publish BOM by @Chuckame in #368
🌟 Enhancements
- fix(confluent-kafka-serializer): Allow deserializing String and ByteArray wrapped inside a value class by @Chuckame in #377
🐛 Bug fixes
- fix: Release version in mvn central without the v prefix by @Chuckame in #366
- build: Do not force kotlin version to 1.9 anymore by @Chuckame in #369
- fix: ensure build runs for releases by @Chuckame in #371
- build: make gradle plug-in works by @Chuckame in #372
- build: release gradle plugin by @Chuckame in #373
- build: fix release workflow by @Chuckame in #374
- build: fix kotlin-generator module release by @Chuckame in #375
- build: change the plugin id to comply with gradle's portal requirements by @Chuckame in #376
Full Changelog: v2.4.1...v2.5.3