Uploaded image for project: 'CMS'
  1. CMS
  2. CMS-10172

Search service : An error occurred and the rendering is in error and is not displayed when a criterion is not valid

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: Major Major
    • 4.5.11, 4.6.0
    • 4.2.7
    • Plugin : Search
    • None
    • 4.6 M8

      How to reproduce
      The customer set-up a search engine with a criteria based on a tag. The tag has been modified by the customer (in the xml) and the criteria in the search engine was not modified.

      Actual behavior
      Then the search engine is displaying an error in the back-office.
      And an error is available in the logs

      2019-12-10 14:48:49,247 ERROR [org.ametys.web.frontoffice.search] (http-nio-8080-exec-22;/entp2/fr/index.html) An error occured while executing search component 'org.ametys.web.frontoffice.search.requesttime.impl.CriterionTreeSearchComponent@50bfe9bd' for request '2175e7fc'. Other components will be executed but the result can be inconsistent
      org.ametys.web.frontoffice.search.requesttime.impl.InvalidUserInputException: The user input criterion '{"value":"ENTP2_APPEL_PROJET_RECHERCHE","autoposting":false}' for criterion 'ContentSearchable$systemProperty$tags$1' is invalid because it is not among declared restricted values ([{"value":"ENTP2_SPORT","autoposting":false}, {"value":"ENTP2_CONCOURS","autoposting":false}, {"value":"ENTP2_FORMATION","autoposting":false}, {"value":"ENTP2_HOMMAGE","autoposting":false}, {"value":"ENTP2_QUOTIDIEN","autoposting":false}, {"value":"ENTP2_SCOLARITE","autoposting":false}, {"value":"ENTP2_TEMOIGNAGE","autoposting":false}, {"value":"ENTP2_LEGISLATION","autoposting":false}, {"value":"ENTP2_FINANCES","autoposting":false}, {"value":"ENTP2_APPEL_PROJET","autoposting":false}, {"value":"ENTP2_INTERNATIONAL","autoposting":false}, {"value":"ENTP2_ACTUALITE","autoposting":false}, {"value":"ENTP2_RECHERCHE","autoposting":false}, {"value":"ENTP2_VIE_INSTITUTIONNELLE","autoposting":false}, {"value":"ENTP2_ELECTIONS","autoposting":false}, {"value":"ENTP2_SORTIES","autoposting":false}, {"value":"ENTP2_CULTURE","autoposting":false}, {"value":"ENTP2_PORTRAIT","autoposting":false}, {"value":"ENTP2_NUMERIQUE","autoposting":false}]).
      

      The error is very clear (thank you)

      Expected behavior

      • catch it and display the service without this criteria
      • if possible display a message in the service parameters

            lbouchet Loïc Bouchet
            fravetier Frederic Ravetier (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated:
              Resolved: