From 1cd3ff1a7086fbf9656e786bf075e4b58af35593 Mon Sep 17 00:00:00 2001 From: "Wang, Fei" Date: Sat, 7 Sep 2024 22:38:28 -0700 Subject: [PATCH] pretty --- .../org/apache/kyuubi/ctl/cmd/delete/DeleteBatchCommand.scala | 2 +- .../org/apache/kyuubi/ctl/cmd/submit/SubmitBatchCommand.scala | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/kyuubi-ctl/src/main/scala/org/apache/kyuubi/ctl/cmd/delete/DeleteBatchCommand.scala b/kyuubi-ctl/src/main/scala/org/apache/kyuubi/ctl/cmd/delete/DeleteBatchCommand.scala index ee4a14d2666..288c33ac9ba 100644 --- a/kyuubi-ctl/src/main/scala/org/apache/kyuubi/ctl/cmd/delete/DeleteBatchCommand.scala +++ b/kyuubi-ctl/src/main/scala/org/apache/kyuubi/ctl/cmd/delete/DeleteBatchCommand.scala @@ -38,7 +38,7 @@ class DeleteBatchCommand(cliConfig: CliConfig) extends Command[Batch](cliConfig) val result = batchRestApi.deleteBatch(batchId) - info(JsonUtils.toJson(result)) + info(JsonUtils.toPrettyJson(result)) if (!result.isSuccess) { val batch = batchRestApi.getBatchById(batchId) diff --git a/kyuubi-ctl/src/main/scala/org/apache/kyuubi/ctl/cmd/submit/SubmitBatchCommand.scala b/kyuubi-ctl/src/main/scala/org/apache/kyuubi/ctl/cmd/submit/SubmitBatchCommand.scala index 863da98d44f..452f1348e6d 100644 --- a/kyuubi-ctl/src/main/scala/org/apache/kyuubi/ctl/cmd/submit/SubmitBatchCommand.scala +++ b/kyuubi-ctl/src/main/scala/org/apache/kyuubi/ctl/cmd/submit/SubmitBatchCommand.scala @@ -48,7 +48,7 @@ class SubmitBatchCommand(cliConfig: CliConfig) extends Command[Batch](cliConfig) batch = logBatchCommand.doRun() if (BatchUtils.isTerminalState(batch.getState) && !BatchUtils.isFinishedState(batch.getState)) { - error(s"Batch ${batch.getId} failed: ${JsonUtils.toJson(batch)}") + error(s"Batch ${batch.getId} failed:\n${${Render.renderBatchInfo(batch)}}") throw ControlCliException(1) }