Some database remarks
#1
Hi!
I have some remarks about the database:

First of all, postgresql should also be supported, not only mysql and sqlite. When users, like me,
already run a postgresql server, they have to switch to mysql or run 2 database servers.

The kodi database user has to much permissions. It would be better, the admin creates a
database for "kodi" and a user for that database. Kodi can only create and alter the tables.
Everytime the database is being updated, kodi could prompt the user to go on or cancel to
make a backup first. So no old database is being left and has to be deleted (maybe also for sqlite).
I think, users with a separate database are advanced ones. So they should be able to make
a backup before the database is updated by kodi.
Reply
#2
Quote:postgresql should also be supported
Based on what? Just because you are a PostgreSQL user? XBMC started the MySQL functionality and still today with Kodi, MySQL usage is considered 'experimental' as indicated in the kodi.log file. Right now, it's not possible to 'simply add' another database layer in Kodi. In terms of man power we are coming up short in that area. So for now we're all stuck with (My)SQL. But we welcome anyone with a fully tested PR for PostgreSQL, MS Access or any other database concept as an additional layer.

Quote:The kodi database user has to much permissions.
The vast majority of Kodi users are not sufficiently sql database savvy, so setting MySQL user settings in a more varied way would make the database maze even bigger. I'm guessing at least 98% of all Kodi mysql users has no other databases running on their setup. And those who do are likely to have more MySQL knowledge to begin with.

Quote:Everytime the database is being updated, kodi could prompt the user to go on or cancel to make a backup first
Huh? Do you have any idea how many updates are made to the video database alone when watching one video? Prompting the user every single time would make ever user go nuts.

Quote:So no old database is being left and has to be deleted
Kodi will not delete old databases. There is always someone who will downgrade, and he will then pick up where the old database was left.
If old(er) databases are truly obsolete, the user can delete them him/herself.

Quote:I think, users with a separate database are advanced ones. So they should be able to make
a backup before the database is updated by kodi.
There are plenty of external (My)SQL tools which can make perfect database backups. There is no need for Kodi to reinvent the wheel for that. The old database is the backup. Whenever a database update is being performed, the data from the old database will be copied into the new database.
Reply
#3
work is done in regards to replacing our current DB system witih ODBC (or some other framework). This should then also allow for PostgreSQL. No ETA
Reply
#4
As long as us mods aren't supposed to diagnose MS Access. Just sayin'.

Personally I am very happy with MySQL. Mind you I already had it installed for MythTV which I still run as a backend.

As far as permissions are concerned, I see the point, and I think the updates the OP was referring to was updates to the database schema, not the database changes that are made on playback or scraping.

As far as udating the schema is concerned, I have seen both methods used. MythTV updates the database to the next schema and there is no going back (except via a backup).

Kodi updates to a NEW database and leaves the old one behind.

I now prefer Kodi's method as an accidental upgrade to one client can otherwise trash your DB with no going back.
If I have helped you or increased your knowledge, click the 'thumbs up' button to give thanks :) (People with less than 20 posts won't see the "thumbs up" button.)
Reply
#5
(2017-07-03, 19:39)Klojum Wrote: Huh? Do you have any idea how many updates are made to the video database alone when watching one video? Prompting the user every single time would make ever user go nuts.
I mean the database version upgrade, not when just doing another entry.
Reply
#6
(2017-07-04, 21:25)mase76 Wrote:
(2017-07-03, 19:39)Klojum Wrote: Huh? Do you have any idea how many updates are made to the video database alone when watching one video? Prompting the user every single time would make ever user go nuts.
I mean the database version upgrade, not when just doing another entry.
Why? We don't touch the old one so why would you even bother nagging the user?
Read/follow the forum rules.
For troubleshooting and bug reporting, read this first
Interested in seeing some YouTube videos about Kodi? Go here and subscribe
Reply
#7
(2017-07-03, 19:39)Klojum Wrote: Why? We don't touch the old one so why would you even bother nagging the user?
I was talking about a case with one database, where kodi can only alter tables.

The current state is no problem when just running mysql for kodi only.
But when having databses for different usecases, it is not very nice.
I know, that would be no easy changes. Don't feel pressed! That is just a thought to be made.
I am glad, that there is a central database support at all. And as this is still an experimental feature,
this is only a suggestion of mine.
Reply

Logout Mark Read Team Forum Stats Members Help
Some database remarks0