Author: sebb
Date: Sat Jan 24 18:23:07 2009
New Revision: 737411

URL: http://svn.apache.org/viewvc?rev=737411&view=rev
Log:
Bug 46436 - Improve error reporting in Proxy Gui

Modified:
    
jakarta/jmeter/trunk/src/protocol/http/org/apache/jmeter/protocol/http/proxy/gui/ProxyControlGui.java
    jakarta/jmeter/trunk/xdocs/changes.xml

Modified: 
jakarta/jmeter/trunk/src/protocol/http/org/apache/jmeter/protocol/http/proxy/gui/ProxyControlGui.java
URL: 
http://svn.apache.org/viewvc/jakarta/jmeter/trunk/src/protocol/http/org/apache/jmeter/protocol/http/proxy/gui/ProxyControlGui.java?rev=737411&r1=737410&r2=737411&view=diff
==============================================================================
--- 
jakarta/jmeter/trunk/src/protocol/http/org/apache/jmeter/protocol/http/proxy/gui/ProxyControlGui.java
 (original)
+++ 
jakarta/jmeter/trunk/src/protocol/http/org/apache/jmeter/protocol/http/proxy/gui/ProxyControlGui.java
 Sat Jan 24 18:23:07 2009
@@ -26,6 +26,8 @@
 import java.awt.event.ItemListener;
 import java.awt.event.KeyEvent;
 import java.awt.event.KeyListener;
+import java.io.IOException;
+import java.net.BindException;
 import java.util.Arrays;
 import java.util.Collection;
 import java.util.LinkedList;
@@ -380,6 +382,16 @@
                     JMeterUtils.getResString("invalid_variables"), // 
$NON-NLS-1$
                     "Error",
                     JOptionPane.ERROR_MESSAGE);
+        } catch (BindException e) {
+            JOptionPane.showMessageDialog(this,
+                    JMeterUtils.getResString("proxy_daemon_bind_error"), // 
$NON-NLS-1$
+                    "Error",
+                    JOptionPane.ERROR_MESSAGE);
+        } catch (IOException e) {
+            JOptionPane.showMessageDialog(this,
+                    JMeterUtils.getResString("proxy_daemon_error"), // 
$NON-NLS-1$
+                    "Error",
+                    JOptionPane.ERROR_MESSAGE);
         }
     }
 
@@ -612,32 +624,6 @@
         panel.add(label);
         panel.add(targetNodes);
 
-        /*
-         * This listener subscription prevents freeing up the GUI when it's no
-         * longer in use (e.g. on locale change)... plus causes some anoying
-         * NPEs in the GUI instance created by the menu manager just to find 
out
-         * our name and which menus we want to be in... ... plus I don't think
-         * it's really necessary: configure(TestElement) already takes care of
-         * reinitializing the target combo when we come back to it. And I can't
-         * see how the tree can change in a relevant way without we leaving 
this
-         * GUI (since it is very unlikely that we will want to record into one
-         * of the controllers created by the proxy). I'll comment it out for 
the
-         * time being: TODO: remove once we're convinced it's really
-         * unnecessary.
-         */
-        /*
-         * try { Class addToTree =
-         * Class.forName("org.apache.jmeter.gui.action.AddToTree"); Class 
remove =
-         * Class.forName("org.apache.jmeter.gui.action.Remove"); ActionListener
-         * listener = new ActionListener() { public void
-         * actionPerformed(ActionEvent e) { reinitializeTargetCombo(); } };
-         * ActionRouter ar = ActionRouter.getInstance();
-         * ar.addPostActionListener(addToTree, listener);
-         * ar.addPostActionListener(remove, listener); } catch
-         * (ClassNotFoundException e) { // This should never happen -- throw an
-         * Error: throw new Error(e.toString());//JDK1.4: remove .toString() }
-         */
-
         return panel;
     }
 

Modified: jakarta/jmeter/trunk/xdocs/changes.xml
URL: 
http://svn.apache.org/viewvc/jakarta/jmeter/trunk/xdocs/changes.xml?rev=737411&r1=737410&r2=737411&view=diff
==============================================================================
--- jakarta/jmeter/trunk/xdocs/changes.xml (original)
+++ jakarta/jmeter/trunk/xdocs/changes.xml Sat Jan 24 18:23:07 2009
@@ -181,6 +181,7 @@
 <li>Correct the variable name "theadName" to "threadName" in the __jexl() and 
__javaScript() functions</li>
 <li>Bug 46522 - Incorrect "Response data" in JDBC sample when column names are 
missing</li>
 <li>Bug 46424 - corrections to French translation</li>
+<li>Bug 46436 - Improve error reporting in Proxy Gui</li>
 </ul>
 
 <h3>Improvements</h3>



---------------------------------------------------------------------
To unsubscribe, e-mail: jmeter-dev-unsubscr...@jakarta.apache.org
For additional commands, e-mail: jmeter-dev-h...@jakarta.apache.org

Reply via email to