-
Notifications
You must be signed in to change notification settings - Fork 2.1k
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
[WIP] Migrate properties to fileid #26949
Conversation
@VicDeo, thanks for your PR! By analyzing the history of the files in this pull request, we identified @DeepDiver1975, @tanghus and @bantu to be potential reviewers. |
def21c1
to
78725ce
Compare
78725ce
to
dd462a1
Compare
// TODO: drop userid and propertypath | ||
} | ||
|
||
if (!$schema->hasTable("${prefix}addressbooks")) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
oh, do we really also need these tables ? are they related to oc_properties ?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@PVince81 oc_properties table belongs to dav
app and is contained in core db schema by mistake now.
To use migrations on dav app all its schema needs to be ported to migrations first.
This is how I see it.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm not sure if this is necessary. But maybe it's also ok to have it now, @DeepDiver1975 what do you think ?
@VicDeo make sure the DB dump diffs before and after are the same.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@PVince81 ok, Let's assume we don't need all this tables. This table is in db_structure.xml and belongs to dav app.
Does this mean that I should rewrite entire core db structure to Migrations?
I think I can't use Migrations just for one table. So the choice either move the table to proper app (dav) and put use_migrations
into its info.xml
or do the same for the entire core.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
A migration should be possible for just a single table.
Note that when enabling the app the first time, ownCloud will still setup the DB based on db_structure.xml. But updates have to go through migrations.
So if you setup that one table within the migration (and move it out of db_structure.xml), it should work.
*/ | ||
public function down(Schema $schema) | ||
{ | ||
// We can't migrate below 10.0, can we? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
no, let's always ignore the down
part for now...
Closed in favor of #27005 |
This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs. |
Description
Use migrations for all dav tables.
Use fileid instead of path in dav properties
Related Issue
Fixes #25563
Motivation and Context
t this table contains the full path to the target file and doesn't properly detect renames... so properties can get lost.
Furthermore, the column is too small and longer paths might not fit.
How Has This Been Tested?
Screenshots (if appropriate):
Checklist: