From 96952d52950fde2a6b84661794838d68dab8b792 Mon Sep 17 00:00:00 2001 From: Dongkyu Hwangbo Date: Mon, 7 Sep 2015 16:53:33 +0900 Subject: [PATCH 1/4] reset --- .../org/apache/tajo/cli/tsql/TajoCli.java | 82 +++++++++---------- 1 file changed, 41 insertions(+), 41 deletions(-) diff --git a/tajo-cli/src/main/java/org/apache/tajo/cli/tsql/TajoCli.java b/tajo-cli/src/main/java/org/apache/tajo/cli/tsql/TajoCli.java index affd12807a..3022a68748 100644 --- a/tajo-cli/src/main/java/org/apache/tajo/cli/tsql/TajoCli.java +++ b/tajo-cli/src/main/java/org/apache/tajo/cli/tsql/TajoCli.java @@ -74,21 +74,21 @@ public class TajoCli { private boolean wasError = false; private static final Class [] registeredCommands = { - DescTableCommand.class, - DescFunctionCommand.class, - HelpCommand.class, - ExitCommand.class, - CopyrightCommand.class, - VersionCommand.class, - ConnectDatabaseCommand.class, - ListDatabaseCommand.class, - SetCommand.class, - UnsetCommand.class, - ExecExternalShellCommand.class, - HdfsCommand.class, - TajoAdminCommand.class, - TajoGetConfCommand.class, - TajoHAAdminCommand.class + DescTableCommand.class, + DescFunctionCommand.class, + HelpCommand.class, + ExitCommand.class, + CopyrightCommand.class, + VersionCommand.class, + ConnectDatabaseCommand.class, + ListDatabaseCommand.class, + SetCommand.class, + UnsetCommand.class, + ExecExternalShellCommand.class, + HdfsCommand.class, + TajoAdminCommand.class, + TajoGetConfCommand.class, + TajoHAAdminCommand.class }; private final Map commands = new TreeMap(); @@ -275,11 +275,11 @@ public TajoCli(TajoConf c, String [] args, InputStream in, OutputStream out) thr } } catch (Exception e) { System.err.println(ERROR_PREFIX + "Exception was thrown. Caused by " + e.getMessage()); - + if (client != null) { client.close(); } - + throw e; } @@ -360,8 +360,8 @@ private void initCommands() { for (Class clazz : registeredCommands) { TajoShellCommand cmd = null; try { - Constructor cons = clazz.getConstructor(new Class[] {TajoCliContext.class}); - cmd = (TajoShellCommand) cons.newInstance(context); + Constructor cons = clazz.getConstructor(new Class[] {TajoCliContext.class}); + cmd = (TajoShellCommand) cons.newInstance(context); } catch (Exception e) { System.err.println(e.getMessage()); throw new RuntimeException(e.getMessage()); @@ -405,7 +405,7 @@ public int runShell() throws Exception { sout.write("Try \\? for help.\n"); SimpleParser parser = new SimpleParser(); - + try { while((line = reader.readLine(currentPrompt + "> ")) != null) { if (line.equals("")) { @@ -435,11 +435,11 @@ public int runShell() throws Exception { } } catch (Exception e) { System.err.println(ERROR_PREFIX + "Exception was thrown. Casued by " + e.getMessage()); - + if (client != null) { client.close(); } - + throw e; } return 0; @@ -498,15 +498,15 @@ private void executeJsonQuery(String json) throws TajoException { if (ReturnStateUtil.isSuccess(response.getState())) { switch (response.getResultType()) { - case FETCH: - QueryId queryId = new QueryId(response.getQueryId()); - waitForQueryCompleted(queryId); - break; - case ENCLOSED: - localQueryCompleted(response, startTime); - break; - default: - displayFormatter.printMessage(sout, "OK"); + case FETCH: + QueryId queryId = new QueryId(response.getQueryId()); + waitForQueryCompleted(queryId); + break; + case ENCLOSED: + localQueryCompleted(response, startTime); + break; + default: + displayFormatter.printMessage(sout, "OK"); } } else { @@ -529,17 +529,17 @@ private int executeQuery(String statement) throws SQLException { switch (response.getResultType()) { - case FETCH: - QueryId queryId = new QueryId(response.getQueryId()); - waitForQueryCompleted(queryId); - break; + case FETCH: + QueryId queryId = new QueryId(response.getQueryId()); + waitForQueryCompleted(queryId); + break; - case ENCLOSED: - localQueryCompleted(response, startTime); - break; + case ENCLOSED: + localQueryCompleted(response, startTime); + break; - default: - displayFormatter.printMessage(sout, "OK"); + default: + displayFormatter.printMessage(sout, "OK"); } } else { @@ -697,4 +697,4 @@ public static void main(String [] args) throws Exception { System.out.println(); System.exit(shell.runShell()); } -} +} \ No newline at end of file From 04f240b5aa594c35084a081442284da96362005f Mon Sep 17 00:00:00 2001 From: Dongkyu Hwangbo Date: Mon, 7 Sep 2015 17:00:43 +0900 Subject: [PATCH 2/4] reset --- .../org/apache/tajo/cli/tsql/TajoCli.java | 82 +++++++++---------- 1 file changed, 41 insertions(+), 41 deletions(-) diff --git a/tajo-cli/src/main/java/org/apache/tajo/cli/tsql/TajoCli.java b/tajo-cli/src/main/java/org/apache/tajo/cli/tsql/TajoCli.java index 3022a68748..affd12807a 100644 --- a/tajo-cli/src/main/java/org/apache/tajo/cli/tsql/TajoCli.java +++ b/tajo-cli/src/main/java/org/apache/tajo/cli/tsql/TajoCli.java @@ -74,21 +74,21 @@ public class TajoCli { private boolean wasError = false; private static final Class [] registeredCommands = { - DescTableCommand.class, - DescFunctionCommand.class, - HelpCommand.class, - ExitCommand.class, - CopyrightCommand.class, - VersionCommand.class, - ConnectDatabaseCommand.class, - ListDatabaseCommand.class, - SetCommand.class, - UnsetCommand.class, - ExecExternalShellCommand.class, - HdfsCommand.class, - TajoAdminCommand.class, - TajoGetConfCommand.class, - TajoHAAdminCommand.class + DescTableCommand.class, + DescFunctionCommand.class, + HelpCommand.class, + ExitCommand.class, + CopyrightCommand.class, + VersionCommand.class, + ConnectDatabaseCommand.class, + ListDatabaseCommand.class, + SetCommand.class, + UnsetCommand.class, + ExecExternalShellCommand.class, + HdfsCommand.class, + TajoAdminCommand.class, + TajoGetConfCommand.class, + TajoHAAdminCommand.class }; private final Map commands = new TreeMap(); @@ -275,11 +275,11 @@ public TajoCli(TajoConf c, String [] args, InputStream in, OutputStream out) thr } } catch (Exception e) { System.err.println(ERROR_PREFIX + "Exception was thrown. Caused by " + e.getMessage()); - + if (client != null) { client.close(); } - + throw e; } @@ -360,8 +360,8 @@ private void initCommands() { for (Class clazz : registeredCommands) { TajoShellCommand cmd = null; try { - Constructor cons = clazz.getConstructor(new Class[] {TajoCliContext.class}); - cmd = (TajoShellCommand) cons.newInstance(context); + Constructor cons = clazz.getConstructor(new Class[] {TajoCliContext.class}); + cmd = (TajoShellCommand) cons.newInstance(context); } catch (Exception e) { System.err.println(e.getMessage()); throw new RuntimeException(e.getMessage()); @@ -405,7 +405,7 @@ public int runShell() throws Exception { sout.write("Try \\? for help.\n"); SimpleParser parser = new SimpleParser(); - + try { while((line = reader.readLine(currentPrompt + "> ")) != null) { if (line.equals("")) { @@ -435,11 +435,11 @@ public int runShell() throws Exception { } } catch (Exception e) { System.err.println(ERROR_PREFIX + "Exception was thrown. Casued by " + e.getMessage()); - + if (client != null) { client.close(); } - + throw e; } return 0; @@ -498,15 +498,15 @@ private void executeJsonQuery(String json) throws TajoException { if (ReturnStateUtil.isSuccess(response.getState())) { switch (response.getResultType()) { - case FETCH: - QueryId queryId = new QueryId(response.getQueryId()); - waitForQueryCompleted(queryId); - break; - case ENCLOSED: - localQueryCompleted(response, startTime); - break; - default: - displayFormatter.printMessage(sout, "OK"); + case FETCH: + QueryId queryId = new QueryId(response.getQueryId()); + waitForQueryCompleted(queryId); + break; + case ENCLOSED: + localQueryCompleted(response, startTime); + break; + default: + displayFormatter.printMessage(sout, "OK"); } } else { @@ -529,17 +529,17 @@ private int executeQuery(String statement) throws SQLException { switch (response.getResultType()) { - case FETCH: - QueryId queryId = new QueryId(response.getQueryId()); - waitForQueryCompleted(queryId); - break; + case FETCH: + QueryId queryId = new QueryId(response.getQueryId()); + waitForQueryCompleted(queryId); + break; - case ENCLOSED: - localQueryCompleted(response, startTime); - break; + case ENCLOSED: + localQueryCompleted(response, startTime); + break; - default: - displayFormatter.printMessage(sout, "OK"); + default: + displayFormatter.printMessage(sout, "OK"); } } else { @@ -697,4 +697,4 @@ public static void main(String [] args) throws Exception { System.out.println(); System.exit(shell.runShell()); } -} \ No newline at end of file +} From 80391efa328b04a63fba026db6d31c2ba452b005 Mon Sep 17 00:00:00 2001 From: Dongkyu Hwangbo Date: Mon, 7 Sep 2015 17:05:11 +0900 Subject: [PATCH 3/4] initial ver --- tajo-core/src/main/resources/webapps/admin/query_executor.jsp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tajo-core/src/main/resources/webapps/admin/query_executor.jsp b/tajo-core/src/main/resources/webapps/admin/query_executor.jsp index 49a43d45ba..cc3efcefb7 100644 --- a/tajo-core/src/main/resources/webapps/admin/query_executor.jsp +++ b/tajo-core/src/main/resources/webapps/admin/query_executor.jsp @@ -300,7 +300,7 @@ function getPage() { <% for (String databaseName : master.getCatalog().getAllDatabaseNames()) { %> - + <% } %> From cfeb33119dd1efcabbcc5e6d847d258d32926776 Mon Sep 17 00:00:00 2001 From: Dongkyu Hwangbo Date: Tue, 8 Sep 2015 09:56:44 +0900 Subject: [PATCH 4/4] travis trigger