Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
Extending kotlinx.serialization functionality w...
Search
Karin-Aleksandra Monoid
June 08, 2022
Programming
0
120
Extending kotlinx.serialization functionality with Arrow Meta (Joker 2021/KotlinDevDay 2022)
Karin-Aleksandra Monoid
June 08, 2022
Tweet
Share
More Decks by Karin-Aleksandra Monoid
See All by Karin-Aleksandra Monoid
Treasure.map(): Functional programming in JVM-based languages
paranoidmonoid
0
330
Extending kotlinx.serialization functionality with Arrow Meta
paranoidmonoid
0
110
Functional Kotlin with Arrow (jLove 2021)
paranoidmonoid
1
220
Hands-on Arrow
paranoidmonoid
1
160
Make Tech Slides Work
paranoidmonoid
0
610
"Fun" as in "funeral": full-stack development using Kotlin JS
paranoidmonoid
0
120
Other Decks in Programming
See All in Programming
AIで開発はどれくらい加速したのか?AIエージェントによるコード生成を、現場の評価と研究開発の評価の両面からdeep diveしてみる
daisuketakeda
1
2.5k
Automatic Grammar Agreementと Markdown Extended Attributes について
kishikawakatsumi
0
200
余白を設計しフロントエンド開発を 加速させる
tsukuha
7
2.1k
The Past, Present, and Future of Enterprise Java
ivargrimstad
0
590
CSC307 Lecture 06
javiergs
PRO
0
690
AIフル活用時代だからこそ学んでおきたい働き方の心得
shinoyu
0
140
Lambda のコードストレージ容量に気をつけましょう
tattwan718
0
130
AWS re:Invent 2025参加 直前 Seattle-Tacoma Airport(SEA)におけるハードウェア紛失インシデントLT
tetutetu214
2
110
Best-Practices-for-Cortex-Analyst-and-AI-Agent
ryotaroikeda
1
110
Apache Iceberg V3 and migration to V3
tomtanaka
0
160
Fluid Templating in TYPO3 14
s2b
0
130
Grafana:建立系統全知視角的捷徑
blueswen
0
330
Featured
See All Featured
4 Signs Your Business is Dying
shpigford
187
22k
SEOcharity - Dark patterns in SEO and UX: How to avoid them and build a more ethical web
sarafernandez
0
120
Leveraging LLMs for student feedback in introductory data science courses - posit::conf(2025)
minecr
0
140
The Cult of Friendly URLs
andyhume
79
6.8k
"I'm Feeling Lucky" - Building Great Search Experiences for Today's Users (#IAC19)
danielanewman
231
22k
Paper Plane
katiecoart
PRO
0
46k
The MySQL Ecosystem @ GitHub 2015
samlambert
251
13k
SERP Conf. Vienna - Web Accessibility: Optimizing for Inclusivity and SEO
sarafernandez
1
1.3k
Large-scale JavaScript Application Architecture
addyosmani
515
110k
How to Create Impact in a Changing Tech Landscape [PerfNow 2023]
tammyeverts
55
3.2k
Joys of Absence: A Defence of Solitary Play
codingconduct
1
290
Thoughts on Productivity
jonyablonski
74
5k
Transcript
1 Extending kotlinx.serialization functionality with Arrow Meta Karin-Aleksandra Monoid Kotlin
Dev Day 2022
2 • Senior Software Engineer at CircleCI • Background in
Kotlin & Scala (both front and backend) • Living in Germany with two cats • GDE in Kotlin About
3 • Senior Software Engineer at CircleCI • Background in
Kotlin & Scala (both front and backend) • Living in Germany with two cats • GDE in Kotlin About
4 Agenda Why? What is Arrow Meta? Sample project Showtime!
5 Project Stack • Just backend with Ktor + Arrow
• Jackson was kind of "default" • Smooth but not Kotlin-first
6 kotlinx.serialization – pros 🚀 • Kotlin-first • No boilerplate
for sealed classes
7 kotlinx.serialization – cons • Not a lot of serializers
out of the box • No global naming strategy
8 Global Naming Strategy UPPER_SNAKE_CASE -> camelCase USER_NAME -> userName
9 Jackson: Object Mapper val objectMapperUpperSnakeCase = jacksonObjectMapper().apply { propertyNamingStrategy
= PropertyNamingStrategies.UPPER_SNAKE_CASE }
10 Issue #33 https://github.com/Kotlin/kotlinx.serialization/issues/33
11 Global Naming Strategy @SerialName("USER_NAME") val userName: String
12 What is Arrow Meta?
13 “Functional companion to Kotlin's Compiler” What is Arrow Meta?
Image source: https://arrow-kt.io/
14 GIF source: https://github.com/arrow-kt/arrow-meta
15 • Already using other part of Arrow for FP
Why Arrow Meta?
16 Why Arrow Meta? • More functionality than KSP/KAPT •
Easier than kotlinc
17 Sample Project
18 https://bit.ly/3C2lHGp Link to repo
19 • various animals (actually, only cats and dogs) •
various sources (= 3rd party services) • various standards of documentation (in JSON format with different naming policies) Setting: a Zoo
20 Live coding time
21 • It works • ??? • Requires more knowledge
than expected • KSP is preferable if it fits Thoughts
22 Resources • https://meta.arrow-kt.io/ • https://github.com/arrow-kt/arrow-meta-examples • https://paranoidmonoid.github.io/articles/Kotlin%20and%20frien ds/Naming%20strategy%20plugin