Closed dabluck closed 1 year ago
I think this is a duplicate of https://github.com/google/ExoPlayer/issues/5933. If you are motivated, feel free to send a PR to make this update. We haven't got around to do this ourselves yet.
@tonihei if I sent a PR are you okay with the hard dependency on the sqlite support lib?
Yes, you are right, this is a potential concern with this approach that wasn't immediately clear when I suggested to write a PR. I'll have a look at #784 and leave further comments there.
If I want to use SimpleCache for a CacheDataSource, it requires a database provider. DatabaseProvider only takes an Android SQLiteDatabase.
If we're using Room, we only have a RoomDatabase which is built on the androidx sql libraries, and we only have a SupportSqliteHelper which gives only a SupportSQLiteDatabase.
As far as can tell, the only workaround is to write your own Cache. Duplicating all the logic in SimpleCache to simply switch out a support library is a lot of work.
Is there any alternative I'm missing?