Мы видим больше сбоев в Fabric во время миграции RoomDatabase. Любое предложение по устранению проблемы
Инициализация RoomDatabase:
companion object {
fun createNotesDatabase(androidContext: Context): NotesDatabase {
try {
return Room.databaseBuilder(androidContext, NotesDatabase::class.java, "notesdb")
.fallbackToDestructiveMigration()
.build()
} catch (e: Exception) {
Log.e("NotesDatabase", "exception")
}
}
}
Трассировка стека за исключением:
Fatal Exception: java.lang.IllegalStateException: A migration from 1 to 4 was required but not found. Please provide the necessary Migration path via RoomDatabase.Builder.addMigration(Migration ...) or allow for destructive migrations via one of the RoomDatabase.Builder.fallbackToDestructiveMigration* methods.
at android.arch.persistence.room.RoomOpenHelper.onUpgrade + 97(RoomOpenHelper.java:97)
at android.arch.persistence.db.framework.FrameworkSQLiteOpenHelper$OpenHelper.onUpgrade + 133(FrameworkSQLiteOpenHelper.java:133)
at android.database.sqlite.SQLiteOpenHelper.getDatabaseLocked + 400(SQLiteOpenHelper.java:400)
at android.database.sqlite.SQLiteOpenHelper.getWritableDatabase + 298(SQLiteOpenHelper.java:298)
at android.arch.persistence.db.framework.FrameworkSQLiteOpenHelper$OpenHelper.getWritableSupportDatabase + 96(FrameworkSQLiteOpenHelper.java:96)
at android.arch.persistence.db.framework.FrameworkSQLiteOpenHelper.getWritableDatabase + 54(FrameworkSQLiteOpenHelper.java:54)
at com.limemobile.notes.data.local.NotesDatabase_Impl.clearAllTables + 280(NotesDatabase_Impl.java:280)