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

Properly support sequence ids with new VCSLockManager

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 5.9.6-SNAPSHOT
    • Fix Version/s: 6.0
    • Component/s: Core VCS

      Description

      In https://github.com/nuxeo/nuxeo-core/commit/ce6a34d7d694e13079cc4736db8a6fcd1753eb04 we've introduced a regression about the use of numerical ids (sequences) in lock manager.

      Caused by: org.nuxeo.ecm.core.storage.lock.LockException: org.nuxeo.ecm.core.storage.StorageException: Could not select: SELECT "owner", "created" FROM "locks" WHERE "id" = ?
              at org.nuxeo.ecm.core.storage.sql.VCSLockManager.setLock(VCSLockManager.java:202)
              at org.nuxeo.ecm.core.storage.sql.SessionImpl.setLock(SessionImpl.java:1427)
              at org.nuxeo.ecm.core.storage.sql.ra.ConnectionImpl.setLock(ConnectionImpl.java:418)
              at org.nuxeo.ecm.core.storage.sql.coremodel.SQLSession.setLock(SQLSession.java:926)
              ... 67 more
              Suppressed: org.nuxeo.ecm.core.storage.StorageException: Could not select: SELECT "owner", "created" FROM "locks" WHERE "id" = ?
                      at org.nuxeo.ecm.core.storage.sql.jdbc.JDBCRowMapper.getSelectRows(JDBCRowMapper.java:457)
                      at org.nuxeo.ecm.core.storage.sql.jdbc.JDBCRowMapper.readSimpleRow(JDBCRowMapper.java:920)
                      at org.nuxeo.ecm.core.storage.sql.jdbc.JDBCMapper.getLock(JDBCMapper.java:1197)
                      at org.nuxeo.ecm.core.storage.sql.jdbc.JDBCMapper$SetLock.call(JDBCMapper.java:1229)
                      at org.nuxeo.ecm.core.storage.sql.jdbc.JDBCMapper$SetLock.call(JDBCMapper.java:1216)
                      at org.nuxeo.ecm.core.storage.sql.jdbc.JDBCMapper.callInTransaction(JDBCMapper.java:1146)
                      at org.nuxeo.ecm.core.storage.sql.jdbc.JDBCMapper.setLock(JDBCMapper.java:1213)
                      at org.nuxeo.ecm.core.storage.sql.VCSLockManager.setLockInternal(VCSLockManager.java:264)
                      at org.nuxeo.ecm.core.storage.sql.VCSLockManager.setLock(VCSLockManager.java:185)
                      ... 70 more
              Caused by: java.lang.ClassCastException: java.lang.String cannot be cast to java.lang.Long
                      at org.nuxeo.ecm.core.storage.sql.jdbc.dialect.DialectPostgreSQL.setToPreparedStatement(DialectPostgreSQL.java:353)
                      at org.nuxeo.ecm.core.storage.sql.jdbc.db.Column.setToPreparedStatement(Column.java:263)
                      at org.nuxeo.ecm.core.storage.sql.jdbc.JDBCRowMapper.getSelectRows(JDBCRowMapper.java:412)
                      ... 78 more
      

        Attachments

          Issue Links

            Activity

              People

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

                Dates

                • Created:
                  Updated:
                  Resolved: