Uploaded image for project: 'WildFly'
  1. WildFly
  2. WFLY-1517

regression: using a ResourceAdaptor (rar) which has properties that use primitives as arguments will fail to deploy

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Done
    • Icon: Major Major
    • 8.0.0.Alpha2
    • 8.0.0.Alpha1
    • JCA
    • None

      org.jboss.as.connector.util.Injection.java:159

      protected Method findMethod(Class<?> clz, String methodName, String propertyType) {
      while (!clz.equals(Object.class)) {
      List<Method> hits = null;
      Method[] methods = clz.getDeclaredMethods();
      for (int i = 0; i < methods.length; i++) {
      Method method = methods[i];
      if (methodName.equals(method.getName()) && method.getParameterTypes().length == 1) {
      if (propertyType == null || propertyType.equals(method.getParameterTypes()[0].getName())) {

      the above is not taking primitives into account.
      Example, the IBM IMS connector ims1132.rar has:

      <config-property>
      <config-property-name>enableHASupport</config-property-name>
      <config-property-type>java.lang.Boolean</config-property-type>
      <config-property-value>true</config-property-value>
      </config-property>

      and the method:

      public void setEnableHASupport(boolean isHAEnabled)

      Our "FindMethod" will find this method but will fail to select it as it compares "java.lang.Boolean" with "boolean"

              tfonteyn Tom Fonteyne (Inactive)
              tfonteyn Tom Fonteyne (Inactive)
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

                Created:
                Updated:
                Resolved: