You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@jmeter.apache.org by pm...@apache.org on 2016/03/12 15:25:49 UTC

svn commit: r1734706 - in /jmeter/trunk: ./ lib/ lib/doc/ res/maven/ src/components/org/apache/jmeter/assertions/ test/src/org/apache/jmeter/functions/ test/src/org/apache/jmeter/junit/ xdocs/

Author: pmouawad
Date: Sat Mar 12 14:25:49 2016
New Revision: 1734706

URL: http://svn.apache.org/viewvc?rev=1734706&view=rev
Log:
Bug 59156 - XMLAssertion : drop jdom dependency by using XMLReader
Move code to standard Java XML API
Fix Tests to remove dependencies on jdom
Move jdom download to lib/doc as it is needed for printable documentation generation (Anakia)
Remove jdom from Maven dependencies and also remove velocity version property by the way as it is not needed (commented)
Move jdom reference in build.properties in the doc block
Bugzilla Id: 59156

Modified:
    jmeter/trunk/build.properties
    jmeter/trunk/build.xml
    jmeter/trunk/eclipse.classpath
    jmeter/trunk/lib/   (props changed)
    jmeter/trunk/lib/aareadme.txt
    jmeter/trunk/lib/doc/   (props changed)
    jmeter/trunk/res/maven/ApacheJMeter_parent.pom
    jmeter/trunk/src/components/org/apache/jmeter/assertions/XMLAssertion.java
    jmeter/trunk/test/src/org/apache/jmeter/functions/ComponentReferenceFunctionTest.java
    jmeter/trunk/test/src/org/apache/jmeter/junit/JMeterTest.java
    jmeter/trunk/xdocs/changes.xml

