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

Search elastic does not return results for fed.shared files #126

Open davitol opened 5 years ago

davitol commented 5 years ago

Steps to reproduce

1) Create a text file 2) Edit it and type as content "Sin cambios" 3) Save it 4) Fed share the file with a server that has elastic search enabled 5) Search for the filename or the content

Expected behavior

File should appear in the search results

Current behavior

File is not shown in the results.

(cc @micbar @pmaier1 JFYI) Please triage

davitol commented 5 years ago

WORKS. occ search:index:rebuild did the trick, sorry for the noise

micbar commented 5 years ago

Ok, that is interesting.

Search Index rebuild is not intended to be used in production. It should work with cron.php or search:index:update (which is basically the same)

micbar commented 5 years ago

Honestly we never tested Federated Files in this context. But I am sure that we are lacking ANY external storage. We can not track changes on WND, Federation or other external user storages.

davitol commented 5 years ago

But I am sure that we are lacking ANY external storage

I was not able to make search elastic work in the external storages (tried with owncloud and Google Drive for example)

@micbar search:index:rebuild command indexes the external mounts? I guess it does not

micbar commented 5 years ago

@davitol search:index:rebuild destroys the index for the given user and indexes every file from scratch. This is why we get files on external mounts.

All other indexing relies on update jobs. Update jobs could only be triggered if we have a filesystem event.

We need to investigate, if we can catch the "Federated Share accepted" event. @VicDeo Could you confirm? You are our federation expert :-)

VicDeo commented 5 years ago

catch the "Federated Share accepted" event

here it is https://github.com/owncloud/core/blob/master/apps/files_sharing/lib/External/Manager.php#L208

micbar commented 5 years ago

ok, thanks, I will consider it for planning.

micbar commented 5 years ago

@VicDeo

sharidas commented 5 years ago

PR here: https://github.com/owncloud/search_elastic/pull/131

micbar commented 3 years ago

@jnweiger Needs re testing

please test during #221