feat: include special directories that won't be indexed#11163
feat: include special directories that won't be indexed#11163jvillafanez merged 4 commits intomasterfrom
Conversation
|
Thanks for opening this pull request! The maintainers of this repository would appreciate it if you would create a changelog item based on your changes. |
|
Current test failures are "expected".
Before adjusting the tests, I think we need to agree if we're fine with this solution. |
|
While trying to add new unit tests I've found https://github.com/owncloud/reva/blob/main/pkg/storage/utils/walker/walker.go#L81-L82 I suggest to swap those lines. |
|
@nirajacharya2 could you adjust the failing tests? #11163 (comment) contains the reasons why the tests are failing. It's probably easier if you add the changes in this branch so we have the tests passing here.
I'll leave it for a different PR because those are changes in reva, so we'd need to update the reva version (once those changes are implemented) and then adjust the test. |
61c4147 to
40ea697
Compare
40ea697 to
e78caf9
Compare
|
feat: include special directories that won't be indexed
feat: include special directories that won't be indexed



Description
Skip indexing some special files.
.directory was indexed with the username as name. For the admin user, searching using "admin" would show results despite the personal space having unrelated files../.spacedirectory contains some space-related data (the space's image, readme file...) that was being indexed. Users are unlikely to look for this type of content.Related Issue
#11028
Motivation and Context
Users might think there are issues if weird results are being returned (despite being "correctly" indexed). It is expected that we search the contents of the space, but not the space itself nor related data.
How Has This Been Tested?
Manually checked with the bleve cli. Those files aren't indexed any longer and they won't appear in the search results.
Screenshots (if appropriate):
Types of changes
Checklist:
Notes
This PR will prevent those files from being indexed. However, in case of upgrades, the files are expected to be indexed already (this code wasn't available when the files were indexed)
For now, oCIS doesn't provide a way to remove the files from the index. You'll need to manually remove the entries from the index.