Uploaded image for project: 'eZ Publish / Platform'
  1. eZ Publish / Platform
  2. EZP-31628

Cache randomly makes SearchService fails on location search after a while in PROD env

    XMLWordPrintable

Details

    • Icon: Bug Bug
    • Resolution: Unresolved
    • Icon: High High
    • None
    • eZ Platform 2.4
    • None
    • None

    Description

      Hi,

      We are working on a website for a client with dynamic contents and so on.

      Currently, we are using plain legacy symfony caches, because SOLR shows issues with our version (object of another issue).

      After a while in use, without any noticeable modifications of the contents that are supposed to be displayed on the page rendered by controller action, the symfony action fails in ezplatform API while searching some locations (that exists).

      Issue is when processing the results by the API.

      Cache clearing solves the issue, but our client has no means to clearing caches from eZPlatform UI (they are webmasters).

      Is it solved anyhow by the next versions of our CMS ?

      Issue can be replicated when copying the full cache/prod cache directory on a duplicate server holding our website.

      Here is the stack of the error rendered in logs :

      Symfony\Component\Debug\Exception\FatalThrowableError: Type error: Argument 2 passed to eZ\Publish\Core\Repository\Helper\DomainMapper::buildLocationWithContent() must be an instance of eZ\Publish\API\Repository\Values\Content\Content, null given, called in /var/www/fire.in/vendor/ezsystems/ezpublish-kernel/eZ/Publish/Core/Repository/Helper/DomainMapper.php on line 624 in /var/www/fire.in/vendor/ezsystems/ezpublish-kernel/eZ/Publish/Core/Repository/Helper/DomainMapper.php:501 Stack trace: #0 /var/www/fire.in/vendor/ezsystems/ezpublish-kernel/eZ/Publish/Core/Repository/Helper/DomainMapper.php(624): eZ\Publish\Core\Repository\Helper\DomainMapper->buildLocationWithContent(Object(eZ\Publish\SPI\Persistence\Content\Location), NULL, Object(eZ\Publish\SPI\Persistence\Content\ContentInfo)) #1 /var/www/fire.in/vendor/ezsystems/ezpublish-kernel/eZ/Publish/Core/Repository/SearchService.php(317): eZ\Publish\Core\Repository\Helper\DomainMapper->buildLocationDomainObjectsOnSearchResult(Object(eZ\Publish\API\Repository\Values\Content\Search\SearchResult), Array) #2 /var/www/fire.in/var/cache/prod/ContainerVvyjbly/SearchService_e90870c.php(33): eZ\Publish\Core\Repository\SearchService->findLocations(Object(eZ\Publish\API\Repository\Values\Content\LocationQuery), Array, true) #3 /var/www/fire.in/vendor/ezsystems/ezpublish-kernel/eZ/Publish/Core/SignalSlot/SearchService.php(135): SearchService_e90870c->findLocations(Object(eZ\Publish\API\Repository\Values\Content\LocationQuery), Array, true) #4 /var/www/fire.in/src/FireInBundle/Service/ChallengesAndResources.php(34):

       

      More oddly, when displaying one of the locations that are supposed to be rendered by the search, another content is returned :

      Location is OK, but Content is root content (ID=1) :

       

      eZ\Publish\Core\Repository\Values\Content\Location Object
      (
      [contentInfo:protected] => eZ\Publish\API\Repository\Values\Content\ContentInfo Object
      (
      [id:protected] => 1
      [contentTypeId:protected] => 1
      [name:protected] => Main page
      [sectionId:protected] => 1
      [currentVersionNo:protected] => 11
      [published:protected] => 1
      [ownerId:protected] => 14
      [modificationDate:protected] => DateTime Object
      (
      [date] => 2019-01-28 15:30:38.000000
      [timezone_type] => 3
      [timezone] => Europe/Berlin
      )

      [publishedDate:protected] => DateTime Object
      (
      [date] => 2015-11-30 14:10:46.000000
      [timezone_type] => 3
      [timezone] => Europe/Berlin
      )

      [alwaysAvailable:protected] => 1
      [remoteId:protected] => 9459d3c29e15006e45197295722c7ade
      [mainLanguageCode:protected] => eng-GB
      [mainLocationId:protected] => 2
      [status:protected] => 1
      )

      [path:protected] =>
      [id:protected] => 320
      [status] => 1
      [priority:protected] => 0
      [hidden:protected] =>
      [invisible:protected] =>
      [remoteId:protected] => 032842b1303d4d05eb08f8fe89aa3e71
      [parentLocationId:protected] => 319
      [pathString:protected] => /1/2/209/319/320/
      [depth:protected] => 4
      [sortField:protected] => 2
      [sortOrder:protected] => 0
      [content:protected] => eZ\Publish\Core\Repository\Values\Content\ContentProxy Object
      (
      [object] => eZ\Publish\Core\Repository\Values\Content\Content Object
      (
      Here is contents of content id=1 (main page)
      )

      [id] => 1
      )

      )

       

      Thanks for any help

      Yours sincerely,

      Julien DEININGER

      AUSY

      Attachments

        Activity

          People

            Unassigned Unassigned
            juliendeininger@yahoo.fr juliendeininger@yahoo.fr
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated: