Skip to content

[POC] Store file id in extended attributes where possible - #14546

Closed
icewind1991 wants to merge 2 commits into
masterfrom
extended-attributes
Closed

icewind1991 wants to merge 2 commits into
masterfrom
extended-attributes

Conversation

@icewind1991

Copy link
Copy Markdown
Contributor

Requires http://pecl.php.net/package/xattr to be installed and the filesystem to support user extended attributes (default on btrfs, mount option for ext(3|4) iirc)

To test:

  • upload a new file to a folder
  • share the file
  • delete the cache entry for the file
  • check that the file is no longer shown in the web interface
  • run the filescanner
  • check that the file is back in the web interface and still shared

cc @PVince81 @DeepDiver1975

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Does it mean you need to add getAttribute and setAttribute to the default storage wrapper, to make sure they are forwarded to the underlying storage ?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No, there are magic methods to handle that

@PVince81

Copy link
Copy Markdown
Contributor

Sweet.

We should probably also check for file id clashes. What happens if two files have the same file id attribute ? (for whatever reason)

@scrutinizer-notifier

Copy link
Copy Markdown

The inspection completed: No issues found

@PVince81 PVince81 mentioned this pull request Mar 23, 2015
3 tasks done
@ghost

ghost commented Apr 30, 2015

Copy link
Copy Markdown

Refer to this link for build results (access rights to CI server needed):
https://ci.owncloud.org//job/pull-request-analyser-ng-simple/12025/
💣 Test FAILed. 💣

nooo432

@MorrisJobke

Copy link
Copy Markdown
Contributor

@icewind1991 rebase needed

@PVince81

PVince81 commented Jul 3, 2015

Copy link
Copy Markdown
Contributor

I wonder if we should do this as an optional separate app and register a storage wrapper or something ? This requires the FS to support xattr and the FS must be local, so no external storage (except the one of type "Local").

@icewind1991

Copy link
Copy Markdown
Contributor Author

Some external storages support adding arbitrary metadata to files which could be used.

I'm not sure if this can be cleanly implemented in an app due to the changes to the scanner logic (which apps cant overwrite without hacks)

@PVince81

PVince81 commented Sep 1, 2015

Copy link
Copy Markdown
Contributor

Would it make sense to move this to an app instead ?

@DeepDiver1975

Copy link
Copy Markdown
Contributor

This could be an alternative implementation for the upcoming storage based cache Händler.i vote die close for the time being.

@icewind1991 icewind1991 closed this Sep 1, 2015
@MorrisJobke
MorrisJobke deleted the extended-attributes branch September 1, 2015 12:21
@lock lock Bot locked as resolved and limited conversation to collaborators Aug 10, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants