Uploaded image for project: 'Infinispan'
  1. Infinispan
  2. ISPN-2082

JdbcStringBasedCacheStore: ORA-24816 when storing BLOB values > 4000 bytes

This issue belongs to an archived project. You can view it, but you can't modify it. Learn more

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Done
    • Icon: Major Major
    • 9.1.0.Final
    • 5.1.5.FINAL
    • Loaders and Stores
    • None
    • Workaround Exists
    • Hide

      Clone the JdbcStringBasedCacheStore implementation and write my own insert/update SQL in storeLockSafe() in order to get around the issue.

      Show
      Clone the JdbcStringBasedCacheStore implementation and write my own insert/update SQL in storeLockSafe() in order to get around the issue.

      I've configured a JdbcStringBasedCacheStore with a VARCHAR(4000) key column and a BLOB value column. If I try to store a BLOB value of less than 4000 bytes, everything works fine. If the value is greater, the cache store fails with ORA-24816. This occurs because the BLOB column is not the last one in the PreparedStatement SQL as the Oracle driver requires. My current, sad workaround is to clone the JdbcStringBasedCacheStore implementation and write my own insert/update SQL in storeLockSafe(). This works fine, but obviously isn't ideal from an upgrade point of view. Simply overriding storeLockSafe() isn't an option due to all the private fields.

              remerson@redhat.com Ryan Emerson
              rlscharer Ryan Scharer (Inactive)
              Archiver:
              rhn-support-adongare Amol Dongare

                Created:
                Updated:
                Resolved:
                Archived: