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 2015/12/08 23:14:01 UTC

svn commit: r1718724 - in /jmeter/trunk/src: components/org/apache/jmeter/assertions/ core/org/apache/jmeter/samplers/ core/org/apache/jmeter/threads/ protocol/http/org/apache/jmeter/protocol/http/config/

Author: pmouawad
Date: Tue Dec  8 22:14:01 2015
New Revision: 1718724

URL: http://svn.apache.org/viewvc?rev=1718724&view=rev
Log:
#resolve #46

Modified:
    jmeter/trunk/src/components/org/apache/jmeter/assertions/MD5HexAssertion.java
    jmeter/trunk/src/core/org/apache/jmeter/samplers/Clearable.java
    jmeter/trunk/src/core/org/apache/jmeter/samplers/Entry.java
    jmeter/trunk/src/core/org/apache/jmeter/threads/JMeterThread.java
    jmeter/trunk/src/core/org/apache/jmeter/threads/JMeterVariables.java
    jmeter/trunk/src/core/org/apache/jmeter/threads/ListenerNotifier.java
    jmeter/trunk/src/protocol/http/org/apache/jmeter/protocol/http/config/MultipartUrlConfig.java

Modified: jmeter/trunk/src/components/org/apache/jmeter/assertions/MD5HexAssertion.java
URL: http://svn.apache.org/viewvc/jmeter/trunk/src/components/org/apache/jmeter/assertions/MD5HexAssertion.java?rev=1718724&r1=1718723&r2=1718724&view=diff
==============================================================================
--- jmeter/trunk/src/components/org/apache/jmeter/assertions/MD5HexAssertion.java (original)
+++ jmeter/trunk/src/components/org/apache/jmeter/assertions/MD5HexAssertion.java Tue Dec  8 22:14:01 2015
@@ -74,8 +74,6 @@ public class MD5HexAssertion extends Abs
 
         String md5Result = baMD5Hex(resultData);
 
-        // String md5Result = DigestUtils.md5Hex(resultData);
-
         if (!md5Result.equalsIgnoreCase(getAllowedMD5Hex())) {
             result.setFailure(true);
 

Modified: jmeter/trunk/src/core/org/apache/jmeter/samplers/Clearable.java
URL: http://svn.apache.org/viewvc/jmeter/trunk/src/core/org/apache/jmeter/samplers/Clearable.java?rev=1718724&r1=1718723&r2=1718724&view=diff
==============================================================================
--- jmeter/trunk/src/core/org/apache/jmeter/samplers/Clearable.java (original)
+++ jmeter/trunk/src/core/org/apache/jmeter/samplers/Clearable.java Tue Dec  8 22:14:01 2015
@@ -25,10 +25,9 @@ package org.apache.jmeter.samplers;
  * Intended for implementation by Listeners.
  */
 public interface Clearable {
+    
     /**
      * Clears the current data of the object.
      */
     void clearData();
-    // N.B. originally called clear()
-    // @see also JMeterGUIComponent
 }

Modified: jmeter/trunk/src/core/org/apache/jmeter/samplers/Entry.java
URL: http://svn.apache.org/viewvc/jmeter/trunk/src/core/org/apache/jmeter/samplers/Entry.java?rev=1718724&r1=1718723&r2=1718724&view=diff
==============================================================================
--- jmeter/trunk/src/core/org/apache/jmeter/samplers/Entry.java (original)
+++ jmeter/trunk/src/core/org/apache/jmeter/samplers/Entry.java Tue Dec  8 22:14:01 2015
@@ -27,18 +27,17 @@ import org.apache.jmeter.assertions.Asse
 import org.apache.jmeter.config.ConfigElement;
 
 // TODO - not used at present - could perhaps be removed
+@Deprecated
 public class Entry {
 
     private Map<Class<?>, ConfigElement> configSet;
 
-    // Set clonedSet;
     private Class<?> sampler;
 
     private List<Assertion> assertions;
 
     public Entry() {
         configSet = new HashMap<>();
-        // clonedSet = new HashSet();
         assertions = new LinkedList<>();
     }
 

Modified: jmeter/trunk/src/core/org/apache/jmeter/threads/JMeterThread.java
URL: http://svn.apache.org/viewvc/jmeter/trunk/src/core/org/apache/jmeter/threads/JMeterThread.java?rev=1718724&r1=1718723&r2=1718724&view=diff
==============================================================================
--- jmeter/trunk/src/core/org/apache/jmeter/threads/JMeterThread.java (original)
+++ jmeter/trunk/src/core/org/apache/jmeter/threads/JMeterThread.java Tue Dec  8 22:14:01 2015
@@ -425,7 +425,7 @@ public class JMeterThread implements Run
                 Sampler sampler = pack.getSampler();
                 sampler.setThreadContext(threadContext);
                 // TODO should this set the thread names for all the subsamples?
-                // might be more efficient than fetching the name elsewehere
+                // might be more efficient than fetching the name elsewhere
                 sampler.setThreadName(threadName);
                 TestBeanHelper.prepare(sampler);
 
@@ -542,15 +542,15 @@ public class JMeterThread implements Run
         threadContext.setThreadGroup(threadGroup);
         threadContext.setEngine(engine);
         testTree.traverse(compiler);
-        // listeners = controller.getListeners();
         if (scheduler) {
             // set the scheduler to start
             startScheduler();
         }
+
         rampUpDelay(); // TODO - how to handle thread stopped here
         log.info("Thread started: " + Thread.currentThread().getName());
         /*
-         * Setting SamplingStarted before the contollers are initialised allows
+         * Setting SamplingStarted before the controllers are initialised allows
          * them to access the running values of functions and variables (however
          * it does not seem to help with the listeners)
          */

Modified: jmeter/trunk/src/core/org/apache/jmeter/threads/JMeterVariables.java
URL: http://svn.apache.org/viewvc/jmeter/trunk/src/core/org/apache/jmeter/threads/JMeterVariables.java?rev=1718724&r1=1718723&r2=1718724&view=diff
==============================================================================
--- jmeter/trunk/src/core/org/apache/jmeter/threads/JMeterVariables.java (original)
+++ jmeter/trunk/src/core/org/apache/jmeter/threads/JMeterVariables.java Tue Dec  8 22:14:01 2015
@@ -71,6 +71,7 @@ public class JMeterVariables {
     }
 
     // Does not appear to be used
+    @Deprecated
     public void initialize() {
         variables.clear();
         preloadVariables();

Modified: jmeter/trunk/src/core/org/apache/jmeter/threads/ListenerNotifier.java
URL: http://svn.apache.org/viewvc/jmeter/trunk/src/core/org/apache/jmeter/threads/ListenerNotifier.java?rev=1718724&r1=1718723&r2=1718724&view=diff
==============================================================================
--- jmeter/trunk/src/core/org/apache/jmeter/threads/ListenerNotifier.java (original)
+++ jmeter/trunk/src/core/org/apache/jmeter/threads/ListenerNotifier.java Tue Dec  8 22:14:01 2015
@@ -89,183 +89,4 @@ public class ListenerNotifier {
         }
     }
 
-//    /**
-//     * The number of milliseconds between batches of notifications.
-//     */
-//    private static final int SLEEP_TIME = 2000;
-//
-//    /**
-//     * Indicates whether or not this thread should remain running. The thread
-//     * will continue running after this field is set to false until the next
-//     * batch of notifications has been completed and the notification queue is
-//     * empty.
-//     */
-//    private boolean running = true;
-//
-//    /**
-//     * Indicates whether or not this thread has stopped. No further
-//     * notifications will be performed.
-//     */
-//    private boolean isStopped = true;
-//
-//    /**
-//     * The queue containing the notifications to be performed. Each notification
-//     * consists of a pair of entries in this queue. The first is the
-//     * {@link org.apache.jmeter.samplers.SampleEvent SampleEvent} representing
-//     * the sample. The second is a List of
-//     * {@link org.apache.jmeter.samplers.SampleListener SampleListener}s which
-//     * should be notified.
-//     */
-//    private Buffer listenerEvents = BufferUtils.synchronizedBuffer(new UnboundedFifoBuffer());
-//
-//    /**
-//     * Stops the ListenerNotifier thread. The thread will continue processing
-//     * any events remaining in the notification queue before it actually stops,
-//     * but this method will return immediately.
-//     */
-//    public void stop() {
-//        running = false;
-//    }
-//
-//    /**
-//     * Indicates whether or not the thread has stopped. This will not return
-//     * true until the <code>stop</code> method has been called and any
-//     * remaining notifications in the queue have been completed.
-//     *
-//     * @return true if the ListenerNotifier has completely stopped, false
-//     *         otherwise
-//     */
-//    public boolean isStopped() {
-//        return isStopped;
-//    }
-//
-//    /**
-//     * Process the events in the notification queue until the thread has been
-//     * told to stop and the notification queue is empty.
-//     * <p>
-//     * In the current implementation, this method will iterate continually until
-//     * the thread is told to stop. In each iteration it will process any
-//     * notifications that are in the queue at the beginning of the iteration,
-//     * and then will sleep until it is time to start the next batch. As long as
-//     * the thread is keeping up, each batch should start 2 seconds after the
-//     * beginning of the last batch. This exact behavior is subject to change.
-//     */
-//    public void run() {
-//        boolean isMaximumPriority = false;
-//        int normalCount = 0;
-//
-//        while (running) {
-//            long startTime = System.currentTimeMillis();
-//            processNotifications();
-//            long sleep = SLEEP_TIME - (System.currentTimeMillis() - startTime);
-//
-//            // If the thread has been told to stop then we shouldn't sleep
-//            if (!running) {
-//                break;
-//            }
-//
-//            if (sleep < 0) {
-//                isMaximumPriority = true;
-//                normalCount = 0;
-//                if (log.isInfoEnabled()) {
-//                    log.info("ListenerNotifier exceeded maximum " + "notification time by " + (-sleep) + "ms");
-//                }
-//                boostPriority();
-//            } else {
-//                normalCount++;
-//
-//                // If there have been three consecutive iterations since the
-//                // last iteration which took too long to execute, return the
-//                // thread to normal priority.
-//                if (isMaximumPriority && normalCount >= 3) {
-//                    isMaximumPriority = false;
-//                    unboostPriority();
-//                }
-//
-//                if (log.isDebugEnabled()) {
-//                    log.debug("ListenerNotifier sleeping for " + sleep + "ms");
-//                }
-//
-//                try {
-//                    Thread.sleep(sleep);
-//                } catch (InterruptedException e) {
-//                }
-//            }
-//        }
-//
-//        // Make sure that all pending notifications are processed before
-//        // actually ending the thread.
-//        processNotifications();
-//        isStopped = true;
-//    }
-//
-//    /**
-//     * Process all of the pending notifications. Only the samples which are in
-//     * the queue when this method is called will be processed. Any samples added
-//     * between the time when this method is called and when it exits are saved
-//     * for the next batch.
-//     */
-//    private void processNotifications() {
-//        int listenerEventsSize = listenerEvents.size();
-//        if (log.isDebugEnabled()) {
-//            log.debug("ListenerNotifier: processing " + listenerEventsSize + " events");
-//        }
-//
-//        while (listenerEventsSize > 0) {
-//            // Since this is a FIFO and this is the only place we remove
-//            // from it (only from a single thread) we don't have to remove
-//            // these two items in one atomic operation. Each individual
-//            // remove is atomic (because we use a synchronized buffer),
-//            // which is necessary since the buffer can be accessed from
-//            // other threads (to add things to the buffer).
-//            SampleEvent res = (SampleEvent) listenerEvents.remove();
-//            List listeners = (List) listenerEvents.remove();
-//
-//            notifyListeners(res, listeners);
-//
-//            listenerEventsSize -= 2;
-//        }
-//    }
-//
-//    /**
-//     * Boost the priority of the current thread to maximum priority. If the
-//     * thread is already at maximum priority then this will have no effect.
-//     */
-//    private void boostPriority() {
-//        if (Thread.currentThread().getPriority() != Thread.MAX_PRIORITY) {
-//            log.info("ListenerNotifier: Boosting thread priority to maximum.");
-//            Thread.currentThread().setPriority(Thread.MAX_PRIORITY);
-//        }
-//    }
-//
-//    /**
-//     * Return the priority of the current thread to normal. If the thread is
-//     * already at normal priority then this will have no effect.
-//     */
-//    private void unboostPriority() {
-//        if (Thread.currentThread().getPriority() != Thread.NORM_PRIORITY) {
-//            log.info("ListenerNotifier: Returning thread priority to normal.");
-//            Thread.currentThread().setPriority(Thread.NORM_PRIORITY);
-//        }
-//    }
-//
-//    /**
-//     * Add a new sample event to the notification queue. The notification will
-//     * be performed asynchronously and this method will return immediately.
-//     *
-//     * @param item
-//     *            the sample event that has occurred. Must be non-null.
-//     * @param listeners
-//     *            a list of the listeners which should be notified. This list
-//     *            must not be null and must contain only SampleListener
-//     *            elements.
-//     */
-//    public void addLast(SampleEvent item, List listeners) {
-//        // Must use explicit synchronization here so that the item and
-//        // listeners are added together atomically
-//        synchronized (listenerEvents) {
-//            listenerEvents.add(item);
-//            listenerEvents.add(listeners);
-//        }
-//    }
 }

Modified: jmeter/trunk/src/protocol/http/org/apache/jmeter/protocol/http/config/MultipartUrlConfig.java
URL: http://svn.apache.org/viewvc/jmeter/trunk/src/protocol/http/org/apache/jmeter/protocol/http/config/MultipartUrlConfig.java?rev=1718724&r1=1718723&r2=1718724&view=diff
==============================================================================
--- jmeter/trunk/src/protocol/http/org/apache/jmeter/protocol/http/config/MultipartUrlConfig.java (original)
+++ jmeter/trunk/src/protocol/http/org/apache/jmeter/protocol/http/config/MultipartUrlConfig.java Tue Dec  8 22:14:01 2015
@@ -82,20 +82,6 @@ public class MultipartUrlConfig implemen
         return files;
     }
 
-// NOT USED
-//    /**
-//     * @deprecated values in a multipart/form-data are not urlencoded,
-//     * so it does not make sense to add a value as a encoded value
-//     */
-//  public void addEncodedArgument(String name, String value) {
-//      Arguments myArgs = getArguments();
-//      HTTPArgument arg = new HTTPArgument(name, value, true);
-//      if (arg.getName().equals(arg.getEncodedName()) && arg.getValue().equals(arg.getEncodedValue())) {
-//          arg.setAlwaysEncoded(false);
-//      }
-//      myArgs.addArgument(arg);
-//  }
-
     /**
      * Add a value that is not URL encoded, and make sure it
      * appears in the GUI that it will not be encoded when



Re: svn commit: r1718724 - in /jmeter/trunk/src: components/org/apache/jmeter/assertions/ core/org/apache/jmeter/samplers/ core/org/apache/jmeter/threads/ protocol/http/org/apache/jmeter/protocol/http/config/

Posted by sebb <se...@gmail.com>.
On 8 December 2015 at 22:14,  <pm...@apache.org> wrote:
> Author: pmouawad
> Date: Tue Dec  8 22:14:01 2015
> New Revision: 1718724
>
> URL: http://svn.apache.org/viewvc?rev=1718724&view=rev
> Log:
> #resolve #46
>
> Modified:
>     jmeter/trunk/src/components/org/apache/jmeter/assertions/MD5HexAssertion.java
>     jmeter/trunk/src/core/org/apache/jmeter/samplers/Clearable.java
>     jmeter/trunk/src/core/org/apache/jmeter/samplers/Entry.java
>     jmeter/trunk/src/core/org/apache/jmeter/threads/JMeterThread.java
>     jmeter/trunk/src/core/org/apache/jmeter/threads/JMeterVariables.java
>     jmeter/trunk/src/core/org/apache/jmeter/threads/ListenerNotifier.java
>     jmeter/trunk/src/protocol/http/org/apache/jmeter/protocol/http/config/MultipartUrlConfig.java
>
> Modified: jmeter/trunk/src/components/org/apache/jmeter/assertions/MD5HexAssertion.java
> URL: http://svn.apache.org/viewvc/jmeter/trunk/src/components/org/apache/jmeter/assertions/MD5HexAssertion.java?rev=1718724&r1=1718723&r2=1718724&view=diff
> ==============================================================================
> --- jmeter/trunk/src/components/org/apache/jmeter/assertions/MD5HexAssertion.java (original)
> +++ jmeter/trunk/src/components/org/apache/jmeter/assertions/MD5HexAssertion.java Tue Dec  8 22:14:01 2015
> @@ -74,8 +74,6 @@ public class MD5HexAssertion extends Abs
>
>          String md5Result = baMD5Hex(resultData);
>
> -        // String md5Result = DigestUtils.md5Hex(resultData);
> -
>          if (!md5Result.equalsIgnoreCase(getAllowedMD5Hex())) {
>              result.setFailure(true);
>
>
> Modified: jmeter/trunk/src/core/org/apache/jmeter/samplers/Clearable.java
> URL: http://svn.apache.org/viewvc/jmeter/trunk/src/core/org/apache/jmeter/samplers/Clearable.java?rev=1718724&r1=1718723&r2=1718724&view=diff
> ==============================================================================
> --- jmeter/trunk/src/core/org/apache/jmeter/samplers/Clearable.java (original)
> +++ jmeter/trunk/src/core/org/apache/jmeter/samplers/Clearable.java Tue Dec  8 22:14:01 2015
> @@ -25,10 +25,9 @@ package org.apache.jmeter.samplers;
>   * Intended for implementation by Listeners.
>   */
>  public interface Clearable {
> +
>      /**
>       * Clears the current data of the object.
>       */
>      void clearData();
> -    // N.B. originally called clear()
> -    // @see also JMeterGUIComponent
>  }
>
> Modified: jmeter/trunk/src/core/org/apache/jmeter/samplers/Entry.java
> URL: http://svn.apache.org/viewvc/jmeter/trunk/src/core/org/apache/jmeter/samplers/Entry.java?rev=1718724&r1=1718723&r2=1718724&view=diff
> ==============================================================================
> --- jmeter/trunk/src/core/org/apache/jmeter/samplers/Entry.java (original)
> +++ jmeter/trunk/src/core/org/apache/jmeter/samplers/Entry.java Tue Dec  8 22:14:01 2015
> @@ -27,18 +27,17 @@ import org.apache.jmeter.assertions.Asse
>  import org.apache.jmeter.config.ConfigElement;
>
>  // TODO - not used at present - could perhaps be removed
> +@Deprecated

-1 to this change.

Although the class is not used, it is still referenced in method definitions.

Deprecating it just adds noise to the builds, making it harder to see
actual problems.
Until such time as it is possible to fix the deprecation, there is no
point in flagging it as deprecated.

>  public class Entry {
>
>      private Map<Class<?>, ConfigElement> configSet;
>
> -    // Set clonedSet;
>      private Class<?> sampler;
>
>      private List<Assertion> assertions;
>
>      public Entry() {
>          configSet = new HashMap<>();
> -        // clonedSet = new HashSet();
>          assertions = new LinkedList<>();
>      }
>
>
> Modified: jmeter/trunk/src/core/org/apache/jmeter/threads/JMeterThread.java
> URL: http://svn.apache.org/viewvc/jmeter/trunk/src/core/org/apache/jmeter/threads/JMeterThread.java?rev=1718724&r1=1718723&r2=1718724&view=diff
> ==============================================================================
> --- jmeter/trunk/src/core/org/apache/jmeter/threads/JMeterThread.java (original)
> +++ jmeter/trunk/src/core/org/apache/jmeter/threads/JMeterThread.java Tue Dec  8 22:14:01 2015
> @@ -425,7 +425,7 @@ public class JMeterThread implements Run
>                  Sampler sampler = pack.getSampler();
>                  sampler.setThreadContext(threadContext);
>                  // TODO should this set the thread names for all the subsamples?
> -                // might be more efficient than fetching the name elsewehere
> +                // might be more efficient than fetching the name elsewhere
>                  sampler.setThreadName(threadName);
>                  TestBeanHelper.prepare(sampler);
>
> @@ -542,15 +542,15 @@ public class JMeterThread implements Run
>          threadContext.setThreadGroup(threadGroup);
>          threadContext.setEngine(engine);
>          testTree.traverse(compiler);
> -        // listeners = controller.getListeners();
>          if (scheduler) {
>              // set the scheduler to start
>              startScheduler();
>          }
> +
>          rampUpDelay(); // TODO - how to handle thread stopped here
>          log.info("Thread started: " + Thread.currentThread().getName());
>          /*
> -         * Setting SamplingStarted before the contollers are initialised allows
> +         * Setting SamplingStarted before the controllers are initialised allows
>           * them to access the running values of functions and variables (however
>           * it does not seem to help with the listeners)
>           */
>
> Modified: jmeter/trunk/src/core/org/apache/jmeter/threads/JMeterVariables.java
> URL: http://svn.apache.org/viewvc/jmeter/trunk/src/core/org/apache/jmeter/threads/JMeterVariables.java?rev=1718724&r1=1718723&r2=1718724&view=diff
> ==============================================================================
> --- jmeter/trunk/src/core/org/apache/jmeter/threads/JMeterVariables.java (original)
> +++ jmeter/trunk/src/core/org/apache/jmeter/threads/JMeterVariables.java Tue Dec  8 22:14:01 2015
> @@ -71,6 +71,7 @@ public class JMeterVariables {
>      }
>
>      // Does not appear to be used
> +    @Deprecated

This one is OK, because it is not referenced.

>      public void initialize() {
>          variables.clear();
>          preloadVariables();
>
> Modified: jmeter/trunk/src/core/org/apache/jmeter/threads/ListenerNotifier.java
> URL: http://svn.apache.org/viewvc/jmeter/trunk/src/core/org/apache/jmeter/threads/ListenerNotifier.java?rev=1718724&r1=1718723&r2=1718724&view=diff
> ==============================================================================
> --- jmeter/trunk/src/core/org/apache/jmeter/threads/ListenerNotifier.java (original)
> +++ jmeter/trunk/src/core/org/apache/jmeter/threads/ListenerNotifier.java Tue Dec  8 22:14:01 2015
> @@ -89,183 +89,4 @@ public class ListenerNotifier {
>          }
>      }
>
> -//    /**
> -//     * The number of milliseconds between batches of notifications.
> -//     */
> -//    private static final int SLEEP_TIME = 2000;
> -//
> -//    /**
> -//     * Indicates whether or not this thread should remain running. The thread
> -//     * will continue running after this field is set to false until the next
> -//     * batch of notifications has been completed and the notification queue is
> -//     * empty.
> -//     */
> -//    private boolean running = true;
> -//
> -//    /**
> -//     * Indicates whether or not this thread has stopped. No further
> -//     * notifications will be performed.
> -//     */
> -//    private boolean isStopped = true;
> -//
> -//    /**
> -//     * The queue containing the notifications to be performed. Each notification
> -//     * consists of a pair of entries in this queue. The first is the
> -//     * {@link org.apache.jmeter.samplers.SampleEvent SampleEvent} representing
> -//     * the sample. The second is a List of
> -//     * {@link org.apache.jmeter.samplers.SampleListener SampleListener}s which
> -//     * should be notified.
> -//     */
> -//    private Buffer listenerEvents = BufferUtils.synchronizedBuffer(new UnboundedFifoBuffer());
> -//
> -//    /**
> -//     * Stops the ListenerNotifier thread. The thread will continue processing
> -//     * any events remaining in the notification queue before it actually stops,
> -//     * but this method will return immediately.
> -//     */
> -//    public void stop() {
> -//        running = false;
> -//    }
> -//
> -//    /**
> -//     * Indicates whether or not the thread has stopped. This will not return
> -//     * true until the <code>stop</code> method has been called and any
> -//     * remaining notifications in the queue have been completed.
> -//     *
> -//     * @return true if the ListenerNotifier has completely stopped, false
> -//     *         otherwise
> -//     */
> -//    public boolean isStopped() {
> -//        return isStopped;
> -//    }
> -//
> -//    /**
> -//     * Process the events in the notification queue until the thread has been
> -//     * told to stop and the notification queue is empty.
> -//     * <p>
> -//     * In the current implementation, this method will iterate continually until
> -//     * the thread is told to stop. In each iteration it will process any
> -//     * notifications that are in the queue at the beginning of the iteration,
> -//     * and then will sleep until it is time to start the next batch. As long as
> -//     * the thread is keeping up, each batch should start 2 seconds after the
> -//     * beginning of the last batch. This exact behavior is subject to change.
> -//     */
> -//    public void run() {
> -//        boolean isMaximumPriority = false;
> -//        int normalCount = 0;
> -//
> -//        while (running) {
> -//            long startTime = System.currentTimeMillis();
> -//            processNotifications();
> -//            long sleep = SLEEP_TIME - (System.currentTimeMillis() - startTime);
> -//
> -//            // If the thread has been told to stop then we shouldn't sleep
> -//            if (!running) {
> -//                break;
> -//            }
> -//
> -//            if (sleep < 0) {
> -//                isMaximumPriority = true;
> -//                normalCount = 0;
> -//                if (log.isInfoEnabled()) {
> -//                    log.info("ListenerNotifier exceeded maximum " + "notification time by " + (-sleep) + "ms");
> -//                }
> -//                boostPriority();
> -//            } else {
> -//                normalCount++;
> -//
> -//                // If there have been three consecutive iterations since the
> -//                // last iteration which took too long to execute, return the
> -//                // thread to normal priority.
> -//                if (isMaximumPriority && normalCount >= 3) {
> -//                    isMaximumPriority = false;
> -//                    unboostPriority();
> -//                }
> -//
> -//                if (log.isDebugEnabled()) {
> -//                    log.debug("ListenerNotifier sleeping for " + sleep + "ms");
> -//                }
> -//
> -//                try {
> -//                    Thread.sleep(sleep);
> -//                } catch (InterruptedException e) {
> -//                }
> -//            }
> -//        }
> -//
> -//        // Make sure that all pending notifications are processed before
> -//        // actually ending the thread.
> -//        processNotifications();
> -//        isStopped = true;
> -//    }
> -//
> -//    /**
> -//     * Process all of the pending notifications. Only the samples which are in
> -//     * the queue when this method is called will be processed. Any samples added
> -//     * between the time when this method is called and when it exits are saved
> -//     * for the next batch.
> -//     */
> -//    private void processNotifications() {
> -//        int listenerEventsSize = listenerEvents.size();
> -//        if (log.isDebugEnabled()) {
> -//            log.debug("ListenerNotifier: processing " + listenerEventsSize + " events");
> -//        }
> -//
> -//        while (listenerEventsSize > 0) {
> -//            // Since this is a FIFO and this is the only place we remove
> -//            // from it (only from a single thread) we don't have to remove
> -//            // these two items in one atomic operation. Each individual
> -//            // remove is atomic (because we use a synchronized buffer),
> -//            // which is necessary since the buffer can be accessed from
> -//            // other threads (to add things to the buffer).
> -//            SampleEvent res = (SampleEvent) listenerEvents.remove();
> -//            List listeners = (List) listenerEvents.remove();
> -//
> -//            notifyListeners(res, listeners);
> -//
> -//            listenerEventsSize -= 2;
> -//        }
> -//    }
> -//
> -//    /**
> -//     * Boost the priority of the current thread to maximum priority. If the
> -//     * thread is already at maximum priority then this will have no effect.
> -//     */
> -//    private void boostPriority() {
> -//        if (Thread.currentThread().getPriority() != Thread.MAX_PRIORITY) {
> -//            log.info("ListenerNotifier: Boosting thread priority to maximum.");
> -//            Thread.currentThread().setPriority(Thread.MAX_PRIORITY);
> -//        }
> -//    }
> -//
> -//    /**
> -//     * Return the priority of the current thread to normal. If the thread is
> -//     * already at normal priority then this will have no effect.
> -//     */
> -//    private void unboostPriority() {
> -//        if (Thread.currentThread().getPriority() != Thread.NORM_PRIORITY) {
> -//            log.info("ListenerNotifier: Returning thread priority to normal.");
> -//            Thread.currentThread().setPriority(Thread.NORM_PRIORITY);
> -//        }
> -//    }
> -//
> -//    /**
> -//     * Add a new sample event to the notification queue. The notification will
> -//     * be performed asynchronously and this method will return immediately.
> -//     *
> -//     * @param item
> -//     *            the sample event that has occurred. Must be non-null.
> -//     * @param listeners
> -//     *            a list of the listeners which should be notified. This list
> -//     *            must not be null and must contain only SampleListener
> -//     *            elements.
> -//     */
> -//    public void addLast(SampleEvent item, List listeners) {
> -//        // Must use explicit synchronization here so that the item and
> -//        // listeners are added together atomically
> -//        synchronized (listenerEvents) {
> -//            listenerEvents.add(item);
> -//            listenerEvents.add(listeners);
> -//        }
> -//    }
>  }
>
> Modified: jmeter/trunk/src/protocol/http/org/apache/jmeter/protocol/http/config/MultipartUrlConfig.java
> URL: http://svn.apache.org/viewvc/jmeter/trunk/src/protocol/http/org/apache/jmeter/protocol/http/config/MultipartUrlConfig.java?rev=1718724&r1=1718723&r2=1718724&view=diff
> ==============================================================================
> --- jmeter/trunk/src/protocol/http/org/apache/jmeter/protocol/http/config/MultipartUrlConfig.java (original)
> +++ jmeter/trunk/src/protocol/http/org/apache/jmeter/protocol/http/config/MultipartUrlConfig.java Tue Dec  8 22:14:01 2015
> @@ -82,20 +82,6 @@ public class MultipartUrlConfig implemen
>          return files;
>      }
>
> -// NOT USED
> -//    /**
> -//     * @deprecated values in a multipart/form-data are not urlencoded,
> -//     * so it does not make sense to add a value as a encoded value
> -//     */
> -//  public void addEncodedArgument(String name, String value) {
> -//      Arguments myArgs = getArguments();
> -//      HTTPArgument arg = new HTTPArgument(name, value, true);
> -//      if (arg.getName().equals(arg.getEncodedName()) && arg.getValue().equals(arg.getEncodedValue())) {
> -//          arg.setAlwaysEncoded(false);
> -//      }
> -//      myArgs.addArgument(arg);
> -//  }
> -
>      /**
>       * Add a value that is not URL encoded, and make sure it
>       * appears in the GUI that it will not be encoded when
>
>