Author: fmui
Date: Fri Nov 15 10:11:34 2013
New Revision: 1542214
URL: http://svn.apache.org/r1542214
Log:
Workbench: minor error handling improvements
Modified:
chemistry/opencmis/trunk/chemistry-opencmis-workbench/chemistry-opencmis-workbench/src/main/java/org/apache/chemistry/opencmis/workbench/ConnectionErrorDialog.java
Modified:
chemistry/opencmis/trunk/chemistry-opencmis-workbench/chemistry-opencmis-workbench/src/main/java/org/apache/chemistry/opencmis/workbench/ConnectionErrorDialog.java
URL:
http://svn.apache.org/viewvc/chemistry/opencmis/trunk/chemistry-opencmis-workbench/chemistry-opencmis-workbench/src/main/java/org/apache/chemistry/opencmis/workbench/ConnectionErrorDialog.java?rev=1542214&r1=1542213&r2=1542214&view=diff
==============================================================================
---
chemistry/opencmis/trunk/chemistry-opencmis-workbench/chemistry-opencmis-workbench/src/main/java/org/apache/chemistry/opencmis/workbench/ConnectionErrorDialog.java
(original)
+++
chemistry/opencmis/trunk/chemistry-opencmis-workbench/chemistry-opencmis-workbench/src/main/java/org/apache/chemistry/opencmis/workbench/ConnectionErrorDialog.java
Fri Nov 15 10:11:34 2013
@@ -120,7 +120,6 @@ public class ConnectionErrorDialog exten
getRootPane().setDefaultButton(closeButton);
- ClientHelper.installKeyBindings();
ClientHelper.installEscapeBinding(this, getRootPane(), true);
setDefaultCloseOperation(JFrame.DISPOSE_ON_CLOSE);
@@ -146,7 +145,7 @@ public class ConnectionErrorDialog exten
} else if (exception instanceof CmisRuntimeException) {
return "Something fatal happend on the client or server side."
+ "<br>Check your URL, the binding, and your proxy
settings."
- + "<br>Also see the CMIS Workbench log for more details."
+ getProxyConfig();
+ + "<br><br>Also see the CMIS Workbench log for more
details." + getProxyConfig();
} else if (exception instanceof CmisConnectionException) {
Throwable cause = exception.getCause();
while (cause instanceof CmisConnectionException) {
@@ -167,13 +166,19 @@ public class ConnectionErrorDialog exten
+ "<br><b>WARNING:</b> It disables <em>all</em> SSL
certificate checks!" + getProxyConfig();
} else if (cause instanceof JSONParseException) {
return "The provided URL does not return a JSON response."
- + "<br>Check your URL, the binding, and your proxy
settings." + getProxyConfig();
+ + "<br>Check your URL, the binding, and your proxy
settings."
+ + "<br><br>Some servers return a HTML login page if
the credentials are incorrect."
+ + "<br>Check your credentials." + getProxyConfig();
} else if (cause instanceof XMLStreamException) {
return "The provided URL does not return an AtomPub response."
- + "<br>Check your URL, the binding, and your proxy
settings." + getProxyConfig();
+ + "<br>Check your URL, the binding, and your proxy
settings."
+ + "<br><br>Some servers return a HTML login page if
the credentials are incorrect."
+ + "<br>Check your credentials." + getProxyConfig();
} else if (cause instanceof SAXParseException) {
return "The provided URL does not return a WSDL."
- + "<br>Check your URL, the binding, and your proxy
settings." + getProxyConfig();
+ + "<br>Check your URL, the binding, and your proxy
settings."
+ + "<br><br>Some servers return a HTML login page if
the credentials are incorrect."
+ + "<br>Check your credentials." + getProxyConfig();
} else if (cause instanceof IOException) {
return "A network problem occured.<br>Check your URL and your
network and proxy settings."
+ getProxyConfig();
@@ -181,7 +186,9 @@ public class ConnectionErrorDialog exten
if
(exception.getMessage().toLowerCase(Locale.ENGLISH).startsWith("unexpected
document")) {
return "The provided URL does not return a AtomPub response."
- + "<br>Check your URL, the binding, and your proxy
settings." + getProxyConfig();
+ + "<br>Check your URL, the binding, and your proxy
settings."
+ + "<br><br>Some servers return a HTML login page if
the credentials are incorrect."
+ + "<br>Check your credentials." + getProxyConfig();
}
return "Check the URL, the binding, and the credentials.";