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

Deprecate XML interchange in java.management/javax/management/modelmbean/DescriptorSupport for removal

XMLWordPrintable

    • Icon: CSR CSR
    • Resolution: Approved
    • Icon: P4 P4
    • 25
    • core-svc
    • None
    • source
    • low
    • Niche methods that exist for historical reasons only. No known usage, no bug reports, and no evidence of discussion in public forums.
    • Java API
    • SE

      Summary

      javax.management.modelmbean.DescriptorSupport has a constructor and a method providing creation from, and export to, XML. These are unused in the JDK and have no commonly known usage. They should be removed. The javax.management.modelmbean.XMLParseException which is only thrown by those methods should be removed too.

      Problem

      A constructor and a method exist for historical convenience reasons, not as a practical requirement.

      They implement a form of XML parsing which may be incomplete or unreliable. This parsing adds an unnecesssary class which is confusingly named the same as a class in a "real" XML parser.

      XML parsing when required, is best done by an independent implementation, not this class.

      To simplify the module, these should be removed.

      Solution

      Deprecate these API for removal.

      Specification

      Terminally deprecate, by annotating with @Deprecated(since="25", forRemoval=true) in the class javax.management.modelmbean.DescriptorSupport

      • DescriptorSupport(String inStr) constructor

      • toXMLString() method

      Also, add the same annotation on the class javax.management.modelmbean.XMLParseException

      specdiff.zip attached, wherein the files specdiff/DescriptorSupport.html and specdiff/XMLParseException.html contain the changes.

            kevinw Kevin Walls
            kevinw Kevin Walls
            Daniel Fuchs, Serguei Spitsyn
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated:
              Resolved: