BTM
  1. BTM
  2. BTM-30

Resource creation cannot map long primitives to vendor's XADataSource

    Details

    • Type: Bug Bug
    • Status: Closed Closed
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 1.0, 1.0.1, 1.1, 1.2, 1.3
    • Fix Version/s: 1.3.1
    • Labels:
      None
    • Number of attachments :
      0

      Description

      The lobBuffer property of the jTDS driver for MS SQL Server 2005 expects a long value. When The property is configured in the driverProperties, the value cannot be mapped by BTM and this exception is thrown:

      bitronix.tm.resource.ResourceConfigurationException: cannot create JDBC datasource named cfgmgmt
      at bitronix.tm.resource.jdbc.PoolingDataSource.init(PoolingDataSource.java:50)
      at bitronix.tm.resource.ResourceLoader.initXAResourceProducers(ResourceLoader.java:161)
      at bitronix.tm.resource.ResourceLoader.init(ResourceLoader.java:132)
      at bitronix.tm.resource.ResourceLoader.init(ResourceLoader.java:62)
      at bitronix.tm.BitronixTransactionManager.<init>(BitronixTransactionManager.java:48)
      at bitronix.tm.TransactionManagerServices.getTransactionManager(TransactionManagerServices.java:43)
      ...
      Caused by: bitronix.tm.utils.PropertyException: cannot convert values of type 'java.lang.String' into type 'long'
      at bitronix.tm.utils.PropertyUtils.transform(PropertyUtils.java:229)
      at bitronix.tm.utils.PropertyUtils.setDirectProperty(PropertyUtils.java:189)
      at bitronix.tm.utils.PropertyUtils.setProperty(PropertyUtils.java:51)
      at bitronix.tm.resource.common.XAPool.createXAFactory(XAPool.java:223)
      at bitronix.tm.resource.common.XAPool.<init>(XAPool.java:47)
      at bitronix.tm.resource.jdbc.PoolingDataSource.buildXAPool(PoolingDataSource.java:59)
      at bitronix.tm.resource.jdbc.PoolingDataSource.init(PoolingDataSource.java:48)

        Activity

        Hide
        Ludovic Orban added a comment -

        This is a limitation of the resource creation code. I never encountered (and even expected) an XADataSource implementation that would require something else than boolean, integer or String so support for those types has been left out.

        Support for setting and getting all primitive types has now been added, the fix is available in the trunk.

        Show
        Ludovic Orban added a comment - This is a limitation of the resource creation code. I never encountered (and even expected) an XADataSource implementation that would require something else than boolean, integer or String so support for those types has been left out. Support for setting and getting all primitive types has now been added, the fix is available in the trunk.

          People

          • Assignee:
            Ludovic Orban
            Reporter:
            Ludovic Orban
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: