-
Notifications
You must be signed in to change notification settings - Fork 656
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Allow custom SqlDriver to support multi-platform encryption #4504
Comments
It might be ok to expose The only thing that makes this code complicated is the expect/actual declaration. It's currently possible to create a |
Correct.
actual class SqlNormalizedCacheFactory internal constructor(
private val driver: SqlDriver,
) : NormalizedCacheFactory() { Simply making this default constructor public should solve my problem without incurring additional overhead elsewhere. |
Want to open a PR about this? (you'll most likely have to run |
Happy to take a stab at it. Thanks! |
Fixed with #4806 |
Use case
I need to be able to encrypt the normalised cache on non-Android targets (specifically iOS).
SqlDelight supports configuring a
SqlDriver
for encryption:Describe the solution you'd like
I would like for the
SqlNormalizedCacheFactory
constructor to be made public, to allow supplying a customisedSqlDriver
when instantiatingSqlNormalizedCacheFactory
.I understand that the constructor is
internal
to allow SqlDelight to remain an implementation detail, but this hides functionality already supported by the dependency.Perhaps an overloaded constructor that allows passing an api-agnostic encryption config (eg,
SqlNormalisedCacheEncryptionConfig
) would solve the problem without leaking the SqlDelight dependency?The text was updated successfully, but these errors were encountered: