Uploaded image for project: 'JBoss Messaging'
  1. JBoss Messaging
  2. JBMESSAGING-825

Transactions corrupted because sybase truncates trailing zeros

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed (View Workflow)
    • Priority: Major
    • Resolution: Done
    • Affects Version/s: 1.2.0.Beta2
    • Fix Version/s: 1.2.0.CR1
    • Component/s: None
    • Labels:
      None

      Description

      Sybase has the wonderful characteristic of truncating trailing zeros in VARBINARY columns.

      So If I set a byte array with values: 1, 2, 3, 4, 5, 0, 0, 0

      Then I get back a byte array with values: 1, 2, 3, 4, 5

      Xid global txids and branch qualifiers can have trailing zeros since they can become corrupt after storing and retrieving in the database.

      Solution is to introduce a flag "usingTrailingByte" on the pm config. If true then a non zero byte will always be appended to the byte[] before storing and removed on retrieval.

      This flag should be true for sybase config and false for others.

        Gliffy Diagrams

          Attachments

            Activity

              People

              • Assignee:
                timfox Tim Fox
                Reporter:
                timfox Tim Fox
              • Votes:
                0 Vote for this issue
                Watchers:
                0 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: