is there an existing task tracking implementing backup restore for corrupt database recovery, for both native and web? I want to add a comment referencing this code in SQLiteDataHandler, to make sure it's updated as part of that task.
Are we going to backup this table? If so then we should add it to NativeSQLiteConnectionManager so that logs are capture for this table. If not then we should update createMainCompaction method so that removeDeviceSpecificDataSQL script removes data from this table after backup is created.
Just to make sure: sessionRecoveryInProgress isn't persisted, right?
I think that the practice of keeping commented-out types has a big advantage of reducing confusion when searching older revisions while it doesn't have any significant disadvantages.
However, if there is no specialRole field encountered, we will assume we're dealing with a Server/"legacy" type and fallback to sketchy string search.
What is the scenario when this can happen?
We should reintroduce the util (probably as a simple function) if we would need to decide if we can edit / delete a role in some other places.
I don't understand the reason behind this diff and the task from the summary doesn't have any description. Why can't we simply check RoleInfo and its specialRole field?