This site has been archived and you can no longer log in or post new messages. For up-to-date community resources please visit

eZ Community » Forums » Developer » viewcache and reverse related objects

viewcache and reverse related objects

viewcache and reverse related objects

Wednesday 12 December 2012 2:14:03 pm - 3 replies


I have encountered a strange problem with the smart cache and reverse related objects.

A page of class 'category' lists its reverse related objects, which are pictures.

In viewcache.ini I have:


When I delete a relation from a 'picture' object, the cache of the related object is cleared, but when I add a relation to the 'picture' object, the cache of the newly added related object is not cleared. So I've had to make do with defining 'AdditionalObjectIDs' in viewcache.ini which means the cache is cleared even it's not necessary.

Can anyone see what I'm doing wrong?



Thursday 13 December 2012 10:21:23 am

Hi Andy, 

From the top of my head, I'd recommend tweaking the following configuration directive, depending on which relation type you are using. Below, the default values in settings/viewcache.ini of the current legacy github master branch.

# Determines which types of related objects will be choosen to clear view cache
# when publishing current object.
# Possible values are:
# common                    - common relations made on object level
# embedded                  - embedded objects
# linked                    - linked objects
# attribute                 - relations made with attributes of 'object relation' or
#                             'object relations' datatypes
# reverse_common            - reverse common relations (objects that relate the one currently
#                             being published) on object level
# reverse_embedded          - objects that have current object as embedded
# reverse_linked            - objects that have linked current object
# reverse_attribute         - objects that have current object as related in their attributes.

Hope this helps a bit,

Thursday 13 December 2012 11:42:24 am

Hi Nicolas

That helped a lot. I had got attribute and reverse_attributes reversed in my mind. I already had:


but that was the wrong way round, as category was related through an attribute of picture. So I needed to add:


Thanks very much!


Thursday 13 December 2012 12:06:27 pm

Great to hear!

Indeed, the control granularity is broad here, sometimes making it a touch complex.


Modified on Thursday 13 December 2012 12:06:45 pm by Nicolas Pastorino


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

36 542 Users on board!

Forums menu

Proudly Developed with from