Uploaded image for project: 'Hadoop Common'
  1. Hadoop Common
  2. HADOOP-12126

Configuration might use ApplicationClassLoader to create XML parser

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Open
    • Major
    • Resolution: Unresolved
    • 2.7.0
    • None
    • conf
    • None

    Description

      org.apache.hadoop.conf.Configuration creates a new DocumentBuilder to parse the XML config files, but it doesn't specify which classloader to use to discover and instantiate the XML parser.

      Because DocumentBuilderFactory relies on ServiceProvider, whose by default, uses the context classloader. If classpath isolation is turned on, one might expect that that Configuration will only load classes from the system classloader, but it turns out that the context classloader is set to ApplicationClassLoader, and that a XML parser might be loaded from the user classpath.

      Attachments

        1. HADOOP-12126.001.patch
          2 kB
          Laurent Goujon
        2. HADOOP-12126.002.patch
          4 kB
          Laurent Goujon
        3. HADOOP-12126.003.patch
          4 kB
          Laurent Goujon

        Activity

          People

            laurent Laurent Goujon
            laurent Laurent Goujon
            Votes:
            0 Vote for this issue
            Watchers:
            6 Start watching this issue

            Dates

              Created:
              Updated: