Confluence - JIRA Workbox notifications fail when sharing a long JQL result

XMLWordPrintable

      If you write a JQL query that is too long and share it with an user that has Confluence access too and your JIRA and Confluence instances are sharing their notifications (https://confluence.atlassian.com/display/DOC/Configuring+Workbox+Notifications), then Confluence will fail to retrieve that notification to the AO_9412A1_AONOTIFICATION table due to column length.

      You will see the following stack trace in your logs when using MySQL:

      ...
      Caused by: com.mysql.jdbc.MysqlDataTruncation: Data truncation: Data too long for column 'GLOBAL_ID' at row 1
              at com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:3561)
              at com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:3495)
              at com.mysql.jdbc.MysqlIO.sendCommand(MysqlIO.java:1959)
              at com.mysql.jdbc.MysqlIO.sqlQueryDirect(MysqlIO.java:2113)
              at com.mysql.jdbc.ConnectionImpl.execSQL(ConnectionImpl.java:2693)
              at com.mysql.jdbc.PreparedStatement.executeInternal(PreparedStatement.java:2102)
              at com.mysql.jdbc.PreparedStatement.executeUpdate(PreparedStatement.java:2395)
              at com.mysql.jdbc.PreparedStatement.executeUpdate(PreparedStatement.java:2313)
              at com.mysql.jdbc.PreparedStatement.executeUpdate(PreparedStatement.java:2298)
              at com.mchange.v2.c3p0.impl.NewProxyPreparedStatement.executeUpdate(NewProxyPreparedStatement.java:105)
              at net.java.ao.EntityProxy.save(EntityProxy.java:278)
              at net.java.ao.EntityProxy.invoke(EntityProxy.java:119)
              ... 275 more
      

      The following on Oracle:

      Caused by: java.sql.SQLException: ORA-12899: value too large for column "CONFLUENCE_4_3_7"."AO_9412A1_AONOTIFICATION"."GLOBAL_ID" (actual: 454, maximum: 255)
      
      	at oracle.jdbc.driver.T4CTTIoer.processError(T4CTTIoer.java:445)
      	at oracle.jdbc.driver.T4CTTIoer.processError(T4CTTIoer.java:396)
      	at oracle.jdbc.driver.T4C8Oall.processError(T4C8Oall.java:879)
      	at oracle.jdbc.driver.T4CTTIfun.receive(T4CTTIfun.java:450)
      	at oracle.jdbc.driver.T4CTTIfun.doRPC(T4CTTIfun.java:192)
      	at oracle.jdbc.driver.T4C8Oall.doOALL(T4C8Oall.java:531)
      	at oracle.jdbc.driver.T4CPreparedStatement.doOall8(T4CPreparedStatement.java:207)
      	at oracle.jdbc.driver.T4CPreparedStatement.executeForRows(T4CPreparedStatement.java:1044)
      	at oracle.jdbc.driver.OracleStatement.doExecuteWithTimeout(OracleStatement.java:1329)
      	at oracle.jdbc.driver.OraclePreparedStatement.executeInternal(OraclePreparedStatement.java:3584)
      	at oracle.jdbc.driver.OraclePreparedStatement.executeUpdate(OraclePreparedStatement.java:3665)
      	at oracle.jdbc.driver.OraclePreparedStatementWrapper.executeUpdate(OraclePreparedStatementWrapper.java:1352)
      	at com.mchange.v2.c3p0.impl.NewProxyPreparedStatement.executeUpdate(NewProxyPreparedStatement.java:105)
      	at net.java.ao.EntityProxy.save(EntityProxy.java:278)
      	at net.java.ao.EntityProxy.invoke(EntityProxy.java:119)
      	... 231 more

      Steps to reproduce

      1. Link Confluence and JIRA together with trusted application link
      2. Set up common user management, so that you will use JIRA as user directory
      3. Create two users user1 and user2, being part of confluence-users group
      4. Create a project in JIRA
      5. Write a JQL in JIRA that contains quite some elements (my example was: ?jql=project%20%3D%20csike%20and%20issuetype%20in%20(Bug%2CImprovement%2C"New%20Feature"%2CSub-task%2CTask)%20and%20created%20>%20endOfDay()%20and%20description%20~%20'whatever'%20and%20affectedVersion%20is%20EMPTY
      6. Share this using the share button (you will need to have mail server configured on JIRA end) with user2 when you are logged in as user1

      Expected result: Workbox Notification displayed on Confluence
      Actual result: No notification displayed, only email received, stack trace above found in the logs

      Workaround
      Save the JQL results as a filter and share the filter instead.

      You need to restart JIRA to get rid of the notification triggered, so that JIRA will remove it from its caches.

            Assignee:
            Vu Truong Vo (Inactive)
            Reporter:
            Peter Koczan (Inactive)
            Votes:
            6 Vote for this issue
            Watchers:
            12 Start watching this issue

              Created:
              Updated:
              Resolved: