I'm trying to encrypt the apollo client SqlNormali...
# apollo-kotlin
y
I'm trying to encrypt the apollo client SqlNormalizedCache(https://www.apollographql.com/docs/kotlin/caching/normalized-cache) in KMP project I'm able to do encrypt/decrypt on Sqldelight https://github.com/cashapp/sqldelight/discussions/5193 But how can i achieve same with apollo client?
m
Not sure why it doesn't show in kdoc but I think you should be able to use that?
y
@mbonnin Let me give a try. Thanks!
m
Mmm looks like it's internal though 🤔
That would explain why it doesn't show in KDoc!
Mind trying to trick the compiler into calling it? See https://publicobject.com/2024/01/30/internal-visibility/
If it works for you we could open up that constructor
y
Yes driver is internal not showing up in code too
I can play with visibility.
m
It should reasonnably work. Not long term solution of course but if it works we'll open up the symbol
👍 1
y
@mbonnin I tested with Sqlcipher and Sqldelight driver and it worked. Able to encrypt/decrypt the db. Apollo client was also working good. How can i request to open the sqldriver constructor in apolloclient repo? should i raise a PR?
m
Please go ahead, PRs are very welcome 🤗
👍 1