geronimo-scm mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From xuhaih...@apache.org
Subject svn commit: r1158498 - /geronimo/server/trunk/framework/modules/geronimo-deploy-tool/src/main/java/org/apache/geronimo/deployment/cli/StreamConsoleReader.java
Date Wed, 17 Aug 2011 03:46:22 GMT
Author: xuhaihong
Date: Wed Aug 17 03:46:22 2011
New Revision: 1158498

URL: http://svn.apache.org/viewvc?rev=1158498&view=rev
Log:
Use throwable as the catch type, and only print the stack tarce while debug option is opened

Modified:
    geronimo/server/trunk/framework/modules/geronimo-deploy-tool/src/main/java/org/apache/geronimo/deployment/cli/StreamConsoleReader.java

Modified: geronimo/server/trunk/framework/modules/geronimo-deploy-tool/src/main/java/org/apache/geronimo/deployment/cli/StreamConsoleReader.java
URL: http://svn.apache.org/viewvc/geronimo/server/trunk/framework/modules/geronimo-deploy-tool/src/main/java/org/apache/geronimo/deployment/cli/StreamConsoleReader.java?rev=1158498&r1=1158497&r2=1158498&view=diff
==============================================================================
--- geronimo/server/trunk/framework/modules/geronimo-deploy-tool/src/main/java/org/apache/geronimo/deployment/cli/StreamConsoleReader.java
(original)
+++ geronimo/server/trunk/framework/modules/geronimo-deploy-tool/src/main/java/org/apache/geronimo/deployment/cli/StreamConsoleReader.java
Wed Aug 17 03:46:22 2011
@@ -56,8 +56,11 @@ public class StreamConsoleReader impleme
             } else {
                 jlineConsoleReader = new jline.console.ConsoleReader(in, out);
             }
-        } catch (Exception e) {
-            logger.warn("Fail to create jline console, some features like password mask will
be disabled", e);
+        } catch (Throwable e) {
+            logger.warn("Fail to create jline console, some features like password mask will
be disabled, you might change the log level to debug to show the detailed information");
+            if (logger.isDebugEnabled()) {
+                logger.debug("Fail to create jline console, some features like password mask
will be disabled", e);
+            }
             jlineConsoleEnabled = false;
             keyboard = new BufferedReader(new InputStreamReader(in));
             console = out;



Mime
View raw message