owncloud / search_elastic

Elasticsearch based full text search
https://github.com/owncloud/search_elastic
GNU General Public License v2.0
8 stars 1 forks source link

Retrieve only the mtime from elasticsearch #311

Closed jvillafanez closed 1 year ago

jvillafanez commented 1 year ago

Retrieve only the mtime field from elasticsearch because it's the only field being used at the moment.

Related https://github.com/owncloud/enterprise/issues/5547

sonarcloud[bot] commented 1 year ago

Kudos, SonarCloud Quality Gate passed!    Quality Gate passed

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 0 Code Smells

0.0% 0.0% Coverage
0.0% 0.0% Duplication

CristianCardosoArellano commented 1 year ago

We cannot see your link from community: https://github.com/owncloud/enterprise/issues/5547

jvillafanez commented 1 year ago

We cannot see your link from community: https://github.com/owncloud/enterprise/issues/5547

I don't think there is a public ticket related to the issue...

Anyway, the reason is to improve the performance since elasticsearch was sending the content of the matched files (not sure if all the content or a part of it). This means that the response could be of several MBs. With this change, elasticsearch will send only the info we need, so instead of several MBs, it should send a few KBs.

The data we have is from ~3MB to ~100KB. It will depend on the number of matches and the size of the file.

Note that there is no change in the behavior coming from this PR

CristianCardosoArellano commented 1 year ago

I see, thanks for your quick response.