Share » Forums » Extensions » eZ Find » Indexing non attributes values

Indexing non attributes values

Indexing non attributes values

Wednesday 08 July 2009 8:06:34 am - 4 replies

Author Message

Max Keil

Wednesday 08 July 2009 3:59:49 pm

Hi again,

at the moment there is just a couple of meta and node attributes per stored for each object - defined in ezsolr.php. All of this attributes have to be attributes of eZContentObject or eZContentObjectTreeNode. There is no way to add custom meta data depending on class.
If you use special custom datatypes only in this class you can write your own indexing class "ezfSolrDocumentFieldBase" and use this to transfer extended meta data to the index.

Mit freundlichen Grüßen
Best regards

Max Keil

____________________________________________________________
eZ Publish Gold Partner - http://www.all2e.com
http://ez.no/partners/worldwide_partners/all2e_gmbh

Carlos Revillo

Thursday 09 July 2009 2:06:01 am

Thanks again, Max.

I'll give a try. On the other hand, i still doubt if this (indexing rating of objects) is really useful. i mean, its easy to think that in a single day, we will have a lot more rating actions than publishing actions. for showing results about time in real-time, we'll have to call the index with every single vote, and that's will impact in the perfomance, i think.

thinking about a cronjob, we'll have to trick the voting action to tell ez that this object "has changed" even if there's no publishing actions related to it (don't know if i'm right with this...).

best regards.

Alexandre Nion

Wednesday 05 August 2009 6:05:02 am

Hi,

I'm also not sure this will be the best way in your case, but for some reasons we also had to customize our object indexing.
The given method (creating dedicated attributes) will do the job, that's what we were usually doing for that kind of needs. But for some practical reasons (because we had several of them to write) and because these were not sensitive data to store, we recently had another approach by allowing eZ Find to handle some what we call "virtual attributes".

In the end we now have a small patch to eZ Find, working like a charm for us, and a quite simple method to write new attributes dedicated to search/facets.
As you write your indexing method (based on content class), You should be able to index any data you want within the object.

You can take a look at http://issues.ez.no/IssueView.php?Id=15222 for more information.

Carlos Revillo

Tuesday 25 August 2009 2:53:19 pm

Hi Alexandre.

I've tested your patch and works perfectly for me. at the end i'm using it for other kind of attributes, (not for voting) but it solves my needs perfectly.

thanks for sharing!.

You must be logged in to post messages in this topic!

36 542 Users on board!

Forums menu