Hello, is there an idiomatic way of handling http patch requests in Kotlin(Ktor, etc)?
a
Aleksei Tirman [JB]
02/24/2023, 9:15 PM
Can you describe your problem in more detail, preferably with a code snippet?
p
P A
02/24/2023, 9:20 PM
I don’t have a code snippet handy at this moment. I’ll share one later. The core of my questions is about how to translate a Patch request into strongly typed (data) classes. In particular, I wonder if there is a Kotlin/Ktor idiomatic way to distinguish between a field being set to null vs a field being removed from the document referenced in a the Patch request.
I wonder if there is some well know practice/pattern in Ktor or if there are Kotlin libraries to deal with the ambiguity mentioned above or is everyone just rolling their own custom solutions.
P A
02/24/2023, 9:25 PM
Let me know if my question makes sense, thank you!