Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-6372375

MXBean spec does not explicitly specify what the "typeName" is for a TabularType or CompositeType

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Duplicate
    • Icon: P3 P3
    • 6
    • 6
    • core-svc
    • None

      The "Type mapping rules" section in MXBean specification describes cases of mapping when the Open Type is TabularType or CompositeType.

      However it is not specified what typeName parameter is used for constructing both TabularType and CompositeType - it can be whatever the implementor wants. The problem is that the value of this field participates in comparison of 2 TabularType/CompositeType objects.

      The only place in spec, which marginally says about the typeName value is:

      <excerpt>
      For example, the TabularType for a Map<String,ObjectName> might be constructed with code like this:

      String typeName =
          "java.util.Map<java.lang.String,javax.management.ObjectName>";
      String[] keyValue =
          new String[] {"key", "value"};
      OpenType[] openTypes =
          new OpenType[] {SimpleType.STRING, SimpleType.OBJECTNAME};
      CompositeType rowType =
          new CompositeType(typeName, typeName, keyValue, keyValue, openTypes);
      TabularType tabularType =
          new TabularType(typeName, typeName, rowType, new String[] {"key"});

      </excerpt>

            emcmanus Eamonn McManus
            ashusher Alexander Shusherov (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved:
              Imported:
              Indexed: