Uploaded image for project: 'Nuxeo Platform'
  1. Nuxeo Platform
  2. NXP-16014

Fix rendition publishing for paths with quotes

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: 6.0
    • Fix Version/s: 6.0-HF01, 7.1
    • Component/s: Core

      Description

      If the path to a section has a quote, a stack trace occurs:

      Caused by: org.nuxeo.ecm.core.api.ClientException: Failed to execute query: org.nuxeo.ecm.core.query.QueryParseException: Syntax error: Invalid token <A/sections> at offset 144 in query: SELECT * FROM Document WHERE rend:sourceVersionableId = '258374dd-22e8-4a82-9dec-7067405f6ecb' AND ecm:path STARTSWITH '/Université Numérique d'A/sections' AND ecm:isProxy = 1
              at org.nuxeo.ecm.core.api.AbstractSession.query(AbstractSession.java:1373)
              at org.nuxeo.ecm.core.api.AbstractSession.query(AbstractSession.java:1269)
              at org.nuxeo.ecm.core.api.AbstractSession.query(AbstractSession.java:1252)
              at org.nuxeo.ecm.core.api.AbstractSession.query(AbstractSession.java:1228)
              at sun.reflect.GeneratedMethodAccessor417.invoke(Unknown Source)
              at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
              at java.lang.reflect.Method.invoke(Method.java:601)
              at org.nuxeo.ecm.core.api.TransactionalCoreSessionWrapper.invoke(TransactionalCoreSessionWrapper.java:131)
              at com.sun.proxy.$Proxy64.query(Unknown Source)
              at org.nuxeo.ecm.platform.rendition.publisher.RenditionPublicationCoreTree.getPublishedDocumentsFromLiveDocument(RenditionPublicationCoreTree.java:94)
              at org.nuxeo.ecm.platform.rendition.publisher.RenditionPublicationCoreTree.getExistingPublishedDocument(RenditionPublicationCoreTree.java:71)
              at org.nuxeo.ecm.platform.publisher.impl.service.PublisherServiceImpl.getExistingPublishedDocument(PublisherServiceImpl.java:566)
              at org.nuxeo.ecm.platform.publisher.impl.service.AbstractRemotableTree.getExistingPublishedDocument(AbstractRemotableTree.java:59)
              at org.nuxeo.ecm.platform.publisher.web.PublishActionsBean.getPublishedDocumentsFor(PublishActionsBean.java:373)
              ...
      Caused by: org.nuxeo.ecm.core.query.QueryException: org.nuxeo.ecm.core.query.QueryParseException: Syntax error: Invalid token <A/sections> at offset 144 in query: SELECT * FROM Document WHERE rend:sourceVersionableId = '258374dd-22e8-4a82-9dec-7067405f6ecb' AND ecm:path STARTSWITH '/Université Numérique d'A/sections' AND ecm:isProxy = 1: SELECT * FROM Document WHERE rend:sourceVersionableId = '258374dd-22e8-4a82-9dec-7067405f6ecb' AND ecm:path STARTSWITH '/Université Numérique d'A/sections' AND ecm:isProxy = 1
              at org.nuxeo.ecm.core.storage.sql.coremodel.SQLSession.query(SQLSession.java:585)
              at org.nuxeo.ecm.core.api.AbstractSession.query(AbstractSession.java:1329)
              ... 474 more
      Caused by: org.nuxeo.ecm.core.query.QueryParseException: org.nuxeo.ecm.core.query.QueryParseException: Syntax error: Invalid token <A/sections> at offset 144 in query: SELECT * FROM Document WHERE rend:sourceVersionableId = '258374dd-22e8-4a82-9dec-7067405f6ecb' AND ecm:path STARTSWITH '/Université Numérique d'A/sections' AND ecm:isProxy = 1
              at org.nuxeo.ecm.core.query.sql.SQLQueryParser.parse(SQLQueryParser.java:51)
              at org.nuxeo.ecm.core.storage.sql.jdbc.NXQLQueryMaker.buildQuery(NXQLQueryMaker.java:262)
              at org.nuxeo.ecm.core.storage.sql.jdbc.JDBCMapper.query(JDBCMapper.java:751)
              at sun.reflect.GeneratedMethodAccessor208.invoke(Unknown Source)
              at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
              at java.lang.reflect.Method.invoke(Method.java:601)
              at org.nuxeo.ecm.core.storage.sql.jdbc.JDBCMapperConnector.doInvoke(JDBCMapperConnector.java:22)
              at org.nuxeo.ecm.core.storage.sql.jdbc.JDBCMapperConnector.invoke(JDBCMapperConnector.java:62)
              at com.sun.proxy.$Proxy65.query(Unknown Source)
              at org.nuxeo.ecm.core.storage.sql.SoftRefCachingMapper.query(SoftRefCachingMapper.java:102)
              at org.nuxeo.ecm.core.storage.sql.SessionImpl.query(SessionImpl.java:1380)
              at org.nuxeo.ecm.core.storage.sql.ra.ConnectionImpl.query(ConnectionImpl.java:366)
              at org.nuxeo.ecm.core.storage.sql.coremodel.SQLSession.query(SQLSession.java:545)
              ... 475 more
      Caused by: org.nuxeo.ecm.core.query.QueryParseException: org.nuxeo.ecm.core.query.QueryParseException: Syntax error: Invalid token <A/sections> at offset 144
              at org.nuxeo.ecm.core.query.sql.SQLQueryParser.parse(SQLQueryParser.java:41)
              at org.nuxeo.ecm.core.query.sql.SQLQueryParser.parse(SQLQueryParser.java:47)
              ... 487 more
      Caused by: org.nuxeo.ecm.core.query.QueryParseException: Syntax error: Invalid token <A/sections> at offset 144
              at org.nuxeo.ecm.core.query.sql.parser.parser.parseFailed(parser.java:466)
              at org.nuxeo.ecm.core.query.sql.parser.parser.unrecovered_syntax_error(parser.java:457)
              at java_cup.runtime.lr_parser.parse(lr_parser.java:601)
              at org.nuxeo.ecm.core.query.sql.SQLQueryParser.parse(SQLQueryParser.java:39)
              ... 488 more
      

        Attachments

          Activity

            People

            • Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: