Uploaded image for project: 'XWiki Platform'
  1. XWiki Platform
  2. XWIKI-18494

Integrity constraint violation error in when saving a page a name longer than 255 characters

    XMLWordPrintable

Details

    • Bug
    • Resolution: Fixed
    • Major
    • 13.2
    • 13.2-rc-1
    • Event Stream
    • None
    • Windows 10 Pro 64 bit, Edge 89, using a local instance XWiki 13.2 RC1 on MariaDB 10.5, Tomcat 9.0.44 and HSQLDB 2.5.1/Jetty 9.4.29
    • Unknown
    • N/A
    • N/A

    Description

      STEPS TO REPRODUCE

      1. Create a page with 256 characters in its name (e.g. ttttttttttttttttttttttttttttttt1ttttttttttttttttttttttttttttttt2ttttttttttttttttttttttttttttttt3tttttttttttttttttttttttttttttt4ttttttttttttttttttttttttttttttt5ttttttttttttttttttttttttttttttt6ttttttttttttttttttttttttttttttt7tttttttttttttttttttttttttttttt256)
      2. Save the page

      EXPECTED RESULTS

      The page is saved successfully without errors and the event is displayed in Activity Stream.

      ACTUAL RESULTS

      The page is saved, but the event is not displayed in Dashboard Activity Stream.

      In console there is the following stacktrace:

      On MariaDB 10.5:

      2021-03-23 13:47:59,752 [Asynchronous handler for event store [legacy]] WARN  o.h.e.j.s.SqlExceptionHelper   - SQL Error: 1406, SQLState: 22001
      2021-03-23 13:47:59,752 [Asynchronous handler for event store [legacy]] ERROR o.h.e.j.s.SqlExceptionHelper   - (conn=7) Data too long for column 'ase_stream' at row 1
      2021-03-23 13:47:59,780 [Asynchronous handler for event store [legacy]] ERROR o.x.e.s.i.LegacyEventSaver     - Failed to save an event in the event stream.
      javax.persistence.PersistenceException: org.hibernate.exception.SQLGrammarException: could not execute statement
              at org.hibernate.internal.ExceptionConverterImpl.convert(ExceptionConverterImpl.java:154)
              at org.hibernate.internal.ExceptionConverterImpl.convert(ExceptionConverterImpl.java:181)
              at org.hibernate.internal.ExceptionConverterImpl.convert(ExceptionConverterImpl.java:188)
              at org.hibernate.internal.SessionImpl.doFlush(SessionImpl.java:1366)
              at org.hibernate.internal.SessionImpl.managedFlush(SessionImpl.java:453)
              at org.hibernate.internal.SessionImpl.flushBeforeTransactionCompletion(SessionImpl.java:3212)
              at org.hibernate.internal.SessionImpl.beforeTransactionCompletion(SessionImpl.java:2380)
              at org.hibernate.engine.jdbc.internal.JdbcCoordinatorImpl.beforeTransactionCompletion(JdbcCoordinatorImpl.java:447)
              at org.hibernate.resource.transaction.backend.jdbc.internal.JdbcResourceLocalTransactionCoordinatorImpl.beforeCompletionCallback(JdbcResourceLocalTransactionCoordinatorImpl.java:183)
              at org.hibernate.resource.transaction.backend.jdbc.internal.JdbcResourceLocalTransactionCoordinatorImpl.access$300(JdbcResourceLocalTransactionCoordinatorImpl.java:40)
              at org.hibernate.resource.transaction.backend.jdbc.internal.JdbcResourceLocalTransactionCoordinatorImpl$TransactionDriverControlImpl.commit(JdbcResourceLocalTransactionCoordinatorImpl.java:281)
              at org.hibernate.engine.transaction.internal.TransactionImpl.commit(TransactionImpl.java:101)
              at com.xpn.xwiki.internal.store.hibernate.HibernateStore.endTransaction(HibernateStore.java:843)
              at com.xpn.xwiki.store.XWikiHibernateBaseStore.endTransaction(XWikiHibernateBaseStore.java:603)
              at org.xwiki.eventstream.store.internal.LegacyEventSaver.lambda$saveLegacyEvent$0(LegacyEventSaver.java:103)
              at com.xpn.xwiki.internal.namespace.DefaultNamespaceContextExecutor.execute(DefaultNamespaceContextExecutor.java:63)
              at org.xwiki.eventstream.store.internal.LegacyEventSaver.saveLegacyEvent(LegacyEventSaver.java:96)
              at org.xwiki.eventstream.store.internal.LegacyEventSaver.saveEvent(LegacyEventSaver.java:80)
              at org.xwiki.eventstream.store.internal.LegacyEventStream.addEvent(LegacyEventStream.java:57)
              at org.xwiki.eventstream.store.internal.AbstractLegacyEventStore.syncSaveEvent(AbstractLegacyEventStore.java:58)
              at org.xwiki.eventstream.internal.AbstractAsynchronousEventStore.processTask(AbstractAsynchronousEventStore.java:365)
              at org.xwiki.eventstream.internal.AbstractAsynchronousEventStore.processTasks(AbstractAsynchronousEventStore.java:338)
              at org.xwiki.eventstream.internal.AbstractAsynchronousEventStore.run(AbstractAsynchronousEventStore.java:325)
              at java.base/java.lang.Thread.run(Thread.java:834)
      Caused by: org.hibernate.exception.SQLGrammarException: could not execute statement
              at org.hibernate.exception.internal.SQLExceptionTypeDelegate.convert(SQLExceptionTypeDelegate.java:63)
              at org.hibernate.exception.internal.StandardSQLExceptionConverter.convert(StandardSQLExceptionConverter.java:42)
              at org.hibernate.engine.jdbc.spi.SqlExceptionHelper.convert(SqlExceptionHelper.java:113)
              at org.hibernate.engine.jdbc.spi.SqlExceptionHelper.convert(SqlExceptionHelper.java:99)
              at org.hibernate.engine.jdbc.internal.ResultSetReturnImpl.executeUpdate(ResultSetReturnImpl.java:200)
              at org.hibernate.persister.entity.AbstractEntityPersister.insert(AbstractEntityPersister.java:3297)
              at org.hibernate.persister.entity.AbstractEntityPersister.insert(AbstractEntityPersister.java:3824)
              at org.hibernate.action.internal.EntityInsertAction.execute(EntityInsertAction.java:107)
              at org.hibernate.engine.spi.ActionQueue.executeActions(ActionQueue.java:604)
              at org.hibernate.engine.spi.ActionQueue.lambda$executeActions$1(ActionQueue.java:478)
              at java.base/java.util.LinkedHashMap.forEach(LinkedHashMap.java:684)
              at org.hibernate.engine.spi.ActionQueue.executeActions(ActionQueue.java:475)
              at org.hibernate.event.internal.AbstractFlushingEventListener.performExecutions(AbstractFlushingEventListener.java:345)
              at org.hibernate.event.internal.DefaultFlushEventListener.onFlush(DefaultFlushEventListener.java:40)
              at org.hibernate.event.service.internal.EventListenerGroupImpl.fireEventOnEachListener(EventListenerGroupImpl.java:93)
              at org.hibernate.internal.SessionImpl.doFlush(SessionImpl.java:1362)
              ... 20 common frames omitted
      Caused by: java.sql.SQLSyntaxErrorException: (conn=7) Data too long for column 'ase_stream' at row 1
              at org.mariadb.jdbc.internal.util.exceptions.ExceptionFactory.createException(ExceptionFactory.java:62)
              at org.mariadb.jdbc.internal.util.exceptions.ExceptionFactory.create(ExceptionFactory.java:153)
              at org.mariadb.jdbc.MariaDbStatement.executeExceptionEpilogue(MariaDbStatement.java:274)
              at org.mariadb.jdbc.ClientSidePreparedStatement.executeInternal(ClientSidePreparedStatement.java:229)
              at org.mariadb.jdbc.ClientSidePreparedStatement.execute(ClientSidePreparedStatement.java:149)
              at org.mariadb.jdbc.ClientSidePreparedStatement.executeUpdate(ClientSidePreparedStatement.java:181)
              at org.apache.commons.dbcp2.DelegatingPreparedStatement.executeUpdate(DelegatingPreparedStatement.java:136)
              at org.apache.commons.dbcp2.DelegatingPreparedStatement.executeUpdate(DelegatingPreparedStatement.java:136)
              at org.apache.commons.dbcp2.DelegatingPreparedStatement.executeUpdate(DelegatingPreparedStatement.java:136)
              at org.hibernate.engine.jdbc.internal.ResultSetReturnImpl.executeUpdate(ResultSetReturnImpl.java:197)
              ... 31 common frames omitted
      Caused by: org.mariadb.jdbc.internal.util.exceptions.MariaDbSqlException: Data too long for column 'ase_stream' at row 1
              at org.mariadb.jdbc.internal.util.exceptions.MariaDbSqlException.of(MariaDbSqlException.java:34)
              at org.mariadb.jdbc.internal.protocol.AbstractQueryProtocol.exceptionWithQuery(AbstractQueryProtocol.java:192)
              at org.mariadb.jdbc.internal.protocol.AbstractQueryProtocol.exceptionWithQuery(AbstractQueryProtocol.java:175)
              at org.mariadb.jdbc.internal.protocol.AbstractQueryProtocol.executeQuery(AbstractQueryProtocol.java:319)
              at org.mariadb.jdbc.ClientSidePreparedStatement.executeInternal(ClientSidePreparedStatement.java:220)
              ... 37 common frames omitted
      Caused by: java.sql.SQLException: Data too long for column 'ase_stream' at row 1
              at org.mariadb.jdbc.internal.protocol.AbstractQueryProtocol.readErrorPacket(AbstractQueryProtocol.java:1681)
              at org.mariadb.jdbc.internal.protocol.AbstractQueryProtocol.readPacket(AbstractQueryProtocol.java:1543)
              at org.mariadb.jdbc.internal.protocol.AbstractQueryProtocol.getResult(AbstractQueryProtocol.java:1506)
              at org.mariadb.jdbc.internal.protocol.AbstractQueryProtocol.executeQuery(AbstractQueryProtocol.java:316)
              ... 38 common frames omitted
      2021-03-23 13:47:59,909 [Asynchronous handler for event store [legacy]] WARN  o.h.e.j.s.SqlExceptionHelper   - SQL Error: 1452, SQLState: 23000
      2021-03-23 13:47:59,910 [Asynchronous handler for event store [legacy]] ERROR o.h.e.j.s.SqlExceptionHelper   - (conn=7) Cannot add or update a child row: a foreign key constraint fails (`xwiki`.`activitystream_events_status`, CONSTRAINT `FKmwu6uxkc2jl3yvej4wi1p0pv0` FOREIGN KEY (`ases_eventid`) REFERENCES `activitystream_events` (`ase_eventid`))
      2021-03-23 13:47:59,914 [Asynchronous handler for event store [legacy]] ERROR .x.x.s.XWikiHibernateBaseStore - Exception while close transaction
      javax.persistence.PersistenceException: org.hibernate.exception.ConstraintViolationException: could not execute statement
              at org.hibernate.internal.ExceptionConverterImpl.convert(ExceptionConverterImpl.java:154)
              at org.hibernate.internal.ExceptionConverterImpl.convert(ExceptionConverterImpl.java:181)
              at org.hibernate.internal.ExceptionConverterImpl.convert(ExceptionConverterImpl.java:188)
              at org.hibernate.internal.SessionImpl.doFlush(SessionImpl.java:1366)
              at org.hibernate.internal.SessionImpl.managedFlush(SessionImpl.java:453)
              at org.hibernate.internal.SessionImpl.flushBeforeTransactionCompletion(SessionImpl.java:3212)
              at org.hibernate.internal.SessionImpl.beforeTransactionCompletion(SessionImpl.java:2380)
              at org.hibernate.engine.jdbc.internal.JdbcCoordinatorImpl.beforeTransactionCompletion(JdbcCoordinatorImpl.java:447)
              at org.hibernate.resource.transaction.backend.jdbc.internal.JdbcResourceLocalTransactionCoordinatorImpl.beforeCompletionCallback(JdbcResourceLocalTransactionCoordinatorImpl.java:183)
              at org.hibernate.resource.transaction.backend.jdbc.internal.JdbcResourceLocalTransactionCoordinatorImpl.access$300(JdbcResourceLocalTransactionCoordinatorImpl.java:40)
              at org.hibernate.resource.transaction.backend.jdbc.internal.JdbcResourceLocalTransactionCoordinatorImpl$TransactionDriverControlImpl.commit(JdbcResourceLocalTransactionCoordinatorImpl.java:281)
              at org.hibernate.engine.transaction.internal.TransactionImpl.commit(TransactionImpl.java:101)
              at com.xpn.xwiki.internal.store.hibernate.HibernateStore.endTransaction(HibernateStore.java:843)
              at com.xpn.xwiki.store.XWikiHibernateBaseStore.execute(XWikiHibernateBaseStore.java:831)
              at com.xpn.xwiki.store.XWikiHibernateBaseStore.executeWrite(XWikiHibernateBaseStore.java:935)
              at org.xwiki.eventstream.store.internal.LegacyEventStatusManager.lambda$saveEventStatusInStore$2(LegacyEventStatusManager.java:194)
              at com.xpn.xwiki.internal.namespace.DefaultNamespaceContextExecutor.execute(DefaultNamespaceContextExecutor.java:63)
              at org.xwiki.eventstream.store.internal.LegacyEventStatusManager.saveEventStatusInStore(LegacyEventStatusManager.java:190)
              at org.xwiki.eventstream.store.internal.LegacyEventStatusManager.saveEventStatus(LegacyEventStatusManager.java:156)
              at org.xwiki.eventstream.store.internal.AbstractLegacyEventStore.syncSaveEventStatus(AbstractLegacyEventStore.java:91)
              at org.xwiki.eventstream.internal.AbstractAsynchronousEventStore.processTask(AbstractAsynchronousEventStore.java:382)
              at org.xwiki.eventstream.internal.AbstractAsynchronousEventStore.processTasks(AbstractAsynchronousEventStore.java:338)
              at org.xwiki.eventstream.internal.AbstractAsynchronousEventStore.run(AbstractAsynchronousEventStore.java:325)
              at java.base/java.lang.Thread.run(Thread.java:834)
      Caused by: org.hibernate.exception.ConstraintViolationException: could not execute statement
              at org.hibernate.exception.internal.SQLExceptionTypeDelegate.convert(SQLExceptionTypeDelegate.java:59)
              at org.hibernate.exception.internal.StandardSQLExceptionConverter.convert(StandardSQLExceptionConverter.java:42)
              at org.hibernate.engine.jdbc.spi.SqlExceptionHelper.convert(SqlExceptionHelper.java:113)
              at org.hibernate.engine.jdbc.spi.SqlExceptionHelper.convert(SqlExceptionHelper.java:99)
              at org.hibernate.engine.jdbc.internal.ResultSetReturnImpl.executeUpdate(ResultSetReturnImpl.java:200)
              at org.hibernate.persister.entity.AbstractEntityPersister.insert(AbstractEntityPersister.java:3297)
              at org.hibernate.persister.entity.AbstractEntityPersister.insert(AbstractEntityPersister.java:3824)
              at org.hibernate.action.internal.EntityInsertAction.execute(EntityInsertAction.java:107)
              at org.hibernate.engine.spi.ActionQueue.executeActions(ActionQueue.java:604)
              at org.hibernate.engine.spi.ActionQueue.lambda$executeActions$1(ActionQueue.java:478)
              at java.base/java.util.LinkedHashMap.forEach(LinkedHashMap.java:684)
              at org.hibernate.engine.spi.ActionQueue.executeActions(ActionQueue.java:475)
              at org.hibernate.event.internal.AbstractFlushingEventListener.performExecutions(AbstractFlushingEventListener.java:345)
              at org.hibernate.event.internal.DefaultFlushEventListener.onFlush(DefaultFlushEventListener.java:40)
              at org.hibernate.event.service.internal.EventListenerGroupImpl.fireEventOnEachListener(EventListenerGroupImpl.java:93)
              at org.hibernate.internal.SessionImpl.doFlush(SessionImpl.java:1362)
              ... 20 common frames omitted
      Caused by: java.sql.SQLIntegrityConstraintViolationException: (conn=7) Cannot add or update a child row: a foreign key constraint fails (`xwiki`.`activitystream_events_status`, CONSTRAINT `FKmwu6uxkc2jl3yvej4wi1p0pv0` FOREIGN KEY (`ases_eventid`) REFERENCES `activitystream_events` (`ase_eventid`))
              at org.mariadb.jdbc.internal.util.exceptions.ExceptionFactory.createException(ExceptionFactory.java:70)
              at org.mariadb.jdbc.internal.util.exceptions.ExceptionFactory.create(ExceptionFactory.java:153)
              at org.mariadb.jdbc.MariaDbStatement.executeExceptionEpilogue(MariaDbStatement.java:274)
              at org.mariadb.jdbc.ClientSidePreparedStatement.executeInternal(ClientSidePreparedStatement.java:229)
              at org.mariadb.jdbc.ClientSidePreparedStatement.execute(ClientSidePreparedStatement.java:149)
              at org.mariadb.jdbc.ClientSidePreparedStatement.executeUpdate(ClientSidePreparedStatement.java:181)
              at org.apache.commons.dbcp2.DelegatingPreparedStatement.executeUpdate(DelegatingPreparedStatement.java:136)
              at org.apache.commons.dbcp2.DelegatingPreparedStatement.executeUpdate(DelegatingPreparedStatement.java:136)
              at org.apache.commons.dbcp2.DelegatingPreparedStatement.executeUpdate(DelegatingPreparedStatement.java:136)
              at org.hibernate.engine.jdbc.internal.ResultSetReturnImpl.executeUpdate(ResultSetReturnImpl.java:197)
              ... 31 common frames omitted
      Caused by: org.mariadb.jdbc.internal.util.exceptions.MariaDbSqlException: Cannot add or update a child row: a foreign key constraint fails (`xwiki`.`activitystream_events_status`, CONSTRAINT `FKmwu6uxkc2jl3yvej4wi1p0pv0` FOREIGN KEY (`ases_eventid`) REFERENCES `activitystream_events` (`ase_eventid`))
              at org.mariadb.jdbc.internal.util.exceptions.MariaDbSqlException.of(MariaDbSqlException.java:34)
              at org.mariadb.jdbc.internal.protocol.AbstractQueryProtocol.exceptionWithQuery(AbstractQueryProtocol.java:192)
              at org.mariadb.jdbc.internal.protocol.AbstractQueryProtocol.exceptionWithQuery(AbstractQueryProtocol.java:175)
              at org.mariadb.jdbc.internal.protocol.AbstractQueryProtocol.executeQuery(AbstractQueryProtocol.java:319)
              at org.mariadb.jdbc.ClientSidePreparedStatement.executeInternal(ClientSidePreparedStatement.java:220)
              ... 37 common frames omitted
      Caused by: java.sql.SQLException: Cannot add or update a child row: a foreign key constraint fails (`xwiki`.`activitystream_events_status`, CONSTRAINT `FKmwu6uxkc2jl3yvej4wi1p0pv0` FOREIGN KEY (`ases_eventid`) REFERENCES `activitystream_events` (`ase_eventid`))
              at org.mariadb.jdbc.internal.protocol.AbstractQueryProtocol.readErrorPacket(AbstractQueryProtocol.java:1681)
              at org.mariadb.jdbc.internal.protocol.AbstractQueryProtocol.readPacket(AbstractQueryProtocol.java:1543)
              at org.mariadb.jdbc.internal.protocol.AbstractQueryProtocol.getResult(AbstractQueryProtocol.java:1506)
              at org.mariadb.jdbc.internal.protocol.AbstractQueryProtocol.executeQuery(AbstractQueryProtocol.java:316)
              ... 38 common frames omitted
      2021-03-23 13:47:59,926 [Asynchronous handler for event store [legacy]] WARN  o.h.e.j.s.SqlExceptionHelper   - SQL Error: 1452, SQLState: 23000
      2021-03-23 13:47:59,926 [Asynchronous handler for event store [legacy]] ERROR o.h.e.j.s.SqlExceptionHelper   - (conn=7) Cannot add or update a child row: a foreign key constraint fails (`xwiki`.`activitystream_events_status`, CONSTRAINT `FKmwu6uxkc2jl3yvej4wi1p0pv0` FOREIGN KEY (`ases_eventid`) REFERENCES `activitystream_events` (`ase_eventid`))
      2021-03-23 13:47:59,929 [Asynchronous handler for event store [legacy]] ERROR .x.x.s.XWikiHibernateBaseStore - Exception while close transaction
      javax.persistence.PersistenceException: org.hibernate.exception.ConstraintViolationException: could not execute statement
              at org.hibernate.internal.ExceptionConverterImpl.convert(ExceptionConverterImpl.java:154)
              at org.hibernate.internal.ExceptionConverterImpl.convert(ExceptionConverterImpl.java:181)
              at org.hibernate.internal.ExceptionConverterImpl.convert(ExceptionConverterImpl.java:188)
              at org.hibernate.internal.SessionImpl.doFlush(SessionImpl.java:1366)
              at org.hibernate.internal.SessionImpl.managedFlush(SessionImpl.java:453)
              at org.hibernate.internal.SessionImpl.flushBeforeTransactionCompletion(SessionImpl.java:3212)
              at org.hibernate.internal.SessionImpl.beforeTransactionCompletion(SessionImpl.java:2380)
              at org.hibernate.engine.jdbc.internal.JdbcCoordinatorImpl.beforeTransactionCompletion(JdbcCoordinatorImpl.java:447)
              at org.hibernate.resource.transaction.backend.jdbc.internal.JdbcResourceLocalTransactionCoordinatorImpl.beforeCompletionCallback(JdbcResourceLocalTransactionCoordinatorImpl.java:183)
              at org.hibernate.resource.transaction.backend.jdbc.internal.JdbcResourceLocalTransactionCoordinatorImpl.access$300(JdbcResourceLocalTransactionCoordinatorImpl.java:40)
              at org.hibernate.resource.transaction.backend.jdbc.internal.JdbcResourceLocalTransactionCoordinatorImpl$TransactionDriverControlImpl.commit(JdbcResourceLocalTransactionCoordinatorImpl.java:281)
              at org.hibernate.engine.transaction.internal.TransactionImpl.commit(TransactionImpl.java:101)
              at com.xpn.xwiki.internal.store.hibernate.HibernateStore.endTransaction(HibernateStore.java:843)
              at com.xpn.xwiki.store.XWikiHibernateBaseStore.execute(XWikiHibernateBaseStore.java:831)
              at com.xpn.xwiki.store.XWikiHibernateBaseStore.executeWrite(XWikiHibernateBaseStore.java:935)
              at org.xwiki.eventstream.store.internal.LegacyEventStatusManager.lambda$saveEventStatusInStore$2(LegacyEventStatusManager.java:194)
              at com.xpn.xwiki.internal.namespace.DefaultNamespaceContextExecutor.execute(DefaultNamespaceContextExecutor.java:63)
              at org.xwiki.eventstream.store.internal.LegacyEventStatusManager.saveEventStatusInStore(LegacyEventStatusManager.java:190)
              at org.xwiki.eventstream.store.internal.LegacyEventStatusManager.saveEventStatus(LegacyEventStatusManager.java:156)
              at org.xwiki.eventstream.store.internal.AbstractLegacyEventStore.syncSaveEventStatus(AbstractLegacyEventStore.java:91)
              at org.xwiki.eventstream.internal.AbstractAsynchronousEventStore.processTask(AbstractAsynchronousEventStore.java:382)
              at org.xwiki.eventstream.internal.AbstractAsynchronousEventStore.processTasks(AbstractAsynchronousEventStore.java:338)
              at org.xwiki.eventstream.internal.AbstractAsynchronousEventStore.run(AbstractAsynchronousEventStore.java:325)
              at java.base/java.lang.Thread.run(Thread.java:834)
      Caused by: org.hibernate.exception.ConstraintViolationException: could not execute statement
              at org.hibernate.exception.internal.SQLExceptionTypeDelegate.convert(SQLExceptionTypeDelegate.java:59)
              at org.hibernate.exception.internal.StandardSQLExceptionConverter.convert(StandardSQLExceptionConverter.java:42)
              at org.hibernate.engine.jdbc.spi.SqlExceptionHelper.convert(SqlExceptionHelper.java:113)
              at org.hibernate.engine.jdbc.spi.SqlExceptionHelper.convert(SqlExceptionHelper.java:99)
              at org.hibernate.engine.jdbc.internal.ResultSetReturnImpl.executeUpdate(ResultSetReturnImpl.java:200)
              at org.hibernate.persister.entity.AbstractEntityPersister.insert(AbstractEntityPersister.java:3297)
              at org.hibernate.persister.entity.AbstractEntityPersister.insert(AbstractEntityPersister.java:3824)
              at org.hibernate.action.internal.EntityInsertAction.execute(EntityInsertAction.java:107)
              at org.hibernate.engine.spi.ActionQueue.executeActions(ActionQueue.java:604)
              at org.hibernate.engine.spi.ActionQueue.lambda$executeActions$1(ActionQueue.java:478)
              at java.base/java.util.LinkedHashMap.forEach(LinkedHashMap.java:684)
              at org.hibernate.engine.spi.ActionQueue.executeActions(ActionQueue.java:475)
              at org.hibernate.event.internal.AbstractFlushingEventListener.performExecutions(AbstractFlushingEventListener.java:345)
              at org.hibernate.event.internal.DefaultFlushEventListener.onFlush(DefaultFlushEventListener.java:40)
              at org.hibernate.event.service.internal.EventListenerGroupImpl.fireEventOnEachListener(EventListenerGroupImpl.java:93)
              at org.hibernate.internal.SessionImpl.doFlush(SessionImpl.java:1362)
              ... 20 common frames omitted
      Caused by: java.sql.SQLIntegrityConstraintViolationException: (conn=7) Cannot add or update a child row: a foreign key constraint fails (`xwiki`.`activitystream_events_status`, CONSTRAINT `FKmwu6uxkc2jl3yvej4wi1p0pv0` FOREIGN KEY (`ases_eventid`) REFERENCES `activitystream_events` (`ase_eventid`))
              at org.mariadb.jdbc.internal.util.exceptions.ExceptionFactory.createException(ExceptionFactory.java:70)
              at org.mariadb.jdbc.internal.util.exceptions.ExceptionFactory.create(ExceptionFactory.java:153)
              at org.mariadb.jdbc.MariaDbStatement.executeExceptionEpilogue(MariaDbStatement.java:274)
              at org.mariadb.jdbc.ClientSidePreparedStatement.executeInternal(ClientSidePreparedStatement.java:229)
              at org.mariadb.jdbc.ClientSidePreparedStatement.execute(ClientSidePreparedStatement.java:149)
              at org.mariadb.jdbc.ClientSidePreparedStatement.executeUpdate(ClientSidePreparedStatement.java:181)
              at org.apache.commons.dbcp2.DelegatingPreparedStatement.executeUpdate(DelegatingPreparedStatement.java:136)
              at org.apache.commons.dbcp2.DelegatingPreparedStatement.executeUpdate(DelegatingPreparedStatement.java:136)
              at org.apache.commons.dbcp2.DelegatingPreparedStatement.executeUpdate(DelegatingPreparedStatement.java:136)
              at org.hibernate.engine.jdbc.internal.ResultSetReturnImpl.executeUpdate(ResultSetReturnImpl.java:197)
              ... 31 common frames omitted
      Caused by: org.mariadb.jdbc.internal.util.exceptions.MariaDbSqlException: Cannot add or update a child row: a foreign key constraint fails (`xwiki`.`activitystream_events_status`, CONSTRAINT `FKmwu6uxkc2jl3yvej4wi1p0pv0` FOREIGN KEY (`ases_eventid`) REFERENCES `activitystream_events` (`ase_eventid`))
              at org.mariadb.jdbc.internal.util.exceptions.MariaDbSqlException.of(MariaDbSqlException.java:34)
              at org.mariadb.jdbc.internal.protocol.AbstractQueryProtocol.exceptionWithQuery(AbstractQueryProtocol.java:192)
              at org.mariadb.jdbc.internal.protocol.AbstractQueryProtocol.exceptionWithQuery(AbstractQueryProtocol.java:175)
              at org.mariadb.jdbc.internal.protocol.AbstractQueryProtocol.executeQuery(AbstractQueryProtocol.java:319)
              at org.mariadb.jdbc.ClientSidePreparedStatement.executeInternal(ClientSidePreparedStatement.java:220)
              ... 37 common frames omitted
      Caused by: java.sql.SQLException: Cannot add or update a child row: a foreign key constraint fails (`xwiki`.`activitystream_events_status`, CONSTRAINT `FKmwu6uxkc2jl3yvej4wi1p0pv0` FOREIGN KEY (`ases_eventid`) REFERENCES `activitystream_events` (`ase_eventid`))
              at org.mariadb.jdbc.internal.protocol.AbstractQueryProtocol.readErrorPacket(AbstractQueryProtocol.java:1681)
              at org.mariadb.jdbc.internal.protocol.AbstractQueryProtocol.readPacket(AbstractQueryProtocol.java:1543)
              at org.mariadb.jdbc.internal.protocol.AbstractQueryProtocol.getResult(AbstractQueryProtocol.java:1506)
              at org.mariadb.jdbc.internal.protocol.AbstractQueryProtocol.executeQuery(AbstractQueryProtocol.java:316)
              ... 38 common frames omitted

      The issue does not occur if the name of the page is 255 characters or shorter.

      Attachments

        Activity

          People

            tmortagne Thomas Mortagne
            iandriuta Ilie Andriuta
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: