Permalink
Browse files

Allow workbench to still statup on socket bind error

  • Loading branch information...
1 parent 70ae7ac commit c605e684549e4bb116c97671d6fe253b50b78472 @jeffheaton jeffheaton committed Apr 19, 2012
Showing with 8 additions and 0 deletions.
  1. +8 −0 src/main/java/org/encog/workbench/EncogWorkBench.java
@@ -32,6 +32,7 @@
import org.encog.Encog;
import org.encog.EncogError;
+import org.encog.cloud.basic.CloudError;
import org.encog.cloud.node.CloudNode;
import org.encog.mathutil.error.ErrorCalculation;
import org.encog.ml.MLMethod;
@@ -426,6 +427,7 @@ public static String displayInput(String prompt, String str) {
}
public void setupServer() {
+ try {
if( this.config.isAllowConnections() ) {
// we should be allowing connections, are we?
if( this.cloudNode!=null ) {
@@ -445,6 +447,12 @@ public void setupServer() {
stopAccepting();
}
}
+ } catch(CloudError e) {
+ this.outputLine("Error starting server: " + e.getMessage());
+ e.printStackTrace();
+ } catch(Throwable t) {
+ EncogWorkBench.displayError("Error Starting Server", t);
+ }
}
public void beginAccepting() {

0 comments on commit c605e68

Please sign in to comment.