Modified: jmeter/trunk/build.properties
URL: http://svn.apache.org/viewvc/jmeter/trunk/build.properties?rev=1734706&r1=1734705&r2=1734706&view=diff
==============================================================================
--- jmeter/trunk/build.properties (original)
+++ jmeter/trunk/build.properties Sat Mar 12 14:25:49 2016
@@ -199,11 +199,6 @@ jcharts.jar                 = jcharts-${
 jcharts.loc                 = ${maven2.repo}/jcharts/jcharts/${jcharts.version}
 jcharts.md5                 = 13927D8077C991E7EBCD8CB284746A7A
 
-jdom.version                = 1.1.3
-jdom.jar                    = jdom-${jdom.version}.jar
-jdom.loc                    = ${maven2.repo}/org/jdom/jdom/${jdom.version}
-jdom.md5                    = 140bfed13341fe2039eee0f26a16d705
-
 rhino.version               = 1.7.7.1
 rhino.jar                   = rhino-${rhino.version}.jar
 rhino.loc                   = ${maven2.repo}/org/mozilla/rhino/${rhino.version}
@@ -352,6 +347,12 @@ commons-lang.jar            = commons-la
 commons-lang.loc            = ${maven2.repo}/commons-lang/commons-lang/${commons-lang.version}
 commons-lang.md5            = 4d5c1693079575b362edf41500630bbd
 
+# required by anakia
+jdom.version                = 1.1.3
+jdom.jar                    = jdom-${jdom.version}.jar
+jdom.loc                    = ${maven2.repo}/org/jdom/jdom/${jdom.version}
+jdom.md5                    = 140bfed13341fe2039eee0f26a16d705
+
 # Optional for use by checkstyle
 checkstyle-all.version       = 6.13
 checkstyle-all.jar           = checkstyle-${checkstyle-all.version}-all.jar

Modified: jmeter/trunk/build.xml
URL: http://svn.apache.org/viewvc/jmeter/trunk/build.xml?rev=1734706&r1=1734705&r2=1734706&view=diff
==============================================================================
--- jmeter/trunk/build.xml (original)
+++ jmeter/trunk/build.xml Sat Mar 12 14:25:49 2016
@@ -387,7 +387,6 @@
     <include name="${lib.dir}/${jakarta-oro.jar}"/>
     <include name="${lib.dir}/${javamail.jar}"/>
     <include name="${lib.dir}/${jcharts.jar}"/>
-    <include name="${lib.dir}/${jdom.jar}"/>
     <include name="${lib.dir}/${jms.jar}"/>
     <include name="${lib.dir}/${rhino.jar}"/>
     <include name="${lib.dir}/${jodd-core.jar}"/>
@@ -460,7 +459,6 @@
     <pathelement location="${lib.dir}/${jakarta-oro.jar}"/>
     <pathelement location="${lib.dir}/${javamail.jar}"/>
     <pathelement location="${lib.dir}/${jcharts.jar}"/>
-    <pathelement location="${lib.dir}/${jdom.jar}"/>
     <pathelement location="${lib.dir}/${jms.jar}"/>
     <pathelement location="${lib.dir}/${rhino.jar}"/>
     <pathelement location="${lib.dir}/${jodd-core.jar}"/>
@@ -496,7 +494,7 @@
   <!-- Anakia classpath -->
   <path id="anakia.classpath">
     <pathelement location="${lib.doc}/${velocity.jar}"/>
-    <pathelement location="${lib.dir}/${jdom.jar}"/>
+    <pathelement location="${lib.doc}/${jdom.jar}"/>
     <pathelement location="${lib.dir}/${commons-collections.jar}"/>
     <pathelement location="${lib.doc}/${commons-lang.jar}"/>
     <pathelement location="${lib.dir}/${logkit.jar}"/>
@@ -2880,7 +2878,7 @@ run JMeter unless all the JMeter jars ar
         <process_jarfile jarname="jakarta-oro"/>
         <process_jarfile jarname="javamail"/>
         <process_jarfile jarname="jcharts"/>
-        <process_jarfile jarname="jdom"/>
+        <process_jarfile jarname="jdom" dest.dir="${lib.doc}"/>
         <process_jarfile jarname="jms"/>
         <process_jarfile jarname="rhino"/>
         <process_jarfile jarname="jodd-core"/>
@@ -2912,7 +2910,7 @@ run JMeter unless all the JMeter jars ar
     <target name="_process_doc_jars">
       <process_jarfile jarname="commons-collections"/>
       <process_jarfile jarname="commons-lang"   dest.dir="${lib.doc}"/>
-      <process_jarfile jarname="jdom"/>
+      <process_jarfile jarname="jdom"           dest.dir="${lib.doc}"/>
       <process_jarfile jarname="velocity"   dest.dir="${lib.doc}"/>
     </target>
 

Modified: jmeter/trunk/eclipse.classpath
URL: http://svn.apache.org/viewvc/jmeter/trunk/eclipse.classpath?rev=1734706&r1=1734705&r2=1734706&view=diff
==============================================================================
--- jmeter/trunk/eclipse.classpath (original)
+++ jmeter/trunk/eclipse.classpath Sat Mar 12 14:25:49 2016
@@ -69,7 +69,6 @@
 	<classpathentry kind="lib" path="lib/httpcore-4.4.4.jar"/>
 	<classpathentry kind="lib" path="lib/httpmime-4.5.2.jar"/>
 	<classpathentry kind="lib" path="lib/jcharts-0.7.5.jar"/>
-	<classpathentry kind="lib" path="lib/jdom-1.1.3.jar"/>
 	<classpathentry kind="lib" path="lib/jodd-core-3.6.7.jar"/>
 	<classpathentry kind="lib" path="lib/jodd-lagarto-3.6.7.jar"/>
 	<classpathentry kind="lib" path="lib/jodd-log-3.6.7.jar"/>

Propchange: jmeter/trunk/lib/
------------------------------------------------------------------------------
--- svn:ignore (original)
+++ svn:ignore Sat Mar 12 14:25:49 2016
@@ -27,7 +27,6 @@ httpclient-4.5.2.jar
 httpcore-4.4.4.jar
 httpmime-4.5.2.jar
 jcharts-0.7.5.jar
-jdom-1.1.3.jar
 jms*.jar
 jodd-core-3.6.7.jar
 jodd-lagarto-3.6.7.jar

Modified: jmeter/trunk/lib/aareadme.txt
URL: http://svn.apache.org/viewvc/jmeter/trunk/lib/aareadme.txt?rev=1734706&r1=1734705&r2=1734706&view=diff
==============================================================================
--- jmeter/trunk/lib/aareadme.txt (original)
+++ jmeter/trunk/lib/aareadme.txt Sat Mar 12 14:25:49 2016
@@ -116,7 +116,6 @@ http://jcharts.sourceforge.net/downloads
 jdom-1.1.3
 --------
 http://www.jdom.org/downloads/index.html
-- XMLAssertion, JMeterTest ONLY
 - Anakia
 
 jodd-core-3.6.7

Propchange: jmeter/trunk/lib/doc/
------------------------------------------------------------------------------
--- svn:ignore (original)
+++ svn:ignore Sat Mar 12 14:25:49 2016
@@ -1,2 +1,3 @@
-velocity-1.7.jar
 commons-lang-2.6.jar
+jdom-1.1.3.jar
+velocity-1.7.jar

Modified: jmeter/trunk/res/maven/ApacheJMeter_parent.pom
URL: http://svn.apache.org/viewvc/jmeter/trunk/res/maven/ApacheJMeter_parent.pom?rev=1734706&r1=1734705&r2=1734706&view=diff
==============================================================================
--- jmeter/trunk/res/maven/ApacheJMeter_parent.pom (original)
+++ jmeter/trunk/res/maven/ApacheJMeter_parent.pom Sat Mar 12 14:25:49 2016
@@ -80,7 +80,6 @@ under the License.
       <httpcore.version>4.4.4</httpcore.version>
       <jakarta-oro.version>2.0.8</jakarta-oro.version>
       <jcharts.version>0.7.5</jcharts.version>
-      <jdom.version>1.1.3</jdom.version>
       <jodd-core.version>3.6.7</jodd-core.version>
       <jodd-lagarto.version>3.6.7</jodd-lagarto.version>
       <jodd-log.version>3.6.7</jodd-log.version>
@@ -106,7 +105,6 @@ under the License.
       <xmlgraphics-commons.version>2.0.1</xmlgraphics-commons.version>
       <javamail.version>1.5.0-b01</javamail.version>
       <jms.version>1.1.1</jms.version>
-      <velocity.version>1.7</velocity.version>
     </properties>
 
     <dependencies>
@@ -246,18 +244,6 @@ under the License.
         <version>0.7.5</version>
       </dependency>
       <dependency>
-        <groupId>org.jdom</groupId>
-        <artifactId>jdom</artifactId>
-        <version>${jdom.version}</version>
-        <!-- Jaxen brings in missing dependencies -->
-        <exclusions>
-          <exclusion>
-            <artifactId>jaxen</artifactId>
-            <groupId>jaxen</groupId>
-          </exclusion>
-        </exclusions>
-      </dependency>
-      <dependency>
         <groupId>org.mozilla</groupId>
         <artifactId>rhino</artifactId>
         <version>${rhino.version}</version>
@@ -392,13 +378,6 @@ under the License.
         <artifactId>hamcrest-core</artifactId>
         <version>${hamcrest-core.version}</version>
       </dependency>
-      <!-- Docs only; not needed for source or binary archives
-      <dependency>
-        <groupId>org.apache.velocity</groupId>
-        <artifactId>velocity</artifactId>
-        <version>${velocity.version}</version>
-      </dependency>
-       -->
     </dependencies>
 
     <repositories>

Modified: jmeter/trunk/src/components/org/apache/jmeter/assertions/XMLAssertion.java
URL: http://svn.apache.org/viewvc/jmeter/trunk/src/components/org/apache/jmeter/assertions/XMLAssertion.java?rev=1734706&r1=1734705&r2=1734706&view=diff
==============================================================================
--- jmeter/trunk/src/components/org/apache/jmeter/assertions/XMLAssertion.java (original)
+++ jmeter/trunk/src/components/org/apache/jmeter/assertions/XMLAssertion.java Sat Mar 12 14:25:49 2016
@@ -27,23 +27,30 @@ import org.apache.jmeter.testelement.Abs
 import org.apache.jmeter.testelement.ThreadListener;
 import org.apache.jorphan.logging.LoggingManager;
 import org.apache.log.Logger;
-import org.jdom.JDOMException;
-import org.jdom.input.SAXBuilder;
+import org.xml.sax.InputSource;
+import org.xml.sax.SAXException;
+import org.xml.sax.XMLReader;
+import org.xml.sax.helpers.XMLReaderFactory;
 
 /**
- * Checks if the result is a well-formed XML content using jdom
+ * Checks if the result is a well-formed XML content using {@link XMLReader}
  * 
  */
 public class XMLAssertion extends AbstractTestElement implements Serializable, Assertion, ThreadListener {
-    private static final Logger log = LoggingManager.getLoggerForClass();
+    private static final Logger LOG = LoggingManager.getLoggerForClass();
 
-    private static final long serialVersionUID = 240L;
+    private static final long serialVersionUID = 241L;
 
     // one builder for all requests in a thread
-    private static final ThreadLocal<SAXBuilder> myBuilder = new ThreadLocal<SAXBuilder>() {
+    private static final ThreadLocal<XMLReader> XML_READER = new ThreadLocal<XMLReader>() {
         @Override
-        protected SAXBuilder initialValue() {
-            return new SAXBuilder();
+        protected XMLReader initialValue() {
+            try {
+                return XMLReaderFactory.createXMLReader();
+            } catch (SAXException e) {
+                LOG.error("Error initializing XMLReader in XMLAssertion", e); 
+                return null;
+            }
         }
     };
 
@@ -62,18 +69,17 @@ public class XMLAssertion extends Abstra
             return result.setResultForNull();
         }
         result.setFailure(false);
-        SAXBuilder builder = myBuilder.get();
-
-        try {
-            builder.build(new StringReader(resultData));
-        } catch (JDOMException e) {
-            log.debug("Cannot parse result content", e); // may well happen
-            result.setFailure(true);
-            result.setFailureMessage(e.getMessage());
-        } catch (IOException e) {
-            log.error("Cannot read result content", e); // should never happen
+        XMLReader builder = XML_READER.get();
+        if(XML_READER!=null) {
+            try {
+                builder.parse(new InputSource(new StringReader(resultData)));
+            } catch (SAXException | IOException e) {
+                result.setError(true);
+                result.setFailureMessage(e.getMessage());
+            }
+        } else {
             result.setError(true);
-            result.setFailureMessage(e.getMessage());
+            result.setFailureMessage("Cannot initialize XMLReader in element:"+getName()+", check jmeter.log file");
         }
 
         return result;
@@ -85,6 +91,6 @@ public class XMLAssertion extends Abstra
 
     @Override
     public void threadFinished() {
-        myBuilder.set(null);
+        XML_READER.set(null);
     }
 }

Modified: jmeter/trunk/test/src/org/apache/jmeter/functions/ComponentReferenceFunctionTest.java
URL: http://svn.apache.org/viewvc/jmeter/trunk/test/src/org/apache/jmeter/functions/ComponentReferenceFunctionTest.java?rev=1734706&r1=1734705&r2=1734706&view=diff
==============================================================================
--- jmeter/trunk/test/src/org/apache/jmeter/functions/ComponentReferenceFunctionTest.java (original)
+++ jmeter/trunk/test/src/org/apache/jmeter/functions/ComponentReferenceFunctionTest.java Sat Mar 12 14:25:49 2016
@@ -18,22 +18,32 @@
 
 package org.apache.jmeter.functions;
 
+import java.io.FileInputStream;
+import java.io.FileNotFoundException;
+import java.io.IOException;
+import java.io.InputStream;
 import java.util.HashMap;
 import java.util.Iterator;
-import java.util.List;
 import java.util.Map;
 
+import javax.xml.parsers.DocumentBuilder;
+import javax.xml.parsers.DocumentBuilderFactory;
+import javax.xml.parsers.ParserConfigurationException;
+
+import junit.framework.Test;
+import junit.framework.TestSuite;
+
+import org.apache.commons.lang3.StringUtils;
 import org.apache.jmeter.engine.util.CompoundVariable;
 import org.apache.jmeter.junit.JMeterTest;
 import org.apache.jmeter.junit.JMeterTestCaseJUnit3;
 import org.apache.jorphan.logging.LoggingManager;
 import org.apache.log.Logger;
-import org.jdom.Document;
-import org.jdom.Element;
-import org.jdom.input.SAXBuilder;
-
-import junit.framework.Test;
-import junit.framework.TestSuite;
+import org.w3c.dom.Document;
+import org.w3c.dom.Element;
+import org.w3c.dom.NodeList;
+import org.xml.sax.InputSource;
+import org.xml.sax.SAXException;
 
 public class ComponentReferenceFunctionTest extends JMeterTestCaseJUnit3 {
 
@@ -72,29 +82,38 @@ public class ComponentReferenceFunctionT
         return suite;
     }
     
+    private Element getBodyFromXMLDocument(InputStream stream)
+            throws ParserConfigurationException, FileNotFoundException, SAXException, IOException {
+        DocumentBuilderFactory dbf = DocumentBuilderFactory.newInstance();
+        dbf.setIgnoringElementContentWhitespace(true);
+        dbf.setIgnoringComments(true);
+        DocumentBuilder db = dbf.newDocumentBuilder();
+        Document doc = db.parse(new InputSource(stream));
+        org.w3c.dom.Element root = doc.getDocumentElement();
+        org.w3c.dom.Element body = (org.w3c.dom.Element) root.getElementsByTagName("body").item(0);
+        return body;
+    }
+    
     /*
      * Extract titles from functions.xml
      */
     public void createFunctionSet() throws Exception {
         funcTitles = new HashMap<>(20);
-
         String compref = "../xdocs/usermanual/functions.xml";
-        SAXBuilder bldr = new SAXBuilder();
-        Document doc = bldr.build(compref);
-        Element root = doc.getRootElement();
-        Element body = root.getChild("body");
-        Element section = body.getChild("section");
-        @SuppressWarnings("unchecked")
-        List<Element> sections = section.getChildren("subsection");
-        for (int i = 0; i < sections.size(); i++) {
-            @SuppressWarnings("unchecked")
-            List<Element> components = sections.get(i).getChildren("component");
-            for (int j = 0; j < components.size(); j++) {
-                Element comp = components.get(j);
-                funcTitles.put(comp.getAttributeValue("name"), Boolean.FALSE);
-                String tag = comp.getAttributeValue("tag");
-                if (tag != null){
-                    funcTitles.put(tag, Boolean.FALSE);                    
+        try (InputStream stream = new FileInputStream(compref)) {
+            Element body = getBodyFromXMLDocument(stream);
+            Element section = (Element) body.getElementsByTagName("section").item(0);
+            NodeList subSections = section.getElementsByTagName("subsection");
+            for (int i = 0; i < subSections.getLength(); i++) {
+                NodeList components = ((Element)subSections.item(i)).getElementsByTagName("component");
+                for (int j = 0; j < components.getLength(); j++) {
+                    org.w3c.dom.Element comp = (org.w3c.dom.Element) 
+                            components.item(j);
+                    funcTitles.put(comp.getAttribute("name"), Boolean.FALSE);
+                    String tag = comp.getAttribute("tag");
+                    if (!StringUtils.isEmpty(tag)){
+                        funcTitles.put(tag, Boolean.FALSE);                    
+                    }
                 }
             }
         }

Modified: jmeter/trunk/test/src/org/apache/jmeter/junit/JMeterTest.java
URL: http://svn.apache.org/viewvc/jmeter/trunk/test/src/org/apache/jmeter/junit/JMeterTest.java?rev=1734706&r1=1734705&r2=1734706&view=diff
==============================================================================
--- jmeter/trunk/test/src/org/apache/jmeter/junit/JMeterTest.java (original)
+++ jmeter/trunk/test/src/org/apache/jmeter/junit/JMeterTest.java Sat Mar 12 14:25:49 2016
@@ -22,6 +22,10 @@ import java.awt.Component;
 import java.awt.HeadlessException;
 import java.io.ByteArrayInputStream;
 import java.io.ByteArrayOutputStream;
+import java.io.FileInputStream;
+import java.io.FileNotFoundException;
+import java.io.IOException;
+import java.io.InputStream;
 import java.io.ObjectInputStream;
 import java.io.ObjectOutputStream;
 import java.io.Serializable;
@@ -36,6 +40,14 @@ import java.util.Map;
 import java.util.Properties;
 import java.util.Set;
 
+import javax.xml.parsers.DocumentBuilder;
+import javax.xml.parsers.DocumentBuilderFactory;
+import javax.xml.parsers.ParserConfigurationException;
+
+import junit.framework.Test;
+import junit.framework.TestSuite;
+
+import org.apache.commons.lang3.StringUtils;
 import org.apache.jmeter.config.gui.ObsoleteGui;
 import org.apache.jmeter.gui.JMeterGUIComponent;
 import org.apache.jmeter.gui.UnsharedComponent;
@@ -49,12 +61,11 @@ import org.apache.jorphan.logging.Loggin
 import org.apache.jorphan.reflect.ClassFinder;
 import org.apache.jorphan.util.JOrphanUtils;
 import org.apache.log.Logger;
-import org.jdom.Document;
-import org.jdom.Element;
-import org.jdom.input.SAXBuilder;
-
-import junit.framework.Test;
-import junit.framework.TestSuite;
+import org.w3c.dom.Document;
+import org.w3c.dom.Element;
+import org.w3c.dom.NodeList;
+import org.xml.sax.InputSource;
+import org.xml.sax.SAXException;
 
 public class JMeterTest extends JMeterTestCaseJUnit3 {
     private static final Logger log = LoggingManager.getLoggerForClass();
@@ -140,19 +151,19 @@ public class JMeterTest extends JMeterTe
         guiTitles = new HashMap<>(90);
 
         String compref = "../xdocs/usermanual/component_reference.xml";
-        SAXBuilder bldr = new SAXBuilder();
-        Document doc = bldr.build(compref);
-        Element root = doc.getRootElement();
-        Element body = root.getChild("body");
-        @SuppressWarnings("unchecked")
-        List<Element> sections = body.getChildren("section");
-        for (Element section : sections) {
-            @SuppressWarnings("unchecked")
-            List<Element> components = section.getChildren("component");
-            for (Element comp : components) {
-                String nm = comp.getAttributeValue("name");
-                if (!nm.equals("SSL Manager")) {// Not a true GUI component
-                    guiTitles.put(nm.replace(' ', '_'), Boolean.FALSE);
+        try (InputStream stream = new FileInputStream(compref)) {
+            org.w3c.dom.Element body = getBodyFromXMLDocument(stream);
+            NodeList sections = body.getElementsByTagName("section");
+            for (int i = 0; i < sections.getLength(); i++) {
+                org.w3c.dom.Element section = (org.w3c.dom.Element) sections.item(i);
+                NodeList components = section.getElementsByTagName("component");
+                for (int j = 0; j < components.getLength(); j++) {
+                    org.w3c.dom.Element comp = (org.w3c.dom.Element) 
+                            components.item(j);
+                    String nm = comp.getAttribute("name");
+                    if (!nm.equals("SSL Manager")) {// Not a true GUI component
+                        guiTitles.put(nm.replace(' ', '_'), Boolean.FALSE);
+                    }
                 }
             }
         }
@@ -160,6 +171,25 @@ public class JMeterTest extends JMeterTe
         guiTitles.put("Example Sampler", Boolean.FALSE);
     }
 
+    /**
+     * @return
+     * @throws ParserConfigurationException
+     * @throws IOException 
+     * @throws SAXException 
+     * @throws FileNotFoundException 
+     */
+    private Element getBodyFromXMLDocument(InputStream stream)
+            throws ParserConfigurationException, FileNotFoundException, SAXException, IOException {
+        DocumentBuilderFactory dbf = DocumentBuilderFactory.newInstance();
+        dbf.setIgnoringElementContentWhitespace(true);
+        dbf.setIgnoringComments(true);
+        DocumentBuilder db = dbf.newDocumentBuilder();
+        Document doc = db.parse(new InputSource(stream));
+        org.w3c.dom.Element root = doc.getDocumentElement();
+        org.w3c.dom.Element body = (org.w3c.dom.Element) root.getElementsByTagName("body").item(0);
+        return body;
+    }
+
     /*
      * Extract titles from component_reference.xml
      */
@@ -167,17 +197,21 @@ public class JMeterTest extends JMeterTe
         guiTags = new HashMap<>(90);
 
         String compref = "../xdocs/usermanual/component_reference.xml";
-        SAXBuilder bldr = new SAXBuilder();
-        Document doc = bldr.build(compref);
-        Element root = doc.getRootElement();
-        Element body = root.getChild("body");
-        @SuppressWarnings("unchecked")
-        List<Element> sections = body.getChildren("section");
-        for (Element section : sections) {
-            @SuppressWarnings("unchecked")
-            List<Element> components = section.getChildren("component");
-            for (Element comp : components) {
-                guiTags.put(comp.getAttributeValue("tag"), Boolean.FALSE);
+        try (InputStream stream = new FileInputStream(compref)) {
+            org.w3c.dom.Element body = getBodyFromXMLDocument(stream);
+            NodeList sections = body.getElementsByTagName("section");
+            
+            for (int i = 0; i < sections.getLength(); i++) {
+                org.w3c.dom.Element section = (org.w3c.dom.Element) sections.item(i);
+                NodeList components = section.getElementsByTagName("component");
+                for (int j = 0; j < components.getLength(); j++) {
+                    org.w3c.dom.Element comp = (org.w3c.dom.Element) 
+                            components.item(j);
+                    String tag = comp.getAttribute("tag");
+                    if (!StringUtils.isEmpty(tag)){
+                        guiTags.put(tag, Boolean.FALSE);
+                    }
+                }
             }
         }
     }

Modified: jmeter/trunk/xdocs/changes.xml
URL: http://svn.apache.org/viewvc/jmeter/trunk/xdocs/changes.xml?rev=1734706&r1=1734705&r2=1734706&view=diff
==============================================================================
--- jmeter/trunk/xdocs/changes.xml (original)
+++ jmeter/trunk/xdocs/changes.xml Sat Mar 12 14:25:49 2016
@@ -116,6 +116,21 @@ Summary
     </li>
     <li><code>httpsampler.await_termination_timeout</code> has been replaced by <code>httpsampler.parallel_download_thread_keepalive_inseconds</code> which is now the keep alive time for the parallel download threads (in seconds).</li>
     <li>For Thread Group Test Element, the property "Action to be taken after a Sample Error" value has been switched from "Continue" to "Start Next thread loop". See <bugzilla>59152</bugzilla></li>
+    <li>The following jars have been removed:
+    <ul>
+        <li>excalibur-datasource-2.1.jar (see <bugzilla>59156</bugzilla>)</li>
+        <li>excalibur-instrument-1.0.jar (see <bugzilla>58786</bugzilla>)</li>
+        <li>excalibur-pool-api-2.1.jar (see <bugzilla>58786</bugzilla>)</li>
+        <li>excalibur-pool-impl-2.1.jar (see <bugzilla>58786</bugzilla>)</li>
+        <li>excalibur-pool-instrumented-2.1.jar (see <bugzilla>58786</bugzilla>)</li>
+        <li>htmllexer-2.1.jar (see <bugzilla>59037</bugzilla>)</li>
+        <li>htmlparser-2.1.jar (see <bugzilla>59037</bugzilla>)</li>
+        <li>soap-2.3.1.jar</li>
+        <li>xmlpull-1.1.3.1.jar (see <bugzilla>58679</bugzilla>)</li>
+        <li>xpp3_min-1.1.4c.jar (see <bugzilla>58679</bugzilla>)</li>
+        <li>jdom-1.1.3.jar (see <bugzilla>59156</bugzilla>)</li>
+    </ul>
+    </li>
 </ul>
 
 <!-- =================== Improvements =================== -->
@@ -197,6 +212,7 @@ Summary
       Based on a patch by Vincent Herilier (vherilier at gmail.com)</li>
   <li><bug>58848</bug>Argument Panel : when adding an argument (add button or from clipboard) scroll the table to the new line. Contributed by Benoit Wiart (benoit dot wiart at gmail.com)</li>
   <li><bug>58865</bug>Allow empty default value in the Regular Expression Extractor. Contributed by Benoit Wiart (benoit dot wiart at gmail.com)</li>
+  <li><bug>59156</bug>XMLAssertion : drop jdom dependency by using XMLReader</li>
 </ul>
 
 <h3>Functions</h3>