I built an SDK for Android, which uses KTOR intern...
# library-development
z
I built an SDK for Android, which uses KTOR internally. I use KTOR version 3.0.0. My main client informed me they have a transitive dependency to KTOR 2.3.13 so they experience a crash. I see many suggestions online for shadowing, fat aar. Assuming the client is not ready to upgrade to 3.0.0, what is my best course of action?
c
The client should do something on their side (e.g. shadowing). If you use shadowing in the SDK, you force all your users to have two Ktors in their binary, and you stop them from being able to control the exact Ktor version used (e.g. so they can quickly patch a security problem)
If you really really want to support them, create a second artifact that is built from the same sources but using Ktor 2, and hope that you don't depend on source-incompatible changes between the two versions
2
z
Thats a good option, thank you
a
If you really really want to support them, create a second artifact that is built from the same sources but using Ktor 2,
yeah, that's what we've ended with having both ktor2/ktor3 abstraction and proposing different artifacts